Edit D:\AVA\AVAStandard\AVA.ResourcesPlatform.WebUI\Themes\NewtonTheme\Control\My\MyVideoEdit.ascx
??<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="MyVideoEdit.ascx.cs" Inherits="AVA.ResourcesPlatform.WebUI.Control.My.MyVideoEdit" %> <%= new MyVideoNavInstance(this) { Local = MyVideoNavItem.??????, Video = this.Video }.ToHtml() %> <div class="flat data-box"> <div class="head"> <span class="title">??????????????</span> </div> <div class="userInput body"> <form id="frmVideoEdit" action="" method="post" onsubmit="return false;"> <table border="0" cellpadding="2px" cellspacing="2px" class="table-cleaned"> <tr> <td class="label-td"><span class="label"><span class="required">*</span>?????</span></td> <td> <%= new HtmlText("Name", this.Video.Name, 256) { }%> <%= new HtmlYKTip("Name")%> </td> </tr> <tr> <td class="label-td"><span class="label">??????</span></td> <td><% var speaker = this.Video.Spreaker; if (speaker == null) { speaker = this.Video.ParentUser.UserName; } %> <%= new HtmlText("Spreaker", speaker, 256) { }%> </td> </tr> <tr> <td class="label-td"><span class="label"><span class="required">*</span>??????<a href="#" title="????? mp4; wmv; asf; avi; flv ???H264?????? ">?</a>??</span></td> <td> <%= new HtmlText("FileName", this.Video.FileName) { ReadOnly = true }%> <%= new HtmlYKTip("FileName")%> <div> <%= new SingleUploadInstance(this) { UploadTag = "FileName", Accept = CreateInstance.DomainInfoDao.THIS().UploadVideoType.ToUpper().Replace("*","").Replace(";",","), UploadControlName="?????????"}.ToHtml()%> <%-- <%= new SingleUploadInstance(this) { UploadTag = "FileName", InitParams = "FileFilter=" + CreateInstance.DomainInfoDao.THIS().UploadVideoType.ToUpper().Replace("*.","") + "???????????(" + CreateInstance.DomainInfoDao.THIS().UploadVideoType + ")|" + CreateInstance.DomainInfoDao.THIS().UploadVideoType + ",DefaultColor=#F5F5F5F5,SelectFiles=??????????????,Upload=?????????" }.ToHtml()%> --%> <%= new HtmlHidden("VideoUploadPath",SettingGroup.VideoUploadPath) %> <script type="text/javascript"> //????????????????????????????????uid $("#frmVideoEdit [name=VideoUploadPath]").val('<%= SettingGroup.VideoUploadPath + this.Video.Guid + "/" %>'); function UploadFinishedFileName(fileName, fileSize) { $("#frmVideoEdit [Name=FileName]").val(fileName); $("#frmVideoEdit [Name=FileSize]").val(fileSize) if (fileName.toLowerCase().indexOf(".asf") != -1) { $("#frmVideoEdit [Name=FileType]").val("1"); } else if (fileName.toLowerCase().indexOf(".wmv") != -1) { $("#frmVideoEdit [Name=FileType]").val("2"); } else if (fileName.toLowerCase().indexOf(".flv") != -1) { $("#frmVideoEdit [Name=FileType]").val("3"); } else if (fileName.toLowerCase().indexOf(".rm") != -1) { $("#frmVideoEdit [Name=FileType]").val("4"); } else if (fileName.toLowerCase().indexOf(".rmvb") != -1) { $("#frmVideoEdit [Name=FileType]").val("5"); } else if (fileName.toLowerCase().indexOf(".avi") != -1) { $("#frmVideoUpload [Name=FileType]").val("6"); } else if (fileName.toLowerCase().indexOf(".mp4") != -1) { $("#frmVideoUpload [Name=FileType]").val("7"); } else { $("#frmVideoUpload [Name=FileType]").val("0"); } //????????? if ($("#frmVideoEdit [name=FileName]").val() != "") { $("#btnUploadVideoToVideo").show(); $("#frmVideoEdit [name=VideoUploadPath]").val("<%= SettingGroup.UploadPath %>"); } else { $("#btnUploadVideoToVideo").hide(); $("#frmVideoEdit [name=VideoUploadPath]").val("<%= SettingGroup.UploadPath %>"); } } </script> </div> <%--<%= new HtmlAnchor("????????????????????????????????????????") { Href=Request.WebPath()+"/Resource/Silverlight.zip" }%>--%> </td> </tr> <tr> <td class="label-td"><span class="label"><span class="required">*</span>?????</span></td> <td> <%= new HtmlSelect("ParentCategory", "Name", "Guid", "Guid") { Option = this.ListAllCategory, OptGroup= CreateInstance.CategoryDao.GetOptGroup(this.ListAllCategory), OnChange = "GetTextbook();", SelectedValue = this.Video.ParentCategory.Guid}.InsertOption("::???::", "", 0)%> <%= new HtmlYKTip("ParentCategory") { }%> </td> </tr> <tr> <td class="label-td"><span class="label"><span class="required"><%= CreateInstance.ConfigDao.VideoGradeTag("") != null ? "*" : "" %></span>?????</span></td> <td> <%= new HtmlSelect("ParentGrade", "Name", "Guid", "Guid") { Option = this.ListAllGrade, OptGroup= CreateInstance.GradeDao.GetOptGroup(this.ListAllGrade), DefaultSelectValue = "", SelectedValue = (this.Video.ParentGrade != null ? this.Video.ParentGrade.Guid : ""), OnChange = "GetTextbook();" }.InsertOption("::???::", "", 0)%> <%= new HtmlYKTip("ParentGrade") { }%> </td> </tr> <tr> <td class="label-td"><span class="label"><span class="required"><%= CreateInstance.ConfigDao.VideoPressTag("") != null ? "*" : "" %></span>??????</span></td> <td> <%= new HtmlSelect("ParentPress", "Name", "Guid", "Guid") { Option = this.ListAllPress, DefaultSelectValue = "", SelectedValue = (this.Video.ParentPress != null ? this.Video.ParentPress.Guid : ""), OnChange = "GetTextbook();" }.InsertOption("::???::", "", 0)%> <%= new HtmlYKTip("ParentPress") { }%> </td> </tr> <%if (SettingGroup.HasWeike) { %> <tr> <td class="label-td"><span class="label">?????????</span></td> <td> <%= new HtmlCheckBox("IsWeiKe", this.Video.IsWeiKe, 1, 0) {Class="IsWeiKe" }%> </td> </tr> <% } %> <% if (SettingGroup.Setting().VideoRangeControl == true) { if(this.VideoViewRange == null) { %> <tr> <td class="label-td"><span class="label">???????????</span></td> <td> <%= new HtmlCheckBox("PersonPageView", false ,true, false) { ID = "PersonPageView", Class="VideoViewRange", Lang="?????????"}%> <%= new HtmlLabel("PersonPageViewLabel", "?????????")%> <%= new HtmlCheckBox("SchoolPageView",false, true, false) { ID = "SchoolPageView", Class="VideoViewRange", Lang="?????????"}%> <%= new HtmlLabel("SchoolPageViewLabel", "?????????")%> <%= new HtmlCheckBox("AreaPageView", false,true, false) { ID = "AreaPageView", Class="VideoViewRange", Lang="????????"}%> <%= new HtmlLabel("AreaPageViewLabel", "????????")%> <span class="label">????????????????????????????????????</span> </td> </tr> <% } else { %> <tr> <td class="label-td"><span class="label">???????????</span></td> <td> <%--??????--%> <% if (this.VideoViewRange.PersonPageView == (int)AVA.ResourcesPlatform.Model.Pub.VideoViewRangePersonPageViewEnum.?????) { %> <%= new HtmlCheckBox("PersonPageView", true ,true, false) { ID = "PersonPageView", Class="VideoViewRange", Lang="?????????", Disabled = true, Title="??????"}%> <%= new HtmlLabel("PersonPageViewLabel", "?????????")%> <% } else { %> <%= new HtmlCheckBox("PersonPageView", this.VideoViewRange.PersonPageView == (int)AVA.ResourcesPlatform.Model.Pub.VideoViewRangePersonPageViewEnum.??? ? true : false ,true, false) { ID = "PersonPageView", Class="VideoViewRange", Lang="?????????"}%> <%= new HtmlLabel("PersonPageViewLabel", "?????????")%> <% } %> <%--??????--%> <% if (this.VideoViewRange.SchoolPageView == (int)AVA.ResourcesPlatform.Model.Pub.VideoViewRangeSchoolPageViewEnum.?????) { %> <%= new HtmlCheckBox("SchoolPageView", true ,true, false) { ID = "SchoolPageView", Class="VideoViewRange", Lang="?????????", Disabled = true, Title="??????"}%> <%= new HtmlLabel("SchoolPageViewLabel", "?????????")%> <% } else { %> <%= new HtmlCheckBox("SchoolPageView", this.VideoViewRange.PersonPageView == (int)AVA.ResourcesPlatform.Model.Pub.VideoViewRangePersonPageViewEnum.??? ? true : false ,true, false) { ID = "SchoolPageView", Class="VideoViewRange", Lang="?????????"}%> <%= new HtmlLabel("SchoolPageViewLabel", "?????????")%> <% } %> <%--?????--%> <% if (this.VideoViewRange.AreaPageView == (int)AVA.ResourcesPlatform.Model.Pub.VideoViewRangeAreaPageViewEnum.?????) { %> <%= new HtmlCheckBox("AreaPageView", true ,true, false) { ID = "AreaPageView", Class="VideoViewRange", Lang="????????", Disabled = true, Title="??????"}%> <%= new HtmlLabel("AreaPageViewLabel", "????????")%> <% } else { %> <%= new HtmlCheckBox("AreaPageView", this.VideoViewRange.PersonPageView == (int)AVA.ResourcesPlatform.Model.Pub.VideoViewRangePersonPageViewEnum.??? ? true : false ,true, false) { ID = "AreaPageView", Class="VideoViewRange", Lang="????????"}%> <%= new HtmlLabel("AreaPageViewLabel", "????????")%> <% } %> <%--<%= new HtmlCheckBox("SchoolPageView",true, true, false) { ID = "SchoolPageView", Class="VideoViewRange", Lang="?????????"}%> <%= new HtmlLabel("SchoolPageViewLabel", "?????????")%> <%= new HtmlCheckBox("AreaPageView", true,true, false) { ID = "AreaPageView", Class="VideoViewRange", Lang="????????"}%> <%= new HtmlLabel("AreaPageViewLabel", "????????")%>--%> <span class="label">????????????????????????????????????</span> </td> </tr> <% } } %> <tr> <td class="label-td"><span class="label">???????????(",")?????</span></td> <td> <%= new HtmlText("VideoTag", this.VideoTag, 256) { Class="VideoTag", Width=800 ,ID = "inputTags"}%> <%if (this.ListTag.Count > 0) { var listTagCK = this.ListTag.Where(l => l.TagType == (int)AVA.ResourcesPlatform.Model.Pub.TagTagTypeEnum.??????).ToList();//?????? var listTagWK = this.ListTag.Where(l => l.TagType == (int)AVA.ResourcesPlatform.Model.Pub.TagTagTypeEnum.??????).ToList();//?????? %> <p class="label">????????</p> <ul class="columns column4" style="margin: 0px; display: <%= this.Video.IsWeiKe ? "none" : ""%>" id="ckTag"> <%foreach (var item in listTagCK) { %> <li> <%-- <%= new HtmlCheckBox("Tag", this.ListSelectTag.Contains(item.Guid), item.Guid, "") { ID = "Tag" + item.Guid, Class="Tag", Lang=item.Name}%>--%> <%= new HtmlLabel( item.Guid, item.Name) { Class="addClass"}.AddAttribute("data-value",item.Name) %> </li> <% } %> </ul> <ul class="columns column4" style="margin: 0px; display: <%= this.Video.IsWeiKe ? "" : "none"%>;" id="wkTag"> <%foreach (var item in listTagWK) { %> <li> <%-- <%= new HtmlCheckBox("Tag", this.ListSelectTag.Contains(item.Guid), item.Guid, "") { ID = "Tag" + item.Guid, Class="Tag", Lang=item.Name}%>--%> <%= new HtmlLabel("Tag" + item.Guid, item.Name) { Class="addClass"}.AddAttribute("data-value",item.Name) %> </li> <% } %> </ul> <% } %> <script> $(function () { $("#inputTags").attr("value", $("#inputTags").val().split(" ").join(",")); $("#inputTags").tagsInput({ 'defaultText': '???...' }); $(".addClass").on("click", function (e) { $('#inputTags').addTag($(e.target).attr("data-value")); }); $(".IsWeiKe").click(function () { if (this.checked == true) { $(".VideoTag").val(""); $(".Tag").removeAttr("checked"); $("#ckTag").toggle(); $("#wkTag").toggle(); } else { $(".VideoTag").val(""); $(".Tag").removeAttr("checked"); $("#ckTag").toggle(); $("#wkTag").toggle(); } }); $(".Tag").click(function () { var tag = this.lang; var videoTag = $(".VideoTag").val().trim(); if (this.checked == true) { if (videoTag == "") { $(".VideoTag").val(tag); } else { $(".VideoTag").val(videoTag + " " + tag) } } else { if (videoTag.indexOf(tag) >= 0) { videoTag = videoTag.replace(tag, ""); $(".VideoTag").val(videoTag); } } }); }); </script> </td> </tr> <tr> <td class="label-td"><span class="label">?????</span></td> <td> <%= new HtmlTextArea("Summary", this.Video.Summary, 2000)%> </td> </tr> </table> <div class="accordion_bl" style="background: #FCFCFC; margin-bottom: 20px;"> <div class="accordion"> <div class="accordion-heading "> <a href="#slide-con_AlbumInfo" data-parent="" data-toggle="collapse" class="accordion-toggle ">?????? <i class="ico oct"></i> </a> </div> <div class="accordion-body collapse " id="slide-con_AlbumInfo"> <div class=" accordion-inner"> <table border="0" cellpadding="2px" cellspacing="2px" class="table-cleaned"> <tr> <td class="label-td"><span class="label"><span class="required"><%= CreateInstance.ConfigDao.VideoCaptionsFileTag("") != null ? "*" : "" %></span>????????</span></td> <td> <%= new HtmlText("CaptionsFile", this.Video.CaptionsFile) { Class = "ipt-t ipt-t-dft ",ReadOnly = true }%> <%= new HtmlButton("???","$('#frmVideoEdit [Name=CaptionsFile]').val('');").Style(new { Width = "60px" })%> <%= new HtmlYKTip("CaptionsFile")%> <div> <%= new SingleUploadInstance(this) { UploadTag = "CaptionsFile", Accept = ".srt", UploadControlName="?????????"}.ToHtml()%> <%-- <%= new SingleUploadInstance(this) { UploadTag = "CaptionsFile", InitParams = "FileFilter=*.srt|*.srt,DefaultColor=#F5F5F5F5,SelectFiles=??????????????,Upload=?????????" }.ToHtml()%> --%> <script type="text/javascript"> function UploadFinishedCaptionsFile(captionsFile, fileSize) { $("#frmVideoEdit [Name=CaptionsFile]").val(captionsFile); } </script> </div> </td> </tr> <tr> <td class="label-td"><span class="label"><span class="required"><%= CreateInstance.ConfigDao.VideoCoverTag("") != null ? "*" : "" %></span>????????</span></td> <td> <table border="0"> <tr> <td> <%= new HtmlHidden("Cover", this.Video.Cover) { Class = "ipt-t ipt-t-dft " }%> <%= new HtmlImg(SettingGroup.VideoCoverL(this.Video), "") { ID = "imgCover", OnErrorImg=SettingGroup.DefaultImg, Width=480,Height=300 }%> </td> </tr> <tr> <td> <input type="button" value="??????" onclick="UploadVideoCover();" style="width: auto;" /> <% if (this.Video.ParentPlaySaveServer == null) { %> <input type="button" id="btnUploadVideoToVideo" value="???????????" onclick="UploadVideoToVideo();" style="width: auto; display: none;" /> <% } %> <%= new HtmlYKTip("Cover")%> <script type="text/javascript"> function UploadVideoCover() { UploadFile('#frmVideoEdit [name=Cover]', '?????????', '0', '<%= SettingGroup.VideoUploadPath %>', '', '480', '300'); } $(function () { if ($("#frmVideoEdit [name=FileName]").val() != "") { $("#btnUploadVideoToVideo").show(); } else { $("#btnUploadVideoToVideo").hide(); } }); function UploadVideoToVideo() { UploadImage('#frmVideoEdit [name=Cover]', '?????????', '0', $("#frmVideoEdit [name=VideoUploadPath]").val(), '<%=this.Video.FileNameGuid%>', '480', '300'); } </script> </td> </tr> <tr> <td>???.jpg??if??ng???????? </td> </tr> </table> </td> </tr> <tr style="display: none;"> <td class="label-td"><span class="label"><span class="required">*</span>????????</span></td> <td> <%= new HtmlSelect("FileType", "Value", "Key") { Option = typeof(AVA.ResourcesPlatform.Model.Pub.VideoFileTypeEnum), Disabled = true, SelectedValue=this.Video.FileType }.InsertOption("::" + DefineEnum.???.Define() + "::", null, 0)%> </td> </tr> <tr style="display: none;"> <td class="label-td"><span class="label"><span class="required">*</span>????????</span></td> <td> <%= new HtmlText("FileSize",this.Video.FileSize) { ReadOnly = true }%> </td> </tr> <tr> <td class="label-td"></td> <td>??????????????????????????????????????????????????? </td> </tr> <tr id="liTextbook" style="display: none;"> <td class="label-td"><span class="label"><%= CreateInstance.ConfigDao.VideoTextBookTag("") != null ? "*" : "" %>?????</span></td> <td><span id="spanTextbook"></span></td> </tr> <tr id="liLesson" style="display: none;"> <td class="label-td"><span class="label"><%= CreateInstance.ConfigDao.VideoTextBookTag("") != null ? "*" : "" %>??????</span></td> <td><span id="spanLesson"></span></td> </tr> <tr style="display: none;"> <td class="label-td"><span class="label"><span class="required">*</span>????????</span></td> <td> <%= new HtmlText("RecTime", this.Video.RecTime, 200) { }.Style(new { Width = "120px" })%> <%= new HtmlYKTip("RecTime")%> </td> </tr> <tr style="display: none;"> <td class="label-td"><span class="label">???(??)??</span></td> <td> <%= new HtmlText("Period", this.Video.Period, 200) { }.Style(new { Width = "120px" })%> <%= new HtmlYKTip("Period")%> </td> </tr> <tr> <td class="label-td"><span class="label"><span class="required">*</span>?????</span></td> <td> <%= new HtmlRadio("Copyright", (this.Video.Copyright == 0 ? true : false), 0, null) { ID = "Video_Copyright_0" }.Style(new { Width = "auto" })%> <label for="Video_Copyright_0"> ??? </label> <%= new HtmlRadio("Copyright", (this.Video.Copyright == 1 ? true : false), 1, null) { ID = "Video_Copyright_1" }.Style(new { Width = "auto" })%> <label for="Video_Copyright_1"> ??? </label> <%= new HtmlYKTip("Copyright") %> </td> </tr> <tr> <td class="label-td"><span class="label"><span class="required">*</span>????????</span></td> <td> <%= new HtmlRadio("Share", (this.Video.Share == 0 ? true : false), 0, null) { ID = "Video_Share_0" }.Style(new { Width = "auto" })%> <label for="Video_Share_0"> ??? </label> <%--<%= new HtmlRadio("Share", (this.Video.Share == 1 ? true : false), 1, null) { ID = "Video_Share_1" }.Style(new { Width = "auto" })%> <label for="Video_Share_1"> ??? </label>--%> <%= new HtmlRadio("Share", (this.Video.Share == 2 ? true : false), 2, null) { ID = "Video_Share_2" }.Style(new { Width = "auto" })%> <label for="Video_Share_2"> ??? </label> <%= new HtmlRadio("Share", (this.Video.Share == 3 ? true : false), 3, null) { ID = "Video_Share_3" }.Style(new { Width = "auto" })%> <label for="Video_Share_3"> ?????? </label> <%= new HtmlYKTip("Share") %> </td> </tr> <tr> <td class="label-td"><span class="label">????????</span></td> <td> <%= new HtmlCheckBox("HasDownload",this.Video.HasDownload,1,0)%> </td> </tr> <tr> <td class="label-td"><span class="label">????????</span></td> <td> <%= new HtmlTextArea("Description", this.Video.Description, 2000)%> </td> </tr> <tr class="hidden"> <td class="label-td"><span class="label"><span class="required">*</span>??????</span></td> <td> <%= new HtmlText("SortNumber", this.Video.SortNumber, 4) { DefaultValue = 1 }%> <%= new HtmlYKTip("SortNumber") %> </td> </tr> <tr> <td class="label-td"><span class="label">????????</span></td> <td> <ul class=" column-list"> <% for (var i = 0; i <= this.ListAllChannel.Count - 1; i++) { var channel = this.ListAllChannel[i]; string parentChannelGuid = ""; if (channel.ParentChannel != null) { parentChannelGuid = channel.ParentChannel.Guid; %> <li style="padding-left: 40px;"> <%= new HtmlCheckBox("Channel", this.SelectChannel.Contains(channel.Guid), channel.Guid, "") { ID = "Channel" + channel.Guid, Class = "ChannelItem ChannelItemChannel" + parentChannelGuid, Lang = channel.ParentChannel.Guid }.Style(new { Width = "auto" })%> <%= new HtmlLabel("Channel" + channel.Guid, channel.Name)%> <% if (i == 0) { %> <%= new HtmlYKTip("Channel")%> <% } %> </li> <% } else { %> <li> <%= new HtmlCheckBox("Channel", this.SelectChannel.Contains(channel.Guid) , channel.Guid, "") { ID = "Channel" + channel.Guid, Class = "ChannelMaster ChannelMaster" + channel.Guid }.Style(new { Width = "auto", Display="none"})%> <%= new HtmlLabel("Channel" + channel.Guid, channel.Name)%> <% if (i == 0) { %> <%= new HtmlYKTip("Channel")%> <% } %> </li> <% } } %> </ul> <script type="text/javascript"> //????????? $(".ChannelMaster").bind("click", function () { if (this.checked == false) { $(".ChannelItem" + this.id).removeAttr("checked"); } }) //????????? $(".ChannelItem").bind("click", function () { if (this.checked == true) { $(".ChannelMaster" + this.lang).attr("checked", "checked"); } else { if ($(".ChannelItemChannel" + this.lang + ":checked").length > 0) { $(".ChannelMaster" + this.lang).attr("checked", "checked"); } else { $(".ChannelMaster" + this.lang).removeAttr("checked"); } } }) </script> </td> </tr> <tr> <td style="height: 80px;"></td> </tr> </table> </div> </div> </div> </div> <table border="0" cellpadding="2px" cellspacing="2px" class="table-cleaned"> <tr> <td class="label-td"><span class="label"></span></td> <td> <%= new HtmlHidden("Key", SetKey(this.Video.Guid, this.Video.Version))%> <%= new HtmlSubmit("?????????", "VideoEdit", "VideoEditClient(this);").Style(new { Width = "100px" })%> </td> </tr> </table> </form> </div> <script type="text/javascript"> $(function () { GetTextbook('<%= this.Video.ParentLesson != null ? this.Video.ParentLesson.ParentTextbook.Guid : ""%>', '<%= this.Video.ParentLesson != null ? this.Video.ParentLesson.Guid : ""%>'); }); function GetTextbook(textbook, lesson) { var categoryGuid = $("#frmVideoEdit [Name=ParentCategory]").val(); var pressGuid = $("#frmVideoEdit [Name=ParentPress]").val(); var gradeGuid = $("#frmVideoEdit [Name=ParentGrade]").val(); if (categoryGuid != "" && pressGuid != "" && gradeGuid != "") { //?????? $("#spanTextbook").html("????????????..."); $("#liTextbook").show(); $("#spanLesson").html(""); $("#liLesson").hide(); Global.HtmlControl("<%= ControlPath("/My/SelectTextbook")%>", "ParentCategory=" + encodeURIComponent(categoryGuid) + "&ParentPress=" + encodeURIComponent(pressGuid) + "&ParentGrade=" + encodeURIComponent(gradeGuid) + "&TextbookGuid=" + textbook, null, function (result) { $("#spanTextbook").html(result.Html); //??????????????????????? //flash($("#frmVideoUpload [name=ParentTextbook]")); if ($("#frmVideoEdit [name=ParentTextbook]").length > 0) { <% if (CreateInstance.ConfigDao.VideoTextBookTag("") != null) { %> $.validator.removeValid("#frmVideoEdit [name=ParentTextbook]", "VideoEdit"); $.validator.removeValid("#frmVideoEdit [name=ParentLesson]", "VideoEdit"); $("#frmVideoEdit [name=ParentTextbook]").formValidator({ validatorGroup: "VideoEdit", rules: { required: null }, message: { required: "????????" } }); <% } %> } //?????? if (lesson != null) { GetLesson(lesson); } }); } else { //?????? $("#spanTextbook").html(""); $.validator.removeValid("#frmVideoEdit [name=ParentTextbook]", "VideoEdit"); $("#liTextbook").hide(); $("#spanLesson").html(""); $.validator.removeValid("#frmVideoEdit [name=ParentLesson]", "VideoEdit"); $("#liLesson").hide(); } } function GetLesson(lesson) { var textbookGuid = $("#frmVideoEdit [Name=ParentTextbook]").val(); if (textbookGuid != "" && textbookGuid != null) { //???????? $("#spanLesson").html("??????????????..."); $("#liLesson").show(); Global.HtmlControl("<%= ControlPath("/My/SelectLesson")%>", "ParentTextbook=" + encodeURIComponent(textbookGuid) + "&LessonGuid=" + lesson, null, function (result) { $("#spanLesson").html(result.Html); //flash($("#frmVideoUpload [name=ParentLesson]")); if ($("#frmVideoEdit [name=ParentLesson]").length > 0) { <% if (CreateInstance.ConfigDao.VideoLessonTag("") != null) { %> $.validator.removeValid("#frmVideoEdit [name=ParentLesson]", "VideoEdit"); $("#frmVideoEdit [name=ParentLesson]").formValidator({ validatorGroup: "VideoEdit", rules: { required: null }, message: { required: "??????????" } }); <% } %> } }); } else { //???????? $("#spanLesson").html(""); $("#liLesson").hide(); $.validator.removeValid("#frmVideoEdit [name=ParentLesson]", "VideoEdit"); } } $(function () { $("#frmVideoEdit [name=RecTime]").datepicker({ dateFormat: "yy-mm-dd", onClose: function () { $.validator.itemValid("#frmVideoEdit [name=RecTime]", "VideoEdit"); } }); }); </script> <script type="text/javascript"> //?????? $.validator.initConfig({ validatorGroup: "VideoEdit", form: "#frmVideoEdit", alertMessage: true, showMessage: false }); //?????? $("#frmVideoEdit [name=Name]").formValidator({ validatorGroup: "VideoEdit", rules: { required: null }, message: { required: "???????????" } }); //?????? $("#frmVideoEdit [name=FileName]").formValidator({ validatorGroup: "VideoEdit", rules: { required: null }, message: { required: "???????????" } }); ////?????? //$("#frmVideoEdit [name=Cover]").formValidator({ // validatorGroup: "VideoEdit", // rules: //{ // required: null //}, // message: //{ // required: "???????????" //} //}); //?????? $("#frmVideoEdit [name=FileSize]").formValidator({ validatorGroup: "VideoEdit", rules: { regex: "num1" }, message: { regex: "??????????????" } }); //??????? $("#frmVideoEdit [name=ParentCategory]").formValidator({ targetFocus: "#frmVideoEdit [name=ParentCategory_Name]", validatorGroup: "VideoEdit", rules: { required: null }, message: { required: "????????????" } }); //???????? $("#frmVideoEdit [name=Period]").formValidator({ validatorGroup: "VideoEdit", rules: { required: null, regex: "num1" }, message: { required: "?????????????????", regex: "??????????????" } }); //??? $("#frmVideoEdit [name=Copyright]").formValidator({ validatorGroup: "VideoEdit", rules: { min: 1 }, message: { min: "????????" } }); //?????? $("#frmVideoEdit [name=Share]").formValidator({ validatorGroup: "VideoEdit", rules: { min: 1 }, message: { min: "???????????" } }); //?????? //$("#frmVideoEdit [name=RecTime]").formValidator({ // validatorGroup: "VideoEdit", // rules: //{ // required: null, // regex: "datetime" //}, // message: //{ // required: "??????????????", // regex: "??????????????" //} //}); //????? //$("#frmVideoEdit [name=SortNumber]").formValidator({ // validatorGroup: "VideoEdit", // rules: //{ // required: null, // regex: "num1" //}, // message: //{ // required: "???????????", // regex: "???????????" //} //}); <% if (CreateInstance.ConfigDao.VideoCaptionsFileTag("") != null) { %> $("#frmVideoEdit [name=CaptionsFile]").formValidator({ validatorGroup: "VideoEdit", rules: { required: null }, message: { required: "???????????" } }); <% } %> <% if (CreateInstance.ConfigDao.VideoCoverTag("") != null) { %> $("#frmVideoEdit [name=Cover]").formValidator({ validatorGroup: "VideoEdit", rules: { required: null }, message: { required: "???????????" } }); <% } %> <% if (CreateInstance.ConfigDao.VideoPressTag("") != null) { %> $("#frmVideoEdit [name=ParentPress]").formValidator({ validatorGroup: "VideoEdit", rules: { required: null }, message: { required: "??????????" } }); <% } %> <% if (CreateInstance.ConfigDao.VideoGradeTag("") != null) { %> $("#frmVideoEdit [name=ParentGrade]").formValidator({ validatorGroup: "VideoEdit", rules: { required: null }, message: { required: "????????" } }); <% } %> <% if (CreateInstance.ConfigDao.VideoChannelTag("") != null) { %> $("#frmVideoEdit [name=Channel]").formValidator({ validatorGroup: "VideoEdit", rules: { min: 1 }, message: { min: "???????????" } }); <% } %> </script> <script type="text/javascript"> function VideoEditClient(send) { if (document.getElementById('progressNumberFileName').innerHTML.indexOf('??????') >= 0) // ???????????????????????????????????????????????????????? { alert('???????????????????????') return false; } $.ajax( { cache: false, type: "POST", url: Global.Site + "/Ajax.aspx?AVA.ResourcesPlatform.Ajax.ClientAjax.VideoEdit", data: Global.GetFormValue($("#frmVideoEdit")), async: true, dataType: 'json', success: function (result) { $(send).val("?????????"); flash("????????????") Global.Disabled(send, false); window.location.href = "<%= WebUrl.MyVideo() %>"; }, beforeSend: function () { $(send).val("??????..."); Global.Disabled(send, true); }, complete: function () { }, error: function (XMLHttpRequest, textStatus, errorThrown) { $(send).val("?????????"); Global.Disabled(send, false); var message = XMLHttpRequest.responseText; Global.Error(message); } }); } </script> </div>
Ms-Dos/Windows
Unix
Write backup
jsp File Browser version 1.2 by
www.vonloesch.de