diff --git a/o2web/source/x_component_StandingBook/$IndexView/default/docList.html b/o2web/source/x_component_StandingBook/$IndexView/default/docList.html index ba9b61410591776629446768755b710548af3cb5..34efe42ad4cf1e96f7774fcdb7c9ecdbae0dc840 100644 --- a/o2web/source/x_component_StandingBook/$IndexView/default/docList.html +++ b/o2web/source/x_component_StandingBook/$IndexView/default/docList.html @@ -1,5 +1,8 @@ + {{each $.fieldList}} {{each $.data}} - + + + {{each $._.fieldList}} {{if $.field === "title"}} {{end if}} - {{if $.field !== "title"}} + {{if $.field === "completed"}} + + {{end if}} + + {{if ["title","completed"].indexOf($.field) === -1 }} {{end if}} diff --git a/o2web/source/x_component_StandingBook/$IndexView/default/view.html b/o2web/source/x_component_StandingBook/$IndexView/default/view.html index 3eba2769fd83b1128e0b7ae8e4721064eedacea0..5ed71fef66d0d87ff0057bc56dba09f046150bc4 100644 --- a/o2web/source/x_component_StandingBook/$IndexView/default/view.html +++ b/o2web/source/x_component_StandingBook/$IndexView/default/view.html @@ -4,17 +4,13 @@
-
-
diff --git a/o2web/source/x_component_StandingBook/$Main/default/style.css b/o2web/source/x_component_StandingBook/$Main/default/style.css index 64e8b3de4e3c91c4e81ac12c658418d7fb772aeb..ce88da817825111a5e13d42ff58058ead782af56 100644 --- a/o2web/source/x_component_StandingBook/$Main/default/style.css +++ b/o2web/source/x_component_StandingBook/$Main/default/style.css @@ -458,6 +458,10 @@ ul { padding-left:20px; margin-top:8px; background: url("../x_component_StandingBook/$Main/default/icons/location.png") no-repeat; + width: calc( 100% - 150px ); + height: 20px; + line-height: 20px; + overflow: hidden; } .breadcrumb-index a{ cursor: pointer; @@ -783,6 +787,8 @@ ul { } + + .actionbar{ text-align: center;margin-bottom: 20px; } @@ -891,7 +897,58 @@ ul { margin:10px; flex-direction: column; } - +/*.index-topLink{*/ +/* cursor: pointer;*/ +/* display: inline-block;*/ +/* width: 100px;*/ +/* height: 30px;*/ +/* line-height: 30px;*/ +/* text-align: center;*/ +/* margin-left: 10px;*/ +/* background: #FFFFFF;*/ +/* border-radius: 15px;*/ +/* color: #4A90E2;*/ +/* border: 1px solid #4A90E2;*/ +/*}*/ +.tl_button{ + cursor: pointer; + display: inline-block; + width: 100px; + height: 32px; + line-height: 32px; + color: #fff; + font-size: 14px; + background: #4A90E2; + border-radius: 16px; +} +.tl_multiActionNode{ + border-top: 1px solid #4A90E2; + line-height:60px; + height:60px; +} +.tl_okButton{ + height: 34px; + line-height: 34px; + cursor: pointer; + background: #4A90E2; + border-radius: 20px; + color: #ffffff; + font-size:14px; + width: 180px; + display: inline-block; +} +.tl_cancelButton{ + margin-left: 30px; + height: 34px; + line-height: 34px; + cursor: pointer; + color: #666666; + background: #F0F0F0; + border-radius: 20px; + font-size:14px; + width: 120px; + display: inline-block; +} .tl_contentWrap{ height: calc( 100% - 90px ); background:#ffffff; @@ -987,7 +1044,7 @@ ul { border-bottom: 1px solid #E6E6E6; } .tl_coreListAppIcon{ - margin-top:10px; + margin-top:5px; width: 30px; height: 30px; /*margin-right: 10px;*/ @@ -1009,8 +1066,8 @@ ul { overflow: hidden; } .tl_coreListAppText{ - margin-top: 10px; - font-size: 16px; + margin-top: 5px; + font-size: 15px; color: #666666; cursor: pointer; height: 30px; @@ -1020,6 +1077,9 @@ ul { border-radius: 20px; user-select: none; } +.checkbox{ + margin-right:5px; +} .tl_coreItemArea{ height: 30px; color: #666666; diff --git a/o2web/source/x_component_StandingBook/$Main/default/tabList_work.html b/o2web/source/x_component_StandingBook/$Main/default/tabList.html similarity index 92% rename from o2web/source/x_component_StandingBook/$Main/default/tabList_work.html rename to o2web/source/x_component_StandingBook/$Main/default/tabList.html index d560f7e0f93c00fd8ebd4c86e08a178d057d6869..6b216c583001066a330f9a92331739cd402ce13d 100644 --- a/o2web/source/x_component_StandingBook/$Main/default/tabList_work.html +++ b/o2web/source/x_component_StandingBook/$Main/default/tabList.html @@ -12,7 +12,7 @@ data-o2-events="mouseover:coreListItemOver;mouseout:coreListItemOut; mousedown:coreListItemDown;mouseup:coreListItemUp;click:coreListItemClick;" >{{$.name}}
-
+ @@ -21,7 +21,7 @@ -
+ {{end each}} diff --git a/o2web/source/x_component_StandingBook/$Main/default/tabList_multiselect.html b/o2web/source/x_component_StandingBook/$Main/default/tabList_multiselect.html new file mode 100644 index 0000000000000000000000000000000000000000..24c1ddf29e33f92a4bec151b4ebd161aff1207bf --- /dev/null +++ b/o2web/source/x_component_StandingBook/$Main/default/tabList_multiselect.html @@ -0,0 +1,29 @@ +
+ {{each $.data}} +
+
+ {{if ($.key)}} +
+ {{end if}} +
+
+
+
+ {{$.name}}
+
+ + + + + + + + + + +
+
+ {{end each}} +
\ No newline at end of file diff --git a/o2web/source/x_component_StandingBook/$Main/default/tabPage.html b/o2web/source/x_component_StandingBook/$Main/default/tabPage.html index 36fb3fbe51422f4102f7ddb2d0935fa529ec41ef..099bafd59b1abe3804efc649d9538c3638354043 100644 --- a/o2web/source/x_component_StandingBook/$Main/default/tabPage.html +++ b/o2web/source/x_component_StandingBook/$Main/default/tabPage.html @@ -3,6 +3,8 @@ {{if $.status.closeEnable}}
{{end if}} +
{{$.lp.enableMultiSelect}}
+
@@ -25,4 +27,8 @@
+ \ No newline at end of file diff --git a/o2web/source/x_component_StandingBook/$Main/default/tabList_doc.html b/o2web/source/x_component_StandingBook/$Main/default/~tabList_doc.html similarity index 92% rename from o2web/source/x_component_StandingBook/$Main/default/tabList_doc.html rename to o2web/source/x_component_StandingBook/$Main/default/~tabList_doc.html index 72325609d4ced73f2e0d2a9ac921a927bcd41eab..405a15dfa53ef47b6fb5634444241fbf91d7c914 100644 --- a/o2web/source/x_component_StandingBook/$Main/default/tabList_doc.html +++ b/o2web/source/x_component_StandingBook/$Main/default/~tabList_doc.html @@ -12,7 +12,7 @@ data-o2-events="mouseover:coreListItemOver;mouseout:coreListItemOut; mousedown:coreListItemDown;mouseup:coreListItemUp;click:coreListItemClick;" >{{$.name}} -
+ @@ -21,7 +21,7 @@ -
+ {{end each}} diff --git a/o2web/source/x_component_StandingBook/IndexView.js b/o2web/source/x_component_StandingBook/IndexView.js index f458d707b8a5b5860fc2a1927d92767d33058e5e..929763aed1ba0b51df053d500ea46a10468a4503 100644 --- a/o2web/source/x_component_StandingBook/IndexView.js +++ b/o2web/source/x_component_StandingBook/IndexView.js @@ -8,25 +8,21 @@ MWF.xApplication.StandingBook.IndexView = new Class({ "style": "default", "date": null }, - initialize: function(node, app, options, tabData){ + initialize: function(node, app, options, tabList){ this.setOptions(options); this.path = "../x_component_StandingBook/$IndexView/"; this.app = app; this.container = $(node); - this.tabData = tabData; + this.tabList = tabList; this.facetOrderList = ["category","applicationName", "processName","appName","categoryName"]; this.load(); }, recordStatus: function(){ return { view: "index", - tab: { - key: this.tabData.key, - name: this.tabData.name, - category: this.tabData.category - } + tab: this.tabList } }, load: function(){ @@ -45,7 +41,11 @@ MWF.xApplication.StandingBook.IndexView = new Class({ var url = this.path+this.options.style+"/view.html"; this.container.loadHtml(url, {"bind": { "lp": this.app.lp, - "tabData": this.tabData + "tabData": { + name: this.tabList.map(function (tab) { + return tab.name + }).join(", ") + } }, "module": this}, function(){ // this.loadSelectedCondition(); this.search(); @@ -141,10 +141,7 @@ MWF.xApplication.StandingBook.IndexView = new Class({ }.bind(this)); o2.Actions.load("x_query_assemble_surface").IndexAction.post({ - directoryList: [{ - key: this.tabData.key, - category: this.tabData.category - }], + directoryList: this.tabList, // query: this.searchInput.get("value") || "", page: this.docPageNum, size: this.pageSize, @@ -205,17 +202,13 @@ MWF.xApplication.StandingBook.IndexView = new Class({ // key: this.tabData.key, // type: this.tabData.type, // category: this.tabData.category, - directoryList: [{ - key: this.tabData.key, - category: this.tabData.category - }], + directoryList: this.tabList, // sortList: sortList, sort: sortList[0] || null, fixedFieldList: fixedFieldList, dynamicFieldList: dynamicFieldList, filterList: filterList }).then(function(json){ - debugger; var indexAction = o2.Actions.load("x_query_assemble_surface").IndexAction; var address = indexAction.action.address; var uri = indexAction.action.actions.exportResult.uri.replace("{flag}", json.data.id); @@ -232,8 +225,8 @@ MWF.xApplication.StandingBook.IndexView = new Class({ }.bind(this)); return facetList }, - openItem: function(id, event, row){ - if( this.tabData.type === "process" || this.tabData.type === "application" ){ + openItem: function(id, isProcess, event, row){ + if( isProcess.toString() === "true" ){ this.openWork(id, event, row) }else{ this.openDoc(id, event, row) @@ -301,6 +294,13 @@ MWF.xApplication.StandingBook.IndexView = new Class({ return field; }.bind(this)); + var sequence = (this.docPageNum - 1) * this.pageSize; + json.data.documentList.map(function (d) { + sequence++; + d.sequence = sequence; + return d; + }); + this.docListNode.loadHtml(this.path+this.options.style+"/docList.html", { "bind": {"lp": this.app.lp, "data": json.data.documentList, "fieldList":fieldList}, @@ -475,8 +475,8 @@ MWF.xApplication.StandingBook.IndexView = new Class({ d.valueCountPairList.each(function (v) { v.field = d.field; v.parentLabel = d.label; - if (d.field === "category") { - v.label = lp[v.value] || v.value; + if (["category","completed"].contains(d.field)) { + v.label = lp[v.value.toString()] || v.value; } else { v.label = v.value; } diff --git a/o2web/source/x_component_StandingBook/Main.js b/o2web/source/x_component_StandingBook/Main.js index e2ba07792df0c43176c8c75208d1dfc02cad7840..60314fd0c3a9c507a9749a54db91f3620e91feed 100644 --- a/o2web/source/x_component_StandingBook/Main.js +++ b/o2web/source/x_component_StandingBook/Main.js @@ -152,14 +152,14 @@ MWF.xApplication.StandingBook.Main = new Class({ this._loadTabList( callback ); }.bind(this)); }, - _loadTabList: function(callback){ + _loadTabList: function(callback, multiSelect){ this.tabData.data.each(function(obj){ if( obj.category === "processPlatform" ){ obj.keyList.each(function(k){ - k.category = "processPlatform"; + if(!k.category)k.category = "processPlatform"; }); this.tl_workTabListNode.empty(); - this.tl_workTabListNode.loadHtml(this.path+this.options.style+"/tabList_work.html", + this.tl_workTabListNode.loadHtml(this.path+this.options.style+"/tabList"+ (multiSelect ? "_multiselect" : "") +".html", { "bind": {"lp": this.lp, "data": obj.keyList || []}, "module": this, @@ -171,10 +171,10 @@ MWF.xApplication.StandingBook.Main = new Class({ ); }else if( obj.category === "cms" ){ obj.keyList.each(function(k){ - k.category = "cms"; + if(!k.category)k.category = "cms"; }); this.tl_docTabListNode.empty(); - this.tl_docTabListNode.loadHtml(this.path+this.options.style+"/tabList_doc.html", + this.tl_docTabListNode.loadHtml(this.path+this.options.style+"/tabList"+ (multiSelect ? "_multiselect" : "") +".html", { "bind": {"lp": this.lp, "data": obj.keyList || []}, "module": this, @@ -209,15 +209,20 @@ MWF.xApplication.StandingBook.Main = new Class({ coreListItemUp: function(e){ e.target.removeClass("mainColor_bg"); }, - coreListItemClick: function(e, data){ + coreListItemClick: function(e, tab){ // var tList = (data.tabList || []).filter(function (tab) { // return tab.core === data.core; // }); // if( tList.length ){ this.closeSelectModule(e); - this.openIndexView(data); + this.openIndexView([{ + category: tab.category, + key: tab.key, + name: tab.name + }]); // } }, + coreItemOver: function(e){ var node = e.target; while (node && !node.hasClass("tl_coreItem")){ node = node.getParent();} @@ -250,7 +255,7 @@ MWF.xApplication.StandingBook.Main = new Class({ node.removeClass("mainColor_bg"); } }, - coreItemClick: function(e, data){ + coreItemClick: function(e, tab){ // var tList = (data.tabList || []).filter(function (tab) { // return tab.core === data.core; // }); @@ -258,9 +263,80 @@ MWF.xApplication.StandingBook.Main = new Class({ // if( tList.length ){ // this.currentTabObj = tList[0]; this.closeSelectModule(e); - this.openIndexView(data); + this.openIndexView([{ + category: tab.category, + key: tab.key, + name: tab.name + }]); // } }, + + coreListItemOver_multi: function(e){ + this.getEventTarget(e, "tl_coreListAppText").addClass("mainColor_bg_opacity"); + }, + coreListItemOut_multi: function(e){ + this.getEventTarget(e, "tl_coreListAppText").removeClass("mainColor_bg_opacity"); + }, + coreListItemDown_multi: function(e){ + this.getEventTarget(e, "tl_coreListAppText").addClass("mainColor_bg_opacity"); + }, + coreListItemUp_multi: function(e){ + this.getEventTarget(e, "tl_coreListAppText").removeClass("mainColor_bg_opacity"); + }, + coreListItemClick_multi: function(e, item){ + debugger; + if( !this.curMultiSelectTabList )this.curMultiSelectTabList = []; + var target = this.getEventTarget(e, "tl_coreListAppText"); + var index = -1; + this.curMultiSelectTabList.each(function (tab, idx) { + if( tab.key === item.key )index = idx; + }); + if( index > -1 ){ //已经选择了 + target.getElement("i.checkbox").removeClass("o2icon-check_box").addClass("o2icon-check_box_outline_blank").removeClass("mainColor_color"); + this.curMultiSelectTabList.splice(index, 1); + }else{ //还没有选择 + target.getElement("i.checkbox").removeClass("o2icon-check_box_outline_blank").addClass("o2icon-check_box").addClass("mainColor_color"); + this.curMultiSelectTabList.push(item); + } + }, + okMultiSelect: function(e){ + if( this.curMultiSelectTabList.length === 0){ + this.notice( this.lp.notSelectNotice, "info"); + return; + } + var data = this.curMultiSelectTabList.map(function (tab) { + return { + category: tab.category, + key: tab.key, + name: tab.name + } + }); + this.curMultiSelectTabList = []; + this.closeSelectModule(e); + this.openIndexView(data); + }, + enableMultiSelect: function(e, data){ + this.curMultiSelectTabList = []; + this.enableMultiNode.hide(); + this.disableMultiNode.setStyle("display","inline-block"); + this.tl_multiActionNode.show(); + this.tl_workTabListNode.setStyle("height", "calc( 100% - 90px )"); + this.tl_docTabListNode.setStyle("height", "calc( 100% - 90px )"); + this._loadTabList(function () { + + }, true) + }, + disableMultiSelect: function(e, data){ + this.curMultiSelectTabList = []; + this.disableMultiNode.hide(); + this.enableMultiNode.setStyle("display","inline-block"); + this.tl_multiActionNode.hide(); + this.tl_workTabListNode.setStyle("height", "calc( 100% - 40px )"); + this.tl_docTabListNode.setStyle("height", "calc( 100% - 40px )"); + this._loadTabList(function () { + + }, false) + }, searchCoreKeydown: function(e){ if( e.keyCode === 13 ){ this.searchCore(); diff --git a/o2web/source/x_component_StandingBook/lp/en.js b/o2web/source/x_component_StandingBook/lp/en.js index 36a87733ab3e473555b35b07d4b6bcccd5fc5dec..64f7de95bc3eb34a53c9571e07f8b5f898283c9e 100644 --- a/o2web/source/x_component_StandingBook/lp/en.js +++ b/o2web/source/x_component_StandingBook/lp/en.js @@ -6,6 +6,7 @@ MWF.xApplication.StandingBook.LP = { "location": "Your location:", + "cms": "CMS", "processPlatform": "Process Management", "processManager": "Process Management", "cmsManager": "Content Management", @@ -62,10 +63,13 @@ MWF.xApplication.StandingBook.LP = { "categoryName": "Content Management Category", "selectConditionNote": "Please select", "fieldSelect": "Column Select", + "sequence": "Sequence", "more": "more", "collapse": "Collapse", "multiSelect": "Multiple Select", + "enableMultiSelect": "Allow Multiple Select ", + "disableMultiSelect": "disables Multiple Select", "ok": "OK", "cancel": "Cancel", "reset": "Reset", @@ -73,6 +77,11 @@ MWF.xApplication.StandingBook.LP = { "moreFilter": "More filter criteria", "collapseFilter": "Collapse filter criteria", + "notSelectNotice": "Please select at least one application ", + + "completed": "completed", + "true": "true", + "false": "false", "rangeSeparator": "to", "startPlaceholder": "Start time", "endPlaceholder": "End time", diff --git a/o2web/source/x_component_StandingBook/lp/zh-cn.js b/o2web/source/x_component_StandingBook/lp/zh-cn.js index 37f7758f7d2d8684f184f06229db8fd19b5217ed..472397a1bfb795b3bb68498ee103fbe86260f2dc 100644 --- a/o2web/source/x_component_StandingBook/lp/zh-cn.js +++ b/o2web/source/x_component_StandingBook/lp/zh-cn.js @@ -6,6 +6,7 @@ MWF.xApplication.StandingBook.LP = { "location": "您的位置:", + "cms": "内容管理", "processPlatform": "流程管理", "processManager": "流程管理", "cmsManager": "内容管理", @@ -60,10 +61,13 @@ MWF.xApplication.StandingBook.LP = { "categoryName": "内容管理分类", "selectConditionNote": "请选择", "fieldSelect": "列选择", + "sequence": "序号", "more": "更多", "collapse": "收起", "multiSelect": "多选", + "enableMultiSelect": "允许多选", + "disableMultiSelect": "取消多选", "ok": "确定", "cancel": "取消", "reset": "重置", @@ -71,6 +75,11 @@ MWF.xApplication.StandingBook.LP = { "moreFilter": "更多筛选条件", "collapseFilter": "收起筛选条件", + "notSelectNotice": "请至少选择一个应用", + + "completed": "已完成", + "true": "是", + "false": "否", "rangeSeparator": "至", "startPlaceholder": "开始时间", "endPlaceholder": "结束时间", diff --git a/o2web/source/x_component_ftsearch/$FTSearchView/default/docList.html b/o2web/source/x_component_ftsearch/$FTSearchView/default/docList.html index 1d79538c9de9bc64f06ed174ab167f57b80ac504..897802ba9026ca3e685b2ffe002b24e7ba902469 100644 --- a/o2web/source/x_component_ftsearch/$FTSearchView/default/docList.html +++ b/o2web/source/x_component_ftsearch/$FTSearchView/default/docList.html @@ -4,10 +4,6 @@
{{$.title}}
-
- {{$._.lp.summary}}: -
-
{{$._.lp.createTime}}: {{($.createTime || "")}} @@ -26,16 +22,6 @@ {{$.title}}
- {{$._.lp.summary}}: -
-
-
- - - - - - {{$._.lp.createTime}}: {{($.createTime || "")}} diff --git a/o2web/source/x_component_ftsearch/FTSearchView.js b/o2web/source/x_component_ftsearch/FTSearchView.js index 2b3ab53b0d01c7dd5be33d9e439e2074b75e3dc0..4b8ab4c20a6e78fe0ff830e4e2aea283cb76ef51 100644 --- a/o2web/source/x_component_ftsearch/FTSearchView.js +++ b/o2web/source/x_component_ftsearch/FTSearchView.js @@ -103,7 +103,13 @@ MWF.xApplication.ftsearch.FTSearchView = new Class({ size: this.pageSize, filterList: filterList }).then(function(json){ - this.docList = json.data.documentList; + var sequence = (this.docPageNum - 1) * this.pageSize; + this.docList = json.data.documentList.map(function (d) { + sequence++; + d.sequence = sequence; + return d; + }); + this.docTotal = json.data.count; this.loadDocList(this.docList); @@ -151,7 +157,7 @@ MWF.xApplication.ftsearch.FTSearchView = new Class({ // if( !body && d._summary_){ // body = o2.typeOf( d._summary_ ) === "array" ? d._summary_.join("") : d._summary_; // } - ev.target.set("html", d.highlighting || "") + ev.target.set("html", d.highlighting || d.summary || "") }, setSummary: function(ev, d){ var body; @@ -215,12 +221,12 @@ MWF.xApplication.ftsearch.FTSearchView = new Class({ loadCondition: function( json ){ var lp = this.app.lp; json.each(function(d){ - d.label = lp[d.field] || d.field; + d.label = lp[d.field.toString()] || d.field; d.valueCountPairList.each(function (v) { v.field = d.field; v.parentLabel = d.label; - if( d.field === "category" ){ - v.label = lp[v.value] || v.value; + if( ["category","completed"].contains(d.field)){ + v.label = lp[v.value.toString()] || v.value; }else{ v.label = v.value; } diff --git a/o2web/source/x_component_ftsearch/lp/en.js b/o2web/source/x_component_ftsearch/lp/en.js index 17f494494ffe110a01c50c50f0b470e636724566..f5caa451138e1093587cee8f1c708eaca1e10f29 100644 --- a/o2web/source/x_component_ftsearch/lp/en.js +++ b/o2web/source/x_component_ftsearch/lp/en.js @@ -6,6 +6,7 @@ MWF.xApplication.ftsearch.LP = { "location": "Your location:", + "cms": "CMS", "processPlatform": "Process Management", "processManager": "Process Management", "cmsManager": "Content Management", @@ -39,6 +40,9 @@ MWF.xApplication.ftsearch.LP = { "activityNameList": "Activity", "workStatusList": "Process Status", "updateTime": "Update Time", + "completed": "Completed", + "true": "true", + "false": "false", "application": "Process Application", "process": "Process", diff --git a/o2web/source/x_component_ftsearch/lp/zh-cn.js b/o2web/source/x_component_ftsearch/lp/zh-cn.js index 09f7ec267467ff457a92dd9ab35f1033e4b2423b..f21f60f00d3cb68b598fd0cdb76c115e40e2e9be 100644 --- a/o2web/source/x_component_ftsearch/lp/zh-cn.js +++ b/o2web/source/x_component_ftsearch/lp/zh-cn.js @@ -6,6 +6,7 @@ MWF.xApplication.ftsearch.LP = { "location": "您的位置:", + "cms": "内容管理", "processPlatform": "流程管理", "processManager": "流程管理", "cmsManager": "内容管理", @@ -37,6 +38,9 @@ MWF.xApplication.ftsearch.LP = { "activityNameList": "活动", "workStatusList": "流程状态", "updateTime": "更新时间", + "completed": "已完成", + "true": "是", + "false": "否", "application": "流程应用", "process": "流程",
+ {{$.lp.sequence}} + {{$.name}} @@ -9,14 +12,20 @@
{{$.sequence}}{{$._[$.field]}}{{ $._._.lp[$._[$.field]] }}{{$._[$.field]}}