gds-plus-design-vue 1.1.87 → 1.2.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/{chartbi.c211f08d.js → chartbi.06e48153.js} +20 -20
- package/lib/{chartbi.090c7bd2.mjs → chartbi.cdd1e365.mjs} +21 -14
- package/lib/gd-initial.js +12 -12
- package/lib/gd-initial.mjs +1993 -1336
- package/lib/main.2415a49a.js +1 -0
- package/lib/{main.b4723893.mjs → main.2cddfbbd.mjs} +5 -5
- package/lib/{main.6903ab7a.js → main.4c447fc3.js} +1 -1
- package/lib/{main.197a0d5f.mjs → main.86fe06d4.mjs} +6 -6
- package/lib/{main.4f2a165f.mjs → main.b2d0a309.mjs} +10 -10
- package/lib/{main.d1772cf9.js → main.d091d06d.js} +1 -1
- package/lib/{messages.0e2d9d5a.js → messages.2fff74f3.js} +5 -5
- package/lib/{messages.a9287789.mjs → messages.d8abe18d.mjs} +18 -18
- package/lib/style.css +3 -3
- package/lib/{system.account.d3dd14ec.js → system.account.8ea53681.js} +2 -2
- package/lib/{system.account.e95f40c9.mjs → system.account.9bc40d08.mjs} +230 -230
- package/lib/{system.config.e74cc108.mjs → system.config.8223d495.mjs} +3 -3
- package/lib/{system.config.1164deec.js → system.config.c6e30213.js} +1 -1
- package/lib/{system.datasource.034737e6.mjs → system.datasource.57233650.mjs} +3 -3
- package/lib/{system.datasource.813c512e.js → system.datasource.fd6a4e76.js} +1 -1
- package/lib/{system.dict.9b1038c3.mjs → system.dict.8f95218b.mjs} +115 -89
- package/lib/system.dict.a24f33b0.js +1 -0
- package/lib/{system.duplicatechecking.e5542a97.js → system.duplicatechecking.39293985.js} +1 -1
- package/lib/{system.duplicatechecking.1aac5b8c.mjs → system.duplicatechecking.6b706948.mjs} +17 -9
- package/lib/{system.email.6041b7b0.js → system.email.a2d9a307.js} +2 -2
- package/lib/{system.email.96d35919.mjs → system.email.dae988be.mjs} +4 -4
- package/lib/{system.fieldsecurity.0909e14b.mjs → system.fieldsecurity.02627a7a.mjs} +14 -14
- package/lib/{system.fieldsecurity.eb33e06f.js → system.fieldsecurity.a0cec24d.js} +1 -1
- package/lib/{system.file.507bf874.mjs → system.file.0fa095a9.mjs} +4 -4
- package/lib/{system.file.e37f9bd2.js → system.file.d695ab37.js} +1 -1
- package/lib/{system.log.0c37bd82.mjs → system.log.acb64505.mjs} +2 -2
- package/lib/{system.log.73097e0b.js → system.log.c07ae5db.js} +1 -1
- package/lib/{system.machine.4302c7e3.js → system.machine.7fa3e3d1.js} +1 -1
- package/lib/{system.machine.fb7aa834.mjs → system.machine.fc392d7f.mjs} +2 -2
- package/lib/{system.notice.128ebe61.mjs → system.notice.5ae50bd4.mjs} +5 -5
- package/lib/{system.notice.d92fe0cd.js → system.notice.f18578ae.js} +1 -1
- package/lib/{system.noticereceived.54ac8bcb.mjs → system.noticereceived.1aa70b65.mjs} +4 -4
- package/lib/{system.noticereceived.32361d39.js → system.noticereceived.bfa98a9b.js} +1 -1
- package/lib/{system.onlineuser.2c37c72c.js → system.onlineuser.1c428d05.js} +1 -1
- package/lib/{system.onlineuser.2a4b2db5.mjs → system.onlineuser.3d848a32.mjs} +2 -2
- package/lib/{system.org.df5901a3.js → system.org.5bb36f9c.js} +1 -1
- package/lib/{system.org.146afbe9.mjs → system.org.fcf96d1e.mjs} +3 -3
- package/lib/{system.permissions.5f00b39f.mjs → system.permissions.23f5b097.mjs} +11 -11
- package/lib/{system.permissions.41571e57.js → system.permissions.a1a9505c.js} +2 -2
- package/lib/{system.plugin.ddd4c699.js → system.plugin.b6de4673.js} +1 -1
- package/lib/{system.plugin.9b9c4301.mjs → system.plugin.e37f9dbc.mjs} +4 -4
- package/lib/{system.pos.eb8248c1.mjs → system.pos.1a01fc97.mjs} +3 -3
- package/lib/{system.pos.352032e6.js → system.pos.a4fb19b0.js} +1 -1
- package/lib/system.promptmanagement.290958b1.js +1 -0
- package/lib/{system.promptmanagement.cd36225c.mjs → system.promptmanagement.36a65c51.mjs} +20 -12
- package/lib/{system.role.8d9f0f33.mjs → system.role.68de93ef.mjs} +13 -13
- package/lib/{system.role.656fa7cc.js → system.role.88100f66.js} +1 -1
- package/lib/{system.sumberrules.6eee79be.mjs → system.sumberrules.cdef9308.mjs} +5 -5
- package/lib/system.sumberrules.dd6299e8.js +1 -0
- package/lib/system.team.53d64006.js +1 -0
- package/lib/system.team.ee652fe4.mjs +926 -0
- package/lib/system.teammembers.26a2ba81.mjs +398 -0
- package/lib/system.teammembers.4a3dc336.js +1 -0
- package/lib/{system.timers.f4eaacaf.mjs → system.timers.4efa8a7d.mjs} +16 -16
- package/lib/{system.timers.a348d394.js → system.timers.b9424204.js} +2 -2
- package/lib/{system.translation.00e5bfa2.mjs → system.translation.0a9399b4.mjs} +14 -14
- package/lib/{system.translation.aa511bcb.js → system.translation.21d2fd8b.js} +1 -1
- package/lib/{system.user.eecef7c2.mjs → system.user.4fcfdf99.mjs} +9 -9
- package/lib/{system.user.2a00c354.js → system.user.d48a08db.js} +3 -3
- package/lib/{system.useraffiliation.f986d344.js → system.useraffiliation.a59ce45b.js} +1 -1
- package/lib/{system.useraffiliation.d638afe1.mjs → system.useraffiliation.fb002239.mjs} +7 -7
- package/lib/{system.webresource.5071b3f4.js → system.webresource.3366cc29.js} +1 -1
- package/lib/{system.webresource.d25eab7d.mjs → system.webresource.4df01c92.mjs} +9 -9
- package/lib/{system.welcome.1988f581.mjs → system.welcome.120f4b50.mjs} +2 -2
- package/lib/{system.welcome.b6ec1ec0.js → system.welcome.472f099b.js} +1 -1
- package/locale/el/en_US.js +122 -122
- package/locale/el/id_ID.js +122 -122
- package/locale/el/vi_VN.js +122 -122
- package/locale/el/zh_CN.js +122 -122
- package/locale/en_US.js +17 -2
- package/locale/id_ID.js +17 -2
- package/locale/vi_VN.js +17 -2
- package/locale/zh_CN.js +17 -2
- package/package.json +1 -1
- package/lib/main.d9f793bb.js +0 -1
- package/lib/system.dict.2deb0cde.js +0 -1
- package/lib/system.promptmanagement.25e1639b.js +0 -1
- package/lib/system.sumberrules.0a269af6.js +0 -1
- /package/lib/{element-theme-chalk.ae828c17.js → element-theme-chalk.dee12271.js} +0 -0
- /package/lib/{element-theme-chalk.35b1f600.mjs → element-theme-chalk.fbb1a631.mjs} +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { s as d, a as c, b as u, G as h, c as m, d as g, e as p, f, g as y, h as
|
|
2
|
-
import { n as r, m as $ } from "./chartbi.
|
|
3
|
-
import { m as v } from "./messages.
|
|
1
|
+
import { s as d, a as c, b as u, G as h, c as m, d as g, e as p, f, g as y, h as _, i as b } from "./system.promptmanagement.36a65c51.mjs";
|
|
2
|
+
import { n as r, m as $ } from "./chartbi.cdd1e365.mjs";
|
|
3
|
+
import { m as v } from "./messages.d8abe18d.mjs";
|
|
4
4
|
const w = {
|
|
5
5
|
props: {
|
|
6
6
|
openPermissions: {
|
|
@@ -214,7 +214,7 @@ var x = function() {
|
|
|
214
214
|
k,
|
|
215
215
|
!1,
|
|
216
216
|
null,
|
|
217
|
-
"
|
|
217
|
+
"98493209",
|
|
218
218
|
null,
|
|
219
219
|
null
|
|
220
220
|
);
|
|
@@ -297,7 +297,7 @@ var C = function() {
|
|
|
297
297
|
F,
|
|
298
298
|
!1,
|
|
299
299
|
null,
|
|
300
|
-
"
|
|
300
|
+
"4232173a",
|
|
301
301
|
null,
|
|
302
302
|
null
|
|
303
303
|
);
|
|
@@ -568,7 +568,7 @@ const O = {
|
|
|
568
568
|
beforeClose: (t, s, a) => {
|
|
569
569
|
if (a(), t === "confirm")
|
|
570
570
|
return new Promise((i, l) => {
|
|
571
|
-
|
|
571
|
+
_({
|
|
572
572
|
ids: e.selectedRowKeys.join(",")
|
|
573
573
|
}).then((n) => {
|
|
574
574
|
n.success ? (e.$message.success(e.$i18nt("gd.https.delSucc")), e.handleOk()) : e.$message.error(e.$i18nt("gd.https.delFail") + n.message), i();
|
|
@@ -596,7 +596,7 @@ const O = {
|
|
|
596
596
|
beforeClose: (t, s, a) => {
|
|
597
597
|
if (a(), t === "confirm")
|
|
598
598
|
return new Promise((i, l) => {
|
|
599
|
-
|
|
599
|
+
b({}).then((n) => {
|
|
600
600
|
n.success ? (e.$message.success(e.$i18nt("gd.https.operateSucc")), e.handleOk()) : e.$message.error(e.$i18nt("gd.https.operateFail") + n.message), i();
|
|
601
601
|
}).catch((n) => {
|
|
602
602
|
e.$message.error(e.$i18nt("gd.error.error") + n.message);
|
|
@@ -627,15 +627,15 @@ const O = {
|
|
|
627
627
|
var N = function() {
|
|
628
628
|
var t = this, s = t._self._c;
|
|
629
629
|
return s("div", { staticClass: "gd-page-view" }, [s("div", { staticClass: "page-view-list" }, [s("gd-tables", { ref: "table", attrs: { height: t.getHeight, columns: t.columns, dataSource: t.loadData, selectedRowKeys: t.selectedRowKeys, size: t.tableSize, pageSize: t.tablePageSize, filtering: !1 }, on: { onChange: t.onSelectChange }, scopedSlots: t._u([t.quickQuery ? { key: "operator", fn: function() {
|
|
630
|
-
return [s("div", { staticClass: "gd-table-operator" }, [s("div", { staticClass: "gd-table-operatorl", staticStyle: { width: "300px", "margin-right": "12px" } }, [s("el-input", { staticClass: "table-operator-input", attrs: { placeholder: t.$i18nt("gd.translation.
|
|
631
|
-
return !a.type.indexOf("key") && t._k(a.keyCode, "enter", 13, a.key, "Enter") ? null : t.query.apply(null, arguments);
|
|
632
|
-
} }, model: { value: t.queryParam.name, callback: function(a) {
|
|
633
|
-
t.$set(t.queryParam, "name", a);
|
|
634
|
-
}, expression: "queryParam.name" } }), s("div", { staticClass: "table-operator-search", on: { click: t.query } }, [s("i", { staticClass: "el-input__icon el-icon-search" })])], 1), s("div", { staticClass: "gd-table-operatorl", staticStyle: { width: "300px" } }, [s("el-input", { staticClass: "table-operator-input", attrs: { placeholder: t.$i18nt("gd.translation.value"), clearable: "" }, nativeOn: { keyup: function(a) {
|
|
630
|
+
return [s("div", { staticClass: "gd-table-operator" }, [s("div", { staticClass: "gd-table-operatorl", staticStyle: { width: "300px", "margin-right": "12px" } }, [s("el-input", { staticClass: "table-operator-input", attrs: { placeholder: t.$i18nt("gd.translation.value"), clearable: "" }, nativeOn: { keyup: function(a) {
|
|
635
631
|
return !a.type.indexOf("key") && t._k(a.keyCode, "enter", 13, a.key, "Enter") ? null : t.query.apply(null, arguments);
|
|
636
632
|
} }, model: { value: t.queryParam.description, callback: function(a) {
|
|
637
633
|
t.$set(t.queryParam, "description", a);
|
|
638
|
-
}, expression: "queryParam.description" } }), s("div", { staticClass: "table-operator-search", on: { click: t.query } }, [s("i", { staticClass: "el-input__icon el-icon-search" })])], 1), s("div", { staticClass: "gd-table-
|
|
634
|
+
}, expression: "queryParam.description" } }), s("div", { staticClass: "table-operator-search", on: { click: t.query } }, [s("i", { staticClass: "el-input__icon el-icon-search" })])], 1), s("div", { staticClass: "gd-table-operatorl", staticStyle: { width: "300px" } }, [s("el-input", { staticClass: "table-operator-input", attrs: { placeholder: t.$i18nt("gd.translation.key"), clearable: "" }, nativeOn: { keyup: function(a) {
|
|
635
|
+
return !a.type.indexOf("key") && t._k(a.keyCode, "enter", 13, a.key, "Enter") ? null : t.query.apply(null, arguments);
|
|
636
|
+
} }, model: { value: t.queryParam.name, callback: function(a) {
|
|
637
|
+
t.$set(t.queryParam, "name", a);
|
|
638
|
+
}, expression: "queryParam.name" } }), s("div", { staticClass: "table-operator-search", on: { click: t.query } }, [s("i", { staticClass: "el-input__icon el-icon-search" })])], 1), s("div", { staticClass: "gd-table-operatorr" }, [s("gd-btn-list", { attrs: { sysViewButtons: t.sysViewButtons }, on: { functionName: t.doEvent } })], 1)])];
|
|
639
639
|
}, proxy: !0 } : null, { key: "defaulttext", fn: function({ row: a }) {
|
|
640
640
|
return [s("span", { staticClass: "active-color", staticStyle: { cursor: "pointer" }, on: { click: function(i) {
|
|
641
641
|
return t.$refs.editForm.init(a);
|
|
@@ -651,7 +651,7 @@ var N = function() {
|
|
|
651
651
|
K,
|
|
652
652
|
!1,
|
|
653
653
|
null,
|
|
654
|
-
"
|
|
654
|
+
"fe7e203c",
|
|
655
655
|
null,
|
|
656
656
|
null
|
|
657
657
|
);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const n=require("./system.promptmanagement.25e1639b.js"),o=require("./chartbi.c211f08d.js"),u=require("./messages.0e2d9d5a.js");const h={props:{openPermissions:{type:Boolean,default:!0},modalAppendToBody:{type:Boolean,default:!0},appendToBody:{type:Boolean,default:!0},tmtype:{type:String,default:""}},data(){return{visible:!1,mockData:[],targetKeys:[],translationDetail:{name:"",langs:[]},confirmLoading:!0,title:"",sysViewButtons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked"}],type:1,addData:null,fullScreen:!1,width:"800px",errInit:null,ruleFormData:{defaulttext:"",name:"",langs:"",type:"3",hintcatalogid:""},rules:{defaulttext:[{required:!0,message:this.$i18nt("gd.btn.input","\u8BF7\u8F93\u5165"),trigger:"change"}],name:[{required:!0,message:this.$i18nt("gd.btn.input","\u8BF7\u8F93\u5165"),trigger:"change"}]}}},computed:{},methods:{toggleFullscreen(){this.fullScreen=!this.fullScreen},changeText(e){let t=[...this.translationDetail.langs];t.map(s=>(s.description=s.languagecode.replace(/-/g,"_")==="zh_CN"?e:s.description,s)),this.translationDetail.langs=[...t]},changeLanguage(e,t){t.languagecode.replace(/-/g,"_")==="zh_CN"&&(this.ruleFormData.defaulttext=e)},init(e){this.fullScreen=!1,this.visible=!0,this.type=e?2:1,this.title=e?this.$i18nt("gd.https.edit"):this.$i18nt("gd.https.add"),this.openPermissions&&(this.sysViewButtons=this.sysViewButtons.map(t=>(t.name=e?"sysTranslation:edit":"sysTranslation:add",t))),e?(this.$nextTick(()=>{setTimeout(()=>{this.ruleFormData.defaulttext=e.defaulttext,this.ruleFormData.id=e.id,this.ruleFormData.name=e.name,this.ruleFormData.hintcatalogid=e.hintcatalogid,this.ruleFormData.type=e.type.toString()},0)}),this.sysTranslationDetail(e.id)):(this.getAllLanguage(),this.tmtype==="translationManagement"&&(this.ruleFormData.type="2"))},editInit(e){if(this.confirmLoading=!0,this.title=this.$i18nt("gd.https.edit"),this.visible=!0,this.openPermissions&&(this.sysViewButtons=this.sysViewButtons.map(t=>(t.name="sysTranslation:edit",t))),!e||e.key===""){this.init(null);return}n.sysTranslationPage({name:e.key}).then(t=>{if(t.code==200){let s=t.data.rows[0],a=e.list.filter(i=>i.code.replace(/-/g,"_")==="zh_CN")[0];s!==void 0&&s.defaulttext===""&&(s=Object.assign(s,{defaulttext:a.val})),s!==void 0?this.init(s):(this.ruleFormData=Object.assign(this.ruleFormData,{defaulttext:e.list[0]?e.list[0].val:"",name:e.key}),this.addData=e.list.length>0?{langs:e.list}:null,this.init(null),this.errInit=e.key,this.$emit("err",e.transKey),this.$message.error(this.$i18nt("gd.translation.errTip","\u6570\u636E\u9519\u8BEF\uFF0C\u8BF7\u91CD\u65B0\u6DFB\u52A0\uFF01")))}})},addInit(e){if(e===""){this.init(null);return}let t=JSON.parse(e);this.addData=t,this.init(null),this.$nextTick(()=>{setTimeout(()=>{this.ruleFormData.defaulttext=t.langs[0].val,this.ruleFormData.name=this.errInit?this.errInit:t.name},0)})},add(e){this.confirmLoading=!0,delete e.id,n.sysTranslationAdd(e).then(t=>{t.success?(this.$message.success(this.$i18nt("gd.https.addSucc","\u65B0\u589E\u6210\u529F")),this.$emit("ok",e),this.handleCancel()):this.$message.error(this.$i18nt("gd.https.addFail","\u65B0\u589E\u5931\u8D25: ")+t.message)}).finally(t=>{this.confirmLoading=!1})},edit(e){this.confirmLoading=!0,n.sysTranslationEdit(e).then(t=>{t.success?(this.$message.success(this.$i18nt("gd.https.editSucc","\u7F16\u8F91\u6210\u529F")),this.$emit("ok",e),this.handleCancel()):this.$message.error(this.$i18nt("gd.https.editFail","\u7F16\u8F91\u5931\u8D25: ")+t.message)}).finally(t=>{this.confirmLoading=!1})},getAllLanguage(){this.confirmLoading=!0,n.GetAllLanguage().then(e=>{let t=e.data;this.addData&&t.map(s=>{let a=this.addData.langs.filter(i=>i.code==s.languagecode)[0];return s.languagecode=s.languagecode.replace(/-/g,"_"),s.description=a===void 0?"":a.val,s}),this.translationDetail.langs=t,this.confirmLoading=!1})},sysTranslationDetail(e){this.confirmLoading=!0,n.sysTranslationDetail({id:e}).then(t=>{let s=t.data&&t.data.langs?t.data.langs:[];s.map(a=>(a.languagecode=a.languagecode.replace(/-/g,"_"),a)),this.translationDetail=Object.assign(t.data,{langs:s}),this.confirmLoading=!1})},filterOption(e,t){return t.description.indexOf(e)>-1},handleChange(e,t,s){this.targetKeys=e},handleSubmit(){this.$refs.ruleForm.validate(e=>{if(e){const t={...this.ruleFormData,langs:this.translationDetail.langs||[],name:this.ruleFormData.name||this.translationDetail.name};this.type==1?this.add(t):this.edit(t)}})},getDictionary(e){return this.$options.filters.dictData(e)},handleCancel(){this.visible=!1,this.confirmLoading=!1,this.$refs.ruleForm.resetFields(),this.ruleFormData={defaulttext:"",name:"",langs:"",id:"",type:"",hintcatalogid:""},this.translationDetail={name:"",langs:[]},this.addData=null,this.errInit=null,this.$emit("closed")},doEvent(e){let t=e.item.functionName;this[t]&&this[t]()}}};var m=function(){var t=this,s=t._self._c;return s("el-dialog",{class:t.fullScreen?"gd-dialog":"gd-dialog gd-dialog-fangda",attrs:{width:t.width,visible:t.visible,fullscreen:t.fullScreen,footer:null,top:"80px","modal-append-to-body":t.modalAppendToBody,"append-to-body":t.appendToBody,"show-close":!1},on:{"update:visible":function(a){t.visible=a},closed:t.handleCancel}},[s("gd-modal-title",{attrs:{slot:"title",title:t.title,fullscreen:t.fullScreen,buttons:t.sysViewButtons,confirmLoading:t.confirmLoading,showClose:!0,closed:"handleCancel"},on:{changeEvent:t.doEvent,toggleFullscreen:t.toggleFullscreen},slot:"title"}),s("div",{directives:[{name:"loading",rawName:"v-loading",value:t.confirmLoading,expression:"confirmLoading"}]},[s("div",{class:t.fullScreen?"modal-bodyq":"modal-body"},[s("el-form",{ref:"ruleForm",attrs:{rules:t.rules,model:t.ruleFormData,"label-width":"160px"},nativeOn:{submit:function(a){a.preventDefault()}}},[s("el-form-item",{staticStyle:{"margin-bottom":"12px"},attrs:{prop:"defaulttext"},scopedSlots:t._u([{key:"label",fn:function(){return[t._v(" "+t._s(t.$i18nt("gd.translation.value"))+"\xA0 "),s("el-tooltip",{attrs:{content:t.$i18nt("gd.translation.valueTip"),placement:"top"}},[s("i",{staticClass:"el-icon-question"})])]},proxy:!0}])},[s("el-input",{attrs:{placeholder:t.$i18nt("gd.placeholder.input","\u8BF7\u8F93\u5165"),disabled:t.type!=1},on:{input:t.changeText},model:{value:t.ruleFormData.defaulttext,callback:function(a){t.$set(t.ruleFormData,"defaulttext",a)},expression:"ruleFormData.defaulttext"}})],1),s("el-form-item",{staticStyle:{"margin-bottom":"12px"},attrs:{prop:"name"},scopedSlots:t._u([{key:"label",fn:function(){return[t._v(" "+t._s(t.$i18nt("gd.translation.key"))+"\xA0 "),s("el-tooltip",{attrs:{content:t.$i18nt("gd.translation.keyTip"),placement:"top"}},[s("i",{staticClass:"el-icon-question"})])]},proxy:!0}])},[s("el-input",{attrs:{placeholder:t.$i18nt("gd.placeholder.input","\u8BF7\u8F93\u5165"),disabled:t.type!=1},model:{value:t.ruleFormData.name,callback:function(a){t.$set(t.ruleFormData,"name",a)},expression:"ruleFormData.name"}})],1),t.tmtype==="translationManagement"?s("el-form-item",{staticStyle:{"margin-bottom":"12px"},attrs:{prop:"type"},scopedSlots:t._u([{key:"label",fn:function(){return[t._v(t._s(t.$i18nt("gd.translation.type"))+"\xA0")]},proxy:!0}],null,!1,1857044530)},[s("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:t.$i18nt("gd.placeholder.select","\u8BF7\u9009\u62E9"),filterable:"","collapse-tags":""},model:{value:t.ruleFormData.type,callback:function(a){t.$set(t.ruleFormData,"type",a)},expression:"ruleFormData.type"}},t._l(t.getDictionary("translation_type"),function(a){return s("el-option",{key:a.code,attrs:{label:t.$i18nt(`Dynamics.${a.transkey}`,a.name),value:a.code}},[s("span",[t._v(t._s(t.$i18nt(`Dynamics.${a.transkey}`,a.name)))])])}),1)],1):t._e(),s("el-divider",{attrs:{dashed:""}}),t._l(this.translationDetail.langs,function(a){return[s("el-form-item",{staticStyle:{"margin-bottom":"12px"},attrs:{label:a.languagename}},[s("el-input",{attrs:{placeholder:t.$i18nt("gd.placeholder.input","\u8BF7\u8F93\u5165"),type:"textarea",autosize:""},on:{input:function(i){return t.changeLanguage(i,a)}},model:{value:a.description,callback:function(i){t.$set(a,"description",i)},expression:"item.description"}})],1)]})],2)],1)])],1)},g=[],p=o.normalizeComponent(h,m,g,!1,null,"7c4bdf77",null,null);const c=p.exports;const f={data(){return{visible:!1,solutionId:"",sysViewButtons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"save",icon:"el-icon-document-checked"}],confirmLoading:!1,type:1,record:{},advanced:!1,fullScreen:!1,width:"800px",fileList:[]}},computed:{title(){return this.$i18nt("gd.web.selectFile")}},methods:{handleRemove(e){const t=this.fileList.indexOf(e),s=this.fileList.slice();s.splice(t,1),this.fileList=s},beforeUpload(e){return this.fileList=[e],!1},toggleFullscreen(){this.fullScreen=!this.fullScreen},open(e){this.fileList=[],this.fullScreen=!1,this.visible=!0},handleSubmit(){this.confirmLoading=!0;let e=new FormData;e.append("file",this.fileList[0]),u.sysFileUpload(e).then(t=>{t.code==200?this.translationImport(t):(this.confirmLoading=!1,this.$message.error(t.message))}).catch(t=>{this.$message.error("\u670D\u52A1\u5668\u9519\u8BEF\uFF0C\u8BF7\u91CD\u8BD5"),this.confirmLoading=!1})},translationImport(e){let t={fileId:e.data};n.sysTranslationImport(t).then(s=>{this.confirmLoading=!1,s.success?(this.closed(),this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.$emit("ok")):this.$message.error(s.message)})},closed(){this.selectedRowKeys=[],this.visible=!1},doEvent(e){let t=e.item.functionName;this[t]&&this[t]()}}};var y=function(){var t=this,s=t._self._c;return s("el-dialog",{class:t.fullScreen?"gd-dialog":"gd-dialog gd-dialog-fangda",attrs:{width:t.width,visible:t.visible,fullscreen:t.fullScreen,footer:null,top:"80px","show-close":!1},on:{"update:visible":function(a){t.visible=a},cancel:t.closed}},[s("template",{slot:"title"},[s("gd-modal-title",{attrs:{title:t.title,confirmLoading:t.confirmLoading,visible:t.visible,fullscreen:t.fullScreen,buttons:t.sysViewButtons,showClose:!0},on:{changeEvent:t.doEvent}})],1),s("div",{directives:[{name:"loading",rawName:"v-loading",value:t.confirmLoading,expression:"confirmLoading"}]},[s("div",{class:t.fullScreen?"modal-bodyq":"modal-body"},[s("el-alert",{staticStyle:{"margin-bottom":"12px"},attrs:{title:t.$i18nt("gd.translation.importTip","\u9009\u62E9\u8981\u5BFC\u5165\u7684(.xlsx)\u6587\u4EF6"),type:"info","show-icon":"",closable:!1}}),s("el-row",{staticStyle:{"margin-left":"-12px","margin-right":"-12px"},attrs:{gutter:48}},[s("el-col",{attrs:{md:20,sm:24}},[s("el-upload",{ref:"upload",staticClass:"upload-demo",attrs:{action:"","file-list":t.fileList,remove:t.handleRemove,"before-upload":t.beforeUpload,accept:".xlsx"}},[s("el-button",{attrs:{id:"upload"}},[s("i",{staticClass:"el-icon-upload2"}),t._v(" "+t._s(t.$i18nt("gd.web.selectFile","\u9009\u62E9\u6587\u4EF6"))+" ")])],1)],1)],1)],1)])],2)},b=[],_=o.normalizeComponent(f,y,b,!1,null,"cffd8852",null,null);const $=_.exports;const v={props:{height:{type:Number,default:100}},name:"GdTranslationList",components:{editForm:c,timport:$},data(){return{sysViewButtons:[{displayName:"\u521D\u59CB\u5316\u7FFB\u8BD1",functionName:"initialize",show:!0,transKey:"gd.translation.initialize",icon:"el-icon-refresh",btnType:"danger",name:"sysTranslation:initialize"},{displayName:"\u65B0\u589E",functionName:"add",show:!0,transKey:"gd.btn.add",icon:"el-icon-plus",name:"sysTranslation:add"},{displayName:"\u7F16\u8F91",functionName:"editForm",show:!0,transKey:"gd.btn.edit",icon:"el-icon-edit",name:"sysTranslation:edit"},{displayName:"\u5220\u9664",functionName:"del",show:!0,transKey:"gd.btn.del",icon:"el-icon-delete",btnType:"danger",name:"sysTranslation:delete"},{displayName:"\u5BFC\u5165",functionName:"transimport",show:!0,transKey:"gd.btn.import",icon:"gd-icon-daoru1",name:"sysTranslation:import"},{displayName:"\u5BFC\u51FA",functionName:"transexport",show:!0,transKey:"gd.btn.export",icon:"gd-icon-daoru",name:"sysTranslation:export"},{displayName:"\u53D1\u5E03",functionName:"release",show:!0,transKey:"gd.btn.release",icon:"gd-icon-fabu1",btnType:"danger",name:"sysTranslation:release"}],advanced:!1,queryParam:{},columns:[{type:"selection",width:"60",fixed:!0},{label:"\u7FFB\u8BD1\u503C(value)",prop:"defaulttext",align:"left",type:"slot",slotType:"defaulttext",transKey:"gd.translation.value",width:"260"},{label:"\u5BF9\u5E94\u503C(key)",prop:"name",transKey:"gd.translation.key",align:"left",width:"360"},{label:"\u7C7B\u578B",prop:"type",type:"slot",slotType:"type",align:"left",transKey:"gd.translation.type",width:"160"},{label:"\u72B6\u6001",prop:"statecodes",type:"slot",slotType:"statecodes",align:"left",transKey:"gd.translation.stateCodes",width:"160"},{label:"\u521B\u5EFA\u65F6\u95F4",prop:"createdtime",align:"center",transKey:"gd.web.creationTime",width:"160"}],loadData:e=>n.sysTranslationPage(Object.assign(e,this.queryParam)).then(t=>t.data),selectedRowKeys:[],selectedRows:[],state:!1,quickQuery:!0,seeQuerys:!1}},computed:{stylew(){return this.seeQuerys?"width: calc(100% - 356px);":""},y(){let e=this.getBntnShow?0:38,t=this.quickQuery?4:0;return this.screenHeight-232-t+e},getBntnShow(){let e=this.sysViewButtons.filter(t=>t.name&&this.$hasPerm(t.name));return this.crumbsState?!0:e.length>0},getBootTrans(){return this.$bootTrans==null?!1:this.$bootTrans},getHeight(){return this.height},...o.mapGetters(["tableSize","tablePageSize","screenHeight","multiTab","crumbsState"])},methods:{changeWid(e){this.seeQuerys=e},reset(){this.queryParam={}},query(){this.$refs.table.refresh(!0)},release(){let e=this;this.$confirm(this.$i18nt("gd.https.releaseContent","\u786E\u8BA4\u53D1\u5E03?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.releaseOk","\u7ACB\u5373\u53D1\u5E03"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(t,s,a)=>{a(),t==="confirm"&&(s.confirmButtonLoading=!0,s.cancelButtonLoading=!0,s.showCancelButton=!1,n.deployTranslation().then(i=>{a(),s.confirmButtonLoading=!1,s.cancelButtonLoading=!1,s.showCancelButton=!0,i.success?(e.$message.success(e.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),e.handleOk()):e.$message.error(e.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+i.message)}).catch(i=>{e.$message.error(e.$i18nt("gd.error.error")+i.message)}))}})},getPopupContainer(e){return e.parentElement},cache(){this.formLoading=!0,n.sysTranslationCache().then(e=>{e.success?this.$message.success(this.$i18nt("gd.https.operateSucc")):this.$message.error(this.$i18nt("gd.https.operateFail")+e.message),this.formLoading=!1})},transexport(){if(this.state)return;this.state=!0;const e=this.$message({message:this.$i18nt("gd.login.exporting","\u6B63\u5728\u5BFC\u51FA\u4E2D..."),duration:0,iconClass:"el-icon-loading"});n.sysTranslationExport({}).then(t=>{this.exportWay(t,e)}).catch(t=>{e.close(),this.$message.error("err!")})},exportWay(e,t){if(e){const s=new Blob([e.data],{type:"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"}),a=URL.createObjectURL(s),i=document.createElement("a");i.style.display="none",i.href=a;let d=new Date().getTime();i.download=`translation${d}`,i.click(),URL.revokeObjectURL(i.href),setTimeout(()=>{this.state=!1,t.close()},1e3)}else t.close(),setTimeout(()=>{this.statu=!1},1e3),this.$nextTick(()=>{setTimeout(()=>{this.$message.error(e.message)},0)})},transimport(){this.$refs.timport.open()},add(){this.$refs.editForm.init(null)},editForm(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne"));return}this.$refs.editForm.init(this.selectedRows[0])},del(){let e=this;if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.delTip"));return}this.$confirm(this.$i18nt("gd.https.delContent","\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.delOk","\u786E\u8BA4\u5220\u9664"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(t,s,a)=>{if(a(),t==="confirm")return new Promise((i,d)=>{n.sysTranslationDelete({ids:e.selectedRowKeys.join(",")}).then(l=>{l.success?(e.$message.success(e.$i18nt("gd.https.delSucc")),e.handleOk()):e.$message.error(e.$i18nt("gd.https.delFail")+l.message),i()}).catch(l=>{e.$message.error(e.$i18nt("gd.error.error")+l.message)})}).catch(()=>console.log("Oops errors!"))}})},initialize(){let e=this;this.$confirm(this.$i18nt("gd.https.initializeTip","\u662F\u5426\u521D\u59CB\u5316\u7FFB\u8BD1?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.translation.initializeOk","\u7ACB\u5373\u521D\u59CB\u5316"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(t,s,a)=>{if(a(),t==="confirm")return new Promise((i,d)=>{n.sysTranslationInit({}).then(l=>{l.success?(e.$message.success(e.$i18nt("gd.https.operateSucc")),e.handleOk()):e.$message.error(e.$i18nt("gd.https.operateFail")+l.message),i()}).catch(l=>{e.$message.error(e.$i18nt("gd.error.error")+l.message)})}).catch(()=>console.log("Oops errors!"))}})},handleOk(){this.$refs.table.refresh()},getDictionary(e){return this.$options.filters.dictData(e)},dictSwitch(e,t){let s=this.$options.filters.dictData(t).filter(a=>a.code==e)[0];return s!=null&&s.colour?s.colour:""},onSelectChange(e,t){this.selectedRowKeys=e,this.selectedRows=t},doEvent(e){let t=e.item.functionName;this[t]()}}};var w=function(){var t=this,s=t._self._c;return s("div",{staticClass:"gd-page-view"},[s("div",{staticClass:"page-view-list"},[s("gd-tables",{ref:"table",attrs:{height:t.getHeight,columns:t.columns,dataSource:t.loadData,selectedRowKeys:t.selectedRowKeys,size:t.tableSize,pageSize:t.tablePageSize,filtering:!1},on:{onChange:t.onSelectChange},scopedSlots:t._u([t.quickQuery?{key:"operator",fn:function(){return[s("div",{staticClass:"gd-table-operator"},[s("div",{staticClass:"gd-table-operatorl",staticStyle:{width:"300px","margin-right":"12px"}},[s("el-input",{staticClass:"table-operator-input",attrs:{placeholder:t.$i18nt("gd.translation.key"),clearable:""},nativeOn:{keyup:function(a){return!a.type.indexOf("key")&&t._k(a.keyCode,"enter",13,a.key,"Enter")?null:t.query.apply(null,arguments)}},model:{value:t.queryParam.name,callback:function(a){t.$set(t.queryParam,"name",a)},expression:"queryParam.name"}}),s("div",{staticClass:"table-operator-search",on:{click:t.query}},[s("i",{staticClass:"el-input__icon el-icon-search"})])],1),s("div",{staticClass:"gd-table-operatorl",staticStyle:{width:"300px"}},[s("el-input",{staticClass:"table-operator-input",attrs:{placeholder:t.$i18nt("gd.translation.value"),clearable:""},nativeOn:{keyup:function(a){return!a.type.indexOf("key")&&t._k(a.keyCode,"enter",13,a.key,"Enter")?null:t.query.apply(null,arguments)}},model:{value:t.queryParam.description,callback:function(a){t.$set(t.queryParam,"description",a)},expression:"queryParam.description"}}),s("div",{staticClass:"table-operator-search",on:{click:t.query}},[s("i",{staticClass:"el-input__icon el-icon-search"})])],1),s("div",{staticClass:"gd-table-operatorr"},[s("gd-btn-list",{attrs:{sysViewButtons:t.sysViewButtons},on:{functionName:t.doEvent}})],1)])]},proxy:!0}:null,{key:"defaulttext",fn:function({row:a}){return[s("span",{staticClass:"active-color",staticStyle:{cursor:"pointer"},on:{click:function(i){return t.$refs.editForm.init(a)}}},[t._v(" "+t._s(a.defaulttext)+" ")])]}},{key:"type",fn:function(a){return[t.dictSwitch(a.row.type,"translation_type")?s("el-tag",{attrs:{color:t.dictSwitch(a.row.type,"translation_type")}},[t._v(" "+t._s(t._f("dictType")("translation_type",a.row.type))+" ")]):s("span",[t._v(t._s(t._f("dictType")("translation_type",a.row.type)))])]}},{key:"statecodes",fn:function(a){return[t.dictSwitch(a.row.statecodes,"state_code")?s("el-tag",{attrs:{effect:"dark",color:t.dictSwitch(a.row.statecodes,"state_code")}},[t._v(" "+t._s(t._f("dictType")("state_code",a.row.statecodes))+" ")]):s("span",[t._v(t._s(t._f("dictType")("state_code",a.row.statecodes)))])]}}],null,!0)})],1),s("editForm",{ref:"editForm",attrs:{tmtype:"translationManagement",openPermissions:!0},on:{ok:t.handleOk}}),s("timport",{ref:"timport",on:{ok:t.handleOk}})],1)},x=[],k=o.normalizeComponent(v,w,x,!1,null,"1cf1d6f2",null,null);const r=k.exports;r.install=function(e){e.component(r.name,r)};exports.GDpackage=r;exports.editForm=c;
|
|
1
|
+
"use strict";const n=require("./system.promptmanagement.290958b1.js"),o=require("./chartbi.06e48153.js"),u=require("./messages.2fff74f3.js");const h={props:{openPermissions:{type:Boolean,default:!0},modalAppendToBody:{type:Boolean,default:!0},appendToBody:{type:Boolean,default:!0},tmtype:{type:String,default:""}},data(){return{visible:!1,mockData:[],targetKeys:[],translationDetail:{name:"",langs:[]},confirmLoading:!0,title:"",sysViewButtons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked"}],type:1,addData:null,fullScreen:!1,width:"800px",errInit:null,ruleFormData:{defaulttext:"",name:"",langs:"",type:"3",hintcatalogid:""},rules:{defaulttext:[{required:!0,message:this.$i18nt("gd.btn.input","\u8BF7\u8F93\u5165"),trigger:"change"}],name:[{required:!0,message:this.$i18nt("gd.btn.input","\u8BF7\u8F93\u5165"),trigger:"change"}]}}},computed:{},methods:{toggleFullscreen(){this.fullScreen=!this.fullScreen},changeText(e){let t=[...this.translationDetail.langs];t.map(s=>(s.description=s.languagecode.replace(/-/g,"_")==="zh_CN"?e:s.description,s)),this.translationDetail.langs=[...t]},changeLanguage(e,t){t.languagecode.replace(/-/g,"_")==="zh_CN"&&(this.ruleFormData.defaulttext=e)},init(e){this.fullScreen=!1,this.visible=!0,this.type=e?2:1,this.title=e?this.$i18nt("gd.https.edit"):this.$i18nt("gd.https.add"),this.openPermissions&&(this.sysViewButtons=this.sysViewButtons.map(t=>(t.name=e?"sysTranslation:edit":"sysTranslation:add",t))),e?(this.$nextTick(()=>{setTimeout(()=>{this.ruleFormData.defaulttext=e.defaulttext,this.ruleFormData.id=e.id,this.ruleFormData.name=e.name,this.ruleFormData.hintcatalogid=e.hintcatalogid,this.ruleFormData.type=e.type.toString()},0)}),this.sysTranslationDetail(e.id)):(this.getAllLanguage(),this.tmtype==="translationManagement"&&(this.ruleFormData.type="2"))},editInit(e){if(this.confirmLoading=!0,this.title=this.$i18nt("gd.https.edit"),this.visible=!0,this.openPermissions&&(this.sysViewButtons=this.sysViewButtons.map(t=>(t.name="sysTranslation:edit",t))),!e||e.key===""){this.init(null);return}n.sysTranslationPage({name:e.key}).then(t=>{if(t.code==200){let s=t.data.rows[0],a=e.list.filter(i=>i.code.replace(/-/g,"_")==="zh_CN")[0];s!==void 0&&s.defaulttext===""&&(s=Object.assign(s,{defaulttext:a.val})),s!==void 0?this.init(s):(this.ruleFormData=Object.assign(this.ruleFormData,{defaulttext:e.list[0]?e.list[0].val:"",name:e.key}),this.addData=e.list.length>0?{langs:e.list}:null,this.init(null),this.errInit=e.key,this.$emit("err",e.transKey),this.$message.error(this.$i18nt("gd.translation.errTip","\u6570\u636E\u9519\u8BEF\uFF0C\u8BF7\u91CD\u65B0\u6DFB\u52A0\uFF01")))}})},addInit(e){if(e===""){this.init(null);return}let t=JSON.parse(e);this.addData=t,this.init(null),this.$nextTick(()=>{setTimeout(()=>{this.ruleFormData.defaulttext=t.langs[0].val,this.ruleFormData.name=this.errInit?this.errInit:t.name},0)})},add(e){this.confirmLoading=!0,delete e.id,n.sysTranslationAdd(e).then(t=>{t.success?(this.$message.success(this.$i18nt("gd.https.addSucc","\u65B0\u589E\u6210\u529F")),this.$emit("ok",e),this.handleCancel()):this.$message.error(this.$i18nt("gd.https.addFail","\u65B0\u589E\u5931\u8D25: ")+t.message)}).finally(t=>{this.confirmLoading=!1})},edit(e){this.confirmLoading=!0,n.sysTranslationEdit(e).then(t=>{t.success?(this.$message.success(this.$i18nt("gd.https.editSucc","\u7F16\u8F91\u6210\u529F")),this.$emit("ok",e),this.handleCancel()):this.$message.error(this.$i18nt("gd.https.editFail","\u7F16\u8F91\u5931\u8D25: ")+t.message)}).finally(t=>{this.confirmLoading=!1})},getAllLanguage(){this.confirmLoading=!0,n.GetAllLanguage().then(e=>{let t=e.data;this.addData&&t.map(s=>{let a=this.addData.langs.filter(i=>i.code==s.languagecode)[0];return s.languagecode=s.languagecode.replace(/-/g,"_"),s.description=a===void 0?"":a.val,s}),this.translationDetail.langs=t,this.confirmLoading=!1})},sysTranslationDetail(e){this.confirmLoading=!0,n.sysTranslationDetail({id:e}).then(t=>{let s=t.data&&t.data.langs?t.data.langs:[];s.map(a=>(a.languagecode=a.languagecode.replace(/-/g,"_"),a)),this.translationDetail=Object.assign(t.data,{langs:s}),this.confirmLoading=!1})},filterOption(e,t){return t.description.indexOf(e)>-1},handleChange(e,t,s){this.targetKeys=e},handleSubmit(){this.$refs.ruleForm.validate(e=>{if(e){const t={...this.ruleFormData,langs:this.translationDetail.langs||[],name:this.ruleFormData.name||this.translationDetail.name};this.type==1?this.add(t):this.edit(t)}})},getDictionary(e){return this.$options.filters.dictData(e)},handleCancel(){this.visible=!1,this.confirmLoading=!1,this.$refs.ruleForm.resetFields(),this.ruleFormData={defaulttext:"",name:"",langs:"",id:"",type:"",hintcatalogid:""},this.translationDetail={name:"",langs:[]},this.addData=null,this.errInit=null,this.$emit("closed")},doEvent(e){let t=e.item.functionName;this[t]&&this[t]()}}};var m=function(){var t=this,s=t._self._c;return s("el-dialog",{class:t.fullScreen?"gd-dialog":"gd-dialog gd-dialog-fangda",attrs:{width:t.width,visible:t.visible,fullscreen:t.fullScreen,footer:null,top:"80px","modal-append-to-body":t.modalAppendToBody,"append-to-body":t.appendToBody,"show-close":!1},on:{"update:visible":function(a){t.visible=a},closed:t.handleCancel}},[s("gd-modal-title",{attrs:{slot:"title",title:t.title,fullscreen:t.fullScreen,buttons:t.sysViewButtons,confirmLoading:t.confirmLoading,showClose:!0,closed:"handleCancel"},on:{changeEvent:t.doEvent,toggleFullscreen:t.toggleFullscreen},slot:"title"}),s("div",{directives:[{name:"loading",rawName:"v-loading",value:t.confirmLoading,expression:"confirmLoading"}]},[s("div",{class:t.fullScreen?"modal-bodyq":"modal-body"},[s("el-form",{ref:"ruleForm",attrs:{rules:t.rules,model:t.ruleFormData,"label-width":"160px"},nativeOn:{submit:function(a){a.preventDefault()}}},[s("el-form-item",{staticStyle:{"margin-bottom":"12px"},attrs:{prop:"defaulttext"},scopedSlots:t._u([{key:"label",fn:function(){return[t._v(" "+t._s(t.$i18nt("gd.translation.value"))+"\xA0 "),s("el-tooltip",{attrs:{content:t.$i18nt("gd.translation.valueTip"),placement:"top"}},[s("i",{staticClass:"el-icon-question"})])]},proxy:!0}])},[s("el-input",{attrs:{placeholder:t.$i18nt("gd.placeholder.input","\u8BF7\u8F93\u5165"),disabled:t.type!=1},on:{input:t.changeText},model:{value:t.ruleFormData.defaulttext,callback:function(a){t.$set(t.ruleFormData,"defaulttext",a)},expression:"ruleFormData.defaulttext"}})],1),s("el-form-item",{staticStyle:{"margin-bottom":"12px"},attrs:{prop:"name"},scopedSlots:t._u([{key:"label",fn:function(){return[t._v(" "+t._s(t.$i18nt("gd.translation.key"))+"\xA0 "),s("el-tooltip",{attrs:{content:t.$i18nt("gd.translation.keyTip"),placement:"top"}},[s("i",{staticClass:"el-icon-question"})])]},proxy:!0}])},[s("el-input",{attrs:{placeholder:t.$i18nt("gd.placeholder.input","\u8BF7\u8F93\u5165"),disabled:t.type!=1},model:{value:t.ruleFormData.name,callback:function(a){t.$set(t.ruleFormData,"name",a)},expression:"ruleFormData.name"}})],1),t.tmtype==="translationManagement"?s("el-form-item",{staticStyle:{"margin-bottom":"12px"},attrs:{prop:"type"},scopedSlots:t._u([{key:"label",fn:function(){return[t._v(t._s(t.$i18nt("gd.translation.type"))+"\xA0")]},proxy:!0}],null,!1,1857044530)},[s("el-select",{staticStyle:{width:"100%"},attrs:{placeholder:t.$i18nt("gd.placeholder.select","\u8BF7\u9009\u62E9"),filterable:"","collapse-tags":""},model:{value:t.ruleFormData.type,callback:function(a){t.$set(t.ruleFormData,"type",a)},expression:"ruleFormData.type"}},t._l(t.getDictionary("translation_type"),function(a){return s("el-option",{key:a.code,attrs:{label:t.$i18nt(`Dynamics.${a.transkey}`,a.name),value:a.code}},[s("span",[t._v(t._s(t.$i18nt(`Dynamics.${a.transkey}`,a.name)))])])}),1)],1):t._e(),s("el-divider",{attrs:{dashed:""}}),t._l(this.translationDetail.langs,function(a){return[s("el-form-item",{staticStyle:{"margin-bottom":"12px"},attrs:{label:a.languagename}},[s("el-input",{attrs:{placeholder:t.$i18nt("gd.placeholder.input","\u8BF7\u8F93\u5165"),type:"textarea",autosize:""},on:{input:function(i){return t.changeLanguage(i,a)}},model:{value:a.description,callback:function(i){t.$set(a,"description",i)},expression:"item.description"}})],1)]})],2)],1)])],1)},g=[],p=o.normalizeComponent(h,m,g,!1,null,"98493209",null,null);const c=p.exports;const f={data(){return{visible:!1,solutionId:"",sysViewButtons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"save",icon:"el-icon-document-checked"}],confirmLoading:!1,type:1,record:{},advanced:!1,fullScreen:!1,width:"800px",fileList:[]}},computed:{title(){return this.$i18nt("gd.web.selectFile")}},methods:{handleRemove(e){const t=this.fileList.indexOf(e),s=this.fileList.slice();s.splice(t,1),this.fileList=s},beforeUpload(e){return this.fileList=[e],!1},toggleFullscreen(){this.fullScreen=!this.fullScreen},open(e){this.fileList=[],this.fullScreen=!1,this.visible=!0},handleSubmit(){this.confirmLoading=!0;let e=new FormData;e.append("file",this.fileList[0]),u.sysFileUpload(e).then(t=>{t.code==200?this.translationImport(t):(this.confirmLoading=!1,this.$message.error(t.message))}).catch(t=>{this.$message.error("\u670D\u52A1\u5668\u9519\u8BEF\uFF0C\u8BF7\u91CD\u8BD5"),this.confirmLoading=!1})},translationImport(e){let t={fileId:e.data};n.sysTranslationImport(t).then(s=>{this.confirmLoading=!1,s.success?(this.closed(),this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.$emit("ok")):this.$message.error(s.message)})},closed(){this.selectedRowKeys=[],this.visible=!1},doEvent(e){let t=e.item.functionName;this[t]&&this[t]()}}};var y=function(){var t=this,s=t._self._c;return s("el-dialog",{class:t.fullScreen?"gd-dialog":"gd-dialog gd-dialog-fangda",attrs:{width:t.width,visible:t.visible,fullscreen:t.fullScreen,footer:null,top:"80px","show-close":!1},on:{"update:visible":function(a){t.visible=a},cancel:t.closed}},[s("template",{slot:"title"},[s("gd-modal-title",{attrs:{title:t.title,confirmLoading:t.confirmLoading,visible:t.visible,fullscreen:t.fullScreen,buttons:t.sysViewButtons,showClose:!0},on:{changeEvent:t.doEvent}})],1),s("div",{directives:[{name:"loading",rawName:"v-loading",value:t.confirmLoading,expression:"confirmLoading"}]},[s("div",{class:t.fullScreen?"modal-bodyq":"modal-body"},[s("el-alert",{staticStyle:{"margin-bottom":"12px"},attrs:{title:t.$i18nt("gd.translation.importTip","\u9009\u62E9\u8981\u5BFC\u5165\u7684(.xlsx)\u6587\u4EF6"),type:"info","show-icon":"",closable:!1}}),s("el-row",{staticStyle:{"margin-left":"-12px","margin-right":"-12px"},attrs:{gutter:48}},[s("el-col",{attrs:{md:20,sm:24}},[s("el-upload",{ref:"upload",staticClass:"upload-demo",attrs:{action:"","file-list":t.fileList,remove:t.handleRemove,"before-upload":t.beforeUpload,accept:".xlsx"}},[s("el-button",{attrs:{id:"upload"}},[s("i",{staticClass:"el-icon-upload2"}),t._v(" "+t._s(t.$i18nt("gd.web.selectFile","\u9009\u62E9\u6587\u4EF6"))+" ")])],1)],1)],1)],1)])],2)},_=[],b=o.normalizeComponent(f,y,_,!1,null,"4232173a",null,null);const $=b.exports;const v={props:{height:{type:Number,default:100}},name:"GdTranslationList",components:{editForm:c,timport:$},data(){return{sysViewButtons:[{displayName:"\u521D\u59CB\u5316\u7FFB\u8BD1",functionName:"initialize",show:!0,transKey:"gd.translation.initialize",icon:"el-icon-refresh",btnType:"danger",name:"sysTranslation:initialize"},{displayName:"\u65B0\u589E",functionName:"add",show:!0,transKey:"gd.btn.add",icon:"el-icon-plus",name:"sysTranslation:add"},{displayName:"\u7F16\u8F91",functionName:"editForm",show:!0,transKey:"gd.btn.edit",icon:"el-icon-edit",name:"sysTranslation:edit"},{displayName:"\u5220\u9664",functionName:"del",show:!0,transKey:"gd.btn.del",icon:"el-icon-delete",btnType:"danger",name:"sysTranslation:delete"},{displayName:"\u5BFC\u5165",functionName:"transimport",show:!0,transKey:"gd.btn.import",icon:"gd-icon-daoru1",name:"sysTranslation:import"},{displayName:"\u5BFC\u51FA",functionName:"transexport",show:!0,transKey:"gd.btn.export",icon:"gd-icon-daoru",name:"sysTranslation:export"},{displayName:"\u53D1\u5E03",functionName:"release",show:!0,transKey:"gd.btn.release",icon:"gd-icon-fabu1",btnType:"danger",name:"sysTranslation:release"}],advanced:!1,queryParam:{},columns:[{type:"selection",width:"60",fixed:!0},{label:"\u7FFB\u8BD1\u503C(value)",prop:"defaulttext",align:"left",type:"slot",slotType:"defaulttext",transKey:"gd.translation.value",width:"260"},{label:"\u5BF9\u5E94\u503C(key)",prop:"name",transKey:"gd.translation.key",align:"left",width:"360"},{label:"\u7C7B\u578B",prop:"type",type:"slot",slotType:"type",align:"left",transKey:"gd.translation.type",width:"160"},{label:"\u72B6\u6001",prop:"statecodes",type:"slot",slotType:"statecodes",align:"left",transKey:"gd.translation.stateCodes",width:"160"},{label:"\u521B\u5EFA\u65F6\u95F4",prop:"createdtime",align:"center",transKey:"gd.web.creationTime",width:"160"}],loadData:e=>n.sysTranslationPage(Object.assign(e,this.queryParam)).then(t=>t.data),selectedRowKeys:[],selectedRows:[],state:!1,quickQuery:!0,seeQuerys:!1}},computed:{stylew(){return this.seeQuerys?"width: calc(100% - 356px);":""},y(){let e=this.getBntnShow?0:38,t=this.quickQuery?4:0;return this.screenHeight-232-t+e},getBntnShow(){let e=this.sysViewButtons.filter(t=>t.name&&this.$hasPerm(t.name));return this.crumbsState?!0:e.length>0},getBootTrans(){return this.$bootTrans==null?!1:this.$bootTrans},getHeight(){return this.height},...o.mapGetters(["tableSize","tablePageSize","screenHeight","multiTab","crumbsState"])},methods:{changeWid(e){this.seeQuerys=e},reset(){this.queryParam={}},query(){this.$refs.table.refresh(!0)},release(){let e=this;this.$confirm(this.$i18nt("gd.https.releaseContent","\u786E\u8BA4\u53D1\u5E03?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.releaseOk","\u7ACB\u5373\u53D1\u5E03"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(t,s,a)=>{a(),t==="confirm"&&(s.confirmButtonLoading=!0,s.cancelButtonLoading=!0,s.showCancelButton=!1,n.deployTranslation().then(i=>{a(),s.confirmButtonLoading=!1,s.cancelButtonLoading=!1,s.showCancelButton=!0,i.success?(e.$message.success(e.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),e.handleOk()):e.$message.error(e.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+i.message)}).catch(i=>{e.$message.error(e.$i18nt("gd.error.error")+i.message)}))}})},getPopupContainer(e){return e.parentElement},cache(){this.formLoading=!0,n.sysTranslationCache().then(e=>{e.success?this.$message.success(this.$i18nt("gd.https.operateSucc")):this.$message.error(this.$i18nt("gd.https.operateFail")+e.message),this.formLoading=!1})},transexport(){if(this.state)return;this.state=!0;const e=this.$message({message:this.$i18nt("gd.login.exporting","\u6B63\u5728\u5BFC\u51FA\u4E2D..."),duration:0,iconClass:"el-icon-loading"});n.sysTranslationExport({}).then(t=>{this.exportWay(t,e)}).catch(t=>{e.close(),this.$message.error("err!")})},exportWay(e,t){if(e){const s=new Blob([e.data],{type:"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet"}),a=URL.createObjectURL(s),i=document.createElement("a");i.style.display="none",i.href=a;let d=new Date().getTime();i.download=`translation${d}`,i.click(),URL.revokeObjectURL(i.href),setTimeout(()=>{this.state=!1,t.close()},1e3)}else t.close(),setTimeout(()=>{this.statu=!1},1e3),this.$nextTick(()=>{setTimeout(()=>{this.$message.error(e.message)},0)})},transimport(){this.$refs.timport.open()},add(){this.$refs.editForm.init(null)},editForm(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne"));return}this.$refs.editForm.init(this.selectedRows[0])},del(){let e=this;if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.delTip"));return}this.$confirm(this.$i18nt("gd.https.delContent","\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.delOk","\u786E\u8BA4\u5220\u9664"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(t,s,a)=>{if(a(),t==="confirm")return new Promise((i,d)=>{n.sysTranslationDelete({ids:e.selectedRowKeys.join(",")}).then(l=>{l.success?(e.$message.success(e.$i18nt("gd.https.delSucc")),e.handleOk()):e.$message.error(e.$i18nt("gd.https.delFail")+l.message),i()}).catch(l=>{e.$message.error(e.$i18nt("gd.error.error")+l.message)})}).catch(()=>console.log("Oops errors!"))}})},initialize(){let e=this;this.$confirm(this.$i18nt("gd.https.initializeTip","\u662F\u5426\u521D\u59CB\u5316\u7FFB\u8BD1?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.translation.initializeOk","\u7ACB\u5373\u521D\u59CB\u5316"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(t,s,a)=>{if(a(),t==="confirm")return new Promise((i,d)=>{n.sysTranslationInit({}).then(l=>{l.success?(e.$message.success(e.$i18nt("gd.https.operateSucc")),e.handleOk()):e.$message.error(e.$i18nt("gd.https.operateFail")+l.message),i()}).catch(l=>{e.$message.error(e.$i18nt("gd.error.error")+l.message)})}).catch(()=>console.log("Oops errors!"))}})},handleOk(){this.$refs.table.refresh()},getDictionary(e){return this.$options.filters.dictData(e)},dictSwitch(e,t){let s=this.$options.filters.dictData(t).filter(a=>a.code==e)[0];return s!=null&&s.colour?s.colour:""},onSelectChange(e,t){this.selectedRowKeys=e,this.selectedRows=t},doEvent(e){let t=e.item.functionName;this[t]()}}};var w=function(){var t=this,s=t._self._c;return s("div",{staticClass:"gd-page-view"},[s("div",{staticClass:"page-view-list"},[s("gd-tables",{ref:"table",attrs:{height:t.getHeight,columns:t.columns,dataSource:t.loadData,selectedRowKeys:t.selectedRowKeys,size:t.tableSize,pageSize:t.tablePageSize,filtering:!1},on:{onChange:t.onSelectChange},scopedSlots:t._u([t.quickQuery?{key:"operator",fn:function(){return[s("div",{staticClass:"gd-table-operator"},[s("div",{staticClass:"gd-table-operatorl",staticStyle:{width:"300px","margin-right":"12px"}},[s("el-input",{staticClass:"table-operator-input",attrs:{placeholder:t.$i18nt("gd.translation.value"),clearable:""},nativeOn:{keyup:function(a){return!a.type.indexOf("key")&&t._k(a.keyCode,"enter",13,a.key,"Enter")?null:t.query.apply(null,arguments)}},model:{value:t.queryParam.description,callback:function(a){t.$set(t.queryParam,"description",a)},expression:"queryParam.description"}}),s("div",{staticClass:"table-operator-search",on:{click:t.query}},[s("i",{staticClass:"el-input__icon el-icon-search"})])],1),s("div",{staticClass:"gd-table-operatorl",staticStyle:{width:"300px"}},[s("el-input",{staticClass:"table-operator-input",attrs:{placeholder:t.$i18nt("gd.translation.key"),clearable:""},nativeOn:{keyup:function(a){return!a.type.indexOf("key")&&t._k(a.keyCode,"enter",13,a.key,"Enter")?null:t.query.apply(null,arguments)}},model:{value:t.queryParam.name,callback:function(a){t.$set(t.queryParam,"name",a)},expression:"queryParam.name"}}),s("div",{staticClass:"table-operator-search",on:{click:t.query}},[s("i",{staticClass:"el-input__icon el-icon-search"})])],1),s("div",{staticClass:"gd-table-operatorr"},[s("gd-btn-list",{attrs:{sysViewButtons:t.sysViewButtons},on:{functionName:t.doEvent}})],1)])]},proxy:!0}:null,{key:"defaulttext",fn:function({row:a}){return[s("span",{staticClass:"active-color",staticStyle:{cursor:"pointer"},on:{click:function(i){return t.$refs.editForm.init(a)}}},[t._v(" "+t._s(a.defaulttext)+" ")])]}},{key:"type",fn:function(a){return[t.dictSwitch(a.row.type,"translation_type")?s("el-tag",{attrs:{color:t.dictSwitch(a.row.type,"translation_type")}},[t._v(" "+t._s(t._f("dictType")("translation_type",a.row.type))+" ")]):s("span",[t._v(t._s(t._f("dictType")("translation_type",a.row.type)))])]}},{key:"statecodes",fn:function(a){return[t.dictSwitch(a.row.statecodes,"state_code")?s("el-tag",{attrs:{effect:"dark",color:t.dictSwitch(a.row.statecodes,"state_code")}},[t._v(" "+t._s(t._f("dictType")("state_code",a.row.statecodes))+" ")]):s("span",[t._v(t._s(t._f("dictType")("state_code",a.row.statecodes)))])]}}],null,!0)})],1),s("editForm",{ref:"editForm",attrs:{tmtype:"translationManagement",openPermissions:!0},on:{ok:t.handleOk}}),s("timport",{ref:"timport",on:{ok:t.handleOk}})],1)},x=[],k=o.normalizeComponent(v,w,x,!1,null,"fe7e203c",null,null);const r=k.exports;r.install=function(e){e.component(r.name,r)};exports.GDpackage=r;exports.editForm=c;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { g as C } from "./system.org.
|
|
2
|
-
import { f as O, a as N, h as P, c as B, i as D, j as E, k as U, l as I, m as A, n as M, e as q, o as H, q as j, r as z, t as S } from "./system.account.
|
|
3
|
-
import { m as R, n as T } from "./chartbi.
|
|
4
|
-
import { t as G } from "./messages.
|
|
5
|
-
import { G as Q } from "./system.role.
|
|
1
|
+
import { g as C } from "./system.org.fcf96d1e.mjs";
|
|
2
|
+
import { f as O, a as N, h as P, c as B, i as D, j as E, k as U, l as I, m as A, n as M, e as q, o as H, q as j, r as z, t as S } from "./system.account.9bc40d08.mjs";
|
|
3
|
+
import { m as R, n as T } from "./chartbi.cdd1e365.mjs";
|
|
4
|
+
import { t as G } from "./messages.d8abe18d.mjs";
|
|
5
|
+
import { G as Q } from "./system.role.68de93ef.mjs";
|
|
6
6
|
const V = {
|
|
7
7
|
data() {
|
|
8
8
|
return {
|
|
@@ -78,7 +78,7 @@ var Y = function() {
|
|
|
78
78
|
J,
|
|
79
79
|
!1,
|
|
80
80
|
null,
|
|
81
|
-
"
|
|
81
|
+
"117b9c7a",
|
|
82
82
|
null,
|
|
83
83
|
null
|
|
84
84
|
);
|
|
@@ -194,7 +194,7 @@ var ee = function() {
|
|
|
194
194
|
te,
|
|
195
195
|
!1,
|
|
196
196
|
null,
|
|
197
|
-
"
|
|
197
|
+
"12675dc5",
|
|
198
198
|
null,
|
|
199
199
|
null
|
|
200
200
|
);
|
|
@@ -977,7 +977,7 @@ var ae = function() {
|
|
|
977
977
|
le,
|
|
978
978
|
!1,
|
|
979
979
|
null,
|
|
980
|
-
"
|
|
980
|
+
"b6f77ddd",
|
|
981
981
|
null,
|
|
982
982
|
null
|
|
983
983
|
);
|
|
@@ -1422,7 +1422,7 @@ var he = function() {
|
|
|
1422
1422
|
fe,
|
|
1423
1423
|
!1,
|
|
1424
1424
|
null,
|
|
1425
|
-
"
|
|
1425
|
+
"d1d24d5d",
|
|
1426
1426
|
null,
|
|
1427
1427
|
null
|
|
1428
1428
|
);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const C=require("./system.org.df5901a3.js"),w=require("./system.account.d3dd14ec.js"),T=require("./chartbi.c211f08d.js"),K=require("./messages.0e2d9d5a.js"),F=require("./system.role.656fa7cc.js");const O={data(){return{buttons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked"}],record:{},visible:!1,confirmLoading:!1,fullscreen:!1,width:"90%",selectedRowKeys:[],allRowData:[]}},components:{RoleForm:F.GDpackage},computed:{height(){return this.screenHeight-(this.fullscreen?160:340)},...T.mapGetters(["screenHeight"])},methods:{handleSubmit(){this.confirmLoading=!0;let i=[];i=this.allRowData.filter(t=>!this.selectedRowKeys.some(r=>r===t.id));const e=i.map(t=>t.id);w.sysUserChangeRole({id:this.record.id,addRoleIdList:this.selectedRowKeys,removeRoleIdList:e}).then(t=>{t.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.closed(),this.$emit("ok")):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+t.message),this.confirmLoading=!1})},open(i){this.confirmLoading=!0,this.record=i,this.visible=!0,w.sysUserOwnRole({id:i.id}).then(e=>{e.code===200&&(this.selectedRowKeys=e.data),this.$nextTick(()=>{setTimeout(()=>{this.$refs.roleForm.refresh()},0)}),this.confirmLoading=!1})},closed(){this.fullscreen=!1,this.visible=!1},toggleFullscreen(){this.fullscreen=!this.fullscreen},onSelectChange(i,e,t){this.selectedRowKeys=i,this.allRowData=t.rows},doEvent(i){const e=i.item.functionName;this[e]&&this[e]()}}};var N=function(){var e=this,t=e._self._c;return t("el-dialog",{directives:[{name:"drag",rawName:"v-drag"}],ref:"dialog",class:e.fullscreen?"gd-dialog gd-dialog-fangda":"gd-dialog",attrs:{fullscreen:e.fullscreen,visible:e.visible,width:e.width,center:!0,"close-on-click-modal":!1,"modal-append-to-body":!0,"append-to-body":!1,top:"80px","show-close":!1},on:{"update:visible":function(r){e.visible=r},closed:e.closed}},[t("template",{slot:"title"},[t("gd-modal-title",{attrs:{title:e.$i18nt("gd.btn.authorizationRole","\u6388\u6743\u89D2\u8272"),fullscreen:e.fullscreen,buttons:e.buttons,confirmLoading:e.confirmLoading,showClose:!0},on:{changeEvent:e.doEvent,toggleFullscreen:e.toggleFullscreen}})],1),t("div",{directives:[{name:"loading",rawName:"v-loading",value:e.confirmLoading,expression:"confirmLoading"}]},[e.visible?t("RoleForm",{ref:"roleForm",attrs:{height:e.height,openMode:"components",openSelecteKeys:e.selectedRowKeys},on:{onSelectChange:e.onSelectChange}}):e._e()],1)],2)},P=[],B=T.normalizeComponent(O,N,P,!1,null,"ff117c0e",null,null);const D=B.exports;const U={data(){return{buttons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked"}],record:{},showForm:!1,visible:!1,confirmLoading:!1,fullscreen:!1,width:"600px",orgTree:[],ruleFormData:{orgIded:"",orgId:""},rules:{orgId:[{required:!0,message:this.$i18nt("gd.btn.select","\u8BF7\u9009\u62E9"),trigger:"change"}]}}},methods:{save(){let i=this;this.$confirm(this.$i18nt("gd.https.orgOldNameTip","\u7528\u6237\u6240\u5C5E\u5386\u53F2\u6570\u636E\u673A\u6784\u4F1A\u66F4\u65B0,\u662F\u5426\u786E\u8BA4\u4FEE\u6539\u7528\u6237\u6240\u5C5E\u673A\u6784?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.saveOk","\u786E\u8BA4\u4FDD\u5B58"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(e,t,r)=>{if(e!=="confirm"){r();return}r(),w.changeUserBUJob({userId:i.record.id,newBusiUnitId:this.ruleFormData.orgId}).then(n=>{n.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.closed(),this.$emit("ok")):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+n.message),this.confirmLoading=!1})}})},handleSubmit(){this.confirmLoading=!0,this.$refs.ruleForm.validate(i=>{i?(this.confirmLoading=!1,this.save()):this.confirmLoading=!1})},open(i){this.confirmLoading=!0,this.record=i,this.visible=!0,this.showForm=!1,C.getOrgTree().then(e=>{const t=r=>(r=r.filter((n,s)=>(n.id===i.orgid&&(n.disabled=!0),n.children&&(n.children=t(n.children)),!0)),r);this.orgTree=t(e.data),this.ruleFormData={orgIded:i.orgid,orgId:""},this.showForm=!0,this.confirmLoading=!1,this.$nextTick(()=>{setTimeout(()=>{this.$refs.ruleForm.clearValidate()},0)})})},closed(){this.fullscreen=!1,this.visible=!1,this.$emit("closed")},toggleFullscreen(){this.fullscreen=!this.fullscreen},doEvent(i){const e=i.item.functionName;this[e]&&this[e]()}}};var I=function(){var e=this,t=e._self._c;return t("el-dialog",{directives:[{name:"drag",rawName:"v-drag"}],ref:"dialog",class:e.fullscreen?"gd-dialog gd-dialog-fangda":"gd-dialog",attrs:{fullscreen:e.fullscreen,visible:e.visible,width:e.width,center:!0,"close-on-click-modal":!1,"modal-append-to-body":!0,"append-to-body":!1,top:"80px","show-close":!1},on:{"update:visible":function(r){e.visible=r},closed:e.closed}},[t("template",{slot:"title"},[t("gd-modal-title",{attrs:{title:e.$i18nt("gd.btn.updateInstitutions","\u66F4\u65B0\u673A\u6784"),fullscreen:e.fullscreen,buttons:e.buttons,confirmLoading:e.confirmLoading,showClose:!0},on:{changeEvent:e.doEvent,toggleFullscreen:e.toggleFullscreen}})],1),t("div",{directives:[{name:"loading",rawName:"v-loading",value:e.confirmLoading,expression:"confirmLoading"}],staticStyle:{"min-height":"130px"}},[e.showForm?t("el-form",{ref:"ruleForm",attrs:{"label-width":"110px","label-position":"top",model:e.ruleFormData,size:"mini",rules:e.rules},nativeOn:{submit:function(r){r.preventDefault()}}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.user.orgOldName","\u539F\u673A\u6784\u540D\u79F0"),prop:"orgIded"}},[t("gd-select-tree",{attrs:{filterable:!0,"tree-options":e.orgTree,"default-value":e.ruleFormData.orgIded,placeholder:e.$i18nt("gd.placeholder.select","\u8BF7\u9009\u62E9"),disabled:!0},model:{value:e.ruleFormData.orgIded,callback:function(r){e.$set(e.ruleFormData,"orgIded",r)},expression:"ruleFormData.orgIded"}})],1),t("el-form-item",{attrs:{label:e.$i18nt("gd.user.organization","\u6240\u5C5E\u673A\u6784"),prop:"orgId"}},[t("gd-select-tree",{attrs:{filterable:!0,"tree-options":e.orgTree,placeholder:e.$i18nt("gd.placeholder.select","\u8BF7\u9009\u62E9")},model:{value:e.ruleFormData.orgId,callback:function(r){e.$set(e.ruleFormData,"orgId",r)},expression:"ruleFormData.orgId"}})],1)],1):e._e()],1)],2)},A=[],M=T.normalizeComponent(U,I,A,!1,null,"576f6840",null,null);const q=M.exports,j={data(){return{tableColumns:[{type:"selection",width:"60",fixed:!0},{transKey:"gd.user.account",prop:"account",label:"\u8D26\u53F7",width:"220",type:"slot",slotType:"account",align:"left",fixed:!0,showOverflowTooltip:!0},{transKey:"gd.user.name",prop:"name",label:"\u59D3\u540D",width:"160",align:"left",showOverflowTooltip:!0},{transKey:"gd.user.sex",prop:"gender",width:"120",label:"\u6027\u522B",type:"slot",slotType:"gender",align:"left",showOverflowTooltip:!0},{transKey:"gd.org.displayName",prop:"orgname",label:"\u673A\u6784\u540D\u79F0",width:"180",align:"left",showOverflowTooltip:!0},{transKey:"gd.user.phone",prop:"phone",width:"160",label:"\u624B\u673A",align:"left"},{transKey:"gd.user.status",prop:"statecodes",label:"\u72B6\u6001",width:"120",type:"slot",slotType:"statecodes",align:"center",dictTypeCode:"state_code",renderHeader:(i,...e)=>this.renderHeader(i,...e,{effectType:"checkbox",dictTypeCode:"state_code"})}],formColumns:[{transKey:"gd.user.account",effectType:"input",prop:"account",label:"\u8D26\u53F7",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change",min:2}]},{transKey:"gd.user.name",prop:"name",effectType:"input",label:"\u59D3\u540D",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.user.sex",prop:"gender",effectType:"radio",label:"\u6027\u522B",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",dictTypeCode:"gender",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.user.birthday",prop:"birthday",effectType:"date",label:"\u751F\u65E5",placeholder:"\u8BF7\u8F93\u5165",valueFormat:"yyyy-MM-dd",placeholderTransKey:"gd.placeholder.select",rules:[]},{transKey:"gd.user.phone",effectType:"input",prop:"phone",label:"\u624B\u673A\u53F7",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.user.email",effectType:"input",prop:"email",label:"\u90AE\u7BB1",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"},{type:"email",message:"\u8BF7\u8F93\u5165\u6B63\u786E\u7684\u90AE\u7BB1\u53F7!",transKey:"gd.account.emailTip"}]},{transKey:"gd.user.nickname",prop:"nickname",effectType:"input",label:"\u6635\u79F0",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[]},{transKey:"gd.user.tel",prop:"tel",effectType:"input",label:"\u7535\u8BDD",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[]},{transKey:"gd.org.displayName",prop:"orgid",effectType:"selectTree",label:"\u6240\u5C5E\u673A\u6784",placeholder:"\u8BF7\u9009\u62E9",placeholderTransKey:"gd.placeholder.select",treeOptions:[],rules:[{required:!0,message:"\u8BF7\u9009\u62E9",transKey:"gd.placeholder.select",trigger:"change"}]},{transKey:"gd.user.PSDNeverExpire",prop:"psdneverexpire",effectType:"switch",label:"\u5BC6\u7801\u6C38\u4E0D\u8FC7\u671F",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[]}],tableButtons:[{displayName:"\u65B0\u589E",functionName:"add",show:!0,transKey:"gd.btn.add",icon:"el-icon-plus",name:"sysUser:add"},{displayName:"\u7F16\u8F91",functionName:"edit",show:!0,transKey:"gd.btn.edit",icon:"el-icon-edit",name:"sysUser:edit"},{displayName:"\u66F4\u65B0\u673A\u6784",functionName:"updateInstitutions",show:!0,transKey:"gd.btn.updateInstitutions",icon:"el-icon-edit",name:"sysUser:updateInstitutions"},{displayName:"\u6388\u6743\u89D2\u8272",functionName:"userRole",show:!0,transKey:"gd.btn.authorizationRole",icon:"el-icon-edit",name:"sysUser:grantRole"},{displayName:"\u91CD\u7F6E\u5BC6\u7801",functionName:"resetPwd",show:!0,transKey:"gd.btn.resetPassword",icon:"el-icon-edit",btnType:"danger",name:"sysUser:resetPwd"},{displayName:"\u542F\u7528",functionName:"enable",show:!1,transKey:"gd.btn.enable",icon:"el-icon-video-play",name:"sysUser:changeStatus"},{displayName:"\u505C\u7528",functionName:"deactivated",show:!1,btnType:"danger",icon:"el-icon-discover",transKey:"gd.btn.deactivate",name:"sysUser:changeStatus"},{displayName:"\u5BFC\u5165",functionName:"importUser",show:!0,icon:"gd-icon-daoru1",transKey:"gd.btn.import",name:"sysUser:import"},{displayName:"\u5BFC\u51FA",functionName:"exportUser",show:!0,icon:"gd-icon-daoru",transKey:"gd.btn.export",name:"sysUser:export"}],formButtons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked",validate:!0}],tableQueries:[{transKey:"gd.user.status",prop:"stateCodes",label:"\u72B6\u6001",effectType:"checkbox",dictTypeCode:"state_code",selectType:"checkbox",rules:[]}]}}};var E={exports:{}};/*!
|
|
1
|
+
"use strict";const C=require("./system.org.5bb36f9c.js"),w=require("./system.account.8ea53681.js"),T=require("./chartbi.06e48153.js"),K=require("./messages.2fff74f3.js"),F=require("./system.role.88100f66.js");const O={data(){return{buttons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked"}],record:{},visible:!1,confirmLoading:!1,fullscreen:!1,width:"90%",selectedRowKeys:[],allRowData:[]}},components:{RoleForm:F.GDpackage},computed:{height(){return this.screenHeight-(this.fullscreen?160:340)},...T.mapGetters(["screenHeight"])},methods:{handleSubmit(){this.confirmLoading=!0;let i=[];i=this.allRowData.filter(t=>!this.selectedRowKeys.some(r=>r===t.id));const e=i.map(t=>t.id);w.sysUserChangeRole({id:this.record.id,addRoleIdList:this.selectedRowKeys,removeRoleIdList:e}).then(t=>{t.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.closed(),this.$emit("ok")):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+t.message),this.confirmLoading=!1})},open(i){this.confirmLoading=!0,this.record=i,this.visible=!0,w.sysUserOwnRole({id:i.id}).then(e=>{e.code===200&&(this.selectedRowKeys=e.data),this.$nextTick(()=>{setTimeout(()=>{this.$refs.roleForm.refresh()},0)}),this.confirmLoading=!1})},closed(){this.fullscreen=!1,this.visible=!1},toggleFullscreen(){this.fullscreen=!this.fullscreen},onSelectChange(i,e,t){this.selectedRowKeys=i,this.allRowData=t.rows},doEvent(i){const e=i.item.functionName;this[e]&&this[e]()}}};var N=function(){var e=this,t=e._self._c;return t("el-dialog",{directives:[{name:"drag",rawName:"v-drag"}],ref:"dialog",class:e.fullscreen?"gd-dialog gd-dialog-fangda":"gd-dialog",attrs:{fullscreen:e.fullscreen,visible:e.visible,width:e.width,center:!0,"close-on-click-modal":!1,"modal-append-to-body":!0,"append-to-body":!1,top:"80px","show-close":!1},on:{"update:visible":function(r){e.visible=r},closed:e.closed}},[t("template",{slot:"title"},[t("gd-modal-title",{attrs:{title:e.$i18nt("gd.btn.authorizationRole","\u6388\u6743\u89D2\u8272"),fullscreen:e.fullscreen,buttons:e.buttons,confirmLoading:e.confirmLoading,showClose:!0},on:{changeEvent:e.doEvent,toggleFullscreen:e.toggleFullscreen}})],1),t("div",{directives:[{name:"loading",rawName:"v-loading",value:e.confirmLoading,expression:"confirmLoading"}]},[e.visible?t("RoleForm",{ref:"roleForm",attrs:{height:e.height,openMode:"components",openSelecteKeys:e.selectedRowKeys},on:{onSelectChange:e.onSelectChange}}):e._e()],1)],2)},P=[],B=T.normalizeComponent(O,N,P,!1,null,"117b9c7a",null,null);const D=B.exports;const U={data(){return{buttons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked"}],record:{},showForm:!1,visible:!1,confirmLoading:!1,fullscreen:!1,width:"600px",orgTree:[],ruleFormData:{orgIded:"",orgId:""},rules:{orgId:[{required:!0,message:this.$i18nt("gd.btn.select","\u8BF7\u9009\u62E9"),trigger:"change"}]}}},methods:{save(){let i=this;this.$confirm(this.$i18nt("gd.https.orgOldNameTip","\u7528\u6237\u6240\u5C5E\u5386\u53F2\u6570\u636E\u673A\u6784\u4F1A\u66F4\u65B0,\u662F\u5426\u786E\u8BA4\u4FEE\u6539\u7528\u6237\u6240\u5C5E\u673A\u6784?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.saveOk","\u786E\u8BA4\u4FDD\u5B58"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(e,t,r)=>{if(e!=="confirm"){r();return}r(),w.changeUserBUJob({userId:i.record.id,newBusiUnitId:this.ruleFormData.orgId}).then(n=>{n.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.closed(),this.$emit("ok")):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+n.message),this.confirmLoading=!1})}})},handleSubmit(){this.confirmLoading=!0,this.$refs.ruleForm.validate(i=>{i?(this.confirmLoading=!1,this.save()):this.confirmLoading=!1})},open(i){this.confirmLoading=!0,this.record=i,this.visible=!0,this.showForm=!1,C.getOrgTree().then(e=>{const t=r=>(r=r.filter((n,s)=>(n.id===i.orgid&&(n.disabled=!0),n.children&&(n.children=t(n.children)),!0)),r);this.orgTree=t(e.data),this.ruleFormData={orgIded:i.orgid,orgId:""},this.showForm=!0,this.confirmLoading=!1,this.$nextTick(()=>{setTimeout(()=>{this.$refs.ruleForm.clearValidate()},0)})})},closed(){this.fullscreen=!1,this.visible=!1,this.$emit("closed")},toggleFullscreen(){this.fullscreen=!this.fullscreen},doEvent(i){const e=i.item.functionName;this[e]&&this[e]()}}};var I=function(){var e=this,t=e._self._c;return t("el-dialog",{directives:[{name:"drag",rawName:"v-drag"}],ref:"dialog",class:e.fullscreen?"gd-dialog gd-dialog-fangda":"gd-dialog",attrs:{fullscreen:e.fullscreen,visible:e.visible,width:e.width,center:!0,"close-on-click-modal":!1,"modal-append-to-body":!0,"append-to-body":!1,top:"80px","show-close":!1},on:{"update:visible":function(r){e.visible=r},closed:e.closed}},[t("template",{slot:"title"},[t("gd-modal-title",{attrs:{title:e.$i18nt("gd.btn.updateInstitutions","\u66F4\u65B0\u673A\u6784"),fullscreen:e.fullscreen,buttons:e.buttons,confirmLoading:e.confirmLoading,showClose:!0},on:{changeEvent:e.doEvent,toggleFullscreen:e.toggleFullscreen}})],1),t("div",{directives:[{name:"loading",rawName:"v-loading",value:e.confirmLoading,expression:"confirmLoading"}],staticStyle:{"min-height":"130px"}},[e.showForm?t("el-form",{ref:"ruleForm",attrs:{"label-width":"110px","label-position":"top",model:e.ruleFormData,size:"mini",rules:e.rules},nativeOn:{submit:function(r){r.preventDefault()}}},[t("el-form-item",{attrs:{label:e.$i18nt("gd.user.orgOldName","\u539F\u673A\u6784\u540D\u79F0"),prop:"orgIded"}},[t("gd-select-tree",{attrs:{filterable:!0,"tree-options":e.orgTree,"default-value":e.ruleFormData.orgIded,placeholder:e.$i18nt("gd.placeholder.select","\u8BF7\u9009\u62E9"),disabled:!0},model:{value:e.ruleFormData.orgIded,callback:function(r){e.$set(e.ruleFormData,"orgIded",r)},expression:"ruleFormData.orgIded"}})],1),t("el-form-item",{attrs:{label:e.$i18nt("gd.user.organization","\u6240\u5C5E\u673A\u6784"),prop:"orgId"}},[t("gd-select-tree",{attrs:{filterable:!0,"tree-options":e.orgTree,placeholder:e.$i18nt("gd.placeholder.select","\u8BF7\u9009\u62E9")},model:{value:e.ruleFormData.orgId,callback:function(r){e.$set(e.ruleFormData,"orgId",r)},expression:"ruleFormData.orgId"}})],1)],1):e._e()],1)],2)},A=[],M=T.normalizeComponent(U,I,A,!1,null,"12675dc5",null,null);const q=M.exports,j={data(){return{tableColumns:[{type:"selection",width:"60",fixed:!0},{transKey:"gd.user.account",prop:"account",label:"\u8D26\u53F7",width:"220",type:"slot",slotType:"account",align:"left",fixed:!0,showOverflowTooltip:!0},{transKey:"gd.user.name",prop:"name",label:"\u59D3\u540D",width:"160",align:"left",showOverflowTooltip:!0},{transKey:"gd.user.sex",prop:"gender",width:"120",label:"\u6027\u522B",type:"slot",slotType:"gender",align:"left",showOverflowTooltip:!0},{transKey:"gd.org.displayName",prop:"orgname",label:"\u673A\u6784\u540D\u79F0",width:"180",align:"left",showOverflowTooltip:!0},{transKey:"gd.user.phone",prop:"phone",width:"160",label:"\u624B\u673A",align:"left"},{transKey:"gd.user.status",prop:"statecodes",label:"\u72B6\u6001",width:"120",type:"slot",slotType:"statecodes",align:"center",dictTypeCode:"state_code",renderHeader:(i,...e)=>this.renderHeader(i,...e,{effectType:"checkbox",dictTypeCode:"state_code"})}],formColumns:[{transKey:"gd.user.account",effectType:"input",prop:"account",label:"\u8D26\u53F7",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change",min:2}]},{transKey:"gd.user.name",prop:"name",effectType:"input",label:"\u59D3\u540D",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.user.sex",prop:"gender",effectType:"radio",label:"\u6027\u522B",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",dictTypeCode:"gender",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.user.birthday",prop:"birthday",effectType:"date",label:"\u751F\u65E5",placeholder:"\u8BF7\u8F93\u5165",valueFormat:"yyyy-MM-dd",placeholderTransKey:"gd.placeholder.select",rules:[]},{transKey:"gd.user.phone",effectType:"input",prop:"phone",label:"\u624B\u673A\u53F7",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.user.email",effectType:"input",prop:"email",label:"\u90AE\u7BB1",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"},{type:"email",message:"\u8BF7\u8F93\u5165\u6B63\u786E\u7684\u90AE\u7BB1\u53F7!",transKey:"gd.account.emailTip"}]},{transKey:"gd.user.nickname",prop:"nickname",effectType:"input",label:"\u6635\u79F0",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[]},{transKey:"gd.user.tel",prop:"tel",effectType:"input",label:"\u7535\u8BDD",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[]},{transKey:"gd.org.displayName",prop:"orgid",effectType:"selectTree",label:"\u6240\u5C5E\u673A\u6784",placeholder:"\u8BF7\u9009\u62E9",placeholderTransKey:"gd.placeholder.select",treeOptions:[],rules:[{required:!0,message:"\u8BF7\u9009\u62E9",transKey:"gd.placeholder.select",trigger:"change"}]},{transKey:"gd.user.PSDNeverExpire",prop:"psdneverexpire",effectType:"switch",label:"\u5BC6\u7801\u6C38\u4E0D\u8FC7\u671F",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[]}],tableButtons:[{displayName:"\u65B0\u589E",functionName:"add",show:!0,transKey:"gd.btn.add",icon:"el-icon-plus",name:"sysUser:add"},{displayName:"\u7F16\u8F91",functionName:"edit",show:!0,transKey:"gd.btn.edit",icon:"el-icon-edit",name:"sysUser:edit"},{displayName:"\u66F4\u65B0\u673A\u6784",functionName:"updateInstitutions",show:!0,transKey:"gd.btn.updateInstitutions",icon:"el-icon-edit",name:"sysUser:updateInstitutions"},{displayName:"\u6388\u6743\u89D2\u8272",functionName:"userRole",show:!0,transKey:"gd.btn.authorizationRole",icon:"el-icon-edit",name:"sysUser:grantRole"},{displayName:"\u91CD\u7F6E\u5BC6\u7801",functionName:"resetPwd",show:!0,transKey:"gd.btn.resetPassword",icon:"el-icon-edit",btnType:"danger",name:"sysUser:resetPwd"},{displayName:"\u542F\u7528",functionName:"enable",show:!1,transKey:"gd.btn.enable",icon:"el-icon-video-play",name:"sysUser:changeStatus"},{displayName:"\u505C\u7528",functionName:"deactivated",show:!1,btnType:"danger",icon:"el-icon-discover",transKey:"gd.btn.deactivate",name:"sysUser:changeStatus"},{displayName:"\u5BFC\u5165",functionName:"importUser",show:!0,icon:"gd-icon-daoru1",transKey:"gd.btn.import",name:"sysUser:import"},{displayName:"\u5BFC\u51FA",functionName:"exportUser",show:!0,icon:"gd-icon-daoru",transKey:"gd.btn.export",name:"sysUser:export"}],formButtons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked",validate:!0}],tableQueries:[{transKey:"gd.user.status",prop:"stateCodes",label:"\u72B6\u6001",effectType:"checkbox",dictTypeCode:"state_code",selectType:"checkbox",rules:[]}]}}};var E={exports:{}};/*!
|
|
2
2
|
* clipboard.js v2.0.4
|
|
3
3
|
* https://zenorocha.github.io/clipboard.js
|
|
4
4
|
*
|
|
@@ -9,6 +9,6 @@ ${this.$i18nt("gd.user.name","\u59D3\u540D")}: ${this.infoData.name}
|
|
|
9
9
|
${this.$i18nt("gd.user.email","\u90AE\u7BB1")}: ${this.infoData.email}
|
|
10
10
|
${this.$i18nt("gd.user.phone","\u624B\u673A\u53F7")}: ${this.infoData.phone}
|
|
11
11
|
`}},methods:{open(i){this.visible=!0,this.isSendEmailList=i},colseCancel(){this.visible=!1},cmpleteUpgrade(){const i=new H(".copy-btn");i.on("success",()=>{this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.isSendEmailList!=1&&(this.visible=!1,this.$emit("sending"))}),i.on("error",()=>{this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")),this.visible=!1}),setTimeout(()=>{i.destroy()},122)},sendingEailm(){let i=this;i.sending=!0;let e={accountName:i.infoData.account,emailAddress:i.infoData.email,pcR_Type:5};w.applyResetPassword(e).then(t=>{t.success?(i.sending=!1,i.visible=!1,i.$notify({duration:8e3,type:"success",title:this.$i18nt("gd.https.resetTipSucc","\u91CD\u7F6E\u6210\u529F"),dangerouslyUseHTMLString:!0,message:`<p>${this.$i18nt("gd.https.addTip","\u5DF2\u5411\u6B64\u7528\u6237\u7684\u90AE\u7BB1\u53D1\u9001\u4E86\u4E00\u5C01\u5305\u542B\u5BC6\u7801\u91CD\u7F6E\u94FE\u63A5\u7684\u90AE\u4EF6\u3002")}</p>
|
|
12
|
-
<p>${this.$i18nt("gd.https.addTipp","\u5982\u679C\u7528\u6237\u6CA1\u6709\u6536\u5230\u90AE\u4EF6\uFF0C\u5C1D\u8BD5\u901A\u8FC7\u3010\u91CD\u7F6E\u5BC6\u7801\u3011\u53D1\u9001\u5BC6\u7801\u91CD\u7F6E\u8BF7\u6C42\u3002")}</p>`}),i.$emit("sending")):i.$message.error(i.$i18nt("gd.https.sendingErr","\u53D1\u9001\u5931\u8D25")+t.message)})}}};var G=function(){var e=this,t=e._self._c;return t("el-dialog",{directives:[{name:"drag",rawName:"v-drag"}],ref:"dialog",class:e.fullscreen?"gd-dialog gd-dialog-fangda":"gd-dialog",attrs:{fullscreen:e.fullscreen,visible:e.visible,width:e.width,center:!0,"close-on-click-modal":!1,"modal-append-to-body":!0,"append-to-body":!1,top:"80px"},on:{"update:visible":function(r){e.visible=r},closed:e.colseCancel}},[t("template",{slot:"title"},[t("div",{staticClass:"gd-dialog-head"},[t("div",{staticClass:"dialog-head-title"},[e._v(e._s(e.$i18nt("gd.user.basicInformation","\u57FA\u672C\u4FE1\u606F")))])])]),t("el-descriptions",{attrs:{title:"",column:1,size:"medium"}},[t("el-descriptions-item",{attrs:{label:e.$i18nt("gd.user.account","\u8D26\u53F7")}},[e._v(e._s(e.infoData.account))]),t("el-descriptions-item",{attrs:{label:e.$i18nt("gd.user.paw","\u5BC6\u7801")}},[e._v(e._s(e.infoData.password))]),t("el-descriptions-item",{attrs:{label:e.$i18nt("gd.user.name","\u59D3\u540D")}},[e._v(e._s(e.infoData.name))]),t("el-descriptions-item",{attrs:{label:e.$i18nt("gd.user.email","\u90AE\u7BB1")}},[e._v(e._s(e.infoData.email))]),t("el-descriptions-item",{attrs:{label:e.$i18nt("gd.user.phone","\u624B\u673A")}},[e._v(e._s(e.infoData.phone))])],1),t("template",{slot:"footer"},[t("el-button",{staticClass:"copy-btn",staticStyle:{"margin-left":"8px"},attrs:{type:"primary","data-clipboard-action":"copy","data-clipboard-text":e.copyInfo,icon:"el-icon-document-copy"},on:{click:e.cmpleteUpgrade}},[e._v(" "+e._s(e.$i18nt("gd.btn.copy"))+" ")]),e.isSendEmail=="1"?t("el-button",{staticClass:"copy-btn",staticStyle:{"margin-left":"8px"},attrs:{type:"primary",loading:e.sending,icon:"el-icon-message"},on:{click:e.sendingEailm}},[e._v(" "+e._s(e.$i18nt("gd.email.sending"))+" ")]):e._e()],1)],2)},Q=[],V=T.normalizeComponent(z,G,Q,!1,null,"
|
|
12
|
+
<p>${this.$i18nt("gd.https.addTipp","\u5982\u679C\u7528\u6237\u6CA1\u6709\u6536\u5230\u90AE\u4EF6\uFF0C\u5C1D\u8BD5\u901A\u8FC7\u3010\u91CD\u7F6E\u5BC6\u7801\u3011\u53D1\u9001\u5BC6\u7801\u91CD\u7F6E\u8BF7\u6C42\u3002")}</p>`}),i.$emit("sending")):i.$message.error(i.$i18nt("gd.https.sendingErr","\u53D1\u9001\u5931\u8D25")+t.message)})}}};var G=function(){var e=this,t=e._self._c;return t("el-dialog",{directives:[{name:"drag",rawName:"v-drag"}],ref:"dialog",class:e.fullscreen?"gd-dialog gd-dialog-fangda":"gd-dialog",attrs:{fullscreen:e.fullscreen,visible:e.visible,width:e.width,center:!0,"close-on-click-modal":!1,"modal-append-to-body":!0,"append-to-body":!1,top:"80px"},on:{"update:visible":function(r){e.visible=r},closed:e.colseCancel}},[t("template",{slot:"title"},[t("div",{staticClass:"gd-dialog-head"},[t("div",{staticClass:"dialog-head-title"},[e._v(e._s(e.$i18nt("gd.user.basicInformation","\u57FA\u672C\u4FE1\u606F")))])])]),t("el-descriptions",{attrs:{title:"",column:1,size:"medium"}},[t("el-descriptions-item",{attrs:{label:e.$i18nt("gd.user.account","\u8D26\u53F7")}},[e._v(e._s(e.infoData.account))]),t("el-descriptions-item",{attrs:{label:e.$i18nt("gd.user.paw","\u5BC6\u7801")}},[e._v(e._s(e.infoData.password))]),t("el-descriptions-item",{attrs:{label:e.$i18nt("gd.user.name","\u59D3\u540D")}},[e._v(e._s(e.infoData.name))]),t("el-descriptions-item",{attrs:{label:e.$i18nt("gd.user.email","\u90AE\u7BB1")}},[e._v(e._s(e.infoData.email))]),t("el-descriptions-item",{attrs:{label:e.$i18nt("gd.user.phone","\u624B\u673A")}},[e._v(e._s(e.infoData.phone))])],1),t("template",{slot:"footer"},[t("el-button",{staticClass:"copy-btn",staticStyle:{"margin-left":"8px"},attrs:{type:"primary","data-clipboard-action":"copy","data-clipboard-text":e.copyInfo,icon:"el-icon-document-copy"},on:{click:e.cmpleteUpgrade}},[e._v(" "+e._s(e.$i18nt("gd.btn.copy"))+" ")]),e.isSendEmail=="1"?t("el-button",{staticClass:"copy-btn",staticStyle:{"margin-left":"8px"},attrs:{type:"primary",loading:e.sending,icon:"el-icon-message"},on:{click:e.sendingEailm}},[e._v(" "+e._s(e.$i18nt("gd.email.sending"))+" ")]):e._e()],1)],2)},Q=[],V=T.normalizeComponent(z,G,Q,!1,null,"b6f77ddd",null,null);const Y=V.exports;const J={name:"GdUse",props:{height:{type:Number,default:100}},mixins:[K.tablesFilter,j],data(){return{transKey:"gd.btn.add",formLoading:!1,currentNode:null,loading:!0,orgTree:[],selectedRowKeys:[],selectedRows:[],queryParam:{},defaultProps:{children:"children",label:"title",value:"value"},defaultExpandedKeys:"",loadData:i=>w.getUserPage(Object.assign(i,this.getQueryParam)).then(e=>e.data),disableBtn:["\u542F\u7528","\u505C\u7528"],fileList:[],needLoad:!1,infoData:{},isSendEmail:"",isSendEmailed:"",institutionsShow:!1}},components:{UserRoleForm:D,EditInstitutions:q,copyInfo:Y},computed:{getQueryParam(){let i=new Map;for(let e in this.queryParam)i.set(e==="statecodes"?"searchctatus":e,this.queryParam[e]);return Object.fromEntries(i)},getFormColumns(){return this.formColumns.filter(e=>(e.prop==="orgid"&&(e.treeOptions=[...this.orgTree]),!0))},getTableButtons(){return this.tableButtons.filter(i=>(i.show=!this.disableBtn.includes(i.displayName),!0))},getHeight(){return this.height},styled(){return`height:${this.height+76}px`},...T.mapGetters(["tablePageSize","tableSize","labelPosition","formMode"])},methods:{updateInstitutions(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.institutionsShow=!0,this.$nextTick(()=>{setTimeout(()=>{this.$refs.editInstitutions.open(this.selectedRows[0])},0)})},userRole(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.$refs.userRoleForm.open(this.selectedRows[0])},saveQueries(i){this.queryParam={...i},this.refresh()},handleFileUpload(i){const e=this.$message({message:this.$i18nt("gd.https.uploading","\u52A0\u8F7D\u4E2D..."),duration:0,iconClass:"el-icon-loading"}),t=new FormData;t.append("file",i.file),w.sysUserImport(t).then(r=>{r.success?(this.$message.success(this.$i18nt("gd.https.uploadSucc","\u4E0A\u4F20\u6210\u529F")),this.refresh()):this.$message.error(this.$i18nt("gd.https.uploadFail","\u4E0A\u4F20\u5931\u8D25")+r.message),this.$nextTick(()=>{setTimeout(()=>{e.close()},200)})})},importUser(){this.fileList=[],document.querySelector(".upload-demo").click()},exportUser(){const i=this.$message({message:this.$i18nt("gd.https.exporting","\u6B63\u5728\u5BFC\u51FA\u4E2D..."),duration:0,iconClass:"el-icon-loading"});w.sysUserExport().then(e=>{this.downloadfile(e),this.$nextTick(()=>{setTimeout(()=>{i.close()},200)})}).catch(e=>{this.$nextTick(()=>{setTimeout(()=>{i.close()},200)})})},enable(){this.editStateCodes({row:this.selectedRows[0]})},deactivated(){this.editStateCodes({row:this.selectedRows[0]})},editStateCodes({column:i,row:e}){const t=e.statecodes!=1?this.$i18nt("gd.https.enableContent","\u662F\u5426\u505C\u7528\u9009\u4E2D\u6570\u636E?"):this.$i18nt("gd.https.deactivateContent","\u662F\u5426\u542F\u7528\u9009\u4E2D\u6570\u636E?"),r=e.statecodes!=1?this.$i18nt("gd.https.enableOk","\u786E\u8BA4\u505C\u7528"):this.$i18nt("gd.https.deactivateOk","\u786E\u8BA4\u542F\u7528");this.$confirm(t,this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:r,cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(n,s,o)=>{if(n!=="confirm"){o();return}s.confirmButtonLoading=!0,s.cancelButtonLoading=!0,s.showCancelButton=!1,w.sysUserChangeStatus({id:e.id,stateCodes:e.statecodes==1?0:1}).then(a=>{o(),a.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.handleOk()):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+a.message),s.confirmButtonLoading=!1,s.cancelButtonLoading=!1,s.showCancelButton=!0})}})},refresh(){this.$refs.table.refresh()},editForm(i){this.transKey="gd.btn.edit",this.$refs.editForm.open(Object.assign({...i},{gender:String(i.gender),orgid:String(i.orgid)}))},getOrgTree(){C.getOrgTree({}).then(i=>{if(i.code===200){const e=t=>(t=t.filter((r,n)=>(r.value=String(r.value),r.children&&r.children.length>0&&(r.children=e(r.children)),!0)),t);this.orgTree=e(i.data)}this.loading=!1})},handleNodeClick(i){this.queryParam.orgId===i.id?(delete this.queryParam.orgId,this.$nextTick(()=>{setTimeout(()=>{this.$refs.tree.setCurrentKey(null)},0)})):this.queryParam=Object.assign({...this.queryParam},{orgId:i.id}),this.refresh()},del(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.delTip","\u8BF7\u9009\u62E9\u8981\u5220\u9664\u7684\u6570\u636E!"));return}this.$confirm(this.$i18nt("gd.https.delContent","\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.delOk","\u786E\u5B9A\u5220\u9664"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(i,e,t)=>{this.delHand(i,e,t)}})},delHand(i,e,t){if(i!=="confirm"){t();return}let r=[];this.selectedRows.forEach(n=>{let s=sysOrgDelete(n).then(o=>o);r.push(s)}),e.confirmButtonLoading=!0,e.cancelButtonLoading=!0,e.showCancelButton=!1,Promise.all(r).then(n=>{t();const s=n.filter(o=>!o.success);s.length===0?this.$message.success(this.$i18nt("gd.https.delSucc","\u5220\u9664\u6210\u529F")):this.$message.error(this.$i18nt("gd.https.delFail","\u5220\u9664\u5931\u8D25")+s[0].message),this.handleOk(),e.confirmButtonLoading=!1,e.cancelButtonLoading=!1,e.showCancelButton=!0})},add(){this.transKey="gd.btn.add",this.$refs.editForm.open(null)},edit(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.editForm(this.selectedRows[0])},async sbumit({data:i,record:e,btn:t},r,n){this.formLoading=!0;let s=e?w.sysUserEdit:w.sysUserAdd;if(!e){let o=await this.getUsrePassword();Object.assign(i,{password:o,confirm:o})}s(i).then(o=>{this.isSendEmailed="",o.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),n(),this.handleOk(),this.infoData=i,this.sendEmail(e,i)):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+o.message),this.formLoading=!1})},sendEmail(i,e){i||(this.isSendEmail==1&&this.$notify({type:"success",title:this.$i18nt("gd.https.sendingSucc","\u53D1\u9001\u6210\u529F"),dangerouslyUseHTMLString:!0,message:`<p>${this.$i18nt("gd.https.addTip","\u5DF2\u5411\u6B64\u7528\u6237\u7684\u90AE\u7BB1\u53D1\u9001\u4E86\u4E00\u5C01\u5305\u542B\u5BC6\u7801\u91CD\u7F6E\u94FE\u63A5\u7684\u90AE\u4EF6\u3002")}</p>
|
|
13
13
|
<p>${this.$i18nt("gd.https.addTipp","\u5982\u679C\u7528\u6237\u6CA1\u6709\u6536\u5230\u90AE\u4EF6\uFF0C\u5C1D\u8BD5\u901A\u8FC7\u3010\u91CD\u7F6E\u5BC6\u7801\u3011\u53D1\u9001\u5BC6\u7801\u91CD\u7F6E\u8BF7\u6C42\u3002")}</p>`}),w.getConfigInfoByCode({code:"GDS_NewUser_DisplayAccount"}).then(t=>{t.code==200&&t.data.value=="1"&&setTimeout(()=>{this.$refs.copyInfo.open(this.copyRule)},1200)}))},handleOk(){this.getOrgTree(),this.$refs.table.refresh()},onSelectChange(i,e){if(this.selectedRowKeys=i,this.selectedRows=e,i.length===0){this.disableBtn=["\u542F\u7528","\u505C\u7528"];return}if(e.length>1){this.disableBtn=["\u542F\u7528","\u505C\u7528"];return}let t=[],r=e.filter(s=>s.statecodes==1),n=e.filter(s=>s.statecodes==0);r.length==e.length?t=["\u542F\u7528"]:n.length==e.length&&(t=["\u505C\u7528"]),this.disableBtn=t},downloadfile(i){var e=new Blob([i.data],{type:"application/octet-stream;charset=UTF-8"}),t=i.headers["content-disposition"];const s=/filename[^;=\n]*=((['"]).*?\2|[^;\n]*)/.exec(t)[1].replace(/['"]/g,"");var o=document.createElement("a"),a=window.URL.createObjectURL(e),c=/^["](.*)["]$/g;o.style.display="none",o.href=a,o.download=decodeURI(s.replace(c,"$1")),document.body.appendChild(o),o.click(),document.body.removeChild(o),window.URL.revokeObjectURL(a)},getUsrePassword(){return w.getPasswordRules({}).then(i=>{if(i.success)return this.combinationRule=i.data.combinationrule.value,this.copyRule=i.data.copyrule.value,this.lengthRule=i.data.lengthrule.value,this.isSendEmail=i.data.issendemail.value,this.mathPasword(this.lengthRule,this.combinationRule)})},getRandomChar(i){return i?i[Math.floor(Math.random()*i.length)]:""},mathPasword(i,e){let t=(e.includes("AL"),"abcdefghijklmnopqrstuvwxyz"),r=(e.includes("AL"),"ABCDEFGHIJKLMNOPQRSTUVWXYZ"),n=(e.includes("NU"),"0123456789"),s=(e.includes("SC"),"!@#$%&*^"),o="",a=[];if(s&&(a.push(this.getRandomChar(s)),a.push(this.getRandomChar(s))),r&&(a.push(this.getRandomChar(r)),a.push(this.getRandomChar(r))),t&&(a.push(this.getRandomChar(t)),a.push(this.getRandomChar(t))),n&&(a.push(this.getRandomChar(n)),a.push(this.getRandomChar(n))),a.length===0)return console.error("\u6CA1\u6709\u53EF\u7528\u7684\u5B57\u7B26\u96C6\u6765\u751F\u6210\u5BC6\u7801\uFF0C\u8BF7\u68C0\u67E5 combinationRule \u53C2\u6570"),"";a=a.sort(()=>Math.random()-.5);let c=a.join("");for(;c.length<i;){const h=[s,r,t,n].filter(p=>p);if(h.length===0)break;const b=h[Math.floor(Math.random()*h.length)];c+=this.getRandomChar(b)}return o=c.substring(0,i),o},resetPwd(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91"));return}this.$confirm(this.$i18nt("gd.https.resetPwdContent","\u662F\u5426\u91CD\u7F6E\u5BC6\u7801?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.resetPwdOk","\u7ACB\u5373\u91CD\u7F6E"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(i,e,t)=>{this.resetPwdHand(i,e,t)}})},async resetPwdHand(i,e,t){const r=await this.getUsrePassword();let n=this;if(i!=="confirm"){t();return}e.confirmButtonLoading=!0,e.cancelButtonLoading=!0,e.showCancelButton=!1;let s,o={};n.isSendEmail==1&&n.copyRule==1?(o={id:n.selectedRows[0].id,newPassword:r},s=w.sysUserResetPwd):n.isSendEmail==1?(o={accountName:n.selectedRows[0].account,emailAddress:n.selectedRows[0].email,pcR_Type:5},s=w.applyResetPassword):n.copyRule==1&&(o={id:n.selectedRows[0].id,newPassword:r},s=w.sysUserResetPwd),s(o).then(a=>{if(n.isSendEmailed=n.isSendEmail,t(),a.success){let c={account:n.selectedRows[0].account,password:r,name:n.selectedRows[0].name,email:n.selectedRows[0].email,phone:n.selectedRows[0].phone};n.isSendEmail==1&&n.copyRule==0?n.$notify({duration:8e3,type:"success",title:this.$i18nt("gd.https.resetTipSucc","\u91CD\u7F6E\u6210\u529F"),dangerouslyUseHTMLString:!0,message:`<p>${this.$i18nt("gd.https.addTip","\u5DF2\u5411\u6B64\u7528\u6237\u7684\u90AE\u7BB1\u53D1\u9001\u4E86\u4E00\u5C01\u5305\u542B\u5BC6\u7801\u91CD\u7F6E\u94FE\u63A5\u7684\u90AE\u4EF6\u3002")}</p>
|
|
14
|
-
<p>${this.$i18nt("gd.https.addTipp","\u5982\u679C\u7528\u6237\u6CA1\u6709\u6536\u5230\u90AE\u4EF6\uFF0C\u5C1D\u8BD5\u901A\u8FC7\u3010\u91CD\u7F6E\u5BC6\u7801\u3011\u53D1\u9001\u5BC6\u7801\u91CD\u7F6E\u8BF7\u6C42\u3002")}</p>`}):n.$message.success(n.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),n.copyRule==1?(n.infoData=c,setTimeout(()=>{n.$refs.copyInfo.open(n.isSendEmail)},500)):n.refresh()}else n.$message.error(n.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+a.message);e.confirmButtonLoading=!1,e.cancelButtonLoading=!1,e.showCancelButton=!0})},sending(){this.refresh()},doEvent(i){let e=i.item.functionName;this[e]&&this[e]()}},created(){this.getOrgTree()}};var W=function(){var e=this,t=e._self._c;return t("div",{staticClass:"gd-page-view",staticStyle:{display:"flex",background:"rgb(245, 245, 245)"}},[t("div",{directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}],staticClass:"page-view-tree",style:e.styled},[t("el-tree",{ref:"tree",attrs:{data:e.orgTree,props:e.defaultProps,"node-key":"id","current-node-key":e.defaultExpandedKeys,"default-expand-all":"","highlight-current":"","expand-on-click-node":!1},on:{"node-click":e.handleNodeClick}})],1),t("div",{staticClass:"page-view-list"},[t("gd-tables",{ref:"table",attrs:{dataSource:e.loadData,size:e.tableSize,pageSize:e.tablePageSize,columns:e.tableColumns,selectedRowKeys:e.selectedRowKeys,height:e.getHeight,filtering:!0},on:{onChange:e.onSelectChange},scopedSlots:e._u([{key:"account",fn:function({column:r,row:n}){return[t("gd-tooltip",{attrs:{rowKey:"account",row:n,highlight:""},on:{click:e.editForm}})]}},{key:"gender",fn:function(r){return[t("div",{staticStyle:{cursor:"pointer"}},[t("el-tag",{style:e._f("dictColor")("gender",r.row.gender),attrs:{effect:"dark"}},[e._v(" "+e._s(e._f("dictType")("gender",r.row.gender))+" ")])],1)]}},{key:"statecodes",fn:function(r){return[t("div",{staticStyle:{cursor:"pointer"},on:{click:function(n){return n.stopPropagation(),e.editStateCodes(r)}}},[r.row.statecodes==1?t("i",{staticClass:"gd-icons gd-icon-xuanzhong active-color",staticStyle:{"font-size":"18px"}}):t("i",{staticClass:"gd-icons gd-icon-jinyong1",staticStyle:{"font-size":"18px",color:"#999"}})])]}},{key:"operator",fn:function(){return[t("div",{staticClass:"gd-table-operator"},[t("div",{staticClass:"gd-table-operatorl",staticStyle:{width:"270px"}},[t("el-input",{staticClass:"table-operator-input",attrs:{placeholder:e.$i18nt("gd.user.keywordTip","\u8BF7\u8F93\u5165\u59D3\u540D\u3001\u8D26\u53F7\u3001\u624B\u673A\u53F7\u5173\u952E\u8BCD"),clearable:""},nativeOn:{keyup:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"enter",13,r.key,"Enter")?null:e.refresh.apply(null,arguments)}},model:{value:e.queryParam.searchValue,callback:function(r){e.$set(e.queryParam,"searchValue",r)},expression:"queryParam.searchValue"}}),t("div",{staticClass:"table-operator-search",on:{click:e.refresh}},[t("i",{staticClass:"el-input__icon el-icon-search"})])],1),t("div",{staticClass:"gd-table-operatorr"},[t("gd-btn-list",{attrs:{sysViewButtons:e.getTableButtons},on:{functionName:e.doEvent}})],1)])]},proxy:!0},{key:"filtering",fn:function({colse:r,visible:n}){return[t("gd-table-queries-field",{attrs:{columns:e.tableQueries,height:e.height,queryParam:e.queryParam,colse:r,visible:n},on:{save:e.saveQueries}})]}}])})],1),t("UserRoleForm",{ref:"userRoleForm",on:{ok:e.handleOk}}),e.institutionsShow?t("EditInstitutions",{ref:"editInstitutions",on:{ok:e.handleOk,closed:function(r){e.institutionsShow=!1}}}):e._e(),t("copyInfo",{ref:"copyInfo",attrs:{infoData:e.infoData,isSendEmail:e.isSendEmailed},on:{sending:e.sending}}),t("gd-edit-form",{ref:"editForm",attrs:{formItemWidth:"90%",loading:e.formLoading,transKey:e.transKey,buttons:e.formButtons,columns:e.getFormColumns,labelPosition:e.labelPosition,formMode:e.formMode,inline:!0,width:"1000px",needLoad:e.needLoad},on:{sbumit:e.sbumit}}),t("div",{staticStyle:{position:"fixed",left:"-20000px",top:"-2000px"}},[t("el-upload",{ref:"upload",attrs:{"http-request":e.handleFileUpload,"file-list":e.fileList,action:""}},[t("el-button",{ref:"uploadDemo",staticClass:"upload-demo",attrs:{slot:"trigger",size:"small",type:"primary"},slot:"trigger"},[e._v(" "+e._s(e.$i18nt("gd.user.selectFile","\u9009\u53D6\u6587\u4EF6"))+" ")])],1)],1)],1)},X=[],Z=T.normalizeComponent(J,W,X,!1,null,"
|
|
14
|
+
<p>${this.$i18nt("gd.https.addTipp","\u5982\u679C\u7528\u6237\u6CA1\u6709\u6536\u5230\u90AE\u4EF6\uFF0C\u5C1D\u8BD5\u901A\u8FC7\u3010\u91CD\u7F6E\u5BC6\u7801\u3011\u53D1\u9001\u5BC6\u7801\u91CD\u7F6E\u8BF7\u6C42\u3002")}</p>`}):n.$message.success(n.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),n.copyRule==1?(n.infoData=c,setTimeout(()=>{n.$refs.copyInfo.open(n.isSendEmail)},500)):n.refresh()}else n.$message.error(n.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+a.message);e.confirmButtonLoading=!1,e.cancelButtonLoading=!1,e.showCancelButton=!0})},sending(){this.refresh()},doEvent(i){let e=i.item.functionName;this[e]&&this[e]()}},created(){this.getOrgTree()}};var W=function(){var e=this,t=e._self._c;return t("div",{staticClass:"gd-page-view",staticStyle:{display:"flex",background:"rgb(245, 245, 245)"}},[t("div",{directives:[{name:"loading",rawName:"v-loading",value:e.loading,expression:"loading"}],staticClass:"page-view-tree",style:e.styled},[t("el-tree",{ref:"tree",attrs:{data:e.orgTree,props:e.defaultProps,"node-key":"id","current-node-key":e.defaultExpandedKeys,"default-expand-all":"","highlight-current":"","expand-on-click-node":!1},on:{"node-click":e.handleNodeClick}})],1),t("div",{staticClass:"page-view-list"},[t("gd-tables",{ref:"table",attrs:{dataSource:e.loadData,size:e.tableSize,pageSize:e.tablePageSize,columns:e.tableColumns,selectedRowKeys:e.selectedRowKeys,height:e.getHeight,filtering:!0},on:{onChange:e.onSelectChange},scopedSlots:e._u([{key:"account",fn:function({column:r,row:n}){return[t("gd-tooltip",{attrs:{rowKey:"account",row:n,highlight:""},on:{click:e.editForm}})]}},{key:"gender",fn:function(r){return[t("div",{staticStyle:{cursor:"pointer"}},[t("el-tag",{style:e._f("dictColor")("gender",r.row.gender),attrs:{effect:"dark"}},[e._v(" "+e._s(e._f("dictType")("gender",r.row.gender))+" ")])],1)]}},{key:"statecodes",fn:function(r){return[t("div",{staticStyle:{cursor:"pointer"},on:{click:function(n){return n.stopPropagation(),e.editStateCodes(r)}}},[r.row.statecodes==1?t("i",{staticClass:"gd-icons gd-icon-xuanzhong active-color",staticStyle:{"font-size":"18px"}}):t("i",{staticClass:"gd-icons gd-icon-jinyong1",staticStyle:{"font-size":"18px",color:"#999"}})])]}},{key:"operator",fn:function(){return[t("div",{staticClass:"gd-table-operator"},[t("div",{staticClass:"gd-table-operatorl",staticStyle:{width:"270px"}},[t("el-input",{staticClass:"table-operator-input",attrs:{placeholder:e.$i18nt("gd.user.keywordTip","\u8BF7\u8F93\u5165\u59D3\u540D\u3001\u8D26\u53F7\u3001\u624B\u673A\u53F7\u5173\u952E\u8BCD"),clearable:""},nativeOn:{keyup:function(r){return!r.type.indexOf("key")&&e._k(r.keyCode,"enter",13,r.key,"Enter")?null:e.refresh.apply(null,arguments)}},model:{value:e.queryParam.searchValue,callback:function(r){e.$set(e.queryParam,"searchValue",r)},expression:"queryParam.searchValue"}}),t("div",{staticClass:"table-operator-search",on:{click:e.refresh}},[t("i",{staticClass:"el-input__icon el-icon-search"})])],1),t("div",{staticClass:"gd-table-operatorr"},[t("gd-btn-list",{attrs:{sysViewButtons:e.getTableButtons},on:{functionName:e.doEvent}})],1)])]},proxy:!0},{key:"filtering",fn:function({colse:r,visible:n}){return[t("gd-table-queries-field",{attrs:{columns:e.tableQueries,height:e.height,queryParam:e.queryParam,colse:r,visible:n},on:{save:e.saveQueries}})]}}])})],1),t("UserRoleForm",{ref:"userRoleForm",on:{ok:e.handleOk}}),e.institutionsShow?t("EditInstitutions",{ref:"editInstitutions",on:{ok:e.handleOk,closed:function(r){e.institutionsShow=!1}}}):e._e(),t("copyInfo",{ref:"copyInfo",attrs:{infoData:e.infoData,isSendEmail:e.isSendEmailed},on:{sending:e.sending}}),t("gd-edit-form",{ref:"editForm",attrs:{formItemWidth:"90%",loading:e.formLoading,transKey:e.transKey,buttons:e.formButtons,columns:e.getFormColumns,labelPosition:e.labelPosition,formMode:e.formMode,inline:!0,width:"1000px",needLoad:e.needLoad},on:{sbumit:e.sbumit}}),t("div",{staticStyle:{position:"fixed",left:"-20000px",top:"-2000px"}},[t("el-upload",{ref:"upload",attrs:{"http-request":e.handleFileUpload,"file-list":e.fileList,action:""}},[t("el-button",{ref:"uploadDemo",staticClass:"upload-demo",attrs:{slot:"trigger",size:"small",type:"primary"},slot:"trigger"},[e._v(" "+e._s(e.$i18nt("gd.user.selectFile","\u9009\u53D6\u6587\u4EF6"))+" ")])],1)],1)],1)},X=[],Z=T.normalizeComponent(J,W,X,!1,null,"d1d24d5d",null,null);const x=Z.exports;x.install=function(i){i.component(x.name,x)};exports.GDpackage=x;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const l=require("./system.duplicatechecking.e5542a97.js"),o=require("./chartbi.c211f08d.js"),u=require("./messages.0e2d9d5a.js"),h={data(){return{tableColumns:[{type:"selection",width:"60",fixed:!0},{transKey:"gd.form.name",prop:"name",label:"\u540D\u79F0",type:"slot",slotType:"name",align:"left",fixed:!0,renderHeader:(t,...e)=>this.renderHeader(t,...e,{effectType:"input"}),showOverflowTooltip:!0}],formColumns:[{transKey:"gd.form.roleName",effectType:"input",prop:"name",label:"\u540D\u79F0",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.ownershipValue.ownershipValue",prop:"affiliationValue",effectType:"input",label:"\u6240\u5C5E\u503C",placeholder:"\u8BF7\u8F93\u5165",disabled:!1,placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]}],tableButtons:[{displayName:"\u65B0\u589E",functionName:"add",show:!0,transKey:"gd.btn.add",icon:"el-icon-plus",name:"sysAffiliation:add"},{displayName:"\u7F16\u8F91",functionName:"edit",show:!0,transKey:"gd.btn.edit",icon:"el-icon-edit",name:"sysAffiliation:edit"},{displayName:"\u5220\u9664",functionName:"del",show:!0,transKey:"gd.btn.del",icon:"el-icon-delete",btnType:"danger",name:"sysAffiliation:delete"}],formButtons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked",validate:!0}],tableQueries:[{transKey:"gd.form.name",prop:"name",label:"\u540D\u79F0",effectType:"input",rules:[]},{transKey:"gd.ownershipValue.ownershipValue",prop:"affiliationValue",label:"\u6240\u5C5E\u503C",effectType:"input",rules:[]}]}}};const f={name:"GdUserRole",props:{height:{type:Number,default:100},openSelecteKeys:{type:Array,default:()=>[]},useraffiliationname:{type:String,default:""},openMode:{type:String,default:"page"}},mixins:[u.tablesFilter],data(){return{transKey:"gd.btn.add",formLoading:!1,currentNode:null,loading:!0,orgTree:[],selectedRowKeys:[],selectedRows:[],queryParam:{},defaultProps:{children:"children",label:"title",value:"value"},defaultExpandedKeys:"",loadData:t=>(this.queryParam={userAffiliationId:this.openSelecteKeys[0]},l.getbyUserAffiliationId(this.queryParam).then(e=>(e.data.length>0&&this.getRowId(e.data),console.log(this.disabledRowId),e.data.forEach(s=>{s.useraffiliationname=this.useraffiliationname}),{pageno:1,pagesize:1e3,rows:e.data}))),disableBtn:[],fileList:[],needLoad:!1,infoData:{},isSendEmail:"",isSendEmailed:"",tableColumns:[{type:"selection",width:"60",fixed:!0},{transKey:"gd.userAffiliation.name",prop:"username",label:"\u7528\u6237(\u59D3\u540D)",align:"left",type:"slot",slotType:"username",showOverflowTooltip:!0},{transKey:"gd.userAffiliation.userOwnershipName",prop:"useraffiliationname",label:"\u7528\u6237\u6240\u5C5E\u540D\u79F0",align:"left",showOverflowTooltip:!0}],formColumnsuser:[{transKey:"gd.user.account",effectType:"input",prop:"account",label:"\u8D26\u53F7",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change",min:2}]},{transKey:"gd.user.name",prop:"name",effectType:"input",label:"\u59D3\u540D",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.user.sex",prop:"gender",effectType:"radio",label:"\u6027\u522B",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",dictTypeCode:"gender",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.user.birthday",prop:"birthday",effectType:"date",label:"\u751F\u65E5",placeholder:"\u8BF7\u8F93\u5165",valueFormat:"yyyy-MM-dd",placeholderTransKey:"gd.placeholder.select",rules:[]},{transKey:"gd.user.phone",effectType:"input",prop:"phone",label:"\u624B\u673A\u53F7",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.user.email",effectType:"input",prop:"email",label:"\u90AE\u7BB1",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"},{type:"email",message:"\u8BF7\u8F93\u5165\u6B63\u786E\u7684\u90AE\u7BB1\u53F7!",transKey:"gd.account.emailTip"}]},{transKey:"gd.user.nickname",prop:"nickname",effectType:"input",label:"\u6635\u79F0",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[]},{transKey:"gd.user.tel",prop:"tel",effectType:"input",label:"\u7535\u8BDD",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[]},{transKey:"gd.org.displayName",prop:"orgid",effectType:"selectTree",label:"\u6240\u5C5E\u673A\u6784",placeholder:"\u8BF7\u9009\u62E9",placeholderTransKey:"gd.placeholder.select",treeOptions:[],rules:[{required:!0,message:"\u8BF7\u9009\u62E9",transKey:"gd.placeholder.select",trigger:"change"}]},{transKey:"gd.user.PSDNeverExpire",prop:"psdneverexpire",effectType:"switch",label:"\u5BC6\u7801\u6C38\u4E0D\u8FC7\u671F",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[]}],tableButtons:[{displayName:"\u65B0\u589E",functionName:"add",show:!0,transKey:"gd.btn.add",icon:"el-icon-plus",name:"sysRole:add"},{displayName:"\u5220\u9664",functionName:"del",show:!0,transKey:"gd.btn.del",icon:"el-icon-delete",btnType:"danger",name:"sysRole:delete"}],disabledRowId:[],sysCodeGenName:"sys_user"}},components:{},computed:{initialLoading(){return this.openMode==="page"},selectedKeep(){return this.openMode!=="page"},getQueryParam(){let t=new Map;for(let e in this.queryParam)t.set(e==="statecodes"?"searchctatus":e,this.queryParam[e]);return Object.fromEntries(t)},getFormColumns(){return this.formColumnsuser.filter(e=>(e.prop==="orgid"&&(e.treeOptions=[...this.orgTree]),!0))},getTableButtons(){return this.tableButtons.filter(t=>(t.show=!this.disableBtn.includes(t.displayName),!0))},getHeight(){return this.height},styled(){return`height:${this.height+76}px`},...o.mapGetters(["tablePageSize","tableSize","labelPosition","formMode"])},methods:{getRowId(t){let e=[];t.filter(s=>!this.disabledRowId.includes(s.userid)).forEach(s=>{e.push(s.userid)}),this.disabledRowId=this.disabledRowId.concat(e)},saveQueries(t){this.queryParam={...t},this.refresh()},refresh(){this.$refs.table.refresh()},handleOk(){this.$refs.table.refresh()},onSelectChange(t,e){this.selectedRowKeys=t,this.selectedRows=e},doEvent(t){let e=t.item.functionName;this[e]&&this[e]()},lookupSeled(t){if(t.fkData.length===0){this.$refs.engineSearch.closed();return}this.$refs.engineSearch.confirmLoading=!0,l.sysUserAffiliationAddRelation({userAffiliationId:this.openSelecteKeys[0],userIdList:t.data}).then(e=>{e.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.$refs.engineSearch.closed(),this.refresh()):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+e.message),this.$refs.engineSearch.confirmLoading=!1})},add(){this.$refs.engineSearch.open({fkEntityName:this.sysCodeGenName,val:[],effectType:"participants",isRelevance:!0})},del(){let t=this;if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.delTip","\u8BF7\u9009\u62E9\u8981\u5220\u9664\u7684\u6570\u636E!"));return}this.$confirm(this.$i18nt("gd.https.delContent","\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.delOk","\u786E\u5B9A\u5220\u9664"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(e,s,i)=>{if(e!=="confirm"){i();return}s.confirmButtonLoading=!0,s.cancelButtonLoading=!0,s.showCancelButton=!1,l.sysUserAffiliationDeleteRelation({userAffiliationId:t.openSelecteKeys[0],userIdList:JSON.parse(JSON.stringify(t.selectedRows)).map(a=>a.userid)}).then(a=>{a.success?(t.$message.success(t.$i18nt("gd.https.delSucc","\u5220\u9664\u6210\u529F")),t.disabledRowId=t.disabledRowId.filter(n=>!t.selectedRows.filter(d=>d.userid===n)[0]),s.confirmButtonLoading=!1,s.cancelButtonLoading=!1,s.showCancelButton=!0,i(),t.refresh()):t.$message.error(t.$i18nt("gd.https.delFail","\u5220\u9664\u5931\u8D25")+a.message)})}})}},created(){}};var p=function(){var e=this,s=e._self._c;return s("div",{staticClass:"gd-page-view",staticStyle:{display:"flex",background:"rgb(245, 245, 245)"}},[s("div",{staticClass:"page-view-list"},[s("gd-tables",{ref:"table",attrs:{dataSource:e.loadData,size:e.tableSize,pageSize:e.tablePageSize,columns:e.tableColumns,showPagination:!1,selectedRowKeys:e.selectedRowKeys,height:e.height,initialLoading:!1},on:{onChange:e.onSelectChange},scopedSlots:e._u([{key:"operator",fn:function(){return[s("div",{staticClass:"gd-table-operator"},[s("div",{staticClass:"gd-table-operatorr"},[s("gd-btn-list",{attrs:{sysViewButtons:e.tableButtons},on:{functionName:e.doEvent}})],1)])]},proxy:!0},{key:"username",fn:function({column:i,row:a}){return[s("span",{staticStyle:{cursor:"pointer"}},[e._v(" "+e._s(a.username)+" ")])]}}])}),s("gd-search",{ref:"engineSearch",attrs:{appendToBody:!0,disabledRowId:e.disabledRowId},on:{lookupSeled:e.lookupSeled}})],1)])},g=[],m=o.normalizeComponent(f,p,g,!1,null,"01c5868d",null,null);const y=m.exports;const b={data(){return{buttons:[],record:{},visible:!1,confirmLoading:!1,fullscreen:!1,width:"90%",selectedRowKeys:[]}},components:{UserRelation:y},computed:{height(){return this.screenHeight-(this.fullscreen?160:340)},...o.mapGetters(["screenHeight"])},methods:{handleSubmit(){this.closed()},open(t){this.record=t,this.visible=!0,this.selectedRowKeys=[t.id],this.useraffiliationname=t.affiliationvalue,this.$nextTick(()=>{setTimeout(()=>{this.$refs.userForm.refresh()},0)})},closed(){this.fullscreen=!1,this.visible=!1},toggleFullscreen(){this.fullscreen=!this.fullscreen},onSelectChange(t){this.selectedRowKeys=t},doEvent(t){const e=t.item.functionName;this[e]&&this[e]()}}};var w=function(){var e=this,s=e._self._c;return s("el-dialog",{directives:[{name:"drag",rawName:"v-drag"}],ref:"dialog",class:e.fullscreen?"gd-dialog gd-dialog-fangda":"gd-dialog",attrs:{fullscreen:e.fullscreen,visible:e.visible,width:e.width,center:!0,"close-on-click-modal":!1,"modal-append-to-body":!1,"append-to-body":!0,top:"80px","show-close":!1},on:{"update:visible":function(i){e.visible=i},closed:e.closed}},[s("template",{slot:"title"},[s("gd-modal-title",{attrs:{title:e.$i18nt("gd.user.userAuthorization","\u6388\u6743\u7528\u6237"),fullscreen:e.fullscreen,buttons:e.buttons,confirmLoading:e.confirmLoading,showClose:!0},on:{changeEvent:e.doEvent,toggleFullscreen:e.toggleFullscreen}})],1),s("div",{directives:[{name:"loading",rawName:"v-loading",value:e.confirmLoading,expression:"confirmLoading"}]},[e.visible?s("UserRelation",{ref:"userForm",attrs:{height:e.height,openMode:"components",openSelecteKeys:e.selectedRowKeys,useraffiliationname:e.useraffiliationname},on:{onSelectChange:e.onSelectChange}}):e._e()],1)],2)},v=[],_=o.normalizeComponent(b,w,v,!1,null,"eceab663",null,null);const $=_.exports;const K={data(){return{sys_UseraffiliationtypeId:"",transKey:"gd.btn.add",formLoading:!1,formButtons:[{displayName:"\u786E\u5B9A",functionName:"formhandleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked",validate:!0}],belongslist:[],formColumns:[{transKey:"gd.form.name",prop:"name",effectType:"input",label:"\u540D\u79F0",placeholder:"\u8BF7\u8F93\u5165",disabled:!1,placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.ownershipValue.ownershipValue",prop:"affiliationValue",effectType:"input",label:"\u6240\u5C5E\u503C",placeholder:"\u8BF7\u8F93\u5165",disabled:!1,placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]}],confirmLoading:!0,title:"",sysViewButtons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked"}],type:1,fullScreen:!1,width:"1000px",ruleFormData:{name:""},rules:{name:[{required:!0,message:this.$i18nt("gd.btn.input","\u8BF7\u8F93\u5165"),trigger:"change"}]},visible:!1,queryParam:{},loadData:t=>(this.queryParam={Sys_UseraffiliationtypeId:this.sys_UseraffiliationtypeId},l.getUserAffiliation(Object.assign(t,this.queryParam)).then(e=>(e.data.rows.forEach(s=>{s.typename=this.ruleFormData.name}),e.data))),openMode:"page",selectedRowKeys:[],selectedRows:[],tableColumns:[{type:"selection",width:"60",fixed:!0},{transKey:"gd.duplicatechecking.name",prop:"name",label:"\u540D\u79F0",type:"slot",slotType:"name",align:"left",showOverflowTooltip:!0},{transKey:"gd.ownershipValue.ownershipValue",prop:"affiliationvalue",label:"\u6240\u5C5E\u503C",align:"left",showOverflowTooltip:!0}],tableButtons:[{displayName:"\u65B0\u589E",functionName:"add",show:!0,transKey:"gd.btn.add",icon:"el-icon-plus",name:"sysAffiliation:add"},{displayName:"\u7F16\u8F91",functionName:"edit",show:!0,transKey:"gd.btn.edit",icon:"el-icon-edit",name:"sysAffiliation:edit"},{displayName:"\u5220\u9664",functionName:"del",show:!0,transKey:"gd.btn.del",icon:"el-icon-delete",btnType:"danger",name:"sysAffiliation:delete"},{displayName:"\u6388\u6743\u7528\u6237",functionName:"userRelationship",show:!0,transKey:"gd.user.userAuthorization",icon:"el-icon-setting",name:"sysAffiliation:belongingMenu"}]}},components:{UserRelationAdd:$},computed:{getFormColumns(){return this.formColumns.filter(t=>!0)},getHeight(){const t=this.fullScreen?230:410;return this.screenHeight-t},initialLoading(){return this.openMode==="page"},selectedKeep(){return this.openMode!=="page"},...o.mapGetters(["screenHeight","tableLists","tableSize","tablePageSize","labelPosition","formMode"])},methods:{userRelationship(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.$refs.userrelationadd.open(this.selectedRows[0])},lookup(t,e){const s=t[e.prop];this.$refs.viewSearch.open({fkEntityName:"DataSource",effectType:e.effectType,val:s||""})},async searchDataSource(t){this.formLoading=!0,this.belongslist=[],this.belongslist=await this.getbelongslist(),this.formLoading=!1},fkSearch(t){const e=`${t}Loading`;t==="name"&&!this[e]&&this.searchDataSource("")},getbelongslist(){return l.getSysUserAffiliationType().then(t=>{if(t.code===200)return t.data.rows})},getDataSource(t){let e={name:t,fkEntityName:this.fkEntityName};return u.baseFkList(e).then(s=>s.data.map(i=>(i.id=String(i.id),i)))},okFilter(t){this.filterList={...t}},toggleFullscreen(){this.fullScreen=!this.fullScreen},getDictionary(t){return this.$options.filters.dictData(t)},selectRules(t){},getList(t,e){},init(t){this.fullScreen=!1,this.confirmLoading=!1,this.visible=!0,this.type=t?2:1,this.title=t?this.$i18nt("gd.https.edit"):this.$i18nt("gd.https.add"),this.sys_UseraffiliationtypeId=t?t.id:"",this.selectedRowKeys=[],this.selectedRows=[],this.$nextTick(()=>{setTimeout(()=>{this.type===2&&this.refresh(),this.ruleFormData={name:t?t.name:""},this.$refs.ruleForm.resetFields()},0)})},del(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.delTip","\u8BF7\u9009\u62E9\u8981\u5220\u9664\u7684\u6570\u636E!"));return}this.$confirm(this.$i18nt("gd.https.delContent","\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.delOk","\u786E\u5B9A\u5220\u9664"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(t,e,s)=>{this.delHand(t,e,s)}})},delHand(t,e,s){if(t!=="confirm"){s();return}let i=[];this.selectedRows.forEach(a=>{let n=l.sysUserAffiliationDelete(a).then(r=>r);i.push(n)}),e.confirmButtonLoading=!0,e.cancelButtonLoading=!0,e.showCancelButton=!1,Promise.all(i).then(a=>{const n=a.filter(r=>!r.success);n.length===0?this.$message.success(this.$i18nt("gd.https.delSucc","\u5220\u9664\u6210\u529F")):this.$message.error(this.$i18nt("gd.https.delFail","\u5220\u9664\u5931\u8D25")+n[0].message),s(),this.refresh(),e.confirmButtonLoading=!1,e.cancelButtonLoading=!1,e.showCancelButton=!0})},add(t){this.transKey="gd.btn.add",this.$refs.editFormref.open(null),this.$refs.editFormref.setData({nametype:this.ruleFormData.name})},edit(t){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.editForm(this.selectedRows[0])},editForm(t){this.transKey="gd.btn.edit",this.$refs.editFormref.open(t),this.$refs.editFormref.setData({nametype:this.ruleFormData.name}),this.$refs.editFormref.setData({affiliationValue:t.affiliationvalue})},formhandleSubmit(){console.log("\u6240\u5C5E\u503C\u7684\u65B0\u589E\u4FDD\u5B58")},handleSubmit(){this.$refs.ruleForm.validate(t=>{if(t){const e={...this.ruleFormData};this.sub(e)}})},sub(t){this.formLoading=!0;let e=this.type==1?l.sysUserAffiliationTypeAdd:l.sysUserAffiliationTypeEdit;const s=this.type==1?t:Object.assign({values:t,id:this.sys_UseraffiliationtypeId});e(s).then(i=>{i.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.handleCancel(),this.$emit("ok")):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+i.message),this.formLoading=!1})},handleCancel(){this.visible=!1,this.confirmLoading=!1,this.tabledisabled=!1},doEvent(t){let e=t.item.functionName;this[e]()},onSelectChange(t,e){this.selectedRowKeys=t,this.selectedRows=e,this.$emit("onSelectChange",t,e)},removeRow(t){let e=this;this.$confirm(this.$i18nt("gd.https.delContent","\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.delOk","\u786E\u5B9A\u5220\u9664"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(s,i,a)=>{if(s!=="confirm"){a();return}e.$message.success(e.$i18nt("gd.https.delSucc","\u5220\u9664\u6210\u529F")),a()}})},sbumit({data:t,record:e,btn:s},i,a){this.formLoading=!0;let n=e?l.sysUserAffiliationEdit:l.sysUserAffiliationAdd;delete t.nametype;const r=e?Object.assign({affiliationValue:t.affiliationValue,sys_UseraffiliationtypeId:this.sys_UseraffiliationtypeId,id:t.id}):Object.assign(t,{sys_UseraffiliationtypeId:this.sys_UseraffiliationtypeId});n(r).then(d=>{d.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),a(),this.refresh()):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+d.message),this.formLoading=!1})},refresh(){this.$refs.table&&this.$refs.table.refresh()}}};var C=function(){var e=this,s=e._self._c;return s("div",[s("el-dialog",{class:e.fullScreen?"gd-dialog gd-dialog-fangda":"gd-dialog",attrs:{fullscreen:e.fullScreen,width:e.width,visible:e.visible,footer:null,top:"80px","append-to-body":"","show-close":!1},on:{"update:visible":function(i){e.visible=i},closed:e.handleCancel}},[s("gd-modal-title",{attrs:{slot:"title",title:e.title,fullscreen:e.fullScreen,buttons:e.sysViewButtons,confirmLoading:e.confirmLoading,showClose:!0,closed:"handleCancel"},on:{changeEvent:e.doEvent},slot:"title"}),s("div",{directives:[{name:"loading",rawName:"v-loading",value:e.confirmLoading,expression:"confirmLoading"}]},[s("div",{staticClass:"setting-navs",class:e.fullScreen?"modal-bodyq":"modal-body"},[s("el-form",{ref:"ruleForm",attrs:{model:e.ruleFormData,rules:e.rules,"label-width":"120px"},nativeOn:{submit:function(i){i.preventDefault()}}},[s("el-row",{staticStyle:{"margin-left":"-12px","margin-right":"-12px"},attrs:{gutter:48}},[s("el-col",{attrs:{span:12}},[s("el-form-item",{staticClass:"form_name",staticStyle:{"margin-bottom":"12px"},attrs:{label:e.$i18nt("gd.duplicatechecking.name","\u540D\u79F0"),prop:"name"}},[s("el-input",{attrs:{disabled:e.type==2,placeholder:e.$i18nt("gd.placeholder.input","\u8BF7\u8F93\u5165")},model:{value:e.ruleFormData.name,callback:function(i){e.$set(e.ruleFormData,"name",i)},expression:"ruleFormData.name"}})],1)],1)],1)],1),e.type==2?[s("el-divider"),s("div",{staticClass:"setting-conter"},[s("gd-tables",{ref:"table",attrs:{dataSource:e.loadData,size:e.tableSize,pageSize:e.tablePageSize,columns:e.tableColumns,selectedRowKeys:e.selectedRowKeys,height:e.getHeight,selectedKeep:e.selectedKeep,initialLoading:e.initialLoading},on:{onChange:e.onSelectChange},scopedSlots:e._u([{key:"name",fn:function({column:i,row:a}){return[s("gd-tooltip",{attrs:{rowKey:"name",row:a,highlight:""},on:{click:e.editForm}})]}},{key:"operator",fn:function(){return[s("div",{staticClass:"operator-list"},[s("div",{staticClass:"clearfix"},[s("span",[e._v(e._s(e.$i18nt("gd.userAffiliation.userownershipValue","\u7528\u6237\u6240\u5C5E\u503C")))])]),s("div",{staticClass:"gd-table-operator"},[s("div",{staticClass:"gd-table-operatorr"},[s("gd-btn-list",{attrs:{sysViewButtons:e.tableButtons},on:{functionName:e.doEvent}})],1)])])]},proxy:!0}],null,!1,3417440761)})],1)]:e._e()],2)])],1),s("gd-edit-form",{ref:"editFormref",attrs:{formItemWidth:"100%",loading:e.formLoading,transKey:e.transKey,buttons:e.formButtons,columns:e.getFormColumns,labelPosition:e.labelPosition,formMode:e.formMode},on:{sbumit:e.sbumit}}),s("UserRelationAdd",{ref:"userrelationadd",on:{ok:e.refresh}})],1)},S=[],T=o.normalizeComponent(K,C,S,!1,null,"40f982ec",null,null);const R=T.exports;const k={name:"GdUserAffiliation",props:{height:{type:Number,default:100},openMode:{type:String,default:"page"},openSelecteKeys:{type:Array,default:()=>[]}},mixins:[u.tablesFilter,h],data(){return{loading:!0,selectedRowKeys:[],selectedRows:[],queryParam:{},record:{},loadData:t=>(this.selectedKeep&&(this.selectedRowKeys=[...this.openSelecteKeys]),l.getSysUserAffiliationType(Object.assign(t,this.queryParam)).then(e=>e.data))}},components:{editForm:R},computed:{initialLoading(){return this.openMode==="page"},selectedKeep(){return this.openMode!=="page"},getHeight(){return this.height},...o.mapGetters(["tablePageSize","tableSize","labelPosition","formMode"])},methods:{saveQueries(t){this.queryParam={...t},this.refresh()},refresh(){this.$refs.table.refresh()},editForm(t){this.$refs.editForm.init(t)},del(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.delTip","\u8BF7\u9009\u62E9\u8981\u5220\u9664\u7684\u6570\u636E!"));return}this.$confirm(this.$i18nt("gd.https.delContent","\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.delOk","\u786E\u5B9A\u5220\u9664"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(t,e,s)=>{this.delHand(t,e,s)}})},delHand(t,e,s){if(t!=="confirm"){s();return}let i=[];this.selectedRows.forEach(a=>{let n=l.sysUserAffiliationTypeDelete(a).then(r=>r);i.push(n)}),e.confirmButtonLoading=!0,e.cancelButtonLoading=!0,e.showCancelButton=!1,Promise.all(i).then(a=>{const n=a.filter(r=>!r.success);n.length===0?this.$message.success(this.$i18nt("gd.https.delSucc","\u5220\u9664\u6210\u529F")):this.$message.error(this.$i18nt("gd.https.delFail","\u5220\u9664\u5931\u8D25")+n[0].message),s(),this.refresh(),e.confirmButtonLoading=!1,e.cancelButtonLoading=!1,e.showCancelButton=!0})},add(){this.$refs.editForm.init(null)},edit(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.editForm(this.selectedRows[0])},handleOk(){this.$refs.table.refresh()},onSelectChange(t,e){this.selectedRowKeys=t,this.selectedRows=e,this.$emit("onSelectChange",t,e)},doEvent(t){let e=t.item.functionName;this[e]&&this[e]()}}};var L=function(){var e=this,s=e._self._c;return s("div",{staticClass:"gd-page-view"},[s("div",{staticClass:"page-view-list",staticStyle:{padding:"0px"}},[s("gd-tables",{ref:"table",attrs:{dataSource:e.loadData,size:e.tableSize,pageSize:e.tablePageSize,columns:e.tableColumns,selectedRowKeys:e.selectedRowKeys,height:e.getHeight,filtering:!0,selectedKeep:e.selectedKeep,initialLoading:e.initialLoading},on:{onChange:e.onSelectChange},scopedSlots:e._u([{key:"name",fn:function({column:i,row:a}){return[s("gd-tooltip",{attrs:{rowKey:"name",row:a,highlight:""},on:{click:e.editForm}})]}},{key:"operator",fn:function(){return[s("div",{staticClass:"gd-table-operator"},[s("div",{staticClass:"gd-table-operatorl"},[s("el-input",{staticClass:"table-operator-input",attrs:{placeholder:e.$i18nt("gd.form.name","\u540D\u79F0"),clearable:""},nativeOn:{keyup:function(i){return!i.type.indexOf("key")&&e._k(i.keyCode,"enter",13,i.key,"Enter")?null:e.refresh.apply(null,arguments)}},model:{value:e.queryParam.name,callback:function(i){e.$set(e.queryParam,"name",i)},expression:"queryParam.name"}}),s("div",{staticClass:"table-operator-search",on:{click:e.refresh}},[s("i",{staticClass:"el-input__icon el-icon-search"})])],1),s("div",{staticClass:"gd-table-operatorr"},[e.openMode==="page"?s("gd-btn-list",{attrs:{sysViewButtons:e.tableButtons},on:{functionName:e.doEvent}}):e._e()],1)])]},proxy:!0},{key:"filtering",fn:function({colse:i,visible:a}){return[s("gd-table-queries-field",{attrs:{columns:e.tableQueries,height:e.getHeight,queryParam:e.queryParam,colse:i,visible:a},on:{save:e.saveQueries}})]}}])})],1),s("editForm",{ref:"editForm",attrs:{table:e.record},on:{ok:e.handleOk}})],1)},B=[],F=o.normalizeComponent(k,L,B,!1,null,"48edf473",null,null);const c=F.exports;c.install=function(t){t.component(c.name,c)};exports.GDpackage=c;
|
|
1
|
+
"use strict";const l=require("./system.duplicatechecking.39293985.js"),o=require("./chartbi.06e48153.js"),u=require("./messages.2fff74f3.js"),h={data(){return{tableColumns:[{type:"selection",width:"60",fixed:!0},{transKey:"gd.form.name",prop:"name",label:"\u540D\u79F0",type:"slot",slotType:"name",align:"left",fixed:!0,renderHeader:(t,...e)=>this.renderHeader(t,...e,{effectType:"input"}),showOverflowTooltip:!0}],formColumns:[{transKey:"gd.form.roleName",effectType:"input",prop:"name",label:"\u540D\u79F0",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.ownershipValue.ownershipValue",prop:"affiliationValue",effectType:"input",label:"\u6240\u5C5E\u503C",placeholder:"\u8BF7\u8F93\u5165",disabled:!1,placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]}],tableButtons:[{displayName:"\u65B0\u589E",functionName:"add",show:!0,transKey:"gd.btn.add",icon:"el-icon-plus",name:"sysAffiliation:add"},{displayName:"\u7F16\u8F91",functionName:"edit",show:!0,transKey:"gd.btn.edit",icon:"el-icon-edit",name:"sysAffiliation:edit"},{displayName:"\u5220\u9664",functionName:"del",show:!0,transKey:"gd.btn.del",icon:"el-icon-delete",btnType:"danger",name:"sysAffiliation:delete"}],formButtons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked",validate:!0}],tableQueries:[{transKey:"gd.form.name",prop:"name",label:"\u540D\u79F0",effectType:"input",rules:[]},{transKey:"gd.ownershipValue.ownershipValue",prop:"affiliationValue",label:"\u6240\u5C5E\u503C",effectType:"input",rules:[]}]}}};const f={name:"GdUserRole",props:{height:{type:Number,default:100},openSelecteKeys:{type:Array,default:()=>[]},useraffiliationname:{type:String,default:""},openMode:{type:String,default:"page"}},mixins:[u.tablesFilter],data(){return{transKey:"gd.btn.add",formLoading:!1,currentNode:null,loading:!0,orgTree:[],selectedRowKeys:[],selectedRows:[],queryParam:{},defaultProps:{children:"children",label:"title",value:"value"},defaultExpandedKeys:"",loadData:t=>(this.queryParam={userAffiliationId:this.openSelecteKeys[0]},l.getbyUserAffiliationId(this.queryParam).then(e=>(e.data.length>0&&this.getRowId(e.data),console.log(this.disabledRowId),e.data.forEach(s=>{s.useraffiliationname=this.useraffiliationname}),{pageno:1,pagesize:1e3,rows:e.data}))),disableBtn:[],fileList:[],needLoad:!1,infoData:{},isSendEmail:"",isSendEmailed:"",tableColumns:[{type:"selection",width:"60",fixed:!0},{transKey:"gd.userAffiliation.name",prop:"username",label:"\u7528\u6237(\u59D3\u540D)",align:"left",type:"slot",slotType:"username",showOverflowTooltip:!0},{transKey:"gd.userAffiliation.userOwnershipName",prop:"useraffiliationname",label:"\u7528\u6237\u6240\u5C5E\u540D\u79F0",align:"left",showOverflowTooltip:!0}],formColumnsuser:[{transKey:"gd.user.account",effectType:"input",prop:"account",label:"\u8D26\u53F7",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change",min:2}]},{transKey:"gd.user.name",prop:"name",effectType:"input",label:"\u59D3\u540D",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.user.sex",prop:"gender",effectType:"radio",label:"\u6027\u522B",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",dictTypeCode:"gender",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.user.birthday",prop:"birthday",effectType:"date",label:"\u751F\u65E5",placeholder:"\u8BF7\u8F93\u5165",valueFormat:"yyyy-MM-dd",placeholderTransKey:"gd.placeholder.select",rules:[]},{transKey:"gd.user.phone",effectType:"input",prop:"phone",label:"\u624B\u673A\u53F7",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.user.email",effectType:"input",prop:"email",label:"\u90AE\u7BB1",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"},{type:"email",message:"\u8BF7\u8F93\u5165\u6B63\u786E\u7684\u90AE\u7BB1\u53F7!",transKey:"gd.account.emailTip"}]},{transKey:"gd.user.nickname",prop:"nickname",effectType:"input",label:"\u6635\u79F0",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[]},{transKey:"gd.user.tel",prop:"tel",effectType:"input",label:"\u7535\u8BDD",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[]},{transKey:"gd.org.displayName",prop:"orgid",effectType:"selectTree",label:"\u6240\u5C5E\u673A\u6784",placeholder:"\u8BF7\u9009\u62E9",placeholderTransKey:"gd.placeholder.select",treeOptions:[],rules:[{required:!0,message:"\u8BF7\u9009\u62E9",transKey:"gd.placeholder.select",trigger:"change"}]},{transKey:"gd.user.PSDNeverExpire",prop:"psdneverexpire",effectType:"switch",label:"\u5BC6\u7801\u6C38\u4E0D\u8FC7\u671F",placeholder:"\u8BF7\u8F93\u5165",placeholderTransKey:"gd.placeholder.input",rules:[]}],tableButtons:[{displayName:"\u65B0\u589E",functionName:"add",show:!0,transKey:"gd.btn.add",icon:"el-icon-plus",name:"sysRole:add"},{displayName:"\u5220\u9664",functionName:"del",show:!0,transKey:"gd.btn.del",icon:"el-icon-delete",btnType:"danger",name:"sysRole:delete"}],disabledRowId:[],sysCodeGenName:"sys_user"}},components:{},computed:{initialLoading(){return this.openMode==="page"},selectedKeep(){return this.openMode!=="page"},getQueryParam(){let t=new Map;for(let e in this.queryParam)t.set(e==="statecodes"?"searchctatus":e,this.queryParam[e]);return Object.fromEntries(t)},getFormColumns(){return this.formColumnsuser.filter(e=>(e.prop==="orgid"&&(e.treeOptions=[...this.orgTree]),!0))},getTableButtons(){return this.tableButtons.filter(t=>(t.show=!this.disableBtn.includes(t.displayName),!0))},getHeight(){return this.height},styled(){return`height:${this.height+76}px`},...o.mapGetters(["tablePageSize","tableSize","labelPosition","formMode"])},methods:{getRowId(t){let e=[];t.filter(s=>!this.disabledRowId.includes(s.userid)).forEach(s=>{e.push(s.userid)}),this.disabledRowId=this.disabledRowId.concat(e)},saveQueries(t){this.queryParam={...t},this.refresh()},refresh(){this.$refs.table.refresh()},handleOk(){this.$refs.table.refresh()},onSelectChange(t,e){this.selectedRowKeys=t,this.selectedRows=e},doEvent(t){let e=t.item.functionName;this[e]&&this[e]()},lookupSeled(t){if(t.fkData.length===0){this.$refs.engineSearch.closed();return}this.$refs.engineSearch.confirmLoading=!0,l.sysUserAffiliationAddRelation({userAffiliationId:this.openSelecteKeys[0],userIdList:t.data}).then(e=>{e.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.$refs.engineSearch.closed(),this.refresh()):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+e.message),this.$refs.engineSearch.confirmLoading=!1})},add(){this.$refs.engineSearch.open({fkEntityName:this.sysCodeGenName,val:[],effectType:"participants",isRelevance:!0})},del(){let t=this;if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.delTip","\u8BF7\u9009\u62E9\u8981\u5220\u9664\u7684\u6570\u636E!"));return}this.$confirm(this.$i18nt("gd.https.delContent","\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.delOk","\u786E\u5B9A\u5220\u9664"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(e,s,i)=>{if(e!=="confirm"){i();return}s.confirmButtonLoading=!0,s.cancelButtonLoading=!0,s.showCancelButton=!1,l.sysUserAffiliationDeleteRelation({userAffiliationId:t.openSelecteKeys[0],userIdList:JSON.parse(JSON.stringify(t.selectedRows)).map(a=>a.userid)}).then(a=>{a.success?(t.$message.success(t.$i18nt("gd.https.delSucc","\u5220\u9664\u6210\u529F")),t.disabledRowId=t.disabledRowId.filter(n=>!t.selectedRows.filter(d=>d.userid===n)[0]),s.confirmButtonLoading=!1,s.cancelButtonLoading=!1,s.showCancelButton=!0,i(),t.refresh()):t.$message.error(t.$i18nt("gd.https.delFail","\u5220\u9664\u5931\u8D25")+a.message)})}})}},created(){}};var p=function(){var e=this,s=e._self._c;return s("div",{staticClass:"gd-page-view",staticStyle:{display:"flex",background:"rgb(245, 245, 245)"}},[s("div",{staticClass:"page-view-list"},[s("gd-tables",{ref:"table",attrs:{dataSource:e.loadData,size:e.tableSize,pageSize:e.tablePageSize,columns:e.tableColumns,showPagination:!1,selectedRowKeys:e.selectedRowKeys,height:e.height,initialLoading:!1},on:{onChange:e.onSelectChange},scopedSlots:e._u([{key:"operator",fn:function(){return[s("div",{staticClass:"gd-table-operator"},[s("div",{staticClass:"gd-table-operatorr"},[s("gd-btn-list",{attrs:{sysViewButtons:e.tableButtons},on:{functionName:e.doEvent}})],1)])]},proxy:!0},{key:"username",fn:function({column:i,row:a}){return[s("span",{staticStyle:{cursor:"pointer"}},[e._v(" "+e._s(a.username)+" ")])]}}])}),s("gd-search",{ref:"engineSearch",attrs:{appendToBody:!0,disabledRowId:e.disabledRowId},on:{lookupSeled:e.lookupSeled}})],1)])},g=[],m=o.normalizeComponent(f,p,g,!1,null,"65ef2965",null,null);const y=m.exports;const b={data(){return{buttons:[],record:{},visible:!1,confirmLoading:!1,fullscreen:!1,width:"90%",selectedRowKeys:[]}},components:{UserRelation:y},computed:{height(){return this.screenHeight-(this.fullscreen?160:340)},...o.mapGetters(["screenHeight"])},methods:{handleSubmit(){this.closed()},open(t){this.record=t,this.visible=!0,this.selectedRowKeys=[t.id],this.useraffiliationname=t.affiliationvalue,this.$nextTick(()=>{setTimeout(()=>{this.$refs.userForm.refresh()},0)})},closed(){this.fullscreen=!1,this.visible=!1},toggleFullscreen(){this.fullscreen=!this.fullscreen},onSelectChange(t){this.selectedRowKeys=t},doEvent(t){const e=t.item.functionName;this[e]&&this[e]()}}};var w=function(){var e=this,s=e._self._c;return s("el-dialog",{directives:[{name:"drag",rawName:"v-drag"}],ref:"dialog",class:e.fullscreen?"gd-dialog gd-dialog-fangda":"gd-dialog",attrs:{fullscreen:e.fullscreen,visible:e.visible,width:e.width,center:!0,"close-on-click-modal":!1,"modal-append-to-body":!1,"append-to-body":!0,top:"80px","show-close":!1},on:{"update:visible":function(i){e.visible=i},closed:e.closed}},[s("template",{slot:"title"},[s("gd-modal-title",{attrs:{title:e.$i18nt("gd.user.userAuthorization","\u6388\u6743\u7528\u6237"),fullscreen:e.fullscreen,buttons:e.buttons,confirmLoading:e.confirmLoading,showClose:!0},on:{changeEvent:e.doEvent,toggleFullscreen:e.toggleFullscreen}})],1),s("div",{directives:[{name:"loading",rawName:"v-loading",value:e.confirmLoading,expression:"confirmLoading"}]},[e.visible?s("UserRelation",{ref:"userForm",attrs:{height:e.height,openMode:"components",openSelecteKeys:e.selectedRowKeys,useraffiliationname:e.useraffiliationname},on:{onSelectChange:e.onSelectChange}}):e._e()],1)],2)},v=[],_=o.normalizeComponent(b,w,v,!1,null,"f6bdfd51",null,null);const $=_.exports;const K={data(){return{sys_UseraffiliationtypeId:"",transKey:"gd.btn.add",formLoading:!1,formButtons:[{displayName:"\u786E\u5B9A",functionName:"formhandleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked",validate:!0}],belongslist:[],formColumns:[{transKey:"gd.form.name",prop:"name",effectType:"input",label:"\u540D\u79F0",placeholder:"\u8BF7\u8F93\u5165",disabled:!1,placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]},{transKey:"gd.ownershipValue.ownershipValue",prop:"affiliationValue",effectType:"input",label:"\u6240\u5C5E\u503C",placeholder:"\u8BF7\u8F93\u5165",disabled:!1,placeholderTransKey:"gd.placeholder.input",rules:[{required:!0,message:"\u8BF7\u8F93\u5165",transKey:"gd.placeholder.input",trigger:"change"}]}],confirmLoading:!0,title:"",sysViewButtons:[{displayName:"\u786E\u5B9A",functionName:"handleSubmit",show:!0,transKey:"gd.btn.confirm",icon:"el-icon-document-checked"}],type:1,fullScreen:!1,width:"1000px",ruleFormData:{name:""},rules:{name:[{required:!0,message:this.$i18nt("gd.btn.input","\u8BF7\u8F93\u5165"),trigger:"change"}]},visible:!1,queryParam:{},loadData:t=>(this.queryParam={Sys_UseraffiliationtypeId:this.sys_UseraffiliationtypeId},l.getUserAffiliation(Object.assign(t,this.queryParam)).then(e=>(e.data.rows.forEach(s=>{s.typename=this.ruleFormData.name}),e.data))),openMode:"page",selectedRowKeys:[],selectedRows:[],tableColumns:[{type:"selection",width:"60",fixed:!0},{transKey:"gd.duplicatechecking.name",prop:"name",label:"\u540D\u79F0",type:"slot",slotType:"name",align:"left",showOverflowTooltip:!0},{transKey:"gd.ownershipValue.ownershipValue",prop:"affiliationvalue",label:"\u6240\u5C5E\u503C",align:"left",showOverflowTooltip:!0}],tableButtons:[{displayName:"\u65B0\u589E",functionName:"add",show:!0,transKey:"gd.btn.add",icon:"el-icon-plus",name:"sysAffiliation:add"},{displayName:"\u7F16\u8F91",functionName:"edit",show:!0,transKey:"gd.btn.edit",icon:"el-icon-edit",name:"sysAffiliation:edit"},{displayName:"\u5220\u9664",functionName:"del",show:!0,transKey:"gd.btn.del",icon:"el-icon-delete",btnType:"danger",name:"sysAffiliation:delete"},{displayName:"\u6388\u6743\u7528\u6237",functionName:"userRelationship",show:!0,transKey:"gd.user.userAuthorization",icon:"el-icon-setting",name:"sysAffiliation:belongingMenu"}]}},components:{UserRelationAdd:$},computed:{getFormColumns(){return this.formColumns.filter(t=>!0)},getHeight(){const t=this.fullScreen?230:410;return this.screenHeight-t},initialLoading(){return this.openMode==="page"},selectedKeep(){return this.openMode!=="page"},...o.mapGetters(["screenHeight","tableLists","tableSize","tablePageSize","labelPosition","formMode"])},methods:{userRelationship(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.$refs.userrelationadd.open(this.selectedRows[0])},lookup(t,e){const s=t[e.prop];this.$refs.viewSearch.open({fkEntityName:"DataSource",effectType:e.effectType,val:s||""})},async searchDataSource(t){this.formLoading=!0,this.belongslist=[],this.belongslist=await this.getbelongslist(),this.formLoading=!1},fkSearch(t){const e=`${t}Loading`;t==="name"&&!this[e]&&this.searchDataSource("")},getbelongslist(){return l.getSysUserAffiliationType().then(t=>{if(t.code===200)return t.data.rows})},getDataSource(t){let e={name:t,fkEntityName:this.fkEntityName};return u.baseFkList(e).then(s=>s.data.map(i=>(i.id=String(i.id),i)))},okFilter(t){this.filterList={...t}},toggleFullscreen(){this.fullScreen=!this.fullScreen},getDictionary(t){return this.$options.filters.dictData(t)},selectRules(t){},getList(t,e){},init(t){this.fullScreen=!1,this.confirmLoading=!1,this.visible=!0,this.type=t?2:1,this.title=t?this.$i18nt("gd.https.edit"):this.$i18nt("gd.https.add"),this.sys_UseraffiliationtypeId=t?t.id:"",this.selectedRowKeys=[],this.selectedRows=[],this.$nextTick(()=>{setTimeout(()=>{this.type===2&&this.refresh(),this.ruleFormData={name:t?t.name:""},this.$refs.ruleForm.resetFields()},0)})},del(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.delTip","\u8BF7\u9009\u62E9\u8981\u5220\u9664\u7684\u6570\u636E!"));return}this.$confirm(this.$i18nt("gd.https.delContent","\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.delOk","\u786E\u5B9A\u5220\u9664"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(t,e,s)=>{this.delHand(t,e,s)}})},delHand(t,e,s){if(t!=="confirm"){s();return}let i=[];this.selectedRows.forEach(a=>{let n=l.sysUserAffiliationDelete(a).then(r=>r);i.push(n)}),e.confirmButtonLoading=!0,e.cancelButtonLoading=!0,e.showCancelButton=!1,Promise.all(i).then(a=>{const n=a.filter(r=>!r.success);n.length===0?this.$message.success(this.$i18nt("gd.https.delSucc","\u5220\u9664\u6210\u529F")):this.$message.error(this.$i18nt("gd.https.delFail","\u5220\u9664\u5931\u8D25")+n[0].message),s(),this.refresh(),e.confirmButtonLoading=!1,e.cancelButtonLoading=!1,e.showCancelButton=!0})},add(t){this.transKey="gd.btn.add",this.$refs.editFormref.open(null),this.$refs.editFormref.setData({nametype:this.ruleFormData.name})},edit(t){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.editForm(this.selectedRows[0])},editForm(t){this.transKey="gd.btn.edit",this.$refs.editFormref.open(t),this.$refs.editFormref.setData({nametype:this.ruleFormData.name}),this.$refs.editFormref.setData({affiliationValue:t.affiliationvalue})},formhandleSubmit(){console.log("\u6240\u5C5E\u503C\u7684\u65B0\u589E\u4FDD\u5B58")},handleSubmit(){this.$refs.ruleForm.validate(t=>{if(t){const e={...this.ruleFormData};this.sub(e)}})},sub(t){this.formLoading=!0;let e=this.type==1?l.sysUserAffiliationTypeAdd:l.sysUserAffiliationTypeEdit;const s=this.type==1?t:Object.assign({values:t,id:this.sys_UseraffiliationtypeId});e(s).then(i=>{i.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),this.handleCancel(),this.$emit("ok")):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+i.message),this.formLoading=!1})},handleCancel(){this.visible=!1,this.confirmLoading=!1,this.tabledisabled=!1},doEvent(t){let e=t.item.functionName;this[e]()},onSelectChange(t,e){this.selectedRowKeys=t,this.selectedRows=e,this.$emit("onSelectChange",t,e)},removeRow(t){let e=this;this.$confirm(this.$i18nt("gd.https.delContent","\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.delOk","\u786E\u5B9A\u5220\u9664"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(s,i,a)=>{if(s!=="confirm"){a();return}e.$message.success(e.$i18nt("gd.https.delSucc","\u5220\u9664\u6210\u529F")),a()}})},sbumit({data:t,record:e,btn:s},i,a){this.formLoading=!0;let n=e?l.sysUserAffiliationEdit:l.sysUserAffiliationAdd;delete t.nametype;const r=e?Object.assign({affiliationValue:t.affiliationValue,sys_UseraffiliationtypeId:this.sys_UseraffiliationtypeId,id:t.id}):Object.assign(t,{sys_UseraffiliationtypeId:this.sys_UseraffiliationtypeId});n(r).then(d=>{d.success?(this.$message.success(this.$i18nt("gd.https.operateSucc","\u64CD\u4F5C\u6210\u529F")),a(),this.refresh()):this.$message.error(this.$i18nt("gd.https.operateFail","\u64CD\u4F5C\u5931\u8D25")+d.message),this.formLoading=!1})},refresh(){this.$refs.table&&this.$refs.table.refresh()}}};var C=function(){var e=this,s=e._self._c;return s("div",[s("el-dialog",{class:e.fullScreen?"gd-dialog gd-dialog-fangda":"gd-dialog",attrs:{fullscreen:e.fullScreen,width:e.width,visible:e.visible,footer:null,top:"80px","append-to-body":"","show-close":!1},on:{"update:visible":function(i){e.visible=i},closed:e.handleCancel}},[s("gd-modal-title",{attrs:{slot:"title",title:e.title,fullscreen:e.fullScreen,buttons:e.sysViewButtons,confirmLoading:e.confirmLoading,showClose:!0,closed:"handleCancel"},on:{changeEvent:e.doEvent},slot:"title"}),s("div",{directives:[{name:"loading",rawName:"v-loading",value:e.confirmLoading,expression:"confirmLoading"}]},[s("div",{staticClass:"setting-navs",class:e.fullScreen?"modal-bodyq":"modal-body"},[s("el-form",{ref:"ruleForm",attrs:{model:e.ruleFormData,rules:e.rules,"label-width":"120px"},nativeOn:{submit:function(i){i.preventDefault()}}},[s("el-row",{staticStyle:{"margin-left":"-12px","margin-right":"-12px"},attrs:{gutter:48}},[s("el-col",{attrs:{span:12}},[s("el-form-item",{staticClass:"form_name",staticStyle:{"margin-bottom":"12px"},attrs:{label:e.$i18nt("gd.duplicatechecking.name","\u540D\u79F0"),prop:"name"}},[s("el-input",{attrs:{disabled:e.type==2,placeholder:e.$i18nt("gd.placeholder.input","\u8BF7\u8F93\u5165")},model:{value:e.ruleFormData.name,callback:function(i){e.$set(e.ruleFormData,"name",i)},expression:"ruleFormData.name"}})],1)],1)],1)],1),e.type==2?[s("el-divider"),s("div",{staticClass:"setting-conter"},[s("gd-tables",{ref:"table",attrs:{dataSource:e.loadData,size:e.tableSize,pageSize:e.tablePageSize,columns:e.tableColumns,selectedRowKeys:e.selectedRowKeys,height:e.getHeight,selectedKeep:e.selectedKeep,initialLoading:e.initialLoading},on:{onChange:e.onSelectChange},scopedSlots:e._u([{key:"name",fn:function({column:i,row:a}){return[s("gd-tooltip",{attrs:{rowKey:"name",row:a,highlight:""},on:{click:e.editForm}})]}},{key:"operator",fn:function(){return[s("div",{staticClass:"operator-list"},[s("div",{staticClass:"clearfix"},[s("span",[e._v(e._s(e.$i18nt("gd.userAffiliation.userownershipValue","\u7528\u6237\u6240\u5C5E\u503C")))])]),s("div",{staticClass:"gd-table-operator"},[s("div",{staticClass:"gd-table-operatorr"},[s("gd-btn-list",{attrs:{sysViewButtons:e.tableButtons},on:{functionName:e.doEvent}})],1)])])]},proxy:!0}],null,!1,3417440761)})],1)]:e._e()],2)])],1),s("gd-edit-form",{ref:"editFormref",attrs:{formItemWidth:"100%",loading:e.formLoading,transKey:e.transKey,buttons:e.formButtons,columns:e.getFormColumns,labelPosition:e.labelPosition,formMode:e.formMode},on:{sbumit:e.sbumit}}),s("UserRelationAdd",{ref:"userrelationadd",on:{ok:e.refresh}})],1)},S=[],T=o.normalizeComponent(K,C,S,!1,null,"d0f142ed",null,null);const R=T.exports;const k={name:"GdUserAffiliation",props:{height:{type:Number,default:100},openMode:{type:String,default:"page"},openSelecteKeys:{type:Array,default:()=>[]}},mixins:[u.tablesFilter,h],data(){return{loading:!0,selectedRowKeys:[],selectedRows:[],queryParam:{},record:{},loadData:t=>(this.selectedKeep&&(this.selectedRowKeys=[...this.openSelecteKeys]),l.getSysUserAffiliationType(Object.assign(t,this.queryParam)).then(e=>e.data))}},components:{editForm:R},computed:{initialLoading(){return this.openMode==="page"},selectedKeep(){return this.openMode!=="page"},getHeight(){return this.height},...o.mapGetters(["tablePageSize","tableSize","labelPosition","formMode"])},methods:{saveQueries(t){this.queryParam={...t},this.refresh()},refresh(){this.$refs.table.refresh()},editForm(t){this.$refs.editForm.init(t)},del(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.delTip","\u8BF7\u9009\u62E9\u8981\u5220\u9664\u7684\u6570\u636E!"));return}this.$confirm(this.$i18nt("gd.https.delContent","\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"),this.$i18nt("gd.https.delTitle","\u6E29\u99A8\u63D0\u793A"),{confirmButtonText:this.$i18nt("gd.https.delOk","\u786E\u5B9A\u5220\u9664"),cancelButtonText:this.$i18nt("gd.https.delCancel","\u53D6\u6D88"),showClose:!1,confirmButtonLoading:!1,cancelButtonLoading:!1,closeOnClickModal:!1,type:"warning",confirmButtonClass:"el-button--danger",customClass:"custom-alert",callback:()=>{},beforeClose:(t,e,s)=>{this.delHand(t,e,s)}})},delHand(t,e,s){if(t!=="confirm"){s();return}let i=[];this.selectedRows.forEach(a=>{let n=l.sysUserAffiliationTypeDelete(a).then(r=>r);i.push(n)}),e.confirmButtonLoading=!0,e.cancelButtonLoading=!0,e.showCancelButton=!1,Promise.all(i).then(a=>{const n=a.filter(r=>!r.success);n.length===0?this.$message.success(this.$i18nt("gd.https.delSucc","\u5220\u9664\u6210\u529F")):this.$message.error(this.$i18nt("gd.https.delFail","\u5220\u9664\u5931\u8D25")+n[0].message),s(),this.refresh(),e.confirmButtonLoading=!1,e.cancelButtonLoading=!1,e.showCancelButton=!0})},add(){this.$refs.editForm.init(null)},edit(){if(this.selectedRowKeys.length===0){this.$message.warning(this.$i18nt("gd.https.editTip","\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));return}if(this.selectedRowKeys.length>1){this.$message.warning(this.$i18nt("gd.https.editTipOne","\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));return}this.editForm(this.selectedRows[0])},handleOk(){this.$refs.table.refresh()},onSelectChange(t,e){this.selectedRowKeys=t,this.selectedRows=e,this.$emit("onSelectChange",t,e)},doEvent(t){let e=t.item.functionName;this[e]&&this[e]()}}};var L=function(){var e=this,s=e._self._c;return s("div",{staticClass:"gd-page-view"},[s("div",{staticClass:"page-view-list",staticStyle:{padding:"0px"}},[s("gd-tables",{ref:"table",attrs:{dataSource:e.loadData,size:e.tableSize,pageSize:e.tablePageSize,columns:e.tableColumns,selectedRowKeys:e.selectedRowKeys,height:e.getHeight,filtering:!0,selectedKeep:e.selectedKeep,initialLoading:e.initialLoading},on:{onChange:e.onSelectChange},scopedSlots:e._u([{key:"name",fn:function({column:i,row:a}){return[s("gd-tooltip",{attrs:{rowKey:"name",row:a,highlight:""},on:{click:e.editForm}})]}},{key:"operator",fn:function(){return[s("div",{staticClass:"gd-table-operator"},[s("div",{staticClass:"gd-table-operatorl"},[s("el-input",{staticClass:"table-operator-input",attrs:{placeholder:e.$i18nt("gd.form.name","\u540D\u79F0"),clearable:""},nativeOn:{keyup:function(i){return!i.type.indexOf("key")&&e._k(i.keyCode,"enter",13,i.key,"Enter")?null:e.refresh.apply(null,arguments)}},model:{value:e.queryParam.name,callback:function(i){e.$set(e.queryParam,"name",i)},expression:"queryParam.name"}}),s("div",{staticClass:"table-operator-search",on:{click:e.refresh}},[s("i",{staticClass:"el-input__icon el-icon-search"})])],1),s("div",{staticClass:"gd-table-operatorr"},[e.openMode==="page"?s("gd-btn-list",{attrs:{sysViewButtons:e.tableButtons},on:{functionName:e.doEvent}}):e._e()],1)])]},proxy:!0},{key:"filtering",fn:function({colse:i,visible:a}){return[s("gd-table-queries-field",{attrs:{columns:e.tableQueries,height:e.getHeight,queryParam:e.queryParam,colse:i,visible:a},on:{save:e.saveQueries}})]}}])})],1),s("editForm",{ref:"editForm",attrs:{table:e.record},on:{ok:e.handleOk}})],1)},B=[],F=o.normalizeComponent(k,L,B,!1,null,"3966b20c",null,null);const c=F.exports;c.install=function(t){t.component(c.name,c)};exports.GDpackage=c;
|