Edit D:\AVA\AVAStandard\AVA.ResourcesPlatform.WebUI\Themes\NewtonTheme\Control\My\MyTag.ascx
??<%@ Control Language="C#" AutoEventWireup="true" CodeBehind="MyTag.ascx.cs" Inherits="AVA.ResourcesPlatform.WebUI.Control.My.MyTag" %> <div class="flat data-box" id="divEdit"> <div class="head"> <span class="title">??????</span><span class="f_r"> </span> </div> <hr /> <div class="dataControl body"> <form id="frmTagAdd" action="" method="post" onsubmit="return false;"> <table border="0" cellpadding="2px" cellspacing="2px" class="myTab"> <tr> <td style="text-align: right;"><span class="label"><span class="required">*</span>????????</span></td> <td> <%= new HtmlText("Name", null, 256) { }.AddAttribute("Placeholder","?????????")%> <%= new HtmlYKTip("Name")%> </td> </tr> <tr> <td style="text-align: right;"><span class="label">????????</span></td> <td> <label for="Tag_TagType_0"> <%= new HtmlRadio("TagType", 0, null) { ID = "Tag_TagType_0", Class = "", Checked = true }%><%= Define.Get("Tag_TagType_??????") %></label> <label for="Tag_TagType_1"> <%= new HtmlRadio("TagType", 1, null) { ID = "Tag_TagType_1", Class = "", }%><%= Define.Get("Tag_TagType_??????") %></label> </td> </tr> <tr> <td style="text-align: right;"><span class="label">????????</span></td> <td> <%= new HtmlCheckBox("IsRecommend",false, 1, 0) { Class = "" }%> </td> </tr> <tr> <td style="text-align: right;"><span class="label">????????</span></td> <td> <%= new HtmlSelect("ParentCategory","Name","Guid","Guid") { Option = this.ListCategory }.InsertOption("::???::", "", 0)%> </td> </tr> <tr> <td style="text-align: right;"></td> <td> <%= new HtmlHidden("Key",this.KEY)%> <%= new HtmlSubmit("??????", "TagAdd", "TagAddClient(this);").Style(new { Width = "100px" })%> <%--<input type="button" value="???" onclick="HideEdit();" style="width: 100px;" />--%> </td> </tr> </table> </form> </div> </div> <script type="text/javascript"> //?????? $.validator.initConfig({ validatorGroup: "TagAdd", form: "#frmTagAdd", alertMessage: true, showMessage: false }); //????????? $("#frmTagAdd [name=Name]").formValidator({ validatorGroup: "TagAdd", rules: { required: null }, message: { required: "???????????" } }); </script> <script type="text/javascript"> function TagAddClient(send) { $.ajax( { cache: false, type: "POST", url: Global.Site + "/Ajax.aspx?AVA.ResourcesPlatform.Ajax.ClientAjax.TagEditClient", data: Global.GetFormValue($("#frmTagAdd")), async: true, dataType: 'json', success: function (result) { $(send).val("??????"); alert("?????????"); Global.Disabled(send, false); window.location.href = result; }, 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 class="flat data-box"> <div class="head"> <span class="title">?????<%= this.Query.RecordCount %>?????</span> <span></span><span class="f_r"></span> </div> <div class="dataControl "> <form> <%--<%= new HtmlButton("???...", "","ShowEdit(this);")%>--%> <%= new HtmlButton("???", "TagBatchDelete(this);"){ Class="btn btn-danger pull-right" }%> </form> </div> <div id="MyTagData" class="data"> <table style="width: 100%" class="table"> <tr id="dataHead" class="dataHead"> <td> <input type="checkbox" class="trselall" /></td> <td> <table border="0" style="width: 100%;" class=" table-cleared"> <tr> <td class="span2">??????</td> <td class="span3">??????</td> <td class="span4">??????</td> <td class="span5">???????</td> <td style="width: 100px;">???</td> </tr> </table> </td> </tr> <% for (int i = 0; i <= this.ListTag.Count - 1; i++) { var tag = this.ListTag[i]; %> <tr> <td><%= new HtmlCheckBox() { Value = SetKey(tag.Guid, tag.Version), Class = "trsel", Title = DefineEnum.???_????.Define() }%></td> <td> <form id="frmTagEdit<%=tag.Guid %>" action="" method="post" onsubmit="return false;" class="inline-form"> <table border="0" style="width: 100%;" id="form_<%= tag.Guid %>" class=" table-cleared"> <tr> <td class="span2"> <div class="form-edit-before "><%= tag.Name %> </div> <div class="form-editing "> <%= new HtmlText("Name", tag.Name, 256) { Class = "span2" }.AddAttribute("Placeholder", "?????????").Style(new {Width="100px" })%> <%= new HtmlYKTip("Name")%> </div> </td> <td class="span3"> <div class="form-edit-before "> <%= (AVA.ResourcesPlatform.Model.Pub.TagTagTypeEnum)tag.TagType %> </div> <div class="form-editing "> <label for="Tag_TagType_0"> <%= new HtmlRadio("TagType", 0, null) { ID = "Tag_TagType_0", Class = "", Checked = tag.TagType == 0 ? true : false }%><%= Define.Get("Tag_TagType_??????") %><br /><br /> <%= new HtmlRadio("TagType", 1, null) { ID = "Tag_TagType_1", Class = "", Checked = tag.TagType == 1 ? true : false }%><%= Define.Get("Tag_TagType_??????") %></label> </div> </td> <td class="span4"> <div class="form-edit-before "> <%= (AVA.ResourcesPlatform.Model.Pub.TagIsRecommendEnum)tag.IsRecommend %> </div> <div class="form-editing "> <%= new HtmlCheckBox("IsRecommend",tag.IsRecommend, 1, 0) { }%> </div> </td> <td class="span5"> <div class="form-edit-before "> <%= tag.ParentCategory == null ? "??????" : tag.ParentCategory.Name %> </div> <div class="form-editing "> <%= new HtmlSelect("ParentCategory","Name","Guid","Guid") { Option = this.ListCategory, SelectedValue = tag.ParentCategory == null ? "" : tag.ParentCategory.Guid }.InsertOption("::???::", "", 0)%> </div> </td> <td style="width: 100px;"> <div class="form-editing"> <%= new HtmlHidden("Key",SetKey(tag.Guid, tag.Version))%> <div class="btn-group"> <%= new HtmlSubmit("??????", "TagEdit" + tag.Guid, "TagEditClient(this,'" + tag.Guid + "');") { Class="btn btn-warning"}%> <a class="btn form-cancel-btn" data-target="form_<%= tag.Guid %>">???</a> </div> </div> <div class="form-edit-before"> <a href="#edit" class="form-edit-btn" data-target="form_<%= tag.Guid %>">???</a> | <a href="#delete" onclick="TagDelete(this,'<%= SetKey(tag.Guid, tag.Version) %>'); return false;">???</a> </div> </td> </tr> </table> </form> </td> </tr> <% } %> </table> <script> $(function () { $(".form-editing").hide(); $(".form-edit-btn").on("click", function (e) { var $target = $("#" + $(e.target).attr("data-target")); $target.find(".form-editing").show(); $target.find(".form-edit-before").hide(); }); $(".form-cancel-btn").on("click", function (e) { var $target = $("#" + $(e.target).attr("data-target")); $target.find(".form-editing").hide(); $target.find(".form-edit-before").show(); }) }); </script> </div> <script type="text/javascript"> $("#MyTagData .trselall").click(function () { if (this.checked == true) { $("#MyTagData .trsel").attr("checked", "checked"); } else { $("#MyTagData .trsel").removeAttr("checked"); } }) function SelectMyTagAll() { var bool = $("#MyTagData .trselall").attr("checked"); bool = !bool; if (bool == true) { $("#MyTagData .trsel").attr("checked", "checked"); $("#MyTagData .trselall").attr("checked", "checked"); } else { $("#MyTagData .trsel").removeAttr("checked"); $("#MyTagData .trselall").removeAttr("checked"); } } </script> <script type="text/javascript"> ////?????? //$.validator.initConfig({ validatorGroup: "TagEdit", form: "#frmTagEdit", alertMessage: true, showMessage: false }); ////?????? //$("#frmTagEdit [name=Name]").formValidator({ // validatorGroup: "TagEdit", // rules: // { // required: null // }, // message: // { // required: "????????????" // } //}); function TagEditClient(send, guid) { //var params = Global.GetFormValue($("#frmTagEdit" + guid)); $.ajax( { cache: false, type: "POST", url: Global.Site + "/Ajax.aspx?AVA.ResourcesPlatform.Ajax.ClientAjax.TagEditClient", data: Global.GetFormValue($("#frmTagEdit" + guid)), async: true, dataType: 'json', success: function (result) { $(send).val("??????"); alert("????????????"); Global.Disabled(send, false); window.location.href = result; }, 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); } }); } //?????? function TagBatchDelete(send) { var items = $("#MyTagData .trsel:checked"); var key = ""; for (var i = 0; i <= items.length - 1; i++) { key += "pkid=" + encodeURIComponent(items[i].value); if (i != items.length - 1) { key += "&"; } } if (key != "") { if (confirm("????????????????????") == true) { $.ajax( { cache: false, type: "POST", url: Global.Site + "/Ajax.aspx?AVA.ResourcesPlatform.Ajax.ClientAjax.TagBatchDelete", data: key, async: true, dataType: 'json', success: function (result) { $(send).val("???"); flash("????????????") Global.Disabled(send, false); window.location.href = window.location.href; }, 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); } }); } } else { flash("??????????????????"); } }; //?????? function TagDelete(send, pkid) { if (confirm("??????????????????") == true) { $.ajax( { cache: false, type: "POST", url: Global.Site + "/Ajax.aspx?AVA.ResourcesPlatform.Ajax.ClientAjax.TagDelete", data: "key=" + pkid, async: true, dataType: 'json', success: function (result) { $(send).html("???"); flash("????????????") Global.Disabled(send, false); window.location.href = window.location.href; }, beforeSend: function () { $(send).html("?????"); Global.Disabled(send, true); }, complete: function () { }, error: function (XMLHttpRequest, textStatus, errorThrown) { $(send).html("???"); Global.Disabled(send, false); var message = XMLHttpRequest.responseText; Global.Error(message); } }); } }; </script> <div> <a onclick="SelectMyTagAll(); return false;" href="#">???? - ???</a> </div> <%= new PagerAjaxInstance(this) { RecordCount = this.Query.RecordCount, PageSize = this.Query.PageSize, PageIndex = this.Query.PageIndex, PageJsFn = WebUrl.MyTag(int.MaxValue, this.Name) }.ToHtml()%> </div>
Ms-Dos/Windows
Unix
Write backup
jsp File Browser version 1.2 by
www.vonloesch.de