@zhijiancloud/bpm 0.0.12 → 0.0.14

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.
@@ -1 +1 @@
1
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("lodash")):"function"==typeof define&&define.amd?define(["lodash"],t):"object"==typeof exports?exports.bpm2=t(require("lodash")):e.bpm2=t(e.lodash)}(self,(function(e){return function(){var t={7279:function(e,t,n){"use strict";var r=n(8081),o=n.n(r),i=n(3645),a=n.n(i)()(o());a.push([e.id,"\n.bpm-text-edit{\n .prefab-words {\n padding-top: 10px;\n ul,\n li {\n margin: 0;\n padding: 0;\n list-style: none;\n }\n \n ul {\n overflow: hidden;\n margin-top: 5px;\n }\n \n li {\n float: left;\n min-height: 28px;\n line-height: 28px;\n cursor: pointer;\n min-width: 50px;\n font-size: 14px;\n padding: 0 10px;\n margin-right: 10px;\n border: 1px solid #DCDCDC;\n border-radius: 100px;\n color: #666666;\n text-align: center;\n margin-bottom: 5px;\n }\n \n li.active {\n background: #1EAAD0;\n border: 1px solid #1EAAD0;\n color: #fff;\n }\n }\n }\n",""]),t.Z=a},2576:function(e,t,n){"use strict";var r=n(8081),o=n.n(r),i=n(3645),a=n.n(i),u=n(7279),s=a()(o());s.i(u.Z),s.push([e.id,"\n",""]),t.Z=s},3645:function(e){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",r=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),r&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),r&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,r,o,i){"string"==typeof e&&(e=[[null,e,void 0]]);var a={};if(r)for(var u=0;u<this.length;u++){var s=this[u][0];null!=s&&(a[s]=!0)}for(var c=0;c<e.length;c++){var l=[].concat(e[c]);r&&a[l[0]]||(void 0!==i&&(void 0===l[5]||(l[1]="@layer".concat(l[5].length>0?" ".concat(l[5]):""," {").concat(l[1],"}")),l[5]=i),n&&(l[2]?(l[1]="@media ".concat(l[2]," {").concat(l[1],"}"),l[2]=n):l[2]=n),o&&(l[4]?(l[1]="@supports (".concat(l[4],") {").concat(l[1],"}"),l[4]=o):l[4]="".concat(o)),t.push(l))}},t}},8081:function(e){"use strict";e.exports=function(e){return e[1]}},3379:function(e){"use strict";var t=[];function n(e){for(var n=-1,r=0;r<t.length;r++)if(t[r].identifier===e){n=r;break}return n}function r(e,r){for(var i={},a=[],u=0;u<e.length;u++){var s=e[u],c=r.base?s[0]+r.base:s[0],l=i[c]||0,p="".concat(c," ").concat(l);i[c]=l+1;var f=n(p),d={css:s[1],media:s[2],sourceMap:s[3],supports:s[4],layer:s[5]};if(-1!==f)t[f].references++,t[f].updater(d);else{var v=o(d,r);r.byIndex=u,t.splice(u,0,{identifier:p,updater:v,references:1})}a.push(p)}return a}function o(e,t){var n=t.domAPI(t);return n.update(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap&&t.supports===e.supports&&t.layer===e.layer)return;n.update(e=t)}else n.remove()}}e.exports=function(e,o){var i=r(e=e||[],o=o||{});return function(e){e=e||[];for(var a=0;a<i.length;a++){var u=n(i[a]);t[u].references--}for(var s=r(e,o),c=0;c<i.length;c++){var l=n(i[c]);0===t[l].references&&(t[l].updater(),t.splice(l,1))}i=s}}},569:function(e){"use strict";var t={};e.exports=function(e,n){var r=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}},9216:function(e){"use strict";e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},3565:function(e,t,n){"use strict";e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7795:function(e){"use strict";e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var r="";n.supports&&(r+="@supports (".concat(n.supports,") {")),n.media&&(r+="@media ".concat(n.media," {"));var o=void 0!==n.layer;o&&(r+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),r+=n.css,o&&(r+="}"),n.media&&(r+="}"),n.supports&&(r+="}");var i=n.sourceMap;i&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(i))))," */")),t.styleTagTransform(r,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},4589:function(e){"use strict";e.exports=function(e,t){if(t.styleSheet)t.styleSheet.cssText=e;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(e))}}},1478:function(e,t,n){"use strict";n.d(t,{Z:function(){return C}});var r=function(){var e=this,t=e.$createElement;return(e._self._c||t)("span",{staticClass:"bpm-text-view",class:e.uiType+"-text-view",attrs:{title:e._value}},[e._v("\n "+e._s(e._value&&0!==e._value?e.value:"--")+"\n")])};r._withStripped=!0;var o=n(467),i=n.n(o),a={props:["value","fieldConf","row","uiType"],computed:{_value(){return i().get(this.row,this.fieldConf.id)||this.value}}},u=n(3379),s=n.n(u),c=n(7795),l=n.n(c),p=n(569),f=n.n(p),d=n(3565),v=n.n(d),m=n(9216),h=n.n(m),b=n(4589),y=n.n(b),x=n(2576),g={};g.styleTagTransform=y(),g.setAttributes=v(),g.insert=f().bind(null,"head"),g.domAPI=l(),g.insertStyleElement=h(),s()(x.Z,g),x.Z&&x.Z.locals&&x.Z.locals;var _=(0,n(1900).Z)(a,r,[],!1,null,null,null);_.options.__file="components/lib/mixins/TextReader.vue";var C=_.exports},1900:function(e,t,n){"use strict";function r(e,t,n,r,o,i,a,u){var s,c="function"==typeof e?e.options:e;if(t&&(c.render=t,c.staticRenderFns=n,c._compiled=!0),r&&(c.functional=!0),i&&(c._scopeId="data-v-"+i),a?(s=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),o&&o.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(a)},c._ssrRegister=s):o&&(s=u?function(){o.call(this,(c.functional?this.parent:this).$root.$options.shadowRoot)}:o),s)if(c.functional){c._injectStyles=s;var l=c.render;c.render=function(e,t){return s.call(t),l(e,t)}}else{var p=c.beforeCreate;c.beforeCreate=p?[].concat(p,s):[s]}return{exports:e,options:c}}n.d(t,{Z:function(){return r}})},6981:function(e){e.exports=function(){return this.ELEMENT}()},3371:function(e){e.exports=function(){return this.Vue}()},467:function(t){"use strict";t.exports=e}},n={};function r(e){var o=n[e];if(void 0!==o)return o.exports;var i=n[e]={id:e,exports:{}};return t[e](i,i.exports,r),i.exports}r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,{a:t}),t},r.d=function(e,t){for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.nc=void 0;var o={};return function(){"use strict";r.r(o),r.d(o,{default:function(){return x}});var e=function(){var e=this,t=e.$createElement;return(e._self._c||t)(e.curComponent,e._g(e._b({tag:"component",staticClass:"bpm-number",attrs:{fieldConf:e.fieldConf,row:e.row,mode:e.mode,uiType:e.uiType},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},"component",e.$attrs,!1),e.$listeners))};e._withStripped=!0;var t=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticStyle:{position:"relative"}},[n("el-input-number",{ref:"component",attrs:{precision:e.precision},on:{change:e.handleChange},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}})],1)};t._withStripped=!0;var n=r(467),i=r.n(n),a=r(3371),u=r.n(a),s=r(6981);u().use(s.InputNumber);var c={data(){return{curVal:null}},props:["value","fieldConf","row"],watch:{value(){this.curVal=this.value}},computed:{precision(){return i().get(this.fieldConf,"view.precision",0)}},methods:{handleChange(){this.$emit("input",this.curVal)}}},l=r(1900),p=(0,l.Z)(c,t,[],!1,null,null,null);p.options.__file="components/lib/bpmNumber/src/part/editor.vue";var f=p.exports,d={mixins:[r(1478).Z]},v=(0,l.Z)(d,void 0,void 0,!1,null,null,null);v.options.__file="components/lib/bpmNumber/src/part/reader.vue";var m=v.exports,h={name:"BpmNumber",components:{editorComponent:f,readerComponent:m},props:{value:{type:[String,Number]},fieldConf:{type:Object,default(){return{}}},row:{type:Object,default(){return{}}},mode:{type:String,default(){return"view"}},uiType:{type:String,default(){return"default"}}},data(){return{curVal:""}},computed:{curComponent(){return"view"==this.mode?m:f}},watch:{curVal(e){this.$emit("input",e),this.$emit("change",e)},value(){this.curVal=this.value}},mounted(){this.curVal=this.value}},b=(0,l.Z)(h,e,[],!1,null,null,null);b.options.__file="components/lib/bpmNumber/src/main.vue";var y=b.exports;y.install=function(e){e.component(y.name,y)};var x=y}(),o}()}));
1
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("lodash")):"function"==typeof define&&define.amd?define(["lodash"],t):"object"==typeof exports?exports.bpm2=t(require("lodash")):e.bpm2=t(e.lodash)}(self,(function(e){return function(){var t={1527:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=function(){var e=this,t=e.$createElement;return(e._self._c||t)("span",{staticClass:"bpm-text-view",class:e.uiType+"-text-view",attrs:{title:e._value}},[e._v("\n "+e._s(e._value&&0!==e._value?e.value:"--")+"\n")])};r._withStripped=!0;var o=n(467),i=n.n(o),u={props:["value","fieldConf","row","uiType"],computed:{_value(){return i().get(this.row,this.fieldConf.id)||this.value}}},a=(0,n(1900).Z)(u,r,[],!1,null,null,null);a.options.__file="components/lib/mixins/TextReader.vue";var l=a.exports},1900:function(e,t,n){"use strict";function r(e,t,n,r,o,i,u,a){var l,s="function"==typeof e?e.options:e;if(t&&(s.render=t,s.staticRenderFns=n,s._compiled=!0),r&&(s.functional=!0),i&&(s._scopeId="data-v-"+i),u?(l=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),o&&o.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(u)},s._ssrRegister=l):o&&(l=a?function(){o.call(this,(s.functional?this.parent:this).$root.$options.shadowRoot)}:o),l)if(s.functional){s._injectStyles=l;var c=s.render;s.render=function(e,t){return l.call(t),c(e,t)}}else{var p=s.beforeCreate;s.beforeCreate=p?[].concat(p,l):[l]}return{exports:e,options:s}}n.d(t,{Z:function(){return r}})},6981:function(e){e.exports=function(){return this.ELEMENT}()},3371:function(e){e.exports=function(){return this.Vue}()},467:function(t){"use strict";t.exports=e}},n={};function r(e){var o=n[e];if(void 0!==o)return o.exports;var i=n[e]={exports:{}};return t[e](i,i.exports,r),i.exports}r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,{a:t}),t},r.d=function(e,t){for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var o={};return function(){"use strict";r.r(o),r.d(o,{default:function(){return y}});var e=function(){var e=this,t=e.$createElement;return(e._self._c||t)(e.curComponent,e._g(e._b({tag:"component",staticClass:"bpm-number",attrs:{fieldConf:e.fieldConf,row:e.row,mode:e.mode,uiType:e.uiType},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},"component",e.$attrs,!1),e.$listeners))};e._withStripped=!0;var t=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticStyle:{position:"relative"}},[n("el-input-number",{ref:"component",attrs:{precision:e.precision},on:{change:e.handleChange},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}})],1)};t._withStripped=!0;var n=r(467),i=r.n(n),u=r(3371),a=r.n(u),l=r(6981);a().use(l.InputNumber);var s={data(){return{curVal:null}},props:["value","fieldConf","row"],watch:{value(){this.curVal=this.value}},computed:{precision(){return i().get(this.fieldConf,"view.precision",0)}},methods:{handleChange(){this.$emit("input",this.curVal)}}},c=r(1900),p=(0,c.Z)(s,t,[],!1,null,null,null);p.options.__file="components/lib/bpmNumber/src/part/editor.vue";var f=p.exports,d={mixins:[r(1527).Z]},m=(0,c.Z)(d,void 0,void 0,!1,null,null,null);m.options.__file="components/lib/bpmNumber/src/part/reader.vue";var v=m.exports,h={name:"BpmNumber",components:{editorComponent:f,readerComponent:v},props:{value:{type:[String,Number]},fieldConf:{type:Object,default(){return{}}},row:{type:Object,default(){return{}}},mode:{type:String,default(){return"view"}},uiType:{type:String,default(){return"default"}}},data(){return{curVal:""}},computed:{curComponent(){return"view"==this.mode?v:f}},watch:{curVal(e){this.$emit("input",e),this.$emit("change",e)},value(){this.curVal=this.value}},mounted(){this.curVal=this.value}},_=(0,c.Z)(h,e,[],!1,null,null,null);_.options.__file="components/lib/bpmNumber/src/main.vue";var b=_.exports;b.install=function(e){e.component(b.name,b)};var y=b}(),o}()}));
@@ -1 +1 @@
1
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("lodash"),require("qs")):"function"==typeof define&&define.amd?define(["lodash","qs"],t):"object"==typeof exports?exports.bpm2=t(require("lodash"),require("qs")):e.bpm2=t(e.lodash,e.qs)}(self,(function(e,t){return function(){var n={3532:function(e,t,n){"use strict";n.d(t,{Z:function(){return u}});var r=n(4239),i=n(467),a=n.n(i),s=class{constructor(e,t={}){this._fnBatchLoad=e,this._options=t,this._queue=[]}async load(e){let t=await this.loads(e);return a().get(t,"0")}loads(...e){return new Promise(((t,n)=>{this._queue.push({keys:e,resolve:t,reject:n}),1==this._queue.length&&this.nextTick((()=>{this.process()}))}))}nextTick(e){setTimeout(e,0)}process(){let e=this._queue;this._queue=[];let t={};a().each(e,(e=>{a().each(e.keys,(e=>t[e]=null))}));let n=a().keys(t);this._fnBatchLoad(n).then((r=>{a().each(n,((e,n)=>{t[e]=r[n]})),a().each(e,(({keys:e,resolve:n})=>{n(a().map(e,(e=>t[e])))}))})).catch((t=>{a().each(e,(({reject:e})=>e(t)))}))}};const o=async(e,t,n)=>{if(console.log("netHeader",t.netHeader),t.networking=!0,t.netHeader&&(e.headers={common:t.netHeader}),e.params=_.merge({},e.params,n),t.env.ignore_levels&&_.set(e.params,"ignore_levels",!0),(0,r.tq)()){let t=zj.utils.pageParam().token;e.params=_.merge({token:t,platform:"phone"},e.params)}e.isSilentOnErr=e=>{let t=_.get(e,"data.result");return t>=19e6||t<=19999999};let i=await zj.net.request(e);return t.networking=!1,i},l={};var u={assistSelectEntranceForm:{getListDefinition(e,{formDefId:t,fieldDefId:n,orgInfo:r,isDm:i}){return o({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${n}/list_definition/`,method:"GET"},e,r)},getOptions(e,{formDefId:t,fieldDefId:n,orgInfo:r,isDm:i},a){return o({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${n}/list_search/`,method:"GET",params:a},e,r)},getListSelected(e,{formDefId:t,fieldDefId:n,orgInfo:r,isDm:i},a){return o({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${n}/list_selected/`,method:"GET",params:a},e,r)}},assistField:{getBatchLoader(e,{formDefId:t,fieldDefId:n,orgInfo:r,uniqueId:i}){const a=`${t}/${n}`,u=l[a]||new s((async a=>{console.log("assist_field/list_title requeset is call");let s=`/app_flow/v1/papi/assist_field/${t}/${n}/list_title/`;const l=await o({url:s,method:"GET",params:{values:JSON.stringify(a)}},e,r),u=_.get(l,"data.data.data",{});let c=[];return _.map(a,(e=>{i?(e=JSON.parse(e),e=_.get(e,`${i}`),c=_.concat(c,u[e])):c=_.concat(c,u[e])})),c}));return l[a]=u,u},getTitle(e,{formDefId:t,fieldDefId:n,orgInfo:r,isDm:i},a){return o({url:`/app_flow/v1/papi/assist_field/${t}/${n}/list_title/`,method:"GET",params:{values:JSON.stringify(a)}},e,r)},searchSelectOpts(e,{formDefId:t,fieldDefId:n,orgInfo:r,isDm:i},a={},s=""){return s&&(a.q=s),o({url:i?`/app_flow/v1/papi/dm/assist_field/${t}/${n}/search_title/`:`/app_flow/v1/papi/assist_field/${t}/${n}/search_title/`,method:"GET",params:a},e,r)}},assistTreeField:{searchSelectOpts(e,{formDefId:t,fieldDefId:n,orgInfo:r,isDm:i},a={},s=""){return s&&(a.q=s),o({url:i?`/app_flow/v1/papi/dm/assist_tree_field/${t}/${n}/search_title/`:`/app_flow/v1/papi/assist_tree_field/${t}/${n}/search_title/`,method:"GET",params:a},e,r)}},assistUserTaskCC:{searchSelectOpts(e,{formDefId:t,node:n,orgInfo:r,isDm:i},a={},s=""){return s&&(a.q=s),o({url:`/app_flow/v1/papi/assist_user_task_cc/${t}/${n}/search_title/`,method:"GET",params:a},e,r)}}}},4239:function(e,t,n){"use strict";function r(){for(var e=["iphone","ipod","ipad","android","mobile","blackberry","webos","incognito","webmate","bada","nokia","lg","ucweb","skyfire"],t=navigator.userAgent.toLowerCase(),n=!1,r=0,i=e.length;r<i;r++)-1!=t.indexOf(e[r])&&(n=!0);return n}n.d(t,{tq:function(){return r}}),n(467),n(6656)},8528:function(e,t,n){"use strict";var r=n(8081),i=n.n(r),a=n(3645),s=n.n(a)()(i());s.push([e.id,".bpm-select-tree {\n .el-select-dropdown__item.hover {\n background: none!important;\n }\n .tree-options.el-select-dropdown__item {\n padding: 0 0;\n }\n}\n",""]),t.Z=s},1912:function(e,t,n){"use strict";var r=n(8081),i=n.n(r),a=n(3645),s=n.n(a),o=n(8528),l=s()(i());l.i(o.Z),l.push([e.id,"\n",""]),t.Z=l},3645:function(e){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",r=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),r&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),r&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,r,i,a){"string"==typeof e&&(e=[[null,e,void 0]]);var s={};if(r)for(var o=0;o<this.length;o++){var l=this[o][0];null!=l&&(s[l]=!0)}for(var u=0;u<e.length;u++){var c=[].concat(e[u]);r&&s[c[0]]||(void 0!==a&&(void 0===c[5]||(c[1]="@layer".concat(c[5].length>0?" ".concat(c[5]):""," {").concat(c[1],"}")),c[5]=a),n&&(c[2]?(c[1]="@media ".concat(c[2]," {").concat(c[1],"}"),c[2]=n):c[2]=n),i&&(c[4]?(c[1]="@supports (".concat(c[4],") {").concat(c[1],"}"),c[4]=i):c[4]="".concat(i)),t.push(c))}},t}},8081:function(e){"use strict";e.exports=function(e){return e[1]}},3379:function(e){"use strict";var t=[];function n(e){for(var n=-1,r=0;r<t.length;r++)if(t[r].identifier===e){n=r;break}return n}function r(e,r){for(var a={},s=[],o=0;o<e.length;o++){var l=e[o],u=r.base?l[0]+r.base:l[0],c=a[u]||0,f="".concat(u," ").concat(c);a[u]=c+1;var d=n(f),p={css:l[1],media:l[2],sourceMap:l[3],supports:l[4],layer:l[5]};if(-1!==d)t[d].references++,t[d].updater(p);else{var h=i(p,r);r.byIndex=o,t.splice(o,0,{identifier:f,updater:h,references:1})}s.push(f)}return s}function i(e,t){var n=t.domAPI(t);return n.update(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap&&t.supports===e.supports&&t.layer===e.layer)return;n.update(e=t)}else n.remove()}}e.exports=function(e,i){var a=r(e=e||[],i=i||{});return function(e){e=e||[];for(var s=0;s<a.length;s++){var o=n(a[s]);t[o].references--}for(var l=r(e,i),u=0;u<a.length;u++){var c=n(a[u]);0===t[c].references&&(t[c].updater(),t.splice(c,1))}a=l}}},569:function(e){"use strict";var t={};e.exports=function(e,n){var r=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}},9216:function(e){"use strict";e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},3565:function(e,t,n){"use strict";e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7795:function(e){"use strict";e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var r="";n.supports&&(r+="@supports (".concat(n.supports,") {")),n.media&&(r+="@media ".concat(n.media," {"));var i=void 0!==n.layer;i&&(r+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),r+=n.css,i&&(r+="}"),n.media&&(r+="}"),n.supports&&(r+="}");var a=n.sourceMap;a&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(a))))," */")),t.styleTagTransform(r,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},4589:function(e){"use strict";e.exports=function(e,t){if(t.styleSheet)t.styleSheet.cssText=e;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(e))}}},5460:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=function(){var e=this,t=e.$createElement;return(e._self._c||t)("span",{attrs:{title:e.label}},[e._v(e._s(e.label))])};r._withStripped=!0;var i=n(467),a=n.n(i),s={props:["value","fieldConf","row","formName","orgInfo"],data(){return{label:""}},watch:{value(){this.loadRemoteLabel()}},mounted(){this.loadRemoteLabel()},methods:{async loadRemoteLabel(){let e=this.value;if(a().isNil(e)||!e)return this.label="未选择";try{if(a().isObject(e))try{e=JSON.parse(e)}catch(e){console.log("error",e)}let t=a().isArray(e)?e:[e],n=a().get(this.fieldConf,"id");a().isEmpty(t)?this.label="未选择":(t=a().isArray(t)?t:[t],this.label=await this.$bpm.fetchLabelByValues(t,n,this.formName,this.row))}finally{console.log("finally")}}}},o=(0,n(1900).Z)(s,r,[],!1,null,null,null);o.options.__file="components/lib/mixins/RemoteSelectReader.vue";var l=o.exports},1900:function(e,t,n){"use strict";function r(e,t,n,r,i,a,s,o){var l,u="function"==typeof e?e.options:e;if(t&&(u.render=t,u.staticRenderFns=n,u._compiled=!0),r&&(u.functional=!0),a&&(u._scopeId="data-v-"+a),s?(l=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),i&&i.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(s)},u._ssrRegister=l):i&&(l=o?function(){i.call(this,(u.functional?this.parent:this).$root.$options.shadowRoot)}:i),l)if(u.functional){u._injectStyles=l;var c=u.render;u.render=function(e,t){return l.call(t),c(e,t)}}else{var f=u.beforeCreate;u.beforeCreate=f?[].concat(f,l):[l]}return{exports:e,options:u}}n.d(t,{Z:function(){return r}})},6981:function(e){e.exports=function(){return this.ELEMENT}()},3371:function(e){e.exports=function(){return this.Vue}()},467:function(t){"use strict";t.exports=e},6656:function(e){"use strict";e.exports=t}},r={};function i(e){var t=r[e];if(void 0!==t)return t.exports;var a=r[e]={id:e,exports:{}};return n[e](a,a.exports,i),a.exports}i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,{a:t}),t},i.d=function(e,t){for(var n in t)i.o(t,n)&&!i.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},i.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.nc=void 0;var a={};return function(){"use strict";i.r(a),i.d(a,{default:function(){return q}});var e=function(){var e=this,t=e.$createElement;return(e._self._c||t)(e.curComponent,e._g(e._b({tag:"component",staticClass:"bpm-select-check-item",attrs:{fieldConf:e.fieldConf,row:e.row,orgInfo:e.orgInfo,formName:e.formName,mode:e.mode,isMultiple:e.multiple,uiType:e.uiType},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},"component",e.$attrs,!1),e.$listeners))};e._withStripped=!0;var t=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",[n("el-select",{staticStyle:{width:"100%"},attrs:{"popper-class":"bpm-select-tree",multiple:e.isMultiple,placeholder:e.placeholder,"multiple-limit":e.maxCount},on:{change:e.onChange},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},[e._l(e.defaultOptions,(function(e){return n("el-option",{key:e.value,attrs:{label:e.label,value:e.value}})})),e._v(" "),n("el-tree",{attrs:{lazy:"",load:e.loadNode,"node-key":"value",props:{label:"treeLabel",children:"children",disabled:"disabled",isLeaf:"isLeaf"},indent:16},scopedSlots:e._u([{key:"default",fn:function(t){var r=t.node;return r.data.disabled?n("span",{},[e._v("\n "+e._s(r.label)+"\n ")]):n("el-option",{staticClass:"tree-options",attrs:{value:r.data.value,label:r.data.label}},[n("span",{staticStyle:{"padding-right":"30px","max-width":"500px",overflow:"hidden"}},[e._v("\n "+e._s(r.label)+"\n ")])])}}],null,!0)})],2)],1)};t._withStripped=!0;var n=i(3532),r=i(3371),s=i.n(r),o=i(467),l=i.n(o),u=i(6981);s().use(u.Tree),s().use(u.Select),s().use(u.Option);var c={props:["value","fieldConf","row","formName","formDefId","orgInfo","dm","isMultiple"],data(){return{curVal:"",defaultOptions:[]}},watch:{value(){this.curVal=this.value?this.value:this.isMultiple?[]:"",this.getDefaultOptions()}},computed:{placeholder(){return this.fieldConf.desc||this.fieldConf.name},maxCount(){return l().get(this.fieldConf,"check.max_count")},tickStrategy(){return"leaf_only"==l().get(this.fieldConf,"tree_select","all")?"leaf-filtered":"strict"},leafOnly(){return"leaf_only"===this.fieldConf.tree_select}},created(){this.curVal=this.isMultiple?[]:""},mounted(){this.curVal=this.value?this.value:this.isMultiple?[]:""},methods:{async loadNode(e,t){let r=l().get(this.fieldConf,"id"),i={father:0===e.level?"":e.data.value||""},a=await n.Z.assistTreeField.searchSelectOpts(this.$bpm,{formDefId:this.formDefId,fieldDefId:r,orgInfo:this.orgInfo,isDm:this.dm},i),s=l().get(a.data,"data.data",[]);t(this.transformResultToTree(s,e))},transformResultToTree(e,t){let n=l().get(this.fieldConf,"type");return"SelectCheckItem"==n||"MulSelectCheckItem"==n?l().map(e,(e=>{this.isMultiple||e[0]!==this.curVal||(this.defaultOptions=[]),this.isMultiple&&this.curVal.includes(e[0])&&(this.defaultOptions=l().filter(this.defaultOptions,(t=>t.value!==e[0])));let n=0===t.level?e[1]:t.data.label+" - "+e[1],r=!e[2];return{value:e[0],lazy:e[2],label:n,treeLabel:e[1],isLeaf:r,disabled:this.leafOnly&&!r}})):"SelectSort"==n||"MulSelectSort"==n?l().map(e,(e=>{this.isMultiple||e.value!==this.curVal||(this.defaultOptions=[]),this.isMultiple&&this.curVal.includes(e.value)&&(this.defaultOptions=l().filter(this.defaultOptions,(t=>t.value!==e.value)));let n=0===t.level?e.label:t.data.label+" - "+e.label,r=!e.lazy;return{value:e.value,lazy:e.lazy,label:n,treeLabel:e.label,isLeaf:r,disabled:this.leafOnly&&!r}})):void 0},async getDefaultOptions(){let e=l().isArray(this.curVal)?this.curVal:this.curVal?[this.curVal]:[];if(!e.length)return;const t=await n.Z.assistField.getTitle(this.$bpm,{formDefId:this.formDefId,fieldDefId:this.fieldConf.id,orgInfo:this.orgInfo,isDm:this.dm},e);console.log(t);const r=l().get(t.data,"data.data",{});let i=l().map(r,((e,t)=>({value:t,label:e})));console.log("default options: ",i),this.defaultOptions=i},onChange(e){this.$emit("input",e),this.$emit("change",e)}}},f=i(1900),d=(0,f.Z)(c,t,[],!1,null,null,null);d.options.__file="components/lib/bpmSelectCheckItem/src/part/editor.vue";var p=d.exports,h={mixins:[i(5460).Z]},m=(0,f.Z)(h,void 0,void 0,!1,null,null,null);m.options.__file="components/lib/bpmSelectCheckItem/src/part/reader.vue";var v=m.exports,_={name:"BpmSelectCheckItem",components:{editorComponent:p,readerComponent:v},props:{value:{type:[String,Array]},type:{type:String,default:"SelectCheckItem"},fieldConf:{type:Object,default(){return{}}},row:{type:Object,default(){return{}}},mode:{type:String,default(){return"view"}},uiType:{type:String,default(){return"default"}},orgInfo:{type:Object},formName:{type:String},isMultiple:{type:Boolean,default(){return!1}}},data(){return{curVal:""}},computed:{curComponent(){return"view"==this.mode?v:p},multiple(){return this.isMultiple||0===this.type.indexOf("Mul")}},watch:{curVal(e){this.$emit("input",e),this.$emit("change",e)},value(){this.curVal=this.value}},mounted(){this.curVal=this.value}},g=i(3379),y=i.n(g),b=i(7795),I=i.n(b),S=i(569),w=i.n(S),C=i(3565),x=i.n(C),$=i(9216),T=i.n($),O=i(4589),D=i.n(O),k=i(1912),E={};E.styleTagTransform=D(),E.setAttributes=x(),E.insert=w().bind(null,"head"),E.domAPI=I(),E.insertStyleElement=T(),y()(k.Z,E),k.Z&&k.Z.locals&&k.Z.locals;var M=(0,f.Z)(_,e,[],!1,null,null,null);M.options.__file="components/lib/bpmSelectCheckItem/src/main.vue";var V=M.exports;V.install=function(e){e.component(V.name,V)};var q=V}(),a}()}));
1
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("lodash"),require("qs")):"function"==typeof define&&define.amd?define(["lodash","qs"],t):"object"==typeof exports?exports.bpm2=t(require("lodash"),require("qs")):e.bpm2=t(e.lodash,e.qs)}(self,(function(e,t){return function(){var n={3532:function(e,t,n){"use strict";n.d(t,{Z:function(){return u}});var r=n(4239),i=n(467),a=n.n(i),s=class{constructor(e,t={}){this._fnBatchLoad=e,this._options=t,this._queue=[]}async load(e){let t=await this.loads(e);return a().get(t,"0")}loads(...e){return new Promise(((t,n)=>{this._queue.push({keys:e,resolve:t,reject:n}),1==this._queue.length&&this.nextTick((()=>{this.process()}))}))}nextTick(e){setTimeout(e,0)}process(){let e=this._queue;this._queue=[];let t={};a().each(e,(e=>{a().each(e.keys,(e=>t[e]=null))}));let n=a().keys(t);this._fnBatchLoad(n).then((r=>{a().each(n,((e,n)=>{t[e]=r[n]})),a().each(e,(({keys:e,resolve:n})=>{n(a().map(e,(e=>t[e])))}))})).catch((t=>{a().each(e,(({reject:e})=>e(t)))}))}};const o=async(e,t,n)=>{if(console.log("netHeader",t.netHeader),t.networking=!0,t.netHeader&&(e.headers={common:t.netHeader}),e.params=_.merge({},e.params,n),t.env.ignore_levels&&_.set(e.params,"ignore_levels",!0),(0,r.tq)()){let t=zj.utils.pageParam().token;e.params=_.merge({token:t,platform:"phone"},e.params)}e.isSilentOnErr=e=>{let t=_.get(e,"data.result");return t>=19e6||t<=19999999};let i=await zj.net.request(e);return t.networking=!1,i},l={};var u={assistSelectEntranceForm:{getListDefinition(e,{formDefId:t,fieldDefId:n,orgInfo:r,isDm:i}){return o({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${n}/list_definition/`,method:"GET"},e,r)},getOptions(e,{formDefId:t,fieldDefId:n,orgInfo:r,isDm:i},a){return o({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${n}/list_search/`,method:"GET",params:a},e,r)},getListSelected(e,{formDefId:t,fieldDefId:n,orgInfo:r,isDm:i},a){return o({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${n}/list_selected/`,method:"GET",params:a},e,r)}},assistField:{getBatchLoader(e,{formDefId:t,fieldDefId:n,orgInfo:r,uniqueId:i}){const a=`${t}/${n}`,u=l[a]||new s((async a=>{console.log("assist_field/list_title requeset is call");let s=`/app_flow/v1/papi/assist_field/${t}/${n}/list_title/`;const l=await o({url:s,method:"GET",params:{values:JSON.stringify(a)}},e,r),u=_.get(l,"data.data.data",{});let c=[];return _.map(a,(e=>{i?(e=JSON.parse(e),e=_.get(e,`${i}`),c=_.concat(c,u[e])):c=_.concat(c,u[e])})),c}));return l[a]=u,u},getTitle(e,{formDefId:t,fieldDefId:n,orgInfo:r,isDm:i},a){return o({url:`/app_flow/v1/papi/assist_field/${t}/${n}/list_title/`,method:"GET",params:{values:JSON.stringify(a)}},e,r)},searchSelectOpts(e,{formDefId:t,fieldDefId:n,orgInfo:r,isDm:i},a={},s=""){return s&&(a.q=s),o({url:i?`/app_flow/v1/papi/dm/assist_field/${t}/${n}/search_title/`:`/app_flow/v1/papi/assist_field/${t}/${n}/search_title/`,method:"GET",params:a},e,r)}},assistTreeField:{searchSelectOpts(e,{formDefId:t,fieldDefId:n,orgInfo:r,isDm:i},a={},s=""){return s&&(a.q=s),o({url:i?`/app_flow/v1/papi/dm/assist_tree_field/${t}/${n}/search_title/`:`/app_flow/v1/papi/assist_tree_field/${t}/${n}/search_title/`,method:"GET",params:a},e,r)}},assistUserTaskCC:{searchSelectOpts(e,{formDefId:t,node:n,orgInfo:r,isDm:i},a={},s=""){return s&&(a.q=s),o({url:`/app_flow/v1/papi/assist_user_task_cc/${t}/${n}/search_title/`,method:"GET",params:a},e,r)}}}},4239:function(e,t,n){"use strict";function r(){for(var e=["iphone","ipod","ipad","android","mobile","blackberry","webos","incognito","webmate","bada","nokia","lg","ucweb","skyfire"],t=navigator.userAgent.toLowerCase(),n=!1,r=0,i=e.length;r<i;r++)-1!=t.indexOf(e[r])&&(n=!0);return n}n.d(t,{tq:function(){return r}}),n(467),n(6656)},8528:function(e,t,n){"use strict";var r=n(8081),i=n.n(r),a=n(3645),s=n.n(a)()(i());s.push([e.id,".bpm-select-tree {\n .el-select-dropdown__item.hover {\n background: none!important;\n }\n .tree-options.el-select-dropdown__item {\n padding: 0 0;\n }\n}\n",""]),t.Z=s},1912:function(e,t,n){"use strict";var r=n(8081),i=n.n(r),a=n(3645),s=n.n(a),o=n(8528),l=s()(i());l.i(o.Z),l.push([e.id,"\n",""]),t.Z=l},3645:function(e){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",r=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),r&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),r&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,r,i,a){"string"==typeof e&&(e=[[null,e,void 0]]);var s={};if(r)for(var o=0;o<this.length;o++){var l=this[o][0];null!=l&&(s[l]=!0)}for(var u=0;u<e.length;u++){var c=[].concat(e[u]);r&&s[c[0]]||(void 0!==a&&(void 0===c[5]||(c[1]="@layer".concat(c[5].length>0?" ".concat(c[5]):""," {").concat(c[1],"}")),c[5]=a),n&&(c[2]?(c[1]="@media ".concat(c[2]," {").concat(c[1],"}"),c[2]=n):c[2]=n),i&&(c[4]?(c[1]="@supports (".concat(c[4],") {").concat(c[1],"}"),c[4]=i):c[4]="".concat(i)),t.push(c))}},t}},8081:function(e){"use strict";e.exports=function(e){return e[1]}},3379:function(e){"use strict";var t=[];function n(e){for(var n=-1,r=0;r<t.length;r++)if(t[r].identifier===e){n=r;break}return n}function r(e,r){for(var a={},s=[],o=0;o<e.length;o++){var l=e[o],u=r.base?l[0]+r.base:l[0],c=a[u]||0,f="".concat(u," ").concat(c);a[u]=c+1;var d=n(f),p={css:l[1],media:l[2],sourceMap:l[3],supports:l[4],layer:l[5]};if(-1!==d)t[d].references++,t[d].updater(p);else{var h=i(p,r);r.byIndex=o,t.splice(o,0,{identifier:f,updater:h,references:1})}s.push(f)}return s}function i(e,t){var n=t.domAPI(t);return n.update(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap&&t.supports===e.supports&&t.layer===e.layer)return;n.update(e=t)}else n.remove()}}e.exports=function(e,i){var a=r(e=e||[],i=i||{});return function(e){e=e||[];for(var s=0;s<a.length;s++){var o=n(a[s]);t[o].references--}for(var l=r(e,i),u=0;u<a.length;u++){var c=n(a[u]);0===t[c].references&&(t[c].updater(),t.splice(c,1))}a=l}}},569:function(e){"use strict";var t={};e.exports=function(e,n){var r=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}},9216:function(e){"use strict";e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},3565:function(e,t,n){"use strict";e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7795:function(e){"use strict";e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var r="";n.supports&&(r+="@supports (".concat(n.supports,") {")),n.media&&(r+="@media ".concat(n.media," {"));var i=void 0!==n.layer;i&&(r+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),r+=n.css,i&&(r+="}"),n.media&&(r+="}"),n.supports&&(r+="}");var a=n.sourceMap;a&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(a))))," */")),t.styleTagTransform(r,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},4589:function(e){"use strict";e.exports=function(e,t){if(t.styleSheet)t.styleSheet.cssText=e;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(e))}}},5460:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=function(){var e=this,t=e.$createElement;return(e._self._c||t)("span",{attrs:{title:e.label}},[e._v(e._s(e.label))])};r._withStripped=!0;var i=n(467),a=n.n(i),s={props:["value","fieldConf","row","formName","orgInfo"],data(){return{label:""}},watch:{value(){this.loadRemoteLabel()}},mounted(){this.loadRemoteLabel()},methods:{async loadRemoteLabel(){let e=this.value;if(a().isNil(e)||!e)return this.label=zj.z("未选择","c.not_selected");try{if(a().isObject(e))try{e=JSON.parse(e)}catch(e){console.log("error",e)}let t=a().isArray(e)?e:[e],n=a().get(this.fieldConf,"id");a().isEmpty(t)?this.label=zj.z("未选择","c.not_selected"):(t=a().isArray(t)?t:[t],this.label=await this.$bpm.fetchLabelByValues(t,n,this.formName,this.row))}finally{console.log("finally")}}}},o=(0,n(1900).Z)(s,r,[],!1,null,null,null);o.options.__file="components/lib/mixins/RemoteSelectReader.vue";var l=o.exports},1900:function(e,t,n){"use strict";function r(e,t,n,r,i,a,s,o){var l,u="function"==typeof e?e.options:e;if(t&&(u.render=t,u.staticRenderFns=n,u._compiled=!0),r&&(u.functional=!0),a&&(u._scopeId="data-v-"+a),s?(l=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),i&&i.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(s)},u._ssrRegister=l):i&&(l=o?function(){i.call(this,(u.functional?this.parent:this).$root.$options.shadowRoot)}:i),l)if(u.functional){u._injectStyles=l;var c=u.render;u.render=function(e,t){return l.call(t),c(e,t)}}else{var f=u.beforeCreate;u.beforeCreate=f?[].concat(f,l):[l]}return{exports:e,options:u}}n.d(t,{Z:function(){return r}})},6981:function(e){e.exports=function(){return this.ELEMENT}()},3371:function(e){e.exports=function(){return this.Vue}()},467:function(t){"use strict";t.exports=e},6656:function(e){"use strict";e.exports=t}},r={};function i(e){var t=r[e];if(void 0!==t)return t.exports;var a=r[e]={id:e,exports:{}};return n[e](a,a.exports,i),a.exports}i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,{a:t}),t},i.d=function(e,t){for(var n in t)i.o(t,n)&&!i.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},i.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.nc=void 0;var a={};return function(){"use strict";i.r(a),i.d(a,{default:function(){return q}});var e=function(){var e=this,t=e.$createElement;return(e._self._c||t)(e.curComponent,e._g(e._b({tag:"component",staticClass:"bpm-select-check-item",attrs:{fieldConf:e.fieldConf,row:e.row,orgInfo:e.orgInfo,formName:e.formName,mode:e.mode,isMultiple:e.multiple,uiType:e.uiType},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},"component",e.$attrs,!1),e.$listeners))};e._withStripped=!0;var t=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",[n("el-select",{staticStyle:{width:"100%"},attrs:{"popper-class":"bpm-select-tree",multiple:e.isMultiple,placeholder:e.placeholder,"multiple-limit":e.maxCount},on:{change:e.onChange},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},[e._l(e.defaultOptions,(function(e){return n("el-option",{key:e.value,attrs:{label:e.label,value:e.value}})})),e._v(" "),n("el-tree",{attrs:{lazy:"",load:e.loadNode,"node-key":"value",props:{label:"treeLabel",children:"children",disabled:"disabled",isLeaf:"isLeaf"},indent:16},scopedSlots:e._u([{key:"default",fn:function(t){var r=t.node;return r.data.disabled?n("span",{},[e._v("\n "+e._s(r.label)+"\n ")]):n("el-option",{staticClass:"tree-options",attrs:{value:r.data.value,label:r.data.label}},[n("span",{staticStyle:{"padding-right":"30px","max-width":"500px",overflow:"hidden"}},[e._v("\n "+e._s(r.label)+"\n ")])])}}],null,!0)})],2)],1)};t._withStripped=!0;var n=i(3532),r=i(3371),s=i.n(r),o=i(467),l=i.n(o),u=i(6981);s().use(u.Tree),s().use(u.Select),s().use(u.Option);var c={props:["value","fieldConf","row","formName","formDefId","orgInfo","dm","isMultiple"],data(){return{curVal:"",defaultOptions:[]}},watch:{value(){this.curVal=this.value?this.value:this.isMultiple?[]:"",this.getDefaultOptions()}},computed:{placeholder(){return this.fieldConf.desc||this.fieldConf.name},maxCount(){return l().get(this.fieldConf,"check.max_count")},tickStrategy(){return"leaf_only"==l().get(this.fieldConf,"tree_select","all")?"leaf-filtered":"strict"},leafOnly(){return"leaf_only"===this.fieldConf.tree_select}},created(){this.curVal=this.isMultiple?[]:""},mounted(){this.curVal=this.value?this.value:this.isMultiple?[]:""},methods:{async loadNode(e,t){let r=l().get(this.fieldConf,"id"),i={father:0===e.level?"":e.data.value||""},a=await n.Z.assistTreeField.searchSelectOpts(this.$bpm,{formDefId:this.formDefId,fieldDefId:r,orgInfo:this.orgInfo,isDm:this.dm},i),s=l().get(a.data,"data.data",[]);t(this.transformResultToTree(s,e))},transformResultToTree(e,t){let n=l().get(this.fieldConf,"type");return"SelectCheckItem"==n||"MulSelectCheckItem"==n?l().map(e,(e=>{this.isMultiple||e[0]!==this.curVal||(this.defaultOptions=[]),this.isMultiple&&this.curVal.includes(e[0])&&(this.defaultOptions=l().filter(this.defaultOptions,(t=>t.value!==e[0])));let n=0===t.level?e[1]:t.data.label+" - "+e[1],r=!e[2];return{value:e[0],lazy:e[2],label:n,treeLabel:e[1],isLeaf:r,disabled:this.leafOnly&&!r}})):"SelectSort"==n||"MulSelectSort"==n?l().map(e,(e=>{this.isMultiple||e.value!==this.curVal||(this.defaultOptions=[]),this.isMultiple&&this.curVal.includes(e.value)&&(this.defaultOptions=l().filter(this.defaultOptions,(t=>t.value!==e.value)));let n=0===t.level?e.label:t.data.label+" - "+e.label,r=!e.lazy;return{value:e.value,lazy:e.lazy,label:n,treeLabel:e.label,isLeaf:r,disabled:this.leafOnly&&!r}})):void 0},async getDefaultOptions(){let e=l().isArray(this.curVal)?this.curVal:this.curVal?[this.curVal]:[];if(!e.length)return;const t=await n.Z.assistField.getTitle(this.$bpm,{formDefId:this.formDefId,fieldDefId:this.fieldConf.id,orgInfo:this.orgInfo,isDm:this.dm},e);console.log(t);const r=l().get(t.data,"data.data",{});let i=l().map(r,((e,t)=>({value:t,label:e})));console.log("default options: ",i),this.defaultOptions=i},onChange(e){this.$emit("input",e),this.$emit("change",e)}}},f=i(1900),d=(0,f.Z)(c,t,[],!1,null,null,null);d.options.__file="components/lib/bpmSelectCheckItem/src/part/editor.vue";var p=d.exports,h={mixins:[i(5460).Z]},m=(0,f.Z)(h,void 0,void 0,!1,null,null,null);m.options.__file="components/lib/bpmSelectCheckItem/src/part/reader.vue";var v=m.exports,_={name:"BpmSelectCheckItem",components:{editorComponent:p,readerComponent:v},props:{value:{type:[String,Array]},type:{type:String,default:"SelectCheckItem"},fieldConf:{type:Object,default(){return{}}},row:{type:Object,default(){return{}}},mode:{type:String,default(){return"view"}},uiType:{type:String,default(){return"default"}},orgInfo:{type:Object},formName:{type:String},isMultiple:{type:Boolean,default(){return!1}}},data(){return{curVal:""}},computed:{curComponent(){return"view"==this.mode?v:p},multiple(){return this.isMultiple||0===this.type.indexOf("Mul")}},watch:{curVal(e){this.$emit("input",e),this.$emit("change",e)},value(){this.curVal=this.value}},mounted(){this.curVal=this.value}},g=i(3379),y=i.n(g),b=i(7795),I=i.n(b),S=i(569),w=i.n(S),C=i(3565),x=i.n(C),$=i(9216),T=i.n($),O=i(4589),D=i.n(O),k=i(1912),E={};E.styleTagTransform=D(),E.setAttributes=x(),E.insert=w().bind(null,"head"),E.domAPI=I(),E.insertStyleElement=T(),y()(k.Z,E),k.Z&&k.Z.locals&&k.Z.locals;var M=(0,f.Z)(_,e,[],!1,null,null,null);M.options.__file="components/lib/bpmSelectCheckItem/src/main.vue";var V=M.exports;V.install=function(e){e.component(V.name,V)};var q=V}(),a}()}));
@@ -1 +1 @@
1
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("lodash"),require("qs")):"function"==typeof define&&define.amd?define(["lodash","qs"],t):"object"==typeof exports?exports.bpm2=t(require("lodash"),require("qs")):e.bpm2=t(e.lodash,e.qs)}(self,(function(e,t){return function(){var s={3532:function(e,t,s){"use strict";s.d(t,{Z:function(){return c}});var i=s(4239),o=s(467),r=s.n(o),n=class{constructor(e,t={}){this._fnBatchLoad=e,this._options=t,this._queue=[]}async load(e){let t=await this.loads(e);return r().get(t,"0")}loads(...e){return new Promise(((t,s)=>{this._queue.push({keys:e,resolve:t,reject:s}),1==this._queue.length&&this.nextTick((()=>{this.process()}))}))}nextTick(e){setTimeout(e,0)}process(){let e=this._queue;this._queue=[];let t={};r().each(e,(e=>{r().each(e.keys,(e=>t[e]=null))}));let s=r().keys(t);this._fnBatchLoad(s).then((i=>{r().each(s,((e,s)=>{t[e]=i[s]})),r().each(e,(({keys:e,resolve:s})=>{s(r().map(e,(e=>t[e])))}))})).catch((t=>{r().each(e,(({reject:e})=>e(t)))}))}};const l=async(e,t,s)=>{if(console.log("netHeader",t.netHeader),t.networking=!0,t.netHeader&&(e.headers={common:t.netHeader}),e.params=_.merge({},e.params,s),t.env.ignore_levels&&_.set(e.params,"ignore_levels",!0),(0,i.tq)()){let t=zj.utils.pageParam().token;e.params=_.merge({token:t,platform:"phone"},e.params)}e.isSilentOnErr=e=>{let t=_.get(e,"data.result");return t>=19e6||t<=19999999};let o=await zj.net.request(e);return t.networking=!1,o},a={};var c={assistSelectEntranceForm:{getListDefinition(e,{formDefId:t,fieldDefId:s,orgInfo:i,isDm:o}){return l({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${s}/list_definition/`,method:"GET"},e,i)},getOptions(e,{formDefId:t,fieldDefId:s,orgInfo:i,isDm:o},r){return l({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${s}/list_search/`,method:"GET",params:r},e,i)},getListSelected(e,{formDefId:t,fieldDefId:s,orgInfo:i,isDm:o},r){return l({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${s}/list_selected/`,method:"GET",params:r},e,i)}},assistField:{getBatchLoader(e,{formDefId:t,fieldDefId:s,orgInfo:i,uniqueId:o}){const r=`${t}/${s}`,c=a[r]||new n((async r=>{console.log("assist_field/list_title requeset is call");let n=`/app_flow/v1/papi/assist_field/${t}/${s}/list_title/`;const a=await l({url:n,method:"GET",params:{values:JSON.stringify(r)}},e,i),c=_.get(a,"data.data.data",{});let u=[];return _.map(r,(e=>{o?(e=JSON.parse(e),e=_.get(e,`${o}`),u=_.concat(u,c[e])):u=_.concat(u,c[e])})),u}));return a[r]=c,c},getTitle(e,{formDefId:t,fieldDefId:s,orgInfo:i,isDm:o},r){return l({url:`/app_flow/v1/papi/assist_field/${t}/${s}/list_title/`,method:"GET",params:{values:JSON.stringify(r)}},e,i)},searchSelectOpts(e,{formDefId:t,fieldDefId:s,orgInfo:i,isDm:o},r={},n=""){return n&&(r.q=n),l({url:o?`/app_flow/v1/papi/dm/assist_field/${t}/${s}/search_title/`:`/app_flow/v1/papi/assist_field/${t}/${s}/search_title/`,method:"GET",params:r},e,i)}},assistTreeField:{searchSelectOpts(e,{formDefId:t,fieldDefId:s,orgInfo:i,isDm:o},r={},n=""){return n&&(r.q=n),l({url:o?`/app_flow/v1/papi/dm/assist_tree_field/${t}/${s}/search_title/`:`/app_flow/v1/papi/assist_tree_field/${t}/${s}/search_title/`,method:"GET",params:r},e,i)}},assistUserTaskCC:{searchSelectOpts(e,{formDefId:t,node:s,orgInfo:i,isDm:o},r={},n=""){return n&&(r.q=n),l({url:`/app_flow/v1/papi/assist_user_task_cc/${t}/${s}/search_title/`,method:"GET",params:r},e,i)}}}},4239:function(e,t,s){"use strict";function i(){for(var e=["iphone","ipod","ipad","android","mobile","blackberry","webos","incognito","webmate","bada","nokia","lg","ucweb","skyfire"],t=navigator.userAgent.toLowerCase(),s=!1,i=0,o=e.length;i<o;i++)-1!=t.indexOf(e[i])&&(s=!0);return s}s.d(t,{tq:function(){return i}}),s(467),s(6656)},5460:function(e,t,s){"use strict";s.d(t,{Z:function(){return a}});var i=function(){var e=this,t=e.$createElement;return(e._self._c||t)("span",{attrs:{title:e.label}},[e._v(e._s(e.label))])};i._withStripped=!0;var o=s(467),r=s.n(o),n={props:["value","fieldConf","row","formName","orgInfo"],data(){return{label:""}},watch:{value(){this.loadRemoteLabel()}},mounted(){this.loadRemoteLabel()},methods:{async loadRemoteLabel(){let e=this.value;if(r().isNil(e)||!e)return this.label="未选择";try{if(r().isObject(e))try{e=JSON.parse(e)}catch(e){console.log("error",e)}let t=r().isArray(e)?e:[e],s=r().get(this.fieldConf,"id");r().isEmpty(t)?this.label="未选择":(t=r().isArray(t)?t:[t],this.label=await this.$bpm.fetchLabelByValues(t,s,this.formName,this.row))}finally{console.log("finally")}}}},l=(0,s(1900).Z)(n,i,[],!1,null,null,null);l.options.__file="components/lib/mixins/RemoteSelectReader.vue";var a=l.exports},1900:function(e,t,s){"use strict";function i(e,t,s,i,o,r,n,l){var a,c="function"==typeof e?e.options:e;if(t&&(c.render=t,c.staticRenderFns=s,c._compiled=!0),i&&(c.functional=!0),r&&(c._scopeId="data-v-"+r),n?(a=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),o&&o.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(n)},c._ssrRegister=a):o&&(a=l?function(){o.call(this,(c.functional?this.parent:this).$root.$options.shadowRoot)}:o),a)if(c.functional){c._injectStyles=a;var u=c.render;c.render=function(e,t){return a.call(t),u(e,t)}}else{var f=c.beforeCreate;c.beforeCreate=f?[].concat(f,a):[a]}return{exports:e,options:c}}s.d(t,{Z:function(){return i}})},6981:function(e){e.exports=function(){return this.ELEMENT}()},3371:function(e){e.exports=function(){return this.Vue}()},467:function(t){"use strict";t.exports=e},6656:function(e){"use strict";e.exports=t}},i={};function o(e){var t=i[e];if(void 0!==t)return t.exports;var r=i[e]={exports:{}};return s[e](r,r.exports,o),r.exports}o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,{a:t}),t},o.d=function(e,t){for(var s in t)o.o(t,s)&&!o.o(e,s)&&Object.defineProperty(e,s,{enumerable:!0,get:t[s]})},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var r={};return function(){"use strict";o.r(r),o.d(r,{default:function(){return C}});var e=function(){var e=this,t=e.$createElement;return(e._self._c||t)(e.curComponent,e._g(e._b({ref:"inner-component",tag:"component",staticClass:"bpm-select-form-field",attrs:{type:e.type,fieldConf:e.fieldConf,row:e.row,mode:e.mode,orgInfo:e.orgInfo,formName:e.formName,uiType:e.uiType,isMultiple:e.multiple},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},"component",e.$attrs,!1),e.$listeners))};e._withStripped=!0;var t=function(){var e=this,t=e.$createElement,s=e._self._c||t;return s("div",{staticClass:"bpm-select-edit",staticStyle:{display:"flex"}},[e.showUnit?s("select-unit",{attrs:{fieldConf:e.fieldConf,formDefId:e.formDefId,orgInfo:e.orgInfo},on:{change:e.handleUnitChange}}):e._e(),e._v(" "),s("el-select",e._g(e._b({key:e.isMultiple?"two":"one",staticStyle:{flex:"1","margin-left":"5px"},attrs:{placeholder:e.placeholder,multiple:e.isMultiple,clearable:"",filterable:"",remote:"","remote-method":e.remoteMethod},on:{change:e.onChange},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},"el-select",e.$attrs,!1),e.$listeners),e._l(e.options,(function(e){return s("el-option",{key:e.value,attrs:{label:e.label,value:e.value}})})),1)],1)};t._withStripped=!0;var s=o(3371),i=o.n(s),n=o(6981),l=o(3532),a=function(){var e=this,t=e.$createElement,s=e._self._c||t;return s("el-select",{attrs:{placeholder:e.$z("单位选择","b2.common.unit_selection"),filterable:"",remote:""},on:{"remote-method":e.remoteMethod,change:e.handleUnitChange},model:{value:e.selectedTeam,callback:function(t){e.selectedTeam=t},expression:"selectedTeam"}},e._l(e.teams,(function(e){return s("el-option",{key:e.value,attrs:{label:e.label,value:e.value}})})),1)};a._withStripped=!0;var c={name:"SelectUnit",props:["fieldConf","orgInfo","formDefId"],data(){return{selectedTeam:"",teams:[],teamMap:{},teamKeyword:"",debounceSearchTeams:_.debounce(_.bind(this.loadTeams,this),150,{trailing:!0,leading:!1})}},mounted(){this.loadTeams()},methods:{handleUnitChange(){this.$emit("change",this.selectedTeam)},async loadTeams(){let e=_.get(this.orgInfo,"page_level"),t=_.get(this.orgInfo,`${e}_id`);this.teams=await this.$bpm.searchTeamSelectOpts(this.fieldConf.id,{keyword:this.teamKeyword,[`${e}_id`]:t},this.formDefId),this.teamMap=_.keyBy(this.teams,"value")},remoteMethod(e){this.teamKeyword=e||"",this.debounceSearchTeams()}}},u=o(1900),f=(0,u.Z)(c,a,[],!1,null,null,null);f.options.__file="components/lib/bpmSelectFromField/src/part/select-unit.vue";var d=f.exports;i().use(n.Select),i().use(n.Option);var p={props:["type","value","fieldConf","row","formName","formDefId","orgInfo","dm","isMultiple"],components:{SelectUnit:d},data(){return{curVal:"",options:[],keyword:"",unit:{search_type:"",org_id:""}}},watch:{value(){this.curVal=this.value},getSelectOptions:function(e){console.log("----selectOptions----",e),this.transformOptions(e)}},inject:["selectOptions"],computed:{placeholder(){return this.fieldConf.desc||this.fieldConf.name},getSelectOptions(){return this.selectOptions?this.selectOptions():[]},showUnit(){return"SelectURUser"===this.type||"MulSelectURUser"===this.type}},created(){this.curVal=this.isMultiple?[]:""},mounted(){(this.fieldConf.perm||{visible:!0}).visible&&(console.log("mounted getting options"),this.loadSelectOpts()),this.curVal=this.value},methods:{handleUnitChange(e){let t=_.split(e,"$"),s=_.get(t,"0"),i=_.get(t,"1");this.unit={search_type:s,org_id:i},this.loadSelectOpts("",JSON.stringify(this.unit))},remoteMethod(e){let t="";this.showUnit&&this.unit.search_type&&(t=JSON.stringify(this.unit)),this.loadSelectOpts(e,t)},async loadSelectOpts(e="",t=""){let s,i=this.fieldConf.id,o={q:e,spec:t};if("UserTaskCC"===this.fieldConf.type){console.log("UserTaskCC is getting options");const e=this.fieldConf.node;s=await l.Z.assistUserTaskCC.searchSelectOpts(this.$bpm,{formDefId:this.formDefId,node:e,orgInfo:this.orgInfo,isDm:this.dm},o)}else s=await l.Z.assistField.searchSelectOpts(this.$bpm,{formDefId:this.formDefId,fieldDefId:i,orgInfo:this.orgInfo,isDm:this.dm},o);const r=_.get(s.data,"data.data",[]);return this.transformOptions(r)},transformOptions(e){console.log("transformOptions origin: ",e);let t=_.map(e,(e=>({value:e[0],label:e[1]})));return this.options=t,console.log("options: ",t),t},onChange(e){this.$emit("input",e),this.$emit("change",e)}}},m=(0,u.Z)(p,t,[],!1,null,null,null);m.options.__file="components/lib/bpmSelectFromField/src/part/editor.vue";var h=m.exports,g={mixins:[o(5460).Z]},v=(0,u.Z)(g,void 0,void 0,!1,null,null,null);v.options.__file="components/lib/bpmSelectFromField/src/part/reader.vue";var y=v.exports,b={name:"BpmSelectFromField",components:{editorComponent:h,readerComponent:y},props:{value:{type:[Array,Number,String]},type:{type:String,default:"SelectFromField"},fieldConf:{type:Object,default(){return{}}},row:{type:Object,default(){return{}}},mode:{type:String,default(){return"view"}},uiType:{type:String,default(){return"default"}},orgInfo:{type:Object},formName:{type:String},isMultiple:{type:Boolean,default(){return!1}}},data(){return{curVal:""}},computed:{curComponent(){return"view"==this.mode?y:h},multiple(){let e=this.isMultiple||0===this.type.indexOf("Mul");return"UserTaskCC"===this.type&&this.fieldConf.selecter&&(e=0===(this.fieldConf.selecter.type||"MulSelectUser4CC").indexOf("Mul")),e}},watch:{curVal(e){this.$emit("input",e),this.$emit("change",e)},value(){this.curVal=this.value}},mounted(){this.curVal=this.value}},S=(0,u.Z)(b,e,[],!1,null,null,null);S.options.__file="components/lib/bpmSelectFromField/src/main.vue";var w=S.exports;w.install=function(e){e.component(w.name,w)};var C=w}(),r}()}));
1
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("lodash"),require("qs")):"function"==typeof define&&define.amd?define(["lodash","qs"],t):"object"==typeof exports?exports.bpm2=t(require("lodash"),require("qs")):e.bpm2=t(e.lodash,e.qs)}(self,(function(e,t){return function(){var s={3532:function(e,t,s){"use strict";s.d(t,{Z:function(){return c}});var o=s(4239),i=s(467),r=s.n(i),n=class{constructor(e,t={}){this._fnBatchLoad=e,this._options=t,this._queue=[]}async load(e){let t=await this.loads(e);return r().get(t,"0")}loads(...e){return new Promise(((t,s)=>{this._queue.push({keys:e,resolve:t,reject:s}),1==this._queue.length&&this.nextTick((()=>{this.process()}))}))}nextTick(e){setTimeout(e,0)}process(){let e=this._queue;this._queue=[];let t={};r().each(e,(e=>{r().each(e.keys,(e=>t[e]=null))}));let s=r().keys(t);this._fnBatchLoad(s).then((o=>{r().each(s,((e,s)=>{t[e]=o[s]})),r().each(e,(({keys:e,resolve:s})=>{s(r().map(e,(e=>t[e])))}))})).catch((t=>{r().each(e,(({reject:e})=>e(t)))}))}};const l=async(e,t,s)=>{if(console.log("netHeader",t.netHeader),t.networking=!0,t.netHeader&&(e.headers={common:t.netHeader}),e.params=_.merge({},e.params,s),t.env.ignore_levels&&_.set(e.params,"ignore_levels",!0),(0,o.tq)()){let t=zj.utils.pageParam().token;e.params=_.merge({token:t,platform:"phone"},e.params)}e.isSilentOnErr=e=>{let t=_.get(e,"data.result");return t>=19e6||t<=19999999};let i=await zj.net.request(e);return t.networking=!1,i},a={};var c={assistSelectEntranceForm:{getListDefinition(e,{formDefId:t,fieldDefId:s,orgInfo:o,isDm:i}){return l({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${s}/list_definition/`,method:"GET"},e,o)},getOptions(e,{formDefId:t,fieldDefId:s,orgInfo:o,isDm:i},r){return l({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${s}/list_search/`,method:"GET",params:r},e,o)},getListSelected(e,{formDefId:t,fieldDefId:s,orgInfo:o,isDm:i},r){return l({url:`/app_flow/v1/papi/assist_select_entrance_form/${t}/${s}/list_selected/`,method:"GET",params:r},e,o)}},assistField:{getBatchLoader(e,{formDefId:t,fieldDefId:s,orgInfo:o,uniqueId:i}){const r=`${t}/${s}`,c=a[r]||new n((async r=>{console.log("assist_field/list_title requeset is call");let n=`/app_flow/v1/papi/assist_field/${t}/${s}/list_title/`;const a=await l({url:n,method:"GET",params:{values:JSON.stringify(r)}},e,o),c=_.get(a,"data.data.data",{});let u=[];return _.map(r,(e=>{i?(e=JSON.parse(e),e=_.get(e,`${i}`),u=_.concat(u,c[e])):u=_.concat(u,c[e])})),u}));return a[r]=c,c},getTitle(e,{formDefId:t,fieldDefId:s,orgInfo:o,isDm:i},r){return l({url:`/app_flow/v1/papi/assist_field/${t}/${s}/list_title/`,method:"GET",params:{values:JSON.stringify(r)}},e,o)},searchSelectOpts(e,{formDefId:t,fieldDefId:s,orgInfo:o,isDm:i},r={},n=""){return n&&(r.q=n),l({url:i?`/app_flow/v1/papi/dm/assist_field/${t}/${s}/search_title/`:`/app_flow/v1/papi/assist_field/${t}/${s}/search_title/`,method:"GET",params:r},e,o)}},assistTreeField:{searchSelectOpts(e,{formDefId:t,fieldDefId:s,orgInfo:o,isDm:i},r={},n=""){return n&&(r.q=n),l({url:i?`/app_flow/v1/papi/dm/assist_tree_field/${t}/${s}/search_title/`:`/app_flow/v1/papi/assist_tree_field/${t}/${s}/search_title/`,method:"GET",params:r},e,o)}},assistUserTaskCC:{searchSelectOpts(e,{formDefId:t,node:s,orgInfo:o,isDm:i},r={},n=""){return n&&(r.q=n),l({url:`/app_flow/v1/papi/assist_user_task_cc/${t}/${s}/search_title/`,method:"GET",params:r},e,o)}}}},4239:function(e,t,s){"use strict";function o(){for(var e=["iphone","ipod","ipad","android","mobile","blackberry","webos","incognito","webmate","bada","nokia","lg","ucweb","skyfire"],t=navigator.userAgent.toLowerCase(),s=!1,o=0,i=e.length;o<i;o++)-1!=t.indexOf(e[o])&&(s=!0);return s}s.d(t,{tq:function(){return o}}),s(467),s(6656)},5460:function(e,t,s){"use strict";s.d(t,{Z:function(){return a}});var o=function(){var e=this,t=e.$createElement;return(e._self._c||t)("span",{attrs:{title:e.label}},[e._v(e._s(e.label))])};o._withStripped=!0;var i=s(467),r=s.n(i),n={props:["value","fieldConf","row","formName","orgInfo"],data(){return{label:""}},watch:{value(){this.loadRemoteLabel()}},mounted(){this.loadRemoteLabel()},methods:{async loadRemoteLabel(){let e=this.value;if(r().isNil(e)||!e)return this.label=zj.z("未选择","c.not_selected");try{if(r().isObject(e))try{e=JSON.parse(e)}catch(e){console.log("error",e)}let t=r().isArray(e)?e:[e],s=r().get(this.fieldConf,"id");r().isEmpty(t)?this.label=zj.z("未选择","c.not_selected"):(t=r().isArray(t)?t:[t],this.label=await this.$bpm.fetchLabelByValues(t,s,this.formName,this.row))}finally{console.log("finally")}}}},l=(0,s(1900).Z)(n,o,[],!1,null,null,null);l.options.__file="components/lib/mixins/RemoteSelectReader.vue";var a=l.exports},1900:function(e,t,s){"use strict";function o(e,t,s,o,i,r,n,l){var a,c="function"==typeof e?e.options:e;if(t&&(c.render=t,c.staticRenderFns=s,c._compiled=!0),o&&(c.functional=!0),r&&(c._scopeId="data-v-"+r),n?(a=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),i&&i.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(n)},c._ssrRegister=a):i&&(a=l?function(){i.call(this,(c.functional?this.parent:this).$root.$options.shadowRoot)}:i),a)if(c.functional){c._injectStyles=a;var u=c.render;c.render=function(e,t){return a.call(t),u(e,t)}}else{var f=c.beforeCreate;c.beforeCreate=f?[].concat(f,a):[a]}return{exports:e,options:c}}s.d(t,{Z:function(){return o}})},6981:function(e){e.exports=function(){return this.ELEMENT}()},3371:function(e){e.exports=function(){return this.Vue}()},467:function(t){"use strict";t.exports=e},6656:function(e){"use strict";e.exports=t}},o={};function i(e){var t=o[e];if(void 0!==t)return t.exports;var r=o[e]={exports:{}};return s[e](r,r.exports,i),r.exports}i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,{a:t}),t},i.d=function(e,t){for(var s in t)i.o(t,s)&&!i.o(e,s)&&Object.defineProperty(e,s,{enumerable:!0,get:t[s]})},i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},i.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var r={};return function(){"use strict";i.r(r),i.d(r,{default:function(){return C}});var e=function(){var e=this,t=e.$createElement;return(e._self._c||t)(e.curComponent,e._g(e._b({ref:"inner-component",tag:"component",staticClass:"bpm-select-form-field",attrs:{type:e.type,fieldConf:e.fieldConf,row:e.row,mode:e.mode,orgInfo:e.orgInfo,formName:e.formName,uiType:e.uiType,isMultiple:e.multiple},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},"component",e.$attrs,!1),e.$listeners))};e._withStripped=!0;var t=function(){var e=this,t=e.$createElement,s=e._self._c||t;return s("div",{staticClass:"bpm-select-edit",staticStyle:{display:"flex"}},[e.showUnit?s("select-unit",{attrs:{fieldConf:e.fieldConf,formDefId:e.formDefId,orgInfo:e.orgInfo},on:{change:e.handleUnitChange}}):e._e(),e._v(" "),s("el-select",e._g(e._b({key:e.isMultiple?"two":"one",staticStyle:{flex:"1","margin-left":"5px"},attrs:{placeholder:e.placeholder,multiple:e.isMultiple,clearable:"",filterable:"",remote:"","remote-method":e.remoteMethod},on:{change:e.onChange},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},"el-select",e.$attrs,!1),e.$listeners),e._l(e.options,(function(e){return s("el-option",{key:e.value,attrs:{label:e.label,value:e.value}})})),1)],1)};t._withStripped=!0;var s=i(3371),o=i.n(s),n=i(6981),l=i(3532),a=function(){var e=this,t=e.$createElement,s=e._self._c||t;return s("el-select",{attrs:{placeholder:e.$z("单位选择","b2.common.unit_selection"),filterable:"",remote:""},on:{"remote-method":e.remoteMethod,change:e.handleUnitChange},model:{value:e.selectedTeam,callback:function(t){e.selectedTeam=t},expression:"selectedTeam"}},e._l(e.teams,(function(e){return s("el-option",{key:e.value,attrs:{label:e.label,value:e.value}})})),1)};a._withStripped=!0;var c={name:"SelectUnit",props:["fieldConf","orgInfo","formDefId"],data(){return{selectedTeam:"",teams:[],teamMap:{},teamKeyword:"",debounceSearchTeams:_.debounce(_.bind(this.loadTeams,this),150,{trailing:!0,leading:!1})}},mounted(){this.loadTeams()},methods:{handleUnitChange(){this.$emit("change",this.selectedTeam)},async loadTeams(){let e=_.get(this.orgInfo,"page_level"),t=_.get(this.orgInfo,`${e}_id`);this.teams=await this.$bpm.searchTeamSelectOpts(this.fieldConf.id,{keyword:this.teamKeyword,[`${e}_id`]:t},this.formDefId),this.teamMap=_.keyBy(this.teams,"value")},remoteMethod(e){this.teamKeyword=e||"",this.debounceSearchTeams()}}},u=i(1900),f=(0,u.Z)(c,a,[],!1,null,null,null);f.options.__file="components/lib/bpmSelectFromField/src/part/select-unit.vue";var d=f.exports;o().use(n.Select),o().use(n.Option);var p={props:["type","value","fieldConf","row","formName","formDefId","orgInfo","dm","isMultiple"],components:{SelectUnit:d},data(){return{curVal:"",options:[],keyword:"",unit:{search_type:"",org_id:""}}},watch:{value(){this.curVal=this.value},getSelectOptions:function(e){console.log("----selectOptions----",e),this.transformOptions(e)}},inject:["selectOptions"],computed:{placeholder(){return this.fieldConf.desc||this.fieldConf.name},getSelectOptions(){return this.selectOptions?this.selectOptions():[]},showUnit(){return"SelectURUser"===this.type||"MulSelectURUser"===this.type}},created(){this.curVal=this.isMultiple?[]:""},mounted(){(this.fieldConf.perm||{visible:!0}).visible&&(console.log("mounted getting options"),this.loadSelectOpts()),this.curVal=this.value},methods:{handleUnitChange(e){let t=_.split(e,"$"),s=_.get(t,"0"),o=_.get(t,"1");this.unit={search_type:s,org_id:o},this.loadSelectOpts("",JSON.stringify(this.unit))},remoteMethod(e){let t="";this.showUnit&&this.unit.search_type&&(t=JSON.stringify(this.unit)),this.loadSelectOpts(e,t)},async loadSelectOpts(e="",t=""){let s,o=this.fieldConf.id,i={q:e,spec:t};if("UserTaskCC"===this.fieldConf.type){console.log("UserTaskCC is getting options");const e=this.fieldConf.node;s=await l.Z.assistUserTaskCC.searchSelectOpts(this.$bpm,{formDefId:this.formDefId,node:e,orgInfo:this.orgInfo,isDm:this.dm},i)}else s=await l.Z.assistField.searchSelectOpts(this.$bpm,{formDefId:this.formDefId,fieldDefId:o,orgInfo:this.orgInfo,isDm:this.dm},i);const r=_.get(s.data,"data.data",[]);return this.transformOptions(r)},transformOptions(e){console.log("transformOptions origin: ",e);let t=_.map(e,(e=>({value:e[0],label:e[1]})));return this.options=t,console.log("options: ",t),t},onChange(e){this.$emit("input",e),this.$emit("change",e)}}},m=(0,u.Z)(p,t,[],!1,null,null,null);m.options.__file="components/lib/bpmSelectFromField/src/part/editor.vue";var h=m.exports,g={mixins:[i(5460).Z]},v=(0,u.Z)(g,void 0,void 0,!1,null,null,null);v.options.__file="components/lib/bpmSelectFromField/src/part/reader.vue";var y=v.exports,b={name:"BpmSelectFromField",components:{editorComponent:h,readerComponent:y},props:{value:{type:[Array,Number,String]},type:{type:String,default:"SelectFromField"},fieldConf:{type:Object,default(){return{}}},row:{type:Object,default(){return{}}},mode:{type:String,default(){return"view"}},uiType:{type:String,default(){return"default"}},orgInfo:{type:Object},formName:{type:String},isMultiple:{type:Boolean,default(){return!1}}},data(){return{curVal:""}},computed:{curComponent(){return"view"==this.mode?y:h},multiple(){let e=this.isMultiple||0===this.type.indexOf("Mul");return"UserTaskCC"===this.type&&this.fieldConf.selecter&&(e=0===(this.fieldConf.selecter.type||"MulSelectUser4CC").indexOf("Mul")),e}},watch:{curVal(e){this.$emit("input",e),this.$emit("change",e)},value(){this.curVal=this.value}},mounted(){this.curVal=this.value}},S=(0,u.Z)(b,e,[],!1,null,null,null);S.options.__file="components/lib/bpmSelectFromField/src/main.vue";var w=S.exports;w.install=function(e){e.component(w.name,w)};var C=w}(),r}()}));
@@ -1 +1 @@
1
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("lodash")):"function"==typeof define&&define.amd?define(["lodash"],t):"object"==typeof exports?exports.bpm2=t(require("lodash")):e.bpm2=t(e.lodash)}(self,(function(e){return function(){var t={9392:function(e,t,n){"use strict";var r=n(8081),o=n.n(r),i=n(3645),s=n.n(i)()(o());s.push([e.id,".select-from-form-editor {\n .fake-trigger {\n min-height: 40px;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n border: 1px solid #d9dce3;\n border-radius: 4px;\n padding: 0 15px;\n cursor: pointer;\n }\n}\n.bpm-select-from-form-box{\n list-style: none;\n padding: 10px 0;\n max-height: calc(70vh - 220px);\n box-sizing: border-box;\n overflow: auto;\n\n .form-item{\n list-style: none;\n margin-bottom: 10px;\n }\n .subitem {\n margin-left: 24px;\n padding: 6px 0;\n font-size: 12px;\n color: #949494;\n }\n}\n",""]),t.Z=s},432:function(e,t,n){"use strict";var r=n(8081),o=n.n(r),i=n(3645),s=n.n(i),a=n(9392),l=s()(o());l.i(a.Z),l.push([e.id,"\n",""]),t.Z=l},3645:function(e){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",r=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),r&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),r&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,r,o,i){"string"==typeof e&&(e=[[null,e,void 0]]);var s={};if(r)for(var a=0;a<this.length;a++){var l=this[a][0];null!=l&&(s[l]=!0)}for(var u=0;u<e.length;u++){var c=[].concat(e[u]);r&&s[c[0]]||(void 0!==i&&(void 0===c[5]||(c[1]="@layer".concat(c[5].length>0?" ".concat(c[5]):""," {").concat(c[1],"}")),c[5]=i),n&&(c[2]?(c[1]="@media ".concat(c[2]," {").concat(c[1],"}"),c[2]=n):c[2]=n),o&&(c[4]?(c[1]="@supports (".concat(c[4],") {").concat(c[1],"}"),c[4]=o):c[4]="".concat(o)),t.push(c))}},t}},8081:function(e){"use strict";e.exports=function(e){return e[1]}},3379:function(e){"use strict";var t=[];function n(e){for(var n=-1,r=0;r<t.length;r++)if(t[r].identifier===e){n=r;break}return n}function r(e,r){for(var i={},s=[],a=0;a<e.length;a++){var l=e[a],u=r.base?l[0]+r.base:l[0],c=i[u]||0,d="".concat(u," ").concat(c);i[u]=c+1;var f=n(d),p={css:l[1],media:l[2],sourceMap:l[3],supports:l[4],layer:l[5]};if(-1!==f)t[f].references++,t[f].updater(p);else{var m=o(p,r);r.byIndex=a,t.splice(a,0,{identifier:d,updater:m,references:1})}s.push(d)}return s}function o(e,t){var n=t.domAPI(t);return n.update(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap&&t.supports===e.supports&&t.layer===e.layer)return;n.update(e=t)}else n.remove()}}e.exports=function(e,o){var i=r(e=e||[],o=o||{});return function(e){e=e||[];for(var s=0;s<i.length;s++){var a=n(i[s]);t[a].references--}for(var l=r(e,o),u=0;u<i.length;u++){var c=n(i[u]);0===t[c].references&&(t[c].updater(),t.splice(c,1))}i=l}}},569:function(e){"use strict";var t={};e.exports=function(e,n){var r=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}},9216:function(e){"use strict";e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},3565:function(e,t,n){"use strict";e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7795:function(e){"use strict";e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var r="";n.supports&&(r+="@supports (".concat(n.supports,") {")),n.media&&(r+="@media ".concat(n.media," {"));var o=void 0!==n.layer;o&&(r+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),r+=n.css,o&&(r+="}"),n.media&&(r+="}"),n.supports&&(r+="}");var i=n.sourceMap;i&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(i))))," */")),t.styleTagTransform(r,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},4589:function(e){"use strict";e.exports=function(e,t){if(t.styleSheet)t.styleSheet.cssText=e;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(e))}}},5460:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=function(){var e=this,t=e.$createElement;return(e._self._c||t)("span",{attrs:{title:e.label}},[e._v(e._s(e.label))])};r._withStripped=!0;var o=n(467),i=n.n(o),s={props:["value","fieldConf","row","formName","orgInfo"],data(){return{label:""}},watch:{value(){this.loadRemoteLabel()}},mounted(){this.loadRemoteLabel()},methods:{async loadRemoteLabel(){let e=this.value;if(i().isNil(e)||!e)return this.label="未选择";try{if(i().isObject(e))try{e=JSON.parse(e)}catch(e){console.log("error",e)}let t=i().isArray(e)?e:[e],n=i().get(this.fieldConf,"id");i().isEmpty(t)?this.label="未选择":(t=i().isArray(t)?t:[t],this.label=await this.$bpm.fetchLabelByValues(t,n,this.formName,this.row))}finally{console.log("finally")}}}},a=(0,n(1900).Z)(s,r,[],!1,null,null,null);a.options.__file="components/lib/mixins/RemoteSelectReader.vue";var l=a.exports},1900:function(e,t,n){"use strict";function r(e,t,n,r,o,i,s,a){var l,u="function"==typeof e?e.options:e;if(t&&(u.render=t,u.staticRenderFns=n,u._compiled=!0),r&&(u.functional=!0),i&&(u._scopeId="data-v-"+i),s?(l=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),o&&o.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(s)},u._ssrRegister=l):o&&(l=a?function(){o.call(this,(u.functional?this.parent:this).$root.$options.shadowRoot)}:o),l)if(u.functional){u._injectStyles=l;var c=u.render;u.render=function(e,t){return l.call(t),c(e,t)}}else{var d=u.beforeCreate;u.beforeCreate=d?[].concat(d,l):[l]}return{exports:e,options:u}}n.d(t,{Z:function(){return r}})},6981:function(e){e.exports=function(){return this.ELEMENT}()},3371:function(e){e.exports=function(){return this.Vue}()},467:function(t){"use strict";t.exports=e}},n={};function r(e){var o=n[e];if(void 0!==o)return o.exports;var i=n[e]={id:e,exports:{}};return t[e](i,i.exports,r),i.exports}r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,{a:t}),t},r.d=function(e,t){for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.nc=void 0;var o={};return function(){"use strict";r.r(o),r.d(o,{default:function(){return $}});var e=function(){var e=this,t=e.$createElement;return(e._self._c||t)(e.curComponent,e._g(e._b({tag:"component",staticClass:"bpm-select-from-form",attrs:{fieldConf:e.fieldConf,row:e.row,mode:e.mode,formName:e.formName,orgInfo:e.orgInfo,uiType:e.uiType,isMultiple:e.isMultiple},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},"component",e.$attrs,!1),e.$listeners))};e._withStripped=!0;var t=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"select-from-form-editor"},[n("div",{on:{click:e.toOpen}},[n("div",{staticClass:"fake-trigger"},[e._v(e._s(e.label))])]),e._v(" "),n("el-dialog",{attrs:{"append-to-body":!0,visible:e.opened,"before-close":e.onHide,title:e.fieldConf.name,width:"40%"},on:{"update:visible":function(t){e.opened=t},open:e.onOpen}},[n("el-input",{staticClass:"input-with-select",attrs:{placeholder:"只展示前100条数据,通过搜索获取更多"},on:{change:e.debounceSearch},model:{value:e.keyword,callback:function(t){e.keyword=t},expression:"keyword"}}),e._v(" "),n("div",{staticClass:"bpm-select-from-form-box"},[e.isMultiple?n("el-checkbox-group",{attrs:{max:e.maxCount},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},e._l(e.formList,(function(t){return n("div",{key:t.id,staticClass:"form-item"},[n("div",{style:e.titleStyle},[n("el-checkbox",{key:t.id,attrs:{label:t.id}},[e._v(e._s(t.title))])],1),e._v(" "),e._l(t.fields,(function(t){return n("div",{key:t.id,staticClass:"subitem",style:e.geFieldStyle(t.key)},[e._v("\n "+e._s(t.key+": "+t.value)+"\n ")])}))],2)})),0):n("el-radio-group",{model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},e._l(e.formList,(function(t){return n("div",{key:t.id,staticClass:"form-item"},[n("div",{style:e.titleStyle},[n("el-radio",{key:t.id,attrs:{label:t.id,value:t.id}},[e._v(e._s(t.title))])],1),e._v(" "),e._l(t.fields,(function(t){return n("div",{key:t.id,staticClass:"subitem",style:e.geFieldStyle(t.key)},[e._v("\n "+e._s(t.key+": "+t.value)+"\n ")])}))],2)})),0)],1),e._v(" "),n("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[n("el-button",{attrs:{type:"primary"},on:{click:e.onSubmit}},[e._v("确 定")])],1)],1)],1)};t._withStripped=!0;var n=r(3371),i=r.n(n),s=r(467),a=r.n(s),l=r(6981);i().use(l.Dialog);var u={props:["value","fieldConf","row","formName","orgInfo","isMultiple"],data(){return{curVal:"",label:"未选择",keyword:"",opened:!1,debounceSearch:a().debounce(a().bind(this.search,this),150,{trailing:!0,leading:!1}),formList:[]}},watch:{value(e){(a().isString(e)||a().isArray(e))&&(this.curVal=e),this.loadRemoteLabel()}},computed:{placeholder(){return this.fieldConf.desc||this.fieldConf.name},maxCount(){return a().get(this.fieldConf,"check.max_count")},titleStyle(){let e=this.fieldConf,t=a().get(e,"range_remote.range_display.title");return{fontSize:a().get(t,"size",16)+"px",color:a().get(t,"color","#333")}},fieldStyleMap(){let e=this.fieldConf,t=a().get(e,"range_remote.range_display.fields");return a().keyBy(t,"field")}},created(){},mounted(){this.value&&(a().isString(this.value)||a().isArray(this.value))?this.curVal=this.value:this.curVal=this.isMultiple?[]:"",this.loadRemoteLabel()},methods:{geFieldStyle(e){let t=a().get(this.fieldStyleMap,e);return{fontSize:a().get(t,"size",12)+"px",color:a().get(t,"color","#949494")}},async search(){let e=this.keyword,t=this.formName,n=a().get(this.fieldConf,"id"),r=await this.$bpm.searchSelectOpts(n,e,t,this,!1,this.orgInfo),o=a().map(r,(e=>({title:e.title,id:e.form_id,form_id:e.form_id,f_fields:e.f_fields,fields:a().map(e.f_fields,((e,t)=>({key:t,value:e})))})));this.formList=o},onHide(){this.opened=!1},onOpen(){this.search()},toOpen(){this.opened=!0},isChecked(e){return a().includes(this.curVal,e)},onSubmit(){this.$emit("input",this.curVal),this.opened=!1},async loadRemoteLabel(){let e=this.value,t=a().get(this.fieldConf,"id");a().isEmpty(e)?this.label="未选择":(e=a().isArray(e)?e:[e],this.label=await this.$bpm.fetchLabelByValues(e,t,this.formName,this.row))}}},c=r(1900),d=(0,c.Z)(u,t,[],!1,null,null,null);d.options.__file="components/lib/bpmSelectFromForm/src/part/editor.vue";var f=d.exports,p={mixins:[r(5460).Z]},m=(0,c.Z)(p,void 0,void 0,!1,null,null,null);m.options.__file="components/lib/bpmSelectFromForm/src/part/reader.vue";var h=m.exports,v={name:"bpmSelectFromForm",components:{editorComponent:f,readerComponent:h},props:{value:{type:[String,Array],default(){return""}},fieldConf:{type:Object,default(){return{}}},row:{type:Object,default(){return{}}},mode:{type:String,default(){return"view"}},uiType:{type:String,default(){return"default"}},orgInfo:{type:Object},formName:{type:String},isMultiple:{type:Boolean,default(){return!1}}},data(){return{curVal:""}},computed:{curComponent(){return"view"==this.mode?h:f}},watch:{curVal(e){this.$emit("input",e)},value(){this.curVal=this.value}},mounted(){this.curVal=this.value}},y=r(3379),b=r.n(y),g=r(7795),_=r.n(g),x=r(569),C=r.n(x),S=r(3565),w=r.n(S),k=r(9216),V=r.n(k),M=r(4589),T=r.n(M),E=r(432),O={};O.styleTagTransform=T(),O.setAttributes=w(),O.insert=C().bind(null,"head"),O.domAPI=_(),O.insertStyleElement=V(),b()(E.Z,O),E.Z&&E.Z.locals&&E.Z.locals;var N=(0,c.Z)(v,e,[],!1,null,null,null);N.options.__file="components/lib/bpmSelectFromForm/src/main.vue";var L=N.exports;L.install=function(e){e.component(L.name,L)};var $=L}(),o}()}));
1
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("lodash")):"function"==typeof define&&define.amd?define(["lodash"],t):"object"==typeof exports?exports.bpm2=t(require("lodash")):e.bpm2=t(e.lodash)}(self,(function(e){return function(){var t={9392:function(e,t,n){"use strict";var r=n(8081),o=n.n(r),i=n(3645),s=n.n(i)()(o());s.push([e.id,".select-from-form-editor {\n .fake-trigger {\n min-height: 40px;\n white-space: nowrap;\n overflow: hidden;\n text-overflow: ellipsis;\n border: 1px solid #d9dce3;\n border-radius: 4px;\n padding: 0 15px;\n cursor: pointer;\n }\n}\n.bpm-select-from-form-box{\n list-style: none;\n padding: 10px 0;\n max-height: calc(70vh - 220px);\n box-sizing: border-box;\n overflow: auto;\n\n .form-item{\n list-style: none;\n margin-bottom: 10px;\n }\n .subitem {\n margin-left: 24px;\n padding: 6px 0;\n font-size: 12px;\n color: #949494;\n }\n}\n",""]),t.Z=s},432:function(e,t,n){"use strict";var r=n(8081),o=n.n(r),i=n(3645),s=n.n(i),a=n(9392),l=s()(o());l.i(a.Z),l.push([e.id,"\n",""]),t.Z=l},3645:function(e){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",r=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),r&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),r&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,r,o,i){"string"==typeof e&&(e=[[null,e,void 0]]);var s={};if(r)for(var a=0;a<this.length;a++){var l=this[a][0];null!=l&&(s[l]=!0)}for(var c=0;c<e.length;c++){var u=[].concat(e[c]);r&&s[u[0]]||(void 0!==i&&(void 0===u[5]||(u[1]="@layer".concat(u[5].length>0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=i),n&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=n):u[2]=n),o&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=o):u[4]="".concat(o)),t.push(u))}},t}},8081:function(e){"use strict";e.exports=function(e){return e[1]}},3379:function(e){"use strict";var t=[];function n(e){for(var n=-1,r=0;r<t.length;r++)if(t[r].identifier===e){n=r;break}return n}function r(e,r){for(var i={},s=[],a=0;a<e.length;a++){var l=e[a],c=r.base?l[0]+r.base:l[0],u=i[c]||0,d="".concat(c," ").concat(u);i[c]=u+1;var f=n(d),p={css:l[1],media:l[2],sourceMap:l[3],supports:l[4],layer:l[5]};if(-1!==f)t[f].references++,t[f].updater(p);else{var m=o(p,r);r.byIndex=a,t.splice(a,0,{identifier:d,updater:m,references:1})}s.push(d)}return s}function o(e,t){var n=t.domAPI(t);return n.update(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap&&t.supports===e.supports&&t.layer===e.layer)return;n.update(e=t)}else n.remove()}}e.exports=function(e,o){var i=r(e=e||[],o=o||{});return function(e){e=e||[];for(var s=0;s<i.length;s++){var a=n(i[s]);t[a].references--}for(var l=r(e,o),c=0;c<i.length;c++){var u=n(i[c]);0===t[u].references&&(t[u].updater(),t.splice(u,1))}i=l}}},569:function(e){"use strict";var t={};e.exports=function(e,n){var r=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!r)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");r.appendChild(n)}},9216:function(e){"use strict";e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},3565:function(e,t,n){"use strict";e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7795:function(e){"use strict";e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var r="";n.supports&&(r+="@supports (".concat(n.supports,") {")),n.media&&(r+="@media ".concat(n.media," {"));var o=void 0!==n.layer;o&&(r+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),r+=n.css,o&&(r+="}"),n.media&&(r+="}"),n.supports&&(r+="}");var i=n.sourceMap;i&&"undefined"!=typeof btoa&&(r+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(i))))," */")),t.styleTagTransform(r,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},4589:function(e){"use strict";e.exports=function(e,t){if(t.styleSheet)t.styleSheet.cssText=e;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(e))}}},5460:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var r=function(){var e=this,t=e.$createElement;return(e._self._c||t)("span",{attrs:{title:e.label}},[e._v(e._s(e.label))])};r._withStripped=!0;var o=n(467),i=n.n(o),s={props:["value","fieldConf","row","formName","orgInfo"],data(){return{label:""}},watch:{value(){this.loadRemoteLabel()}},mounted(){this.loadRemoteLabel()},methods:{async loadRemoteLabel(){let e=this.value;if(i().isNil(e)||!e)return this.label=zj.z("未选择","c.not_selected");try{if(i().isObject(e))try{e=JSON.parse(e)}catch(e){console.log("error",e)}let t=i().isArray(e)?e:[e],n=i().get(this.fieldConf,"id");i().isEmpty(t)?this.label=zj.z("未选择","c.not_selected"):(t=i().isArray(t)?t:[t],this.label=await this.$bpm.fetchLabelByValues(t,n,this.formName,this.row))}finally{console.log("finally")}}}},a=(0,n(1900).Z)(s,r,[],!1,null,null,null);a.options.__file="components/lib/mixins/RemoteSelectReader.vue";var l=a.exports},1900:function(e,t,n){"use strict";function r(e,t,n,r,o,i,s,a){var l,c="function"==typeof e?e.options:e;if(t&&(c.render=t,c.staticRenderFns=n,c._compiled=!0),r&&(c.functional=!0),i&&(c._scopeId="data-v-"+i),s?(l=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),o&&o.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(s)},c._ssrRegister=l):o&&(l=a?function(){o.call(this,(c.functional?this.parent:this).$root.$options.shadowRoot)}:o),l)if(c.functional){c._injectStyles=l;var u=c.render;c.render=function(e,t){return l.call(t),u(e,t)}}else{var d=c.beforeCreate;c.beforeCreate=d?[].concat(d,l):[l]}return{exports:e,options:c}}n.d(t,{Z:function(){return r}})},6981:function(e){e.exports=function(){return this.ELEMENT}()},3371:function(e){e.exports=function(){return this.Vue}()},467:function(t){"use strict";t.exports=e}},n={};function r(e){var o=n[e];if(void 0!==o)return o.exports;var i=n[e]={id:e,exports:{}};return t[e](i,i.exports,r),i.exports}r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,{a:t}),t},r.d=function(e,t){for(var n in t)r.o(t,n)&&!r.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.nc=void 0;var o={};return function(){"use strict";r.r(o),r.d(o,{default:function(){return L}});var e=function(){var e=this,t=e.$createElement;return(e._self._c||t)(e.curComponent,e._g(e._b({tag:"component",staticClass:"bpm-select-from-form",attrs:{fieldConf:e.fieldConf,row:e.row,mode:e.mode,formName:e.formName,orgInfo:e.orgInfo,uiType:e.uiType,isMultiple:e.isMultiple},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},"component",e.$attrs,!1),e.$listeners))};e._withStripped=!0;var t=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"select-from-form-editor"},[n("div",{on:{click:e.toOpen}},[n("div",{staticClass:"fake-trigger"},[e._v(e._s(e.label))])]),e._v(" "),n("el-dialog",{attrs:{"append-to-body":!0,visible:e.opened,"before-close":e.onHide,title:e.fieldConf.name,width:"40%"},on:{"update:visible":function(t){e.opened=t},open:e.onOpen}},[n("el-input",{staticClass:"input-with-select",attrs:{placeholder:"只展示前100条数据,通过搜索获取更多"},on:{change:e.debounceSearch},model:{value:e.keyword,callback:function(t){e.keyword=t},expression:"keyword"}}),e._v(" "),n("div",{staticClass:"bpm-select-from-form-box"},[e.isMultiple?n("el-checkbox-group",{attrs:{max:e.maxCount},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},e._l(e.formList,(function(t){return n("div",{key:t.id,staticClass:"form-item"},[n("div",{style:e.titleStyle},[n("el-checkbox",{key:t.id,attrs:{label:t.id}},[e._v(e._s(t.title))])],1),e._v(" "),e._l(t.fields,(function(t){return n("div",{key:t.id,staticClass:"subitem",style:e.geFieldStyle(t.key)},[e._v("\n "+e._s(t.key+": "+t.value)+"\n ")])}))],2)})),0):n("el-radio-group",{model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},e._l(e.formList,(function(t){return n("div",{key:t.id,staticClass:"form-item"},[n("div",{style:e.titleStyle},[n("el-radio",{key:t.id,attrs:{label:t.id,value:t.id}},[e._v(e._s(t.title))])],1),e._v(" "),e._l(t.fields,(function(t){return n("div",{key:t.id,staticClass:"subitem",style:e.geFieldStyle(t.key)},[e._v("\n "+e._s(t.key+": "+t.value)+"\n ")])}))],2)})),0)],1),e._v(" "),n("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[n("el-button",{attrs:{type:"primary"},on:{click:e.onSubmit}},[e._v("确 定")])],1)],1)],1)};t._withStripped=!0;var n=r(3371),i=r.n(n),s=r(467),a=r.n(s),l=r(6981);i().use(l.Dialog);var c={props:["value","fieldConf","row","formName","orgInfo","isMultiple"],data(){return{curVal:"",label:"未选择",keyword:"",opened:!1,debounceSearch:a().debounce(a().bind(this.search,this),150,{trailing:!0,leading:!1}),formList:[]}},watch:{value(e){(a().isString(e)||a().isArray(e))&&(this.curVal=e),this.loadRemoteLabel()}},computed:{placeholder(){return this.fieldConf.desc||this.fieldConf.name},maxCount(){return a().get(this.fieldConf,"check.max_count")},titleStyle(){let e=this.fieldConf,t=a().get(e,"range_remote.range_display.title");return{fontSize:a().get(t,"size",16)+"px",color:a().get(t,"color","#333")}},fieldStyleMap(){let e=this.fieldConf,t=a().get(e,"range_remote.range_display.fields");return a().keyBy(t,"field")}},created(){},mounted(){this.value&&(a().isString(this.value)||a().isArray(this.value))?this.curVal=this.value:this.curVal=this.isMultiple?[]:"",this.loadRemoteLabel()},methods:{geFieldStyle(e){let t=a().get(this.fieldStyleMap,e);return{fontSize:a().get(t,"size",12)+"px",color:a().get(t,"color","#949494")}},async search(){let e=this.keyword,t=this.formName,n=a().get(this.fieldConf,"id"),r=await this.$bpm.searchSelectOpts(n,e,t,this,!1,this.orgInfo),o=a().map(r,(e=>({title:e.title,id:e.form_id,form_id:e.form_id,f_fields:e.f_fields,fields:a().map(e.f_fields,((e,t)=>({key:t,value:e})))})));this.formList=o},onHide(){this.opened=!1},onOpen(){this.search()},toOpen(){this.opened=!0},isChecked(e){return a().includes(this.curVal,e)},onSubmit(){this.$emit("input",this.curVal),this.opened=!1},async loadRemoteLabel(){let e=this.value,t=a().get(this.fieldConf,"id");a().isEmpty(e)?this.label="未选择":(e=a().isArray(e)?e:[e],this.label=await this.$bpm.fetchLabelByValues(e,t,this.formName,this.row))}}},u=r(1900),d=(0,u.Z)(c,t,[],!1,null,null,null);d.options.__file="components/lib/bpmSelectFromForm/src/part/editor.vue";var f=d.exports,p={mixins:[r(5460).Z]},m=(0,u.Z)(p,void 0,void 0,!1,null,null,null);m.options.__file="components/lib/bpmSelectFromForm/src/part/reader.vue";var h=m.exports,v={name:"bpmSelectFromForm",components:{editorComponent:f,readerComponent:h},props:{value:{type:[String,Array],default(){return""}},fieldConf:{type:Object,default(){return{}}},row:{type:Object,default(){return{}}},mode:{type:String,default(){return"view"}},uiType:{type:String,default(){return"default"}},orgInfo:{type:Object},formName:{type:String},isMultiple:{type:Boolean,default(){return!1}}},data(){return{curVal:""}},computed:{curComponent(){return"view"==this.mode?h:f}},watch:{curVal(e){this.$emit("input",e)},value(){this.curVal=this.value}},mounted(){this.curVal=this.value}},y=r(3379),b=r.n(y),g=r(7795),_=r.n(g),x=r(569),C=r.n(x),S=r(3565),w=r.n(S),k=r(9216),V=r.n(k),M=r(4589),T=r.n(M),E=r(432),O={};O.styleTagTransform=T(),O.setAttributes=w(),O.insert=C().bind(null,"head"),O.domAPI=_(),O.insertStyleElement=V(),b()(E.Z,O),E.Z&&E.Z.locals&&E.Z.locals;var N=(0,u.Z)(v,e,[],!1,null,null,null);N.options.__file="components/lib/bpmSelectFromForm/src/main.vue";var j=N.exports;j.install=function(e){e.component(j.name,j)};var L=j}(),o}()}));
@@ -1 +1 @@
1
- !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("lodash")):"function"==typeof define&&define.amd?define(["lodash"],t):"object"==typeof exports?exports.bpm2=t(require("lodash")):e.bpm2=t(e.lodash)}(self,(function(e){return function(){var t={7553:function(e,t,n){"use strict";var i=n(8081),r=n.n(i),o=n(3645),a=n.n(o)()(r());a.push([e.id,"\n .select-box{\n display: flex;\n .select-box-left{\n width: 200px;\n .title{\n margin-bottom: 10px;\n }\n }\n .select-box-right{\n flex: 1;\n padding-left: 20px;\n .title{\n margin-bottom: 10px;\n }\n }\n } \n .select-app,.select-app-item, .select-form, .select-form-item{\n list-style: none;\n margin: 0;\n padding: 0;\n margin-bottom: 10px;\n } \n .select-app, .select-form{\n padding: 10px;\n .select-app-item{\n cursor: pointer;\n }\n }\n\n .select-app-item.active{\n color: #409EFF;\n }\n",""]),t.Z=a},7957:function(e,t,n){"use strict";var i=n(8081),r=n.n(i),o=n(3645),a=n.n(o),s=n(7553),l=a()(r());l.i(s.Z),l.push([e.id,"\n",""]),t.Z=l},3645:function(e){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",i=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),i&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),i&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,i,r,o){"string"==typeof e&&(e=[[null,e,void 0]]);var a={};if(i)for(var s=0;s<this.length;s++){var l=this[s][0];null!=l&&(a[l]=!0)}for(var c=0;c<e.length;c++){var u=[].concat(e[c]);i&&a[u[0]]||(void 0!==o&&(void 0===u[5]||(u[1]="@layer".concat(u[5].length>0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=o),n&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=n):u[2]=n),r&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=r):u[4]="".concat(r)),t.push(u))}},t}},8081:function(e){"use strict";e.exports=function(e){return e[1]}},3379:function(e){"use strict";var t=[];function n(e){for(var n=-1,i=0;i<t.length;i++)if(t[i].identifier===e){n=i;break}return n}function i(e,i){for(var o={},a=[],s=0;s<e.length;s++){var l=e[s],c=i.base?l[0]+i.base:l[0],u=o[c]||0,p="".concat(c," ").concat(u);o[c]=u+1;var d=n(p),f={css:l[1],media:l[2],sourceMap:l[3],supports:l[4],layer:l[5]};if(-1!==d)t[d].references++,t[d].updater(f);else{var m=r(f,i);i.byIndex=s,t.splice(s,0,{identifier:p,updater:m,references:1})}a.push(p)}return a}function r(e,t){var n=t.domAPI(t);return n.update(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap&&t.supports===e.supports&&t.layer===e.layer)return;n.update(e=t)}else n.remove()}}e.exports=function(e,r){var o=i(e=e||[],r=r||{});return function(e){e=e||[];for(var a=0;a<o.length;a++){var s=n(o[a]);t[s].references--}for(var l=i(e,r),c=0;c<o.length;c++){var u=n(o[c]);0===t[u].references&&(t[u].updater(),t.splice(u,1))}o=l}}},569:function(e){"use strict";var t={};e.exports=function(e,n){var i=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!i)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");i.appendChild(n)}},9216:function(e){"use strict";e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},3565:function(e,t,n){"use strict";e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7795:function(e){"use strict";e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var i="";n.supports&&(i+="@supports (".concat(n.supports,") {")),n.media&&(i+="@media ".concat(n.media," {"));var r=void 0!==n.layer;r&&(i+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),i+=n.css,r&&(i+="}"),n.media&&(i+="}"),n.supports&&(i+="}");var o=n.sourceMap;o&&"undefined"!=typeof btoa&&(i+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),t.styleTagTransform(i,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},4589:function(e){"use strict";e.exports=function(e,t){if(t.styleSheet)t.styleSheet.cssText=e;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(e))}}},5460:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var i=function(){var e=this,t=e.$createElement;return(e._self._c||t)("span",{attrs:{title:e.label}},[e._v(e._s(e.label))])};i._withStripped=!0;var r=n(467),o=n.n(r),a={props:["value","fieldConf","row","formName","orgInfo"],data(){return{label:""}},watch:{value(){this.loadRemoteLabel()}},mounted(){this.loadRemoteLabel()},methods:{async loadRemoteLabel(){let e=this.value;if(o().isNil(e)||!e)return this.label="未选择";try{if(o().isObject(e))try{e=JSON.parse(e)}catch(e){console.log("error",e)}let t=o().isArray(e)?e:[e],n=o().get(this.fieldConf,"id");o().isEmpty(t)?this.label="未选择":(t=o().isArray(t)?t:[t],this.label=await this.$bpm.fetchLabelByValues(t,n,this.formName,this.row))}finally{console.log("finally")}}}},s=(0,n(1900).Z)(a,i,[],!1,null,null,null);s.options.__file="components/lib/mixins/RemoteSelectReader.vue";var l=s.exports},1900:function(e,t,n){"use strict";function i(e,t,n,i,r,o,a,s){var l,c="function"==typeof e?e.options:e;if(t&&(c.render=t,c.staticRenderFns=n,c._compiled=!0),i&&(c.functional=!0),o&&(c._scopeId="data-v-"+o),a?(l=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),r&&r.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(a)},c._ssrRegister=l):r&&(l=s?function(){r.call(this,(c.functional?this.parent:this).$root.$options.shadowRoot)}:r),l)if(c.functional){c._injectStyles=l;var u=c.render;c.render=function(e,t){return l.call(t),u(e,t)}}else{var p=c.beforeCreate;c.beforeCreate=p?[].concat(p,l):[l]}return{exports:e,options:c}}n.d(t,{Z:function(){return i}})},6981:function(e){e.exports=function(){return this.ELEMENT}()},3371:function(e){e.exports=function(){return this.Vue}()},467:function(t){"use strict";t.exports=e}},n={};function i(e){var r=n[e];if(void 0!==r)return r.exports;var o=n[e]={id:e,exports:{}};return t[e](o,o.exports,i),o.exports}i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,{a:t}),t},i.d=function(e,t){for(var n in t)i.o(t,n)&&!i.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},i.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.nc=void 0;var r={};return function(){"use strict";i.r(r),i.d(r,{default:function(){return j}});var e=function(){var e=this,t=e.$createElement;return(e._self._c||t)(e.curComponent,e._g(e._b({tag:"component",staticClass:"bpm-select-from-id",attrs:{fieldConf:e.fieldConf,row:e.row,mode:e.mode,uiType:e.uiType,orgInfo:e.orgInfo,formName:e.formName,isMultiple:e.isMultiple},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},"component",e.$attrs,!1),e.$listeners))};e._withStripped=!0;var t=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"select-from-id-editor"},[n("div",[n("div",{on:{click:e.toOpen}},[e._v(e._s(e.label))])]),e._v(" "),n("el-dialog",e._g(e._b({attrs:{visible:e.opened,"before-close":e.onHide,title:e.fieldConf.name,fullscreen:!0,"custom-class":"select-from-id-editor-dialog"},on:{"update:visible":function(t){e.opened=t},open:e.onOpen}},"el-dialog",e.$attrs,!1),e.$listeners),[n("div",{attrs:{slot:"title"},slot:"title"},[n("div",[e._v("\n 已选名单:\n "),e._l(e.selectedLabels,(function(t,i){return n("el-tag",{directives:[{name:"show",rawName:"v-show",value:i<=5,expression:"index <= 5"}],key:i,attrs:{type:"success"}},[e._v(e._s(t)+"\n "),n("i",{staticClass:"fa fa-times-circle",on:{click:function(t){return e.deleteSelected(i)}}})])})),e._v(" "),e.selectedLabels.length>5?n("el-button",{attrs:{label:"查看全部"+e.selectedLabels.length}},[n("i",{staticClass:"fa fa-sort-desc",attrs:{"aria-hidden":"true"}}),e._v(" "),n("el-popover",[n("div",{attrs:{separator:"",link:""}},e._l(e.selectedLabels,(function(t,i){return n("div",{key:i},[e._v("\n "+e._s(t)+"\n "),n("i",{staticClass:"fa fa-times",staticStyle:{float:"right","margin-left":"8px","font-size":"20px"},on:{click:function(t){return e.deleteSelected(i)}}})])})),0)])],1):e._e()],2)]),e._v(" "),n("div",{staticClass:"select-box"},[n("div",{staticClass:"select-box-left"},[n("div",{staticClass:"title"},[e._v("选择应用")]),e._v(" "),n("div",[n("el-input",{staticClass:"input-with-select",attrs:{placeholder:"请输入关键字搜索",clearale:!0},on:{change:e.debounceSearchApps},model:{value:e.appKeyword,callback:function(t){e.appKeyword=t},expression:"appKeyword"}})],1),e._v(" "),n("ul",{staticClass:"select-app"},e._l(e.apps,(function(t){return n("li",{key:t.value,staticClass:"select-app-item",class:t.value==e.selectedApp?"active":"",on:{click:function(n){return e.loadForms(t.value)}}},[e._v("\n "+e._s(t.label)+"\n ")])})),0)]),e._v(" "),e.selectedApp?n("div",{staticClass:"select-box-right"},[n("div",{staticClass:"title"},[e._v("表单选择")]),e._v(" "),n("div",[n("el-input",{staticClass:"input-with-select",attrs:{placeholder:"请输入关键字搜索",clearale:!0},on:{change:e.debounceSearch},model:{value:e.formKeyword,callback:function(t){e.formKeyword=t},expression:"formKeyword"}})],1),e._v(" "),n("ul",{staticClass:"select-form"},e._l(e.formList,(function(t){return n("li",{key:t.value,staticClass:"select-form-item"},[e.isMultiple?n("el-checkbox",{attrs:{label:t.value},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},[e._v(e._s(t.label))]):n("el-radio",{attrs:{label:t.value},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},[e._v(e._s(t.label))])],1)})),0)]):n("div",{staticClass:"select-box-right"},[e._v("\n 先选择表单\n ")])]),e._v(" "),n("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[n("el-button",{attrs:{type:"primary"},on:{click:e.onSubmit}},[e._v("确 定")])],1)])],1)};t._withStripped=!0;var n=i(3371),o=i.n(n),a=i(467),s=i.n(a),l=i(6981);o().use(l.Dialog);var c={props:["value","fieldConf","row","formName","orgInfo","isMultiple"],data(){return{curVal:[],apps:[],label:"",opened:!1,debounceSearchApps:s().debounce(s().bind(this.loadApps,this),150,{trailing:!0,leading:!1}),debounceSearch:s().debounce(s().bind(this.search,this),150,{trailing:!0,leading:!1}),selectedLabels:[],formList:[],appKeyword:"",selectedApp:"",formKeyword:""}},watch:{curVal(){this.loadSelectedLabels()},value(){this.loadRemoteLabel(),this.curVal=this.value?this.value:this.isMultiple?[]:""}},computed:{placeholder(){return this.fieldConf.desc||this.fieldConf.name},maxCount(){return s().get(this.fieldConf,"check.max_count")},titleStyle(){let e=this.fieldConf,t=s().get(e,"range_remote.range_display.title");return{fontSize:s().get(t,"size",16)+"px",color:s().get(t,"color","#333")}},fieldStyleMap(){let e=this.fieldConf,t=s().get(e,"range_remote.range_display.fields");return s().keyBy(t,"field")}},created(){this.curVal=this.isMultiple?[]:""},mounted(){this.curVal=this.value?this.value:this.isMultiple?[]:"",this.loadRemoteLabel()},methods:{async loadApps(){let e=this.appKeyword,t=this.formName,n=s().get(this.fieldConf,"id"),i=await zj.net.w.noapi({url:`/app_flow/v1/papi/dm/assist_field/select_form_id/${t}/${n}/search_left_title/?q=${e}`,params:this.orgInfo});this.apps=s().map(i.data,(e=>({value:e[0],label:e[1]})))},async search(){let e=this.formKeyword,t=this.formName,n=s().get(this.fieldConf,"id"),i=this.selectedApp,r=await zj.net.w.noapi({url:`/app_flow/v1/papi/dm/assist_field/select_form_id/${t}/${n}/search_right_title/?q=${e}&left=${i}`,params:this.orgInfo});this.formList=s().map(r.data,(e=>({value:e[0],label:e[1]})))},loadForms(e){this.selectedApp=e,this.debounceSearch()},async loadSelectedLabels(){let e=this.curVal,t=s().get(this.fieldConf,"id");if(!s().isEmpty(e)){let n=await zj.net.w.noapi({url:`/app_flow/v1/papi/dm/assist_field/${this.formName}/${t}/list_title/?values=${e}`,params:this.orgInfo});this.selectedLabels=s().cloneDeep(n)}},async loadRemoteLabel(){let e=this.value,t=s().get(this.fieldConf,"id");if(s().isEmpty(e))this.label="未选择";else{let n=await zj.net.w.noapi({url:`/app_flow/v1/papi/dm/assist_field/${this.formName}/${t}/list_title/?values=${e}`,params:this.orgInfo}),i=s().map(n.data);this.label=s().join(i,",")}},onHide(){this.opened=!1},onOpen(){this.loadApps()},isChecked(e){return s().includes(this.curVal,e)},onSubmit(){this.$emit("input",this.curVal),this.opened=!1},toOpen(){this.opened=!0},deleteSelected(e){let t=this.curVal;s().pullAt(t,e),this.curVal=s().cloneDeep(t)}}},u=i(1900),p=(0,u.Z)(c,t,[],!1,null,null,null);p.options.__file="components/lib/bpmSelectFromId/src/part/editor.vue";var d=p.exports,f={mixins:[i(5460).Z]},m=(0,u.Z)(f,void 0,void 0,!1,null,null,null);m.options.__file="components/lib/bpmSelectFromId/src/part/reader.vue";var h=m.exports,v={name:"bpmSelectFromId",components:{editorComponent:d,readerComponent:h},props:{value:{type:[String,Array]},fieldConf:{type:Object,default(){return{}}},row:{type:Object,default(){return{}}},mode:{type:String,default(){return"view"}},uiType:{type:String,default(){return"default"}},orgInfo:{type:Object},formName:{type:String},isMultiple:{type:Boolean,default(){return!1}}},data(){return{curVal:""}},computed:{curComponent(){return"view"==this.mode?h:d}},watch:{curVal(e){this.$emit("input",e),this.$emit("change",e)},value(){this.curVal=this.value}},mounted(){this.curVal=this.value}},b=i(3379),_=i.n(b),y=i(7795),g=i.n(y),x=i(569),C=i.n(x),w=i(3565),S=i.n(w),$=i(9216),V=i.n($),L=i(4589),k=i.n(L),E=i(7957),I={};I.styleTagTransform=k(),I.setAttributes=S(),I.insert=C().bind(null,"head"),I.domAPI=g(),I.insertStyleElement=V(),_()(E.Z,I),E.Z&&E.Z.locals&&E.Z.locals;var M=(0,u.Z)(v,e,[],!1,null,null,null);M.options.__file="components/lib/bpmSelectFromId/src/main.vue";var N=M.exports;N.install=function(e){e.component(N.name,N)};var j=N}(),r}()}));
1
+ !function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("lodash")):"function"==typeof define&&define.amd?define(["lodash"],t):"object"==typeof exports?exports.bpm2=t(require("lodash")):e.bpm2=t(e.lodash)}(self,(function(e){return function(){var t={7553:function(e,t,n){"use strict";var i=n(8081),r=n.n(i),o=n(3645),a=n.n(o)()(r());a.push([e.id,"\n .select-box{\n display: flex;\n .select-box-left{\n width: 200px;\n .title{\n margin-bottom: 10px;\n }\n }\n .select-box-right{\n flex: 1;\n padding-left: 20px;\n .title{\n margin-bottom: 10px;\n }\n }\n } \n .select-app,.select-app-item, .select-form, .select-form-item{\n list-style: none;\n margin: 0;\n padding: 0;\n margin-bottom: 10px;\n } \n .select-app, .select-form{\n padding: 10px;\n .select-app-item{\n cursor: pointer;\n }\n }\n\n .select-app-item.active{\n color: #409EFF;\n }\n",""]),t.Z=a},7957:function(e,t,n){"use strict";var i=n(8081),r=n.n(i),o=n(3645),a=n.n(o),s=n(7553),l=a()(r());l.i(s.Z),l.push([e.id,"\n",""]),t.Z=l},3645:function(e){"use strict";e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var n="",i=void 0!==t[5];return t[4]&&(n+="@supports (".concat(t[4],") {")),t[2]&&(n+="@media ".concat(t[2]," {")),i&&(n+="@layer".concat(t[5].length>0?" ".concat(t[5]):""," {")),n+=e(t),i&&(n+="}"),t[2]&&(n+="}"),t[4]&&(n+="}"),n})).join("")},t.i=function(e,n,i,r,o){"string"==typeof e&&(e=[[null,e,void 0]]);var a={};if(i)for(var s=0;s<this.length;s++){var l=this[s][0];null!=l&&(a[l]=!0)}for(var c=0;c<e.length;c++){var u=[].concat(e[c]);i&&a[u[0]]||(void 0!==o&&(void 0===u[5]||(u[1]="@layer".concat(u[5].length>0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=o),n&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=n):u[2]=n),r&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=r):u[4]="".concat(r)),t.push(u))}},t}},8081:function(e){"use strict";e.exports=function(e){return e[1]}},3379:function(e){"use strict";var t=[];function n(e){for(var n=-1,i=0;i<t.length;i++)if(t[i].identifier===e){n=i;break}return n}function i(e,i){for(var o={},a=[],s=0;s<e.length;s++){var l=e[s],c=i.base?l[0]+i.base:l[0],u=o[c]||0,p="".concat(c," ").concat(u);o[c]=u+1;var d=n(p),f={css:l[1],media:l[2],sourceMap:l[3],supports:l[4],layer:l[5]};if(-1!==d)t[d].references++,t[d].updater(f);else{var m=r(f,i);i.byIndex=s,t.splice(s,0,{identifier:p,updater:m,references:1})}a.push(p)}return a}function r(e,t){var n=t.domAPI(t);return n.update(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap&&t.supports===e.supports&&t.layer===e.layer)return;n.update(e=t)}else n.remove()}}e.exports=function(e,r){var o=i(e=e||[],r=r||{});return function(e){e=e||[];for(var a=0;a<o.length;a++){var s=n(o[a]);t[s].references--}for(var l=i(e,r),c=0;c<o.length;c++){var u=n(o[c]);0===t[u].references&&(t[u].updater(),t.splice(u,1))}o=l}}},569:function(e){"use strict";var t={};e.exports=function(e,n){var i=function(e){if(void 0===t[e]){var n=document.querySelector(e);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(e){n=null}t[e]=n}return t[e]}(e);if(!i)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");i.appendChild(n)}},9216:function(e){"use strict";e.exports=function(e){var t=document.createElement("style");return e.setAttributes(t,e.attributes),e.insert(t,e.options),t}},3565:function(e,t,n){"use strict";e.exports=function(e){var t=n.nc;t&&e.setAttribute("nonce",t)}},7795:function(e){"use strict";e.exports=function(e){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var t=e.insertStyleElement(e);return{update:function(n){!function(e,t,n){var i="";n.supports&&(i+="@supports (".concat(n.supports,") {")),n.media&&(i+="@media ".concat(n.media," {"));var r=void 0!==n.layer;r&&(i+="@layer".concat(n.layer.length>0?" ".concat(n.layer):""," {")),i+=n.css,r&&(i+="}"),n.media&&(i+="}"),n.supports&&(i+="}");var o=n.sourceMap;o&&"undefined"!=typeof btoa&&(i+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(o))))," */")),t.styleTagTransform(i,e,t.options)}(t,e,n)},remove:function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(t)}}}},4589:function(e){"use strict";e.exports=function(e,t){if(t.styleSheet)t.styleSheet.cssText=e;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(e))}}},5460:function(e,t,n){"use strict";n.d(t,{Z:function(){return l}});var i=function(){var e=this,t=e.$createElement;return(e._self._c||t)("span",{attrs:{title:e.label}},[e._v(e._s(e.label))])};i._withStripped=!0;var r=n(467),o=n.n(r),a={props:["value","fieldConf","row","formName","orgInfo"],data(){return{label:""}},watch:{value(){this.loadRemoteLabel()}},mounted(){this.loadRemoteLabel()},methods:{async loadRemoteLabel(){let e=this.value;if(o().isNil(e)||!e)return this.label=zj.z("未选择","c.not_selected");try{if(o().isObject(e))try{e=JSON.parse(e)}catch(e){console.log("error",e)}let t=o().isArray(e)?e:[e],n=o().get(this.fieldConf,"id");o().isEmpty(t)?this.label=zj.z("未选择","c.not_selected"):(t=o().isArray(t)?t:[t],this.label=await this.$bpm.fetchLabelByValues(t,n,this.formName,this.row))}finally{console.log("finally")}}}},s=(0,n(1900).Z)(a,i,[],!1,null,null,null);s.options.__file="components/lib/mixins/RemoteSelectReader.vue";var l=s.exports},1900:function(e,t,n){"use strict";function i(e,t,n,i,r,o,a,s){var l,c="function"==typeof e?e.options:e;if(t&&(c.render=t,c.staticRenderFns=n,c._compiled=!0),i&&(c.functional=!0),o&&(c._scopeId="data-v-"+o),a?(l=function(e){(e=e||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(e=__VUE_SSR_CONTEXT__),r&&r.call(this,e),e&&e._registeredComponents&&e._registeredComponents.add(a)},c._ssrRegister=l):r&&(l=s?function(){r.call(this,(c.functional?this.parent:this).$root.$options.shadowRoot)}:r),l)if(c.functional){c._injectStyles=l;var u=c.render;c.render=function(e,t){return l.call(t),u(e,t)}}else{var p=c.beforeCreate;c.beforeCreate=p?[].concat(p,l):[l]}return{exports:e,options:c}}n.d(t,{Z:function(){return i}})},6981:function(e){e.exports=function(){return this.ELEMENT}()},3371:function(e){e.exports=function(){return this.Vue}()},467:function(t){"use strict";t.exports=e}},n={};function i(e){var r=n[e];if(void 0!==r)return r.exports;var o=n[e]={id:e,exports:{}};return t[e](o,o.exports,i),o.exports}i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,{a:t}),t},i.d=function(e,t){for(var n in t)i.o(t,n)&&!i.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},i.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.nc=void 0;var r={};return function(){"use strict";i.r(r),i.d(r,{default:function(){return N}});var e=function(){var e=this,t=e.$createElement;return(e._self._c||t)(e.curComponent,e._g(e._b({tag:"component",staticClass:"bpm-select-from-id",attrs:{fieldConf:e.fieldConf,row:e.row,mode:e.mode,uiType:e.uiType,orgInfo:e.orgInfo,formName:e.formName,isMultiple:e.isMultiple},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},"component",e.$attrs,!1),e.$listeners))};e._withStripped=!0;var t=function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{staticClass:"select-from-id-editor"},[n("div",[n("div",{on:{click:e.toOpen}},[e._v(e._s(e.label))])]),e._v(" "),n("el-dialog",e._g(e._b({attrs:{visible:e.opened,"before-close":e.onHide,title:e.fieldConf.name,fullscreen:!0,"custom-class":"select-from-id-editor-dialog"},on:{"update:visible":function(t){e.opened=t},open:e.onOpen}},"el-dialog",e.$attrs,!1),e.$listeners),[n("div",{attrs:{slot:"title"},slot:"title"},[n("div",[e._v("\n 已选名单:\n "),e._l(e.selectedLabels,(function(t,i){return n("el-tag",{directives:[{name:"show",rawName:"v-show",value:i<=5,expression:"index <= 5"}],key:i,attrs:{type:"success"}},[e._v(e._s(t)+"\n "),n("i",{staticClass:"fa fa-times-circle",on:{click:function(t){return e.deleteSelected(i)}}})])})),e._v(" "),e.selectedLabels.length>5?n("el-button",{attrs:{label:"查看全部"+e.selectedLabels.length}},[n("i",{staticClass:"fa fa-sort-desc",attrs:{"aria-hidden":"true"}}),e._v(" "),n("el-popover",[n("div",{attrs:{separator:"",link:""}},e._l(e.selectedLabels,(function(t,i){return n("div",{key:i},[e._v("\n "+e._s(t)+"\n "),n("i",{staticClass:"fa fa-times",staticStyle:{float:"right","margin-left":"8px","font-size":"20px"},on:{click:function(t){return e.deleteSelected(i)}}})])})),0)])],1):e._e()],2)]),e._v(" "),n("div",{staticClass:"select-box"},[n("div",{staticClass:"select-box-left"},[n("div",{staticClass:"title"},[e._v("选择应用")]),e._v(" "),n("div",[n("el-input",{staticClass:"input-with-select",attrs:{placeholder:"请输入关键字搜索",clearale:!0},on:{change:e.debounceSearchApps},model:{value:e.appKeyword,callback:function(t){e.appKeyword=t},expression:"appKeyword"}})],1),e._v(" "),n("ul",{staticClass:"select-app"},e._l(e.apps,(function(t){return n("li",{key:t.value,staticClass:"select-app-item",class:t.value==e.selectedApp?"active":"",on:{click:function(n){return e.loadForms(t.value)}}},[e._v("\n "+e._s(t.label)+"\n ")])})),0)]),e._v(" "),e.selectedApp?n("div",{staticClass:"select-box-right"},[n("div",{staticClass:"title"},[e._v("表单选择")]),e._v(" "),n("div",[n("el-input",{staticClass:"input-with-select",attrs:{placeholder:"请输入关键字搜索",clearale:!0},on:{change:e.debounceSearch},model:{value:e.formKeyword,callback:function(t){e.formKeyword=t},expression:"formKeyword"}})],1),e._v(" "),n("ul",{staticClass:"select-form"},e._l(e.formList,(function(t){return n("li",{key:t.value,staticClass:"select-form-item"},[e.isMultiple?n("el-checkbox",{attrs:{label:t.value},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},[e._v(e._s(t.label))]):n("el-radio",{attrs:{label:t.value},model:{value:e.curVal,callback:function(t){e.curVal=t},expression:"curVal"}},[e._v(e._s(t.label))])],1)})),0)]):n("div",{staticClass:"select-box-right"},[e._v("\n 先选择表单\n ")])]),e._v(" "),n("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[n("el-button",{attrs:{type:"primary"},on:{click:e.onSubmit}},[e._v("确 定")])],1)])],1)};t._withStripped=!0;var n=i(3371),o=i.n(n),a=i(467),s=i.n(a),l=i(6981);o().use(l.Dialog);var c={props:["value","fieldConf","row","formName","orgInfo","isMultiple"],data(){return{curVal:[],apps:[],label:"",opened:!1,debounceSearchApps:s().debounce(s().bind(this.loadApps,this),150,{trailing:!0,leading:!1}),debounceSearch:s().debounce(s().bind(this.search,this),150,{trailing:!0,leading:!1}),selectedLabels:[],formList:[],appKeyword:"",selectedApp:"",formKeyword:""}},watch:{curVal(){this.loadSelectedLabels()},value(){this.loadRemoteLabel(),this.curVal=this.value?this.value:this.isMultiple?[]:""}},computed:{placeholder(){return this.fieldConf.desc||this.fieldConf.name},maxCount(){return s().get(this.fieldConf,"check.max_count")},titleStyle(){let e=this.fieldConf,t=s().get(e,"range_remote.range_display.title");return{fontSize:s().get(t,"size",16)+"px",color:s().get(t,"color","#333")}},fieldStyleMap(){let e=this.fieldConf,t=s().get(e,"range_remote.range_display.fields");return s().keyBy(t,"field")}},created(){this.curVal=this.isMultiple?[]:""},mounted(){this.curVal=this.value?this.value:this.isMultiple?[]:"",this.loadRemoteLabel()},methods:{async loadApps(){let e=this.appKeyword,t=this.formName,n=s().get(this.fieldConf,"id"),i=await zj.net.w.noapi({url:`/app_flow/v1/papi/dm/assist_field/select_form_id/${t}/${n}/search_left_title/?q=${e}`,params:this.orgInfo});this.apps=s().map(i.data,(e=>({value:e[0],label:e[1]})))},async search(){let e=this.formKeyword,t=this.formName,n=s().get(this.fieldConf,"id"),i=this.selectedApp,r=await zj.net.w.noapi({url:`/app_flow/v1/papi/dm/assist_field/select_form_id/${t}/${n}/search_right_title/?q=${e}&left=${i}`,params:this.orgInfo});this.formList=s().map(r.data,(e=>({value:e[0],label:e[1]})))},loadForms(e){this.selectedApp=e,this.debounceSearch()},async loadSelectedLabels(){let e=this.curVal,t=s().get(this.fieldConf,"id");if(!s().isEmpty(e)){let n=await zj.net.w.noapi({url:`/app_flow/v1/papi/dm/assist_field/${this.formName}/${t}/list_title/?values=${e}`,params:this.orgInfo});this.selectedLabels=s().cloneDeep(n)}},async loadRemoteLabel(){let e=this.value,t=s().get(this.fieldConf,"id");if(s().isEmpty(e))this.label="未选择";else{let n=await zj.net.w.noapi({url:`/app_flow/v1/papi/dm/assist_field/${this.formName}/${t}/list_title/?values=${e}`,params:this.orgInfo}),i=s().map(n.data);this.label=s().join(i,",")}},onHide(){this.opened=!1},onOpen(){this.loadApps()},isChecked(e){return s().includes(this.curVal,e)},onSubmit(){this.$emit("input",this.curVal),this.opened=!1},toOpen(){this.opened=!0},deleteSelected(e){let t=this.curVal;s().pullAt(t,e),this.curVal=s().cloneDeep(t)}}},u=i(1900),p=(0,u.Z)(c,t,[],!1,null,null,null);p.options.__file="components/lib/bpmSelectFromId/src/part/editor.vue";var d=p.exports,f={mixins:[i(5460).Z]},m=(0,u.Z)(f,void 0,void 0,!1,null,null,null);m.options.__file="components/lib/bpmSelectFromId/src/part/reader.vue";var h=m.exports,v={name:"bpmSelectFromId",components:{editorComponent:d,readerComponent:h},props:{value:{type:[String,Array]},fieldConf:{type:Object,default(){return{}}},row:{type:Object,default(){return{}}},mode:{type:String,default(){return"view"}},uiType:{type:String,default(){return"default"}},orgInfo:{type:Object},formName:{type:String},isMultiple:{type:Boolean,default(){return!1}}},data(){return{curVal:""}},computed:{curComponent(){return"view"==this.mode?h:d}},watch:{curVal(e){this.$emit("input",e),this.$emit("change",e)},value(){this.curVal=this.value}},mounted(){this.curVal=this.value}},b=i(3379),_=i.n(b),y=i(7795),g=i.n(y),x=i(569),C=i.n(x),w=i(3565),S=i.n(w),$=i(9216),V=i.n($),L=i(4589),j=i.n(L),k=i(7957),E={};E.styleTagTransform=j(),E.setAttributes=S(),E.insert=C().bind(null,"head"),E.domAPI=g(),E.insertStyleElement=V(),_()(k.Z,E),k.Z&&k.Z.locals&&k.Z.locals;var I=(0,u.Z)(v,e,[],!1,null,null,null);I.options.__file="components/lib/bpmSelectFromId/src/main.vue";var M=I.exports;M.install=function(e){e.component(M.name,M)};var N=M}(),r}()}));
@@ -0,0 +1,2 @@
1
+ /*! For license information please see bpmSelectSection.umd.js.LICENSE.txt */
2
+ !function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.bpm2=e():t.bpm2=e()}(self,(function(){return function(){var t={8459:function(t,e,o){"use strict";var n=o(8081),i=o.n(n),r=o(3645),l=o.n(r)()(i());l.push([t.id,".select-position-table{height:100%;overflow:auto}.select-position-table table,.select-position-table td,.select-position-table th{border:0 solid #E2E2E2;border-collapse:collapse;text-align:center;padding:0}.select-position-table .select-position-table-content{display:flex}.select-position-table .select-position-table-content .select-position-table-content-left .floor{display:flex;align-items:center;height:85px;border:2px solid #E2E2E2;text-align:center;justify-content:center;width:100px!important}.select-position-table .select-position-table-content .select-position-table-content-right{width:100%;overflow:auto}.position-table-cell .flag{position:absolute;right:0;top:0;width:0;height:0;border-style:solid;border-top:8px solid #246AE3;border-right:8px solid #246AE3;border-left:8px solid transparent;border-bottom:8px solid transparent}.position-table-cell .flag .icon{position:absolute;right:-10px;top:-10px;font-size:12px;color:#FFF;font-weight:900}.position-table-cell .is_selected .parent{position:relative;border-top:2px solid #246AE3!important;border-left:2px solid #246AE3!important;border-right:2px solid #246AE3!important}.position-table-cell .is_selected .cell-childs{position:relative}.position-table-cell .is_selected .cell-childs .cell-child{position:relative;border-bottom:2px solid #246AE3!important}.position-table-cell .is_selected .cell-childs .cell-child:first-child{border-left:2px solid #246AE3!important}.position-table-cell .is_selected .cell-childs .cell-child:last-child{border-right:2px solid #246AE3!important}.position-table-cell .is_child_selected{border:2px solid #246AE3!important}.position-table-cell .cell-parent{box-sizing:content-box}.position-table-cell .cell-parent .parent{padding:10px;border:2px solid #E2E2E2}.position-table-cell .cell-parent .cell-childs{box-sizing:content-box;display:flex;border:none}.position-table-cell .cell-parent .cell-childs .cell-child{position:relative;border:2px solid #E2E2E2;white-space:nowrap;word-break:none;padding:10px;flex:1;border-right:2px solid #E2E2E2}",""]),e.Z=l},3645:function(t){"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var o="",n=void 0!==e[5];return e[4]&&(o+="@supports (".concat(e[4],") {")),e[2]&&(o+="@media ".concat(e[2]," {")),n&&(o+="@layer".concat(e[5].length>0?" ".concat(e[5]):""," {")),o+=t(e),n&&(o+="}"),e[2]&&(o+="}"),e[4]&&(o+="}"),o})).join("")},e.i=function(t,o,n,i,r){"string"==typeof t&&(t=[[null,t,void 0]]);var l={};if(n)for(var a=0;a<this.length;a++){var s=this[a][0];null!=s&&(l[s]=!0)}for(var c=0;c<t.length;c++){var u=[].concat(t[c]);n&&l[u[0]]||(void 0!==r&&(void 0===u[5]||(u[1]="@layer".concat(u[5].length>0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=r),o&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=o):u[2]=o),i&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=i):u[4]="".concat(i)),e.push(u))}},e}},8081:function(t){"use strict";t.exports=function(t){return t[1]}},3379:function(t){"use strict";var e=[];function o(t){for(var o=-1,n=0;n<e.length;n++)if(e[n].identifier===t){o=n;break}return o}function n(t,n){for(var r={},l=[],a=0;a<t.length;a++){var s=t[a],c=n.base?s[0]+n.base:s[0],u=r[c]||0,d="".concat(c," ").concat(u);r[c]=u+1;var h=o(d),f={css:s[1],media:s[2],sourceMap:s[3],supports:s[4],layer:s[5]};if(-1!==h)e[h].references++,e[h].updater(f);else{var p=i(f,n);n.byIndex=a,e.splice(a,0,{identifier:d,updater:p,references:1})}l.push(d)}return l}function i(t,e){var o=e.domAPI(e);return o.update(t),function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap&&e.supports===t.supports&&e.layer===t.layer)return;o.update(t=e)}else o.remove()}}t.exports=function(t,i){var r=n(t=t||[],i=i||{});return function(t){t=t||[];for(var l=0;l<r.length;l++){var a=o(r[l]);e[a].references--}for(var s=n(t,i),c=0;c<r.length;c++){var u=o(r[c]);0===e[u].references&&(e[u].updater(),e.splice(u,1))}r=s}}},569:function(t){"use strict";var e={};t.exports=function(t,o){var n=function(t){if(void 0===e[t]){var o=document.querySelector(t);if(window.HTMLIFrameElement&&o instanceof window.HTMLIFrameElement)try{o=o.contentDocument.head}catch(t){o=null}e[t]=o}return e[t]}(t);if(!n)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");n.appendChild(o)}},9216:function(t){"use strict";t.exports=function(t){var e=document.createElement("style");return t.setAttributes(e,t.attributes),t.insert(e,t.options),e}},3565:function(t,e,o){"use strict";t.exports=function(t){var e=o.nc;e&&t.setAttribute("nonce",e)}},7795:function(t){"use strict";t.exports=function(t){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var e=t.insertStyleElement(t);return{update:function(o){!function(t,e,o){var n="";o.supports&&(n+="@supports (".concat(o.supports,") {")),o.media&&(n+="@media ".concat(o.media," {"));var i=void 0!==o.layer;i&&(n+="@layer".concat(o.layer.length>0?" ".concat(o.layer):""," {")),n+=o.css,i&&(n+="}"),o.media&&(n+="}"),o.supports&&(n+="}");var r=o.sourceMap;r&&"undefined"!=typeof btoa&&(n+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(r))))," */")),e.styleTagTransform(n,t,e.options)}(e,t,o)},remove:function(){!function(t){if(null===t.parentNode)return!1;t.parentNode.removeChild(t)}(e)}}}},4589:function(t){"use strict";t.exports=function(t,e){if(e.styleSheet)e.styleSheet.cssText=t;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(t))}}},1900:function(t,e,o){"use strict";function n(t,e,o,n,i,r,l,a){var s,c="function"==typeof t?t.options:t;if(e&&(c.render=e,c.staticRenderFns=o,c._compiled=!0),n&&(c.functional=!0),r&&(c._scopeId="data-v-"+r),l?(s=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),i&&i.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(l)},c._ssrRegister=s):i&&(s=a?function(){i.call(this,(c.functional?this.parent:this).$root.$options.shadowRoot)}:i),s)if(c.functional){c._injectStyles=s;var u=c.render;c.render=function(t,e){return s.call(e),u(t,e)}}else{var d=c.beforeCreate;c.beforeCreate=d?[].concat(d,s):[s]}return{exports:t,options:c}}o.d(e,{Z:function(){return n}})},6407:function(t){self,t.exports=function(){"use strict";var t={924:function(t,e,o){o.d(e,{default:function(){return l}});var n=function(){var t=this;return t.$createElement,t._self._c,t._m(0)};n._withStripped=!0;var i=(0,o(900).Z)({name:"Demo"},n,[function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("div",[o("h1",{staticClass:"m-demo"},[t._v("demo1")])])}],!1,null,null,null);i.options.__file="components/lib/demo/src/main.vue";var r=i.exports;r.install=function(t){t.component(r.name,r)};var l=r},367:function(t,e,o){o.d(e,{default:function(){return l}});var n=function(){var t=this;return t.$createElement,t._self._c,t._m(0)};n._withStripped=!0;var i=(0,o(900).Z)({name:"Demo2"},n,[function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("div",[o("h1",{staticClass:"m-demo"},[t._v("demo2")])])}],!1,null,null,null);i.options.__file="components/lib/demo2/src/main.vue";var r=i.exports;r.install=function(t){t.component(r.name,r)};var l=r},622:function(t,e,o){o.d(e,{default:function(){return d}});var n=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("div",{staticClass:"select-position-table"},[o("div",{staticClass:"select-position-table-content"},[o("div",{staticClass:"select-position-table-content-left"},t._l(t.list,(function(e){return o("div",{key:e.title},[o("div",{staticClass:"floor"},[t._v(t._s(e.title))])])})),0),t._v(" "),o("div",{staticClass:"select-position-table-content-right"},[o("table",[o("tbody",t._l(t.list,(function(e){return o("tr",{key:e.title},t._l(e.childrens,(function(n,i){return o("td",{key:n.title},[o("cell-item",{model:{value:e.childrens[i],callback:function(o){t.$set(e.childrens,i,o)},expression:"item.childrens[index]"}})],1)})),0)})),0)])])])])};n._withStripped=!0;var i=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("div",{staticClass:"position-table-cell"},[o("div",{staticClass:"cell-parent",class:{is_selected:t.curVal.state},style:{background:t.curVal.color}},[o("div",{staticClass:"parent",on:{click:function(e){return t.troggleParent()}}},[t._v(t._s(t.curVal.title)+"\n "),o("div",{directives:[{name:"show",rawName:"v-show",value:t.curVal.state,expression:"curVal.state"}],staticClass:"flag"},[o("i",{staticClass:"icon el-icon-check"})])]),t._v(" "),o("div",{staticClass:"cell-childs"},t._l(t.curVal.childrens,(function(e){return o("div",{key:e.key,staticClass:"cell-child",class:{is_child_selected:e.state&&!t.curVal.state},style:{background:e.color},on:{click:function(o){return t.troggleChild(e)}}},[t._v(t._s(e.title)+"\n\n "),o("div",{directives:[{name:"show",rawName:"v-show",value:e.state&&!t.curVal.state,expression:"child_item.state && !curVal.state"}],staticClass:"flag"},[o("i",{staticClass:"icon el-icon-check"})])])})),0)])])};i._withStripped=!0;var r={props:{value:{type:Object,default:function(){return{}}}},data(){return{curVal:{}}},watch:{value(t){this.curVal=t}},methods:{troggleParent(){this.curVal.state=!this.curVal.state,_.each(this.curVal.childrens,(t=>{t.state=this.curVal.state})),this.setVal()},troggleChild(t){t.state=!t.state;let e=!0;_.each(this.curVal.childrens,(t=>{t.state||(e=!1)})),this.curVal.state=e,this.setVal()},setVal(){this.$emit("input",this.curVal)}},mounted(){this.curVal=this.value,console.log("this.curVal",this.curVal)}},l=o(900),a=(0,l.Z)(r,i,[],!1,null,null,null);a.options.__file="components/lib/select-position-table/src/widgets/cell-item.vue";var s={name:"ZjSelectPositionTable",components:{CellItem:a.exports},props:{value:{type:Array,default:function(){return[]}},data:{type:Array,default:()=>[]}},watch:{value:{handler(){this.setSelectedItem()},deep:!0},data:{handler(t){this.list=_.cloneDeep(t),this.setSelectedItem()},deep:!0,immediate:!0},list:{handler(t){this.getSelectedItem(t)},deep:!0}},data(){return{list:[]}},methods:{setSelectedItem(){console.log("haha"),_.each(this.list,(t=>{_.each(t.childrens,(t=>{if(t.childrens){let e=0;_.each(t.childrens,(t=>{_.find(this.value,{key:t.key})?(t.state=!0,e++):t.state=!1})),e==t.childrens.length?t.state=!0:t.state=!1}else _.find(this.value,{key:t.key})&&(t.state=!0)}))}))},getSelectedItem(t){let e=[];_.each(t,(t=>{_.each(t.childrens,(o=>{o.childrens?_.each(o.childrens,(n=>{n.state&&e.push({name:t.title+"-"+o.title+"-"+n.title,key:n.key})})):o.state&&e.push({name:t.title+"-"+o.title,key:o.key})}))})),console.log("val",t),this.$emit("input",e)}},mounted(){}},c=(0,l.Z)(s,n,[],!1,null,null,null);c.options.__file="components/lib/select-position-table/src/main.vue";var u=c.exports;u.install=function(t){t.component(u.name,u)};var d=u},387:function(t,e,o){o.d(e,{default:function(){return de}});var n=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("div",[o("el-popover",{ref:"col_config",attrs:{"popper-class":"table-cloumn-configer",placement:"bottom",width:"200",trigger:"click"}},[o("div",{staticClass:"content"},[o("div",[t.showConfirm?o("div",{staticClass:"btn-grp"},[o("el-button",{attrs:{round:"",size:"mini",disabled:!t.editing},on:{click:t.reset}},[t._v(t._s(t.$z("重置","c.reset"))+"\n ")]),t._v(" "),o("el-button",{attrs:{type:"primary",round:"",size:"mini",disabled:!t.editing},on:{click:t.submit}},[t._v(t._s(t.$z("确定","c.confirm"))+"\n ")])],1):t._e(),t._v(" "),o("div",{staticClass:"tip"},[t._v("\n "+t._s(t.$z("提示:拖拽可排序","b2.common.tip_can_drap_sort")))])]),t._v(" "),o("ul",{staticClass:"col-config-list"},t._l(t.cols_config,(function(e,n){return o("li",{key:""+n,staticStyle:{cursor:"grab"}},[o("el-checkbox",{on:{change:function(e){return t.checkboxClick()}},model:{value:e.show,callback:function(o){t.$set(e,"show",o)},expression:"col.show"}}),t._v(" "),o("div",{staticClass:"item-name",attrs:{title:e.label}},[t._v("\n "+t._s(e.label)+"\n ")])],1)})),0)]),t._v(" "),t._t("default",(function(){return[o("i",{staticClass:"el-icon-s-tools",staticStyle:{"font-size":"20px",color:"#666",cursor:"pointer"},attrs:{title:"设置字段"}})]}),{slot:"reference"})],2)],1)};function i(t,e){var o=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),o.push.apply(o,n)}return o}function r(t){for(var e=1;e<arguments.length;e++){var o=null!=arguments[e]?arguments[e]:{};e%2?i(Object(o),!0).forEach((function(e){a(t,e,o[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):i(Object(o)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(o,e))}))}return t}function l(t){return l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},l(t)}function a(t,e,o){return e in t?Object.defineProperty(t,e,{value:o,enumerable:!0,configurable:!0,writable:!0}):t[e]=o,t}function s(){return s=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var o=arguments[e];for(var n in o)Object.prototype.hasOwnProperty.call(o,n)&&(t[n]=o[n])}return t},s.apply(this,arguments)}function c(t){if("undefined"!=typeof window&&window.navigator)return!!navigator.userAgent.match(t)}n._withStripped=!0;var u=c(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),d=c(/Edge/i),h=c(/firefox/i),f=c(/safari/i)&&!c(/chrome/i)&&!c(/android/i),p=c(/iP(ad|od|hone)/i),g=c(/chrome/i)&&c(/android/i),m={capture:!1,passive:!1};function v(t,e,o){t.addEventListener(e,o,!u&&m)}function b(t,e,o){t.removeEventListener(e,o,!u&&m)}function y(t,e){if(e){if(">"===e[0]&&(e=e.substring(1)),t)try{if(t.matches)return t.matches(e);if(t.msMatchesSelector)return t.msMatchesSelector(e);if(t.webkitMatchesSelector)return t.webkitMatchesSelector(e)}catch(t){return!1}return!1}}function F(t){return t.host&&t!==document&&t.host.nodeType?t.host:t.parentNode}function C(t,e,o,n){if(t){o=o||document;do{if(null!=e&&(">"===e[0]?t.parentNode===o&&y(t,e):y(t,e))||n&&t===o)return t;if(t===o)break}while(t=F(t))}return null}var w,S=/\s+/g;function E(t,e,o){if(t&&e)if(t.classList)t.classList[o?"add":"remove"](e);else{var n=(" "+t.className+" ").replace(S," ").replace(" "+e+" "," ");t.className=(n+(o?" "+e:"")).replace(S," ")}}function D(t,e,o){var n=t&&t.style;if(n){if(void 0===o)return document.defaultView&&document.defaultView.getComputedStyle?o=document.defaultView.getComputedStyle(t,""):t.currentStyle&&(o=t.currentStyle),void 0===e?o:o[e];e in n||-1!==e.indexOf("webkit")||(e="-webkit-"+e),n[e]=o+("string"==typeof o?"":"px")}}function k(t,e){var o="";if("string"==typeof t)o=t;else do{var n=D(t,"transform");n&&"none"!==n&&(o=n+" "+o)}while(!e&&(t=t.parentNode));var i=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return i&&new i(o)}function x(t,e,o){if(t){var n=t.getElementsByTagName(e),i=0,r=n.length;if(o)for(;i<r;i++)o(n[i],i);return n}return[]}function T(){return document.scrollingElement||document.documentElement}function O(t,e,o,n,i){if(t.getBoundingClientRect||t===window){var r,l,a,s,c,d,h;if(t!==window&&t.parentNode&&t!==T()?(l=(r=t.getBoundingClientRect()).top,a=r.left,s=r.bottom,c=r.right,d=r.height,h=r.width):(l=0,a=0,s=window.innerHeight,c=window.innerWidth,d=window.innerHeight,h=window.innerWidth),(e||o)&&t!==window&&(i=i||t.parentNode,!u))do{if(i&&i.getBoundingClientRect&&("none"!==D(i,"transform")||o&&"static"!==D(i,"position"))){var f=i.getBoundingClientRect();l-=f.top+parseInt(D(i,"border-top-width")),a-=f.left+parseInt(D(i,"border-left-width")),s=l+r.height,c=a+r.width;break}}while(i=i.parentNode);if(n&&t!==window){var p=k(i||t),g=p&&p.a,m=p&&p.d;p&&(s=(l/=m)+(d/=m),c=(a/=g)+(h/=g))}return{top:l,left:a,bottom:s,right:c,width:h,height:d}}}function I(t){var e=O(t),o=parseInt(D(t,"padding-left")),n=parseInt(D(t,"padding-top")),i=parseInt(D(t,"padding-right")),r=parseInt(D(t,"padding-bottom"));return e.top+=n+parseInt(D(t,"border-top-width")),e.left+=o+parseInt(D(t,"border-left-width")),e.width=t.clientWidth-o-i,e.height=t.clientHeight-n-r,e.bottom=e.top+e.height,e.right=e.left+e.width,e}function N(t,e,o){for(var n=B(t,!0),i=O(t)[e];n;){var r=O(n)[o];if(!("top"===o||"left"===o?i>=r:i<=r))return n;if(n===T())break;n=B(n,!1)}return!1}function A(t,e,o,n){for(var i=0,r=0,l=t.children;r<l.length;){if("none"!==l[r].style.display&&l[r]!==jt.ghost&&(n||l[r]!==jt.dragged)&&C(l[r],o.draggable,t,!1)){if(i===e)return l[r];i++}r++}return null}function M(t,e){for(var o=t.lastElementChild;o&&(o===jt.ghost||"none"===D(o,"display")||e&&!y(o,e));)o=o.previousElementSibling;return o||null}function P(t,e){var o=0;if(!t||!t.parentNode)return-1;for(;t=t.previousElementSibling;)"TEMPLATE"===t.nodeName.toUpperCase()||t===jt.clone||e&&!y(t,e)||o++;return o}function W(t){var e=0,o=0,n=T();if(t)do{var i=k(t),r=i.a,l=i.d;e+=t.scrollLeft*r,o+=t.scrollTop*l}while(t!==n&&(t=t.parentNode));return[e,o]}function B(t,e){if(!t||!t.getBoundingClientRect)return T();var o=t,n=!1;do{if(o.clientWidth<o.scrollWidth||o.clientHeight<o.scrollHeight){var i=D(o);if(o.clientWidth<o.scrollWidth&&("auto"==i.overflowX||"scroll"==i.overflowX)||o.clientHeight<o.scrollHeight&&("auto"==i.overflowY||"scroll"==i.overflowY)){if(!o.getBoundingClientRect||o===document.body)return T();if(n||e)return o;n=!0}}}while(o=o.parentNode);return T()}function R(t,e){return Math.round(t.top)===Math.round(e.top)&&Math.round(t.left)===Math.round(e.left)&&Math.round(t.height)===Math.round(e.height)&&Math.round(t.width)===Math.round(e.width)}function j(t,e){return function(){if(!w){var o=arguments;1===o.length?t.call(this,o[0]):t.apply(this,o),w=setTimeout((function(){w=void 0}),e)}}}function V(t,e,o){t.scrollLeft+=e,t.scrollTop+=o}function X(t){var e=window.Polymer,o=window.jQuery||window.Zepto;return e&&e.dom?e.dom(t).cloneNode(!0):o?o(t).clone(!0)[0]:t.cloneNode(!0)}var $="Sortable"+(new Date).getTime(),Y=[],L={initializeByDefault:!0},z={mount:function(t){for(var e in L)L.hasOwnProperty(e)&&!(e in t)&&(t[e]=L[e]);Y.forEach((function(e){if(e.pluginName===t.pluginName)throw"Sortable: Cannot mount plugin ".concat(t.pluginName," more than once")})),Y.push(t)},pluginEvent:function(t,e,o){var n=this;this.eventCanceled=!1,o.cancel=function(){n.eventCanceled=!0};var i=t+"Global";Y.forEach((function(n){e[n.pluginName]&&(e[n.pluginName][i]&&e[n.pluginName][i](r({sortable:e},o)),e.options[n.pluginName]&&e[n.pluginName][t]&&e[n.pluginName][t](r({sortable:e},o)))}))},initializePlugins:function(t,e,o,n){for(var i in Y.forEach((function(n){var i=n.pluginName;if(t.options[i]||n.initializeByDefault){var r=new n(t,e,t.options);r.sortable=t,r.options=t.options,t[i]=r,s(o,r.defaults)}})),t.options)if(t.options.hasOwnProperty(i)){var r=this.modifyOption(t,i,t.options[i]);void 0!==r&&(t.options[i]=r)}},getEventProperties:function(t,e){var o={};return Y.forEach((function(n){"function"==typeof n.eventProperties&&s(o,n.eventProperties.call(e[n.pluginName],t))})),o},modifyOption:function(t,e,o){var n;return Y.forEach((function(i){t[i.pluginName]&&i.optionListeners&&"function"==typeof i.optionListeners[e]&&(n=i.optionListeners[e].call(t[i.pluginName],o))})),n}},H=["evt"],U=function(t,e){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=o.evt,i=function(t,e){if(null==t)return{};var o,n,i=function(t,e){if(null==t)return{};var o,n,i={},r=Object.keys(t);for(n=0;n<r.length;n++)o=r[n],e.indexOf(o)>=0||(i[o]=t[o]);return i}(t,e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);for(n=0;n<r.length;n++)o=r[n],e.indexOf(o)>=0||Object.prototype.propertyIsEnumerable.call(t,o)&&(i[o]=t[o])}return i}(o,H);z.pluginEvent.bind(jt)(t,e,r({dragEl:G,parentEl:K,ghostEl:q,rootEl:J,nextEl:Q,lastDownEl:tt,cloneEl:et,cloneHidden:ot,dragStarted:gt,putSortable:st,activeSortable:jt.active,originalEvent:n,oldIndex:nt,oldDraggableIndex:rt,newIndex:it,newDraggableIndex:lt,hideGhostForTarget:Pt,unhideGhostForTarget:Wt,cloneNowHidden:function(){ot=!0},cloneNowShown:function(){ot=!1},dispatchSortableEvent:function(t){Z({sortable:e,name:t,originalEvent:n})}},i))};function Z(t){!function(t){var e=t.sortable,o=t.rootEl,n=t.name,i=t.targetEl,l=t.cloneEl,a=t.toEl,s=t.fromEl,c=t.oldIndex,h=t.newIndex,f=t.oldDraggableIndex,p=t.newDraggableIndex,g=t.originalEvent,m=t.putSortable,v=t.extraEventProperties;if(e=e||o&&o[$]){var _,b=e.options,y="on"+n.charAt(0).toUpperCase()+n.substr(1);!window.CustomEvent||u||d?(_=document.createEvent("Event")).initEvent(n,!0,!0):_=new CustomEvent(n,{bubbles:!0,cancelable:!0}),_.to=a||o,_.from=s||o,_.item=i||o,_.clone=l,_.oldIndex=c,_.newIndex=h,_.oldDraggableIndex=f,_.newDraggableIndex=p,_.originalEvent=g,_.pullMode=m?m.lastPutMode:void 0;var F=r(r({},v),z.getEventProperties(n,e));for(var C in F)_[C]=F[C];o&&o.dispatchEvent(_),b[y]&&b[y].call(e,_)}}(r({putSortable:st,cloneEl:et,targetEl:G,rootEl:J,oldIndex:nt,oldDraggableIndex:rt,newIndex:it,newDraggableIndex:lt},t))}var G,K,q,J,Q,tt,et,ot,nt,it,rt,lt,at,st,ct,ut,dt,ht,ft,pt,gt,mt,vt,_t,bt,yt=!1,Ft=!1,Ct=[],wt=!1,St=!1,Et=[],Dt=!1,kt=[],xt="undefined"!=typeof document,Tt=p,Ot=d||u?"cssFloat":"float",It=xt&&!g&&!p&&"draggable"in document.createElement("div"),Nt=function(){if(xt){if(u)return!1;var t=document.createElement("x");return t.style.cssText="pointer-events:auto","auto"===t.style.pointerEvents}}(),At=function(t,e){var o=D(t),n=parseInt(o.width)-parseInt(o.paddingLeft)-parseInt(o.paddingRight)-parseInt(o.borderLeftWidth)-parseInt(o.borderRightWidth),i=A(t,0,e),r=A(t,1,e),l=i&&D(i),a=r&&D(r),s=l&&parseInt(l.marginLeft)+parseInt(l.marginRight)+O(i).width,c=a&&parseInt(a.marginLeft)+parseInt(a.marginRight)+O(r).width;if("flex"===o.display)return"column"===o.flexDirection||"column-reverse"===o.flexDirection?"vertical":"horizontal";if("grid"===o.display)return o.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal";if(i&&l.float&&"none"!==l.float){var u="left"===l.float?"left":"right";return!r||"both"!==a.clear&&a.clear!==u?"horizontal":"vertical"}return i&&("block"===l.display||"flex"===l.display||"table"===l.display||"grid"===l.display||s>=n&&"none"===o[Ot]||r&&"none"===o[Ot]&&s+c>n)?"vertical":"horizontal"},Mt=function(t){function e(t,o){return function(n,i,r,l){var a=n.options.group.name&&i.options.group.name&&n.options.group.name===i.options.group.name;if(null==t&&(o||a))return!0;if(null==t||!1===t)return!1;if(o&&"clone"===t)return t;if("function"==typeof t)return e(t(n,i,r,l),o)(n,i,r,l);var s=(o?n:i).options.group.name;return!0===t||"string"==typeof t&&t===s||t.join&&t.indexOf(s)>-1}}var o={},n=t.group;n&&"object"==l(n)||(n={name:n}),o.name=n.name,o.checkPull=e(n.pull,!0),o.checkPut=e(n.put),o.revertClone=n.revertClone,t.group=o},Pt=function(){!Nt&&q&&D(q,"display","none")},Wt=function(){!Nt&&q&&D(q,"display","")};xt&&!g&&document.addEventListener("click",(function(t){if(Ft)return t.preventDefault(),t.stopPropagation&&t.stopPropagation(),t.stopImmediatePropagation&&t.stopImmediatePropagation(),Ft=!1,!1}),!0);var Bt=function(t){if(G){t=t.touches?t.touches[0]:t;var e=(i=t.clientX,r=t.clientY,Ct.some((function(t){var e=t[$].options.emptyInsertThreshold;if(e&&!M(t)){var o=O(t),n=i>=o.left-e&&i<=o.right+e,a=r>=o.top-e&&r<=o.bottom+e;return n&&a?l=t:void 0}})),l);if(e){var o={};for(var n in t)t.hasOwnProperty(n)&&(o[n]=t[n]);o.target=o.rootEl=e,o.preventDefault=void 0,o.stopPropagation=void 0,e[$]._onDragOver(o)}}var i,r,l},Rt=function(t){G&&G.parentNode[$]._isOutsideThisEl(t.target)};function jt(t,e){if(!t||!t.nodeType||1!==t.nodeType)throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(t));this.el=t,this.options=e=s({},e),t[$]=this;var o,n,i={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(t.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return At(t,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(t,e){t.setData("Text",e.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,delayOnTouchOnly:!1,touchStartThreshold:(Number.parseInt?Number:window).parseInt(window.devicePixelRatio,10)||1,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:!1!==jt.supportPointer&&"PointerEvent"in window&&!f,emptyInsertThreshold:5};for(var l in z.initializePlugins(this,t,i),i)!(l in e)&&(e[l]=i[l]);for(var a in Mt(e),this)"_"===a.charAt(0)&&"function"==typeof this[a]&&(this[a]=this[a].bind(this));this.nativeDraggable=!e.forceFallback&&It,this.nativeDraggable&&(this.options.touchStartThreshold=1),e.supportPointer?v(t,"pointerdown",this._onTapStart):(v(t,"mousedown",this._onTapStart),v(t,"touchstart",this._onTapStart)),this.nativeDraggable&&(v(t,"dragover",this),v(t,"dragenter",this)),Ct.push(this.el),e.store&&e.store.get&&this.sort(e.store.get(this)||[]),s(this,(n=[],{captureAnimationState:function(){n=[],this.options.animation&&[].slice.call(this.el.children).forEach((function(t){if("none"!==D(t,"display")&&t!==jt.ghost){n.push({target:t,rect:O(t)});var e=r({},n[n.length-1].rect);if(t.thisAnimationDuration){var o=k(t,!0);o&&(e.top-=o.f,e.left-=o.e)}t.fromRect=e}}))},addAnimationState:function(t){n.push(t)},removeAnimationState:function(t){n.splice(function(t,e){for(var o in t)if(t.hasOwnProperty(o))for(var n in e)if(e.hasOwnProperty(n)&&e[n]===t[o][n])return Number(o);return-1}(n,{target:t}),1)},animateAll:function(t){var e=this;if(!this.options.animation)return clearTimeout(o),void("function"==typeof t&&t());var i=!1,r=0;n.forEach((function(t){var o=0,n=t.target,l=n.fromRect,a=O(n),s=n.prevFromRect,c=n.prevToRect,u=t.rect,d=k(n,!0);d&&(a.top-=d.f,a.left-=d.e),n.toRect=a,n.thisAnimationDuration&&R(s,a)&&!R(l,a)&&(u.top-a.top)/(u.left-a.left)==(l.top-a.top)/(l.left-a.left)&&(o=function(t,e,o,n){return Math.sqrt(Math.pow(e.top-t.top,2)+Math.pow(e.left-t.left,2))/Math.sqrt(Math.pow(e.top-o.top,2)+Math.pow(e.left-o.left,2))*n.animation}(u,s,c,e.options)),R(a,l)||(n.prevFromRect=l,n.prevToRect=a,o||(o=e.options.animation),e.animate(n,u,a,o)),o&&(i=!0,r=Math.max(r,o),clearTimeout(n.animationResetTimer),n.animationResetTimer=setTimeout((function(){n.animationTime=0,n.prevFromRect=null,n.fromRect=null,n.prevToRect=null,n.thisAnimationDuration=null}),o),n.thisAnimationDuration=o)})),clearTimeout(o),i?o=setTimeout((function(){"function"==typeof t&&t()}),r):"function"==typeof t&&t(),n=[]},animate:function(t,e,o,n){if(n){D(t,"transition",""),D(t,"transform","");var i=k(this.el),r=i&&i.a,l=i&&i.d,a=(e.left-o.left)/(r||1),s=(e.top-o.top)/(l||1);t.animatingX=!!a,t.animatingY=!!s,D(t,"transform","translate3d("+a+"px,"+s+"px,0)"),this.forRepaintDummy=function(t){return t.offsetWidth}(t),D(t,"transition","transform "+n+"ms"+(this.options.easing?" "+this.options.easing:"")),D(t,"transform","translate3d(0,0,0)"),"number"==typeof t.animated&&clearTimeout(t.animated),t.animated=setTimeout((function(){D(t,"transition",""),D(t,"transform",""),t.animated=!1,t.animatingX=!1,t.animatingY=!1}),n)}}}))}function Vt(t,e,o,n,i,r,l,a){var s,c,h=t[$],f=h.options.onMove;return!window.CustomEvent||u||d?(s=document.createEvent("Event")).initEvent("move",!0,!0):s=new CustomEvent("move",{bubbles:!0,cancelable:!0}),s.to=e,s.from=t,s.dragged=o,s.draggedRect=n,s.related=i||e,s.relatedRect=r||O(e),s.willInsertAfter=a,s.originalEvent=l,t.dispatchEvent(s),f&&(c=f.call(h,s,l)),c}function Xt(t){t.draggable=!1}function $t(){Dt=!1}function Yt(t){for(var e=t.tagName+t.className+t.src+t.href+t.textContent,o=e.length,n=0;o--;)n+=e.charCodeAt(o);return n.toString(36)}function Lt(t){return setTimeout(t,0)}function zt(t){return clearTimeout(t)}jt.prototype={constructor:jt,_isOutsideThisEl:function(t){this.el.contains(t)||t===this.el||(mt=null)},_getDirection:function(t,e){return"function"==typeof this.options.direction?this.options.direction.call(this,t,e,G):this.options.direction},_onTapStart:function(t){if(t.cancelable){var e=this,o=this.el,n=this.options,i=n.preventOnFilter,r=t.type,l=t.touches&&t.touches[0]||t.pointerType&&"touch"===t.pointerType&&t,a=(l||t).target,s=t.target.shadowRoot&&(t.path&&t.path[0]||t.composedPath&&t.composedPath()[0])||a,c=n.filter;if(function(t){kt.length=0;for(var e=t.getElementsByTagName("input"),o=e.length;o--;){var n=e[o];n.checked&&kt.push(n)}}(o),!G&&!(/mousedown|pointerdown/.test(r)&&0!==t.button||n.disabled)&&!s.isContentEditable&&(this.nativeDraggable||!f||!a||"SELECT"!==a.tagName.toUpperCase())&&!((a=C(a,n.draggable,o,!1))&&a.animated||tt===a)){if(nt=P(a),rt=P(a,n.draggable),"function"==typeof c){if(c.call(this,t,a,this))return Z({sortable:e,rootEl:s,name:"filter",targetEl:a,toEl:o,fromEl:o}),U("filter",e,{evt:t}),void(i&&t.cancelable&&t.preventDefault())}else if(c&&(c=c.split(",").some((function(n){if(n=C(s,n.trim(),o,!1))return Z({sortable:e,rootEl:n,name:"filter",targetEl:a,fromEl:o,toEl:o}),U("filter",e,{evt:t}),!0}))))return void(i&&t.cancelable&&t.preventDefault());n.handle&&!C(s,n.handle,o,!1)||this._prepareDragStart(t,l,a)}}},_prepareDragStart:function(t,e,o){var n,i=this,r=i.el,l=i.options,a=r.ownerDocument;if(o&&!G&&o.parentNode===r){var s=O(o);if(J=r,K=(G=o).parentNode,Q=G.nextSibling,tt=o,at=l.group,jt.dragged=G,ct={target:G,clientX:(e||t).clientX,clientY:(e||t).clientY},ft=ct.clientX-s.left,pt=ct.clientY-s.top,this._lastX=(e||t).clientX,this._lastY=(e||t).clientY,G.style["will-change"]="all",n=function(){U("delayEnded",i,{evt:t}),jt.eventCanceled?i._onDrop():(i._disableDelayedDragEvents(),!h&&i.nativeDraggable&&(G.draggable=!0),i._triggerDragStart(t,e),Z({sortable:i,name:"choose",originalEvent:t}),E(G,l.chosenClass,!0))},l.ignore.split(",").forEach((function(t){x(G,t.trim(),Xt)})),v(a,"dragover",Bt),v(a,"mousemove",Bt),v(a,"touchmove",Bt),v(a,"mouseup",i._onDrop),v(a,"touchend",i._onDrop),v(a,"touchcancel",i._onDrop),h&&this.nativeDraggable&&(this.options.touchStartThreshold=4,G.draggable=!0),U("delayStart",this,{evt:t}),!l.delay||l.delayOnTouchOnly&&!e||this.nativeDraggable&&(d||u))n();else{if(jt.eventCanceled)return void this._onDrop();v(a,"mouseup",i._disableDelayedDrag),v(a,"touchend",i._disableDelayedDrag),v(a,"touchcancel",i._disableDelayedDrag),v(a,"mousemove",i._delayedDragTouchMoveHandler),v(a,"touchmove",i._delayedDragTouchMoveHandler),l.supportPointer&&v(a,"pointermove",i._delayedDragTouchMoveHandler),i._dragStartTimer=setTimeout(n,l.delay)}}},_delayedDragTouchMoveHandler:function(t){var e=t.touches?t.touches[0]:t;Math.max(Math.abs(e.clientX-this._lastX),Math.abs(e.clientY-this._lastY))>=Math.floor(this.options.touchStartThreshold/(this.nativeDraggable&&window.devicePixelRatio||1))&&this._disableDelayedDrag()},_disableDelayedDrag:function(){G&&Xt(G),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var t=this.el.ownerDocument;b(t,"mouseup",this._disableDelayedDrag),b(t,"touchend",this._disableDelayedDrag),b(t,"touchcancel",this._disableDelayedDrag),b(t,"mousemove",this._delayedDragTouchMoveHandler),b(t,"touchmove",this._delayedDragTouchMoveHandler),b(t,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(t,e){e=e||"touch"==t.pointerType&&t,!this.nativeDraggable||e?this.options.supportPointer?v(document,"pointermove",this._onTouchMove):v(document,e?"touchmove":"mousemove",this._onTouchMove):(v(G,"dragend",this),v(J,"dragstart",this._onDragStart));try{document.selection?Lt((function(){document.selection.empty()})):window.getSelection().removeAllRanges()}catch(t){}},_dragStarted:function(t,e){if(yt=!1,J&&G){U("dragStarted",this,{evt:e}),this.nativeDraggable&&v(document,"dragover",Rt);var o=this.options;!t&&E(G,o.dragClass,!1),E(G,o.ghostClass,!0),jt.active=this,t&&this._appendGhost(),Z({sortable:this,name:"start",originalEvent:e})}else this._nulling()},_emulateDragOver:function(){if(ut){this._lastX=ut.clientX,this._lastY=ut.clientY,Pt();for(var t=document.elementFromPoint(ut.clientX,ut.clientY),e=t;t&&t.shadowRoot&&(t=t.shadowRoot.elementFromPoint(ut.clientX,ut.clientY))!==e;)e=t;if(G.parentNode[$]._isOutsideThisEl(t),e)do{if(e[$]&&e[$]._onDragOver({clientX:ut.clientX,clientY:ut.clientY,target:t,rootEl:e})&&!this.options.dragoverBubble)break;t=e}while(e=e.parentNode);Wt()}},_onTouchMove:function(t){if(ct){var e=this.options,o=e.fallbackTolerance,n=e.fallbackOffset,i=t.touches?t.touches[0]:t,r=q&&k(q,!0),l=q&&r&&r.a,a=q&&r&&r.d,s=Tt&&bt&&W(bt),c=(i.clientX-ct.clientX+n.x)/(l||1)+(s?s[0]-Et[0]:0)/(l||1),u=(i.clientY-ct.clientY+n.y)/(a||1)+(s?s[1]-Et[1]:0)/(a||1);if(!jt.active&&!yt){if(o&&Math.max(Math.abs(i.clientX-this._lastX),Math.abs(i.clientY-this._lastY))<o)return;this._onDragStart(t,!0)}if(q){r?(r.e+=c-(dt||0),r.f+=u-(ht||0)):r={a:1,b:0,c:0,d:1,e:c,f:u};var d="matrix(".concat(r.a,",").concat(r.b,",").concat(r.c,",").concat(r.d,",").concat(r.e,",").concat(r.f,")");D(q,"webkitTransform",d),D(q,"mozTransform",d),D(q,"msTransform",d),D(q,"transform",d),dt=c,ht=u,ut=i}t.cancelable&&t.preventDefault()}},_appendGhost:function(){if(!q){var t=this.options.fallbackOnBody?document.body:J,e=O(G,!0,Tt,!0,t),o=this.options;if(Tt){for(bt=t;"static"===D(bt,"position")&&"none"===D(bt,"transform")&&bt!==document;)bt=bt.parentNode;bt!==document.body&&bt!==document.documentElement?(bt===document&&(bt=T()),e.top+=bt.scrollTop,e.left+=bt.scrollLeft):bt=T(),Et=W(bt)}E(q=G.cloneNode(!0),o.ghostClass,!1),E(q,o.fallbackClass,!0),E(q,o.dragClass,!0),D(q,"transition",""),D(q,"transform",""),D(q,"box-sizing","border-box"),D(q,"margin",0),D(q,"top",e.top),D(q,"left",e.left),D(q,"width",e.width),D(q,"height",e.height),D(q,"opacity","0.8"),D(q,"position",Tt?"absolute":"fixed"),D(q,"zIndex","100000"),D(q,"pointerEvents","none"),jt.ghost=q,t.appendChild(q),D(q,"transform-origin",ft/parseInt(q.style.width)*100+"% "+pt/parseInt(q.style.height)*100+"%")}},_onDragStart:function(t,e){var o=this,n=t.dataTransfer,i=o.options;U("dragStart",this,{evt:t}),jt.eventCanceled?this._onDrop():(U("setupClone",this),jt.eventCanceled||((et=X(G)).removeAttribute("id"),et.draggable=!1,et.style["will-change"]="",this._hideClone(),E(et,this.options.chosenClass,!1),jt.clone=et),o.cloneId=Lt((function(){U("clone",o),jt.eventCanceled||(o.options.removeCloneOnHide||J.insertBefore(et,G),o._hideClone(),Z({sortable:o,name:"clone"}))})),!e&&E(G,i.dragClass,!0),e?(Ft=!0,o._loopId=setInterval(o._emulateDragOver,50)):(b(document,"mouseup",o._onDrop),b(document,"touchend",o._onDrop),b(document,"touchcancel",o._onDrop),n&&(n.effectAllowed="move",i.setData&&i.setData.call(o,n,G)),v(document,"drop",o),D(G,"transform","translateZ(0)")),yt=!0,o._dragStartId=Lt(o._dragStarted.bind(o,e,t)),v(document,"selectstart",o),gt=!0,f&&D(document.body,"user-select","none"))},_onDragOver:function(t){var e,o,n,i,l=this.el,a=t.target,s=this.options,c=s.group,u=jt.active,d=at===c,h=s.sort,f=st||u,p=this,g=!1;if(!Dt){if(void 0!==t.preventDefault&&t.cancelable&&t.preventDefault(),a=C(a,s.draggable,l,!0),j("dragOver"),jt.eventCanceled)return g;if(G.contains(t.target)||a.animated&&a.animatingX&&a.animatingY||p._ignoreWhileAnimating===a)return Y(!1);if(Ft=!1,u&&!s.disabled&&(d?h||(n=K!==J):st===this||(this.lastPutMode=at.checkPull(this,u,G,t))&&c.checkPut(this,u,G,t))){if(i="vertical"===this._getDirection(t,a),e=O(G),j("dragOverValid"),jt.eventCanceled)return g;if(n)return K=J,X(),this._hideClone(),j("revert"),jt.eventCanceled||(Q?J.insertBefore(G,Q):J.appendChild(G)),Y(!0);var m=M(l,s.draggable);if(!m||function(t,e,o){var n=O(M(o.el,o.options.draggable)),i=I(o.el);return e?t.clientX>i.right+10||t.clientY>n.bottom&&t.clientX>n.left:t.clientY>i.bottom+10||t.clientX>n.right&&t.clientY>n.top}(t,i,this)&&!m.animated){if(m===G)return Y(!1);if(m&&l===t.target&&(a=m),a&&(o=O(a)),!1!==Vt(J,l,G,e,a,o,t,!!a))return X(),m&&m.nextSibling?l.insertBefore(G,m.nextSibling):l.appendChild(G),K=l,L(),Y(!0)}else if(m&&function(t,e,o){var n=O(A(o.el,0,o.options,!0)),i=I(o.el);return e?t.clientX<i.left-10||t.clientY<n.top&&t.clientX<n.right:t.clientY<i.top-10||t.clientY<n.bottom&&t.clientX<n.left}(t,i,this)){var v=A(l,0,s,!0);if(v===G)return Y(!1);if(o=O(a=v),!1!==Vt(J,l,G,e,a,o,t,!1))return X(),l.insertBefore(G,v),K=l,L(),Y(!0)}else if(a.parentNode===l){o=O(a);var _,b,y,F=G.parentNode!==l,w=!function(t,e,o){var n=o?t.left:t.top,i=o?t.right:t.bottom,r=o?t.width:t.height,l=o?e.left:e.top,a=o?e.right:e.bottom,s=o?e.width:e.height;return n===l||i===a||n+r/2===l+s/2}(G.animated&&G.toRect||e,a.animated&&a.toRect||o,i),S=i?"top":"left",k=N(a,"top","top")||N(G,"top","top"),x=k?k.scrollTop:void 0;if(mt!==a&&(b=o[S],wt=!1,St=!w&&s.invertSwap||F),_=function(t,e,o,n,i,r,l,a){var s=n?t.clientY:t.clientX,c=n?o.height:o.width,u=n?o.top:o.left,d=n?o.bottom:o.right,h=!1;if(!l)if(a&&_t<c*i){if(!wt&&(1===vt?s>u+c*r/2:s<d-c*r/2)&&(wt=!0),wt)h=!0;else if(1===vt?s<u+_t:s>d-_t)return-vt}else if(s>u+c*(1-i)/2&&s<d-c*(1-i)/2)return function(t){return P(G)<P(t)?1:-1}(e);return(h=h||l)&&(s<u+c*r/2||s>d-c*r/2)?s>u+c/2?1:-1:0}(t,a,o,i,w?1:s.swapThreshold,null==s.invertedSwapThreshold?s.swapThreshold:s.invertedSwapThreshold,St,mt===a),0!==_){var T=P(G);do{T-=_,y=K.children[T]}while(y&&("none"===D(y,"display")||y===q))}if(0===_||y===a)return Y(!1);mt=a,vt=_;var W=a.nextElementSibling,B=!1,R=Vt(J,l,G,e,a,o,t,B=1===_);if(!1!==R)return 1!==R&&-1!==R||(B=1===R),Dt=!0,setTimeout($t,30),X(),B&&!W?l.appendChild(G):a.parentNode.insertBefore(G,B?W:a),k&&V(k,0,x-k.scrollTop),K=G.parentNode,void 0===b||St||(_t=Math.abs(b-O(a)[S])),L(),Y(!0)}if(l.contains(G))return Y(!1)}return!1}function j(s,c){U(s,p,r({evt:t,isOwner:d,axis:i?"vertical":"horizontal",revert:n,dragRect:e,targetRect:o,canSort:h,fromSortable:f,target:a,completed:Y,onMove:function(o,n){return Vt(J,l,G,e,o,O(o),t,n)},changed:L},c))}function X(){j("dragOverAnimationCapture"),p.captureAnimationState(),p!==f&&f.captureAnimationState()}function Y(e){return j("dragOverCompleted",{insertion:e}),e&&(d?u._hideClone():u._showClone(p),p!==f&&(E(G,st?st.options.ghostClass:u.options.ghostClass,!1),E(G,s.ghostClass,!0)),st!==p&&p!==jt.active?st=p:p===jt.active&&st&&(st=null),f===p&&(p._ignoreWhileAnimating=a),p.animateAll((function(){j("dragOverAnimationComplete"),p._ignoreWhileAnimating=null})),p!==f&&(f.animateAll(),f._ignoreWhileAnimating=null)),(a===G&&!G.animated||a===l&&!a.animated)&&(mt=null),s.dragoverBubble||t.rootEl||a===document||(G.parentNode[$]._isOutsideThisEl(t.target),!e&&Bt(t)),!s.dragoverBubble&&t.stopPropagation&&t.stopPropagation(),g=!0}function L(){it=P(G),lt=P(G,s.draggable),Z({sortable:p,name:"change",toEl:l,newIndex:it,newDraggableIndex:lt,originalEvent:t})}},_ignoreWhileAnimating:null,_offMoveEvents:function(){b(document,"mousemove",this._onTouchMove),b(document,"touchmove",this._onTouchMove),b(document,"pointermove",this._onTouchMove),b(document,"dragover",Bt),b(document,"mousemove",Bt),b(document,"touchmove",Bt)},_offUpEvents:function(){var t=this.el.ownerDocument;b(t,"mouseup",this._onDrop),b(t,"touchend",this._onDrop),b(t,"pointerup",this._onDrop),b(t,"touchcancel",this._onDrop),b(document,"selectstart",this)},_onDrop:function(t){var e=this.el,o=this.options;it=P(G),lt=P(G,o.draggable),U("drop",this,{evt:t}),K=G&&G.parentNode,it=P(G),lt=P(G,o.draggable),jt.eventCanceled||(yt=!1,St=!1,wt=!1,clearInterval(this._loopId),clearTimeout(this._dragStartTimer),zt(this.cloneId),zt(this._dragStartId),this.nativeDraggable&&(b(document,"drop",this),b(e,"dragstart",this._onDragStart)),this._offMoveEvents(),this._offUpEvents(),f&&D(document.body,"user-select",""),D(G,"transform",""),t&&(gt&&(t.cancelable&&t.preventDefault(),!o.dropBubble&&t.stopPropagation()),q&&q.parentNode&&q.parentNode.removeChild(q),(J===K||st&&"clone"!==st.lastPutMode)&&et&&et.parentNode&&et.parentNode.removeChild(et),G&&(this.nativeDraggable&&b(G,"dragend",this),Xt(G),G.style["will-change"]="",gt&&!yt&&E(G,st?st.options.ghostClass:this.options.ghostClass,!1),E(G,this.options.chosenClass,!1),Z({sortable:this,name:"unchoose",toEl:K,newIndex:null,newDraggableIndex:null,originalEvent:t}),J!==K?(it>=0&&(Z({rootEl:K,name:"add",toEl:K,fromEl:J,originalEvent:t}),Z({sortable:this,name:"remove",toEl:K,originalEvent:t}),Z({rootEl:K,name:"sort",toEl:K,fromEl:J,originalEvent:t}),Z({sortable:this,name:"sort",toEl:K,originalEvent:t})),st&&st.save()):it!==nt&&it>=0&&(Z({sortable:this,name:"update",toEl:K,originalEvent:t}),Z({sortable:this,name:"sort",toEl:K,originalEvent:t})),jt.active&&(null!=it&&-1!==it||(it=nt,lt=rt),Z({sortable:this,name:"end",toEl:K,originalEvent:t}),this.save())))),this._nulling()},_nulling:function(){U("nulling",this),J=G=K=q=Q=et=tt=ot=ct=ut=gt=it=lt=nt=rt=mt=vt=st=at=jt.dragged=jt.ghost=jt.clone=jt.active=null,kt.forEach((function(t){t.checked=!0})),kt.length=dt=ht=0},handleEvent:function(t){switch(t.type){case"drop":case"dragend":this._onDrop(t);break;case"dragenter":case"dragover":G&&(this._onDragOver(t),function(t){t.dataTransfer&&(t.dataTransfer.dropEffect="move"),t.cancelable&&t.preventDefault()}(t));break;case"selectstart":t.preventDefault()}},toArray:function(){for(var t,e=[],o=this.el.children,n=0,i=o.length,r=this.options;n<i;n++)C(t=o[n],r.draggable,this.el,!1)&&e.push(t.getAttribute(r.dataIdAttr)||Yt(t));return e},sort:function(t,e){var o={},n=this.el;this.toArray().forEach((function(t,e){var i=n.children[e];C(i,this.options.draggable,n,!1)&&(o[t]=i)}),this),e&&this.captureAnimationState(),t.forEach((function(t){o[t]&&(n.removeChild(o[t]),n.appendChild(o[t]))})),e&&this.animateAll()},save:function(){var t=this.options.store;t&&t.set&&t.set(this)},closest:function(t,e){return C(t,e||this.options.draggable,this.el,!1)},option:function(t,e){var o=this.options;if(void 0===e)return o[t];var n=z.modifyOption(this,t,e);o[t]=void 0!==n?n:e,"group"===t&&Mt(o)},destroy:function(){U("destroy",this);var t=this.el;t[$]=null,b(t,"mousedown",this._onTapStart),b(t,"touchstart",this._onTapStart),b(t,"pointerdown",this._onTapStart),this.nativeDraggable&&(b(t,"dragover",this),b(t,"dragenter",this)),Array.prototype.forEach.call(t.querySelectorAll("[draggable]"),(function(t){t.removeAttribute("draggable")})),this._onDrop(),this._disableDelayedDragEvents(),Ct.splice(Ct.indexOf(this.el),1),this.el=t=null},_hideClone:function(){if(!ot){if(U("hideClone",this),jt.eventCanceled)return;D(et,"display","none"),this.options.removeCloneOnHide&&et.parentNode&&et.parentNode.removeChild(et),ot=!0}},_showClone:function(t){if("clone"===t.lastPutMode){if(ot){if(U("showClone",this),jt.eventCanceled)return;G.parentNode!=J||this.options.group.revertClone?Q?J.insertBefore(et,Q):J.appendChild(et):J.insertBefore(et,G),this.options.group.revertClone&&this.animate(G,et),D(et,"display",""),ot=!1}}else this._hideClone()}},xt&&v(document,"touchmove",(function(t){(jt.active||yt)&&t.cancelable&&t.preventDefault()})),jt.utils={on:v,off:b,css:D,find:x,is:function(t,e){return!!C(t,e,t,!1)},extend:function(t,e){if(t&&e)for(var o in e)e.hasOwnProperty(o)&&(t[o]=e[o]);return t},throttle:j,closest:C,toggleClass:E,clone:X,index:P,nextTick:Lt,cancelNextTick:zt,detectDirection:At,getChild:A},jt.get=function(t){return t[$]},jt.mount=function(){for(var t=arguments.length,e=new Array(t),o=0;o<t;o++)e[o]=arguments[o];e[0].constructor===Array&&(e=e[0]),e.forEach((function(t){if(!t.prototype||!t.prototype.constructor)throw"Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(t));t.utils&&(jt.utils=r(r({},jt.utils),t.utils)),z.mount(t)}))},jt.create=function(t,e){return new jt(t,e)},jt.version="1.15.1";var Ht,Ut,Zt,Gt,Kt,qt,Jt=[],Qt=!1;function te(){Jt.forEach((function(t){clearInterval(t.pid)})),Jt=[]}function ee(){clearInterval(qt)}var oe=j((function(t,e,o,n){if(e.scroll){var i,r=(t.touches?t.touches[0]:t).clientX,l=(t.touches?t.touches[0]:t).clientY,a=e.scrollSensitivity,s=e.scrollSpeed,c=T(),u=!1;Ut!==o&&(Ut=o,te(),Ht=e.scroll,i=e.scrollFn,!0===Ht&&(Ht=B(o,!0)));var d=0,h=Ht;do{var f=h,p=O(f),g=p.top,m=p.bottom,v=p.left,_=p.right,b=p.width,y=p.height,F=void 0,C=void 0,w=f.scrollWidth,S=f.scrollHeight,E=D(f),k=f.scrollLeft,x=f.scrollTop;f===c?(F=b<w&&("auto"===E.overflowX||"scroll"===E.overflowX||"visible"===E.overflowX),C=y<S&&("auto"===E.overflowY||"scroll"===E.overflowY||"visible"===E.overflowY)):(F=b<w&&("auto"===E.overflowX||"scroll"===E.overflowX),C=y<S&&("auto"===E.overflowY||"scroll"===E.overflowY));var I=F&&(Math.abs(_-r)<=a&&k+b<w)-(Math.abs(v-r)<=a&&!!k),N=C&&(Math.abs(m-l)<=a&&x+y<S)-(Math.abs(g-l)<=a&&!!x);if(!Jt[d])for(var A=0;A<=d;A++)Jt[A]||(Jt[A]={});Jt[d].vx==I&&Jt[d].vy==N&&Jt[d].el===f||(Jt[d].el=f,Jt[d].vx=I,Jt[d].vy=N,clearInterval(Jt[d].pid),0==I&&0==N||(u=!0,Jt[d].pid=setInterval(function(){n&&0===this.layer&&jt.active._onTouchMove(Kt);var e=Jt[this.layer].vy?Jt[this.layer].vy*s:0,o=Jt[this.layer].vx?Jt[this.layer].vx*s:0;"function"==typeof i&&"continue"!==i.call(jt.dragged.parentNode[$],o,e,t,Kt,Jt[this.layer].el)||V(Jt[this.layer].el,o,e)}.bind({layer:d}),24))),d++}while(e.bubbleScroll&&h!==c&&(h=B(h,!1)));Qt=u}}),30),ne=function(t){var e=t.originalEvent,o=t.putSortable,n=t.dragEl,i=t.activeSortable,r=t.dispatchSortableEvent,l=t.hideGhostForTarget,a=t.unhideGhostForTarget;if(e){var s=o||i;l();var c=e.changedTouches&&e.changedTouches.length?e.changedTouches[0]:e,u=document.elementFromPoint(c.clientX,c.clientY);a(),s&&!s.el.contains(u)&&(r("spill"),this.onSpill({dragEl:n,putSortable:o}))}};function ie(){}function re(){}ie.prototype={startIndex:null,dragStart:function(t){var e=t.oldDraggableIndex;this.startIndex=e},onSpill:function(t){var e=t.dragEl,o=t.putSortable;this.sortable.captureAnimationState(),o&&o.captureAnimationState();var n=A(this.sortable.el,this.startIndex,this.options);n?this.sortable.el.insertBefore(e,n):this.sortable.el.appendChild(e),this.sortable.animateAll(),o&&o.animateAll()},drop:ne},s(ie,{pluginName:"revertOnSpill"}),re.prototype={onSpill:function(t){var e=t.dragEl,o=t.putSortable||this.sortable;o.captureAnimationState(),e.parentNode&&e.parentNode.removeChild(e),o.animateAll()},drop:ne},s(re,{pluginName:"removeOnSpill"}),jt.mount(new function(){function t(){for(var t in this.defaults={scroll:!0,forceAutoScrollFallback:!1,scrollSensitivity:30,scrollSpeed:10,bubbleScroll:!0},this)"_"===t.charAt(0)&&"function"==typeof this[t]&&(this[t]=this[t].bind(this))}return t.prototype={dragStarted:function(t){var e=t.originalEvent;this.sortable.nativeDraggable?v(document,"dragover",this._handleAutoScroll):this.options.supportPointer?v(document,"pointermove",this._handleFallbackAutoScroll):e.touches?v(document,"touchmove",this._handleFallbackAutoScroll):v(document,"mousemove",this._handleFallbackAutoScroll)},dragOverCompleted:function(t){var e=t.originalEvent;this.options.dragOverBubble||e.rootEl||this._handleAutoScroll(e)},drop:function(){this.sortable.nativeDraggable?b(document,"dragover",this._handleAutoScroll):(b(document,"pointermove",this._handleFallbackAutoScroll),b(document,"touchmove",this._handleFallbackAutoScroll),b(document,"mousemove",this._handleFallbackAutoScroll)),ee(),te(),clearTimeout(w),w=void 0},nulling:function(){Kt=Ut=Ht=Qt=qt=Zt=Gt=null,Jt.length=0},_handleFallbackAutoScroll:function(t){this._handleAutoScroll(t,!0)},_handleAutoScroll:function(t,e){var o=this,n=(t.touches?t.touches[0]:t).clientX,i=(t.touches?t.touches[0]:t).clientY,r=document.elementFromPoint(n,i);if(Kt=t,e||this.options.forceAutoScrollFallback||d||u||f){oe(t,this.options,r,e);var l=B(r,!0);!Qt||qt&&n===Zt&&i===Gt||(qt&&ee(),qt=setInterval((function(){var r=B(document.elementFromPoint(n,i),!0);r!==l&&(l=r,te()),oe(t,o.options,r,e)}),10),Zt=n,Gt=i)}else{if(!this.options.bubbleScroll||B(r,!0)===T())return void te();oe(t,this.options,B(r,!1),!1)}}},s(t,{pluginName:"scroll",initializeByDefault:!0})}),jt.mount(re,ie);var le=jt,ae={name:"ZjTableColumnConfiger",props:{defaultColumnShowCount:{type:Number,default:20},defaultColumnShowKeys:{type:Array,default:()=>[]},columns:{type:Array,default:()=>[]},columnKey:{type:String,default:"id"},props:{type:Object,default(){return{label:"label"}}},showConfirm:{type:Boolean,default:!1},tag:{type:String,default:""},userId:{type:[String,Number],default:""}},watch:{columns(t){console.log("newValue",t),this.cols_config=this.getCustomerColsConfig(t),this.$emit("change",this.cols_config)}},data(){return{editing:!1,visible:!1,cols_config:[],ColsConfigTmp:[]}},methods:{reset(){this.cols_config=[],this.$nextTick((()=>{this.cols_config=this.getCustomerColsConfig(this.columns)})),this.editing=!1},submit(){this.update(),this.editing=!1},update(){console.log("update: ",this.cols_config),this.setCutomerColsConfig(),this.$emit("change",this.cols_config)},checkboxClick(){this.editing=!0,this.showConfirm||this.update()},initDragSort(){const t=this.$refs.col_config.$el.querySelectorAll(".col-config-list")[0];le.create(t,{onEnd:({oldIndex:t,newIndex:e})=>{this.editing=!0;const o=this.ColsConfigTmp[t];this.ColsConfigTmp.splice(t,1),this.ColsConfigTmp.splice(e,0,o),console.log("this.ColsConfigTmp",this.ColsConfigTmp);const n=this.ColsConfigTmp.map((t=>t.id));console.log("newKeysArr: ",n),_.each(this.cols_config,(t=>{const e=n.indexOf(t.id);t.sort_index=e})),console.log("this.col_config: ",this.col_config),this.$forceUpdate(),this.showConfirm||this.update()}})},setCutomerColsConfig(){let t={},e="";t=localStorage.getItem("COLUMN_CUSTOMER_CONFIG")&&JSON.parse(localStorage.getItem("COLUMN_CUSTOMER_CONFIG"))||{},e=t[this.userId+this.tag],e?e.field_colunms_config=this.cols_config:e={field_colunms_config:this.cols_config},t[this.userId+this.tag]=e,localStorage.setItem("COLUMN_CUSTOMER_CONFIG",JSON.stringify(t))},setColWidth(t,e){_.each(this.cols_config,(o=>{o.id==t&&(o.width=e)})),this.setCutomerColsConfig()},getCustomerColsConfig(t){let e=[],o={},n=[],i={};i=localStorage.getItem("COLUMN_CUSTOMER_CONFIG")&&JSON.parse(localStorage.getItem("COLUMN_CUSTOMER_CONFIG"))||{},o=i[this.userId+this.tag],o&&o.field_colunms_config&&(n=o.field_colunms_config);let r=0;return _.each(t,(t=>{let o=_.find(n,{id:t[this.columnKey]});o?e.push({label:t[this.props.label],id:t[this.columnKey],show:o.show,sort_index:o.sort_index,width:o.width||""}):(r++,e.push({label:t[this.props.label],id:t[this.columnKey],show:!!(r<=this.defaultColumnShowCount||_.includes(this.defaultColumnShowKeys,t[this.columnKey])),sort_index:0,width:""}))})),e=_.sortBy(e,"sort_index"),this.ColsConfigTmp=_.cloneDeep(e),e}},mounted(){this.cols_config=this.getCustomerColsConfig(this.columns),this.initDragSort()}},se=ae,ce=(0,o(900).Z)(se,n,[],!1,null,null,null);ce.options.__file="components/lib/table-column-configer/src/main.vue";var ue=ce.exports;ue.install=function(t){t.component(ue.name,ue)};var de=ue},900:function(t,e,o){function n(t,e,o,n,i,r,l,a){var s,c="function"==typeof t?t.options:t;if(e&&(c.render=e,c.staticRenderFns=o,c._compiled=!0),n&&(c.functional=!0),r&&(c._scopeId="data-v-"+r),l?(s=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),i&&i.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(l)},c._ssrRegister=s):i&&(s=a?function(){i.call(this,(c.functional?this.parent:this).$root.$options.shadowRoot)}:i),s)if(c.functional){c._injectStyles=s;var u=c.render;c.render=function(t,e){return s.call(e),u(t,e)}}else{var d=c.beforeCreate;c.beforeCreate=d?[].concat(d,s):[s]}return{exports:t,options:c}}o.d(e,{Z:function(){return n}})}},e={};function o(n){var i=e[n];if(void 0!==i)return i.exports;var r=e[n]={exports:{}};return t[n](r,r.exports,o),r.exports}o.d=function(t,e){for(var n in e)o.o(e,n)&&!o.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},o.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},o.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var n={};return function(){o.r(n),o.d(n,{Demo:function(){return t.default},Demo2:function(){return e.default},SelectPositionTable:function(){return r.default},TableColumnConfiger:function(){return i.default}});var t=o(924),e=o(367),i=o(387),r=o(622);const l={Demo:t.default,Demo2:e.default,TableColumnConfiger:i.default,SelectPositionTable:r.default},a=function(t){a.installed||Object.keys(l).forEach((e=>{t.component(l[e].name,l[e])}))};n.default={version:"0.0.4",install:a}}(),n}()},6981:function(t){t.exports=function(){return this.ELEMENT}()},3371:function(t){t.exports=function(){return this.Vue}()}},e={};function o(n){var i=e[n];if(void 0!==i)return i.exports;var r=e[n]={id:n,exports:{}};return t[n](r,r.exports,o),r.exports}o.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return o.d(e,{a:e}),e},o.d=function(t,e){for(var n in e)o.o(e,n)&&!o.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},o.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},o.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},o.nc=void 0;var n={};return function(){"use strict";o.r(n),o.d(n,{default:function(){return T}});var t=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("div",{staticClass:"select-section"},[o("el-button",{attrs:{type:"plain",icon:"el-icon-location-outline"},on:{click:function(e){return t.openSelectSectionDlg()}}},[t._v("选择部位")]),t._v(" "),o("dlg-select-section",{attrs:{show:t.dlg.show},on:{close:function(e){return t.colseSelectSectionDlg()}}})],1)};t._withStripped=!0;var e=o(6981),i=o(3371),r=o.n(i),l=function(){var t=this,e=t.$createElement,o=t._self._c||e;return o("el-dialog",{attrs:{title:"选择部位",visible:t.dialogVisible,width:"80%","before-close":t.handleClose},on:{"update:visible":function(e){t.dialogVisible=e}}},[o("zj-select-position-table",{attrs:{data:t.treeData},model:{value:t.selectedItem,callback:function(e){t.selectedItem=e},expression:"selectedItem"}}),t._v(" "),o("span",{staticClass:"dialog-footer",attrs:{slot:"footer"},slot:"footer"},[o("el-button",{on:{click:function(e){return t.close()}}},[t._v("取 消")]),t._v(" "),o("el-button",{attrs:{type:"primary"},on:{click:function(e){return t.close()}}},[t._v("确 定")])],1)],1)};l._withStripped=!0;var a=o(6407),s=o(3379),c=o.n(s),u=o(7795),d=o.n(u),h=o(569),f=o.n(h),p=o(3565),g=o.n(p),m=o(9216),v=o.n(m),_=o(4589),b=o.n(_),y=o(8459),F={};F.styleTagTransform=b(),F.setAttributes=g(),F.insert=f().bind(null,"head"),F.domAPI=d(),F.insertStyleElement=v(),c()(y.Z,F),y.Z&&y.Z.locals&&y.Z.locals,r().use(a.SelectPositionTable);var C={props:{show:{type:Boolean,default:!1}},watch:{show(t){this.dialogVisible=t}},data(){return{dialogVisible:!1,form:{building:"1",show_type:"4",keyword:""},floors:[],selectedItem:[{name:"7层-CW01-左防水片",key:"7_1_1"},{name:"7层-CW01-右防水片",key:"7_1_2"},{name:"7层-CW02-左防水片",key:"7_2_1"},{name:"7层-CW02-右防水片",key:"7_2_2"}],treeData:[]}},methods:{close(){this.dialogVisible=!1,this.$emit("close")},handleClose(t){this.$emit("close"),this.$confirm("确认关闭?").then((e=>{t()})).catch((t=>{}))},loadData(){let t=[];this.form.show_type,t=[{title:"7层",childrens:[{title:"CW01",color:"#FFF",state:!1,key:"7_1",childrens:[{key:"7_1_1",title:"左防水片",color:"#FFF",state:!1},{key:"7_1_2",title:"右防水片",color:"#FFF",state:!1}]},{title:"CW02",color:"#FFF",state:!1,key:"7_2",childrens:[{key:"7_2_1",title:"左防水片",color:"#FFF",state:!1},{key:"7_2_2",title:"右防水片",color:"#FFF",state:!1}]},{title:"CW03",color:"#FFF",state:!1,key:"7_3",childrens:[{title:"左防水片",color:"#FEEDCA",state:!1,key:"7_3_1"},{title:"右防水片",color:"#FFF",state:!1,key:"7_3_2"}]},{title:"CW04",color:"#FFF",state:!1,key:"7_4",childrens:[{title:"左防水片",color:"#CBF3DD",state:!1,key:"7_4_1"},{title:"右防水片",color:"#CBF3DD",state:!1,key:"7_4_2"}]},{title:"CW05",color:"#FFF",state:!1,key:"7_5",childrens:[{title:"左防水片",color:"#CBF3DD",state:!1,key:"7_5_1"},{title:"右防水片",color:"#FFF",state:!1,key:"7_45_2"}]},{title:"CW06",color:"#FFF",state:!1,key:"7_6",childrens:[{title:"左防水片",color:"#CBF3DD",state:!1,key:"7_6_1"},{title:"右防水片",color:"#FFF",state:!1,key:"7_6_2"}]},{title:"CW07",color:"#FFF",state:!1,key:"7_7",childrens:[{title:"左防水片",color:"#CBF3DD",state:!1,key:"7_7_1"},{title:"右防水片",color:"#FFF",state:!1,key:"7_7_2"}]},{title:"CW08",color:"#FFF",state:!1,key:"7_8",childrens:[{title:"左防水片",color:"#CBF3DD",state:!1,key:"7_8_1"},{title:"右防水片",color:"#FFF",state:!1,key:"7_8_2"}]}]},{title:"6层",childrens:[{title:"CW01",color:"#FFF",state:!1,key:"6_1",childrens:[{key:"6_1_1",title:"左防水片",color:"#FFF",state:!1},{key:"6_1_2",title:"右防水片",color:"#FFF",state:!1}]},{title:"CW02",color:"#FFF",state:!1,key:"6_2",childrens:[{key:"6_2_1",title:"左防水片",color:"#FFF",state:!1},{key:"6_2_2",title:"右防水片",color:"#FFF",state:!1}]},{title:"CW03",color:"#FFF",state:!1,key:"6_3",childrens:[{title:"左防水片",color:"#FEEDCA",state:!1,key:"6_3_1"},{title:"右防水片",color:"#FFF",state:!1,key:"6_3_2"}]},{title:"CW04",color:"#FFF",state:!1,key:"6_4",childrens:[{title:"左防水片",color:"#CBF3DD",state:!1,key:"6_4_1"},{title:"右防水片",color:"#CBF3DD",state:!1,key:"6_4_2"}]},{title:"CW05",color:"#FFF",state:!1,key:"6_5",childrens:[{title:"左防水片",color:"#CBF3DD",state:!1,key:"6_5_1"},{title:"右防水片",color:"#FFF",state:!1,key:"6_5_2"}]}]},{title:"5层",childrens:[{title:"CW01",color:"#FFF",state:!1,key:"5_1",childrens:[{key:"5_1_1",title:"左防水片",color:"#FFF",state:!1},{key:"5_1_2",title:"右防水片",color:"#FFF",state:!1}]},{title:"CW02",color:"#FFF",state:!1,key:"5_2",childrens:[{key:"5_2_1",title:"左防水片",color:"#FFF",state:!1},{key:"5_2_2",title:"右防水片",color:"#FFF",state:!1}]},{title:"CW03",color:"#FFF",state:!1,key:"5_3",childrens:[{title:"左防水片",color:"#FEEDCA",state:!1,key:"5_3_1"},{title:"右防水片",color:"#FFF",state:!1,key:"5_3_2"}]},{title:"CW04",color:"#FFF",state:!1,key:"5_4",childrens:[{title:"左防水片",color:"#CBF3DD",state:!1,key:"5_4_1"},{title:"右防水片",color:"#CBF3DD",state:!1,key:"5_4_2"}]},{title:"CW05",color:"#FFF",state:!1,key:"5_5",childrens:[{title:"左防水片",color:"#CBF3DD",state:!1,key:"5_5_1"},{title:"右防水片",color:"#FFF",state:!1,key:"5_5_2"}]}]},{title:"4层",childrens:[{title:"CW01",color:"#FFF",state:!1,key:"4_1",childrens:[{key:"4_1_1",title:"左防水片",color:"#FFF",state:!1},{key:"4_1_2",title:"右防水片",color:"#FFF",state:!1}]},{title:"CW02",color:"#FFF",state:!1,key:"4_2",childrens:[{key:"4_2_1",title:"左防水片",color:"#FFF",state:!1},{key:"4_2_2",title:"右防水片",color:"#FFF",state:!1}]},{title:"CW03",color:"#FFF",state:!1,key:"4_3",childrens:[{title:"左防水片",color:"#FEEDCA",state:!1,key:"4_3_1"},{title:"右防水片",color:"#FFF",state:!1,key:"4_3_2"}]},{title:"CW04",color:"#FFF",state:!1,key:"4_4",childrens:[{title:"左防水片",color:"#CBF3DD",state:!1,key:"4_4_1"},{title:"右防水片",color:"#CBF3DD",state:!1,key:"4_4_2"}]},{title:"CW05",color:"#FFF",state:!1,key:"4_5",childrens:[{title:"左防水片",color:"#CBF3DD",state:!1,key:"4_5_1"},{title:"右防水片",color:"#FFF",state:!1,key:"4_5_2"}]}]},{title:"3层",childrens:[{title:"CW01",color:"#FFF",state:!1,key:"3_1",childrens:[{key:"3_1_1",title:"左防水片",color:"#FFF",state:!1},{key:"3_1_2",title:"右防水片",color:"#FFF",state:!1}]},{title:"CW02",color:"#FFF",state:!1,key:"3_2",childrens:[{key:"3_2_1",title:"左防水片",color:"#FFF",state:!1},{key:"3_2_2",title:"右防水片",color:"#FFF",state:!1}]},{title:"CW03",color:"#FFF",state:!1,key:"3_3",childrens:[{title:"左防水片",color:"#FEEDCA",state:!1,key:"3_3_1"},{title:"右防水片",color:"#FFF",state:!1,key:"3_3_2"}]},{title:"CW04",color:"#FFF",state:!1,key:"3_4",childrens:[{title:"左防水片",color:"#CBF3DD",state:!1,key:"3_4_1"},{title:"右防水片",color:"#CBF3DD",state:!1,key:"3_4_2"}]},{title:"CW05",color:"#FFF",state:!1,key:"3_5",childrens:[{title:"左防水片",color:"#CBF3DD",state:!1,key:"3_5_1"},{title:"右防水片",color:"#FFF",state:!1,key:"3_5_2"}]}]},{title:"2层",childrens:[{title:"CW01",color:"#FFF",state:!1,key:"2_1",childrens:[{key:"2_1_1",title:"左防水片",color:"#FFF",state:!1},{key:"2_1_2",title:"右防水片",color:"#FFF",state:!1}]},{title:"CW02",color:"#FFF",state:!1,key:"2_2",childrens:[{key:"2_2_1",title:"左防水片",color:"#FFF",state:!1},{key:"2_2_2",title:"右防水片",color:"#FFF",state:!1}]},{title:"CW03",color:"#FFF",state:!1,key:"2_3",childrens:[{title:"左防水片",color:"#FEEDCA",state:!1,key:"2_3_1"},{title:"右防水片",color:"#FFF",state:!1,key:"2_3_2"}]},{title:"CW04",color:"#FFF",state:!1,key:"2_4",childrens:[{title:"左防水片",color:"#CBF3DD",state:!1,key:"2_4_1"},{title:"右防水片",color:"#CBF3DD",state:!1,key:"2_4_2"}]},{title:"CW05",color:"#FFF",state:!1,key:"2_5",childrens:[{title:"左防水片",color:"#CBF3DD",state:!1,key:"2_5_1"},{title:"右防水片",color:"#FFF",state:!1,key:"2_5_2"}]}]},{title:"1层",childrens:[{title:"CW01",color:"#FFF",state:!1,key:"1_1",childrens:[{key:"1_1_1",title:"左防水片",color:"#FFF",state:!1},{key:"1_1_2",title:"右防水片",color:"#FFF",state:!1}]},{title:"CW02",color:"#FFF",state:!1,key:"1_2",childrens:[{key:"1_2_1",title:"左防水片",color:"#FFF",state:!1},{key:"1_2_2",title:"右防水片",color:"#FFF",state:!1}]},{title:"CW03",color:"#FFF",state:!1,key:"1_3",childrens:[{title:"左防水片",color:"#FEEDCA",state:!1,key:"1_3_1"},{title:"右防水片",color:"#FFF",state:!1,key:"1_3_2"}]},{title:"CW04",color:"#FFF",state:!1,key:"1_4",childrens:[{title:"左防水片",color:"#CBF3DD",state:!1,key:"1_4_1"},{title:"右防水片",color:"#CBF3DD",state:!1,key:"1_4_2"}]},{title:"CW05",color:"#FFF",state:!1,key:"1_5",childrens:[{title:"左防水片",color:"#CBF3DD",state:!1,key:"1_5_1"},{title:"右防水片",color:"#FFF",state:!1,key:"1_5_2"}]}]}],this.treeData=t.filter((t=>t))}},mounted(){this.loadData()}},w=o(1900),S=(0,w.Z)(C,l,[],!1,null,null,null);S.options.__file="components/lib/bpmSelectSection/src/part/dlgSelectSection.vue";var E=S.exports;r().use(e.Dialog);var D={name:"BpmSelectSection",components:{dlgSelectSection:E},props:{value:{type:[String,Array,Number]},fieldConf:{type:Object,default(){return{}}},row:{type:Object,default(){return{}}},mode:{type:String,default(){return"view"}},uiType:{type:String,default(){return"default"}},isMultiple:{type:Boolean,default(){return!1}}},data(){return{dlg:{show:!1},curVal:""}},computed:{},watch:{curVal(t){this.$emit("input",t),this.$emit("change",t)},value(){this.curVal=this.value}},mounted(){this.curVal=this.value},methods:{openSelectSectionDlg(){this.dlg.show=!0},colseSelectSectionDlg(){this.dlg.show=!1}}},k=(0,w.Z)(D,t,[],!1,null,null,null);k.options.__file="components/lib/bpmSelectSection/src/main.vue";var x=k.exports;x.install=function(t){t.component(x.name,x)};var T=x}(),n}()}));
@@ -0,0 +1 @@
1
+ /*! For license information please see index.umd.js.LICENSE.txt */