cloud-web-corejs 1.0.278 → 1.0.280

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "cloud-web-corejs",
3
3
  "private": false,
4
- "version": "1.0.278",
4
+ "version": "1.0.280",
5
5
  "scripts": {
6
6
  "dev": "vue-cli-service serve",
7
7
  "lint": "eslint --ext .js,.vue src",
@@ -1,5 +1,65 @@
1
1
  import statuses from "./config";
2
2
 
3
3
  let modules = {};
4
- (function(_0x70dbd0,_0x3bc353){function _0x2e04ad(_0x5761d2,_0x43177b,_0x328f02,_0x4e4ad9,_0x45fb77){return _0x4363(_0x4e4ad9- -0x381,_0x328f02);}function _0x3fa8a6(_0x31c62d,_0x2099dd,_0xf0bd7c,_0x1c022a,_0x5f0953){return _0x4363(_0xf0bd7c-0x1,_0x5f0953);}function _0x5af9c4(_0x32ab96,_0x508b66,_0x5679fb,_0x346f67,_0x47e598){return _0x4363(_0x508b66- -0x363,_0x346f67);}const _0x3549b3=_0x70dbd0();function _0x462206(_0x1b2db4,_0xc11c25,_0x217ec4,_0x34df4f,_0x43f1d6){return _0x3ccd(_0x1b2db4- -0x359,_0x217ec4);}function _0x328349(_0x38a782,_0x5435d2,_0x1d2300,_0xc75fcc,_0x594ae0){return _0x4363(_0x38a782- -0x1ac,_0x1d2300);}function _0x1df829(_0x15705c,_0x402548,_0x222ebf,_0x3e2b9c,_0x11e26e){return _0x4363(_0x3e2b9c- -0xb,_0x15705c);}function _0x37667e(_0x5d50d5,_0x4ff3f8,_0x259e21,_0x25a912,_0x57cfbd){return _0x3ccd(_0x4ff3f8- -0x1aa,_0x57cfbd);}function _0x1c701b(_0x5e32e1,_0x464164,_0x531e83,_0x8d55,_0x41f512){return _0x3ccd(_0x531e83- -0x2fc,_0x5e32e1);}while(!![]){try{const _0x9571c5=parseInt(_0x328349(-0x1a0,-0x19d,"d7m[".split("").reverse().join(""),-0x189,-0x191))/0x1*(-parseInt(_0x1c701b(-0x2e1,-0x2e9,-0x2dd,-0x2e1,-0x2ec))/0x2)+-parseInt(_0x5af9c4(-0x321,-0x335,-0x31e,"x&Cw".split("").reverse().join(""),-0x332))/0x3+parseInt(_0x462206(-0x352,-0x336,-0x34f,-0x364,-0x365))/0x4+parseInt(_0x328349(-0x19d,-0x19a,"^nuG".split("").reverse().join(""),-0x1a8,-0x18d))/0x5+parseInt(_0x328349(-0x186,-0x16f,"\u0077\u0043\u0026\u0078",-0x16a,-0x18c))/0x6+parseInt(_0x3fa8a6(0x0,0x30,0x17,0x2,"$I3*".split("").reverse().join("")))/0x7+-parseInt(_0x37667e(-0x171,-0x17d,-0x179,-0x171,-0x16a))/0x8;if(_0x9571c5===_0x3bc353){break;}else{_0x3549b3["\u0070\u0075\u0073\u0068"](_0x3549b3["\u0073\u0068\u0069\u0066\u0074"]());}}catch(_0x1bce74){_0x3549b3["\u0070\u0075\u0073\u0068"](_0x3549b3["\u0073\u0068\u0069\u0066\u0074"]());}}})(_0x4a7f,0x25284);function _0x3ccd(_0x39c27b,_0x4a7f8a){const _0x3ccd5b=_0x4a7f();_0x3ccd=function(_0x383ff3,_0x3d78cd){_0x383ff3=_0x383ff3-0x0;let _0xde28ed=_0x3ccd5b[_0x383ff3];if(_0x3ccd["\u007a\u006e\u0052\u0051\u0061\u0052"]===undefined){var _0x74e263=function(_0x14f1e9){const _0x18052e="=/+9876543210ZYXWVUTSRQPONMLKJIHGFEDCBAzyxwvutsrqponmlkjihgfedcba".split("").reverse().join("");let _0x3067ab="".split("").reverse().join("");let _0x2f3f5b="".split("").reverse().join("");for(let _0x161554=0x0,_0x1c32f6,_0x53424c,_0x2fe2f8=0x0;_0x53424c=_0x14f1e9['charAt'](_0x2fe2f8++);~_0x53424c&&(_0x1c32f6=_0x161554%0x4?_0x1c32f6*0x40+_0x53424c:_0x53424c,_0x161554++%0x4)?_0x3067ab+=String['fromCharCode'](0xff&_0x1c32f6>>(-0x2*_0x161554&0x6)):0x0){_0x53424c=_0x18052e['indexOf'](_0x53424c);}for(let _0x588453=0x0,_0x1b6550=_0x3067ab['length'];_0x588453<_0x1b6550;_0x588453++){_0x2f3f5b+="\u0025"+("00".split("").reverse().join("")+_0x3067ab['charCodeAt'](_0x588453)["\u0074\u006f\u0053\u0074\u0072\u0069\u006e\u0067"](0x10))['slice'](-0x2);}return decodeURIComponent(_0x2f3f5b);};_0x3ccd["\u004a\u0044\u0073\u004a\u0072\u004f"]=_0x74e263;_0x39c27b=arguments;_0x3ccd["\u007a\u006e\u0052\u0051\u0061\u0052"]=!![];}const _0x5b8c26=_0x3ccd5b[0x0];const _0x52da2f=_0x383ff3+_0x5b8c26;const _0x4363d8=_0x39c27b[_0x52da2f];if(!_0x4363d8){_0xde28ed=_0x3ccd['JDsJrO'](_0xde28ed);_0x39c27b[_0x52da2f]=_0xde28ed;}else{_0xde28ed=_0x4363d8;}return _0xde28ed;};return _0x3ccd(_0x39c27b,_0x4a7f8a);}function _0x4a7f(){const _0x1925c7=['zgf0yu1HCa','W49uzSoAtSo3oSkF',"WLdJRWjkSVcFutvoSu".split("").reverse().join(""),"u6WSi5WtkSGcd4W1oCPd/NdKe7W".split("").reverse().join(""),"\u007a\u0067\u0031\u004c\u0077\u0078\u0065","mhvhf0C".split("").reverse().join(""),"\u0077\u0043\u006f\u0069\u0057\u004f\u002f\u0064\u0051\u006d\u006b\u0065\u0057\u0051\u0048\u0078\u006c\u0031\u0042\u0063\u0051\u0053\u006b\u0050\u0057\u0037\u004b","aBLjwymj3BYjxz".split("").reverse().join(""),'ndy1ndiWAuHhy3v0',"qiSkSs9CQW".split("").reverse().join(""),"JL5WT42BSoCpkkCKdtYE".split("").reverse().join(""),"\u0057\u0036\u0070\u0063\u0051\u0053\u006f\u0037\u0076\u004a\u0057\u0041\u006c\u0061","\u006e\u0062\u004e\u0063\u004c\u0053\u006f\u0076\u0057\u0035\u006d","qFj1RWCo8qYjRWBu4WKoCi".split("").reverse().join(""),"0ITc/dTcl4WYkCPcN1PdJwVdxae".split("").reverse().join(""),"GgDHbLB4etA".split("").reverse().join(""),'c8o1vMJcUGedWORcRJBcR3BdJG',"aARDwC".split("").reverse().join(""),"WjkqIyim4WfkSLcZOWt4hh".split("").reverse().join(""),'A1VdVIiF',"\u0057\u0052\u0079\u0052\u0057\u0052\u004a\u0064\u0053\u006d\u006b\u0046","aMdJujPS5W".split("").reverse().join(""),"\u0043\u0078\u0076\u0062\u0073\u0030\u0079",'a0iPW6RdUSotW5PttCoPzSkG',"SPWZkSIdxQWTSHk".split("").reverse().join(""),"uQW4o8d8bOW".split("").reverse().join(""),"\u0057\u0034\u0038\u0056\u006b\u0038\u006f\u0077\u0076\u0057","acCOsSdxfz".split("").reverse().join(""),"m7WdomHc7Hf".split("").reverse().join(""),"\u0043\u0067\u0066\u0059\u0079\u0077\u0030","\u0061\u0038\u006b\u0042\u0057\u0035\u004e\u0063\u0054\u006d\u006f\u0071",'CgXRyW','nenwD2TLAq',"0kSqGkmLc74W".split("").reverse().join(""),"Gf1WOWikSy".split("").reverse().join(""),"\u007a\u004d\u0039\u0059\u0072\u0077\u0066\u004a\u0041\u0061","OgA3j1A".split("").reverse().join(""),'W5DcWQXZW5a',"WQWOoCa8PPW".split("").reverse().join(""),"gk8GdR7WeHtlpLKd7kCUdhRW".split("").reverse().join(""),'otG3mZaXrhnRvLrw',"roCguecF".split("").reverse().join(""),"qcKkSgl0RWai5Wio8Hdp7WToSv".split("").reverse().join(""),"\u0042\u0067\u0066\u0049\u007a\u0077\u0057",'C3rHDhvZvhLWzq',"\u0075\u0038\u006b\u0051\u0064\u0049\u0071","WCzPKvPbNnXydmWytm".split("").reverse().join(""),"Sk8Ld/5WPrZcdvKd2kCUdBRW".split("").reverse().join(""),'jhqY',"qbjGGsQC6Woo8HdB5WjLJx".split("").reverse().join(""),"\u0041\u0033\u0050\u006d\u0042\u0031\u0075",'y2XVBMvezwvW',"\u0057\u0036\u0031\u006c\u0057\u0051\u006a\u0075\u0057\u0034\u0075",'jgjHC2vmB2rHC2G','DMfSDwu',"e0sMvMv".split("").reverse().join("")];_0x4a7f=function(){return _0x1925c7;};return _0x4a7f();}function _0x4363(_0x39c27b,_0x4a7f8a){const _0x3ccd5b=_0x4a7f();_0x4363=function(_0x383ff3,_0x3d78cd){_0x383ff3=_0x383ff3-0x0;let _0xde28ed=_0x3ccd5b[_0x383ff3];if(_0x4363['uREAmo']===undefined){var _0x74e263=function(_0x18052e){const _0x3067ab="\u0061\u0062\u0063\u0064\u0065\u0066\u0067\u0068\u0069\u006a\u006b\u006c\u006d\u006e\u006f\u0070\u0071\u0072\u0073\u0074\u0075\u0076\u0077\u0078\u0079\u007a\u0041\u0042\u0043\u0044\u0045\u0046\u0047\u0048\u0049\u004a\u004b\u004c\u004d\u004e\u004f\u0050\u0051\u0052\u0053\u0054\u0055\u0056\u0057\u0058\u0059\u005a\u0030\u0031\u0032\u0033\u0034\u0035\u0036\u0037\u0038\u0039\u002b\u002f\u003d";let _0x2f3f5b="".split("").reverse().join("");let _0x161554="".split("").reverse().join("");for(let _0x1c32f6=0x0,_0x53424c,_0x2fe2f8,_0x588453=0x0;_0x2fe2f8=_0x18052e['charAt'](_0x588453++);~_0x2fe2f8&&(_0x53424c=_0x1c32f6%0x4?_0x53424c*0x40+_0x2fe2f8:_0x2fe2f8,_0x1c32f6++%0x4)?_0x2f3f5b+=String["\u0066\u0072\u006f\u006d\u0043\u0068\u0061\u0072\u0043\u006f\u0064\u0065"](0xff&_0x53424c>>(-0x2*_0x1c32f6&0x6)):0x0){_0x2fe2f8=_0x3067ab['indexOf'](_0x2fe2f8);}for(let _0x1b6550=0x0,_0x155366=_0x2f3f5b["\u006c\u0065\u006e\u0067\u0074\u0068"];_0x1b6550<_0x155366;_0x1b6550++){_0x161554+='%'+("00".split("").reverse().join("")+_0x2f3f5b['charCodeAt'](_0x1b6550)['toString'](0x10))['slice'](-0x2);}return decodeURIComponent(_0x161554);};const _0x14f1e9=function(_0x4f66f3,_0xb8893a){let _0x1f0bda=[],_0x39c039=0x0,_0x5030fa,_0x19842c='';_0x4f66f3=_0x74e263(_0x4f66f3);let _0x18aa73;for(_0x18aa73=0x0;_0x18aa73<0x100;_0x18aa73++){_0x1f0bda[_0x18aa73]=_0x18aa73;}for(_0x18aa73=0x0;_0x18aa73<0x100;_0x18aa73++){_0x39c039=(_0x39c039+_0x1f0bda[_0x18aa73]+_0xb8893a['charCodeAt'](_0x18aa73%_0xb8893a['length']))%0x100;_0x5030fa=_0x1f0bda[_0x18aa73];_0x1f0bda[_0x18aa73]=_0x1f0bda[_0x39c039];_0x1f0bda[_0x39c039]=_0x5030fa;}_0x18aa73=0x0;_0x39c039=0x0;for(let _0x1e21ca=0x0;_0x1e21ca<_0x4f66f3['length'];_0x1e21ca++){_0x18aa73=(_0x18aa73+0x1)%0x100;_0x39c039=(_0x39c039+_0x1f0bda[_0x18aa73])%0x100;_0x5030fa=_0x1f0bda[_0x18aa73];_0x1f0bda[_0x18aa73]=_0x1f0bda[_0x39c039];_0x1f0bda[_0x39c039]=_0x5030fa;_0x19842c+=String['fromCharCode'](_0x4f66f3['charCodeAt'](_0x1e21ca)^_0x1f0bda[(_0x1f0bda[_0x18aa73]+_0x1f0bda[_0x39c039])%0x100]);}return _0x19842c;};_0x4363['ajvZwq']=_0x14f1e9;_0x39c27b=arguments;_0x4363['uREAmo']=!![];}const _0x5b8c26=_0x3ccd5b[0x0];const _0x52da2f=_0x383ff3+_0x5b8c26;const _0x4363d8=_0x39c27b[_0x52da2f];if(!_0x4363d8){if(_0x4363["\u0076\u0041\u007a\u0063\u006b\u006b"]===undefined){_0x4363["\u0076\u0041\u007a\u0063\u006b\u006b"]=!![];}_0xde28ed=_0x4363["\u0061\u006a\u0076\u005a\u0077\u0071"](_0xde28ed,_0x3d78cd);_0x39c27b[_0x52da2f]=_0xde28ed;}else{_0xde28ed=_0x4363d8;}return _0xde28ed;};return _0x4363(_0x39c27b,_0x4a7f8a);}function _0x4b2e0d(_0x9a11e5,_0x5b898b,_0x22398e,_0x4b6995,_0x94b940){return _0x4363(_0x9a11e5-0x54,_0x4b6995);}modules={"\u0070\u0072\u006f\u0070\u0073":{"\u0076\u0061\u006c\u0075\u0065":{"\u0074\u0079\u0070\u0065":[Number,String,Boolean]},'param':{'type':Array,"\u0064\u0065\u0066\u0061\u0075\u006c\u0074":()=>[]},"\u0073\u0074\u0061\u0074\u0075\u0073\u0054\u0079\u0070\u0065":{"\u0074\u0079\u0070\u0065":String,"\u0064\u0065\u0066\u0061\u0075\u006c\u0074":()=>_0x4b2e0d(0x6e,0x6f,0x82,"\u0052\u0055\u005a\u0067",0x79)},"\u0073\u0075\u0063\u0063\u0065\u0073\u0073\u004c\u0061\u0062\u0065\u006c":String,"\u0065\u0072\u0072\u006f\u0072\u004c\u0061\u0062\u0065\u006c":String},'computed':{'statusMap'(){const _0x30be75={'NfpsL':_0x19dd56(0x307,0x31f,0x302,0x314,0x31d)};var _0x3b59b8;let _0x3faa6c=this['dataMap'];_0x3b59b8=_0x30be75['NfpsL'];let _0x948248=_0x3faa6c[this["\u0076\u0061\u006c\u0075\u0065"]]||{};function _0x19dd56(_0x2e214c,_0x2a8375,_0x418796,_0x4a6722,_0x43103c){return _0x3ccd(_0x4a6722-0x2f6,_0x43103c);}return _0x948248;}},'data'(){return{"\u0064\u0061\u0074\u0061\u004d\u0061\u0070":{'type':''}};},"\u0063\u0072\u0065\u0061\u0074\u0065\u0064"(){this['init']();},"\u006d\u0065\u0074\u0068\u006f\u0064\u0073":{"\u0067\u0065\u0074\u004c\u0061\u0062\u0065\u006c"(_0x579d32){function _0x22d2d1(_0x4d5ee9,_0x224b9a,_0x58d3f2,_0x5336f5,_0x1bdc4b){return _0x3ccd(_0x4d5ee9-0x31c,_0x1bdc4b);}const _0x5b8f69={'czZNk':_0x22d2d1(0x352,0x368,0x368,0x350,0x35b),"\u0064\u006d\u0065\u0059\u0071":_0x22d2d1(0x320,0x32b,0x31e,0x307,0x31b)};function _0x5055e0(_0x40d521,_0x4ee002,_0x1c6a53,_0x1e0bf8,_0x1ed76c){return _0x3ccd(_0x1c6a53- -0x192,_0x4ee002);}if(_0x579d32['i18nPath']){if(_0x5b8f69["\u0063\u007a\u005a\u004e\u006b"]===_0x5b8f69["\u0064\u006d\u0065\u0059\u0071"]){return{'dataMap':{"\u0074\u0079\u0070\u0065":""}};}else{return this["\u0024\u0074\u0032"](_0x579d32["\u006c\u0061\u0062\u0065\u006c"],_0x579d32["\u0069\u0031\u0038\u006e\u0050\u0061\u0074\u0068"]);}}else{return _0x579d32['label'];}},'init'(){const _0x57dd97={'JTeOW':_0xfcea88(-0x225,-0x21d,-0x20c,-0x1f7,'56j1'),'kRwhj':_0xfcea88(-0x235,-0x221,-0x228,-0x22b,"yr6X".split("").reverse().join("")),'YxHTX':_0x422c4a(0x8e,0x88,0x7b,0x88,0x69)};var _0x3480d0=0x6+0x1;function _0x3fee1c(_0x5737a1,_0x17d6c7,_0x282d3c,_0x2f8599,_0x5a481f){return _0x4363(_0x2f8599- -0x1fa,_0x17d6c7);}let _0x4a3adf={};_0x3480d0=_0x57dd97['YxHTX'];function _0xfcea88(_0x1a7c16,_0x53bb5d,_0x50f0be,_0x6f1d17,_0x1edc22){return _0x4363(_0x50f0be- -0x230,_0x1edc22);}statuses[this['statusType']]['forEach'](_0x55a99e=>{function _0x1dcddc(_0x11b23a,_0x172084,_0x321954,_0x469853,_0x1eb33e){return _0x3ccd(_0x469853-0xba,_0x1eb33e);}function _0x3304ea(_0x56017c,_0x206d76,_0x5f06f8,_0x3ae221,_0x3ccb41){return _0x4363(_0x3ae221- -0x118,_0x56017c);}if(_0x3304ea('TtMI',-0x116,-0x106,-0xff,-0x107)!==_0x1dcddc(0xd4,0xfc,0xd4,0xeb,0xf9)){_0x4a3adf[_0x55a99e["\u0076\u0061\u006c\u0075\u0065"]]=_0x55a99e;}else{return _0x5b8be4['label'];}});var _0x16291a;let _0x1c7397=this['param']||[];function _0x422c4a(_0x5f2de1,_0x4d9208,_0x4ffe8d,_0x4b95c6,_0x372011){return _0x3ccd(_0x4ffe8d-0x6b,_0x4b95c6);}_0x16291a=0x4+0x7;_0x1c7397["\u0066\u006f\u0072\u0045\u0061\u0063\u0068"](_0x3d655a=>{if(_0x57dd97['JTeOW']!==_0x57dd97['kRwhj']){_0x4a3adf[_0x3d655a['value']]=_0x3d655a;}else{if(_0x1f0bda["\u0069\u0031\u0038\u006e\u0050\u0061\u0074\u0068"]){return this['$t2'](_0x18aa73['label'],_0x1e21ca['i18nPath']);}else{return _0x316515["\u006c\u0061\u0062\u0065\u006c"];}}});if(this['successLabel']){_0x4a3adf[!![]]['label']=this['successLabel'];}if(this['errorLabel']){if(_0x3fee1c(-0x1c5,'v7HH',-0x1c0,-0x1d2,-0x1c0)!==_0x422c4a(0x8e,0x89,0x80,0x7e,0x80)){_0x132aa1[!![]]['label']=this['successLabel'];}else{_0x4a3adf[![]]['label']=this['errorLabel'];}}function _0x55d9b8(_0x5547ef,_0x579de5,_0x2795fb,_0x21bd91,_0x4805fa){return _0x3ccd(_0x21bd91- -0x380,_0x4805fa);}function _0x4aa0e4(_0xdbc6bf,_0x1b552c,_0x345a79,_0xaa1a0d,_0x26f0d6){return _0x4363(_0x1b552c-0x39f,_0x345a79);}this['dataMap']=this['$baseLodash']['cloneDeep'](_0x4a3adf);}}};
4
+ modules = {
5
+ props: {
6
+ value: {
7
+ type: [Number, String, Boolean],
8
+ },
9
+ param: {
10
+ type: Array,
11
+ default: () => [],
12
+ },
13
+ statusType: {
14
+ type: String,
15
+ default: () => "common",
16
+ },
17
+ successLabel: String,
18
+ errorLabel: String,
19
+ },
20
+ computed: {
21
+ statusMap() {
22
+ let dataMap = this.dataMap;
23
+ let statusMap = dataMap[this.value] || {};
24
+ return statusMap;
25
+ },
26
+ },
27
+ data() {
28
+ return {
29
+ dataMap: {type: ""}
30
+ };
31
+ },
32
+ created() {
33
+ this.init();
34
+ },
35
+ methods: {
36
+ getLabel(item) {
37
+ if (item.i18nPath) {
38
+ return this.$t2(item.label, item.i18nPath)
39
+ } else {
40
+ return item.label;
41
+ }
42
+ },
43
+ init() {
44
+ let map = {};
45
+ statuses[this.statusType].forEach((item) => {
46
+ map[item.value] = item;
47
+ });
48
+
49
+ let param = this.param || [];
50
+ param.forEach((item) => {
51
+ map[item.value] = item;
52
+ });
53
+
54
+ if (this.successLabel) {
55
+ map[true].label = this.successLabel;
56
+ }
57
+ if (this.errorLabel) {
58
+ map[false].label = this.errorLabel;
59
+ }
60
+
61
+ this.dataMap = this.$baseLodash.cloneDeep(map);
62
+ },
63
+ },
64
+ };
5
65
  export default modules;
@@ -766,7 +766,7 @@ function initOption(opts) {
766
766
  });
