fix: BUG修改

This commit is contained in:
kun 2024-04-30 17:43:52 +08:00
parent b13d2aa96b
commit cab54e0acc
18 changed files with 26 additions and 20 deletions

View File

@ -1,9 +1,9 @@
//基础请求地址,需要根据自己的需求切换
// export const BASE_URL = "http://47.93.215.234:9809" // 鞍钢正式环境
export const BASE_URL = "http://47.93.215.234:19098" // 鞍钢线上测试环境
// export const BASE_URL = "http://47.93.215.234:19098" // 鞍钢线上测试环境
// export const BASE_URL = "http://47.93.215.234:19097"
// export const BASE_URL = "http://182.90.224.237:35557"
// export const BASE_URL = "http://192.168.34.155:19111"
export const BASE_URL = "http://192.168.34.155:19111"
// export const BASE_URL = "http://192.168.34.221:9111"
// axios.defaults.baseURL ='http://192.168.34.221:9111/' //郭圣雄本地
//export const BASE_URL = "http://192.168.8.100:10000"

View File

@ -54,7 +54,8 @@
})
const options = {
url: BASE_URL + '/wflow/res',
// url: BASE_URL + '/wflow/res',
url: BASE_URL + '/image',
header: {
Authorization: "Bearer " + uni.getStorageSync('wflow-token')
},

View File

@ -1 +1 @@
import{_ as e,aE as a,aF as o,aG as s,B as l,aH as r,C as t,aI as d,a as i,c as m,w as u,d as n,x as f,F as p,y as c,ai as h,Z as w,e as y,b as _,H as F,aj as V,f as v,i as I}from"./index-25d50b98.js";const b=e({name:"FormRender",options:{styleIsolation:"shared"},components:{WFormItem:a},props:{modelValue:{type:Object,default:()=>({})},config:{type:Object,default:()=>({})},jsonConf:{type:Array,default:()=>[]}},computed:{_value:{get(){return this.modelValue},set(e){emit("update:modelValue",e)}},rules(){const e={};return this.formFields.forEach((a=>{a.props.required&&(e[a.id]={rules:[{required:!0,errorMessage:"请填写"+a.title}]})})),e},formFields(){const e=[];return this.jsonConf.forEach((a=>this.loadInnerField(a,e))),console.log(JSON.stringify(e),666),e}},data:()=>({}),onReady(){this.$refs.wflowForm.setRules(this.rules)},methods:{showItem:o,loadInnerField(e,a){"SpanLayout"===e.name?e.props.items.forEach((e=>this.loadInnerField(e,a))):a.push(e)},validate(e){this.$refs.wflowForm.validate().then((a=>{e(!0),console.log("表单数据信息:",a)})).catch((e=>{console.log("表单错误信息:",e)}))}},emits:["update:modelValue"]},[["render",function(e,a,o,b,g,E){const j=v,q=I,x=s("w-form-item"),C=l(t("uni-forms-item"),r),R=l(t("uni-forms"),d);return i(),m(q,{class:"wflow-form"},{default:u((()=>[n(R,{ref:"wflowForm",class:"wflow-form",rules:E.rules,modelValue:E._value,"label-position":"top","label-width":"200"},{default:u((()=>[(i(!0),f(p,null,c(E.formFields,(e=>h((i(),m(C,{class:w("w-form-item "+("R"===e.perm?"w-form-item-r":"")),name:e.id,key:e.id,required:e.props.required},{label:u((()=>[n(q,{class:"w-form-title"},{default:u((()=>[e.props.required&&"E"===e.perm?(i(),m(j,{key:0,style:{color:"#CE5266"}},{default:u((()=>[y("* ")])),_:1})):_("",!0),n(j,{style:{"font-size":"32rpx"}},{default:u((()=>[y(F(e.title),1)])),_:2},1024)])),_:2},1024)])),default:u((()=>[n(x,{type:e.name,modelValue:E._value[e.id],"onUpdate:modelValue":a=>E._value[e.id]=a,"form-props":e.props,readonly:"E"!==e.perm,formData:E._value},null,8,["type","modelValue","onUpdate:modelValue","form-props","readonly","formData"])])),_:2},1032,["class","name","required"])),[[V,E.showItem(e,E._value[e.id])]]))),128))])),_:1},8,["rules","modelValue"])])),_:1})}],["__scopeId","data-v-c065bdd3"]]);export{b as F};
import{_ as e,aE as a,aF as o,aG as s,B as l,aH as r,C as t,aI as d,a as i,c as m,w as u,d as n,x as f,F as p,y as c,ai as h,Z as w,e as y,b as _,H as F,aj as V,f as v,i as I}from"./index-7d490659.js";const b=e({name:"FormRender",options:{styleIsolation:"shared"},components:{WFormItem:a},props:{modelValue:{type:Object,default:()=>({})},config:{type:Object,default:()=>({})},jsonConf:{type:Array,default:()=>[]}},computed:{_value:{get(){return this.modelValue},set(e){emit("update:modelValue",e)}},rules(){const e={};return this.formFields.forEach((a=>{a.props.required&&(e[a.id]={rules:[{required:!0,errorMessage:"请填写"+a.title}]})})),e},formFields(){const e=[];return this.jsonConf.forEach((a=>this.loadInnerField(a,e))),console.log(JSON.stringify(e),666),e}},data:()=>({}),onReady(){this.$refs.wflowForm.setRules(this.rules)},methods:{showItem:o,loadInnerField(e,a){"SpanLayout"===e.name?e.props.items.forEach((e=>this.loadInnerField(e,a))):a.push(e)},validate(e){this.$refs.wflowForm.validate().then((a=>{e(!0),console.log("表单数据信息:",a)})).catch((e=>{console.log("表单错误信息:",e)}))}},emits:["update:modelValue"]},[["render",function(e,a,o,b,g,E){const j=v,q=I,x=s("w-form-item"),C=l(t("uni-forms-item"),r),R=l(t("uni-forms"),d);return i(),m(q,{class:"wflow-form"},{default:u((()=>[n(R,{ref:"wflowForm",class:"wflow-form",rules:E.rules,modelValue:E._value,"label-position":"top","label-width":"200"},{default:u((()=>[(i(!0),f(p,null,c(E.formFields,(e=>h((i(),m(C,{class:w("w-form-item "+("R"===e.perm?"w-form-item-r":"")),name:e.id,key:e.id,required:e.props.required},{label:u((()=>[n(q,{class:"w-form-title"},{default:u((()=>[e.props.required&&"E"===e.perm?(i(),m(j,{key:0,style:{color:"#CE5266"}},{default:u((()=>[y("* ")])),_:1})):_("",!0),n(j,{style:{"font-size":"32rpx"}},{default:u((()=>[y(F(e.title),1)])),_:2},1024)])),_:2},1024)])),default:u((()=>[n(x,{type:e.name,modelValue:E._value[e.id],"onUpdate:modelValue":a=>E._value[e.id]=a,"form-props":e.props,readonly:"E"!==e.perm,formData:E._value},null,8,["type","modelValue","onUpdate:modelValue","form-props","readonly","formData"])])),_:2},1032,["class","name","required"])),[[V,E.showItem(e,E._value[e.id])]]))),128))])),_:1},8,["rules","modelValue"])])),_:1})}],["__scopeId","data-v-c065bdd3"]]);export{b as F};

View File

@ -1 +1 @@
import{_ as e,p as a,r as t,q as s,t as l,a as r,c as o,w as n,u as c,i as u,d as i,v as d,x as m,y as v,F as p,z as f,A as g,B as _,C as h,D as y,E as w,G as k,S as x,k as I,e as b,H as T,J as C,K as N,L as S,M as U,$ as z,N as P,P as j,f as D}from"./index-25d50b98.js";import{_ as F}from"./uni-segmented-control.e91c5003.js";import{_ as L}from"./noData.0cd6533e.js";import{t as $}from"./task.a0386a26.js";import{g as M,a as A}from"./ProcessUtil.a1410eb2.js";const E=e({__name:"ProcessSelect",setup(e){const E=a((()=>{const e=["待我处理","已处理的","我发起的","抄送我的"];return e[B.value]+=`-${K.value.total}`,e})),H=a((()=>f().windowHeight-40)),q=t({current:0,old:0}),B=t(0),G=t("more"),J=t({pageSize:10,pageNo:1,code:""}),K=t({pages:1,size:10,total:0,records:[]});function R(e){switch(B.value){case 0:return{text:"待处理",type:"warning"};case 1:return A(e);case 2:case 3:return M(e.result)}}function O(e){B.value=e.currentIndex,J.value.pageNo=1,V(),q.value.current=q.value.old,g((()=>{q.value.current=0}))}function Q(e){q.value.old=e.detail.scrollTop}function V(){G.value="loading",function(){switch(B.value){case 0:return $.getUserTodoList(J.value);case 1:return $.getIdoList(J.value);case 2:return $.getUserSubmittedList(J.value);case 3:return $.getCcMeList(J.value)}}().then((e=>{c(),K.value.total=e.data.total,1===J.value.pageNo&&(K.value.records.length=0),K.value.records.push(...e.data.records),G.value=J.value.pageNo*J.value.pageSize<K.value.total?"more":"noMore"})).catch((e=>{c()}))}function W(){J.value.pageNo++,V()}return s((e=>{V()})),l((()=>{V()})),(e,a)=>{const t=_(h("uni-segmented-control"),F),s=u,l=D,c=_(h("uni-tag"),y),f=_(h("uni-icons"),w),g=_(h("uni-load-more"),k),$=x,M=I;return r(),o(s,{class:"content"},{default:n((()=>[i(s,{class:"nav-type"},{default:n((()=>[i(t,{current:B.value,values:E.value,onClickItem:O,styleType:"text",activeColor:"#4C87F3"},null,8,["current","values"])])),_:1}),i(s,{class:"datas"},{default:n((()=>[K.value.records.length>0?(r(),o($,{key:0,class:"scrool-more","refresher-threshold":0,onScrolltolower:W,"scroll-top":q.value.current,onScroll:Q,enablePullDownRefresh:"",onScrolltoupper:()=>{},"show-scrollbar":!0,style:d({height:H.value+"px"}),"scroll-y":"true","scroll-with-animation":"true"},{default:n((()=>[(r(!0),m(p,null,v(K.value.records,((e,a)=>(r(),o(s,{class:"process-item",key:e.instanceId+a,onClick:a=>function(e){j({url:`/pages/instance/instancePreview?instanceId=${e.instanceId}&nodeId=${e.nodeId}`})}(e)},{default:n((()=>[i(s,null,{default:n((()=>[i(l,null,{default:n((()=>[b(T((e.owner||e.staterUser).name)+"提交的 "+T(e.processDefName),1)])),_:2},1024),i(c,{class:"process-item-status",circle:"true",text:R(e).text,type:R(e).type,inverted:""},null,8,["text","type"])])),_:2},1024),i(s,{class:"form-content"},{default:n((()=>[(r(!0),m(p,null,v(e.formAbstracts||[],(e=>(r(),o(s,{key:e.id},{default:n((()=>[i(l,{style:{color:"#b5b5b5"}},{default:n((()=>[b(T(e.name)+": ",1)])),_:2},1024),i(l,{class:"over-tip"},{default:n((()=>[b(T(C(N)(e)),1)])),_:2},1024)])),_:2},1024)))),128))])),_:2},1024),i(s,{class:"process-item-footer"},{default:n((()=>[i(S,{name:(e.owner||e.staterUser).name,src:(e.owner||e.staterUser).avatar,size:30},null,8,["name","src"]),i(l,null,{default:n((()=>[b("在 "+T((e.createTime||e.startTime).substring(0,16))+" 提交 ",1)])),_:2},1024),i(s,{onClick:U((a=>function(e){z("selectProcess",{id:e.instanceId,name:e.processDefName,startUser:e.owner||e.staterUser,createTime:e.createTime||e.startTime}),setTimeout((()=>P()),100)}(e)),["stop"])},{default:n((()=>[i(f,{color:"#5976EF",type:"checkbox",size:"18"}),i(l,null,{default:n((()=>[b("选择")])),_:1})])),_:2},1032,["onClick"])])),_:2},1024)])),_:2},1032,["onClick"])))),128)),i(g,{status:G.value,mode:"scaleToFill",showIcon:!1},null,8,["status"])])),_:1},8,["scroll-top","style"])):(r(),o(M,{key:1,class:"nodata",src:L,mode:"aspectFit"}))])),_:1})])),_:1})}}},[["__scopeId","data-v-9485c865"]]);export{E as default};
import{_ as e,p as a,r as t,q as s,t as l,a as r,c as o,w as n,u as c,i as u,d as i,v as d,x as m,y as v,F as p,z as f,A as g,B as _,C as h,D as y,E as w,G as k,S as x,k as I,e as b,H as T,J as C,K as N,L as S,M as U,$ as z,N as P,P as j,f as D}from"./index-7d490659.js";import{_ as F}from"./uni-segmented-control.ddbfca10.js";import{_ as L}from"./noData.0cd6533e.js";import{t as $}from"./task.327044a8.js";import{g as M,a as A}from"./ProcessUtil.a1410eb2.js";const E=e({__name:"ProcessSelect",setup(e){const E=a((()=>{const e=["待我处理","已处理的","我发起的","抄送我的"];return e[B.value]+=`-${K.value.total}`,e})),H=a((()=>f().windowHeight-40)),q=t({current:0,old:0}),B=t(0),G=t("more"),J=t({pageSize:10,pageNo:1,code:""}),K=t({pages:1,size:10,total:0,records:[]});function R(e){switch(B.value){case 0:return{text:"待处理",type:"warning"};case 1:return A(e);case 2:case 3:return M(e.result)}}function O(e){B.value=e.currentIndex,J.value.pageNo=1,V(),q.value.current=q.value.old,g((()=>{q.value.current=0}))}function Q(e){q.value.old=e.detail.scrollTop}function V(){G.value="loading",function(){switch(B.value){case 0:return $.getUserTodoList(J.value);case 1:return $.getIdoList(J.value);case 2:return $.getUserSubmittedList(J.value);case 3:return $.getCcMeList(J.value)}}().then((e=>{c(),K.value.total=e.data.total,1===J.value.pageNo&&(K.value.records.length=0),K.value.records.push(...e.data.records),G.value=J.value.pageNo*J.value.pageSize<K.value.total?"more":"noMore"})).catch((e=>{c()}))}function W(){J.value.pageNo++,V()}return s((e=>{V()})),l((()=>{V()})),(e,a)=>{const t=_(h("uni-segmented-control"),F),s=u,l=D,c=_(h("uni-tag"),y),f=_(h("uni-icons"),w),g=_(h("uni-load-more"),k),$=x,M=I;return r(),o(s,{class:"content"},{default:n((()=>[i(s,{class:"nav-type"},{default:n((()=>[i(t,{current:B.value,values:E.value,onClickItem:O,styleType:"text",activeColor:"#4C87F3"},null,8,["current","values"])])),_:1}),i(s,{class:"datas"},{default:n((()=>[K.value.records.length>0?(r(),o($,{key:0,class:"scrool-more","refresher-threshold":0,onScrolltolower:W,"scroll-top":q.value.current,onScroll:Q,enablePullDownRefresh:"",onScrolltoupper:()=>{},"show-scrollbar":!0,style:d({height:H.value+"px"}),"scroll-y":"true","scroll-with-animation":"true"},{default:n((()=>[(r(!0),m(p,null,v(K.value.records,((e,a)=>(r(),o(s,{class:"process-item",key:e.instanceId+a,onClick:a=>function(e){j({url:`/pages/instance/instancePreview?instanceId=${e.instanceId}&nodeId=${e.nodeId}`})}(e)},{default:n((()=>[i(s,null,{default:n((()=>[i(l,null,{default:n((()=>[b(T((e.owner||e.staterUser).name)+"提交的 "+T(e.processDefName),1)])),_:2},1024),i(c,{class:"process-item-status",circle:"true",text:R(e).text,type:R(e).type,inverted:""},null,8,["text","type"])])),_:2},1024),i(s,{class:"form-content"},{default:n((()=>[(r(!0),m(p,null,v(e.formAbstracts||[],(e=>(r(),o(s,{key:e.id},{default:n((()=>[i(l,{style:{color:"#b5b5b5"}},{default:n((()=>[b(T(e.name)+": ",1)])),_:2},1024),i(l,{class:"over-tip"},{default:n((()=>[b(T(C(N)(e)),1)])),_:2},1024)])),_:2},1024)))),128))])),_:2},1024),i(s,{class:"process-item-footer"},{default:n((()=>[i(S,{name:(e.owner||e.staterUser).name,src:(e.owner||e.staterUser).avatar,size:30},null,8,["name","src"]),i(l,null,{default:n((()=>[b("在 "+T((e.createTime||e.startTime).substring(0,16))+" 提交 ",1)])),_:2},1024),i(s,{onClick:U((a=>function(e){z("selectProcess",{id:e.instanceId,name:e.processDefName,startUser:e.owner||e.staterUser,createTime:e.createTime||e.startTime}),setTimeout((()=>P()),100)}(e)),["stop"])},{default:n((()=>[i(f,{color:"#5976EF",type:"checkbox",size:"18"}),i(l,null,{default:n((()=>[b("选择")])),_:1})])),_:2},1032,["onClick"])])),_:2},1024)])),_:2},1032,["onClick"])))),128)),i(g,{status:G.value,mode:"scaleToFill",showIcon:!1},null,8,["status"])])),_:1},8,["scroll-top","style"])):(r(),o(M,{key:1,class:"nodata",src:L,mode:"aspectFit"}))])),_:1})])),_:1})}}},[["__scopeId","data-v-9485c865"]]);export{E as default};

View File

@ -1 +1 @@
import{ay as t}from"./index-25d50b98.js";function e(e,o=!1){return t({url:`wflow/model/${o?"sub/":""}group/list`,data:e})}function o(e,o){return t({url:"wflow/model/list/byUser",data:e,header:o})}function r(e){return t({url:`wflow/model/detail/${e}`,data:"GET"})}function n(){return t({url:"wflow/process/instance/count",method:"GET"})}function u(e){return t({url:"xmgl/baseModule/getModuleAndMenuList",method:"POST",data:e})}export{o as a,n as b,e as c,r as d,u as g};
import{ay as t}from"./index-7d490659.js";function e(e,o=!1){return t({url:`wflow/model/${o?"sub/":""}group/list`,data:e})}function o(e,o){return t({url:"wflow/model/list/byUser",data:e,header:o})}function r(e){return t({url:`wflow/model/detail/${e}`,data:"GET"})}function n(){return t({url:"wflow/process/instance/count",method:"GET"})}function u(e){return t({url:"xmgl/baseModule/getModuleAndMenuList",method:"POST",data:e})}export{o as a,n as b,e as c,r as d,u as g};

View File

@ -1 +1 @@
import{_ as e,r as a,p as t,a as l,c as s,w as n,d as u,L as r,e as i,H as o,x as d,y as c,F as p,a3 as v,a4 as h,f as y,B as m,D as f,C as g,i as x,E as _,a5 as w,a6 as k,a7 as b,o as C,a8 as z,V as E,a9 as T,aa as A,v as N,S as F,ab as I,z as V,a0 as B,ac as D,ad as P,k as U,ae as $,b as j,af as H}from"./index-25d50b98.js";const L=e({__name:"UserCard",props:["userId"],setup(e,{expose:C}){const z=a({}),E=a(),T=t((()=>0===(z.value.depts||[]).length?"未设置部门":z.value.depts.join("、")));function A(){E.value.close()}return C({show:function(e){v(e).then((e=>{z.value=e.data,E.value.open("center")}))},hide:A}),(e,a)=>{const t=y,v=m(g("uni-tag"),f),C=x,N=m(g("uni-icons"),_),F=m(g("uni-list-item"),w),I=m(g("uni-list"),k),V=m(g("uni-popup"),b);return l(),s(V,{ref_key:"userCardPopup",ref:E,type:"center"},{default:n((()=>[u(C,{class:"w-user-card"},{default:n((()=>[u(r,{class:"w-avatar",src:z.value.avatar,name:z.value.username,size:55,showName:!1},null,8,["src","name"]),u(C,null,{default:n((()=>[u(t,{style:{"margin-right":"10px"}},{default:n((()=>[i(o(z.value.username),1)])),_:1}),(l(!0),d(p,null,c(z.value.roles||[],((e,a)=>(l(),s(v,{type:"warning",size:"mini",text:e,inverted:"",key:`r${a}`},null,8,["text"])))),128))])),_:1}),u(N,{class:"w-xicon",type:"closeempty",color:"#A2A2A2",size:20,onClick:A}),u(I,{class:"w-user-info"},{default:n((()=>[u(F,{title:"所属部门",rightText:T.value,"show-extra-icon":"","extra-icon":{type:"home"}},null,8,["rightText"]),u(F,{title:"入职时间",rightText:z.value.entryDate,"show-extra-icon":"","extra-icon":{type:"calendar"}},null,8,["rightText"]),u(F,{title:"性别",rightText:z.value.sex?"男":"女","show-extra-icon":"","extra-icon":{type:"staff"}},null,8,["rightText"]),u(F,{title:"电话",onClick:a[0]||(a[0]=e=>{h({phoneNumber:"18866668888"})}),"show-extra-icon":"",rightText:"18866668888",clickable:"","show-arrow":"","extra-icon":{type:"phone"}})])),_:1})])),_:1})])),_:1},512)}}},[["__scopeId","data-v-5975a4bb"]]),O=e({__name:"contacts",setup(e){const v=a(),h=a(0),_=a(""),b=a([]),O=a([]),S=a([{name:"组织",id:0}]),J=t((()=>V().windowHeight-105));a(!1);const q=t((()=>""!==_.value.trim()?b.value:O.value));function G(){const e=JSON.parse(E("loginUser"));T({deptId:h.value+"P"+e.sn,type:"user"}).then((e=>{O.value=e.data,loadOrgPath()})).catch((e=>{}))}return C((()=>G())),z((()=>(v.value.hide(),S.value.length>1&&(S.value.length--,h.value=S.value[S.value.length-1].id,G(),!0)))),A(_,(()=>{""!==_.value.trim()&&(b.value.length=0,H({userName:_.value.trim()}).then((e=>{b.value=e.data})).catch((e=>{})))})),(e,a)=>{const t=m(g("uni-search-bar"),B),b=x,C=m(g("uni-breadcrumb-item"),D),z=m(g("uni-breadcrumb"),P),E=F,T=U,A=y,V=m(g("uni-tag"),f),H=m(g("uni-list-item"),w),K=m(g("uni-list"),k);return l(),d(p,null,[u(b,{style:{padding:"0 0 16rpx 0","background-color":"white"}},{default:n((()=>[u(b,{class:"search"},{default:n((()=>[u(t,{modelValue:_.value,"onUpdate:modelValue":a[0]||(a[0]=e=>_.value=e),bgColor:"#EEEEEE",radius:"5",placeholder:"搜索人员",clearButton:"auto",cancelButton:"none"},null,8,["modelValue"])])),_:1}),u(b,{style:{padding:"6rpx 16rpx"}},{default:n((()=>[u(E,{"scroll-x":""},{default:n((()=>[u(z,{separator:">"},{default:n((()=>[(l(!0),d(p,null,c(S.value,((e,a)=>(l(),s(C,{key:a,onClick:t=>{return l=e.id,s=a,h.value=l,S.value.length=s+1,void G();var l,s}},{default:n((()=>[u(b,{style:N({color:a+1===S.value.length?"#989996":"#1E90FD","font-size":"32rpx"})},{default:n((()=>[i(o(e.name),1)])),_:2},1032,["style"])])),_:2},1032,["onClick"])))),128))])),_:1})])),_:1})])),_:1})])),_:1}),O.value.length>0?(l(),s(E,{key:0,class:"w-org-list","scroll-y":"",style:N({height:J.value+"px"})},{default:n((()=>[u(K,null,{default:n((()=>[(l(!0),d(p,null,c(q.value,((e,a)=>(l(),s(H,{clickable:"",showArrow:"dept"===e.type,key:`${e.type}_${e.id}`,class:"w-org-item",onClick:a=>function(e){"dept"===e.type?(h.value=e.id,S.value.push({name:e.name,id:e.id}),G()):"user"===e.type&&v.value.show(e.id)}(e)},{header:n((()=>[u(b,{class:"w-org-avatar"},{default:n((()=>["user"===e.type?(l(),s(r,{key:0,name:e.name,src:e.avatar,showName:!1},null,8,["name","src"])):(l(),s(T,{key:1,"lazy-load":"",mode:"aspectFit",src:$}))])),_:2},1024)])),body:n((()=>[u(b,{style:{display:"flex","align-items":"center"}},{default:n((()=>[u(A,{style:{"font-size":"32rpx"}},{default:n((()=>[i(o(e.name),1)])),_:2},1024),e.isLeader?(l(),s(b,{key:0,style:{display:"flex","align-items":"center","margin-left":"16rpx"}},{default:n((()=>[u(V,{type:"warning",size:"mini",text:"部门负责人",inverted:""})])),_:1})):j("",!0)])),_:2},1024)])),_:2},1032,["showArrow","onClick"])))),128))])),_:1})])),_:1},8,["style"])):(l(),s(b,{key:1,style:{width:"100%"}},{default:n((()=>[u(T,{mode:"aspectFit",style:{width:"100%"},src:I})])),_:1})),u(L,{ref_key:"userCard",ref:v},null,512)],64)}}},[["__scopeId","data-v-5512bd08"]]);export{O as default};
import{_ as e,r as a,p as t,a as l,c as s,w as n,d as u,L as r,e as i,H as o,x as d,y as c,F as p,a3 as v,a4 as h,f as y,B as m,D as f,C as g,i as x,E as _,a5 as w,a6 as k,a7 as b,o as C,a8 as z,V as E,a9 as T,aa as A,v as N,S as F,ab as I,z as V,a0 as B,ac as D,ad as P,k as U,ae as $,b as j,af as H}from"./index-7d490659.js";const L=e({__name:"UserCard",props:["userId"],setup(e,{expose:C}){const z=a({}),E=a(),T=t((()=>0===(z.value.depts||[]).length?"未设置部门":z.value.depts.join("、")));function A(){E.value.close()}return C({show:function(e){v(e).then((e=>{z.value=e.data,E.value.open("center")}))},hide:A}),(e,a)=>{const t=y,v=m(g("uni-tag"),f),C=x,N=m(g("uni-icons"),_),F=m(g("uni-list-item"),w),I=m(g("uni-list"),k),V=m(g("uni-popup"),b);return l(),s(V,{ref_key:"userCardPopup",ref:E,type:"center"},{default:n((()=>[u(C,{class:"w-user-card"},{default:n((()=>[u(r,{class:"w-avatar",src:z.value.avatar,name:z.value.username,size:55,showName:!1},null,8,["src","name"]),u(C,null,{default:n((()=>[u(t,{style:{"margin-right":"10px"}},{default:n((()=>[i(o(z.value.username),1)])),_:1}),(l(!0),d(p,null,c(z.value.roles||[],((e,a)=>(l(),s(v,{type:"warning",size:"mini",text:e,inverted:"",key:`r${a}`},null,8,["text"])))),128))])),_:1}),u(N,{class:"w-xicon",type:"closeempty",color:"#A2A2A2",size:20,onClick:A}),u(I,{class:"w-user-info"},{default:n((()=>[u(F,{title:"所属部门",rightText:T.value,"show-extra-icon":"","extra-icon":{type:"home"}},null,8,["rightText"]),u(F,{title:"入职时间",rightText:z.value.entryDate,"show-extra-icon":"","extra-icon":{type:"calendar"}},null,8,["rightText"]),u(F,{title:"性别",rightText:z.value.sex?"男":"女","show-extra-icon":"","extra-icon":{type:"staff"}},null,8,["rightText"]),u(F,{title:"电话",onClick:a[0]||(a[0]=e=>{h({phoneNumber:"18866668888"})}),"show-extra-icon":"",rightText:"18866668888",clickable:"","show-arrow":"","extra-icon":{type:"phone"}})])),_:1})])),_:1})])),_:1},512)}}},[["__scopeId","data-v-5975a4bb"]]),O=e({__name:"contacts",setup(e){const v=a(),h=a(0),_=a(""),b=a([]),O=a([]),S=a([{name:"组织",id:0}]),J=t((()=>V().windowHeight-105));a(!1);const q=t((()=>""!==_.value.trim()?b.value:O.value));function G(){const e=JSON.parse(E("loginUser"));T({deptId:h.value+"P"+e.sn,type:"user"}).then((e=>{O.value=e.data,loadOrgPath()})).catch((e=>{}))}return C((()=>G())),z((()=>(v.value.hide(),S.value.length>1&&(S.value.length--,h.value=S.value[S.value.length-1].id,G(),!0)))),A(_,(()=>{""!==_.value.trim()&&(b.value.length=0,H({userName:_.value.trim()}).then((e=>{b.value=e.data})).catch((e=>{})))})),(e,a)=>{const t=m(g("uni-search-bar"),B),b=x,C=m(g("uni-breadcrumb-item"),D),z=m(g("uni-breadcrumb"),P),E=F,T=U,A=y,V=m(g("uni-tag"),f),H=m(g("uni-list-item"),w),K=m(g("uni-list"),k);return l(),d(p,null,[u(b,{style:{padding:"0 0 16rpx 0","background-color":"white"}},{default:n((()=>[u(b,{class:"search"},{default:n((()=>[u(t,{modelValue:_.value,"onUpdate:modelValue":a[0]||(a[0]=e=>_.value=e),bgColor:"#EEEEEE",radius:"5",placeholder:"搜索人员",clearButton:"auto",cancelButton:"none"},null,8,["modelValue"])])),_:1}),u(b,{style:{padding:"6rpx 16rpx"}},{default:n((()=>[u(E,{"scroll-x":""},{default:n((()=>[u(z,{separator:">"},{default:n((()=>[(l(!0),d(p,null,c(S.value,((e,a)=>(l(),s(C,{key:a,onClick:t=>{return l=e.id,s=a,h.value=l,S.value.length=s+1,void G();var l,s}},{default:n((()=>[u(b,{style:N({color:a+1===S.value.length?"#989996":"#1E90FD","font-size":"32rpx"})},{default:n((()=>[i(o(e.name),1)])),_:2},1032,["style"])])),_:2},1032,["onClick"])))),128))])),_:1})])),_:1})])),_:1})])),_:1}),O.value.length>0?(l(),s(E,{key:0,class:"w-org-list","scroll-y":"",style:N({height:J.value+"px"})},{default:n((()=>[u(K,null,{default:n((()=>[(l(!0),d(p,null,c(q.value,((e,a)=>(l(),s(H,{clickable:"",showArrow:"dept"===e.type,key:`${e.type}_${e.id}`,class:"w-org-item",onClick:a=>function(e){"dept"===e.type?(h.value=e.id,S.value.push({name:e.name,id:e.id}),G()):"user"===e.type&&v.value.show(e.id)}(e)},{header:n((()=>[u(b,{class:"w-org-avatar"},{default:n((()=>["user"===e.type?(l(),s(r,{key:0,name:e.name,src:e.avatar,showName:!1},null,8,["name","src"])):(l(),s(T,{key:1,"lazy-load":"",mode:"aspectFit",src:$}))])),_:2},1024)])),body:n((()=>[u(b,{style:{display:"flex","align-items":"center"}},{default:n((()=>[u(A,{style:{"font-size":"32rpx"}},{default:n((()=>[i(o(e.name),1)])),_:2},1024),e.isLeader?(l(),s(b,{key:0,style:{display:"flex","align-items":"center","margin-left":"16rpx"}},{default:n((()=>[u(V,{type:"warning",size:"mini",text:"部门负责人",inverted:""})])),_:1})):j("",!0)])),_:2},1024)])),_:2},1032,["showArrow","onClick"])))),128))])),_:1})])),_:1},8,["style"])):(l(),s(b,{key:1,style:{width:"100%"}},{default:n((()=>[u(T,{mode:"aspectFit",style:{width:"100%"},src:I})])),_:1})),u(L,{ref_key:"userCard",ref:v},null,512)],64)}}},[["__scopeId","data-v-5512bd08"]]);export{O as default};

View File

@ -1 +1 @@
import{_ as e,r as a,p as s,az as t,aJ as l,a as u,c as n,w as r,i,d as o,as as d,e as m,b as c,aK as f,aL as p,s as v,N as g,aM as _,B as h,aN as w,C as y,aH as V,aI as R,E as b,j as k}from"./index-25d50b98.js";const q=e({__name:"UserAgent",setup(e){const q=a({timeRange:[],effective:!1,user:[]}),z=a(!1),C=a();s({get:()=>q.value.user?[q.value.user]:[],set(e){q.value.user=e[0]}});const M={timeRange:{rules:[{errorMessage:"请选择代理时间段",required:!0}]},user:{rules:[{errorMessage:"请选择代理人",required:!0}]}};function U(){f({title:"提示",content:"您是否要取消该代理人设置",success:function(e){e.confirm&&p().then((e=>{v({icon:"none",title:"取消成功"}),g()}))}})}function j(){C.value.validate().then((e=>{_({timeRange:q.value.timeRange,user:q.value.user[0]}).then((e=>{v({icon:"none",title:"设置代理人成功"}),g()})).catch((e=>{v({icon:"none",title:"设置失败:"+e.msg})}))})).catch((e=>{v({icon:"none",title:"请完成设置"})}))}return t((()=>{l().then((e=>{e.data&&(q.value={...e.data,user:e.data.user?[e.data.user]:[]},z.value=!0)}))})),(e,a)=>{const s=h(y("uni-datetime-picker"),w),t=h(y("uni-forms-item"),V),l=h(y("uni-forms"),R),f=h(y("uni-icons"),b),p=k,v=i;return u(),n(v,{class:"w-user-angent"},{default:r((()=>[o(l,{ref_key:"wflowForm",ref:C,rules:M,modelValue:q.value,"label-position":"top","label-width":"200"},{default:r((()=>[o(t,{name:"timeRange",required:!0,label:"代理时间段"},{default:r((()=>[o(s,{modelValue:q.value.timeRange,"onUpdate:modelValue":a[0]||(a[0]=e=>q.value.timeRange=e),type:"datetimerange",rangeSeparator:"至"},null,8,["modelValue"])])),_:1}),o(t,{name:"user",required:!0,label:"代理人"},{default:r((()=>[o(d,{class:"w-user",modelValue:q.value.user,"onUpdate:modelValue":a[1]||(a[1]=e=>q.value.user=e),formProps:{multiple:!1,placeholder:"请选择代理人"},position:"right"},null,8,["modelValue"])])),_:1})])),_:1},8,["modelValue"]),z.value?(u(),n(p,{key:0,type:"warn",plain:"",size:"mini",onClick:U},{default:r((()=>[o(f,{type:"refreshempty",color:"#E64340",size:"13"}),m(" 取消代理人 ")])),_:1})):c("",!0),o(p,{type:"primary",size:"mini",class:"w-button",onClick:j},{default:r((()=>[m("提交")])),_:1})])),_:1})}}},[["__scopeId","data-v-5fc00c84"]]);export{q as default};
import{_ as e,r as a,p as s,az as t,aJ as l,a as u,c as n,w as r,i,d as o,as as d,e as m,b as c,aK as f,aL as p,s as v,N as g,aM as _,B as h,aN as w,C as y,aH as V,aI as R,E as b,j as k}from"./index-7d490659.js";const q=e({__name:"UserAgent",setup(e){const q=a({timeRange:[],effective:!1,user:[]}),z=a(!1),C=a();s({get:()=>q.value.user?[q.value.user]:[],set(e){q.value.user=e[0]}});const M={timeRange:{rules:[{errorMessage:"请选择代理时间段",required:!0}]},user:{rules:[{errorMessage:"请选择代理人",required:!0}]}};function U(){f({title:"提示",content:"您是否要取消该代理人设置",success:function(e){e.confirm&&p().then((e=>{v({icon:"none",title:"取消成功"}),g()}))}})}function j(){C.value.validate().then((e=>{_({timeRange:q.value.timeRange,user:q.value.user[0]}).then((e=>{v({icon:"none",title:"设置代理人成功"}),g()})).catch((e=>{v({icon:"none",title:"设置失败:"+e.msg})}))})).catch((e=>{v({icon:"none",title:"请完成设置"})}))}return t((()=>{l().then((e=>{e.data&&(q.value={...e.data,user:e.data.user?[e.data.user]:[]},z.value=!0)}))})),(e,a)=>{const s=h(y("uni-datetime-picker"),w),t=h(y("uni-forms-item"),V),l=h(y("uni-forms"),R),f=h(y("uni-icons"),b),p=k,v=i;return u(),n(v,{class:"w-user-angent"},{default:r((()=>[o(l,{ref_key:"wflowForm",ref:C,rules:M,modelValue:q.value,"label-position":"top","label-width":"200"},{default:r((()=>[o(t,{name:"timeRange",required:!0,label:"代理时间段"},{default:r((()=>[o(s,{modelValue:q.value.timeRange,"onUpdate:modelValue":a[0]||(a[0]=e=>q.value.timeRange=e),type:"datetimerange",rangeSeparator:"至"},null,8,["modelValue"])])),_:1}),o(t,{name:"user",required:!0,label:"代理人"},{default:r((()=>[o(d,{class:"w-user",modelValue:q.value.user,"onUpdate:modelValue":a[1]||(a[1]=e=>q.value.user=e),formProps:{multiple:!1,placeholder:"请选择代理人"},position:"right"},null,8,["modelValue"])])),_:1})])),_:1},8,["modelValue"]),z.value?(u(),n(p,{key:0,type:"warn",plain:"",size:"mini",onClick:U},{default:r((()=>[o(f,{type:"refreshempty",color:"#E64340",size:"13"}),m(" 取消代理人 ")])),_:1})):c("",!0),o(p,{type:"primary",size:"mini",class:"w-button",onClick:j},{default:r((()=>[m("提交")])),_:1})])),_:1})}}},[["__scopeId","data-v-5fc00c84"]]);export{q as default};

View File

@ -1 +1 @@
import{_ as a,r as e,V as s,p as t,ag as l,a3 as u,a as n,x as i,d as r,w as c,F as o,ah as m,P as f,i as d,B as g,j as _,L as p,e as w,H as v,y as b,D as y,C as h,f as k,a5 as x,a6 as j,c as A}from"./index-25d50b98.js";const C=a({__name:"my",setup(a){const C=e({}),$=JSON.parse(s("loginUser")),z=t((()=>0===(C.value.depts||[]).length?"未设置部门":C.value.depts.join("、"))),D=t((()=>{const a=C.value.userAgent;return a?`${a.user.name}${a.effective?"代理中":"代理未生效"}`:"未设置"}));function I(){m(),f({url:"/pages/login/login"})}function N(){f({url:"/pages/my/UserAgent"})}return l((()=>{u($.userId).then((a=>{C.value=a.data})).catch((a=>{}))})),(a,e)=>{const s=d,t=g(h("uni-tag"),y),l=k,u=g(h("uni-list-item"),x),m=g(h("uni-list"),j),f=_;return n(),i(o,null,[r(s,{class:"w-user-info"},{default:c((()=>[r(p,{name:C.value.username,src:C.value.avatar,size:70,showName:!1},null,8,["name","src"]),r(s,{class:"w-user-name"},{default:c((()=>[w(v(C.value.username),1)])),_:1}),(n(!0),i(o,null,b(C.value.roles||[],((a,e)=>(n(),A(t,{class:"w-user-role",type:"warning",size:"mini",text:a,inverted:"",key:`r${e}`},null,8,["text"])))),128))])),_:1}),r(m,{class:"w-user-items"},{default:c((()=>[r(u,{thumb:"/static/image/dept.png",clickable:""},{body:c((()=>[r(l,{class:"w-items-t"},{default:c((()=>[w("所属部门")])),_:1})])),footer:c((()=>[r(l,{class:"w-items-f"},{default:c((()=>[w(v(z.value),1)])),_:1})])),_:1}),r(u,{thumb:"/static/image/entry.png",clickable:""},{body:c((()=>[r(l,{class:"w-items-t"},{default:c((()=>[w("入职时间")])),_:1})])),footer:c((()=>[r(l,{class:"w-items-f"},{default:c((()=>[w(v(C.value.entryDate),1)])),_:1})])),_:1}),r(u,{thumb:"/static/image/agent.png",clickable:"",showArrow:"",onClick:N},{body:c((()=>[r(l,{class:"w-items-t"},{default:c((()=>[w("设置代理人")])),_:1})])),footer:c((()=>[r(l,{class:"w-items-f"},{default:c((()=>[w(v(D.value),1)])),_:1})])),_:1})])),_:1}),r(f,{class:"w-user-logout",onClick:I,plain:"true",type:"warn"},{default:c((()=>[w("退出/切换 账号")])),_:1})],64)}}},[["__scopeId","data-v-f9eb6b66"]]);export{C as default};
import{_ as a,r as e,V as s,p as t,ag as l,a3 as u,a as n,x as i,d as r,w as c,F as o,ah as m,P as f,i as d,B as g,j as _,L as p,e as w,H as v,y as b,D as y,C as h,f as k,a5 as x,a6 as j,c as A}from"./index-7d490659.js";const C=a({__name:"my",setup(a){const C=e({}),$=JSON.parse(s("loginUser")),z=t((()=>0===(C.value.depts||[]).length?"未设置部门":C.value.depts.join("、"))),D=t((()=>{const a=C.value.userAgent;return a?`${a.user.name}${a.effective?"代理中":"代理未生效"}`:"未设置"}));function I(){m(),f({url:"/pages/login/login"})}function N(){f({url:"/pages/my/UserAgent"})}return l((()=>{u($.userId).then((a=>{C.value=a.data})).catch((a=>{}))})),(a,e)=>{const s=d,t=g(h("uni-tag"),y),l=k,u=g(h("uni-list-item"),x),m=g(h("uni-list"),j),f=_;return n(),i(o,null,[r(s,{class:"w-user-info"},{default:c((()=>[r(p,{name:C.value.username,src:C.value.avatar,size:70,showName:!1},null,8,["name","src"]),r(s,{class:"w-user-name"},{default:c((()=>[w(v(C.value.username),1)])),_:1}),(n(!0),i(o,null,b(C.value.roles||[],((a,e)=>(n(),A(t,{class:"w-user-role",type:"warning",size:"mini",text:a,inverted:"",key:`r${e}`},null,8,["text"])))),128))])),_:1}),r(m,{class:"w-user-items"},{default:c((()=>[r(u,{thumb:"/static/image/dept.png",clickable:""},{body:c((()=>[r(l,{class:"w-items-t"},{default:c((()=>[w("所属部门")])),_:1})])),footer:c((()=>[r(l,{class:"w-items-f"},{default:c((()=>[w(v(z.value),1)])),_:1})])),_:1}),r(u,{thumb:"/static/image/entry.png",clickable:""},{body:c((()=>[r(l,{class:"w-items-t"},{default:c((()=>[w("入职时间")])),_:1})])),footer:c((()=>[r(l,{class:"w-items-f"},{default:c((()=>[w(v(C.value.entryDate),1)])),_:1})])),_:1}),r(u,{thumb:"/static/image/agent.png",clickable:"",showArrow:"",onClick:N},{body:c((()=>[r(l,{class:"w-items-t"},{default:c((()=>[w("设置代理人")])),_:1})])),footer:c((()=>[r(l,{class:"w-items-f"},{default:c((()=>[w(v(D.value),1)])),_:1})])),_:1})])),_:1}),r(f,{class:"w-user-logout",onClick:I,plain:"true",type:"warn"},{default:c((()=>[w("退出/切换 账号")])),_:1})],64)}}},[["__scopeId","data-v-f9eb6b66"]]);export{C as default};

View File

@ -1 +1 @@
import{_ as e,p as a,r as t,q as s,Q as l,R as r,T as n,U as o,t as u,J as c,a as i,c as d,w as v,b as p,V as f,A as m,u as g,i as h,d as y,x as _,y as w,F as x,v as k,z as I,B as S,C as N,D as b,G as C,W as T,e as U,H as j,K as O,L as J,P as L,f as z,S as D,k as F,X as P}from"./index-25d50b98.js";import{_ as $}from"./uni-segmented-control.e91c5003.js";import{_ as A}from"./noData.0cd6533e.js";import{t as H}from"./task.a0386a26.js";import{g as M}from"./model.953efe57.js";import{g as R,a as q}from"./ProcessUtil.a1410eb2.js";const B=e({__name:"workspace",setup(e){const B=a((()=>{const e=["待我处理","已处理的","我发起的","抄送我的"];let a=JSON.parse(JSON.stringify(Y.value));return a=a.filter((a=>e.includes(a))),a[Q.value]=(a[Q.value]||"")+`-${E.value.total||0}`,a})),G=a((()=>I().windowHeight-40)),K=t({current:0,old:0}),Q=t(0),V=t("more"),W=t({pageSize:10,pageNo:1,code:""}),X=t([[],[],[],[]]),E=t({pages:1,size:10,total:0,records:[]});let Y=t([]),Z=t(!0);function ee(e){let a=B.value[Q.value];switch(a.indexOf("-")>=0&&(a=a.split("-")[0]),a){case"待我处理":return{text:"待处理",type:"warning"};case"已处理的":return q(e);case"我发起的":case"抄送我的":return R(e.result)}}function ae(e){Q.value=e.currentIndex,W.value.pageNo=1,le(),K.value.current=K.value.old,m((()=>{K.value.current=0}))}function te(e){K.value.old=e.detail.scrollTop}function se(e){ae({currentIndex:e.target.current||e.detail.current})}function le(){V.value="loading";try{(function(){let e=B.value[Q.value];switch(console.log(B.value,Q.value),e.indexOf("-")>=0&&(e=e.split("-")[0]),e){case"待我处理":return H.getUserTodoList(W.value);case"已处理的":return H.getIdoList(W.value);case"我发起的":return H.getUserSubmittedList(W.value);case"抄送我的":return H.getCcMeList(W.value)}})().then((e=>{g(),E.value.total=e.data.total,1===W.value.pageNo&&(X.value[Q.value].length=0),X.value[Q.value].push(...e.data.records),V.value=W.value.pageNo*W.value.pageSize<E.value.total?"more":"noMore"})).catch((e=>{g()}))}catch(e){console.log(e)}}function re(){W.value.pageNo++,le()}return t(!1),s((e=>{l(),le(),function(){let e=JSON.parse(f("loginUser"));M({projectSn:e.sn,moduleType:7,userId:e.userId}).then((e=>{let a=e.data.result.menuList;Y.value=a.map((e=>e.name));let t=JSON.parse(JSON.stringify(Y.value));const s=["待我处理","已处理的","我发起的","抄送我的"];t=t.filter((e=>s.includes(e))),Y.value=t,X.value.length=t.length,Z.value=!1,console.log(Y.value),le()}))}()})),r("to:workspace",(e=>{ae({currentIndex:e})})),n((()=>o("to:workspace"))),u((()=>{le()})),(e,a)=>{const t=S(N("uni-segmented-control"),$),s=h,l=z,r=S(N("uni-tag"),b),n=S(N("uni-load-more"),C),o=D,u=F,f=P,m=T;return c(Y).length>0?(i(),d(s,{key:0,class:"content"},{default:v((()=>[y(s,{class:"nav-type"},{default:v((()=>[y(t,{current:Q.value,values:B.value,onClickItem:ae,styleType:"text",activeColor:"#4C87F3"},null,8,["current","values"])])),_:1}),y(m,{current:Q.value,duration:300,onChange:se,style:k({height:G.value+"px"})},{default:v((()=>[(i(!0),_(x,null,w(X.value,((e,a)=>(i(),d(f,{class:"datas",key:a},{default:v((()=>[e.length>0?(i(),d(o,{key:0,class:"scrool-more","refresher-threshold":0,onScrolltolower:re,"scroll-top":K.value.current,onScroll:te,enablePullDownRefresh:"",onScrolltoupper:()=>{},"show-scrollbar":!0,style:k({height:G.value+"px"}),"scroll-y":"true","scroll-with-animation":"true"},{default:v((()=>[(i(!0),_(x,null,w(e,((e,a)=>(i(),d(s,{class:"process-item",key:e.instanceId+a,onClick:a=>function(e){L({url:`/pages/instance/instancePreview?instanceId=${e.instanceId}&nodeId=${0===Q.value?e.nodeId:null}`})}(e)},{default:v((()=>[y(s,null,{default:v((()=>[y(l,null,{default:v((()=>[U(j((e.owner||e.staterUser||{}).name)+"提交的 "+j(e.processDefName),1)])),_:2},1024),y(r,{class:"process-item-status",circle:"true",text:ee(e).text,type:ee(e).type,inverted:""},null,8,["text","type"])])),_:2},1024),y(s,{class:"form-content"},{default:v((()=>[(i(!0),_(x,null,w(e.formAbstracts||[],(e=>(i(),d(s,{key:e.id,class:"form-content-it"},{default:v((()=>[y(l,{style:{color:"#b5b5b5"}},{default:v((()=>[U(j(e.name)+": ",1)])),_:2},1024),y(l,{class:"over-tip"},{default:v((()=>[U(j(c(O)(e)),1)])),_:2},1024)])),_:2},1024)))),128))])),_:2},1024),y(s,{class:"process-item-footer"},{default:v((()=>[y(J,{name:(e.owner||e.staterUser).name,src:(e.owner||e.staterUser).avatar,size:30},null,8,["name","src"]),y(l,null,{default:v((()=>[U("在 "+j(e.createTime||e.startTime)+" 提交 ",1)])),_:2},1024)])),_:2},1024)])),_:2},1032,["onClick"])))),128)),y(n,{status:V.value,mode:"scaleToFill",showIcon:!1},null,8,["status"])])),_:2},1032,["scroll-top","style"])):(i(),d(u,{key:1,class:"nodata",src:A,mode:"widthFix"}))])),_:2},1024)))),128))])),_:1},8,["current","style"])])),_:1})):p("",!0)}}},[["__scopeId","data-v-b10ea852"]]);export{B as default};
import{_ as e,p as a,r as t,q as s,Q as l,R as r,T as n,U as o,t as u,J as c,a as i,c as d,w as v,b as p,V as f,A as m,u as g,i as h,d as y,x as _,y as w,F as x,v as k,z as I,B as S,C as N,D as b,G as C,W as T,e as U,H as j,K as O,L as J,P as L,f as z,S as D,k as F,X as P}from"./index-7d490659.js";import{_ as $}from"./uni-segmented-control.ddbfca10.js";import{_ as A}from"./noData.0cd6533e.js";import{t as H}from"./task.327044a8.js";import{g as M}from"./model.b63f5684.js";import{g as R,a as q}from"./ProcessUtil.a1410eb2.js";const B=e({__name:"workspace",setup(e){const B=a((()=>{const e=["待我处理","已处理的","我发起的","抄送我的"];let a=JSON.parse(JSON.stringify(Y.value));return a=a.filter((a=>e.includes(a))),a[Q.value]=(a[Q.value]||"")+`-${E.value.total||0}`,a})),G=a((()=>I().windowHeight-40)),K=t({current:0,old:0}),Q=t(0),V=t("more"),W=t({pageSize:10,pageNo:1,code:""}),X=t([[],[],[],[]]),E=t({pages:1,size:10,total:0,records:[]});let Y=t([]),Z=t(!0);function ee(e){let a=B.value[Q.value];switch(a.indexOf("-")>=0&&(a=a.split("-")[0]),a){case"待我处理":return{text:"待处理",type:"warning"};case"已处理的":return q(e);case"我发起的":case"抄送我的":return R(e.result)}}function ae(e){Q.value=e.currentIndex,W.value.pageNo=1,le(),K.value.current=K.value.old,m((()=>{K.value.current=0}))}function te(e){K.value.old=e.detail.scrollTop}function se(e){ae({currentIndex:e.target.current||e.detail.current})}function le(){V.value="loading";try{(function(){let e=B.value[Q.value];switch(console.log(B.value,Q.value),e.indexOf("-")>=0&&(e=e.split("-")[0]),e){case"待我处理":return H.getUserTodoList(W.value);case"已处理的":return H.getIdoList(W.value);case"我发起的":return H.getUserSubmittedList(W.value);case"抄送我的":return H.getCcMeList(W.value)}})().then((e=>{g(),E.value.total=e.data.total,1===W.value.pageNo&&(X.value[Q.value].length=0),X.value[Q.value].push(...e.data.records),V.value=W.value.pageNo*W.value.pageSize<E.value.total?"more":"noMore"})).catch((e=>{g()}))}catch(e){console.log(e)}}function re(){W.value.pageNo++,le()}return t(!1),s((e=>{l(),le(),function(){let e=JSON.parse(f("loginUser"));M({projectSn:e.sn,moduleType:7,userId:e.userId}).then((e=>{let a=e.data.result.menuList;Y.value=a.map((e=>e.name));let t=JSON.parse(JSON.stringify(Y.value));const s=["待我处理","已处理的","我发起的","抄送我的"];t=t.filter((e=>s.includes(e))),Y.value=t,X.value.length=t.length,Z.value=!1,console.log(Y.value),le()}))}()})),r("to:workspace",(e=>{ae({currentIndex:e})})),n((()=>o("to:workspace"))),u((()=>{le()})),(e,a)=>{const t=S(N("uni-segmented-control"),$),s=h,l=z,r=S(N("uni-tag"),b),n=S(N("uni-load-more"),C),o=D,u=F,f=P,m=T;return c(Y).length>0?(i(),d(s,{key:0,class:"content"},{default:v((()=>[y(s,{class:"nav-type"},{default:v((()=>[y(t,{current:Q.value,values:B.value,onClickItem:ae,styleType:"text",activeColor:"#4C87F3"},null,8,["current","values"])])),_:1}),y(m,{current:Q.value,duration:300,onChange:se,style:k({height:G.value+"px"})},{default:v((()=>[(i(!0),_(x,null,w(X.value,((e,a)=>(i(),d(f,{class:"datas",key:a},{default:v((()=>[e.length>0?(i(),d(o,{key:0,class:"scrool-more","refresher-threshold":0,onScrolltolower:re,"scroll-top":K.value.current,onScroll:te,enablePullDownRefresh:"",onScrolltoupper:()=>{},"show-scrollbar":!0,style:k({height:G.value+"px"}),"scroll-y":"true","scroll-with-animation":"true"},{default:v((()=>[(i(!0),_(x,null,w(e,((e,a)=>(i(),d(s,{class:"process-item",key:e.instanceId+a,onClick:a=>function(e){L({url:`/pages/instance/instancePreview?instanceId=${e.instanceId}&nodeId=${0===Q.value?e.nodeId:null}`})}(e)},{default:v((()=>[y(s,null,{default:v((()=>[y(l,null,{default:v((()=>[U(j((e.owner||e.staterUser||{}).name)+"提交的 "+j(e.processDefName),1)])),_:2},1024),y(r,{class:"process-item-status",circle:"true",text:ee(e).text,type:ee(e).type,inverted:""},null,8,["text","type"])])),_:2},1024),y(s,{class:"form-content"},{default:v((()=>[(i(!0),_(x,null,w(e.formAbstracts||[],(e=>(i(),d(s,{key:e.id,class:"form-content-it"},{default:v((()=>[y(l,{style:{color:"#b5b5b5"}},{default:v((()=>[U(j(e.name)+": ",1)])),_:2},1024),y(l,{class:"over-tip"},{default:v((()=>[U(j(c(O)(e)),1)])),_:2},1024)])),_:2},1024)))),128))])),_:2},1024),y(s,{class:"process-item-footer"},{default:v((()=>[y(J,{name:(e.owner||e.staterUser).name,src:(e.owner||e.staterUser).avatar,size:30},null,8,["name","src"]),y(l,null,{default:v((()=>[U("在 "+j(e.createTime||e.startTime)+" 提交 ",1)])),_:2},1024)])),_:2},1024)])),_:2},1032,["onClick"])))),128)),y(n,{status:V.value,mode:"scaleToFill",showIcon:!1},null,8,["status"])])),_:2},1032,["scroll-top","style"])):(i(),d(u,{key:1,class:"nodata",src:A,mode:"widthFix"}))])),_:2},1024)))),128))])),_:1},8,["current","style"])])),_:1})):p("",!0)}}},[["__scopeId","data-v-b10ea852"]]);export{B as default};

View File

@ -1 +1 @@
import{ay as t}from"./index-25d50b98.js";function e(e,s){return t({url:`wflow/process/progress/${e}/${s}`,method:"get"})}function s(e){return t({url:"wflow/process/task/handler",method:"post",data:e})}function o(e,s){return t({url:"wflow/process/task/recall/nodes",method:"get",data:{instanceId:e,taskId:s}})}function r(e){return t({url:`wflow/process/task/settings/${e}`,method:"get"})}const a={getUserTodoList:function(e){return t({url:"wflow/process/task/todoList",method:"get",data:e})},getUserSubmittedList:function(e){return t({url:"wflow/process/mySubmitted",method:"get",data:e})},getSubmittedList:function(e){return t({url:"wflow/process/submittedList",method:"get",data:e})},getFormAndProcessProgress:e,approvalTask:s,getInstanceFormData:function(e){return t({url:`wflow/process/form/data/by/${e}`,method:"get"})},getEnableRecallNodes:o,getIdoList:function(e){return t({url:"wflow/process/task/idoList",method:"get",data:e})},getCcMeList:function(e){return t({url:"wflow/process/ccMe",method:"get",params:e})},getTaskNodeSettings:r};export{r as a,o as b,s as c,e as g,a as t};
import{ay as t}from"./index-7d490659.js";function e(e,s){return t({url:`wflow/process/progress/${e}/${s}`,method:"get"})}function s(e){return t({url:"wflow/process/task/handler",method:"post",data:e})}function o(e,s){return t({url:"wflow/process/task/recall/nodes",method:"get",data:{instanceId:e,taskId:s}})}function r(e){return t({url:`wflow/process/task/settings/${e}`,method:"get"})}const a={getUserTodoList:function(e){return t({url:"wflow/process/task/todoList",method:"get",data:e})},getUserSubmittedList:function(e){return t({url:"wflow/process/mySubmitted",method:"get",data:e})},getSubmittedList:function(e){return t({url:"wflow/process/submittedList",method:"get",data:e})},getFormAndProcessProgress:e,approvalTask:s,getInstanceFormData:function(e){return t({url:`wflow/process/form/data/by/${e}`,method:"get"})},getEnableRecallNodes:o,getIdoList:function(e){return t({url:"wflow/process/task/idoList",method:"get",data:e})},getCcMeList:function(e){return t({url:"wflow/process/ccMe",method:"get",params:e})},getTaskNodeSettings:r};export{r as a,o as b,s as c,e as g,a as t};

View File

@ -1 +1 @@
import{_ as t,a as e,c as n,w as s,x as r,F as l,y as o,Z as c,v as a,d,e as u,H as y,f as i,i as m}from"./index-25d50b98.js";const x=t({name:"UniSegmentedControl",emits:["clickItem"],props:{current:{type:Number,default:0},values:{type:Array,default:()=>[]},activeColor:{type:String,default:"#2979FF"},styleType:{type:String,default:"button"}},data:()=>({currentIndex:0}),watch:{current(t){t!==this.currentIndex&&(this.currentIndex=t)}},created(){this.currentIndex=this.current},methods:{_onClick(t){this.currentIndex!==t&&(this.currentIndex=t,this.$emit("clickItem",{currentIndex:t}))}}},[["render",function(t,x,_,p,b,f){const g=i,I=m;return e(),n(I,{class:c([["text"===_.styleType?"segmented-control--text":"segmented-control--button"],"segmented-control"]),style:a({borderColor:"text"===_.styleType?"":_.activeColor})},{default:s((()=>[(e(!0),r(l,null,o(_.values,((t,r)=>(e(),n(I,{class:c([["text"===_.styleType?"":"segmented-control__item--button",r===b.currentIndex&&"button"===_.styleType?"segmented-control__item--button--active":"",0===r&&"button"===_.styleType?"segmented-control__item--button--first":"",r===_.values.length-1&&"button"===_.styleType?"segmented-control__item--button--last":""],"segmented-control__item"]),key:r,style:a({backgroundColor:r===b.currentIndex&&"button"===_.styleType?_.activeColor:"",borderColor:r===b.currentIndex&&"text"===_.styleType||"button"===_.styleType?_.activeColor:"transparent"}),onClick:t=>f._onClick(r)},{default:s((()=>[d(I,null,{default:s((()=>[d(g,{style:a({color:r===b.currentIndex?"text"===_.styleType?_.activeColor:"#fff":"text"===_.styleType?"#000":_.activeColor}),class:c(["segmented-control__text","text"===_.styleType&&r===b.currentIndex?"segmented-control__item--text":""])},{default:s((()=>[u(y(t),1)])),_:2},1032,["style","class"])])),_:2},1024)])),_:2},1032,["class","style","onClick"])))),128))])),_:1},8,["class","style"])}],["__scopeId","data-v-bda4a78b"]]);export{x as _};
import{_ as t,a as e,c as n,w as s,x as r,F as l,y as o,Z as c,v as a,d,e as u,H as y,f as i,i as m}from"./index-7d490659.js";const x=t({name:"UniSegmentedControl",emits:["clickItem"],props:{current:{type:Number,default:0},values:{type:Array,default:()=>[]},activeColor:{type:String,default:"#2979FF"},styleType:{type:String,default:"button"}},data:()=>({currentIndex:0}),watch:{current(t){t!==this.currentIndex&&(this.currentIndex=t)}},created(){this.currentIndex=this.current},methods:{_onClick(t){this.currentIndex!==t&&(this.currentIndex=t,this.$emit("clickItem",{currentIndex:t}))}}},[["render",function(t,x,_,p,b,f){const g=i,I=m;return e(),n(I,{class:c([["text"===_.styleType?"segmented-control--text":"segmented-control--button"],"segmented-control"]),style:a({borderColor:"text"===_.styleType?"":_.activeColor})},{default:s((()=>[(e(!0),r(l,null,o(_.values,((t,r)=>(e(),n(I,{class:c([["text"===_.styleType?"":"segmented-control__item--button",r===b.currentIndex&&"button"===_.styleType?"segmented-control__item--button--active":"",0===r&&"button"===_.styleType?"segmented-control__item--button--first":"",r===_.values.length-1&&"button"===_.styleType?"segmented-control__item--button--last":""],"segmented-control__item"]),key:r,style:a({backgroundColor:r===b.currentIndex&&"button"===_.styleType?_.activeColor:"",borderColor:r===b.currentIndex&&"text"===_.styleType||"button"===_.styleType?_.activeColor:"transparent"}),onClick:t=>f._onClick(r)},{default:s((()=>[d(I,null,{default:s((()=>[d(g,{style:a({color:r===b.currentIndex?"text"===_.styleType?_.activeColor:"#fff":"text"===_.styleType?"#000":_.activeColor}),class:c(["segmented-control__text","text"===_.styleType&&r===b.currentIndex?"segmented-control__item--text":""])},{default:s((()=>[u(y(t),1)])),_:2},1032,["style","class"])])),_:2},1024)])),_:2},1032,["class","style","onClick"])))),128))])),_:1},8,["class","style"])}],["__scopeId","data-v-bda4a78b"]]);export{x as _};

View File

@ -14,7 +14,7 @@
<title>wflow-pro工作流</title>
<!--preload-links-->
<!--app-context-->
<script type="module" crossorigin src="/assets/index-25d50b98.js"></script>
<script type="module" crossorigin src="/assets/index-7d490659.js"></script>
<link rel="stylesheet" href="/assets/index-72c81faf.css">
</head>
<body>

View File

@ -95,12 +95,12 @@ export function removeFileTemp(name) {
//下载并打开文件
export function openLocalFile(name, path) {
console.log(path)
let path
//除h5外其他端先看本地有没有没有就下载到本地再打开有就直接打开
// #ifdef H5
window.open(path)
// #endif
console.log(uni.getStorageSync('wflow-token'),999)
// #ifndef H5
let fileObj = uni.getStorageSync('localFile')
if (fileObj && fileObj[name]) {
@ -116,6 +116,11 @@ export function openLocalFile(name, path) {
}
uni.downloadFile({
url: path,
header: {
//大家在这里传自定义的token这里默认wflow的
Authorization: "Bearer " + uni.getStorageSync('wflow-token'),
TenantId: JSON.parse(uni.getStorageSync("loginUser")).sn
},
success: function(res) {
uni.showToast({
icon: 'none',