Browse Source

Pull request #2: DEC-13237 fix: 修复次管问题

Merge in PG/plugin-decision-batch-role from ~FRANK.QIU/plugin-decision-batch-role:release/10.0 to release/10.0

* commit '5586428f5e13bc573810f71c32a2edfb709ec937':
  fix:添加finekit
  fix: 国际化
  DEC-13237 fix: 修复次管问题
persist/10.0
Frank.Qiu 5 years ago
parent
commit
6a8fb2bb48
  1. 3
      .gitignore
  2. BIN
      lib/finekit-10.0-20200430.jar
  3. 6
      plugin.xml
  4. 2
      src/main/resources/com/fr/plugin/decision/batch/role/i18n_en_US.properties
  5. 2
      src/main/resources/com/fr/plugin/decision/batch/role/i18n_ja_JP.properties
  6. 2
      src/main/resources/com/fr/plugin/decision/batch/role/i18n_ko_KR.properties
  7. 2
      src/main/resources/com/fr/plugin/decision/batch/role/i18n_zh_CN.properties
  8. 2
      src/main/resources/com/fr/plugin/decision/batch/role/i18n_zh_TW.properties
  9. 4
      src/main/resources/com/fr/plugin/decision/batch/role/plugin.min.js

3
.gitignore vendored