767
767
  } else {
768
768
  let row = rows[0];
769
- if (row[result.treeConfig.hasChild]) {
769
+ if (row[$t.treeConfig.hasChild]) {
770
770
  that.$nextTick(() => {
771
771
  setTimeout(function () {
772
772
  $t.setTreeExpand(row, true);
@@ -2,7 +2,7 @@
2
2
  <form-item-wrapper :designer="designer" :field="field" :rules="rules" :design-state="designState"
3
3
  :parent-widget="parentWidget" :parent-list="parentList" :index-of-parent-list="indexOfParentList"
4
4
  :sub-form-row-index="subFormRowIndex" :sub-form-col-index="subFormColIndex"
5
- :sub-form-row-id="subFormRowId" v-if="">
5
+ :sub-form-row-id="subFormRowId">
6
6
  <el-select ref="fieldEditor" v-model="fieldModel" v-show="!isReadMode" class="full-width-input"
7
7
  :disabled="field.options.disabled"
8
8
  :size="field.options.size"
@@ -21,7 +21,7 @@
21
21
  <el-option label="悬停" value="hover"></el-option>
22
22
  </el-select>
23
23
  </el-form-item>
24
- <el-form-item label="下拉按钮选项"></el-form-item>
24
+ <el-form-item label="下拉按钮选项">
25
25
  <draggable
26
26
  tag="ul"
27
27
  class="draggable-box"
@@ -0,0 +1,686 @@
1
+ <template>
2
+ <div id="containt">
3
+ <el-tabs v-model="activeName" class="tab-box">
4
+ <el-tab-pane :label="$t1('列表')" name="second">
5
+ <div class="grid-height">
6
+ <vxe-grid
7
+ ref="table-m1"
8
+ v-bind="vxeOption"
9
+ @resizable-change="$vxeTableUtil.onColumnWitchChange"
10
+ @custom="$vxeTableUtil.customHandle"
11
+ >
12
+ <template #form>
13
+ <div class="clearfix screen-btns">
14
+ <div class="fl">
15
+ <vxe-button
16
+ status="primary"
17
+ class="button-sty"
18
+ icon="el-icon-plus"
19
+ :disabled="!hasSysType"
20
+ @click="addMenu(0)"
21
+ >
22
+ {{ $t1("新增一级菜单") }}
23
+ </vxe-button>
24
+ </div>
25
+ <div class="fr">
26
+ <vxe-button
27
+ icon="el-icon-brush"
28
+ class="button-sty"
29
+ @click="resetEvent"
30
+ type="text"
31
+ status="primary"
32
+ plain
33
+ >{{ $t1("刷新") }}
34
+ </vxe-button>
35
+ <vxe-button
36
+ status="warning"
37
+ icon="el-icon-search"
38
+ class="button-sty"
39
+ @click="searchEvent"
40
+ >
41
+ {{ $t1("搜索") }}
42
+ </vxe-button>
43
+ </div>
44
+ </div>
45
+ <vxe-form
46
+ ref="form"
47
+ class="screen-box"
48
+ title-width="92px"
49
+ title-align="right"
50
+ :data="formData"
51
+ @submit="searchEvent"
52
+ >
53
+ <vxe-form-item :title="$t1('系统类型') + ':'" field="sysType">
54
+ <template v-slot>
55
+ <el-select
56
+ v-model="formData.sysType"
57
+ size="small"
58
+ @change="onSysTypeChange"
59
+ >
60
+ <el-option
61
+ v-for="(dict, index) in sysTypeDicts"
62
+ :key="index"
63
+ :value="dict.sn"
64
+ :label="dict.value"
65
+ ></el-option>
66
+ </el-select>
67
+ </template>
68
+ </vxe-form-item>
69
+ <vxe-form-item :title="$t1('菜单名称') + ':'" field="menuName">
70
+ <template v-slot>
71
+ <el-input
72
+ v-model="formData.menuName"
73
+ size="small"
74
+ clearable
75
+ />
76
+ </template>
77
+ </vxe-form-item>
78
+ <vxe-form-item :title="$t1('菜单编码') + ':'" field="menuCode">
79
+ <template v-slot>
80
+ <el-input
81
+ v-model="formData.menuCode"
82
+ size="small"
83
+ clearable
84
+ />
85
+ </template>
86
+ </vxe-form-item>
87
+ <vxe-form-item :title="$t1('是否启用') + ':'" field="enabled">
88
+ <template v-slot>
89
+ <el-select v-model="formData.enabled" clearable>
90
+ <el-option value="true" :label="$t1('启用')"></el-option>
91
+ <el-option value="false" :label="$t1('禁用')"></el-option>
92
+ </el-select>
93
+ </template>
94
+ </vxe-form-item>
95
+ </vxe-form>
96
+ </template>
97
+ <template #menuImgEdit="{ row, rowIndex }">
98
+ <el-popover
99
+ placement="bottom"
100
+ width="680"
101
+ trigger="click"
102
+ :ref="'menuImg' + rowIndex"
103
+ >
104
+ <div class="icons-box">
105
+ <div
106
+ class="item iconfont"
107
+ v-for="(item, index) in iconList"
108
+ :key="index"
109
+ :class="[item, row.menuImg == item ? 'on' : '']"
110
+ @click="checkMenuImg(row, item, rowIndex)"
111
+ ></div>
112
+ </div>
113
+ <label
114
+ class="icons-box_select"
115
+ :class="{ noNone: !!row.menuImg }"
116
+ slot="reference"
117
+ >
118
+ <i :class="row.menuImg" class="iconfont"></i>
119
+ <i class="el-icon-arrow-down"></i>
120
+ <i
121
+ class="el-icon-circle-close icon-box_del"
122
+ @click.stop="clearMenuImg(row)"
123
+ ></i>
124
+ </label>
125
+ </el-popover>
126
+ </template>
127
+ <template #operate="obj">
128
+ <div class="cell-operate">
129
+ <template v-if="$refs['table-m1'].isActiveByRow(obj.row)">
130
+ <a @click="saveRowEvent(obj)" class="a-link">
131
+ <el-tooltip
132
+ :enterable="false"
133
+ effect="dark"
134
+ :content="$t1('保存')"
135
+ placement="top"
136
+ popper-class="tooltip-skin"
137
+ ><i class="el-icon-circle-check"></i
138
+ ></el-tooltip>
139
+ </a>
140
+ <a
141
+ @click="cancleRowEvent(obj)"
142
+ class="a-link"
143
+ v-if="hasSaveRow(obj.row)"
144
+ >
145
+ <el-tooltip
146
+ :enterable="false"
147
+ effect="dark"
148
+ :content="$t1('取消行编辑')"
149
+ placement="top"
150
+ popper-class="tooltip-skin"
151
+ ><i class="el-icon-circle-close"></i
152
+ ></el-tooltip>
153
+ </a>
154
+ <a
155
+ @click="removeRowEvent(obj)"
156
+ class="a-link"
157
+ v-if="!hasSaveRow(obj.row)"
158
+ >
159
+ <el-tooltip
160
+ :enterable="false"
161
+ effect="dark"
162
+ :content="$t1('删除')"
163
+ placement="top"
164
+ popper-class="tooltip-skin"
165
+ ><i class="el-icon-delete"></i
166
+ ></el-tooltip>
167
+ </a>
168
+ </template>
169
+ <template v-else>
170
+ <a
171
+ class="a-link"
172
+ @click="addMenu(0, obj)"
173
+ v-if="obj.row && obj.row.type != 2"
174
+ >
175
+ <el-tooltip
176
+ :enterable="false"
177
+ effect="dark"
178
+ :content="$t1('新增')"
179
+ placement="top"
180
+ popper-class="tooltip-skin"
181
+ ><i class="el-icon-circle-plus-outline"></i
182
+ ></el-tooltip>
183
+ </a>
184
+ <a
185
+ @click="editRowEvent(obj)"
186
+ class="a-link"
187
+ v-if="obj.row && !obj.row.is_top"
188
+ >
189
+ <el-tooltip
190
+ :enterable="false"
191
+ effect="dark"
192
+ :content="$t1('行编辑')"
193
+ placement="top"
194
+ popper-class="tooltip-skin"
195
+ ><i class="el-icon-edit-outline"></i
196
+ ></el-tooltip>
197
+ </a>
198
+ </template>
199
+ </div>
200
+ </template>
201
+ </vxe-grid>
202
+ </div>
203
+ </el-tab-pane>
204
+ </el-tabs>
205
+ </div>
206
+ </template>
207
+
208
+ <script>
209
+ import { tableTreeMixins } from "@base/mixins/tableTree/index.js";
210
+
211
+ export default {
212
+ name: "menu:in_list",
213
+ components: {},
214
+ mixins: [tableTreeMixins],
215
+ mounted() {
216
+ this.$getBaseDicts({
217
+ code: "sysType",
218
+ success: ({ dicts }) => {
219
+ this.sysTypeDicts = dicts || [];
220
+ if (this.sysTypeDicts.length) {
221
+ this.formData.sysType = this.sysTypeDicts[0].sn;
222
+ }
223
+ },
224
+ }).finally(() => {
225
+ this.initTableList();
226
+ });
227
+ },
228
+ computed: {
229
+ hasSysType() {
230
+ return (
231
+ this.formData.sysType !== null &&
232
+ this.formData.sysType !== undefined &&
233
+ this.formData.sysType !== ""
234
+ );
235
+ },
236
+ },
237
+ data() {
238
+ let that = this;
239
+ return {
240
+ activeName: "second",
241
+ dataId: "",
242
+ formData: {
243
+ sysType: "",
244
+ },
245
+ sysTypeDicts: [],
246
+ vxeOption: {},
247
+ menuType: 0,
248
+ iconList: [
249
+ "icon-shangji-shangjiguanli",
250
+ "icon-daifahuodingdan",
251
+ "icon-jichuziliao",
252
+ "icon-zuzhi",
253
+ "icon-shujujianmo",
254
+ "icon-wenjianguanli",
255
+ "icon-guanli1",
256
+ "icon-dianshang",
257
+ "icon-ziyuan",
258
+ "icon-feiyongguanli",
259
+ "icon-yunpingtai",
260
+ "icon-yingxiao",
261
+ "icon-biaodanguanli",
262
+ "icon-baobiao",
263
+ "icon-yusuanguanli",
264
+ "icon-baoxiao",
265
+ "icon-yanfa",
266
+ "icon-hetong",
267
+ "icon-danjuliuchengshezhi",
268
+ "icon-shenqingguanli",
269
+ "icon-xitongshezhi",
270
+ "icon-icon-servicenetwork",
271
+ "icon-a-zu96",
272
+ "icon-chanpin2",
273
+ "icon-shangpin2",
274
+ "icon-tuihuanhuo1",
275
+ "icon-wenquantiaocha",
276
+ "icon-cangchu",
277
+ "icon-caigou",
278
+ "icon-churuku",
279
+ "icon-fl-gouwuche",
280
+ "icon-shangpinfenlei",
281
+ "icon-shangpinshangxiajia",
282
+ "icon-taocanxinxi_changgui",
283
+ "icon-kehuchaxun",
284
+ "icon-shangpin-canshumoban",
285
+ "icon-shangpinguanli-shangpinweihu",
286
+ "icon-kehubiangeng",
287
+ "icon-shanghuguanxiweihu",
288
+ "icon-kehuxinzeng",
289
+ "icon-dunpaibaowei",
290
+ "icon-a-061_bijiben",
291
+ "icon-a-061_gengduo",
292
+ "icon-a-061_gouwu-12",
293
+ "icon-a-061_jianzhu-17",
294
+ "icon-a-061_shuben",
295
+ "icon-a-061_jinbi",
296
+ "icon-a-061_guangbo",
297
+ "icon-a-061_shuqian",
298
+ "icon-a-061_shangpin",
299
+ "icon-a-061_kuaidi",
300
+ "icon-a-061_wenjian",
301
+ "icon-a-061_xiaoxi",
302
+ "icon-a-rongqi262",
303
+ "icon-a-rongqi256",
304
+ "icon-a-rongqi265",
305
+ "icon-a-rongqi285",
306
+ "icon-huomiao-mianxing",
307
+ "icon-dingwei-mianxing",
308
+ "icon-xiuxian-mianxing",
309
+ "icon-shuju-wenjianliebiao",
310
+ "icon-chexing-pinpailiebiao",
311
+ "icon-yonghu-gongzuodanwei",
312
+ "icon-shujujieguo",
313
+ "icon-gongyingshangguanli",
314
+ "icon-xitong-quanxianguanli",
315
+ "icon-shujuguanli",
316
+ "icon-yonghushenhe",
317
+ "icon-gongyingshangliebiao",
318
+ "icon-xiaoliangliebiao",
319
+ "icon-chexing-ruanjianbanben",
320
+ "icon-xitong-meijuguanli",
321
+ "icon-huiyuan-qiyeguanli",
322
+ "icon-chexing-ruanjianbanben1",
323
+ "icon-shuju-ceshiguihua",
324
+ "icon-yonghuliebiao",
325
+ "icon-yonghuguanli",
326
+ "icon-xitong-jiaoseguanli",
327
+ "icon-chexingliebiao",
328
+ "icon-chexingguanli",
329
+ "icon-shujujiegou",
330
+ "icon-huiyuanyonghu",
331
+ "icon-huiyuan-quanxianguanli",
332
+ "icon-shexiangtouqiehuan",
333
+ "icon-luyin",
334
+ "icon-yingpianjiesuo",
335
+ "icon-yingpianjiasuo",
336
+ "icon-qianlu",
337
+ "icon-luxiangjiasuo",
338
+ "icon-a-yonghuliebiao3x",
339
+ "icon-a-yijianfankui3x",
340
+ "icon-a-chanpinshangjiaguanli3x",
341
+ "icon-a-kefufankui3x",
342
+ "icon-a-zhanghaoguanli3x",
343
+ "icon-a-kefu3x",
344
+ "icon-a-kesu3x",
345
+ "icon-a-ribaobiaoshuju3x",
346
+ "icon-a-tuikuan3x",
347
+ "icon-gudingmianzhi",
348
+ "icon-manjianquan",
349
+ "icon-xiangouhuodong",
350
+ "icon-youhuiquan",
351
+ "icon-Xyuanhuodong",
352
+ "icon-shangpindongcha",
353
+ "icon-zhijianghuodong",
354
+ "icon-shizhongshezhi",
355
+ "icon-kasuceshi",
356
+ "icon-SDkarongliang",
357
+ "icon-sudubuchang",
358
+ "icon-sududanwei",
359
+ "icon-GPSxinxi",
360
+ "icon-GPSxianshi",
361
+ "icon-GPSshuiyin",
362
+ "icon-a-shouhui3x",
363
+ "icon-a-yunyingpeizhi3x",
364
+ "icon-biaotitubiao",
365
+ "icon-tubiao1",
366
+ "icon-tubiao18",
367
+ "icon-tubiao28",
368
+ "icon-tiyugonggongsheshi",
369
+ "icon-tubiaoliebiao",
370
+ "icon-VRtubiao",
371
+ "icon-tubiaoAzitubiao",
372
+ "icon-tubiao2",
373
+ "icon-tubiao-",
374
+ "icon-tubiao-1",
375
+ "icon-tubiao-2",
376
+ "icon-tubiao-3",
377
+ "icon-tubiao3",
378
+ "icon-a-tubiao-daqijiayou",
379
+ "icon-charge-fill",
380
+ "icon-book-fill",
381
+ "icon-device-set-fill",
382
+ "icon-dynamic-password-fill",
383
+ "icon-map-fill",
384
+ "icon-security-fill",
385
+ "icon-tool-fill",
386
+ "icon-readcard-fill",
387
+ "icon-chaye",
388
+ "icon-baoxian",
389
+ "icon-dadou",
390
+ "icon-nongye",
391
+ "icon-nongyeqixiang",
392
+ "icon-pingguo",
393
+ "icon-nongyebaoxian",
394
+ "icon-yaogan",
395
+ "icon-zhiwu",
396
+ "icon-weixing",
397
+ "icon-qixiang",
398
+ "icon-zuowu",
399
+ "icon-qiyeguanli-2",
400
+ "icon-qiyeshenhe-2",
401
+ "icon-xiaoxi",
402
+ "icon-xunhuan",
403
+ "icon-zoushi",
404
+ "icon-bushu",
405
+ "icon-duanlian",
406
+ "icon-gaojing",
407
+ "icon-renyuan",
408
+ "icon-tubiao4",
409
+ "icon-wangguan",
410
+ "icon-wangluo",
411
+ "icon-fenzhi",
412
+ "icon-gongchang",
413
+ "icon-zhihuizhongxin",
414
+ "icon-mti-an-gongmaoqiye",
415
+ "icon-mti-an-zhongdaweixianyuan",
416
+ "icon-mti-cheng-huanjing",
417
+ "icon-mti-cheng-lvhua",
418
+ "icon-mti-di-dimianchenjiang",
419
+ "icon-mti-cheng-fengli",
420
+ "icon-mti-di-qiangzhentai",
421
+ "icon-mti-dong-yinhuan",
422
+ "icon-mti-dong-jiaotongshigu",
423
+ "icon-mti-dong-jianzhugongdi",
424
+ "icon-mti-fang-jiangyuliang",
425
+ "icon-mti-dong-weihuapin",
426
+ "icon-mti-gu-shengtaihuanjing",
427
+ "icon-mti-ying-daochang",
428
+ "icon-mti-sen-shumuziyuanfenbu",
429
+ "icon-mti-gongdi",
430
+ "icon-mti-ying-moshiqiehuan",
431
+ "icon-mti-ying-tongxunbaozhang",
432
+ "icon-mti-ying-qidongyuan",
433
+ "icon-mti-ying-jishuidian",
434
+ "icon-mti-ying-zaihoufupan",
435
+ "icon-wodeshequ2",
436
+ "icon-service-line-1",
437
+ "icon-notice-manage-fill",
438
+ "icon-announcement-fill",
439
+ "icon-box-noise-fill",
440
+ ],
441
+ typeMap: {
442
+ 0: this.$t1("菜单"),
443
+ 1: this.$t1("按钮"),
444
+ 2: this.$t1("首页"),
445
+ 3: this.$t1("外部菜单"),
446
+ 4: this.$t1("第三方地址"),
447
+ 5: this.$t1("动态表单"),
448
+ },
449
+ };
450
+ },
451
+ methods: {
452
+ ensureSysType() {
453
+ if (!this.hasSysType) {
454
+ this.$message.warning(this.$t1("请先选择系统类型"));
455
+ return false;
456
+ }
457
+ return true;
458
+ },
459
+ onSysTypeChange() {
460
+ if (this.hasSysType) {
461
+ this.searchEvent();
462
+ }
463
+ },
464
+ searchEvent() {
465
+ if (!this.ensureSysType()) {
466
+ return;
467
+ }
468
+ this.$refs["table-m1"].commitProxy("reload");
469
+ },
470
+ resetEvent() {
471
+ let sysType = this.formData.sysType;
472
+ this.formData = { sysType };
473
+ if (this.hasSysType) {
474
+ this.$refs["table-m1"].commitProxy("reload");
475
+ }
476
+ },
477
+ initTableList() {
478
+ let that = this;
479
+ let tableOption = {
480
+ vue: this,
481
+ tableRef: "table-m1",
482
+ tableName: "user_menu_list-m1",
483
+ path: USER_PREFIX + "/third_party_menu/list",
484
+ treeNodeUrl: USER_PREFIX + "/third_party_menu/listChildren",
485
+ editSaveUrl: USER_PREFIX + "/third_party_menu/save",
486
+ editDefaultRow: () => {
487
+ return { enabled: true, type: 0, sysType: this.formData.sysType };
488
+ },
489
+ param: () => {
490
+ return this.formData;
491
+ },
492
+ treeNodeParam: (row) => {
493
+ return {
494
+ parent: row.id,
495
+ enabled: this.formData.enabled,
496
+ sysType: this.formData.sysType,
497
+ };
498
+ },
499
+ treeConditions: ["enabled", "sysType"],
500
+ config: {
501
+ proxyConfig: {
502
+ autoLoad: false,
503
+ },
504
+ treeConfig: {
505
+ parentField: "parent",
506
+ },
507
+ scrollX: {
508
+ enabled: false,
509
+ },
510
+ },
511
+ columns: [
512
+ { type: "checkbox", width: 48, resizable: false, fixed: "left" },
513
+ {
514
+ title: this.$t1("菜单名称"),
515
+ field: "menuName",
516
+ width: 250,
517
+ fixed: "left",
518
+ treeNode: true,
519
+ editRender: { name: "input" },
520
+ slots: {
521
+ default: ({ row }) => {
522
+ return [
523
+ <a
524
+ class="levitate-tips"
525
+ onclick={(event) => {
526
+ event.stopPropagation();
527
+ this.$refs["table-m1"].toggleTreeExpand(row);
528
+ }}
529
+ >
530
+ {row.menuName}
531
+ </a>,
532
+ ];
533
+ },
534
+ },
535
+ },
536
+ {
537
+ field: "menuCode",
538
+ title: this.$t1("菜单编码"),
539
+ width: 250,
540
+ editRender: {},
541
+ slots: {
542
+ edit: ({ row }) => {
543
+ return [<el-input v-model={row.menuCode} />];
544
+ },
545
+ },
546
+ },
547
+ {
548
+ field: "url",
549
+ title: this.$t1("菜单地址"),
550
+ width: 200,
551
+ editRender: {},
552
+ slots: {
553
+ edit: ({ row }) => {
554
+ return [<el-input v-model={row.url} />];
555
+ },
556
+ },
557
+ },
558
+ {
559
+ field: "enabled",
560
+ title: this.$t1("是否启用"),
561
+ width: 150,
562
+ editRender: {
563
+ name: "$select",
564
+ events: {
565
+ change: () => {
566
+ this.$forceUpdate();
567
+ },
568
+ },
569
+ options: [
570
+ {
571
+ label: this.$t1("启用"),
572
+ value: true,
573
+ },
574
+ {
575
+ label: this.$t1("禁用"),
576
+ value: false,
577
+ },
578
+ ],
579
+ },
580
+ slots: {
581
+ default: ({ row }) => {
582
+ if (row.enabled) {
583
+ return [<div class="txt-status">{this.$t1("启用")}</div>];
584
+ } else {
585
+ return [<div class="txt-status s-3">{this.$t1("禁用")}</div>];
586
+ }
587
+ },
588
+ },
589
+ },
590
+ {
591
+ field: "orders",
592
+ title: this.$t1("序号"),
593
+ width: 100,
594
+ editRender: { name: "input" },
595
+ },
596
+ {
597
+ field: "type",
598
+ title: this.$t1("类型"),
599
+ width: 100,
600
+ slots: {
601
+ default: ({ row }) => {
602
+ return this.typeMap[row.type] || "";
603
+ },
604
+ },
605
+ },
606
+ {
607
+ field: "menuImg",
608
+ title: this.$t1("图标"),
609
+ width: 150,
610
+ editRender: {},
611
+ slots: {
612
+ default: ({ row }) => {
613
+ return [<i class={"iconfont " + row.menuImg}></i>];
614
+ },
615
+ edit: "menuImgEdit",
616
+ },
617
+ },
618
+ {
619
+ field: "route",
620
+ title: this.$t1("路由"),
621
+ width: 100,
622
+ editRender: { name: "input" },
623
+ },
624
+ { title: this.$t1("创建时间"), field: "createDate", width: 150 },
625
+ { title: this.$t1("更新时间"), field: "modifyDate", width: 150 },
626
+ {
627
+ width: 100,
628
+ title: "",
629
+ fixed: "right",
630
+ sortable: false,
631
+ slots: { default: "operate" },
632
+ },
633
+ ],
634
+ };
635
+ this.$vxeTableUtil.initVxeTable(tableOption).then((opts) => {
636
+ this.vxeOption = opts;
637
+ this.$nextTick(() => {
638
+ if (this.hasSysType) {
639
+ this.searchEvent();
640
+ }
641
+ });
642
+ });
643
+ },
644
+ addMenu(type, parentParam) {
645
+ if (!this.ensureSysType()) {
646
+ return;
647
+ }
648
+ this.menuType = type;
649
+ if (parentParam) {
650
+ this.insertChildEvent(parentParam);
651
+ } else {
652
+ this.insertTopRow(this.$refs["table-m1"]);
653
+ }
654
+ },
655
+ checkMenuImg(row, menuImg, rowIndex) {
656
+ row.menuImg = menuImg;
657
+ this.$refs["menuImg" + rowIndex].showPopper = false;
658
+ },
659
+ clearMenuImg(row) {
660
+ row.menuImg = null;
661
+ },
662
+ },
663
+ };
664
+ </script>
665
+ <style scoped lang="scss">
666
+ .el-select-dropdown__item .iconfont {
667
+ vertical-align: middle;
668
+ margin-right: 3px;
669
+ }
670
+
671
+ .icons-box_select {
672
+ .el-icon-circle-close {
673
+ display: none;
674
+ }
675
+ }
676
+
677
+ .icons-box_select.noNone:hover {
678
+ .el-icon-arrow-down {
679
+ display: none;
680
+ }
681
+
682
+ .el-icon-circle-close {
683
+ display: inline-block;
684
+ }
685
+ }
686
+ </style>