!function(){functione(t){returne="function"==typeofSymbol&&"symbol"==typeofSymbol.iterator?function(e){returntypeofe}:function(e){returne&&"function"==typeofSymbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeofe},e(t)}functiont(e,t){varn=Object.keys(e);if(Object.getOwnPropertySymbols){varr=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){returnObject.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}returnn}functionn(e){for(varn=1;n<arguments.length;n++){varr=null!=arguments[n]?arguments[n]:{};n%2?t(Object(r),!0).forEach((function(t){v(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):t(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}returne}functionr(e){returnfunction(e){if(Array.isArray(e))returno(e)}(e)||function(e){if("undefined"!=typeofSymbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])returnArray.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeofe)returno(e,t);varn=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)returnArray.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))returno(e,t)}(e)||function(){thrownewTypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}functiono(e,t){(null==t||t>e.length)&&(t=e.length);for(varn=0,r=newArray(t);n<t;n++)r[n]=e[n];returnr}functioni(){"use strict";/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */i=function(){returnt};vart={},n=Object.prototype,r=n.hasOwnProperty,o=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeofSymbol?Symbol:{},l=a.iterator||"@@iterator",c=a.asyncIterator||"@@asyncIterator",s=a.toStringTag||"@@toStringTag";functionu(e,t,n){returnObject.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{u({},"")}catch(j){u=function(e,t,n){returne[t]=n}}functiond(e,t,n,r){vari=t&&t.prototypeinstanceofm?t:m,a=Object.create(i.prototype),l=newF(r||[]);returno(a,"_invoke",{value:S(e,n,l)}),a}functionf(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(j){return{type:"throw",arg:j}}}t.wrap=d;varp={};functionm(){}functionh(){}functionv(){}vary={};u(y,l,(function(){returnthis}));varb=Object.getPrototypeOf,w=b&&b(b(C([])));w&&w!==n&&r.call(w,l)&&(y=w);varg=v.prototype=m.prototype=Object.create(y);functionx(e){["next","throw","return"].forEach((function(t){u(e,t,(function(e){returnthis._invoke(t,e)}))}))}functionE(t,n){functioni(o,a,l,c){vars=f(t[o],t,a);if("throw"!==s.type){varu=s.arg,d=u.value;returnd&&"object"==e(d)&&r.call(d,"__await")?n.resolve(d.__await).then((function(e){i("next",e,l,c)}),(function(e){i("throw",e,l,c)})):n.resolve(d).then((function(e){u.value=e,l(u)}),(function(e){returni("throw",e,l,c)}))}c(s.arg)}vara;o(this,"_invoke",{value:function(e,t){functionr(){returnnewn((function(n,r){i(e,t,n,r)}))}returna=a?a.then(r,r):r()}})}functionS(e,t,n){varr="suspendedStart";returnfunction(o,i){if("executing"===r)thrownewError("Generator is already running");if("completed"===r){if("throw"===o)throwi;returnL()}for(n.method=o,n.arg=i;;){vara=n.delegate;if(a){varl=k(a,n);if(l){if(l===p)continue;returnl}}if("next"===n.method)n.sent=n._sent=n.arg;elseif("throw"===n.method){if("suspendedStart"===r)throwr="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";varc=f(e,t,n);if("normal"===c.type){if(r=n.done?"completed":"suspendedYield",c.arg===p)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(r="completed",n.method="throw",n.arg=c.arg)}}}functionk(e,t){varn=t.method,r=e.iterator[n];if(void0===r)returnt.delegate=null,"throw"===n&&e.iterator.return&&(t.method="return",t.arg=void0,k(e,t),"throw"===t.method)||"return"!==n&&(t.method="throw",t.arg=newTypeError("The iterator does not provide a '"+n+"' method")),p;varo=f(r,e.iterator,t.arg);if("throw"===o.type)returnt.method="throw",t.arg=o.arg,t.delegate=null,p;vari=o.arg;returni?i.done?(t[e.resultName]=i.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void0),t.delegate=null,p):i:(t.method="throw",t.arg=newTypeError("iterator result is not an object"),t.delegate=null,p)}functionU(e){vart={tryLoc:e[0]};1ine&&(t.catchLoc=e[1]),2ine&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}functionO(e){vart=e.completion||{};t.type="normal",deletet.arg,e.completion=t}functionF(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(U,this),this.reset(!0)}functionC(e){if(e){vart=e[l];if(t)returnt.call(e);if("function"==typeofe.next)returne;if(!isNaN(e.length)){varn=-1,o=functiont(){for(;++n<e.length;)if(r.call(e,n))returnt.value=e[n],t.done=!1,t;returnt.value=void0,t.done=!0,t};returno.next=o}}return{next:L}}functionL(){return{value:void0,done:!0}}returnh.prototype=v,o(g,"constructor",{value:v,configurable:!0}),o(v,"constructor",{value:h,configurable:!0}),h.displayName=u(v,s,"GeneratorFunction"),t.isGeneratorFunction=function(e){vart="function"==typeofe&&e.constructor;return!!t&&(t===h||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){returnObject.setPrototypeOf?Object.setPrototypeOf(e,v):(e.__proto__=v,u(e,s,"GeneratorFunction")),e.prototype=Object.create(g),e},t.awrap=function(e){return{__await:e}},x(E.prototype),u(E.prototype,c,(function(){returnthis})),t.AsyncIterator=E,t.async=function(e,n,r,o,i){void0===i&&(i=Promise);vara=newE(d(e,n,r,o),i);returnt.isGeneratorFunction(n)?a:a.next().then((function(e){returne.done?e.value:a.next()}))},x(g),u(g,s,"Generator"),u(g,l,(function(){returnthis})),u(g,"toString",(function(){return"[object Generator]"})),t.keys=function(e){vart=Object(e),n=[];for(varrint)n.push(r);returnn.reverse(),functione(){for(;n.length;){varr=n.pop();if(rint)returne.value=r,e.done=!1,e}returne.done=!0,e}},t.values=C,F.prototype={constructor:F,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void0,this.done=!1,this.delegate=null,this.method="next",this.arg=void0,this.tryEntries.forEach(O),!e)for(vartinthis)"t"===t.charAt(0)&&r.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void0)},stop:function(){this.done=!0;vare=this.tryEntries[0].completion;if("throw"===e.type)throwe.arg;returnthis.rval},dispatchException:function(e){if(this.done)throwe;vart=this;functionn(n,r){returna.type="throw",a.arg=e,t.next=n,r&&(t.method="next",t.arg=void0),!!r}for(varo=this.tryEntries.length-1;o>=0;--o){vari=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)returnn("end");if(i.tryLoc<=this.prev){varl=r.call(i,"catchLoc"),c=r.call(i,"finallyLoc");if(l&&c){if(this.prev<i.catchLoc)returnn(i.catchLoc,!0);if(this.prev<i.finallyLoc)returnn(i.finallyLoc)}elseif(l){if(this.prev<i.catchLoc)returnn(i.catchLoc,!0)}else{if(!c)thrownewError("try statement without catch or finally");if(this.prev<i.finallyLoc)returnn(i.finallyLoc)}}}},abrupt:function(e,t){for(varn=this.tryEntries.length-1;n>=0;--n){varo=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){vari=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);vara=i?i.completion:{};returna.type=e,a.arg=t,i?(this.method="next",this.next=i.finallyLoc,p):this.complete(a)},complete:function(e,t){if("throw"===e.type)throwe.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),p},finish:function(e){for(vart=this.tryEntries.length-1;t>=0;--t){varn=this.tryEntries[t];if(n.finallyLoc===e)returnthis.complete(n.completion,n.afterLoc),O(n),p}},catch:function(e){for(vart=this.tryEntries.length-1;t>=0;--t){varn=this.tryEntries[t];if(n.tryLoc===e){varr=n.completion;if("throw"===r.type){varo=r.arg;O(n)}returno}}thrownewError("illegal catch attempt")},delegateYield:function(e,t,n){returnthis.delegate={iterator:C(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void0),p}},t}functiona(e,t,n,r,o,i,a){try{varl=e[i](a),c=l.value}catch(s){returnvoidn(s)}l.done?t(c):Promise.resolve(c).then(r,o)}functionl(e){returnfunction(){vart=this,n=arguments;returnnewPromise((function(r,o){vari=e.apply(t,n);functionl(e){a(i,r,o,l,c,"next",e)}functionc(e){a(i,r,o,l,c,"throw",e)}l(void0)}))}}functionc(e,t){if(!(einstanceoft))thrownewTypeError("Cannot call a class as a function")}functions(e,t){for(varn=0;n<t.length;n++){varr=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"inr&&(r.writable=!0),Object.defineProperty(e,y(r.key),r)}}functionu(e,t,n){returnt&&s(e.prototype,t),n&&s(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}functiond(e,t){returnd=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){returne.__proto__=t,e},d(e,t)}functionf(e){vart=function(){if("undefined"==typeofReflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeofProxy)return!0;try{returnBoolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();returnfunction(){varn,r=h(e);if(t){varo=h(this).constructor;n=Reflect.construct(r,arguments,o)}elsen=r.apply(this,arguments);returnp(this,n)}}functionp(t,n){if(n&&("object"===e(n)||"function"==typeofn))returnn;if(void0!==n)thrownewTypeError("Derived constructors may only return object or undefined");returnm(t)}functionm(e){if(void0===e)thrownewReferenceError("this hasn't been initialised - super() hasn't been called");returne}functionh(e){returnh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){returne.__proto__||Object.getPrototypeOf(e)},h(e)}functionv(e,t,n){return(t=y(t))ine?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}functiony(t){varn=function(t,n){if("object"!==e(t)||null===t)returnt;varr=t[Symbol.toPrimitive];if(void0!==r){varo=r.call(t,n||"default");if("object"!==e(o))returno;thrownewTypeError("@@toPrimitive must return a primitive value.")}return("string"===n?String:Number)(t)}(t,"string");return"symbol"===e(n)?n:String(n)}System.register(["@ibiz-template/controller","vue","@ibiz-template/vue-util","@ibiz-template/core","qx-util","@ibiz-template/runtime","@ibiz-template/model"],(function(e,t){"use strict";varo,a,s,p,h,y,b,w,g,x,E,S,k,U,O,F,C,L,j,P,T,N,I,D,_,M,R,V,z,A,G,W;return{setters:[function(e){o=e.GridFieldColumnController,a=e.GridRowController,s=e.WFStepTraceViewController,p=e.UploadEditorController},function(e){h=e.defineComponent,y=e.computed,b=e.h,w=e.getCurrentInstance,g=e.ref,x=e.watch,E=e.toRefs},function(e){S=e.useNamespace,k=e.useViewController,U=e.usePropsWatch,O=e.getUploadProps,F=e.getEditorEmits,C=e.getGridUploadProps,L=e.getGridEditorEmits,j=e.useClickOutside,P=e.useEventListener,T=e.useWFStepTraceViewController,N=e.useWFDynaEditView3Controller,I=e.useEditView3Controller},function(e){D=e.colorBlend,_=e.HttpError,M=e.isImage,R=e.uploadFile,V=e.RuntimeError},function(e){z=e.getCookie},function(e){A=e.ViewMode,G=e.PluginStaticResource},function(e){W=e.ViewType}],execute:function(){varq=h({name:"CodeListGridColumn",props:{controller:{type:o,required:!0},row:{type:a,required:!0}},setup:function(e){vart=S("grid-field-column"),n=y((function(){varn;if("FRONT"!==e.controller.model.source.cLConvertMode)return[];varr=e.row.data[e.controller.model.codeName];returnnull!==(n=e.controller.codeListItems)&&void0!==n&&n.length&&r?r.split(",").map((function(n){varr=e.controller.codeListItems.find((function(e){returne.value===n}));if(r){varo=r.color||"#515a6e";return{text:r.text,colorStyle:t.cssVarBlock({color:o,"border-color":o,"bg-color":D(o,"#fff")})}}})).filter(Boolean):[]})),r=y((function(){varn="";switch(e.controller.model.align){case"LEFT":n="flex-start";break;case"RIGHT":n="flex-end";break;default:n="center"}returnt.cssVarBlock({"justify-content":n})}));return{ns:t,alignStyle:r,selectedItems:n,onCellClick:function(t){e.controller.isLinkColumn&&e.controller.openLinkView(e.row,t)}}},render:function(){vare=this,t=this.controller,n=this.row.data[t.model.codeName];returnb("div",{class:[this.ns.b(),t.isLinkColumn&&this.ns.m("link-column")],style:this.alignStyle,on:{click:this.onCellClick}},[this.selectedItems.length>0?this.selectedItems.map((function(t){returnb("span",{class:e.ns.e("code-list-item"),style:t.colorStyle},[t.text])})):b("span",{class:this.ns.e("text")},[n])])}}),B=function(e){!function(e,t){if("function"!=typeoft&&null!==t)thrownewTypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&d(e,t)}(r,e);vart,n=f(r);functionr(){vare;c(this,r);for(vart=arguments.length,o=newArray(t),i=0;i<t;i++)o[i]=arguments[i];returnv(m(e=n.call.apply(n,[this].concat(o))),"imgSrc",void0),e}returnu(r,[{key:"getUIData",value:(t=l(i().mark((functione(){vart,n,r;returni().wrap((function(e){for(;;)switch(e.prev=e.next){case0:returnt=Object.assign(this.context.clone(),this.params),e.next=3,this.entityService.wf.getWFProcessDiagram(t);case3:n=e.sent,r=newBlob([n.data]),this.imgSrc=URL.createObjectURL(r);case6:case"end":returne.stop()}}),e,this)}))),function(){returnt.apply(this,arguments)})}]),r}(s),$=h({name:"PresetWFChartView",props:{context:Object,params:{type:Object},modelPath:{type:String,required:!0},modal:{type:Object},deName:{type:String,required:!0}},setup:function(e){vart=S("preset-wf-chart-view"),n=w().proxy,r=k(n,(function(t,n){returnnewB(e.modelPath,t,n)}));returnU(n,"deName",r.setDeName.bind(r)),{c:r,ns:t}},render:function(){returnb("div",{class:this.ns.b()},[b("img",{attrs:{src:this.c.imgSrc}})])}}),J=h({name:"WFToolbar",props:{wfLinks:{type:Array,required:!0}},setup:function(e,t){varn=t.emit,r=S("wf-toolbar"),o=function(){vare=l(i().mark((functione(t,r){returni().wrap((function(e){for(;;)switch(e.prev=e.next){case0:n("wf-link-click",t,r);case1:case"end":returne.stop()}}),e)})));returnfunction(t,n){returne.apply(this,arguments)}}();return{ns:r,handleClick:o}},render:function(){vare=this,t=this.wfLinks||[];returnb("div",{class:"".concat(this.ns.b())},[t.length>0&&t.map((function(t){varn="驳回"==t.sequenceFlowName||"取消"==t.sequenceFlowName;returnb("div",{key:t.sequenceFlowId,class:[e.ns.e("item"),n?e.ns.em("item","reject"):""]},[b("i-button",{attrs:{title:t.sequenceFlowName},on:{click:function(n){returne.handleClick(t,n)}}},[t.sequenceFlowName||""])])}))])}}),Y="function"==typeofbtoa,H="function"==typeofBuffer;"function"==typeofTextDecoder&&newTextDecoder;varK,Q="function"==typeofTextEncoder?newTextEncoder:void0,X=Array.prototype.slice.call("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=");K={},X.forEach((function(e,t){returnK[e]=t}));varZ=String.fromCharCode.bind(String);"function"==typeofUint8Array.from&&Uint8Array.from.bind(Uint8Array);varee=function(e){returne.replace(/=/g,"").replace(/[+\/]/g,(function(e){return"+"==e?"-":"_"}))},te=Y?function(e){returnbtoa(e)}:H?function(e){returnBuffer.from(e,"binary").toString("base64")}:function(e){for(vart,n,r,o,i="",a=e.length%3,l=0;l<e.length;){if((n=e.charCodeAt(l++))>255||(r=e.charCodeAt(l++))>255||(o=e.charCodeAt(l++))>255)thrownewTypeError("invalid character found");i+=X[(t=n<<16|r<<8|o)>>18&63]+X[t>>12&63]+X[t>>6&63]+X[63&t]}returna?i.slice(0,a-3)+"===".substring(a):i},ne=H?function(e){returnBuffer.from(e).toString("base64")}:function(e){for(vart=[],n=0,r=e.length;n<r;n+=4096)t.push(Z.apply(null,e.subarray(n,n+4096)));returnte(t.join(""))},re=function(e){if(e.length<2)return(t=e.charCodeAt(0))<128?e:t<2048?Z(192|t>>>6)+Z(128|63&t):Z(224|t>>>12&15)+Z(128|t>>>6&63)+Z(128|63&t);vart=65536+1024*(e.charCodeAt(0)-55296)+(e.charCodeAt(1)-56320);returnZ(240|t>>>18&7)+Z(128|t>>>12&63)+Z(128|t>>>6&63)+Z(128|63&t)},oe=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,ie=H?function(e){returnBuffer.from(e,"utf8").toString("base64")}:Q?function(e){returnne(Q.encode(e))}:function(e){returnte(e.replace(oe,re))},ae=function(e){vart=arguments.length>1&&void0!==arguments[1]&&arguments[1];returnt?ee(ie(e)):ie(e)};varle=h({name:"SyFileUpload",props:O(),emits:F(),setup:function(e,t){varn=t.emit,o=S("sy-file-upload"),i=e.controller,a=function(e,t,n){varo=g([]),i=g({Authorization:"Bearer ".concat(z("access_token"))}),a=g(""),l=g(""),c={count:0,cacheFiles:[]};x((function(){returne.value}),(function(e){o.value=e?JSON.parse(e):[]}),{immediate:!0}),x((function(){returne.data}),(function(e){if(e){vart=n.calcBaseUrl(e);a.value=t.uploadUrl,l.value=t.downloadUrl}}),{immediate:!0,deep:!0}),x(o,(function(e){null!=e&&e.length&&l.value&&e.forEach((function(e){e.url=e.url||l.value.replace("%fileId%",e.id)}))}),{immediate:!0}),x(l,(function(e){e&&o.value.length&&o.value.forEach((function(e){e.url=l.value.replace("%fileId%",e.id)}))}),{immediate:!0});vars=function(){vare=[].concat(r(o.value),r(c.cacheFiles)),n=e.length>0?JSON.stringify(e.map((function(e){return{name:e.name,id:e.id}}))):null;c.cacheFiles=[],t(n)},u=g(!1),d=g(""),f=g("");return{uploadUrl:a,downloadUrl:l,headers:i,files:o,onDownload:function(e){vart=e.url||l.value.replace("%fileId%",e.id);n.fileDownload({url:t,name:e.name})},onError:function(e,t){throwc.count-=1,new_({response:{data:t,status:e.status}})},onRemove:function(t){if(!e.disabled){varn=o.value.findIndex((function(e){returne.id===t.id}));-1!==n&&o.value.splice(n,1),s()}},onSuccess:function(e){e&&(c.cacheFiles.push({name:e.filename,id:e.fileid}),c.count-=1,0===c.count&&s())},beforeUpload:function(e){vart=e.name.trim().toLowerCase();if(["html","js","exe","sh"].some((function(e){returnt.endsWith(".".concat(e))})))returnibiz.message.error("不可上传 html、js、 exe、sh类型的文件!"),!1;c.count+=1},showModal:u,modalTitle:d,iframeUrl:f,onModalCancel:function(){u.value=!1,d.value="",f.value=""},previewFile:function(e){u.value=!0,d.value=e.name;vart=window.Environment.previewFileUrl;if(t){varn=encodeURIComponent(ae("".concat(window.location.origin).concat(e.url,"?fullfilename=").concat(e.name)));f.value="".concat(t,"/onlinePreview?url=").concat(n)}}}}(e,(function(e){n("change",e)}),i);return{ns:o,c:i,uploadUrl:a.uploadUrl,headers:a.headers,files:a.files,onDownload:a.onDownload,onError:a.onError,onRemove:a.onRemove,onSuccess:a.onSuccess,beforeUpload:a.beforeUpload,showModal:a.showModal,modalTitle:a.modalTitle,iframeUrl:a.iframeUrl,onModalCancel:a.onModalCancel,previewFile:a.previewFile}},render:function(e){vart=this;returne("div",{class:[this.ns.b(),this.disabled?this.ns.m("disabled"):"",this.readonly?this.ns.m("readonly"):""]},[e("IUpload",{ref:"fileUpload",props:{action:this.uploadUrl,headers:this.headers,disabled:this.disabled,"default-file-list":this.files,multiple:this.c.model.multiple,type:this.c.model.isDrag?"drag":"select",accept:this.c.model.accept,"before-upload":this.beforeUpload,"on-success":this.onSuccess,"on-error":this.onError,"on-remove":this.onRemove,"on-preview":this.onDownload,"show-upload-list":!1}},[this.c.model.isDrag?e("div",{class:this.ns.bm("box","drag")},[e("i-icon",{attrs:{type:"md-cloud-upload"}}),e("div",{class:this.ns.be("box","title")},[e("span",["将文件拖到此处,或"]),e("span",["点击上传"])])]):e("i-button",{attrs:{icon:"ios-cloud-upload-outline"},class:this.ns.bm("box","select")},["上传文件"])]),e("div",{class:this.ns.b("file-list")},[this.files.map((function(n){returne("div",{class:t.ns.b("file-item"),key:n.id},[e("div",{class:t.ns.b("file-item-left")},[e("i-icon",{attrs:{type:"md-document"}})]),e("div",{class:t.ns.b("file-item-right")},[e("div",{class:t.ns.b("file-item-right-title"),on:{click:function(){returnt.previewFile(n)}}},[n.name]),e("div",{class:t.ns.b("file-item-right-action")},[e("i-icon",{attrs:{type:"md-download"},on:{click:function(){returnt.onDownload(n)}}}),e("i-icon",{attrs:{type:"md-eye"},on:{click:function(){returnt.previewFile(n)}}}),t.disabled||t.readonly?null:e("i-icon",{attrs:{type:"md-close"},on:{click:function(){returnt.onRemove(n)}}})])])])}))]),e("i-modal",{attrs:{value:this.showModal,title:this.modalTitle,"class-name":this.ns.b("modal"),width:"70%",transfer:!1,"footer-hide":!0},on:{"on-cancel":this.onModalCancel}},[e("iframe",{class:this.ns.b("iframe"),attrs:{src:this.iframeUrl}})])])}});functionce(e,t){if(e.url=t.replace("%fileId%",e.id),e.status||(e.status="finished"),!e.fileName){varn=e.name.lastIndexOf(".");e.fileName=e.name.substring(0,n),e.fileExt=e.name.substring(n),e.isImage=M(e.name)}returne}functionse(e){vart=g(""),n=g(""),r=g([]);returnx(e.data,(function(r){if(r){varo=e.controller.value.calcBaseUrl(r);t.value=o.uploadUrl,n.value=o.downloadUrl}}),{immediate:!0,deep:!0}),x(e.value,(function(e){r.value=e?JSON.parse(e):[],r.value.length&&n.value&&r.value.forEach((function(e){ce(e,n.value)}))}),{immediate:!0}),x(n,(function(e){e&&r.value.length&&r.value.forEach((function(t){ce(t,e)}))}),{immediate:!0}),{downloadUrl:n,uploadUrl:t,valueList:r}}functionue(e){vart=g("undo"),n=g([]),r=e.downloadUrl,o=e.value,i=e.uploadUrl;x(o,(function(e){e.length>0&&(n.value=[],e.forEach((function(e){n.value.push(ce(e,r.value))})))}),{immediate:!0,deep:!0});vara=function(e,t){varr=["html","js","exe","sh"],o=[];returnt.forEach((function(e,t){vari=e.name.trim().toLowerCase();r.some((function(e){returni.endsWith(".".concat(e))}))?o.push(t):n.value.push({name:e.name,status:e.status,percentage:e.percentage,id:e.uid,url:""})})),o.length===t.length?(ibiz.message.error("不可上传 html、js、 exe、sh类型的文件!"),!1):(o.length&&(o.forEach((function(n){e.splice(n,1),t.splice(n,1)})),ibiz.message.error("不可上传 html、js、 exe、sh类型的文件!")),!0)},l=function(e){e.forEach((function(e){n.value.find((function(t){returnt.id===e.uid&&(t.percentage=e.percentage,!0)}))}))},c=function(e,t){e.forEach((function(e){n.value.find((function(n){returnn.id===e.uid&&(n.status=e.status,n.id=t.data.fileid,n.name=t.data.filename,ce(n,r.value),!0)}))}))},s=function(e,t){varr;e.forEach((function(e){n.value.find((function(t){returnt.id===e.uid&&(t.status=e.status,!0)}))}));varo=new_(t);ibiz.notification.error({title:null===(r=o.status)||void0===r?void0:r.toString(),desc:o.message,duration:10})},u=function(e){n.value=n.value.filter((function(e){return"finished"===e.status})),t.value="done"},d=g(!1),f=g(""),p=g("");return{selectFile:function(){R({multiple:e.multiple,accept:e.accept,uploadUrl:i.value,beforeUpload:a,progress:l,success:c,error:s,finish:u})},fileList:n,uploadState:t,showModal:d,modalTitle:f,iframeUrl:p,onModalCancel:function(){d.value=!1,f.value="",p.value=""},previewFile:function(e){d.value=!0,f.value=e.name;vart=window.Environment.previewFileUrl;if(t){varn=encodeURIComponent(ae("".concat(window.location.origin).concat(e.url,"?fullfilename=").concat(e.name)));p.value="".concat(t,"/onlinePreview?url=").concat(n)}}}}varde=h({name:"SyGridFileUpload",props:C(),setup:function(e){vart=S("sy-grid-file-upload"),n=E(e),r=se({value:n.value,data:n.data,controller:n.controller}),o=ue({downloadUrl:r.downloadUrl,uploadUrl:r.uploadUrl,value:r.valueList});return{ns:t,fileList:o.fileList,showModal:o.showModal,modalTitle:o.modalTitle,iframeUrl:o.iframeUrl,downloadFile:function(t){e.controller.fileDownload(t)},previewFile:o.previewFile,onModalCancel:o.onModalCancel}},render:function(){vare=this;returnb("grid-editor",{attrs:{disabled:this.disabled,readonly:this.readonly},class:[this.ns.b(),this.disabled?this.ns.m("disabled"):"",this.readonly?this.ns.m("readonly"):""]},[b("div",{class:this.ns.b("file-list")},[this.fileList.map((function(t){returnb("div",{class:e.ns.b("file-item"),key:t.id},[b("div",{class:e.ns.b("file-item-title"),on:{click:function(){returne.previewFile(t)}}},[t.name]),b("div",{class:e.ns.b("file-item-action")},[b("i-icon",{attrs:{type:"md-download"},on:{click:function(){returne.downloadFile(t)}}}),b("i-icon",{attrs:{type:"md-eye"},on:{click:function(){returne.previewFile(t)}}})])])}))]),b("i-modal",{attrs:{value:this.showModal,title:this.modalTitle,"class-name":this.ns.b("modal"),width:"70%",transfer:!1,"footer-hide":!0},on:{"on-cancel":this.onModalCancel}},[b("iframe",{class:this.ns.b("iframe"),attrs:{src:this.iframeUrl}})])])}}),fe=h({name:"SyGridFileUploadContainer",props:C(),emits:L(),render:function(e){vart=this;returnthis.disabled||this.readonly?e("SyGridFileUpload",{props:n({},this.$props)}):e("SyEditGridFileUpload",{props:n({},this.$props),on:{change:function(e,n){t.$emit("change",e,n)},rowSave:function(){t.$emit("rowSave")}}})}}),pe=h({name:"SyEditGridFileUploadPopover",props:{uploadUrl:{type:String,required:!0},downloadUrl:{type:String,required:!0},value:{type:Array,required:!0},controller:{type:p,required:!0}},emits:{close:function(e){return!0}},setup:function(e,t){varn=t.emit,r=S("sy-edit-grid-file-upload-popover"),o=E(e),a=ue({downloadUrl:o.downloadUrl,value:o.value,uploadUrl:o.uploadUrl}),c=a.fileList,s=a.uploadState,u=a.selectFile,d=g(),f=g(!1),p=j(d,function(){vare=l(i().mark((functione(t){returni().wrap((function(e){for(;;)switch(e.prev=e.next){case0:n("close",{isModified:f.value,resultFiles:c.value});case1:case"end":returne.stop()}}),e)})));returnfunction(t){returne.apply(this,arguments)}}());x(s,(function(e){"done"===e?(f.value=!0,p.proceed()):"loading"===e&&p.pause()}));return{ns:r,componentRef:d,fileList:c,deleteFile:function(e){vart=c.value.findIndex((function(t){returnt.id===e.id}));c.value.splice(t,1),f.value=!0},selectFile:u,downloadFile:function(t){e.controller.fileDownload(t)}}},render:function(){vare=this;returnb("div",{ref:"componentRef",style:"width:300px",class:this.ns.b()},[b("div",{class:this.ns.b("file-list")},[this.fileList.map((function(t){returnb("div",{class:e.ns.b("file-item"),key:t.id},[b("div",{class:e.ns.b("file-item-title"),on:{click:function(){returne.downloadFile(t)}}},[t.name]),b("div",{class:e.ns.b("file-item-action")},[b("i-icon",{attrs:{type:"md-close"},on:{click:function(){returne.deleteFile(t)}}})])])}))]),b("div",{on:{click:function(){returne.selectFile()}},class:this.ns.e("button")},[b("i-icon",{attrs:{type:"md-add"}}),"添加文件"])])}}),me=h({name:"SyEditGridFileUpload",props:C(),emits:L(),setup:function(e,t){varn=t.emit,r=S("sy-edit-grid-file-upload"),o=E(e),a=o.value,c=o.data,s=o.controller,u=se({value:a,data:c,controller:s}),d=u.downloadUrl,f=u.uploadUrl,p=u.valueList,m=g(),h=function(){vare=l(i().mark((functione(){vart,r,o,a,l,c,u;returni().wrap((function(e){for(;;)switch(e.prev=e.next){case0:if(m.value){e.next=2;break}thrownewV("容器元素不存在");case2:returnt=m.value.$el,r=t.offsetHeight,o=ibiz.overlay.createPopover((function(e){returne(pe,{props:{value:p.value,uploadUrl:f.value,downloadUrl:d.value,controller:s.value},on:{close:function(e){o.dismiss(e)}}})}),void0,{noArrow:!0,placement:"bottom-start",offsetOpts:{mainAxis:-r,crossAxis:0}}),e.next=7,o.present(t);case7:returne.next=9,o.onWillDismiss();case9:a=e.sent,l=a.isModified,c=a.resultFiles,l&&(u=c.length>0?JSON.stringify(c.map((function(e){return{name:e.name,id:e.id}}))):null,n("change",u),n("rowSave"));case13:case"end":returne.stop()}}),e)})));returnfunction(){returne.apply(this,arguments)}}();returnP(m,"click",(function(t){e.disabled||h()})),{ns:r,valueList:p,componentRef:m}},render:function(){vare=this;returnb("grid-editor",{attrs:{disabled:this.disabled,readonly:this.readonly},ref:"componentRef",class:this.ns.b()},[b("div",{class:this.ns.b("file-list")},[this.valueList.map((function(t){returnb("div",{class:e.ns.b("file-item"),key:t.id},[b("div",{class:e.ns.b("file-item-title")},[t.name])])}))])])}}),he=u((functione(){c(this,e),v(this,"component",$)})),ve=function(){functione(){c(this,e),v(this,"component",q)}vart;returnu(e,[{key:"createController",value:(t=l(i().mark((functione(t,n){varr;returni().wrap((function(e){for(;;)switch(e.prev=e.next){case0:returnr=newo(t,n),e.next=3,r.init();case3:returne.abrupt("return",r);case4:case"end":returne.stop()}}),e)}))),function(e,n){returnt.apply(this,arguments)})}]),e}(),ye=u((functione(){c(this,e),v(this,"component","IndexView")})),be=h({name:"WFStepTraceGrid",props:{context:Object,params:{type:Object},modelPath:{type:String,required:!0},modal:{type:Object},deName:{type:String,required:!0}},setup:function(e){vart=w().proxy,n=T(t,e.modelPath);U(t,"deName",n.setDeName.bind(n));varr=S("wf-step-trace-grid"),o=g([]);n.nerve.self.evt.on("mounted",(function(){vare;n.data&&(null===(e=n.data.usertasks)||void0===e||e.forEach((function(e){e.identitylinks.length>0||(e.comments.length>0&&e.comments.forEach((function(t){o.value.push({nodeName:e.userTaskName,personName:t.authorName,time:t.time,content:t.type,comment:t.fullMessage})})),o.value.sort((function(e,t){returnDate.parse(t.time)-Date.parse(e.time)})))})))}));vari=g([{title:"处理环节",key:"nodeName",width:180,resizable:!0},{title:"处理人",key:"personName",width:180,resizable:!0},{title:"处理时间",key:"time",width:180,resizable:!0},{title:"处理内容",key:"content",width:180,resizable:!0},{title:"处理意见",key:"comment"}]);return{c:n,ns:r,gridData:o,columns:i}},render:function(){returnb("div",{class:this.ns.b()},[b("div",{class:this.ns.e("title")},["审批信息"]),b("i-table",{attrs:{"disabled-hover":!0,columns:this.columns,data:this.gridData},class:this.ns.e("grid")})])}}),we=h({props:{context:Object,params:{type:Object},modelPath:{type:String,required:!0},modal:{type:Object}},setup:function(e){vart=w().proxy,n=N(t,e.modelPath),r=S("view-".concat(W.DE_WF_DYNA_EDIT_VIEW3).toLowerCase()),o=g(["mainForm"]);return{c:n,ns:r,onTabClick:function(e){o.value.includes(e)||o.value.push(e)},lazyList:o}},render:function(e){vart=this,n=[];if(this.c.complete){varr=this.c.activeForm;r&&this.c.providers[r.name]&&n.push(e(this.c.providers[r.name].component,{props:{modelData:r,context:this.c.context,params:this.c.params},style:{height:"auto"},on:{neuronInit:this.c.nerve.onNeuronInit("form")}}))}if(this.c.complete&&this.c.model.drTab.pages[0]){varo=this.c.model.drTab.pages[0],i=this.c.drPages[o.source.name];n.push(e(be,{attrs:{context:i.context,params:i.params,deName:this.c.model.appEntity.source.codeName,modal:this.modal,modelPath:o.embedView.source.modelPath}}))}returne("view-base",{attrs:{controller:this.c},scopedSlots:{toolbar:function(){returnt.c.complete?[t.c.wfLinks.length>0&&e("wf-toolbar",{attrs:{wfLinks:t.c.wfLinks},on:{"wf-link-click":function(e){t.c.onLinkClick(e)}}})]:null}}},[this.c.complete&&e("i-tabs",{class:[this.ns.be("","tab")],attrs:{name:this.c.model.drTab.source.name},on:{"on-click":this.onTabClick}},[e("i-tab-pane",{class:this.ns.be("","tab-item"),attrs:{tab:this.c.model.drTab.source.name,label:this.c.model.drTab.source.editItemCaption,name:"mainForm"}},[n]),this.c.model.drTab.pages.map((function(n){varr=t.c.drPages[n.source.name];returne("i-tab-pane",{class:t.ns.be("","tab-item"),attrs:{tab:t.c.model.drTab.source.name,disabled:t.c.isNewData,label:n.source.caption,name:n.source.name}},[!t.c.isNewData&&t.lazyList.includes(n.source.name)&&e("ViewShell",{props:{context:r.context,params:r.params,modal:{mode:A.EMBED},modelPath:n.embedView.source.modelPath,deName:t.c.model.appEntity.source.codeName},on:{neuronInit:t.c.nerve.onNeuronInit(n.source.name)},key:r.key})])}))])])}}),ge=u((functione(){c(this,e),v(this,"component",we)})),xe=h({name:"SyEditView3",props:{context:Object,params:{type:Object},modelPath:{type:String,required:!0},modal:{type:Object}},setup:function(e){vart=w().proxy,n=I(t,e.modelPath),r=S("view-deeditview3"),o=g(["mainForm"]);return{c:n,ns:r,onTabClick:function(e){o.value.includes(e)||o.value.push(e)},lazyList:o}},render:function(e){vart=this;returne("view-base",{attrs:{controller:this.c}},[this.c.complete&&e("i-tabs",{class:[this.ns.be("","tab")],attrs:{name:this.c.model.drTab.source.name},on:{"on-click":this.onTabClick}},[e("i-tab-pane",{class:this.ns.be("","tab-item"),attrs:{tab:this.c.model.drTab.source.name,label:this.c.model.drTab.source.editItemCaption,name:"mainForm"}},[e("edit-form-control",{attrs:{modelData:this.c.model.form,context:this.c.context,params:this.c.params},style:{height:"auto"},on:{neuronInit:this.c.nerve.onNeuronInit(this.c.model.form.source.name)}}),e(be,{attrs:{context:this.c.drPages[this.c.model.drTab.pages[0].source.name].context,params:this.c.drPages[this.c.model.drTab.pages[0].source.name].params,deName:this.c.model.appEntity.source.codeName,modal:this.modal,modelPath:this.c.model.drTab.pages[0].embedView.source.modelPath}})]),this.c.model.drTab.pages.map((function(n){varr=t.c.drPages[n.source.name];if(r)returne("i-tab-pane",{class:t.ns.be("","tab-item"),attrs:{tab:t.c.model.drTab.source.name,disabled:t.c.isNewData,label:n.source.caption,name:n.source.name}},[!t.c.isNewData&&t.lazyList.includes(n.source.name)&&e("ViewShell",{attrs:{context:r.context,params:r.params,modal:{mode:A.EMBED},modelPath:n.embedView.source.modelPath,deName:t.c.model.appEntity.source.codeName},on:{neuronInit:t.c.nerve.onNeuronInit(n.source.name)},key:r.key})])}))])])}}),Ee=u((functione(){c(this,e),v(this,"component",xe)})),Se=function(){functione(){c(this,e),v(this,"formEditor","SyFileUpload"),v(this,"gridEditor","SyGridFileUploadContainer")}vart;returnu(e,[{key:"createController",value:(t=l(i().mark((functione(t,n){varr;returni().wrap((function(e){for(;;)switch(e.prev=e.next){case0:returnr=newp(t,n),e.next=3,r.init();case3:returne.abrupt("return",r);case4:case"end":returne.stop()}}),e)}))),function(e,n){returnt.apply(this,arguments)})}]),e}(),ke=newG(t.meta.url);e("default",{mateUrl:t.meta.url,install:function(e){ke.loadStyle(["/style.css"]),ibiz.config.enableDataInfoBar=!1,ibiz.config.gridEditShowMode="all",e.component("WfToolbar",J),ibiz.register.view.register("VIEW_CUSTOM_SyWebIndexView",newye),ibiz.register.view.register("VIEW_CUSTOM_PresetWFChartView",newhe),ibiz.register.gridColumn.register("GRID_COLRENDER_CodeListGridColumn",newve),ibiz.register.view.register("VIEW_CUSTOM_SyWfDynaEditView3",newge),ibiz.register.view.register("VIEW_CUSTOM_SyEditView3",newEe),e.component("SyFileUpload",le),e.component("SyGridFileUpload",de),e.component("SyEditGridFileUpload",me),e.component("SyGridFileUploadContainer",fe),ibiz.register.editor.register("EDITOR_CUSTOMSTYLE_SyFileUpload",newSe)}})}}}))}();
!function(){functione(t){returne="function"==typeofSymbol&&"symbol"==typeofSymbol.iterator?function(e){returntypeofe}:function(e){returne&&"function"==typeofSymbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeofe},e(t)}functiont(e,t){varn=Object.keys(e);if(Object.getOwnPropertySymbols){varr=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){returnObject.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}returnn}functionn(e){for(varn=1;n<arguments.length;n++){varr=null!=arguments[n]?arguments[n]:{};n%2?t(Object(r),!0).forEach((function(t){v(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):t(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}returne}functionr(e){returnfunction(e){if(Array.isArray(e))returno(e)}(e)||function(e){if("undefined"!=typeofSymbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])returnArray.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeofe)returno(e,t);varn=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)returnArray.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))returno(e,t)}(e)||function(){thrownewTypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}functiono(e,t){(null==t||t>e.length)&&(t=e.length);for(varn=0,r=newArray(t);n<t;n++)r[n]=e[n];returnr}functioni(){"use strict";/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */i=function(){returnt};vart={},n=Object.prototype,r=n.hasOwnProperty,o=Object.defineProperty||function(e,t,n){e[t]=n.value},a="function"==typeofSymbol?Symbol:{},l=a.iterator||"@@iterator",c=a.asyncIterator||"@@asyncIterator",s=a.toStringTag||"@@toStringTag";functionu(e,t,n){returnObject.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{u({},"")}catch(j){u=function(e,t,n){returne[t]=n}}functiond(e,t,n,r){vari=t&&t.prototypeinstanceofm?t:m,a=Object.create(i.prototype),l=newF(r||[]);returno(a,"_invoke",{value:S(e,n,l)}),a}functionf(e,t,n){try{return{type:"normal",arg:e.call(t,n)}}catch(j){return{type:"throw",arg:j}}}t.wrap=d;varp={};functionm(){}functionh(){}functionv(){}vary={};u(y,l,(function(){returnthis}));varb=Object.getPrototypeOf,w=b&&b(b(C([])));w&&w!==n&&r.call(w,l)&&(y=w);varg=v.prototype=m.prototype=Object.create(y);functionx(e){["next","throw","return"].forEach((function(t){u(e,t,(function(e){returnthis._invoke(t,e)}))}))}functionE(t,n){functioni(o,a,l,c){vars=f(t[o],t,a);if("throw"!==s.type){varu=s.arg,d=u.value;returnd&&"object"==e(d)&&r.call(d,"__await")?n.resolve(d.__await).then((function(e){i("next",e,l,c)}),(function(e){i("throw",e,l,c)})):n.resolve(d).then((function(e){u.value=e,l(u)}),(function(e){returni("throw",e,l,c)}))}c(s.arg)}vara;o(this,"_invoke",{value:function(e,t){functionr(){returnnewn((function(n,r){i(e,t,n,r)}))}returna=a?a.then(r,r):r()}})}functionS(e,t,n){varr="suspendedStart";returnfunction(o,i){if("executing"===r)thrownewError("Generator is already running");if("completed"===r){if("throw"===o)throwi;returnL()}for(n.method=o,n.arg=i;;){vara=n.delegate;if(a){varl=k(a,n);if(l){if(l===p)continue;returnl}}if("next"===n.method)n.sent=n._sent=n.arg;elseif("throw"===n.method){if("suspendedStart"===r)throwr="completed",n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r="executing";varc=f(e,t,n);if("normal"===c.type){if(r=n.done?"completed":"suspendedYield",c.arg===p)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(r="completed",n.method="throw",n.arg=c.arg)}}}functionk(e,t){varn=t.method,r=e.iterator[n];if(void0===r)returnt.delegate=null,"throw"===n&&e.iterator.return&&(t.method="return",t.arg=void0,k(e,t),"throw"===t.method)||"return"!==n&&(t.method="throw",t.arg=newTypeError("The iterator does not provide a '"+n+"' method")),p;varo=f(r,e.iterator,t.arg);if("throw"===o.type)returnt.method="throw",t.arg=o.arg,t.delegate=null,p;vari=o.arg;returni?i.done?(t[e.resultName]=i.value,t.next=e.nextLoc,"return"!==t.method&&(t.method="next",t.arg=void0),t.delegate=null,p):i:(t.method="throw",t.arg=newTypeError("iterator result is not an object"),t.delegate=null,p)}functionU(e){vart={tryLoc:e[0]};1ine&&(t.catchLoc=e[1]),2ine&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}functionO(e){vart=e.completion||{};t.type="normal",deletet.arg,e.completion=t}functionF(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(U,this),this.reset(!0)}functionC(e){if(e){vart=e[l];if(t)returnt.call(e);if("function"==typeofe.next)returne;if(!isNaN(e.length)){varn=-1,o=functiont(){for(;++n<e.length;)if(r.call(e,n))returnt.value=e[n],t.done=!1,t;returnt.value=void0,t.done=!0,t};returno.next=o}}return{next:L}}functionL(){return{value:void0,done:!0}}returnh.prototype=v,o(g,"constructor",{value:v,configurable:!0}),o(v,"constructor",{value:h,configurable:!0}),h.displayName=u(v,s,"GeneratorFunction"),t.isGeneratorFunction=function(e){vart="function"==typeofe&&e.constructor;return!!t&&(t===h||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){returnObject.setPrototypeOf?Object.setPrototypeOf(e,v):(e.__proto__=v,u(e,s,"GeneratorFunction")),e.prototype=Object.create(g),e},t.awrap=function(e){return{__await:e}},x(E.prototype),u(E.prototype,c,(function(){returnthis})),t.AsyncIterator=E,t.async=function(e,n,r,o,i){void0===i&&(i=Promise);vara=newE(d(e,n,r,o),i);returnt.isGeneratorFunction(n)?a:a.next().then((function(e){returne.done?e.value:a.next()}))},x(g),u(g,s,"Generator"),u(g,l,(function(){returnthis})),u(g,"toString",(function(){return"[object Generator]"})),t.keys=function(e){vart=Object(e),n=[];for(varrint)n.push(r);returnn.reverse(),functione(){for(;n.length;){varr=n.pop();if(rint)returne.value=r,e.done=!1,e}returne.done=!0,e}},t.values=C,F.prototype={constructor:F,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=void0,this.done=!1,this.delegate=null,this.method="next",this.arg=void0,this.tryEntries.forEach(O),!e)for(vartinthis)"t"===t.charAt(0)&&r.call(this,t)&&!isNaN(+t.slice(1))&&(this[t]=void0)},stop:function(){this.done=!0;vare=this.tryEntries[0].completion;if("throw"===e.type)throwe.arg;returnthis.rval},dispatchException:function(e){if(this.done)throwe;vart=this;functionn(n,r){returna.type="throw",a.arg=e,t.next=n,r&&(t.method="next",t.arg=void0),!!r}for(varo=this.tryEntries.length-1;o>=0;--o){vari=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)returnn("end");if(i.tryLoc<=this.prev){varl=r.call(i,"catchLoc"),c=r.call(i,"finallyLoc");if(l&&c){if(this.prev<i.catchLoc)returnn(i.catchLoc,!0);if(this.prev<i.finallyLoc)returnn(i.finallyLoc)}elseif(l){if(this.prev<i.catchLoc)returnn(i.catchLoc,!0)}else{if(!c)thrownewError("try statement without catch or finally");if(this.prev<i.finallyLoc)returnn(i.finallyLoc)}}}},abrupt:function(e,t){for(varn=this.tryEntries.length-1;n>=0;--n){varo=this.tryEntries[n];if(o.tryLoc<=this.prev&&r.call(o,"finallyLoc")&&this.prev<o.finallyLoc){vari=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);vara=i?i.completion:{};returna.type=e,a.arg=t,i?(this.method="next",this.next=i.finallyLoc,p):this.complete(a)},complete:function(e,t){if("throw"===e.type)throwe.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),p},finish:function(e){for(vart=this.tryEntries.length-1;t>=0;--t){varn=this.tryEntries[t];if(n.finallyLoc===e)returnthis.complete(n.completion,n.afterLoc),O(n),p}},catch:function(e){for(vart=this.tryEntries.length-1;t>=0;--t){varn=this.tryEntries[t];if(n.tryLoc===e){varr=n.completion;if("throw"===r.type){varo=r.arg;O(n)}returno}}thrownewError("illegal catch attempt")},delegateYield:function(e,t,n){returnthis.delegate={iterator:C(e),resultName:t,nextLoc:n},"next"===this.method&&(this.arg=void0),p}},t}functiona(e,t,n,r,o,i,a){try{varl=e[i](a),c=l.value}catch(s){returnvoidn(s)}l.done?t(c):Promise.resolve(c).then(r,o)}functionl(e){returnfunction(){vart=this,n=arguments;returnnewPromise((function(r,o){vari=e.apply(t,n);functionl(e){a(i,r,o,l,c,"next",e)}functionc(e){a(i,r,o,l,c,"throw",e)}l(void0)}))}}functionc(e,t){if(!(einstanceoft))thrownewTypeError("Cannot call a class as a function")}functions(e,t){for(varn=0;n<t.length;n++){varr=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"inr&&(r.writable=!0),Object.defineProperty(e,y(r.key),r)}}functionu(e,t,n){returnt&&s(e.prototype,t),n&&s(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}functiond(e,t){returnd=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){returne.__proto__=t,e},d(e,t)}functionf(e){vart=function(){if("undefined"==typeofReflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeofProxy)return!0;try{returnBoolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();returnfunction(){varn,r=h(e);if(t){varo=h(this).constructor;n=Reflect.construct(r,arguments,o)}elsen=r.apply(this,arguments);returnp(this,n)}}functionp(t,n){if(n&&("object"===e(n)||"function"==typeofn))returnn;if(void0!==n)thrownewTypeError("Derived constructors may only return object or undefined");returnm(t)}functionm(e){if(void0===e)thrownewReferenceError("this hasn't been initialised - super() hasn't been called");returne}functionh(e){returnh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){returne.__proto__||Object.getPrototypeOf(e)},h(e)}functionv(e,t,n){return(t=y(t))ine?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}functiony(t){varn=function(t,n){if("object"!==e(t)||null===t)returnt;varr=t[Symbol.toPrimitive];if(void0!==r){varo=r.call(t,n||"default");if("object"!==e(o))returno;thrownewTypeError("@@toPrimitive must return a primitive value.")}return("string"===n?String:Number)(t)}(t,"string");return"symbol"===e(n)?n:String(n)}System.register(["@ibiz-template/controller","vue","@ibiz-template/vue-util","@ibiz-template/core","qx-util","@ibiz-template/runtime","@ibiz-template/model"],(function(e,t){"use strict";varo,a,s,p,h,y,b,w,g,x,E,S,k,U,O,F,C,L,j,P,T,N,I,D,_,M,R,V,z,A,G,W;return{setters:[function(e){o=e.GridFieldColumnController,a=e.GridRowController,s=e.WFStepTraceViewController,p=e.UploadEditorController},function(e){h=e.defineComponent,y=e.computed,b=e.h,w=e.getCurrentInstance,g=e.ref,x=e.watch,E=e.toRefs},function(e){S=e.useNamespace,k=e.useViewController,U=e.usePropsWatch,O=e.getUploadProps,F=e.getEditorEmits,C=e.getGridUploadProps,L=e.getGridEditorEmits,j=e.useClickOutside,P=e.useEventListener,T=e.useWFStepTraceViewController,N=e.useWFDynaEditView3Controller,I=e.useEditView3Controller},function(e){D=e.colorBlend,_=e.HttpError,M=e.isImage,R=e.uploadFile,V=e.RuntimeError},function(e){z=e.getCookie},function(e){A=e.ViewMode,G=e.PluginStaticResource},function(e){W=e.ViewType}],execute:function(){varq=h({name:"CodeListGridColumn",props:{controller:{type:o,required:!0},row:{type:a,required:!0}},setup:function(e){vart=S("grid-field-column"),n=y((function(){varn;if("FRONT"!==e.controller.model.source.cLConvertMode)return[];varr=e.row.data[e.controller.model.codeName];returnnull!==(n=e.controller.codeListItems)&&void0!==n&&n.length&&r?r.split(",").map((function(n){varr=e.controller.codeListItems.find((function(e){returne.value===n}));if(r){varo=r.color||"#515a6e";return{text:r.text,colorStyle:t.cssVarBlock({color:o,"border-color":o,"bg-color":D(o,"#fff")})}}})).filter(Boolean):[]})),r=y((function(){varn="";switch(e.controller.model.align){case"LEFT":n="flex-start";break;case"RIGHT":n="flex-end";break;default:n="center"}returnt.cssVarBlock({"justify-content":n})}));return{ns:t,alignStyle:r,selectedItems:n,onCellClick:function(t){e.controller.isLinkColumn&&e.controller.openLinkView(e.row,t)}}},render:function(){vare=this,t=this.controller,n=this.row.data[t.model.codeName];returnb("div",{class:[this.ns.b(),t.isLinkColumn&&this.ns.m("link-column")],style:this.alignStyle,on:{click:this.onCellClick}},[this.selectedItems.length>0?this.selectedItems.map((function(t){returnb("span",{class:e.ns.e("code-list-item"),style:t.colorStyle},[t.text])})):b("span",{class:this.ns.e("text")},[n])])}}),B=function(e){!function(e,t){if("function"!=typeoft&&null!==t)thrownewTypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&d(e,t)}(r,e);vart,n=f(r);functionr(){vare;c(this,r);for(vart=arguments.length,o=newArray(t),i=0;i<t;i++)o[i]=arguments[i];returnv(m(e=n.call.apply(n,[this].concat(o))),"imgSrc",void0),e}returnu(r,[{key:"getUIData",value:(t=l(i().mark((functione(){vart,n,r;returni().wrap((function(e){for(;;)switch(e.prev=e.next){case0:returnt=Object.assign(this.context.clone(),this.params),e.next=3,this.entityService.wf.getWFProcessDiagram(t);case3:n=e.sent,r=newBlob([n.data]),this.imgSrc=URL.createObjectURL(r);case6:case"end":returne.stop()}}),e,this)}))),function(){returnt.apply(this,arguments)})}]),r}(s),$=h({name:"PresetWFChartView",props:{context:Object,params:{type:Object},modelPath:{type:String,required:!0},modal:{type:Object},deName:{type:String,required:!0}},setup:function(e){vart=S("preset-wf-chart-view"),n=w().proxy,r=k(n,(function(t,n){returnnewB(e.modelPath,t,n)}));returnU(n,"deName",r.setDeName.bind(r)),{c:r,ns:t}},render:function(){returnb("div",{class:this.ns.b()},[b("img",{attrs:{src:this.c.imgSrc}})])}}),J=h({name:"WFToolbar",props:{wfLinks:{type:Array,required:!0}},setup:function(e,t){varn=t.emit,r=S("wf-toolbar"),o=function(){vare=l(i().mark((functione(t,r){returni().wrap((function(e){for(;;)switch(e.prev=e.next){case0:n("wf-link-click",t,r);case1:case"end":returne.stop()}}),e)})));returnfunction(t,n){returne.apply(this,arguments)}}();return{ns:r,handleClick:o}},render:function(){vare=this,t=this.wfLinks||[];returnb("div",{class:"".concat(this.ns.b())},[t.length>0&&t.map((function(t){varn="驳回"==t.sequenceFlowName||"取消"==t.sequenceFlowName;returnb("div",{key:t.sequenceFlowId,class:[e.ns.e("item"),n?e.ns.em("item","reject"):""]},[b("i-button",{attrs:{title:t.sequenceFlowName},on:{click:function(n){returne.handleClick(t,n)}}},[t.sequenceFlowName||""])])}))])}}),Y="function"==typeofbtoa,H="function"==typeofBuffer;"function"==typeofTextDecoder&&newTextDecoder;varK,Q="function"==typeofTextEncoder?newTextEncoder:void0,X=Array.prototype.slice.call("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=");K={},X.forEach((function(e,t){returnK[e]=t}));varZ=String.fromCharCode.bind(String);"function"==typeofUint8Array.from&&Uint8Array.from.bind(Uint8Array);varee=function(e){returne.replace(/=/g,"").replace(/[+\/]/g,(function(e){return"+"==e?"-":"_"}))},te=Y?function(e){returnbtoa(e)}:H?function(e){returnBuffer.from(e,"binary").toString("base64")}:function(e){for(vart,n,r,o,i="",a=e.length%3,l=0;l<e.length;){if((n=e.charCodeAt(l++))>255||(r=e.charCodeAt(l++))>255||(o=e.charCodeAt(l++))>255)thrownewTypeError("invalid character found");i+=X[(t=n<<16|r<<8|o)>>18&63]+X[t>>12&63]+X[t>>6&63]+X[63&t]}returna?i.slice(0,a-3)+"===".substring(a):i},ne=H?function(e){returnBuffer.from(e).toString("base64")}:function(e){for(vart=[],n=0,r=e.length;n<r;n+=4096)t.push(Z.apply(null,e.subarray(n,n+4096)));returnte(t.join(""))},re=function(e){if(e.length<2)return(t=e.charCodeAt(0))<128?e:t<2048?Z(192|t>>>6)+Z(128|63&t):Z(224|t>>>12&15)+Z(128|t>>>6&63)+Z(128|63&t);vart=65536+1024*(e.charCodeAt(0)-55296)+(e.charCodeAt(1)-56320);returnZ(240|t>>>18&7)+Z(128|t>>>12&63)+Z(128|t>>>6&63)+Z(128|63&t)},oe=/[\uD800-\uDBFF][\uDC00-\uDFFFF]|[^\x00-\x7F]/g,ie=H?function(e){returnBuffer.from(e,"utf8").toString("base64")}:Q?function(e){returnne(Q.encode(e))}:function(e){returnte(e.replace(oe,re))},ae=function(e){vart=arguments.length>1&&void0!==arguments[1]&&arguments[1];returnt?ee(ie(e)):ie(e)};varle=h({name:"SyFileUpload",props:O(),emits:F(),setup:function(e,t){varn=t.emit,o=S("sy-file-upload"),i=e.controller,a=function(e,t,n){varo=g([]),i=g({Authorization:"Bearer ".concat(z("access_token"))}),a=g(""),l=g(""),c={count:0,cacheFiles:[]};x((function(){returne.value}),(function(e){o.value=e?JSON.parse(e):[]}),{immediate:!0}),x((function(){returne.data}),(function(e){if(e){vart=n.calcBaseUrl(e);a.value=t.uploadUrl,l.value=t.downloadUrl}}),{immediate:!0,deep:!0}),x(o,(function(e){null!=e&&e.length&&l.value&&e.forEach((function(e){e.url=e.url||l.value.replace("%fileId%",e.id)}))}),{immediate:!0}),x(l,(function(e){e&&o.value.length&&o.value.forEach((function(e){e.url=l.value.replace("%fileId%",e.id)}))}),{immediate:!0});vars=function(){vare=[].concat(r(o.value),r(c.cacheFiles)),n=e.length>0?JSON.stringify(e.map((function(e){return{name:e.name,id:e.id}}))):null;c.cacheFiles=[],t(n)},u=g(!1),d=g(""),f=g("");return{uploadUrl:a,downloadUrl:l,headers:i,files:o,onDownload:function(e){vart=e.url||l.value.replace("%fileId%",e.id);n.fileDownload({url:t,name:e.name})},onError:function(e,t){throwc.count-=1,new_({response:{data:t,status:e.status}})},onRemove:function(t){if(!e.disabled){varn=o.value.findIndex((function(e){returne.id===t.id}));-1!==n&&o.value.splice(n,1),s()}},onSuccess:function(e){e&&(c.cacheFiles.push({name:e.filename,id:e.fileid}),c.count-=1,0===c.count&&s())},beforeUpload:function(e){vart=e.name.trim().toLowerCase();if(["html","js","exe","sh"].some((function(e){returnt.endsWith(".".concat(e))})))returnibiz.message.error("不可上传 html、js、 exe、sh类型的文件!"),!1;c.count+=1},showModal:u,modalTitle:d,iframeUrl:f,onModalCancel:function(){u.value=!1,d.value="",f.value=""},previewFile:function(e){u.value=!0,d.value=e.name;vart=window.Environment.previewFileUrl;if(t){varn=encodeURIComponent(ae("".concat(window.location.origin).concat(e.url,"?fullfilename=").concat(e.name)));f.value="".concat(t,"/onlinePreview?url=").concat(n)}}}}(e,(function(e){n("change",e)}),i);return{ns:o,c:i,uploadUrl:a.uploadUrl,headers:a.headers,files:a.files,onDownload:a.onDownload,onError:a.onError,onRemove:a.onRemove,onSuccess:a.onSuccess,beforeUpload:a.beforeUpload,showModal:a.showModal,modalTitle:a.modalTitle,iframeUrl:a.iframeUrl,onModalCancel:a.onModalCancel,previewFile:a.previewFile}},render:function(e){vart=this;returne("div",{class:[this.ns.b(),this.disabled?this.ns.m("disabled"):"",this.readonly?this.ns.m("readonly"):""]},[e("IUpload",{ref:"fileUpload",props:{action:this.uploadUrl,headers:this.headers,disabled:this.disabled,"default-file-list":this.files,multiple:this.c.model.multiple,type:this.c.model.isDrag?"drag":"select",accept:this.c.model.accept,"before-upload":this.beforeUpload,"on-success":this.onSuccess,"on-error":this.onError,"on-remove":this.onRemove,"on-preview":this.onDownload,"show-upload-list":!1}},[this.c.model.isDrag?e("div",{class:this.ns.bm("box","drag")},[e("i-icon",{attrs:{type:"md-cloud-upload"}}),e("div",{class:this.ns.be("box","title")},[e("span",["将文件拖到此处,或"]),e("span",["点击上传"])])]):e("i-button",{attrs:{icon:"ios-cloud-upload-outline"},class:this.ns.bm("box","select")},["上传文件"])]),e("div",{class:this.ns.b("file-list")},[this.files.map((function(n){returne("div",{class:t.ns.b("file-item"),key:n.id},[e("div",{class:t.ns.b("file-item-left")},[e("i-icon",{attrs:{type:"md-document"}})]),e("div",{class:t.ns.b("file-item-right")},[e("div",{class:t.ns.b("file-item-right-title"),on:{click:function(){returnt.previewFile(n)}}},[n.name]),e("div",{class:t.ns.b("file-item-right-action")},[e("i-icon",{attrs:{type:"md-download"},on:{click:function(){returnt.onDownload(n)}}}),e("i-icon",{attrs:{type:"md-eye"},on:{click:function(){returnt.previewFile(n)}}}),t.disabled||t.readonly?null:e("i-icon",{attrs:{type:"md-close"},on:{click:function(){returnt.onRemove(n)}}})])])])}))]),e("i-modal",{attrs:{value:this.showModal,title:this.modalTitle,"class-name":this.ns.b("modal"),width:"70%",transfer:!1,"footer-hide":!0},on:{"on-cancel":this.onModalCancel}},[e("iframe",{class:this.ns.b("iframe"),attrs:{src:this.iframeUrl}})])])}});functionce(e,t){if(e.url=t.replace("%fileId%",e.id),e.status||(e.status="finished"),!e.fileName){varn=e.name.lastIndexOf(".");e.fileName=e.name.substring(0,n),e.fileExt=e.name.substring(n),e.isImage=M(e.name)}returne}functionse(e){vart=g(""),n=g(""),r=g([]);returnx(e.data,(function(r){if(r){varo=e.controller.value.calcBaseUrl(r);t.value=o.uploadUrl,n.value=o.downloadUrl}}),{immediate:!0,deep:!0}),x(e.value,(function(e){r.value=e?JSON.parse(e):[],r.value.length&&n.value&&r.value.forEach((function(e){ce(e,n.value)}))}),{immediate:!0}),x(n,(function(e){e&&r.value.length&&r.value.forEach((function(t){ce(t,e)}))}),{immediate:!0}),{downloadUrl:n,uploadUrl:t,valueList:r}}functionue(e){vart=g("undo"),n=g([]),r=e.downloadUrl,o=e.value,i=e.uploadUrl;x(o,(function(e){e.length>0&&(n.value=[],e.forEach((function(e){n.value.push(ce(e,r.value))})))}),{immediate:!0,deep:!0});vara=function(e,t){varr=["html","js","exe","sh"],o=[];returnt.forEach((function(e,t){vari=e.name.trim().toLowerCase();r.some((function(e){returni.endsWith(".".concat(e))}))?o.push(t):n.value.push({name:e.name,status:e.status,percentage:e.percentage,id:e.uid,url:""})})),o.length===t.length?(ibiz.message.error("不可上传 html、js、 exe、sh类型的文件!"),!1):(o.length&&(o.forEach((function(n){e.splice(n,1),t.splice(n,1)})),ibiz.message.error("不可上传 html、js、 exe、sh类型的文件!")),!0)},l=function(e){e.forEach((function(e){n.value.find((function(t){returnt.id===e.uid&&(t.percentage=e.percentage,!0)}))}))},c=function(e,t){e.forEach((function(e){n.value.find((function(n){returnn.id===e.uid&&(n.status=e.status,n.id=t.data.fileid,n.name=t.data.filename,ce(n,r.value),!0)}))}))},s=function(e,t){varr;e.forEach((function(e){n.value.find((function(t){returnt.id===e.uid&&(t.status=e.status,!0)}))}));varo=new_(t);ibiz.notification.error({title:null===(r=o.status)||void0===r?void0:r.toString(),desc:o.message,duration:10})},u=function(e){n.value=n.value.filter((function(e){return"finished"===e.status})),t.value="done"},d=g(!1),f=g(""),p=g("");return{selectFile:function(){R({multiple:e.multiple,accept:e.accept,uploadUrl:i.value,beforeUpload:a,progress:l,success:c,error:s,finish:u})},fileList:n,uploadState:t,showModal:d,modalTitle:f,iframeUrl:p,onModalCancel:function(){d.value=!1,f.value="",p.value=""},previewFile:function(e){d.value=!0,f.value=e.name;vart=window.Environment.previewFileUrl;if(t){varn=encodeURIComponent(ae("".concat(window.location.origin).concat(e.url,"?fullfilename=").concat(e.name)));p.value="".concat(t,"/onlinePreview?url=").concat(n)}}}}varde=h({name:"SyGridFileUpload",props:C(),setup:function(e){vart=S("sy-grid-file-upload"),n=E(e),r=se({value:n.value,data:n.data,controller:n.controller}),o=ue({downloadUrl:r.downloadUrl,uploadUrl:r.uploadUrl,value:r.valueList});return{ns:t,fileList:o.fileList,showModal:o.showModal,modalTitle:o.modalTitle,iframeUrl:o.iframeUrl,downloadFile:function(t){e.controller.fileDownload(t)},previewFile:o.previewFile,onModalCancel:o.onModalCancel}},render:function(){vare=this;returnb("grid-editor",{attrs:{disabled:this.disabled,readonly:this.readonly},class:[this.ns.b(),this.disabled?this.ns.m("disabled"):"",this.readonly?this.ns.m("readonly"):""]},[b("div",{class:this.ns.b("file-list")},[this.fileList.map((function(t){returnb("div",{class:e.ns.b("file-item"),key:t.id},[b("div",{class:e.ns.b("file-item-title"),on:{click:function(){returne.previewFile(t)}}},[t.name]),b("div",{class:e.ns.b("file-item-action")},[b("i-icon",{attrs:{type:"md-download"},on:{click:function(){returne.downloadFile(t)}}}),b("i-icon",{attrs:{type:"md-eye"},on:{click:function(){returne.previewFile(t)}}})])])}))]),b("i-modal",{attrs:{value:this.showModal,title:this.modalTitle,"class-name":this.ns.b("modal"),width:"70%",transfer:!1,"footer-hide":!0},on:{"on-cancel":this.onModalCancel}},[b("iframe",{class:this.ns.b("iframe"),attrs:{src:this.iframeUrl}})])])}}),fe=h({name:"SyGridFileUploadContainer",props:C(),emits:L(),render:function(e){vart=this;returnthis.disabled||this.readonly?e("SyGridFileUpload",{props:n({},this.$props)}):e("SyEditGridFileUpload",{props:n({},this.$props),on:{change:function(e,n){t.$emit("change",e,n)},rowSave:function(){t.$emit("rowSave")}}})}}),pe=h({name:"SyEditGridFileUploadPopover",props:{uploadUrl:{type:String,required:!0},downloadUrl:{type:String,required:!0},value:{type:Array,required:!0},controller:{type:p,required:!0}},emits:{close:function(e){return!0}},setup:function(e,t){varn=t.emit,r=S("sy-edit-grid-file-upload-popover"),o=E(e),a=ue({downloadUrl:o.downloadUrl,value:o.value,uploadUrl:o.uploadUrl}),c=a.fileList,s=a.uploadState,u=a.selectFile,d=g(),f=g(!1),p=j(d,function(){vare=l(i().mark((functione(t){returni().wrap((function(e){for(;;)switch(e.prev=e.next){case0:n("close",{isModified:f.value,resultFiles:c.value});case1:case"end":returne.stop()}}),e)})));returnfunction(t){returne.apply(this,arguments)}}());x(s,(function(e){"done"===e?(f.value=!0,p.proceed()):"loading"===e&&p.pause()}));return{ns:r,componentRef:d,fileList:c,deleteFile:function(e){vart=c.value.findIndex((function(t){returnt.id===e.id}));c.value.splice(t,1),f.value=!0},selectFile:u,downloadFile:function(t){e.controller.fileDownload(t)}}},render:function(){vare=this;returnb("div",{ref:"componentRef",style:"width:300px",class:this.ns.b()},[b("div",{class:this.ns.b("file-list")},[this.fileList.map((function(t){returnb("div",{class:e.ns.b("file-item"),key:t.id},[b("div",{class:e.ns.b("file-item-title"),on:{click:function(){returne.downloadFile(t)}}},[t.name]),b("div",{class:e.ns.b("file-item-action")},[b("i-icon",{attrs:{type:"md-close"},on:{click:function(){returne.deleteFile(t)}}})])])}))]),b("div",{on:{click:function(){returne.selectFile()}},class:this.ns.e("button")},[b("i-icon",{attrs:{type:"md-add"}}),"添加文件"])])}}),me=h({name:"SyEditGridFileUpload",props:C(),emits:L(),setup:function(e,t){varn=t.emit,r=S("sy-edit-grid-file-upload"),o=E(e),a=o.value,c=o.data,s=o.controller,u=se({value:a,data:c,controller:s}),d=u.downloadUrl,f=u.uploadUrl,p=u.valueList,m=g(),h=function(){vare=l(i().mark((functione(){vart,r,o,a,l,c,u;returni().wrap((function(e){for(;;)switch(e.prev=e.next){case0:if(m.value){e.next=2;break}thrownewV("容器元素不存在");case2:returnt=m.value.$el,r=t.offsetHeight,o=ibiz.overlay.createPopover((function(e){returne(pe,{props:{value:p.value,uploadUrl:f.value,downloadUrl:d.value,controller:s.value},on:{close:function(e){o.dismiss(e)}}})}),void0,{noArrow:!0,placement:"bottom-start",offsetOpts:{mainAxis:-r,crossAxis:0}}),e.next=7,o.present(t);case7:returne.next=9,o.onWillDismiss();case9:a=e.sent,l=a.isModified,c=a.resultFiles,l&&(u=c.length>0?JSON.stringify(c.map((function(e){return{name:e.name,id:e.id}}))):null,n("change",u),n("rowSave"));case13:case"end":returne.stop()}}),e)})));returnfunction(){returne.apply(this,arguments)}}();returnP(m,"click",(function(t){e.disabled||h()})),{ns:r,valueList:p,componentRef:m}},render:function(){vare=this;returnb("grid-editor",{attrs:{disabled:this.disabled,readonly:this.readonly},ref:"componentRef",class:this.ns.b()},[b("div",{class:this.ns.b("file-list")},[this.valueList.map((function(t){returnb("div",{class:e.ns.b("file-item"),key:t.id},[b("div",{class:e.ns.b("file-item-title")},[t.name])])}))])])}}),he=u((functione(){c(this,e),v(this,"component",$)})),ve=function(){functione(){c(this,e),v(this,"component",q)}vart;returnu(e,[{key:"createController",value:(t=l(i().mark((functione(t,n){varr;returni().wrap((function(e){for(;;)switch(e.prev=e.next){case0:returnr=newo(t,n),e.next=3,r.init();case3:returne.abrupt("return",r);case4:case"end":returne.stop()}}),e)}))),function(e,n){returnt.apply(this,arguments)})}]),e}(),ye=u((functione(){c(this,e),v(this,"component","IndexView")})),be=h({name:"WFStepTraceGrid",props:{context:Object,params:{type:Object},modelPath:{type:String,required:!0},modal:{type:Object},deName:{type:String,required:!0}},setup:function(e){vart=w().proxy,n=T(t,e.modelPath);U(t,"deName",n.setDeName.bind(n));varr=S("wf-step-trace-grid"),o=g([]);n.nerve.self.evt.on("mounted",(function(){vare;n.data&&(null===(e=n.data.usertasks)||void0===e||e.forEach((function(e){e.identitylinks.length>0||(e.comments.length>0&&e.comments.forEach((function(t){o.value.push({nodeName:e.userTaskName,personName:t.authorName,time:t.time,content:t.type,comment:t.fullMessage})})),o.value.sort((function(e,t){returnDate.parse(t.time)-Date.parse(e.time)})))})))}));vari=g([{title:"处理环节",key:"nodeName",width:180,resizable:!0},{title:"处理人",key:"personName",width:180,resizable:!0},{title:"处理时间",key:"time",width:180,resizable:!0},{title:"处理内容",key:"content",width:180,resizable:!0},{title:"处理意见",key:"comment"}]);return{c:n,ns:r,gridData:o,columns:i}},render:function(){returnb("div",{class:this.ns.b()},[b("div",{class:this.ns.e("title")},["审批信息"]),b("i-table",{attrs:{"disabled-hover":!0,columns:this.columns,data:this.gridData},class:this.ns.e("grid")})])}}),we=h({props:{context:Object,params:{type:Object},modelPath:{type:String,required:!0},modal:{type:Object}},setup:function(e){vart=w().proxy,n=N(t,e.modelPath),r=S("view-".concat(W.DE_WF_DYNA_EDIT_VIEW3).toLowerCase()),o=g(["mainForm"]);return{c:n,ns:r,onTabClick:function(e){o.value.includes(e)||o.value.push(e)},lazyList:o}},render:function(e){vart=this,n=[];if(this.c.complete){varr=this.c.activeForm;r&&this.c.providers[r.name]&&n.push(e(this.c.providers[r.name].component,{props:{modelData:r,context:this.c.context,params:this.c.params},style:{height:"auto"},on:{neuronInit:this.c.nerve.onNeuronInit("form")}}))}if(this.c.complete&&this.c.model.drTab.pages[0]){varo=this.c.model.drTab.pages[0],i=this.c.drPages[o.source.name];n.push(e(be,{attrs:{context:i.context,params:i.params,deName:this.c.model.appEntity.source.codeName,modal:this.modal,modelPath:o.embedView.source.modelPath}}))}returne("view-base",{attrs:{controller:this.c},scopedSlots:{toolbar:function(){returnt.c.complete?[t.c.wfLinks.length>0&&e("wf-toolbar",{attrs:{wfLinks:t.c.wfLinks},on:{"wf-link-click":function(e){t.c.onLinkClick(e)}}})]:null}}},[this.c.complete&&e("i-tabs",{class:[this.ns.be("","tab")],attrs:{name:this.c.model.drTab.source.name},on:{"on-click":this.onTabClick}},[e("i-tab-pane",{class:this.ns.be("","tab-item"),attrs:{tab:this.c.model.drTab.source.name,label:this.c.model.drTab.source.editItemCaption,name:"mainForm"}},[n]),this.c.model.drTab.pages.map((function(n){varr=t.c.drPages[n.source.name];returne("i-tab-pane",{class:t.ns.be("","tab-item"),attrs:{tab:t.c.model.drTab.source.name,disabled:t.c.isNewData,label:n.source.caption,name:n.source.name}},[!t.c.isNewData&&t.lazyList.includes(n.source.name)&&e("ViewShell",{attrs:{context:r.context,params:r.params,modal:{mode:A.EMBED},modelPath:n.embedView.source.modelPath,deName:t.c.model.appEntity.source.codeName},on:{neuronInit:t.c.nerve.onNeuronInit(n.source.name)},key:r.key})])}))])])}}),ge=u((functione(){c(this,e),v(this,"component",we)})),xe=h({name:"SyEditView3",props:{context:Object,params:{type:Object},modelPath:{type:String,required:!0},modal:{type:Object}},setup:function(e){vart=w().proxy,n=I(t,e.modelPath),r=S("view-deeditview3"),o=g(["mainForm"]);return{c:n,ns:r,onTabClick:function(e){o.value.includes(e)||o.value.push(e)},lazyList:o}},render:function(e){vart=this;returne("view-base",{attrs:{controller:this.c}},[this.c.complete&&e("i-tabs",{class:[this.ns.be("","tab")],attrs:{name:this.c.model.drTab.source.name},on:{"on-click":this.onTabClick}},[e("i-tab-pane",{class:this.ns.be("","tab-item"),attrs:{tab:this.c.model.drTab.source.name,label:this.c.model.drTab.source.editItemCaption,name:"mainForm"}},[e("edit-form-control",{attrs:{modelData:this.c.model.form,context:this.c.context,params:this.c.params},style:{height:"auto"},on:{neuronInit:this.c.nerve.onNeuronInit(this.c.model.form.source.name)}}),e(be,{attrs:{context:this.c.drPages[this.c.model.drTab.pages[0].source.name].context,params:this.c.drPages[this.c.model.drTab.pages[0].source.name].params,deName:this.c.model.appEntity.source.codeName,modal:this.modal,modelPath:this.c.model.drTab.pages[0].embedView.source.modelPath}})]),this.c.model.drTab.pages.map((function(n){varr=t.c.drPages[n.source.name];if(r)returne("i-tab-pane",{class:t.ns.be("","tab-item"),attrs:{tab:t.c.model.drTab.source.name,disabled:t.c.isNewData,label:n.source.caption,name:n.source.name}},[!t.c.isNewData&&t.lazyList.includes(n.source.name)&&e("ViewShell",{attrs:{context:r.context,params:r.params,modal:{mode:A.EMBED},modelPath:n.embedView.source.modelPath,deName:t.c.model.appEntity.source.codeName},on:{neuronInit:t.c.nerve.onNeuronInit(n.source.name)},key:r.key})])}))])])}}),Ee=u((functione(){c(this,e),v(this,"component",xe)})),Se=function(){functione(){c(this,e),v(this,"formEditor","SyFileUpload"),v(this,"gridEditor","SyGridFileUploadContainer")}vart;returnu(e,[{key:"createController",value:(t=l(i().mark((functione(t,n){varr;returni().wrap((function(e){for(;;)switch(e.prev=e.next){case0:returnr=newp(t,n),e.next=3,r.init();case3:returne.abrupt("return",r);case4:case"end":returne.stop()}}),e)}))),function(e,n){returnt.apply(this,arguments)})}]),e}(),ke=newG(t.meta.url);e("default",{mateUrl:t.meta.url,install:function(e){ke.loadStyle(["/style.css"]),ibiz.config.enableDataInfoBar=!1,ibiz.config.gridEditShowMode="all",e.component("WfToolbar",J),ibiz.register.view.register("VIEW_CUSTOM_SyWebIndexView",newye),ibiz.register.view.register("VIEW_CUSTOM_PresetWFChartView",newhe),ibiz.register.gridColumn.register("GRID_COLRENDER_CodeListGridColumn",newve),ibiz.register.view.register("VIEW_CUSTOM_SyWfDynaEditView3",newge),ibiz.register.view.register("VIEW_CUSTOM_SyEditView3",newEe),e.component("SyFileUpload",le),e.component("SyGridFileUpload",de),e.component("SyEditGridFileUpload",me),e.component("SyGridFileUploadContainer",fe),ibiz.register.editor.register("EDITOR_CUSTOMSTYLE_SyFileUpload",newSe)}})}}}))}();