@ -1,5 +1,6 @@
*.iml
.idea/
lib/report/*.jar
lib/report
.DS_Store
.classpath
fr-plugin-decision-batch-role-*

BIN
lib/finekit-10.0-20200430.jar

Binary file not shown.

6
plugin.xml

@ -1,13 +1,13 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<plugin>
<id>com.fr.plugin.decision.batch.role</id>
<name><![CDATA[批量设置角色管理权限]]></name>
<name><![CDATA[批量授权角色]]></name>
<active>yes</active>
<hidden>no</hidden>
<version>1.0.1</version>
<env-version>10.0~</env-version>
<jartime>2020-4-20</jartime>
<vendor>zed</vendor>
<jartime>2020-5-1</jartime>
<vendor>finereport</vendor>
<description><![CDATA[可以批量设置角色权限]]></description>
<change-notes><![CDATA[
<p>[2019-04-28]实现批量设置角色逻辑</p>

2
src/main/resources/com/fr/plugin/decision/batch/role/i18n_en_US.properties

@ -2,6 +2,6 @@ Dec-Plugin_Authority_Role_De_Authorization=Full Cancels
Dec-Plugin_Authority_Role_De_Authorization_Tip=Are you sure want to remove the administrative rights of the selected {} to all the following roles?
Dec-Plugin_Authority_Role_Full_Authorization=Full Authorize
Dec-Plugin_Authority_Role_Full_Authorization_Tip=Are you sure want to grant the selected {} administrative rights to all of the following roles?
Dec-Plugin_Authority_Role_Processing=Processing
Dec-Plugin_Authority_Role_Processing=Processing...
Dec-Plugin_Authority_Role_Processing_Fail=Processing failed
Dec-Plugin_Authority_Role_Processing_Success=Processing complete

2
src/main/resources/com/fr/plugin/decision/batch/role/i18n_ja_JP.properties

@ -2,6 +2,6 @@ Dec-Plugin_Authority_Role_De_Authorization=\u5168\u90E8\u89E3\u9664
Dec-Plugin_Authority_Role_De_Authorization_Tip=\u786E\u5B9A\u89E3\u9664\u5DF2\u9009{}\u5BF9\u4EE5\u4E0B\u6240\u6709\u89D2\u8272\u7684\u7BA1\u7406\u6743\u9650\uFF1F
Dec-Plugin_Authority_Role_Full_Authorization=\u5168\u90E8\u6388\u6743
Dec-Plugin_Authority_Role_Full_Authorization_Tip=\u786E\u5B9A\u6388\u4E88\u5DF2\u9009{}\u5BF9\u4EE5\u4E0B\u6240\u6709\u89D2\u8272\u7684\u7BA1\u7406\u6743\u9650\uFF1F
Dec-Plugin_Authority_Role_Processing=\u5904\u7406\u4E2D
Dec-Plugin_Authority_Role_Processing=\u5904\u7406\u4E2D...
Dec-Plugin_Authority_Role_Processing_Fail=\u5904\u7406\u5931\u8D25
Dec-Plugin_Authority_Role_Processing_Success=\u5904\u7406\u5B8C\u6210

2
src/main/resources/com/fr/plugin/decision/batch/role/i18n_ko_KR.properties

@ -2,6 +2,6 @@ Dec-Plugin_Authority_Role_De_Authorization=\u5168\u90E8\u89E3\u9664
Dec-Plugin_Authority_Role_De_Authorization_Tip=\u786E\u5B9A\u89E3\u9664\u5DF2\u9009{}\u5BF9\u4EE5\u4E0B\u6240\u6709\u89D2\u8272\u7684\u7BA1\u7406\u6743\u9650\uFF1F
Dec-Plugin_Authority_Role_Full_Authorization=\u5168\u90E8\u6388\u6743
Dec-Plugin_Authority_Role_Full_Authorization_Tip=\u786E\u5B9A\u6388\u4E88\u5DF2\u9009{}\u5BF9\u4EE5\u4E0B\u6240\u6709\u89D2\u8272\u7684\u7BA1\u7406\u6743\u9650\uFF1F
Dec-Plugin_Authority_Role_Processing=\u5904\u7406\u4E2D
Dec-Plugin_Authority_Role_Processing=\u5904\u7406\u4E2D...
Dec-Plugin_Authority_Role_Processing_Fail=\u5904\u7406\u5931\u8D25
Dec-Plugin_Authority_Role_Processing_Success=\u5904\u7406\u5B8C\u6210

2
src/main/resources/com/fr/plugin/decision/batch/role/i18n_zh_CN.properties

@ -2,6 +2,6 @@ Dec-Plugin_Authority_Role_De_Authorization=\u5168\u90E8\u89E3\u9664
Dec-Plugin_Authority_Role_De_Authorization_Tip=\u786E\u5B9A\u89E3\u9664\u5DF2\u9009{}\u5BF9\u4EE5\u4E0B\u6240\u6709\u89D2\u8272\u7684\u7BA1\u7406\u6743\u9650\uFF1F
Dec-Plugin_Authority_Role_Full_Authorization=\u5168\u90E8\u6388\u6743
Dec-Plugin_Authority_Role_Full_Authorization_Tip=\u786E\u5B9A\u6388\u4E88\u5DF2\u9009{}\u5BF9\u4EE5\u4E0B\u6240\u6709\u89D2\u8272\u7684\u7BA1\u7406\u6743\u9650\uFF1F
Dec-Plugin_Authority_Role_Processing=\u5904\u7406\u4E2D
Dec-Plugin_Authority_Role_Processing=\u5904\u7406\u4E2D...
Dec-Plugin_Authority_Role_Processing_Fail=\u5904\u7406\u5931\u8D25
Dec-Plugin_Authority_Role_Processing_Success=\u5904\u7406\u5B8C\u6210

2
src/main/resources/com/fr/plugin/decision/batch/role/i18n_zh_TW.properties

@ -2,6 +2,6 @@ Dec-Plugin_Authority_Role_De_Authorization=\u5168\u90E8\u89E3\u9664
Dec-Plugin_Authority_Role_De_Authorization_Tip=\u78BA\u5B9A\u89E3\u9664\u5DF2\u9078{}\u5C0D\u4EE5\u4E0B\u6240\u6709\u89D2\u8272\u7684\u7BA1\u7406\u8A31\u53EF\u6B0A\uFF1F
Dec-Plugin_Authority_Role_Full_Authorization=\u5168\u90E8\u6388\u6B0A
Dec-Plugin_Authority_Role_Full_Authorization_Tip=\u78BA\u5B9A\u6388\u4E88\u5DF2\u9078{}\u5C0D\u4EE5\u4E0B\u6240\u6709\u89D2\u8272\u7684\u7BA1\u7406\u8A31\u53EF\u6B0A\uFF1F
Dec-Plugin_Authority_Role_Processing=\u8655\u7406\u4E2D
Dec-Plugin_Authority_Role_Processing=\u8655\u7406\u4E2D...
Dec-Plugin_Authority_Role_Processing_Fail=\u8655\u7406\u5931\u6557
Dec-Plugin_Authority_Role_Processing_Success=\u8655\u7406\u5B8C\u6210

4
src/main/resources/com/fr/plugin/decision/batch/role/plugin.min.js vendored

@ -1,2 +1,2 @@
/** simple-template 20-05-06 15:14:46 */
!function(){var t=BI.inherit(BI.BasicButton,{props:{baseCls:"",text:"",items:[{value:!0,text:BI.i18nText("Dec-Plugin_Authority_Role_Full_Authorization")},{value:!1,text:BI.i18nText("Dec-Plugin_Authority_Role_De_Authorization")}]},render:function(){var e=this,t=this.options;return{type:"bi.center_adapt",items:[{type:"bi.combo",trigger:"click",adjustXOffset:60,adjustYOffset:-8,el:{type:"bi.vertical_adapt",height:36,items:[{type:"bi.label",text:t.text,ref:function(t){e.text=t}},{type:"bi.icon_button",height:16,tgap:5,cls:"trigger-triangle-font",ref:function(t){e.trigger=t}}]},popup:{el:{type:"bi.vertical",items:[{type:"bi.text_value_combo_popup",chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE,items:t.items,textAlign:"center",listeners:[{eventName:BI.IconComboPopup.EVENT_CHANGE,action:function(){e.combo.hideView(),e.fireEvent("EVENT_CHANGE",this.getValue()[0]),this.setValue()}}]}]}},ref:function(t){e.combo=t}}]}},doHighLight:function(){this.text.doHighLight()},unHighLight:function(){this.text.unHighLight()}});BI.shortcut("dec.plugin.role.list.header.auth",t)}(),Dec.Utils=Dec.Utils||{},BI.extend(Dec.Utils,{setPluginRoleAuthority:function(t,e){Dec.reqPost("/batch/role",t,e)}}),function(){var t=BI.inherit(BI.NodeButton,{props:{baseCls:"dec-expander-trigger bi-background",texts:[],items:[],iconWidth:30},_store:function(){return BI.Models.getModel("dec.model.plugin.role.trigger")},watch:{status:function(t){this.statusMasker&&this.statusMasker.setStatus(t)}},render:function(){var e=this,i=this.options;return{type:"bi.htape",items:[{el:{type:"dec.screening.combo",ref:function(t){e.combo=t},text:i.texts.all,defaultValue:1,items:[{text:i.texts.all,iconCls1:"check-mark-e-font",value:1},{text:i.texts.onlyOpen,iconCls1:"check-mark-e-font",value:2}],listeners:[{eventName:"EVENT_CHANGE",action:function(){}}]}},{el:{type:"bi.button_group",ref:function(t){e.authItemsGroup=t},layouts:[{type:"bi.right_vertical_adapt"}],items:this._formatItems(i.items)},width:300},{el:{type:"dec.display.selector",ref:function(t){e.displaySelecter=t},items:i.items,listeners:[{eventName:"EVENT_CHANGE",action:function(t){i.onAuthItemsChange(t)}}]},width:30},{type:"bi.default",width:i.iconWidth}]}},_formatItems:function(t){var i=this,o=[];return BI.each(t,function(t,e){e.selected&&o.push(BI.extend({type:"dec.plugin.role.list.header.auth",width:i.options.itemWidth,listeners:[{eventName:"EVENT_CHANGE",action:function(t){i._doAuth(t)}}]},e))}),o},_doAuth:function(e){var i=this,t=BI.i18nText(e?"Dec-Plugin_Authority_Role_Full_Authorization_Tip":"Dec-Plugin_Authority_Role_De_Authorization_Tip",this.model.carrierText);BI.Msg.confirm(BI.i18nText("BI-Basic_Sure"),t,function(t){t&&i._startSet(e)})},_startSet:function(t){var e=this,i=BI.UUID();BI.Maskers.create(i,null,{render:{type:"dec.test.status",waitingText:BI.i18nText("Dec-Plugin_Authority_Role_Processing"),successText:BI.i18nText("Dec-Plugin_Authority_Role_Processing_Success"),failText:BI.i18nText("Dec-Plugin_Authority_Role_Processing_Fail"),listeners:[{eventName:"EVENT_CLOSE",action:function(){BI.Maskers.hide(i),BI.Maskers.remove(i)}}],ref:function(t){e.statusMasker=t}}}),BI.Maskers.show(i),e.store.doAuthorization(t)},doHighLight:function(i){var t=this.authItemsGroup.getAllButtons();BI.each(t,function(t,e){e.getValue()===i?e.doHighLight():e.unHighLight()})},unHighLight:function(){var t=this.authItemsGroup.getAllButtons();BI.each(t,function(t,e){e.unHighLight()})},populate:function(t){this.options.authItems=t,this.authItemsGroup.populate(this._formatItems(t))}});t.EVENT_CHANGE="EVENT_CHANGE",t.EVENT_RESIZE="EVENT_RESIZE",BI.shortcut("dec.plugin.role.list.header",t)}(),function(){var t=BI.inherit(Fix.Model,{state:function(){return{status:{}}},context:["keyword","entityInfo","carrierInfo"],computed:{carrierText:function(){var t=this.model.carrierInfo.carrierType;return t===DecCst.Authority.CARRIER_TYPE.USER?BI.i18nText("Dec-Basic_User"):t===DecCst.Authority.CARRIER_TYPE.DEPOST?BI.i18nText("Dec-Department"):t===DecCst.Authority.CARRIER_TYPE.ROLE?BI.i18nText("Dec-Role"):""}},actions:{doAuthorization:function(t){var e=this;Dec.Utils.setPluginRoleAuthority({roleType:this.model.carrierInfo.carrierType,roleId:this.model.carrierInfo.carrierId,authType:2,authValue:t?2:1,keyword:this.model.keyword},function(t){e.model.status=t,BI.isNotNull(t.data)&&(e.model.carrierInfo=BI.extend({},e.model.carrierInfo))})}}});BI.model("dec.model.plugin.role.trigger",t)}(),BI.config("dec.role.expander",function(t){return BI.extend(t,{header:"dec.plugin.role.list.header"})});
/** simple-template 20-05-09 17:10:41 */
!function(){var t=BI.inherit(BI.BasicButton,{props:{baseCls:"",text:"",items:[{value:!0,text:BI.i18nText("Dec-Plugin_Authority_Role_Full_Authorization")},{value:!1,text:BI.i18nText("Dec-Plugin_Authority_Role_De_Authorization")}]},render:function(){var e=this,t=this.options;return{type:"bi.center_adapt",items:[{type:"bi.combo",trigger:"click",adjustXOffset:60,adjustYOffset:-8,el:{type:"bi.vertical_adapt",height:36,items:[{type:"bi.label",text:t.text,ref:function(t){e.text=t}},{type:"bi.icon_button",height:16,tgap:5,cls:"trigger-triangle-font",ref:function(t){e.trigger=t}}]},popup:{el:{type:"bi.vertical",items:[{type:"bi.text_value_combo_popup",chooseType:BI.ButtonGroup.CHOOSE_TYPE_SINGLE,items:t.items,textAlign:"center",listeners:[{eventName:BI.IconComboPopup.EVENT_CHANGE,action:function(){e.combo.hideView(),e.fireEvent("EVENT_CHANGE",this.getValue()[0]),this.setValue()}}]}]}},ref:function(t){e.combo=t}}]}},doHighLight:function(){this.text.doHighLight()},unHighLight:function(){this.text.unHighLight()}});BI.shortcut("dec.plugin.role.list.header.auth",t)}(),Dec.Utils=Dec.Utils||{},BI.extend(Dec.Utils,{setPluginRoleAuthority:function(t,e){Dec.reqPost("/batch/role",t,e)}}),function(){var t=BI.inherit(BI.NodeButton,{props:{baseCls:"dec-expander-trigger bi-background",texts:[],items:[],iconWidth:30},_store:function(){return BI.Models.getModel("dec.model.plugin.role.trigger")},watch:{status:function(t){this.statusMasker&&this.statusMasker.setStatus(t)}},render:function(){var e=this,i=this.options;return{type:"bi.htape",items:[{el:{type:"dec.screening.combo",ref:function(t){e.combo=t},text:i.texts.all,defaultValue:1,items:[{text:i.texts.all,iconCls1:"check-mark-e-font",value:1},{text:i.texts.onlyOpen,iconCls1:"check-mark-e-font",value:2}],listeners:[{eventName:"EVENT_CHANGE",action:function(){}}]}},{el:{type:"bi.button_group",ref:function(t){e.authItemsGroup=t},layouts:[{type:"bi.right_vertical_adapt"}],items:this._formatItems(i.items)},width:300},{el:{type:"dec.display.selector",ref:function(t){e.displaySelecter=t},items:i.items,listeners:[{eventName:"EVENT_CHANGE",action:function(t){i.onAuthItemsChange(t)}}]},width:30},{type:"bi.default",width:i.iconWidth}]}},_formatItems:function(t){var i=this,o=[];return BI.each(t,function(t,e){e.selected&&o.push(BI.extend({type:"dec.plugin.role.list.header.auth",width:i.options.itemWidth,listeners:[{eventName:"EVENT_CHANGE",action:function(t){i._doAuth(t)}}]},e))}),o},_doAuth:function(e){var i=this,t=BI.i18nText(e?"Dec-Plugin_Authority_Role_Full_Authorization_Tip":"Dec-Plugin_Authority_Role_De_Authorization_Tip",this.model.carrierText);BI.Msg.confirm(BI.i18nText("BI-Basic_Sure"),t,function(t){t&&i._startSet(e)})},_startSet:function(t){var e=this,i=BI.UUID();BI.Maskers.create(i,null,{render:{type:"dec.test.status",waitingText:BI.i18nText("Dec-Plugin_Authority_Role_Processing"),successText:BI.i18nText("Dec-Plugin_Authority_Role_Processing_Success"),failText:BI.i18nText("Dec-Plugin_Authority_Role_Processing_Fail"),listeners:[{eventName:"EVENT_CLOSE",action:function(){BI.Maskers.hide(i),BI.Maskers.remove(i)}}],ref:function(t){e.statusMasker=t}}}),BI.Maskers.show(i),e.store.doAuthorization(t)},doHighLight:function(i){var t=this.authItemsGroup.getAllButtons();BI.each(t,function(t,e){e.getValue()===i?e.doHighLight():e.unHighLight()})},unHighLight:function(){var t=this.authItemsGroup.getAllButtons();BI.each(t,function(t,e){e.unHighLight()})},populate:function(t){this.options.authItems=t,this.authItemsGroup.populate(this._formatItems(t))}});t.EVENT_CHANGE="EVENT_CHANGE",t.EVENT_RESIZE="EVENT_RESIZE",BI.shortcut("dec.plugin.role.list.header",t)}(),function(){var t=BI.inherit(Fix.Model,{state:function(){return{status:{}}},context:["keyword","entityInfo","carrierInfo"],computed:{carrierText:function(){var t=this.model.carrierInfo.carrierType;return t===DecCst.Authority.CARRIER_TYPE.USER?BI.i18nText("Dec-Basic_User"):t===DecCst.Authority.CARRIER_TYPE.DEPOST?BI.i18nText("Dec-Department"):t===DecCst.Authority.CARRIER_TYPE.ROLE?BI.i18nText("Dec-Role"):""}},actions:{doAuthorization:function(t){var e=this;Dec.Utils.setPluginRoleAuthority({roleType:this.model.carrierInfo.carrierType,roleId:this.model.carrierInfo.carrierId,authType:2,authValue:t?2:1,keyword:this.model.keyword},function(t){e.model.status=t,BI.isNotNull(t.data)&&(e.model.carrierInfo=BI.extend({},e.model.carrierInfo))})}}});BI.model("dec.model.plugin.role.trigger",t)}(),BI.config("dec.role.expander",function(t){return BI.Services.getService("dec.service.global").isAdmin()?BI.extend(t,{header:"dec.plugin.role.list.header"}):t});
Loading…
Cancel
Save