From c04d98128fc48cdf871e80a59828687c889ac890 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=8F=99=E8=BF=B0=E3=80=81=E5=88=AB=E7=A6=BB?= <93301500+xushubieli@users.noreply.github.com> Date: Thu, 10 Nov 2022 18:08:19 +0800 Subject: [PATCH] =?UTF-8?q?=E7=A7=BB=E9=99=A4=E4=B8=8D=E5=BF=85=E8=A6=81?= =?UTF-8?q?=E7=9A=84=E8=B5=84=E6=BA=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/admin/js/diy.js | 5 - src/admin/js/global.js | 2 +- src/admin/js/ieemu.js | 240 ------------------- src/admin/js/indexbody.js | 39 +-- src/admin/js/list.js | 11 +- src/admin/js/user.js | 5 - src/admin/templets/catalog_main.htm | 9 +- src/admin/templets/content_i_list.htm | 9 +- src/admin/templets/content_list.htm | 1 - src/admin/templets/content_s_list.htm | 79 +----- src/admin/templets/content_sg_list.htm | 108 +-------- src/admin/templets/diy_add.htm | 13 - src/admin/templets/diy_edit.htm | 18 -- src/admin/templets/diy_main.htm | 6 +- src/admin/templets/makehtml_taglist.htm | 2 +- src/admin/templets/member_main.htm | 7 +- src/static/web/js/select2.full.min.js | 2 - src/system/typelink/typeunit.class.admin.php | 12 +- 18 files changed, 25 insertions(+), 543 deletions(-) delete mode 100644 src/admin/js/diy.js delete mode 100644 src/admin/js/ieemu.js delete mode 100644 src/static/web/js/select2.full.min.js diff --git a/src/admin/js/diy.js b/src/admin/js/diy.js deleted file mode 100644 index ee3ea105..00000000 --- a/src/admin/js/diy.js +++ /dev/null @@ -1,5 +0,0 @@ -function showHide2(objname) { - var obj = $Obj(objname); - if (obj.style.display != 'block') { obj.style.display = 'block' } - else { obj.style.display = 'none'; } -} \ No newline at end of file diff --git a/src/admin/js/global.js b/src/admin/js/global.js index 1a150446..82fdd240 100644 --- a/src/admin/js/global.js +++ b/src/admin/js/global.js @@ -14,7 +14,7 @@ function browserVersion(types) { var matches = re.exec(USERAGENT); var ver = matches != null ? matches[2] : 0; other = ver !== 0 ? 0 : other; - }else { + } else { var ver = 0; } eval('BROWSER.' + i + '= ver'); diff --git a/src/admin/js/ieemu.js b/src/admin/js/ieemu.js deleted file mode 100644 index 3a177771..00000000 --- a/src/admin/js/ieemu.js +++ /dev/null @@ -1,240 +0,0 @@ -var ie = document.all != null; -var moz = !ie && document.getElementById != null && document.layers == null; -/* - * Extends the event object with srcElement, cancelBubble, returnValue, - * fromElement and toElement - */ -function extendEventObject() { - Event.prototype.__defineSetter__("returnValue", function (b) { - if (!b) this.preventDefault(); - }); - Event.prototype.__defineSetter__("cancelBubble", function (b) { - if (b) this.stopPropagation(); - }); - Event.prototype.__defineGetter__("srcElement", function () { - var node = this.target; - while (node.nodeType != 1) node = node.parentNode; - return node; - }); - Event.prototype.__defineGetter__("fromElement", function () { - var node; - if (this.type == "mouseover") - node = this.relatedTarget; - else if (this.type == "mouseout") - node = this.target; - if (!node) return; - while (node.nodeType != 1) node = node.parentNode; - return node; - }); - Event.prototype.__defineGetter__("toElement", function () { - var node; - if (this.type == "mouseout") - node = this.relatedTarget; - else if (this.type == "mouseover") - node = this.target; - if (!node) return; - while (node.nodeType != 1) node = node.parentNode; - return node; - }); - Event.prototype.__defineGetter__("offsetX", function () { - return this.layerX; - }); - Event.prototype.__defineGetter__("offsetY", function () { - return this.layerY; - }); -} -/* - * Emulates element.attachEvent as well as detachEvent - */ -function emulateAttachEvent() { - HTMLDocument.prototype.attachEvent = - HTMLElement.prototype.attachEvent = function (sType, fHandler) { - var shortTypeName = sType.replace(/on/, ""); - fHandler._ieEmuEventHandler = function (e) { - window.event = e; - return fHandler(); - }; - this.addEventListener(shortTypeName, fHandler._ieEmuEventHandler, false); - }; - HTMLDocument.prototype.detachEvent = - HTMLElement.prototype.detachEvent = function (sType, fHandler) { - var shortTypeName = sType.replace(/on/, ""); - if (typeof fHandler._ieEmuEventHandler == "function") - this.removeEventListener(shortTypeName, fHandler._ieEmuEventHandler, false); - else - this.removeEventListener(shortTypeName, fHandler, true); - }; -} -/* - * This function binds the event object passed along in an - * event to window.event - */ -function emulateEventHandlers(eventNames) { - for (var i = 0; i < eventNames.length; i++) { - document.addEventListener(eventNames[i], function (e) { - window.event = e; - }, true); // using capture - } -} -/* - * Simple emulation of document.all - * this one is far from complete. Be cautious - */ -function emulateAllModel() { - var allGetter = function () { - var a = this.getElementsByTagName("*"); - var node = this; - a.tags = function (sTagName) { - return node.getElementsByTagName(sTagName); - }; - return a; - }; - HTMLDocument.prototype.__defineGetter__("all", allGetter); - HTMLElement.prototype.__defineGetter__("all", allGetter); -} -function extendElementModel() { - HTMLElement.prototype.__defineGetter__("parentElement", function () { - if (this.parentNode == this.ownerDocument) return null; - return this.parentNode; - }); - HTMLElement.prototype.__defineGetter__("children", function () { - var tmp = []; - var j = 0; - var n; - for (var i = 0; i < this.childNodes.length; i++) { - n = this.childNodes[i]; - if (n.nodeType == 1) { - tmp[j++] = n; - if (n.name) { // named children - if (!tmp[n.name]) - tmp[n.name] = []; - tmp[n.name][tmp[n.name].length] = n; - } - if (n.id) // child with id - tmp[n.id] = n - } - } - return tmp; - }); - HTMLElement.prototype.contains = function (oEl) { - if (oEl == this) return true; - if (oEl == null) return false; - return this.contains(oEl.parentNode); - }; -} -/* -document.defaultView.getComputedStyle(el1,
null).getPropertyValue('top'); -*/ -function emulateCurrentStyle(properties) { - HTMLElement.prototype.__defineGetter__("currentStyle", function () { - var cs = {}; - var el = this; - for (var i = 0; i < properties.length; i++) { - cs.__defineGetter__(properties[i], encapsulateObjects(el, properties[i])); - } - return cs; - }); -} -// used internally for emualteCurrentStyle -function encapsulateObjects(el, sProperty) { - return function () { - return document.defaultView.getComputedStyle(el, null).getPropertyValue(sProperty); - }; -} -function emulateHTMLModel() { - // This function is used to generate a html string for the text properties/methods - // It replaces '\n' with " as well as fixes consecutive white spaces - // It also repalaces some special characters - function convertTextToHTML(s) { - s = s.replace(/\&/g, "&").replace(//g, ">").replace(/\n/g, "
"); - while (/\s\s/.test(s)) - s = s.replace(/\s\s/, "  "); - return s.replace(/\s/g, " "); - } - HTMLElement.prototype.insertAdjacentHTML = function (sWhere, sHTML) { - var df; // : DocumentFragment - var r = this.ownerDocument.createRange(); - switch (String(sWhere).toLowerCase()) { - case "beforebegin": - r.setStartBefore(this); - df = r.createContextualFragment(sHTML); - this.parentNode.insertBefore(df, this); - break; - case "afterbegin": - r.selectNodeContents(this); - r.collapse(true); - df = r.createContextualFragment(sHTML); - this.insertBefore(df, this.firstChild); - break; - case "beforeend": - r.selectNodeContents(this); - r.collapse(false); - df = r.createContextualFragment(sHTML); - this.appendChild(df); - break; - case "afterend": - r.setStartAfter(this); - df = r.createContextualFragment(sHTML); - this.parentNode.insertBefore(df, this.nextSibling); - break; - } - }; - HTMLElement.prototype.__defineSetter__("outerHTML", function (sHTML) { - var r = this.ownerDocument.createRange(); - r.setStartBefore(this); - var df = r.createContextualFragment(sHTML); - this.parentNode.replaceChild(df, this); - - return sHTML; - }); - HTMLElement.prototype.__defineGetter__("canHaveChildren", function () { - switch (this.tagName) { - case "AREA": - case "BASE": - case "BASEFONT": - case "COL": - case "FRAME": - case "HR": - case "IMG": - case "BR": - case "INPUT": - case "ISINDEX": - case "LINK": - case "META": - case "PARAM": - return false; - } - return true; - }); - HTMLElement.prototype.__defineGetter__("outerHTML", function () { - var attr, attrs = this.attributes; - var str = "<" + this.tagName; - for (var i = 0; i < attrs.length; i++) { - attr = attrs[i]; - if (attr.specified) - str += " " + attr.name + '="' + attr.value + '"'; - } - if (!this.canHaveChildren) - return str + ">"; - - return str + ">" + this.innerHTML + ""; - }); - HTMLElement.prototype.__defineSetter__("innerText", function (sText) { - this.innerHTML = convertTextToHTML(sText); - return sText; - }); - var tmpGet; - HTMLElement.prototype.__defineGetter__("innerText", tmpGet = function () { - var r = this.ownerDocument.createRange(); - r.selectNodeContents(this); - return r.toString(); - }); - HTMLElement.prototype.__defineSetter__("outerText", function (sText) { - this.outerHTML = convertTextToHTML(sText); - return sText; - }); - HTMLElement.prototype.__defineGetter__("outerText", tmpGet); - HTMLElement.prototype.insertAdjacentText = function (sWhere, sText) { - this.insertAdjacentHTML(sWhere, convertTextToHTML(sText)); - }; -} \ No newline at end of file diff --git a/src/admin/js/indexbody.js b/src/admin/js/indexbody.js index a5a9f0f4..ddc47881 100644 --- a/src/admin/js/indexbody.js +++ b/src/admin/js/indexbody.js @@ -20,7 +20,7 @@ function DedeCopyToClipboard(text) { } else { var textarea = document.createElement('textarea'); document.body.appendChild(textarea); - // 隐藏此输入框 + //隐藏此输入框 textarea.style.position = 'fixed'; textarea.style.clip = 'rect(0 0 0 0)'; textarea.style.top = '10px'; @@ -83,18 +83,6 @@ function LoadServer() { 授权版本: ${rsp.result.auth_version}.x.x(时间:${rsp.result.auth_at}) - `; - } - - /*多余代码*/ - if (typeof rsp.result.title !== "undefined") { - infoStr += ` - `; - } - /*多余代码*/ - - if (typeof rsp.result.auth_version !== "undefined" && typeof rsp.result.auth_at !== "undefined") { - infoStr += ` 站点名称: ${rsp.result.title}(${rsp.result.stype}) @@ -106,21 +94,6 @@ function LoadServer() { `; } - - /*多余代码*/ - if (rsp.result.core === null || rsp.result.core.code != 200) { - //下面是DedeBIZ Core组件信息 - infoStr += ` - - `; - } else { - dedebizInfo = JSON.parse(rsp.result.core.data); - infoStr += ` - `; - } - /*多余代码*/ - - infoStr += ""; $("#system-info").html(infoStr); } else { @@ -134,16 +107,11 @@ function LoadServer() { -
您的后台已是最新软件版本
- - - - @@ -161,10 +129,6 @@ function LoadServer() {
本更新提供了重要的安全性更新,建议所有用户升级,软件更新将覆盖以下文件,请做好备份。下一步/system/database/dedesqlite.class.php
- - - - @@ -176,7 +140,6 @@ function LoadServer() {
更新诊断出数据结构有问题,可能无法正常使用后台,是否尝试修复数据?
- `); } }); diff --git a/src/admin/js/list.js b/src/admin/js/list.js index f162e489..8274a359 100644 --- a/src/admin/js/list.js +++ b/src/admin/js/list.js @@ -1,8 +1,3 @@ -if (moz) { - extendEventObject(); - extendElementModel(); - emulateAttachEvent(); -} function viewArc(aid){ if (aid==0) aid = getOneItem(); window.open("archives_do.php?aid="+aid+"&dopost=viewArchives"); @@ -12,7 +7,7 @@ function kwArc(aid){ if (aid==0) aid = getOneItem(); if (qstr=='') { - ShowMsg('必须选择一个或多个文档'); + ShowMsg('需要选择一个或多个文档'); return; } location="archives_do.php?aid="+aid+"&dopost=makekw&qstr="+qstr; @@ -35,7 +30,7 @@ function moveArc(e, obj, cid){ var qstr=getCheckboxItem(); if (qstr=='') { - ShowMsg('必须选择一个或多个文档'); + ShowMsg('需要选择一个或多个文档'); return; } LoadQuickDiv(e, 'archives_do.php?dopost=moveArchives&qstr='+qstr+'&channelid='+cid+'&rnd='+Math.random(), 'moveArchives', '480px', '180px'); @@ -52,7 +47,7 @@ function cAtts(jname, e, obj) var screeheight = document.body.clientHeight + 20; if (qstr=='') { - ShowMsg('必须选择一个或多个文档'); + ShowMsg('需要选择一个或多个文档'); return; } LoadQuickDiv(e, 'archives_do.php?dopost=attsDlg&qstr='+qstr+'&dojob='+jname+'&rnd='+Math.random(), 'attsDlg', '480px', '180px'); diff --git a/src/admin/js/user.js b/src/admin/js/user.js index 909cb046..cedd1c97 100644 --- a/src/admin/js/user.js +++ b/src/admin/js/user.js @@ -3,11 +3,6 @@ if (moz == null) var ie = document.all != null; var moz = !ie && document.getElementById != null && document.layers == null; } -if (moz) { - extendEventObject(); - extendElementModel(); - emulateAttachEvent(); -} function delArc(mid){ var qstr=getCheckboxItem(); if (mid==0) mid = getOneItem(); diff --git a/src/admin/templets/catalog_main.htm b/src/admin/templets/catalog_main.htm index 1f1c1481..df5f3bb3 100644 --- a/src/admin/templets/catalog_main.htm +++ b/src/admin/templets/catalog_main.htm @@ -7,10 +7,8 @@ - - - + diff --git a/src/admin/templets/content_i_list.htm b/src/admin/templets/content_i_list.htm index 1f611026..4f90dd43 100644 --- a/src/admin/templets/content_i_list.htm +++ b/src/admin/templets/content_i_list.htm @@ -9,9 +9,8 @@ - - + @@ -59,10 +58,11 @@ - + + @@ -78,6 +78,7 @@
{dede:global.positionname/}文档列表{dede:global.positionname/}文档列表
选择id 文档属性 时间 类目
+
{dede:field.id/} {dede:field.title/}{dede:field.flag function='IsCommendArchives(@me)'/} @@ -101,8 +102,6 @@ 全选 取消 - 查看 - 修改 更新 审核 推荐 diff --git a/src/admin/templets/content_list.htm b/src/admin/templets/content_list.htm index 2e68b507..6eab62b1 100644 --- a/src/admin/templets/content_list.htm +++ b/src/admin/templets/content_list.htm @@ -10,7 +10,6 @@ - diff --git a/src/admin/templets/content_s_list.htm b/src/admin/templets/content_s_list.htm index d36e2bdc..cd855884 100644 --- a/src/admin/templets/content_s_list.htm +++ b/src/admin/templets/content_s_list.htm @@ -7,82 +7,7 @@ - - + @@ -143,8 +68,6 @@
全选 取消 - 查看 - 修改 更新 审核 推荐 diff --git a/src/admin/templets/content_sg_list.htm b/src/admin/templets/content_sg_list.htm index bd9b4ad3..344a2266 100644 --- a/src/admin/templets/content_sg_list.htm +++ b/src/admin/templets/content_sg_list.htm @@ -10,114 +10,8 @@ - - + diff --git a/src/admin/templets/diy_add.htm b/src/admin/templets/diy_add.htm index 9f010626..45e4c6a1 100644 --- a/src/admin/templets/diy_add.htm +++ b/src/admin/templets/diy_add.htm @@ -7,19 +7,6 @@ - - - - -
diff --git a/src/admin/templets/diy_edit.htm b/src/admin/templets/diy_edit.htm index 23738b8f..30c83f00 100644 --- a/src/admin/templets/diy_edit.htm +++ b/src/admin/templets/diy_edit.htm @@ -7,24 +7,6 @@ - - - - -
diff --git a/src/admin/templets/diy_main.htm b/src/admin/templets/diy_main.htm index c7ea4537..6c29fdd8 100644 --- a/src/admin/templets/diy_main.htm +++ b/src/admin/templets/diy_main.htm @@ -15,9 +15,9 @@ - - - + + + {dede:datalist empty=''} diff --git a/src/admin/templets/makehtml_taglist.htm b/src/admin/templets/makehtml_taglist.htm index effb2746..b0de0dec 100644 --- a/src/admin/templets/makehtml_taglist.htm +++ b/src/admin/templets/makehtml_taglist.htm @@ -9,7 +9,7 @@ - + @@ -102,9 +101,9 @@ {/dede:datalist} diff --git a/src/static/web/js/select2.full.min.js b/src/static/web/js/select2.full.min.js deleted file mode 100644 index bf4755d8..00000000 --- a/src/static/web/js/select2.full.min.js +++ /dev/null @@ -1,2 +0,0 @@ -/*! Select2 4.0.13 | https://github.com/select2/select2/blob/master/LICENSE.md */ -!function(n){"function"==typeof define&&define.amd?define(["jquery"],n):"object"==typeof module&&module.exports?module.exports=function(e,t){return void 0===t&&(t="undefined"!=typeof window?require("jquery"):require("jquery")(e)),n(t),t}:n(jQuery)}(function(d){var e=function(){if(d&&d.fn&&d.fn.select2&&d.fn.select2.amd)var e=d.fn.select2.amd;var t,n,i,h,o,s,f,g,m,v,y,_,r,a,w,l;function b(e,t){return r.call(e,t)}function c(e,t){var n,i,r,o,s,a,l,c,u,d,p,h=t&&t.split("/"),f=y.map,g=f&&f["*"]||{};if(e){for(s=(e=e.split("/")).length-1,y.nodeIdCompat&&w.test(e[s])&&(e[s]=e[s].replace(w,"")),"."===e[0].charAt(0)&&h&&(e=h.slice(0,h.length-1).concat(e)),u=0;u":">",'"':""","'":"'","/":"/"};return"string"!=typeof e?e:String(e).replace(/[&<>"'\/\\]/g,function(e){return t[e]})},r.appendMany=function(e,t){if("1.7"===o.fn.jquery.substr(0,3)){var n=o();o.map(t,function(e){n=n.add(e)}),t=n}e.append(t)},r.__cache={};var n=0;return r.GetUniqueElementId=function(e){var t=e.getAttribute("data-select2-id");return null==t&&(e.id?(t=e.id,e.setAttribute("data-select2-id",t)):(e.setAttribute("data-select2-id",++n),t=n.toString())),t},r.StoreData=function(e,t,n){var i=r.GetUniqueElementId(e);r.__cache[i]||(r.__cache[i]={}),r.__cache[i][t]=n},r.GetData=function(e,t){var n=r.GetUniqueElementId(e);return t?r.__cache[n]&&null!=r.__cache[n][t]?r.__cache[n][t]:o(e).data(t):r.__cache[n]},r.RemoveData=function(e){var t=r.GetUniqueElementId(e);null!=r.__cache[t]&&delete r.__cache[t],e.removeAttribute("data-select2-id")},r}),e.define("select2/results",["jquery","./utils"],function(h,f){function i(e,t,n){this.$element=e,this.data=n,this.options=t,i.__super__.constructor.call(this)}return f.Extend(i,f.Observable),i.prototype.render=function(){var e=h('
    ');return this.options.get("multiple")&&e.attr("aria-multiselectable","true"),this.$results=e},i.prototype.clear=function(){this.$results.empty()},i.prototype.displayMessage=function(e){var t=this.options.get("escapeMarkup");this.clear(),this.hideLoading();var n=h(''),i=this.options.get("translations").get(e.message);n.append(t(i(e.args))),n[0].className+=" select2-results__message",this.$results.append(n)},i.prototype.hideMessages=function(){this.$results.find(".select2-results__message").remove()},i.prototype.append=function(e){this.hideLoading();var t=[];if(null!=e.results&&0!==e.results.length){e.results=this.sort(e.results);for(var n=0;n",{class:"select2-results__options select2-results__options--nested"});p.append(l),s.append(a),s.append(p)}else this.template(e,t);return f.StoreData(t,"data",e),t},i.prototype.bind=function(t,e){var l=this,n=t.id+"-results";this.$results.attr("id",n),t.on("results:all",function(e){l.clear(),l.append(e.data),t.isOpen()&&(l.setClasses(),l.highlightFirstItem())}),t.on("results:append",function(e){l.append(e.data),t.isOpen()&&l.setClasses()}),t.on("query",function(e){l.hideMessages(),l.showLoading(e)}),t.on("select",function(){t.isOpen()&&(l.setClasses(),l.options.get("scrollAfterSelect")&&l.highlightFirstItem())}),t.on("unselect",function(){t.isOpen()&&(l.setClasses(),l.options.get("scrollAfterSelect")&&l.highlightFirstItem())}),t.on("open",function(){l.$results.attr("aria-expanded","true"),l.$results.attr("aria-hidden","false"),l.setClasses(),l.ensureHighlightVisible()}),t.on("close",function(){l.$results.attr("aria-expanded","false"),l.$results.attr("aria-hidden","true"),l.$results.removeAttr("aria-activedescendant")}),t.on("results:toggle",function(){var e=l.getHighlightedResults();0!==e.length&&e.trigger("mouseup")}),t.on("results:select",function(){var e=l.getHighlightedResults();if(0!==e.length){var t=f.GetData(e[0],"data");"true"==e.attr("aria-selected")?l.trigger("close",{}):l.trigger("select",{data:t})}}),t.on("results:previous",function(){var e=l.getHighlightedResults(),t=l.$results.find("[aria-selected]"),n=t.index(e);if(!(n<=0)){var i=n-1;0===e.length&&(i=0);var r=t.eq(i);r.trigger("mouseenter");var o=l.$results.offset().top,s=r.offset().top,a=l.$results.scrollTop()+(s-o);0===i?l.$results.scrollTop(0):s-o<0&&l.$results.scrollTop(a)}}),t.on("results:next",function(){var e=l.getHighlightedResults(),t=l.$results.find("[aria-selected]"),n=t.index(e)+1;if(!(n>=t.length)){var i=t.eq(n);i.trigger("mouseenter");var r=l.$results.offset().top+l.$results.outerHeight(!1),o=i.offset().top+i.outerHeight(!1),s=l.$results.scrollTop()+o-r;0===n?l.$results.scrollTop(0):rthis.$results.outerHeight()||o<0)&&this.$results.scrollTop(r)}},i.prototype.template=function(e,t){var n=this.options.get("templateResult"),i=this.options.get("escapeMarkup"),r=n(e,t);null==r?t.style.display="none":"string"==typeof r?t.innerHTML=i(r):h(t).append(r)},i}),e.define("select2/keys",[],function(){return{BACKSPACE:8,TAB:9,ENTER:13,SHIFT:16,CTRL:17,ALT:18,ESC:27,SPACE:32,PAGE_UP:33,PAGE_DOWN:34,END:35,HOME:36,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46}}),e.define("select2/selection/base",["jquery","../utils","../keys"],function(n,i,r){function o(e,t){this.$element=e,this.options=t,o.__super__.constructor.call(this)}return i.Extend(o,i.Observable),o.prototype.render=function(){var e=n('');return this._tabindex=0,null!=i.GetData(this.$element[0],"old-tabindex")?this._tabindex=i.GetData(this.$element[0],"old-tabindex"):null!=this.$element.attr("tabindex")&&(this._tabindex=this.$element.attr("tabindex")),e.attr("title",this.$element.attr("title")),e.attr("tabindex",this._tabindex),e.attr("aria-disabled","false"),this.$selection=e},o.prototype.bind=function(e,t){var n=this,i=e.id+"-results";this.container=e,this.$selection.on("focus",function(e){n.trigger("focus",e)}),this.$selection.on("blur",function(e){n._handleBlur(e)}),this.$selection.on("keydown",function(e){n.trigger("keypress",e),e.which===r.SPACE&&e.preventDefault()}),e.on("results:focus",function(e){n.$selection.attr("aria-activedescendant",e.data._resultId)}),e.on("selection:update",function(e){n.update(e.data)}),e.on("open",function(){n.$selection.attr("aria-expanded","true"),n.$selection.attr("aria-owns",i),n._attachCloseHandler(e)}),e.on("close",function(){n.$selection.attr("aria-expanded","false"),n.$selection.removeAttr("aria-activedescendant"),n.$selection.removeAttr("aria-owns"),n.$selection.trigger("focus"),n._detachCloseHandler(e)}),e.on("enable",function(){n.$selection.attr("tabindex",n._tabindex),n.$selection.attr("aria-disabled","false")}),e.on("disable",function(){n.$selection.attr("tabindex","-1"),n.$selection.attr("aria-disabled","true")})},o.prototype._handleBlur=function(e){var t=this;window.setTimeout(function(){document.activeElement==t.$selection[0]||n.contains(t.$selection[0],document.activeElement)||t.trigger("blur",e)},1)},o.prototype._attachCloseHandler=function(e){n(document.body).on("mousedown.select2."+e.id,function(e){var t=n(e.target).closest(".select2");n(".select2.select2-container--open").each(function(){this!=t[0]&&i.GetData(this,"element").select2("close")})})},o.prototype._detachCloseHandler=function(e){n(document.body).off("mousedown.select2."+e.id)},o.prototype.position=function(e,t){t.find(".selection").append(e)},o.prototype.destroy=function(){this._detachCloseHandler(this.container)},o.prototype.update=function(e){throw new Error("The `update` method must be defined in child classes.")},o.prototype.isEnabled=function(){return!this.isDisabled()},o.prototype.isDisabled=function(){return this.options.get("disabled")},o}),e.define("select2/selection/single",["jquery","./base","../utils","../keys"],function(e,t,n,i){function r(){r.__super__.constructor.apply(this,arguments)}return n.Extend(r,t),r.prototype.render=function(){var e=r.__super__.render.call(this);return e.addClass("select2-selection--single"),e.html(''),e},r.prototype.bind=function(t,e){var n=this;r.__super__.bind.apply(this,arguments);var i=t.id+"-container";this.$selection.find(".select2-selection__rendered").attr("id",i).attr("role","textbox").attr("aria-readonly","true"),this.$selection.attr("aria-labelledby",i),this.$selection.on("mousedown",function(e){1===e.which&&n.trigger("toggle",{originalEvent:e})}),this.$selection.on("focus",function(e){}),this.$selection.on("blur",function(e){}),t.on("focus",function(e){t.isOpen()||n.$selection.trigger("focus")})},r.prototype.clear=function(){var e=this.$selection.find(".select2-selection__rendered");e.empty(),e.removeAttr("title")},r.prototype.display=function(e,t){var n=this.options.get("templateSelection");return this.options.get("escapeMarkup")(n(e,t))},r.prototype.selectionContainer=function(){return e("")},r.prototype.update=function(e){if(0!==e.length){var t=e[0],n=this.$selection.find(".select2-selection__rendered"),i=this.display(t,n);n.empty().append(i);var r=t.title||t.text;r?n.attr("title",r):n.removeAttr("title")}else this.clear()},r}),e.define("select2/selection/multiple",["jquery","./base","../utils"],function(r,e,l){function n(e,t){n.__super__.constructor.apply(this,arguments)}return l.Extend(n,e),n.prototype.render=function(){var e=n.__super__.render.call(this);return e.addClass("select2-selection--multiple"),e.html('
      '),e},n.prototype.bind=function(e,t){var i=this;n.__super__.bind.apply(this,arguments),this.$selection.on("click",function(e){i.trigger("toggle",{originalEvent:e})}),this.$selection.on("click",".select2-selection__choice__remove",function(e){if(!i.isDisabled()){var t=r(this).parent(),n=l.GetData(t[0],"data");i.trigger("unselect",{originalEvent:e,data:n})}})},n.prototype.clear=function(){var e=this.$selection.find(".select2-selection__rendered");e.empty(),e.removeAttr("title")},n.prototype.display=function(e,t){var n=this.options.get("templateSelection");return this.options.get("escapeMarkup")(n(e,t))},n.prototype.selectionContainer=function(){return r('
    • ×
    • ')},n.prototype.update=function(e){if(this.clear(),0!==e.length){for(var t=[],n=0;n×');a.StoreData(i[0],"data",t),this.$selection.find(".select2-selection__rendered").prepend(i)}},e}),e.define("select2/selection/search",["jquery","../utils","../keys"],function(i,a,l){function e(e,t,n){e.call(this,t,n)}return e.prototype.render=function(e){var t=i('');this.$searchContainer=t,this.$search=t.find("input");var n=e.call(this);return this._transferTabIndex(),n},e.prototype.bind=function(e,t,n){var i=this,r=t.id+"-results";e.call(this,t,n),t.on("open",function(){i.$search.attr("aria-controls",r),i.$search.trigger("focus")}),t.on("close",function(){i.$search.val(""),i.$search.removeAttr("aria-controls"),i.$search.removeAttr("aria-activedescendant"),i.$search.trigger("focus")}),t.on("enable",function(){i.$search.prop("disabled",!1),i._transferTabIndex()}),t.on("disable",function(){i.$search.prop("disabled",!0)}),t.on("focus",function(e){i.$search.trigger("focus")}),t.on("results:focus",function(e){e.data._resultId?i.$search.attr("aria-activedescendant",e.data._resultId):i.$search.removeAttr("aria-activedescendant")}),this.$selection.on("focusin",".select2-search--inline",function(e){i.trigger("focus",e)}),this.$selection.on("focusout",".select2-search--inline",function(e){i._handleBlur(e)}),this.$selection.on("keydown",".select2-search--inline",function(e){if(e.stopPropagation(),i.trigger("keypress",e),i._keyUpPrevented=e.isDefaultPrevented(),e.which===l.BACKSPACE&&""===i.$search.val()){var t=i.$searchContainer.prev(".select2-selection__choice");if(0this.maximumInputLength?this.trigger("results:message",{message:"inputTooLong",args:{maximum:this.maximumInputLength,input:t.term,params:t}}):e.call(this,t,n)},e}),e.define("select2/data/maximumSelectionLength",[],function(){function e(e,t,n){this.maximumSelectionLength=n.get("maximumSelectionLength"),e.call(this,t,n)}return e.prototype.bind=function(e,t,n){var i=this;e.call(this,t,n),t.on("select",function(){i._checkIfMaximumSelected()})},e.prototype.query=function(e,t,n){var i=this;this._checkIfMaximumSelected(function(){e.call(i,t,n)})},e.prototype._checkIfMaximumSelected=function(e,n){var i=this;this.current(function(e){var t=null!=e?e.length:0;0=i.maximumSelectionLength?i.trigger("results:message",{message:"maximumSelected",args:{maximum:i.maximumSelectionLength}}):n&&n()})},e}),e.define("select2/dropdown",["jquery","./utils"],function(t,e){function n(e,t){this.$element=e,this.options=t,n.__super__.constructor.call(this)}return e.Extend(n,e.Observable),n.prototype.render=function(){var e=t('');return e.attr("dir",this.options.get("dir")),this.$dropdown=e},n.prototype.bind=function(){},n.prototype.position=function(e,t){},n.prototype.destroy=function(){this.$dropdown.remove()},n}),e.define("select2/dropdown/search",["jquery","../utils"],function(o,e){function t(){}return t.prototype.render=function(e){var t=e.call(this),n=o('');return this.$searchContainer=n,this.$search=n.find("input"),t.prepend(n),t},t.prototype.bind=function(e,t,n){var i=this,r=t.id+"-results";e.call(this,t,n),this.$search.on("keydown",function(e){i.trigger("keypress",e),i._keyUpPrevented=e.isDefaultPrevented()}),this.$search.on("input",function(e){o(this).off("keyup")}),this.$search.on("keyup input",function(e){i.handleSearch(e)}),t.on("open",function(){i.$search.attr("tabindex",0),i.$search.attr("aria-controls",r),i.$search.trigger("focus"),window.setTimeout(function(){i.$search.trigger("focus")},0)}),t.on("close",function(){i.$search.attr("tabindex",-1),i.$search.removeAttr("aria-controls"),i.$search.removeAttr("aria-activedescendant"),i.$search.val(""),i.$search.trigger("blur")}),t.on("focus",function(){t.isOpen()||i.$search.trigger("focus")}),t.on("results:all",function(e){null!=e.query.term&&""!==e.query.term||(i.showSearch(e)?i.$searchContainer.removeClass("select2-search--hide"):i.$searchContainer.addClass("select2-search--hide"))}),t.on("results:focus",function(e){e.data._resultId?i.$search.attr("aria-activedescendant",e.data._resultId):i.$search.removeAttr("aria-activedescendant")})},t.prototype.handleSearch=function(e){if(!this._keyUpPrevented){var t=this.$search.val();this.trigger("query",{term:t})}this._keyUpPrevented=!1},t.prototype.showSearch=function(e,t){return!0},t}),e.define("select2/dropdown/hidePlaceholder",[],function(){function e(e,t,n,i){this.placeholder=this.normalizePlaceholder(n.get("placeholder")),e.call(this,t,n,i)}return e.prototype.append=function(e,t){t.results=this.removePlaceholder(t.results),e.call(this,t)},e.prototype.normalizePlaceholder=function(e,t){return"string"==typeof t&&(t={id:"",text:t}),t},e.prototype.removePlaceholder=function(e,t){for(var n=t.slice(0),i=t.length-1;0<=i;i--){var r=t[i];this.placeholder.id===r.id&&n.splice(i,1)}return n},e}),e.define("select2/dropdown/infiniteScroll",["jquery"],function(n){function e(e,t,n,i){this.lastParams={},e.call(this,t,n,i),this.$loadingMore=this.createLoadingMore(),this.loading=!1}return e.prototype.append=function(e,t){this.$loadingMore.remove(),this.loading=!1,e.call(this,t),this.showLoadingMore(t)&&(this.$results.append(this.$loadingMore),this.loadMoreIfNeeded())},e.prototype.bind=function(e,t,n){var i=this;e.call(this,t,n),t.on("query",function(e){i.lastParams=e,i.loading=!0}),t.on("query:append",function(e){i.lastParams=e,i.loading=!0}),this.$results.on("scroll",this.loadMoreIfNeeded.bind(this))},e.prototype.loadMoreIfNeeded=function(){var e=n.contains(document.documentElement,this.$loadingMore[0]);if(!this.loading&&e){var t=this.$results.offset().top+this.$results.outerHeight(!1);this.$loadingMore.offset().top+this.$loadingMore.outerHeight(!1)<=t+50&&this.loadMore()}},e.prototype.loadMore=function(){this.loading=!0;var e=n.extend({},{page:1},this.lastParams);e.page++,this.trigger("query:append",e)},e.prototype.showLoadingMore=function(e,t){return t.pagination&&t.pagination.more},e.prototype.createLoadingMore=function(){var e=n('
    • '),t=this.options.get("translations").get("loadingMore");return e.html(t(this.lastParams)),e},e}),e.define("select2/dropdown/attachBody",["jquery","../utils"],function(f,a){function e(e,t,n){this.$dropdownParent=f(n.get("dropdownParent")||document.body),e.call(this,t,n)}return e.prototype.bind=function(e,t,n){var i=this;e.call(this,t,n),t.on("open",function(){i._showDropdown(),i._attachPositioningHandler(t),i._bindContainerResultHandlers(t)}),t.on("close",function(){i._hideDropdown(),i._detachPositioningHandler(t)}),this.$dropdownContainer.on("mousedown",function(e){e.stopPropagation()})},e.prototype.destroy=function(e){e.call(this),this.$dropdownContainer.remove()},e.prototype.position=function(e,t,n){t.attr("class",n.attr("class")),t.removeClass("select2"),t.addClass("select2-container--open"),t.css({position:"absolute",top:-999999}),this.$container=n},e.prototype.render=function(e){var t=f(""),n=e.call(this);return t.append(n),this.$dropdownContainer=t},e.prototype._hideDropdown=function(e){this.$dropdownContainer.detach()},e.prototype._bindContainerResultHandlers=function(e,t){if(!this._containerResultsHandlersBound){var n=this;t.on("results:all",function(){n._positionDropdown(),n._resizeDropdown()}),t.on("results:append",function(){n._positionDropdown(),n._resizeDropdown()}),t.on("results:message",function(){n._positionDropdown(),n._resizeDropdown()}),t.on("select",function(){n._positionDropdown(),n._resizeDropdown()}),t.on("unselect",function(){n._positionDropdown(),n._resizeDropdown()}),this._containerResultsHandlersBound=!0}},e.prototype._attachPositioningHandler=function(e,t){var n=this,i="scroll.select2."+t.id,r="resize.select2."+t.id,o="orientationchange.select2."+t.id,s=this.$container.parents().filter(a.hasScroll);s.each(function(){a.StoreData(this,"select2-scroll-position",{x:f(this).scrollLeft(),y:f(this).scrollTop()})}),s.on(i,function(e){var t=a.GetData(this,"select2-scroll-position");f(this).scrollTop(t.y)}),f(window).on(i+" "+r+" "+o,function(e){n._positionDropdown(),n._resizeDropdown()})},e.prototype._detachPositioningHandler=function(e,t){var n="scroll.select2."+t.id,i="resize.select2."+t.id,r="orientationchange.select2."+t.id;this.$container.parents().filter(a.hasScroll).off(n),f(window).off(n+" "+i+" "+r)},e.prototype._positionDropdown=function(){var e=f(window),t=this.$dropdown.hasClass("select2-dropdown--above"),n=this.$dropdown.hasClass("select2-dropdown--below"),i=null,r=this.$container.offset();r.bottom=r.top+this.$container.outerHeight(!1);var o={height:this.$container.outerHeight(!1)};o.top=r.top,o.bottom=r.top+o.height;var s=this.$dropdown.outerHeight(!1),a=e.scrollTop(),l=e.scrollTop()+e.height(),c=ar.bottom+s,d={left:r.left,top:o.bottom},p=this.$dropdownParent;"static"===p.css("position")&&(p=p.offsetParent());var h={top:0,left:0};(f.contains(document.body,p[0])||p[0].isConnected)&&(h=p.offset()),d.top-=h.top,d.left-=h.left,t||n||(i="below"),u||!c||t?!c&&u&&t&&(i="below"):i="above",("above"==i||t&&"below"!==i)&&(d.top=o.top-h.top-s),null!=i&&(this.$dropdown.removeClass("select2-dropdown--below select2-dropdown--above").addClass("select2-dropdown--"+i),this.$container.removeClass("select2-container--below select2-container--above").addClass("select2-container--"+i)),this.$dropdownContainer.css(d)},e.prototype._resizeDropdown=function(){var e={width:this.$container.outerWidth(!1)+"px"};this.options.get("dropdownAutoWidth")&&(e.minWidth=e.width,e.position="relative",e.width="auto"),this.$dropdown.css(e)},e.prototype._showDropdown=function(e){this.$dropdownContainer.appendTo(this.$dropdownParent),this._positionDropdown(),this._resizeDropdown()},e}),e.define("select2/dropdown/minimumResultsForSearch",[],function(){function e(e,t,n,i){this.minimumResultsForSearch=n.get("minimumResultsForSearch"),this.minimumResultsForSearch<0&&(this.minimumResultsForSearch=1/0),e.call(this,t,n,i)}return e.prototype.showSearch=function(e,t){return!(function e(t){for(var n=0,i=0;i');return e.attr("dir",this.options.get("dir")),this.$container=e,this.$container.addClass("select2-container--"+this.options.get("theme")),u.StoreData(e[0],"element",this.$element),e},d}),e.define("select2/compat/utils",["jquery"],function(s){return{syncCssClasses:function(e,t,n){var i,r,o=[];(i=s.trim(e.attr("class")))&&s((i=""+i).split(/\s+/)).each(function(){0===this.indexOf("select2-")&&o.push(this)}),(i=s.trim(t.attr("class")))&&s((i=""+i).split(/\s+/)).each(function(){0!==this.indexOf("select2-")&&null!=(r=n(this))&&o.push(r)}),e.attr("class",o.join(" "))}}}),e.define("select2/compat/containerCss",["jquery","./utils"],function(s,a){function l(e){return null}function e(){}return e.prototype.render=function(e){var t=e.call(this),n=this.options.get("containerCssClass")||"";s.isFunction(n)&&(n=n(this.$element));var i=this.options.get("adaptContainerCssClass");if(i=i||l,-1!==n.indexOf(":all:")){n=n.replace(":all:","");var r=i;i=function(e){var t=r(e);return null!=t?t+" "+e:e}}var o=this.options.get("containerCss")||{};return s.isFunction(o)&&(o=o(this.$element)),a.syncCssClasses(t,this.$element,i),t.css(o),t.addClass(n),t},e}),e.define("select2/compat/dropdownCss",["jquery","./utils"],function(s,a){function l(e){return null}function e(){}return e.prototype.render=function(e){var t=e.call(this),n=this.options.get("dropdownCssClass")||"";s.isFunction(n)&&(n=n(this.$element));var i=this.options.get("adaptDropdownCssClass");if(i=i||l,-1!==n.indexOf(":all:")){n=n.replace(":all:","");var r=i;i=function(e){var t=r(e);return null!=t?t+" "+e:e}}var o=this.options.get("dropdownCss")||{};return s.isFunction(o)&&(o=o(this.$element)),a.syncCssClasses(t,this.$element,i),t.css(o),t.addClass(n),t},e}),e.define("select2/compat/initSelection",["jquery"],function(i){function e(e,t,n){n.get("debug")&&window.console&&console.warn&&console.warn("Select2: The `initSelection` option has been deprecated in favor of a custom data adapter that overrides the `current` method. This method is now called multiple times instead of a single time when the instance is initialized. Support will be removed for the `initSelection` option in future versions of Select2"),this.initSelection=n.get("initSelection"),this._isInitialized=!1,e.call(this,t,n)}return e.prototype.current=function(e,t){var n=this;this._isInitialized?e.call(this,t):this.initSelection.call(null,this.$element,function(e){n._isInitialized=!0,i.isArray(e)||(e=[e]),t(e)})},e}),e.define("select2/compat/inputData",["jquery","../utils"],function(s,i){function e(e,t,n){this._currentData=[],this._valueSeparator=n.get("valueSeparator")||",","hidden"===t.prop("type")&&n.get("debug")&&console&&console.warn&&console.warn("Select2: Using a hidden input with Select2 is no longer supported and may stop working in the future. It is recommended to use a `
      自定义表单管理
      diyid名称表名diyid名称表名 管理
      暂无文档
      - - - + 全选 + 取消 + 删除
      列表{$nss}".$typeName."[id:".$id."](文档数:".$this->GetTotalArc($id).")"; + echo ""; - echo "
      列表{$nss}".$typeName."[id:".$id."](文档数:".$this->GetTotalArc($id).")"; echo ""; echo ""; echo ""; @@ -130,7 +130,7 @@ class TypeUnit //带封面的栏目 else if ($ispart == 1) { echo "
      封面{$nss}".$typeName."[id:".$id."]"; + echo ""; - echo "
      封面{$nss}".$typeName."[id:".$id."]"; echo ""; echo ""; echo ""; @@ -143,7 +143,7 @@ class TypeUnit //独立页面 else if ($ispart == 2) { echo "
      外部{$nss}".$typeName."[id:".$id."]"; + echo ""; echo "
      外部{$nss}".$typeName."[id:".$id."]"; echo ""; echo ""; echo ""; @@ -200,7 +200,7 @@ class TypeUnit if ($ispart == 0) { echo "
      "; echo "
      "; - echo "$step列表{$nss}".$typeName."[id:".$id."](文档数:".$this->GetTotalArc($id).")"; + echo "$step列表{$nss}".$typeName."[id:".$id."](文档数:".$this->GetTotalArc($id).")"; echo ""; echo ""; echo ""; @@ -214,7 +214,7 @@ class TypeUnit else if ($ispart == 1) { echo "
      "; echo "
      "; - echo "$step封面{$nss}".$typeName."[id:".$id."]"; + echo "$step封面{$nss}".$typeName."[id:".$id."]"; echo ""; echo ""; echo ""; @@ -228,7 +228,7 @@ class TypeUnit else if ($ispart == 2) { echo "
      "; - echo "$step外部{$nss}".$typeName."[id:".$id."]"; + echo "$step外部{$nss}".$typeName."[id:".$id."]"; echo ""; echo ""; echo "";