nbb-component-ui 1.3.8 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.es.js +16 -16
- package/dist/index.umd.js +1 -1
- package/dist/src/api/processInstance.d.ts +1 -1
- package/dist/src/api/task.d.ts +1 -1
- package/package.json +1 -1
- package/src/api/processInstance.ts +2 -2
- package/src/api/task.ts +2 -2
package/dist/index.es.js
CHANGED
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { ElMessage as
|
|
3
|
-
const P =
|
|
1
|
+
import { defineComponent as y, ref as n, watch as k, resolveComponent as w, openBlock as C, createBlock as b, withCtx as q, createTextVNode as x } from "vue";
|
|
2
|
+
import { ElMessage as i } from "element-plus";
|
|
3
|
+
const P = (s) => _().get({
|
|
4
4
|
url: "/system/bpm/process-instance/get-approval-detail",
|
|
5
5
|
params: {
|
|
6
6
|
processInstanceId: s
|
|
7
7
|
}
|
|
8
|
-
}), T =
|
|
8
|
+
}), T = (s) => _().get({
|
|
9
9
|
url: "/system/bpm/task/list-by-process-instance-id",
|
|
10
10
|
params: {
|
|
11
11
|
processInstanceId: s
|
|
12
12
|
}
|
|
13
|
-
}), F = /* @__PURE__ */
|
|
13
|
+
}), F = /* @__PURE__ */ y({
|
|
14
14
|
__name: "CmcProcessFlow",
|
|
15
15
|
props: {
|
|
16
16
|
processInstanceId: {},
|
|
17
17
|
request: {}
|
|
18
18
|
},
|
|
19
19
|
setup(s) {
|
|
20
|
-
const t = s, r = n(!1), p = n({}),
|
|
20
|
+
const t = s, r = n(!1), p = n({}), u = n({}), f = n(""), m = n([]), a = n(""), v = (o) => {
|
|
21
21
|
a.value = o, g(), d();
|
|
22
22
|
}, g = async () => {
|
|
23
23
|
var o, c;
|
|
@@ -25,33 +25,33 @@ const P = async (s) => await _().get({
|
|
|
25
25
|
r.value = !0;
|
|
26
26
|
const e = await P(a.value);
|
|
27
27
|
if (!e) {
|
|
28
|
-
|
|
28
|
+
i.error("查询不到审批详情信息!");
|
|
29
29
|
return;
|
|
30
30
|
}
|
|
31
31
|
if (!e.processDefinition || !e.processInstance) {
|
|
32
|
-
|
|
32
|
+
i.error("查询不到流程信息!");
|
|
33
33
|
return;
|
|
34
34
|
}
|
|
35
|
-
p.value = e == null ? void 0 : e.processInstance, f.value = (c = (o = e == null ? void 0 : e.processInstance) == null ? void 0 : o.formVariables) == null ? void 0 : c.applicationPrefix,
|
|
35
|
+
p.value = e == null ? void 0 : e.processInstance, f.value = (c = (o = e == null ? void 0 : e.processInstance) == null ? void 0 : o.formVariables) == null ? void 0 : c.applicationPrefix, u.value = e == null ? void 0 : e.todoTask;
|
|
36
36
|
} finally {
|
|
37
37
|
r.value = !1;
|
|
38
38
|
}
|
|
39
39
|
}, d = async () => {
|
|
40
40
|
m.value = await T(a.value);
|
|
41
41
|
};
|
|
42
|
-
|
|
42
|
+
k(
|
|
43
43
|
() => t.processInstanceId,
|
|
44
44
|
(o) => {
|
|
45
45
|
o && o !== a.value && v(o);
|
|
46
46
|
},
|
|
47
47
|
{ immediate: !0, deep: !0 }
|
|
48
48
|
);
|
|
49
|
-
const
|
|
50
|
-
|
|
49
|
+
const I = () => {
|
|
50
|
+
i.success("aaa!");
|
|
51
51
|
};
|
|
52
52
|
return (o, c) => {
|
|
53
|
-
const e =
|
|
54
|
-
return C(), b(e, { onClick:
|
|
53
|
+
const e = w("el-button");
|
|
54
|
+
return C(), b(e, { onClick: I }, {
|
|
55
55
|
default: q(() => [...c[0] || (c[0] = [
|
|
56
56
|
x("测试按钮3", -1)
|
|
57
57
|
])]),
|
|
@@ -62,8 +62,8 @@ const P = async (s) => await _().get({
|
|
|
62
62
|
});
|
|
63
63
|
const h = (s, t) => {
|
|
64
64
|
const r = s.__vccOpts || s;
|
|
65
|
-
for (const [p,
|
|
66
|
-
r[p] =
|
|
65
|
+
for (const [p, u] of t)
|
|
66
|
+
r[p] = u;
|
|
67
67
|
return r;
|
|
68
68
|
}, B = /* @__PURE__ */ h(F, [["__scopeId", "data-v-e422ef37"]]);
|
|
69
69
|
let l = null;
|
package/dist/index.umd.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(t,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("element-plus")):typeof define=="function"&&define.amd?define(["exports","vue","element-plus"],e):(t=typeof globalThis<"u"?globalThis:t||self,e(t.NbbComponentUi={},t.Vue,t.ElementPlus))})(this,function(t,e,p){"use strict";const m=
|
|
1
|
+
(function(t,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("element-plus")):typeof define=="function"&&define.amd?define(["exports","vue","element-plus"],e):(t=typeof globalThis<"u"?globalThis:t||self,e(t.NbbComponentUi={},t.Vue,t.ElementPlus))})(this,function(t,e,p){"use strict";const m=n=>u().get({url:"/system/bpm/process-instance/get-approval-detail",params:{processInstanceId:n}}),g=n=>u().get({url:"/system/bpm/task/list-by-process-instance-id",params:{processInstanceId:n}}),y=e.defineComponent({__name:"CmcProcessFlow",props:{processInstanceId:{},request:{}},setup(n){const o=n,c=e.ref(!1),f=e.ref({}),_=e.ref({}),b=e.ref(""),q=e.ref([]),i=e.ref(""),v=r=>{i.value=r,w(),C()},w=async()=>{var r,a;try{c.value=!0;const s=await m(i.value);if(!s){p.ElMessage.error("查询不到审批详情信息!");return}if(!s.processDefinition||!s.processInstance){p.ElMessage.error("查询不到流程信息!");return}f.value=s==null?void 0:s.processInstance,b.value=(a=(r=s==null?void 0:s.processInstance)==null?void 0:r.formVariables)==null?void 0:a.applicationPrefix,_.value=s==null?void 0:s.todoTask}finally{c.value=!1}},C=async()=>{q.value=await g(i.value)};e.watch(()=>o.processInstanceId,r=>{r&&r!==i.value&&v(r)},{immediate:!0,deep:!0});const k=()=>{p.ElMessage.success("aaa!")};return(r,a)=>{const s=e.resolveComponent("el-button");return e.openBlock(),e.createBlock(s,{onClick:k},{default:e.withCtx(()=>[...a[0]||(a[0]=[e.createTextVNode("测试按钮3",-1)])]),_:1})}}}),x="",d=((n,o)=>{const c=n.__vccOpts||n;for(const[f,_]of o)c[f]=_;return c})(y,[["__scopeId","data-v-e422ef37"]]);let l=null;const I={install(n,o){if(console.log("插件install执行,options:",o),!(o!=null&&o.request))throw new Error("请在 app.use(NbbComponentUi) 时传入 { request }");l=o.request,n.component("CmcProcessFlow",d)}};function u(){if(console.log("getRequest",l),!l)throw new Error("没有_request对象");return l}t.CmcProcessFlow=d,t.default=I,t.getRequest=u,Object.defineProperties(t,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const getApprovalDetail: (processInstanceId: string) =>
|
|
1
|
+
export declare const getApprovalDetail: (processInstanceId: string) => any;
|
package/dist/src/api/task.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const getTaskListByProcessInstanceId: (processInstanceId: string) =>
|
|
1
|
+
export declare const getTaskListByProcessInstanceId: (processInstanceId: string) => any;
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import {getRequest} from "../../index";
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
export const getApprovalDetail =
|
|
5
|
-
return
|
|
4
|
+
export const getApprovalDetail = (processInstanceId: string) => {
|
|
5
|
+
return getRequest().get({
|
|
6
6
|
url: `/system/bpm/process-instance/get-approval-detail`,
|
|
7
7
|
params: {
|
|
8
8
|
processInstanceId
|
package/src/api/task.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import {getRequest} from "../../index";
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
export const getTaskListByProcessInstanceId =
|
|
5
|
-
return
|
|
4
|
+
export const getTaskListByProcessInstanceId = (processInstanceId: string) => {
|
|
5
|
+
return getRequest().get({
|
|
6
6
|
url: `/system/bpm/task/list-by-process-instance-id`,
|
|
7
7
|
params: {
|
|
8
8
|
processInstanceId
|