一单n制等功能,接入随手拍之前我先提交一版本
This commit is contained in:
@@ -10,7 +10,7 @@ const _imports_1$2 = "/static/my/Notification.png";
|
||||
const _imports_2 = "/static/my/Account.png";
|
||||
const _imports_0$3 = "/static/my/Customer service.png";
|
||||
const _imports_1$1 = "/static/my/Phone.png";
|
||||
const _imports_0$2 = "/static/index/index_bg.png";
|
||||
const _imports_0$2 = "/static/logo1.png";
|
||||
const _imports_0$1 = "/static/index/phone.png";
|
||||
const _imports_1 = "/static/index/lock.png";
|
||||
const _imports_0 = "/static/index/蒙版组 260.png";
|
||||
|
||||
@@ -7141,7 +7141,7 @@ function isConsoleWritable() {
|
||||
function initRuntimeSocketService() {
|
||||
const hosts = "172.30.48.1,192.168.1.144,127.0.0.1";
|
||||
const port = "8090";
|
||||
const id = "mp-weixin_6yA7g3";
|
||||
const id = "mp-weixin_f-DRnr";
|
||||
const lazy = typeof swan !== "undefined";
|
||||
let restoreError = lazy ? () => {
|
||||
} : initOnError();
|
||||
|
||||
@@ -123,48 +123,47 @@ const _sfc_main = {
|
||||
d: common_vendor.t(fieldText(item, item.operator)),
|
||||
e: common_vendor.t(fieldText(item, item.time))
|
||||
} : {
|
||||
f: common_vendor.t(common_vendor.unref(labels).executorPrefix),
|
||||
g: common_vendor.t(common_vendor.unref(labels).personnelSuffix),
|
||||
h: common_vendor.t(fieldText(item, item.currentHandlerName)),
|
||||
i: common_vendor.t(common_vendor.unref(labels).statusSuffix),
|
||||
j: common_vendor.t(common_vendor.unref(components_hazardDetail_processChain.PENDING_LABEL))
|
||||
f: common_vendor.t(common_vendor.unref(labels).nextHandlerLabel),
|
||||
g: common_vendor.t(fieldText(item, item.currentHandlerName)),
|
||||
h: common_vendor.t(common_vendor.unref(labels).statusSuffix),
|
||||
i: common_vendor.t(common_vendor.unref(components_hazardDetail_processChain.PENDING_LABEL))
|
||||
}, {
|
||||
k: item.completed && item.type === "add" && item.content.levelName
|
||||
j: item.completed && item.type === "add" && item.content.levelName
|
||||
}, item.completed && item.type === "add" && item.content.levelName ? {
|
||||
l: common_vendor.t(item.content.levelName),
|
||||
m: common_vendor.n(getLevelTagClass(item.content))
|
||||
k: common_vendor.t(item.content.levelName),
|
||||
l: common_vendor.n(getLevelTagClass(item.content))
|
||||
} : {}, {
|
||||
n: item.completed
|
||||
m: item.completed
|
||||
}, item.completed ? {} : {}, {
|
||||
o: item.completed
|
||||
n: item.completed
|
||||
}, item.completed ? common_vendor.e({
|
||||
p: item.type === "add"
|
||||
o: item.type === "add"
|
||||
}, item.type === "add" ? common_vendor.e({
|
||||
q: common_vendor.t(common_vendor.unref(labels).hazardCode),
|
||||
r: common_vendor.t(fieldText(item, item.content.code)),
|
||||
s: common_vendor.t(common_vendor.unref(labels).hazardTitle),
|
||||
t: common_vendor.t(fieldText(item, item.content.title)),
|
||||
v: common_vendor.t(common_vendor.unref(labels).checkSource),
|
||||
w: common_vendor.t(fieldText(item, item.content.source)),
|
||||
x: common_vendor.t(common_vendor.unref(labels).hazardSource),
|
||||
y: common_vendor.t(fieldText(item, item.content.hazardSourceName)),
|
||||
z: common_vendor.t(common_vendor.unref(labels).hazardArea),
|
||||
A: common_vendor.t(fieldText(item, item.content.areaName)),
|
||||
B: common_vendor.t(common_vendor.unref(labels).address),
|
||||
C: common_vendor.t(fieldText(item, item.content.address)),
|
||||
D: common_vendor.t(common_vendor.unref(labels).hazardLevel),
|
||||
E: common_vendor.t(fieldText(item, item.content.levelName)),
|
||||
F: common_vendor.n(getLevelTagClass(item.content)),
|
||||
G: common_vendor.t(common_vendor.unref(labels).hazardTag),
|
||||
H: common_vendor.t(fieldText(item, item.content.tagName)),
|
||||
I: common_vendor.t(common_vendor.unref(labels).description),
|
||||
J: common_vendor.t(fieldText(item, item.content.description)),
|
||||
K: item.content.attachments && item.content.attachments.length || !item.completed
|
||||
p: common_vendor.t(common_vendor.unref(labels).hazardCode),
|
||||
q: common_vendor.t(fieldText(item, item.content.code)),
|
||||
r: common_vendor.t(common_vendor.unref(labels).hazardTitle),
|
||||
s: common_vendor.t(fieldText(item, item.content.title)),
|
||||
t: common_vendor.t(common_vendor.unref(labels).checkSource),
|
||||
v: common_vendor.t(fieldText(item, item.content.source)),
|
||||
w: common_vendor.t(common_vendor.unref(labels).hazardSource),
|
||||
x: common_vendor.t(fieldText(item, item.content.hazardSourceName)),
|
||||
y: common_vendor.t(common_vendor.unref(labels).hazardArea),
|
||||
z: common_vendor.t(fieldText(item, item.content.areaName)),
|
||||
A: common_vendor.t(common_vendor.unref(labels).address),
|
||||
B: common_vendor.t(fieldText(item, item.content.address)),
|
||||
C: common_vendor.t(common_vendor.unref(labels).hazardLevel),
|
||||
D: common_vendor.t(fieldText(item, item.content.levelName)),
|
||||
E: common_vendor.n(getLevelTagClass(item.content)),
|
||||
F: common_vendor.t(common_vendor.unref(labels).hazardTag),
|
||||
G: common_vendor.t(fieldText(item, item.content.tagName)),
|
||||
H: common_vendor.t(common_vendor.unref(labels).description),
|
||||
I: common_vendor.t(fieldText(item, item.content.description)),
|
||||
J: item.content.attachments && item.content.attachments.length || !item.completed
|
||||
}, item.content.attachments && item.content.attachments.length || !item.completed ? common_vendor.e({
|
||||
L: common_vendor.t(common_vendor.unref(labels).hazardAttachments),
|
||||
M: item.content.attachments && item.content.attachments.length
|
||||
K: common_vendor.t(common_vendor.unref(labels).hazardAttachments),
|
||||
L: item.content.attachments && item.content.attachments.length
|
||||
}, item.content.attachments && item.content.attachments.length ? {
|
||||
N: common_vendor.f(item.content.attachments, (file, idx, i1) => {
|
||||
M: common_vendor.f(item.content.attachments, (file, idx, i1) => {
|
||||
return {
|
||||
a: idx,
|
||||
b: resolveFileUrl(file.filePath),
|
||||
@@ -173,44 +172,44 @@ const _sfc_main = {
|
||||
};
|
||||
})
|
||||
} : {
|
||||
O: common_vendor.t(fieldText(item, ""))
|
||||
N: common_vendor.t(fieldText(item, ""))
|
||||
}) : {}, {
|
||||
P: common_vendor.t(common_vendor.unref(labels).legalBasis),
|
||||
Q: common_vendor.t(fieldText(item, item.content.legalBasis))
|
||||
O: common_vendor.t(common_vendor.unref(labels).legalBasis),
|
||||
P: common_vendor.t(fieldText(item, item.content.legalBasis))
|
||||
}) : item.type === "assign" ? {
|
||||
S: common_vendor.t(common_vendor.unref(labels).assigneeName),
|
||||
T: common_vendor.t(fieldText(item, item.content.assigneeName)),
|
||||
U: common_vendor.t(common_vendor.unref(labels).assignDeadline),
|
||||
V: common_vendor.t(fieldText(item, item.content.deadline)),
|
||||
W: common_vendor.t(common_vendor.unref(labels).assignStatus),
|
||||
X: common_vendor.t(fieldText(item, item.content.assignStatusName))
|
||||
R: common_vendor.t(common_vendor.unref(labels).assigneeName),
|
||||
S: common_vendor.t(fieldText(item, item.content.assigneeName)),
|
||||
T: common_vendor.t(common_vendor.unref(labels).assignDeadline),
|
||||
U: common_vendor.t(fieldText(item, item.content.deadline)),
|
||||
V: common_vendor.t(common_vendor.unref(labels).assignStatus),
|
||||
W: common_vendor.t(fieldText(item, item.content.assignStatusName))
|
||||
} : item.type === "rectify" ? common_vendor.e({
|
||||
Z: common_vendor.t(common_vendor.unref(labels).rectifyStatus),
|
||||
aa: common_vendor.t(fieldText(item, item.content.rectifyStatusName)),
|
||||
ab: common_vendor.t(common_vendor.unref(labels).rectifyPlan),
|
||||
ac: common_vendor.t(fieldText(item, item.content.rectifyPlan)),
|
||||
ad: common_vendor.t(common_vendor.unref(labels).rectifyResult),
|
||||
ae: common_vendor.t(fieldText(item, item.content.rectifyResult)),
|
||||
af: common_vendor.t(common_vendor.unref(labels).rectifyMeasures),
|
||||
ag: common_vendor.t(fieldText(item, item.content.rectificationMeasures)),
|
||||
ah: common_vendor.t(common_vendor.unref(labels).controlMeasures),
|
||||
ai: common_vendor.t(fieldText(item, item.content.controlMeasures)),
|
||||
aj: common_vendor.t(common_vendor.unref(labels).rectifierName),
|
||||
ak: common_vendor.t(fieldText(item, item.content.rectifierName)),
|
||||
al: common_vendor.t(common_vendor.unref(labels).managerNames),
|
||||
am: common_vendor.t(fieldText(item, item.content.managerNames)),
|
||||
an: common_vendor.t(common_vendor.unref(labels).memberNames),
|
||||
ao: common_vendor.t(fieldText(item, item.content.memberNames)),
|
||||
ap: common_vendor.t(common_vendor.unref(labels).planCost),
|
||||
aq: common_vendor.t(formatCost(item.content.planCost, item.completed)),
|
||||
ar: common_vendor.t(common_vendor.unref(labels).actualCost),
|
||||
as: common_vendor.t(formatCost(item.content.actualCost, item.completed)),
|
||||
at: item.content.attachments && item.content.attachments.length || !item.completed
|
||||
Y: common_vendor.t(common_vendor.unref(labels).rectifyStatus),
|
||||
Z: common_vendor.t(fieldText(item, item.content.rectifyStatusName)),
|
||||
aa: common_vendor.t(common_vendor.unref(labels).rectifyPlan),
|
||||
ab: common_vendor.t(fieldText(item, item.content.rectifyPlan)),
|
||||
ac: common_vendor.t(common_vendor.unref(labels).rectifyResult),
|
||||
ad: common_vendor.t(fieldText(item, item.content.rectifyResult)),
|
||||
ae: common_vendor.t(common_vendor.unref(labels).rectifyMeasures),
|
||||
af: common_vendor.t(fieldText(item, item.content.rectificationMeasures)),
|
||||
ag: common_vendor.t(common_vendor.unref(labels).controlMeasures),
|
||||
ah: common_vendor.t(fieldText(item, item.content.controlMeasures)),
|
||||
ai: common_vendor.t(common_vendor.unref(labels).rectifierName),
|
||||
aj: common_vendor.t(fieldText(item, item.content.rectifierName)),
|
||||
ak: common_vendor.t(common_vendor.unref(labels).managerNames),
|
||||
al: common_vendor.t(fieldText(item, item.content.managerNames)),
|
||||
am: common_vendor.t(common_vendor.unref(labels).memberNames),
|
||||
an: common_vendor.t(fieldText(item, item.content.memberNames)),
|
||||
ao: common_vendor.t(common_vendor.unref(labels).planCost),
|
||||
ap: common_vendor.t(formatCost(item.content.planCost, item.completed)),
|
||||
aq: common_vendor.t(common_vendor.unref(labels).actualCost),
|
||||
ar: common_vendor.t(formatCost(item.content.actualCost, item.completed)),
|
||||
as: item.content.attachments && item.content.attachments.length || !item.completed
|
||||
}, item.content.attachments && item.content.attachments.length || !item.completed ? common_vendor.e({
|
||||
av: common_vendor.t(common_vendor.unref(labels).rectifyAttachments),
|
||||
aw: item.content.attachments && item.content.attachments.length
|
||||
at: common_vendor.t(common_vendor.unref(labels).rectifyAttachments),
|
||||
av: item.content.attachments && item.content.attachments.length
|
||||
}, item.content.attachments && item.content.attachments.length ? {
|
||||
ax: common_vendor.f(item.content.attachments, (file, idx, i1) => {
|
||||
aw: common_vendor.f(item.content.attachments, (file, idx, i1) => {
|
||||
return common_vendor.e({
|
||||
a: file.fileType === "image" || !file.fileType
|
||||
}, file.fileType === "image" || !file.fileType ? {
|
||||
@@ -224,38 +223,38 @@ const _sfc_main = {
|
||||
});
|
||||
})
|
||||
} : {
|
||||
ay: common_vendor.t(fieldText(item, ""))
|
||||
ax: common_vendor.t(fieldText(item, ""))
|
||||
}) : {}, {
|
||||
az: item.content.signPath || !item.completed
|
||||
ay: item.content.signPath || !item.completed
|
||||
}, item.content.signPath || !item.completed ? common_vendor.e({
|
||||
aA: common_vendor.t(common_vendor.unref(labels).rectifySign),
|
||||
aB: item.content.signPath
|
||||
az: common_vendor.t(common_vendor.unref(labels).rectifySign),
|
||||
aA: item.content.signPath
|
||||
}, item.content.signPath ? {
|
||||
aC: resolveFileUrl(item.content.signPath),
|
||||
aD: common_vendor.o(($event) => previewSingle(item.content.signPath), "node-" + index),
|
||||
aE: common_vendor.o((...args) => common_vendor.unref(scheduleMeasureLayout) && common_vendor.unref(scheduleMeasureLayout)(...args), "node-" + index)
|
||||
aB: resolveFileUrl(item.content.signPath),
|
||||
aC: common_vendor.o(($event) => previewSingle(item.content.signPath), "node-" + index),
|
||||
aD: common_vendor.o((...args) => common_vendor.unref(scheduleMeasureLayout) && common_vendor.unref(scheduleMeasureLayout)(...args), "node-" + index)
|
||||
} : {
|
||||
aF: common_vendor.t(fieldText(item, ""))
|
||||
aE: common_vendor.t(fieldText(item, ""))
|
||||
}) : {}) : item.type === "verify" || item.type === "writeoff_approve" ? common_vendor.e({
|
||||
aH: common_vendor.t(common_vendor.unref(labels).verifyResult),
|
||||
aI: item.completed && item.content.resultName
|
||||
aG: common_vendor.t(common_vendor.unref(labels).verifyResult),
|
||||
aH: item.completed && item.content.resultName
|
||||
}, item.completed && item.content.resultName ? {
|
||||
aJ: common_vendor.t(item.content.resultName),
|
||||
aK: common_vendor.n(item.content.resultName === common_vendor.unref(labels).pass ? "result-tag--pass" : "result-tag--fail")
|
||||
aI: common_vendor.t(item.content.resultName),
|
||||
aJ: common_vendor.n(item.content.resultName === common_vendor.unref(labels).pass ? "result-tag--pass" : "result-tag--fail")
|
||||
} : {
|
||||
aL: common_vendor.t(fieldText(item, item.content.resultName))
|
||||
aK: common_vendor.t(fieldText(item, item.content.resultName))
|
||||
}, {
|
||||
aM: item.content.remark || !item.completed
|
||||
aL: item.content.remark || !item.completed
|
||||
}, item.content.remark || !item.completed ? {
|
||||
aN: common_vendor.t(common_vendor.unref(labels).verifyRemark),
|
||||
aO: common_vendor.t(fieldText(item, item.content.remark))
|
||||
aM: common_vendor.t(common_vendor.unref(labels).verifyRemark),
|
||||
aN: common_vendor.t(fieldText(item, item.content.remark))
|
||||
} : {}, {
|
||||
aP: item.content.attachments && item.content.attachments.length || !item.completed
|
||||
aO: item.content.attachments && item.content.attachments.length || !item.completed
|
||||
}, item.content.attachments && item.content.attachments.length || !item.completed ? common_vendor.e({
|
||||
aQ: common_vendor.t(common_vendor.unref(labels).verifyAttachments),
|
||||
aR: item.content.attachments && item.content.attachments.length
|
||||
aP: common_vendor.t(common_vendor.unref(labels).verifyAttachments),
|
||||
aQ: item.content.attachments && item.content.attachments.length
|
||||
}, item.content.attachments && item.content.attachments.length ? {
|
||||
aS: common_vendor.f(item.content.attachments, (file, idx, i1) => {
|
||||
aR: common_vendor.f(item.content.attachments, (file, idx, i1) => {
|
||||
return common_vendor.e({
|
||||
a: file.fileType === "image" || !file.fileType
|
||||
}, file.fileType === "image" || !file.fileType ? {
|
||||
@@ -269,81 +268,81 @@ const _sfc_main = {
|
||||
});
|
||||
})
|
||||
} : {
|
||||
aT: common_vendor.t(fieldText(item, ""))
|
||||
aS: common_vendor.t(fieldText(item, ""))
|
||||
}) : {}, {
|
||||
aU: item.content.signPath || !item.completed
|
||||
aT: item.content.signPath || !item.completed
|
||||
}, item.content.signPath || !item.completed ? common_vendor.e({
|
||||
aV: common_vendor.t(common_vendor.unref(labels).verifySign),
|
||||
aW: item.content.signPath
|
||||
aU: common_vendor.t(common_vendor.unref(labels).verifySign),
|
||||
aV: item.content.signPath
|
||||
}, item.content.signPath ? {
|
||||
aX: resolveFileUrl(item.content.signPath),
|
||||
aY: common_vendor.o(($event) => previewSingle(item.content.signPath), "node-" + index),
|
||||
aZ: common_vendor.o((...args) => common_vendor.unref(scheduleMeasureLayout) && common_vendor.unref(scheduleMeasureLayout)(...args), "node-" + index)
|
||||
aW: resolveFileUrl(item.content.signPath),
|
||||
aX: common_vendor.o(($event) => previewSingle(item.content.signPath), "node-" + index),
|
||||
aY: common_vendor.o((...args) => common_vendor.unref(scheduleMeasureLayout) && common_vendor.unref(scheduleMeasureLayout)(...args), "node-" + index)
|
||||
} : {
|
||||
ba: common_vendor.t(fieldText(item, ""))
|
||||
aZ: common_vendor.t(fieldText(item, ""))
|
||||
}) : {}) : item.type === "writeoff_apply" ? common_vendor.e({
|
||||
bc: common_vendor.t(common_vendor.unref(labels).writeoffDeadline),
|
||||
bd: common_vendor.t(fieldText(item, item.content.rectifyDeadline)),
|
||||
be: common_vendor.t(common_vendor.unref(labels).responsibleDept),
|
||||
bf: common_vendor.t(fieldText(item, item.content.responsibleDeptName)),
|
||||
bg: common_vendor.t(common_vendor.unref(labels).responsiblePerson),
|
||||
bh: common_vendor.t(fieldText(item, item.content.responsiblePerson)),
|
||||
bi: common_vendor.t(common_vendor.unref(labels).mainTreatment),
|
||||
bj: common_vendor.t(fieldText(item, item.content.mainTreatmentContent)),
|
||||
bk: common_vendor.t(common_vendor.unref(labels).treatmentResult),
|
||||
bl: common_vendor.t(fieldText(item, item.content.treatmentResult)),
|
||||
bm: common_vendor.t(common_vendor.unref(labels).selfVerify),
|
||||
bn: common_vendor.t(fieldText(item, item.content.selfVerifyContent)),
|
||||
bo: item.content.signPath || !item.completed
|
||||
bb: common_vendor.t(common_vendor.unref(labels).writeoffDeadline),
|
||||
bc: common_vendor.t(fieldText(item, item.content.rectifyDeadline)),
|
||||
bd: common_vendor.t(common_vendor.unref(labels).responsibleDept),
|
||||
be: common_vendor.t(fieldText(item, item.content.responsibleDeptName)),
|
||||
bf: common_vendor.t(common_vendor.unref(labels).responsiblePerson),
|
||||
bg: common_vendor.t(fieldText(item, item.content.responsiblePerson)),
|
||||
bh: common_vendor.t(common_vendor.unref(labels).mainTreatment),
|
||||
bi: common_vendor.t(fieldText(item, item.content.mainTreatmentContent)),
|
||||
bj: common_vendor.t(common_vendor.unref(labels).treatmentResult),
|
||||
bk: common_vendor.t(fieldText(item, item.content.treatmentResult)),
|
||||
bl: common_vendor.t(common_vendor.unref(labels).selfVerify),
|
||||
bm: common_vendor.t(fieldText(item, item.content.selfVerifyContent)),
|
||||
bn: item.content.signPath || !item.completed
|
||||
}, item.content.signPath || !item.completed ? common_vendor.e({
|
||||
bp: common_vendor.t(common_vendor.unref(labels).applySign),
|
||||
bq: item.content.signPath
|
||||
bo: common_vendor.t(common_vendor.unref(labels).applySign),
|
||||
bp: item.content.signPath
|
||||
}, item.content.signPath ? {
|
||||
br: resolveFileUrl(item.content.signPath),
|
||||
bs: common_vendor.o(($event) => previewSingle(item.content.signPath), "node-" + index),
|
||||
bt: common_vendor.o((...args) => common_vendor.unref(scheduleMeasureLayout) && common_vendor.unref(scheduleMeasureLayout)(...args), "node-" + index)
|
||||
bq: resolveFileUrl(item.content.signPath),
|
||||
br: common_vendor.o(($event) => previewSingle(item.content.signPath), "node-" + index),
|
||||
bs: common_vendor.o((...args) => common_vendor.unref(scheduleMeasureLayout) && common_vendor.unref(scheduleMeasureLayout)(...args), "node-" + index)
|
||||
} : {
|
||||
bv: common_vendor.t(fieldText(item, ""))
|
||||
bt: common_vendor.t(fieldText(item, ""))
|
||||
}) : {}) : item.type === "approval" ? common_vendor.e({
|
||||
bx: common_vendor.t(common_vendor.unref(labels).approvalOpinion),
|
||||
by: item.completed && item.content.approveTypeName
|
||||
bw: common_vendor.t(common_vendor.unref(labels).approvalOpinion),
|
||||
bx: item.completed && item.content.approveTypeName
|
||||
}, item.completed && item.content.approveTypeName ? {
|
||||
bz: common_vendor.t(item.content.approveTypeName),
|
||||
bA: common_vendor.n(item.content.pass ? "result-tag--pass" : "result-tag--fail")
|
||||
by: common_vendor.t(item.content.approveTypeName),
|
||||
bz: common_vendor.n(item.content.pass ? "result-tag--pass" : "result-tag--fail")
|
||||
} : {
|
||||
bB: common_vendor.t(fieldText(item, item.content.approveTypeName))
|
||||
bA: common_vendor.t(fieldText(item, item.content.approveTypeName))
|
||||
}, {
|
||||
bC: common_vendor.t(common_vendor.unref(labels).approvalComment),
|
||||
bD: common_vendor.t(fieldText(item, item.content.comment)),
|
||||
bE: isPendingText(item, item.content.comment) ? 1 : "",
|
||||
bF: common_vendor.t(common_vendor.unref(labels).smsReminder),
|
||||
bG: item.content.sendMsgFlag != null
|
||||
bB: common_vendor.t(common_vendor.unref(labels).approvalComment),
|
||||
bC: common_vendor.t(fieldText(item, item.content.comment)),
|
||||
bD: isPendingText(item, item.content.comment) ? 1 : "",
|
||||
bE: common_vendor.t(common_vendor.unref(labels).smsReminder),
|
||||
bF: item.content.sendMsgFlag != null
|
||||
}, item.content.sendMsgFlag != null ? {
|
||||
bH: common_vendor.t(item.content.sendMsgFlag ? common_vendor.unref(labels).yes : common_vendor.unref(labels).no)
|
||||
bG: common_vendor.t(item.content.sendMsgFlag ? common_vendor.unref(labels).yes : common_vendor.unref(labels).no)
|
||||
} : {
|
||||
bI: common_vendor.t(fieldText(item, ""))
|
||||
bH: common_vendor.t(fieldText(item, ""))
|
||||
}, {
|
||||
bJ: item.content.signPath || !item.completed
|
||||
bI: item.content.signPath || !item.completed
|
||||
}, item.content.signPath || !item.completed ? common_vendor.e({
|
||||
bK: common_vendor.t(common_vendor.unref(labels).approvalSign),
|
||||
bL: item.content.signPath
|
||||
bJ: common_vendor.t(common_vendor.unref(labels).approvalSign),
|
||||
bK: item.content.signPath
|
||||
}, item.content.signPath ? {
|
||||
bM: resolveFileUrl(item.content.signPath),
|
||||
bN: common_vendor.o(($event) => previewSingle(item.content.signPath), "node-" + index),
|
||||
bO: common_vendor.o((...args) => common_vendor.unref(scheduleMeasureLayout) && common_vendor.unref(scheduleMeasureLayout)(...args), "node-" + index)
|
||||
bL: resolveFileUrl(item.content.signPath),
|
||||
bM: common_vendor.o(($event) => previewSingle(item.content.signPath), "node-" + index),
|
||||
bN: common_vendor.o((...args) => common_vendor.unref(scheduleMeasureLayout) && common_vendor.unref(scheduleMeasureLayout)(...args), "node-" + index)
|
||||
} : {
|
||||
bP: common_vendor.t(fieldText(item, ""))
|
||||
bO: common_vendor.t(fieldText(item, ""))
|
||||
}) : {}) : {}, {
|
||||
R: item.type === "assign",
|
||||
Y: item.type === "rectify",
|
||||
aG: item.type === "verify" || item.type === "writeoff_approve",
|
||||
bb: item.type === "writeoff_apply",
|
||||
bw: item.type === "approval"
|
||||
Q: item.type === "assign",
|
||||
X: item.type === "rectify",
|
||||
aF: item.type === "verify" || item.type === "writeoff_approve",
|
||||
ba: item.type === "writeoff_apply",
|
||||
bv: item.type === "approval"
|
||||
}) : {}, {
|
||||
bQ: common_vendor.unref(activeIndex) === index ? 1 : "",
|
||||
bR: "node-" + index,
|
||||
bS: "process-node-" + index,
|
||||
bT: index === common_vendor.unref(historyList).length - 1 ? 1 : ""
|
||||
bP: common_vendor.unref(activeIndex) === index ? 1 : "",
|
||||
bQ: "node-" + index,
|
||||
bR: "process-node-" + index,
|
||||
bS: index === common_vendor.unref(historyList).length - 1 ? 1 : ""
|
||||
});
|
||||
}),
|
||||
i: common_vendor.s(scrollAreaStyle.value),
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -3,7 +3,7 @@ const CHAIN_LABELS = {
|
||||
loading: "加载中...",
|
||||
empty: "暂无流程记录",
|
||||
personnelSuffix: "人员:",
|
||||
executorPrefix: "执行",
|
||||
nextHandlerLabel: "下一步处理人:",
|
||||
statusSuffix: "状态:",
|
||||
hazardCode: "隐患编号",
|
||||
hazardTitle: "隐患标题",
|
||||
|
||||
@@ -24,7 +24,7 @@ const _sfc_main = {
|
||||
if (runMode === 4) {
|
||||
const rosterItems = detail.value.rosterItems || [];
|
||||
if (rosterItems.length > 0) {
|
||||
return rosterItems.map((item) => item.identityName).filter(Boolean).join("、") || "-";
|
||||
return rosterItems.map((item) => (item.userName || item.identityName || "").trim()).filter(Boolean).join("、") || "-";
|
||||
}
|
||||
return "-";
|
||||
}
|
||||
@@ -49,7 +49,7 @@ const _sfc_main = {
|
||||
common_vendor.index.showToast({ title: res.msg || "获取详情失败", icon: "none" });
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/checklist/detail.vue:145", "获取检查计划详情失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/checklist/detail.vue:148", "获取检查计划详情失败:", error);
|
||||
common_vendor.index.showToast({ title: "获取详情失败", icon: "none" });
|
||||
} finally {
|
||||
loading.value = false;
|
||||
|
||||
217
unpackage/dist/dev/mp-weixin/pages/closeout/apply.js
vendored
217
unpackage/dist/dev/mp-weixin/pages/closeout/apply.js
vendored
@@ -7,16 +7,14 @@ if (!Array) {
|
||||
const _easycom_up_radio2 = common_vendor.resolveComponent("up-radio");
|
||||
const _easycom_up_radio_group2 = common_vendor.resolveComponent("up-radio-group");
|
||||
const _easycom_up_picker2 = common_vendor.resolveComponent("up-picker");
|
||||
const _easycom_u_popup2 = common_vendor.resolveComponent("u-popup");
|
||||
(_easycom_up_textarea2 + _easycom_up_radio2 + _easycom_up_radio_group2 + _easycom_up_picker2 + _easycom_u_popup2)();
|
||||
(_easycom_up_textarea2 + _easycom_up_radio2 + _easycom_up_radio_group2 + _easycom_up_picker2)();
|
||||
}
|
||||
const _easycom_up_textarea = () => "../../uni_modules/uview-plus/components/u-textarea/u-textarea.js";
|
||||
const _easycom_up_radio = () => "../../uni_modules/uview-plus/components/u-radio/u-radio.js";
|
||||
const _easycom_up_radio_group = () => "../../uni_modules/uview-plus/components/u-radio-group/u-radio-group.js";
|
||||
const _easycom_up_picker = () => "../../uni_modules/uview-plus/components/u-picker/u-picker.js";
|
||||
const _easycom_u_popup = () => "../../uni_modules/uview-plus/components/u-popup/u-popup.js";
|
||||
if (!Math) {
|
||||
(_easycom_up_textarea + _easycom_up_radio + _easycom_up_radio_group + _easycom_up_picker + _easycom_u_popup)();
|
||||
(_easycom_up_textarea + _easycom_up_radio + _easycom_up_radio_group + _easycom_up_picker)();
|
||||
}
|
||||
const _sfc_main = {
|
||||
__name: "apply",
|
||||
@@ -31,6 +29,9 @@ const _sfc_main = {
|
||||
const selectableHazardList = common_vendor.ref([]);
|
||||
const selectedDeptName = common_vendor.ref("");
|
||||
const aiGenerating = common_vendor.ref(false);
|
||||
const hazardEndRadio = common_vendor.ref("no");
|
||||
const hazardEnd = common_vendor.computed(() => hazardEndRadio.value === "yes");
|
||||
const normalizeHazardEndRadio = (value) => value === "yes" ? "yes" : "no";
|
||||
const sendMsgFlagRadio = common_vendor.ref("yes");
|
||||
const sendMsgFlag = common_vendor.computed(() => sendMsgFlagRadio.value === "yes");
|
||||
const nextStepName = common_vendor.ref("");
|
||||
@@ -42,11 +43,11 @@ const _sfc_main = {
|
||||
});
|
||||
const selectedAssigneeIdentityId = common_vendor.ref("");
|
||||
const selectedAssigneeName = common_vendor.ref("");
|
||||
const pickerAssigneeIdentityId = common_vendor.ref("");
|
||||
const pickerAssigneeName = common_vendor.ref("");
|
||||
const showAssigneePopup = common_vendor.ref(false);
|
||||
const assigneeList = common_vendor.ref([]);
|
||||
const assigneeLoading = common_vendor.ref(false);
|
||||
common_vendor.ref("");
|
||||
common_vendor.ref("");
|
||||
common_vendor.ref(false);
|
||||
common_vendor.ref([]);
|
||||
common_vendor.ref(false);
|
||||
const formData = common_vendor.reactive({
|
||||
rectifyDeadline: "",
|
||||
responsibleDeptId: "",
|
||||
@@ -142,95 +143,6 @@ const _sfc_main = {
|
||||
const buildPreviewVariables = () => ({
|
||||
quickApprove: true
|
||||
});
|
||||
const getStoredUserInfo = () => {
|
||||
try {
|
||||
const stored = common_vendor.index.getStorageSync("userInfo");
|
||||
if (!stored)
|
||||
return {};
|
||||
return typeof stored === "string" ? JSON.parse(stored) : stored;
|
||||
} catch (error) {
|
||||
return {};
|
||||
}
|
||||
};
|
||||
const getCurrentDeptId = () => {
|
||||
const userInfo = getStoredUserInfo();
|
||||
const identity = userInfo.userIdentity;
|
||||
if ((identity == null ? void 0 : identity.deptId) != null && identity.deptId !== "") {
|
||||
return String(identity.deptId);
|
||||
}
|
||||
if (userInfo.deptId != null && userInfo.deptId !== "") {
|
||||
return String(userInfo.deptId);
|
||||
}
|
||||
return "";
|
||||
};
|
||||
const resolveAssigneeIdentityId = (user) => {
|
||||
if (!user)
|
||||
return "";
|
||||
const id = user.identityId ?? user.userIdentityId ?? user.userId ?? "";
|
||||
return id === "" || id == null ? "" : String(id);
|
||||
};
|
||||
const getAssigneeItemKey = (user) => {
|
||||
const identityId = resolveAssigneeIdentityId(user);
|
||||
if (identityId)
|
||||
return `identity-${identityId}`;
|
||||
return `user-${user.userId || user.nickName || ""}`;
|
||||
};
|
||||
const formatAssigneeDisplayName = (user) => {
|
||||
if (!user)
|
||||
return "";
|
||||
const name = user.nickName || user.userName || user.name || "";
|
||||
const identityName = user.identityName || "";
|
||||
if (name && identityName)
|
||||
return `${name}(${identityName})`;
|
||||
return name || identityName || "未知人员";
|
||||
};
|
||||
const resolveAssigneeDeptUserType = () => 2;
|
||||
const fetchAssigneeList = async () => {
|
||||
const deptId = getCurrentDeptId();
|
||||
if (!deptId) {
|
||||
assigneeList.value = [];
|
||||
return;
|
||||
}
|
||||
assigneeLoading.value = true;
|
||||
try {
|
||||
const res = await request_api.getDeptUsers(deptId, { type: resolveAssigneeDeptUserType() });
|
||||
if (res.code === 0) {
|
||||
assigneeList.value = res.data || [];
|
||||
} else {
|
||||
assigneeList.value = [];
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/closeout/apply.vue:320", "获取部门人员失败:", error);
|
||||
assigneeList.value = [];
|
||||
} finally {
|
||||
assigneeLoading.value = false;
|
||||
}
|
||||
};
|
||||
const openAssigneePopup = async () => {
|
||||
pickerAssigneeIdentityId.value = selectedAssigneeIdentityId.value;
|
||||
pickerAssigneeName.value = selectedAssigneeName.value;
|
||||
showAssigneePopup.value = true;
|
||||
await fetchAssigneeList();
|
||||
};
|
||||
const onAssigneeItemClick = (user) => {
|
||||
const identityId = resolveAssigneeIdentityId(user);
|
||||
if (!identityId)
|
||||
return;
|
||||
pickerAssigneeIdentityId.value = String(identityId);
|
||||
pickerAssigneeName.value = formatAssigneeDisplayName(user);
|
||||
};
|
||||
const confirmAssigneeSelect = () => {
|
||||
if (!pickerAssigneeIdentityId.value) {
|
||||
common_vendor.index.showToast({ title: "请选择下一步处理人", icon: "none" });
|
||||
return;
|
||||
}
|
||||
selectedAssigneeIdentityId.value = pickerAssigneeIdentityId.value;
|
||||
selectedAssigneeName.value = pickerAssigneeName.value;
|
||||
showAssigneePopup.value = false;
|
||||
};
|
||||
const cancelAssigneeSelect = () => {
|
||||
showAssigneePopup.value = false;
|
||||
};
|
||||
const fetchNextStep = async () => {
|
||||
nextStepLoading.value = true;
|
||||
try {
|
||||
@@ -251,7 +163,7 @@ const _sfc_main = {
|
||||
nextStepName.value = "";
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/closeout/apply.vue:375", "获取下一步流程失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/closeout/apply.vue:384", "获取下一步流程失败:", error);
|
||||
nextStepName.value = "";
|
||||
} finally {
|
||||
nextStepLoading.value = false;
|
||||
@@ -282,7 +194,7 @@ const _sfc_main = {
|
||||
taskId.value = resolveTaskIdFromDetail(res.data) || presetTaskId;
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/closeout/apply.vue:411", "获取隐患任务信息失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/closeout/apply.vue:420", "获取隐患任务信息失败:", error);
|
||||
}
|
||||
if (!taskId.value && presetTaskId) {
|
||||
taskId.value = presetTaskId;
|
||||
@@ -330,7 +242,7 @@ const _sfc_main = {
|
||||
}
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/closeout/apply.vue:464", "获取可申请销号隐患列表失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/closeout/apply.vue:473", "获取可申请销号隐患列表失败:", error);
|
||||
}
|
||||
};
|
||||
const onHazardConfirm = async (e) => {
|
||||
@@ -381,7 +293,7 @@ const _sfc_main = {
|
||||
common_vendor.index.showToast({ title: aiRes.msg || "AI生成失败", icon: "none" });
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/closeout/apply.vue:529", "AI生成销号方案失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/closeout/apply.vue:538", "AI生成销号方案失败:", error);
|
||||
common_vendor.index.showToast({ title: "AI生成失败,请重试", icon: "none" });
|
||||
} finally {
|
||||
aiGenerating.value = false;
|
||||
@@ -395,10 +307,6 @@ const _sfc_main = {
|
||||
common_vendor.index.showToast({ title: "请选择隐患", icon: "none" });
|
||||
return;
|
||||
}
|
||||
if (!selectedAssigneeIdentityId.value) {
|
||||
common_vendor.index.showToast({ title: "请选择下一步处理人", icon: "none" });
|
||||
return;
|
||||
}
|
||||
const params = {
|
||||
hazardId: Number(selectedHazardId.value),
|
||||
rectifyDeadline: formData.rectifyDeadline || "",
|
||||
@@ -407,8 +315,9 @@ const _sfc_main = {
|
||||
mainTreatmentContent: formData.mainTreatmentContent || "",
|
||||
treatmentResult: formData.treatmentResult || "",
|
||||
selfVerifyContent: formData.selfVerifyContent || "",
|
||||
assigneeIdentityId: selectedAssigneeIdentityId.value,
|
||||
sendMsgFlag: sendMsgFlag.value
|
||||
hazardEnd: hazardEnd.value,
|
||||
quickApprove: hazardEnd.value ? null : true,
|
||||
sendMsgFlag: hazardEnd.value ? null : sendMsgFlag.value
|
||||
};
|
||||
try {
|
||||
const res = await request_api.applyDelete(params);
|
||||
@@ -421,7 +330,7 @@ const _sfc_main = {
|
||||
common_vendor.index.showToast({ title: res.msg || "申请失败", icon: "none" });
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/closeout/apply.vue:573", "申请失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/closeout/apply.vue:588", "申请失败:", error);
|
||||
common_vendor.index.showToast({ title: "请求失败", icon: "none" });
|
||||
}
|
||||
};
|
||||
@@ -436,14 +345,17 @@ const _sfc_main = {
|
||||
const hazardFromOptions = utils_hazardNav.buildWriteoffHazardFromOptions(options);
|
||||
if (hazardFromOptions == null ? void 0 : hazardFromOptions.hazardId) {
|
||||
await applySelectedHazard(hazardFromOptions);
|
||||
return;
|
||||
}
|
||||
if (!hazardLocked.value) {
|
||||
await fetchSelectableHazardList();
|
||||
}
|
||||
if (taskId.value) {
|
||||
await fetchNextStep();
|
||||
} else {
|
||||
if (!hazardLocked.value) {
|
||||
await fetchSelectableHazardList();
|
||||
}
|
||||
if (taskId.value) {
|
||||
await fetchNextStep();
|
||||
}
|
||||
}
|
||||
common_vendor.nextTick$1(() => {
|
||||
hazardEndRadio.value = normalizeHazardEndRadio(hazardEndRadio.value);
|
||||
});
|
||||
});
|
||||
return (_ctx, _cache) => {
|
||||
return common_vendor.e({
|
||||
@@ -483,63 +395,58 @@ const _sfc_main = {
|
||||
placeholder: "请输入隐患治理责任单位自行验收的情况",
|
||||
modelValue: formData.selfVerifyContent
|
||||
}),
|
||||
y: common_vendor.t(nextStepDisplay.value),
|
||||
z: common_vendor.t(selectedAssigneeName.value || "请选择下一步处理人"),
|
||||
A: !selectedAssigneeName.value ? 1 : "",
|
||||
B: common_vendor.o(openAssigneePopup),
|
||||
y: common_vendor.p({
|
||||
label: "否",
|
||||
name: "no",
|
||||
customStyle: {
|
||||
marginRight: "48rpx"
|
||||
}
|
||||
}),
|
||||
z: common_vendor.p({
|
||||
label: "是",
|
||||
name: "yes"
|
||||
}),
|
||||
A: "hazard-end-" + hazardEndRadio.value,
|
||||
B: common_vendor.o(($event) => hazardEndRadio.value = $event),
|
||||
C: common_vendor.p({
|
||||
placement: "row",
|
||||
activeColor: "#2667e9",
|
||||
modelValue: hazardEndRadio.value
|
||||
}),
|
||||
D: !hazardEnd.value
|
||||
}, !hazardEnd.value ? {
|
||||
E: common_vendor.t(nextStepDisplay.value),
|
||||
F: common_vendor.p({
|
||||
label: "是",
|
||||
name: "yes",
|
||||
customStyle: {
|
||||
marginRight: "48rpx"
|
||||
}
|
||||
}),
|
||||
D: common_vendor.p({
|
||||
G: common_vendor.p({
|
||||
label: "否",
|
||||
name: "no"
|
||||
}),
|
||||
E: common_vendor.o(($event) => sendMsgFlagRadio.value = $event),
|
||||
F: common_vendor.p({
|
||||
H: common_vendor.o(($event) => sendMsgFlagRadio.value = $event),
|
||||
I: common_vendor.p({
|
||||
placement: "row",
|
||||
activeColor: "#2667e9",
|
||||
modelValue: sendMsgFlagRadio.value
|
||||
}),
|
||||
G: common_vendor.o(handleCancel),
|
||||
H: common_vendor.o(handleSubmit),
|
||||
I: !hazardLocked.value
|
||||
})
|
||||
} : {}, {
|
||||
J: common_vendor.o(handleCancel),
|
||||
K: common_vendor.o(handleSubmit),
|
||||
L: !hazardLocked.value
|
||||
}, !hazardLocked.value ? {
|
||||
J: common_vendor.o(onHazardConfirm),
|
||||
K: common_vendor.o(($event) => showHazardPicker.value = false),
|
||||
L: common_vendor.o(($event) => showHazardPicker.value = false),
|
||||
M: common_vendor.p({
|
||||
M: common_vendor.o(onHazardConfirm),
|
||||
N: common_vendor.o(($event) => showHazardPicker.value = false),
|
||||
O: common_vendor.o(($event) => showHazardPicker.value = false),
|
||||
P: common_vendor.p({
|
||||
show: showHazardPicker.value,
|
||||
columns: hazardColumns.value
|
||||
})
|
||||
} : {}, {
|
||||
N: common_vendor.o(cancelAssigneeSelect),
|
||||
O: assigneeLoading.value
|
||||
}, assigneeLoading.value ? {} : assigneeList.value.length === 0 ? {} : {
|
||||
Q: common_vendor.f(assigneeList.value, (user, k0, i0) => {
|
||||
return common_vendor.e({
|
||||
a: common_vendor.t(formatAssigneeDisplayName(user)),
|
||||
b: String(pickerAssigneeIdentityId.value) === String(resolveAssigneeIdentityId(user))
|
||||
}, String(pickerAssigneeIdentityId.value) === String(resolveAssigneeIdentityId(user)) ? {} : {}, {
|
||||
c: getAssigneeItemKey(user),
|
||||
d: String(pickerAssigneeIdentityId.value) === String(resolveAssigneeIdentityId(user)) ? 1 : "",
|
||||
e: common_vendor.o(($event) => onAssigneeItemClick(user), getAssigneeItemKey(user))
|
||||
});
|
||||
})
|
||||
}, {
|
||||
P: assigneeList.value.length === 0,
|
||||
R: common_vendor.o(cancelAssigneeSelect),
|
||||
S: common_vendor.o(confirmAssigneeSelect),
|
||||
T: common_vendor.o(cancelAssigneeSelect),
|
||||
U: common_vendor.p({
|
||||
show: showAssigneePopup.value,
|
||||
mode: "bottom",
|
||||
round: "20"
|
||||
}),
|
||||
V: common_vendor.gei(_ctx, "")
|
||||
Q: common_vendor.gei(_ctx, "")
|
||||
});
|
||||
};
|
||||
}
|
||||
|
||||
@@ -4,7 +4,6 @@
|
||||
"up-textarea": "../../uni_modules/uview-plus/components/u-textarea/u-textarea",
|
||||
"up-radio": "../../uni_modules/uview-plus/components/u-radio/u-radio",
|
||||
"up-radio-group": "../../uni_modules/uview-plus/components/u-radio-group/u-radio-group",
|
||||
"up-picker": "../../uni_modules/uview-plus/components/u-picker/u-picker",
|
||||
"u-popup": "../../uni_modules/uview-plus/components/u-popup/u-popup"
|
||||
"up-picker": "../../uni_modules/uview-plus/components/u-picker/u-picker"
|
||||
}
|
||||
}
|
||||
File diff suppressed because one or more lines are too long
@@ -9,18 +9,17 @@ if (!Array) {
|
||||
const _easycom_up_radio_group2 = common_vendor.resolveComponent("up-radio-group");
|
||||
const _easycom_wd_signature2 = common_vendor.resolveComponent("wd-signature");
|
||||
const _easycom_up_picker2 = common_vendor.resolveComponent("up-picker");
|
||||
const _easycom_u_popup2 = common_vendor.resolveComponent("u-popup");
|
||||
(_easycom_up_textarea2 + _easycom_up_radio2 + _easycom_up_radio_group2 + _easycom_wd_signature2 + _easycom_up_picker2 + _easycom_u_popup2)();
|
||||
(_easycom_up_textarea2 + _easycom_up_radio2 + _easycom_up_radio_group2 + _easycom_wd_signature2 + _easycom_up_picker2)();
|
||||
}
|
||||
const _easycom_up_textarea = () => "../../uni_modules/uview-plus/components/u-textarea/u-textarea.js";
|
||||
const _easycom_up_radio = () => "../../uni_modules/uview-plus/components/u-radio/u-radio.js";
|
||||
const _easycom_up_radio_group = () => "../../uni_modules/uview-plus/components/u-radio-group/u-radio-group.js";
|
||||
const _easycom_wd_signature = () => "../../node-modules/wot-design-uni/components/wd-signature/wd-signature.js";
|
||||
const _easycom_up_picker = () => "../../uni_modules/uview-plus/components/u-picker/u-picker.js";
|
||||
const _easycom_u_popup = () => "../../uni_modules/uview-plus/components/u-popup/u-popup.js";
|
||||
if (!Math) {
|
||||
(_easycom_up_textarea + _easycom_up_radio + _easycom_up_radio_group + _easycom_wd_signature + _easycom_up_picker + _easycom_u_popup)();
|
||||
(_easycom_up_textarea + _easycom_up_radio + _easycom_up_radio_group + _easycom_wd_signature + _easycom_up_picker + FlowAssigneePickerPopup)();
|
||||
}
|
||||
const FlowAssigneePickerPopup = () => "../../components/flow/FlowAssigneePickerPopup.js";
|
||||
const FLOW_END_STEP_NAME = "隐患流程结束";
|
||||
const _sfc_main = {
|
||||
__name: "approval",
|
||||
@@ -59,8 +58,6 @@ const _sfc_main = {
|
||||
const pickerAssigneeIdentityId = common_vendor.ref("");
|
||||
const pickerAssigneeName = common_vendor.ref("");
|
||||
const showAssigneePopup = common_vendor.ref(false);
|
||||
const assigneeList = common_vendor.ref([]);
|
||||
const assigneeLoading = common_vendor.ref(false);
|
||||
const showCanvas = common_vendor.ref(true);
|
||||
const signatureUrl = common_vendor.ref("");
|
||||
const signatureServerPath = common_vendor.ref("");
|
||||
@@ -211,94 +208,18 @@ const _sfc_main = {
|
||||
type: "agree"
|
||||
};
|
||||
};
|
||||
const getStoredUserInfo = () => {
|
||||
try {
|
||||
const stored = common_vendor.index.getStorageSync("userInfo");
|
||||
if (!stored)
|
||||
return {};
|
||||
return typeof stored === "string" ? JSON.parse(stored) : stored;
|
||||
} catch (error) {
|
||||
return {};
|
||||
}
|
||||
};
|
||||
const getCurrentDeptId = () => {
|
||||
const userInfo = getStoredUserInfo();
|
||||
const identity = userInfo.userIdentity;
|
||||
if ((identity == null ? void 0 : identity.deptId) != null && identity.deptId !== "") {
|
||||
return String(identity.deptId);
|
||||
}
|
||||
if (userInfo.deptId != null && userInfo.deptId !== "") {
|
||||
return String(userInfo.deptId);
|
||||
}
|
||||
return "";
|
||||
};
|
||||
const resolveAssigneeIdentityId = (user) => {
|
||||
if (!user)
|
||||
return "";
|
||||
const id = user.identityId ?? user.userIdentityId ?? user.userId ?? "";
|
||||
return id === "" || id == null ? "" : String(id);
|
||||
};
|
||||
const getAssigneeItemKey = (user) => {
|
||||
const identityId = resolveAssigneeIdentityId(user);
|
||||
if (identityId)
|
||||
return `identity-${identityId}`;
|
||||
return `user-${user.userId || user.nickName || ""}`;
|
||||
};
|
||||
const formatAssigneeDisplayName = (user) => {
|
||||
if (!user)
|
||||
return "";
|
||||
const name = user.nickName || user.userName || user.name || "";
|
||||
const identityName = user.identityName || "";
|
||||
if (name && identityName)
|
||||
return `${name}(${identityName})`;
|
||||
return name || identityName || "未知人员";
|
||||
};
|
||||
const resolveAssigneeDeptUserType = () => {
|
||||
if (formData.approvalResult === 2)
|
||||
return 3;
|
||||
return quickApproveRadio.value === "yes" ? 2 : 3;
|
||||
};
|
||||
const fetchAssigneeList = async () => {
|
||||
const deptId = getCurrentDeptId();
|
||||
if (!deptId) {
|
||||
assigneeList.value = [];
|
||||
const openAssigneePopup = () => {
|
||||
if (!taskId.value) {
|
||||
common_vendor.index.showToast({ title: "缺少任务ID", icon: "none" });
|
||||
return;
|
||||
}
|
||||
assigneeLoading.value = true;
|
||||
try {
|
||||
const res = await request_api.getDeptUsers(deptId, { type: resolveAssigneeDeptUserType() });
|
||||
if (res.code === 0) {
|
||||
assigneeList.value = res.data || [];
|
||||
} else {
|
||||
assigneeList.value = [];
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/closeout/approval.vue:500", "获取部门人员失败:", error);
|
||||
assigneeList.value = [];
|
||||
} finally {
|
||||
assigneeLoading.value = false;
|
||||
}
|
||||
};
|
||||
const openAssigneePopup = async () => {
|
||||
pickerAssigneeIdentityId.value = selectedAssigneeIdentityId.value;
|
||||
pickerAssigneeName.value = selectedAssigneeName.value;
|
||||
showAssigneePopup.value = true;
|
||||
await fetchAssigneeList();
|
||||
};
|
||||
const onAssigneeItemClick = (user) => {
|
||||
const identityId = resolveAssigneeIdentityId(user);
|
||||
if (!identityId)
|
||||
return;
|
||||
pickerAssigneeIdentityId.value = String(identityId);
|
||||
pickerAssigneeName.value = formatAssigneeDisplayName(user);
|
||||
};
|
||||
const confirmAssigneeSelect = () => {
|
||||
if (!pickerAssigneeIdentityId.value) {
|
||||
common_vendor.index.showToast({ title: "请选择下一步处理人", icon: "none" });
|
||||
return;
|
||||
}
|
||||
selectedAssigneeIdentityId.value = pickerAssigneeIdentityId.value;
|
||||
selectedAssigneeName.value = pickerAssigneeName.value;
|
||||
const confirmAssigneeSelect = ({ identityId, name }) => {
|
||||
selectedAssigneeIdentityId.value = identityId;
|
||||
selectedAssigneeName.value = name;
|
||||
showAssigneePopup.value = false;
|
||||
};
|
||||
const cancelAssigneeSelect = () => {
|
||||
@@ -328,7 +249,7 @@ const _sfc_main = {
|
||||
nextStepName.value = "";
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/closeout/approval.vue:559", "获取下一步流程失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/closeout/approval.vue:460", "获取下一步流程失败:", error);
|
||||
nextStepName.value = "";
|
||||
} finally {
|
||||
nextStepLoading.value = false;
|
||||
@@ -359,7 +280,7 @@ const _sfc_main = {
|
||||
taskId.value = resolveTaskIdFromDetail(res.data) || presetTaskId;
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/closeout/approval.vue:595", "获取隐患任务信息失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/closeout/approval.vue:496", "获取隐患任务信息失败:", error);
|
||||
}
|
||||
if (!taskId.value && presetTaskId) {
|
||||
taskId.value = presetTaskId;
|
||||
@@ -416,7 +337,7 @@ const _sfc_main = {
|
||||
}
|
||||
return res;
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/closeout/approval.vue:654", "获取销号审批表单失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/closeout/approval.vue:555", "获取销号审批表单失败:", error);
|
||||
common_vendor.index.showToast({ title: "获取销号审批表单失败", icon: "none" });
|
||||
return null;
|
||||
}
|
||||
@@ -514,7 +435,7 @@ const _sfc_main = {
|
||||
} catch (err) {
|
||||
isSubmitting.value = false;
|
||||
common_vendor.index.hideLoading();
|
||||
common_vendor.index.__f__("error", "at pages/closeout/approval.vue:780", "签名上传失败:", err);
|
||||
common_vendor.index.__f__("error", "at pages/closeout/approval.vue:681", "签名上传失败:", err);
|
||||
common_vendor.index.showToast({ title: "签名上传失败,请重试", icon: "none" });
|
||||
}
|
||||
};
|
||||
@@ -556,7 +477,7 @@ const _sfc_main = {
|
||||
common_vendor.index.showToast({ title: aiRes.msg || "AI生成失败", icon: "none" });
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/closeout/approval.vue:828", "AI生成销号方案失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/closeout/approval.vue:729", "AI生成销号方案失败:", error);
|
||||
common_vendor.index.showToast({ title: "AI生成失败,请重试", icon: "none" });
|
||||
} finally {
|
||||
aiGenerating.value = false;
|
||||
@@ -591,7 +512,7 @@ const _sfc_main = {
|
||||
} catch (err) {
|
||||
isSubmitting.value = false;
|
||||
common_vendor.index.hideLoading();
|
||||
common_vendor.index.__f__("error", "at pages/closeout/approval.vue:865", "签名上传失败:", err);
|
||||
common_vendor.index.__f__("error", "at pages/closeout/approval.vue:766", "签名上传失败:", err);
|
||||
common_vendor.index.showToast({ title: "签名上传失败,请重试", icon: "none" });
|
||||
}
|
||||
};
|
||||
@@ -672,7 +593,7 @@ const _sfc_main = {
|
||||
common_vendor.index.showToast({ title: res.msg || "审批失败", icon: "none" });
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/closeout/approval.vue:952", "审批失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/closeout/approval.vue:853", "审批失败:", error);
|
||||
common_vendor.index.showToast({ title: "请求失败", icon: "none" });
|
||||
} finally {
|
||||
isSubmitting.value = false;
|
||||
@@ -684,7 +605,7 @@ const _sfc_main = {
|
||||
const sysInfo = common_vendor.index.getSystemInfoSync();
|
||||
signatureWidth.value = sysInfo.windowWidth - 40;
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/closeout/approval.vue:965", "获取系统信息失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/closeout/approval.vue:866", "获取系统信息失败:", error);
|
||||
}
|
||||
const hazardId = options == null ? void 0 : options.hazardId;
|
||||
hazardLocked.value = (options == null ? void 0 : options.locked) === "1";
|
||||
@@ -872,29 +793,16 @@ const _sfc_main = {
|
||||
})
|
||||
} : {}, {
|
||||
at: common_vendor.o(cancelAssigneeSelect),
|
||||
av: assigneeLoading.value
|
||||
}, assigneeLoading.value ? {} : assigneeList.value.length === 0 ? {} : {
|
||||
ax: common_vendor.f(assigneeList.value, (user, k0, i0) => {
|
||||
return common_vendor.e({
|
||||
a: common_vendor.t(formatAssigneeDisplayName(user)),
|
||||
b: String(pickerAssigneeIdentityId.value) === String(resolveAssigneeIdentityId(user))
|
||||
}, String(pickerAssigneeIdentityId.value) === String(resolveAssigneeIdentityId(user)) ? {} : {}, {
|
||||
c: getAssigneeItemKey(user),
|
||||
d: String(pickerAssigneeIdentityId.value) === String(resolveAssigneeIdentityId(user)) ? 1 : "",
|
||||
e: common_vendor.o(($event) => onAssigneeItemClick(user), getAssigneeItemKey(user))
|
||||
});
|
||||
})
|
||||
}, {
|
||||
aw: assigneeList.value.length === 0,
|
||||
ay: common_vendor.o(cancelAssigneeSelect),
|
||||
az: common_vendor.o(confirmAssigneeSelect),
|
||||
aA: common_vendor.o(cancelAssigneeSelect),
|
||||
aB: common_vendor.p({
|
||||
av: common_vendor.o(confirmAssigneeSelect),
|
||||
aw: common_vendor.o(($event) => pickerAssigneeIdentityId.value = $event),
|
||||
ax: common_vendor.o(($event) => pickerAssigneeName.value = $event),
|
||||
ay: common_vendor.p({
|
||||
show: showAssigneePopup.value,
|
||||
mode: "bottom",
|
||||
round: "20"
|
||||
["task-id"]: taskId.value,
|
||||
["picker-identity-id"]: pickerAssigneeIdentityId.value,
|
||||
["picker-name"]: pickerAssigneeName.value
|
||||
}),
|
||||
aC: common_vendor.gei(_ctx, "")
|
||||
az: common_vendor.gei(_ctx, "")
|
||||
});
|
||||
};
|
||||
}
|
||||
|
||||
@@ -6,6 +6,6 @@
|
||||
"up-radio-group": "../../uni_modules/uview-plus/components/u-radio-group/u-radio-group",
|
||||
"wd-signature": "../../node-modules/wot-design-uni/components/wd-signature/wd-signature",
|
||||
"up-picker": "../../uni_modules/uview-plus/components/u-picker/u-picker",
|
||||
"u-popup": "../../uni_modules/uview-plus/components/u-popup/u-popup"
|
||||
"flow-assignee-picker-popup": "../../components/flow/FlowAssigneePickerPopup"
|
||||
}
|
||||
}
|
||||
File diff suppressed because one or more lines are too long
@@ -114,83 +114,6 @@
|
||||
font-size: 28rpx;
|
||||
color: #333;
|
||||
}
|
||||
.user-popup.data-v-367b7912 {
|
||||
background: #fff;
|
||||
}
|
||||
.user-popup .popup-header.data-v-367b7912 {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
padding: 30rpx;
|
||||
border-bottom: 1rpx solid #eee;
|
||||
}
|
||||
.user-popup .popup-header .popup-title.data-v-367b7912 {
|
||||
font-size: 32rpx;
|
||||
color: #333;
|
||||
}
|
||||
.user-popup .popup-header .popup-close.data-v-367b7912 {
|
||||
font-size: 40rpx;
|
||||
color: #999;
|
||||
line-height: 1;
|
||||
}
|
||||
.user-popup .user-list-scroll.data-v-367b7912 {
|
||||
max-height: 600rpx;
|
||||
padding: 0 30rpx;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
.user-popup .empty-tip.data-v-367b7912 {
|
||||
padding: 80rpx 20rpx;
|
||||
text-align: center;
|
||||
color: #909399;
|
||||
font-size: 26rpx;
|
||||
}
|
||||
.user-popup .user-item.data-v-367b7912 {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
padding: 24rpx 0;
|
||||
border-bottom: 1rpx solid #f5f5f5;
|
||||
}
|
||||
.user-popup .user-item.data-v-367b7912:last-child {
|
||||
border-bottom: none;
|
||||
}
|
||||
.user-popup .user-item.active .user-item-text.data-v-367b7912 {
|
||||
color: #2667E9;
|
||||
font-weight: 600;
|
||||
}
|
||||
.user-popup .user-item .user-item-text.data-v-367b7912 {
|
||||
flex: 1;
|
||||
font-size: 28rpx;
|
||||
color: #333;
|
||||
}
|
||||
.user-popup .popup-footer.data-v-367b7912 {
|
||||
display: flex;
|
||||
gap: 24rpx;
|
||||
padding: 24rpx 30rpx;
|
||||
padding-bottom: calc(24rpx + env(safe-area-inset-bottom));
|
||||
background: #fff;
|
||||
}
|
||||
.user-popup .popup-footer button.data-v-367b7912 {
|
||||
flex: 1;
|
||||
height: 80rpx;
|
||||
line-height: 80rpx;
|
||||
border-radius: 40rpx;
|
||||
font-size: 30rpx;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
.user-popup .popup-footer button.data-v-367b7912::after {
|
||||
border: none;
|
||||
}
|
||||
.user-popup .popup-footer .btn-cancel.data-v-367b7912 {
|
||||
background: #fff;
|
||||
color: #2667E9;
|
||||
border: 2rpx solid #2667E9;
|
||||
}
|
||||
.user-popup .popup-footer .btn-confirm.data-v-367b7912 {
|
||||
color: #fff;
|
||||
border: none;
|
||||
}
|
||||
.signature-action-btn.data-v-367b7912 {
|
||||
margin: 0;
|
||||
padding: 0 20rpx;
|
||||
|
||||
@@ -45,7 +45,7 @@ const _sfc_main = {
|
||||
modeName: "",
|
||||
selectDeptId: "",
|
||||
selectDeptName: "",
|
||||
executorId: "",
|
||||
executorIdentityId: "",
|
||||
executorNames: "",
|
||||
rosterIdentityIds: [],
|
||||
cycleId: "",
|
||||
@@ -152,7 +152,7 @@ const _sfc_main = {
|
||||
const endDateMinDate = common_vendor.computed(() => {
|
||||
if (formData.startDate) {
|
||||
const [year, month, day] = formData.startDate.split("-").map(Number);
|
||||
return new Date(year, month - 1, day + 1).getTime();
|
||||
return new Date(year, month - 1, day).getTime();
|
||||
}
|
||||
return getTodayTimestamp();
|
||||
});
|
||||
@@ -169,7 +169,7 @@ const _sfc_main = {
|
||||
const cycleColumns = common_vendor.ref([["每天一次", "每周一次", "每月一次", "每季度一次"]]);
|
||||
const showExecutorPopup = common_vendor.ref(false);
|
||||
const executorList = common_vendor.ref([]);
|
||||
const selectedExecutorId = common_vendor.ref(null);
|
||||
const selectedExecutorIdentityId = common_vendor.ref(null);
|
||||
const selectedRosterIdentityIds = common_vendor.ref([]);
|
||||
const pageScrollLockStyle = common_vendor.computed(() => {
|
||||
if (showDeptPicker.value || showExecutorPopup.value) {
|
||||
@@ -281,32 +281,63 @@ const _sfc_main = {
|
||||
showModePicker.value = false;
|
||||
};
|
||||
const clearExecutorSelection = () => {
|
||||
formData.executorId = "";
|
||||
formData.executorIdentityId = "";
|
||||
formData.executorNames = "";
|
||||
formData.rosterIdentityIds = [];
|
||||
selectedExecutorId.value = null;
|
||||
selectedExecutorIdentityId.value = null;
|
||||
selectedRosterIdentityIds.value = [];
|
||||
};
|
||||
const getDeptUsersQueryParams = () => {
|
||||
if (formData.runMode === 4) {
|
||||
return { type: 4 };
|
||||
}
|
||||
if (formData.runMode === 1) {
|
||||
return { type: 5 };
|
||||
}
|
||||
return {};
|
||||
};
|
||||
const syncSingleExecutorSelection = (rawValue) => {
|
||||
if (formData.runMode === 4 || rawValue === void 0 || rawValue === null || rawValue === "") {
|
||||
return;
|
||||
}
|
||||
const num = Number(rawValue);
|
||||
if (Number.isNaN(num))
|
||||
return;
|
||||
const byIdentity = executorList.value.find((user) => Number(user.identityId) === num);
|
||||
if (byIdentity) {
|
||||
selectedExecutorIdentityId.value = byIdentity.identityId;
|
||||
formData.executorIdentityId = byIdentity.identityId;
|
||||
return;
|
||||
}
|
||||
const byUser = executorList.value.find((user) => Number(user.userId) === num);
|
||||
if (byUser) {
|
||||
selectedExecutorIdentityId.value = byUser.identityId;
|
||||
formData.executorIdentityId = byUser.identityId;
|
||||
}
|
||||
};
|
||||
const fetchDeptUsers = async (deptId) => {
|
||||
if (!deptId) {
|
||||
executorList.value = [];
|
||||
return;
|
||||
}
|
||||
try {
|
||||
const params = formData.runMode === 4 ? { type: 4 } : {};
|
||||
const params = getDeptUsersQueryParams();
|
||||
const res = await request_api.getDeptUsers(deptId, params);
|
||||
if (res.code === 0 && res.data) {
|
||||
executorList.value = res.data || [];
|
||||
if (formData.runMode === 1) {
|
||||
syncSingleExecutorSelection(formData.executorIdentityId);
|
||||
}
|
||||
} else {
|
||||
executorList.value = [];
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:810", "获取部门用户失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:842", "获取部门用户失败:", error);
|
||||
executorList.value = [];
|
||||
}
|
||||
};
|
||||
const selectExecutor = (item) => {
|
||||
selectedExecutorId.value = item.userId;
|
||||
selectedExecutorIdentityId.value = item.identityId;
|
||||
};
|
||||
const toggleRosterExecutor = (item) => {
|
||||
const identityId = item.identityId;
|
||||
@@ -331,12 +362,12 @@ const _sfc_main = {
|
||||
showExecutorPopup.value = false;
|
||||
return;
|
||||
}
|
||||
if (!selectedExecutorId.value) {
|
||||
if (!selectedExecutorIdentityId.value) {
|
||||
common_vendor.index.showToast({ title: "请选择执行人员", icon: "none" });
|
||||
return;
|
||||
}
|
||||
const selectedUser = executorList.value.find((u) => u.userId === selectedExecutorId.value);
|
||||
formData.executorId = selectedExecutorId.value;
|
||||
const selectedUser = executorList.value.find((user) => user.identityId === selectedExecutorIdentityId.value);
|
||||
formData.executorIdentityId = selectedExecutorIdentityId.value;
|
||||
formData.executorNames = (selectedUser == null ? void 0 : selectedUser.nickName) || (selectedUser == null ? void 0 : selectedUser.nickname) || "";
|
||||
showExecutorPopup.value = false;
|
||||
};
|
||||
@@ -348,7 +379,7 @@ const _sfc_main = {
|
||||
if (formData.runMode === 4) {
|
||||
selectedRosterIdentityIds.value = [...formData.rosterIdentityIds || []];
|
||||
} else {
|
||||
selectedExecutorId.value = formData.executorId || null;
|
||||
selectedExecutorIdentityId.value = formData.executorIdentityId || null;
|
||||
}
|
||||
fetchDeptUsers(formData.deptId);
|
||||
showExecutorPopup.value = true;
|
||||
@@ -361,7 +392,7 @@ const _sfc_main = {
|
||||
deptTree.value = handleTree(list, "deptId");
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:876", "获取部门树失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:908", "获取部门树失败:", error);
|
||||
}
|
||||
};
|
||||
const onCycleConfirm = (e) => {
|
||||
@@ -411,7 +442,7 @@ const _sfc_main = {
|
||||
});
|
||||
return;
|
||||
}
|
||||
if (formData.endDate && parseDateValue(selectedDate) >= parseDateValue(formData.endDate)) {
|
||||
if (formData.endDate && parseDateValue(selectedDate) > parseDateValue(formData.endDate)) {
|
||||
formData.endDate = "";
|
||||
}
|
||||
formData.startDate = selectedDate;
|
||||
@@ -426,8 +457,8 @@ const _sfc_main = {
|
||||
});
|
||||
return;
|
||||
}
|
||||
if (formData.startDate && parseDateValue(selectedDate) <= parseDateValue(formData.startDate)) {
|
||||
common_vendor.index.showToast({ title: "计划结束日期必须晚于计划开始日期", icon: "none" });
|
||||
if (formData.startDate && parseDateValue(selectedDate) < parseDateValue(formData.startDate)) {
|
||||
common_vendor.index.showToast({ title: "计划结束日期不能早于计划开始日期", icon: "none" });
|
||||
return;
|
||||
}
|
||||
formData.endDate = selectedDate;
|
||||
@@ -470,7 +501,7 @@ const _sfc_main = {
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.hideLoading();
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:1004", "删除检查项失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:1036", "删除检查项失败:", error);
|
||||
common_vendor.index.showToast({ title: "删除失败", icon: "none" });
|
||||
}
|
||||
} else {
|
||||
@@ -530,7 +561,7 @@ const _sfc_main = {
|
||||
industryOptions.value = res.data || [];
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:1073", "获取行业类型失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:1105", "获取行业类型失败:", error);
|
||||
}
|
||||
};
|
||||
common_vendor.watch(showAddPopup, (val) => {
|
||||
@@ -598,7 +629,7 @@ const _sfc_main = {
|
||||
hasMoreLaw.value = lawList.value.length < total;
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:1152", "获取法规列表失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:1184", "获取法规列表失败:", error);
|
||||
} finally {
|
||||
lawLoading.value = false;
|
||||
}
|
||||
@@ -692,7 +723,7 @@ const _sfc_main = {
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.hideLoading();
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:1265", "添加检查项失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:1297", "添加检查项失败:", error);
|
||||
common_vendor.index.showToast({ title: "添加失败", icon: "none" });
|
||||
}
|
||||
};
|
||||
@@ -741,7 +772,7 @@ const _sfc_main = {
|
||||
hasMoreLibrary.value = libraryList.value.length < total;
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:1325", "获取检查库列表失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:1357", "获取检查库列表失败:", error);
|
||||
} finally {
|
||||
libraryLoading.value = false;
|
||||
}
|
||||
@@ -844,7 +875,7 @@ const _sfc_main = {
|
||||
selectedLibraries.value = [];
|
||||
} catch (error) {
|
||||
common_vendor.index.hideLoading();
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:1445", "获取检查库详情失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:1477", "获取检查库详情失败:", error);
|
||||
common_vendor.index.showToast({ title: "添加失败", icon: "none" });
|
||||
}
|
||||
};
|
||||
@@ -866,7 +897,7 @@ const _sfc_main = {
|
||||
common_vendor.index.showToast({ title: "请选择模式", icon: "none" });
|
||||
return;
|
||||
}
|
||||
if (formData.runMode === 1 && !formData.executorId) {
|
||||
if (formData.runMode === 1 && !formData.executorIdentityId) {
|
||||
common_vendor.index.showToast({ title: "请选择执行人员", icon: "none" });
|
||||
return;
|
||||
}
|
||||
@@ -882,8 +913,8 @@ const _sfc_main = {
|
||||
common_vendor.index.showToast({ title: "请选择计划日期", icon: "none" });
|
||||
return;
|
||||
}
|
||||
if (parseDateValue(formData.endDate) <= parseDateValue(formData.startDate)) {
|
||||
common_vendor.index.showToast({ title: "计划结束日期必须晚于计划开始日期", icon: "none" });
|
||||
if (parseDateValue(formData.endDate) < parseDateValue(formData.startDate)) {
|
||||
common_vendor.index.showToast({ title: "计划结束日期不能早于计划开始日期", icon: "none" });
|
||||
return;
|
||||
}
|
||||
const items = [];
|
||||
@@ -925,8 +956,8 @@ const _sfc_main = {
|
||||
planStartTime: `${formData.startDate} 00:00:00`,
|
||||
planEndTime: `${formData.endDate} 00:00:00`
|
||||
};
|
||||
if (formData.runMode === 1 && formData.executorId) {
|
||||
params.executorId = formData.executorId;
|
||||
if (formData.runMode === 1 && formData.executorIdentityId) {
|
||||
params.executorIdentityId = formData.executorIdentityId;
|
||||
}
|
||||
if (formData.runMode === 4 && ((_a = formData.rosterIdentityIds) == null ? void 0 : _a.length)) {
|
||||
params.rosterIdentityIds = formData.rosterIdentityIds;
|
||||
@@ -945,7 +976,7 @@ const _sfc_main = {
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.hideLoading();
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:1562", "保存失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/editchecklist/editchecklist.vue:1594", "保存失败:", error);
|
||||
common_vendor.index.showToast({ title: "保存失败", icon: "none" });
|
||||
}
|
||||
};
|
||||
@@ -1234,9 +1265,9 @@ const _sfc_main = {
|
||||
}, selectedRosterIdentityIds.value.includes(item.identityId) ? {} : {}, {
|
||||
b: selectedRosterIdentityIds.value.includes(item.identityId) ? 1 : ""
|
||||
}) : common_vendor.e({
|
||||
c: selectedExecutorId.value === item.userId
|
||||
}, selectedExecutorId.value === item.userId ? {} : {}, {
|
||||
d: selectedExecutorId.value === item.userId ? 1 : ""
|
||||
c: selectedExecutorIdentityId.value === item.identityId
|
||||
}, selectedExecutorIdentityId.value === item.identityId ? {} : {}, {
|
||||
d: selectedExecutorIdentityId.value === item.identityId ? 1 : ""
|
||||
}), {
|
||||
e: common_vendor.t(item.nickName),
|
||||
f: item.identityId || item.userId,
|
||||
|
||||
@@ -229,8 +229,8 @@ const _sfc_main = {
|
||||
}, item.statusName === "待验收" && item.canEdit ? {
|
||||
o: common_vendor.o(($event) => editRectification(item), item.hazardId)
|
||||
} : {}, {
|
||||
p: common_vendor.unref(utils_hazardNav.canShowAcceptanceButton)(item, userRole.value)
|
||||
}, common_vendor.unref(utils_hazardNav.canShowAcceptanceButton)(item, userRole.value) ? {
|
||||
p: common_vendor.unref(utils_hazardNav.canShowAcceptanceButton)(item)
|
||||
}, common_vendor.unref(utils_hazardNav.canShowAcceptanceButton)(item) ? {
|
||||
q: common_vendor.o(($event) => acceptance(item), item.hazardId)
|
||||
} : {}, {
|
||||
r: item.statusName === "待交办"
|
||||
|
||||
@@ -8,17 +8,20 @@ const utils_upload = require("../../utils/upload.js");
|
||||
if (!Array) {
|
||||
const _easycom_up_textarea2 = common_vendor.resolveComponent("up-textarea");
|
||||
const _easycom_up_upload2 = common_vendor.resolveComponent("up-upload");
|
||||
const _easycom_u_popup2 = common_vendor.resolveComponent("u-popup");
|
||||
const _easycom_up_radio2 = common_vendor.resolveComponent("up-radio");
|
||||
const _easycom_up_radio_group2 = common_vendor.resolveComponent("up-radio-group");
|
||||
const _easycom_wd_signature2 = common_vendor.resolveComponent("wd-signature");
|
||||
(_easycom_up_textarea2 + _easycom_up_upload2 + _easycom_u_popup2 + _easycom_wd_signature2)();
|
||||
(_easycom_up_textarea2 + _easycom_up_upload2 + _easycom_up_radio2 + _easycom_up_radio_group2 + _easycom_wd_signature2)();
|
||||
}
|
||||
const _easycom_up_textarea = () => "../../uni_modules/uview-plus/components/u-textarea/u-textarea.js";
|
||||
const _easycom_up_upload = () => "../../uni_modules/uview-plus/components/u-upload/u-upload.js";
|
||||
const _easycom_u_popup = () => "../../uni_modules/uview-plus/components/u-popup/u-popup.js";
|
||||
const _easycom_up_radio = () => "../../uni_modules/uview-plus/components/u-radio/u-radio.js";
|
||||
const _easycom_up_radio_group = () => "../../uni_modules/uview-plus/components/u-radio-group/u-radio-group.js";
|
||||
const _easycom_wd_signature = () => "../../node-modules/wot-design-uni/components/wd-signature/wd-signature.js";
|
||||
if (!Math) {
|
||||
(_easycom_up_textarea + _easycom_up_upload + _easycom_u_popup + _easycom_wd_signature)();
|
||||
(_easycom_up_textarea + _easycom_up_upload + _easycom_up_radio + _easycom_up_radio_group + FlowAssigneePickerPopup + _easycom_wd_signature)();
|
||||
}
|
||||
const FlowAssigneePickerPopup = () => "../../components/flow/FlowAssigneePickerPopup.js";
|
||||
const _sfc_main = {
|
||||
__name: "acceptance",
|
||||
setup(__props) {
|
||||
@@ -96,40 +99,24 @@ const _sfc_main = {
|
||||
if (formData.result === 2) {
|
||||
return { pass: false };
|
||||
}
|
||||
if (hazardEndRadio.value === "yes") {
|
||||
return { pass: true, hazardEnd: true };
|
||||
}
|
||||
return {
|
||||
pass: true,
|
||||
quickApprove: formData.quickApproveRadio === "yes"
|
||||
quickApprove: quickApproveRadio.value === "yes"
|
||||
};
|
||||
};
|
||||
const getStoredUserInfo = () => {
|
||||
try {
|
||||
const stored = common_vendor.index.getStorageSync("userInfo");
|
||||
if (!stored)
|
||||
return {};
|
||||
return typeof stored === "string" ? JSON.parse(stored) : stored;
|
||||
} catch (error) {
|
||||
return {};
|
||||
}
|
||||
};
|
||||
const getCurrentDeptId = () => {
|
||||
const userInfo = getStoredUserInfo();
|
||||
const identity = userInfo.userIdentity;
|
||||
if ((identity == null ? void 0 : identity.deptId) != null && identity.deptId !== "") {
|
||||
return String(identity.deptId);
|
||||
}
|
||||
if (userInfo.deptId != null && userInfo.deptId !== "") {
|
||||
return String(userInfo.deptId);
|
||||
}
|
||||
return "";
|
||||
};
|
||||
const rectifierDisplayName = common_vendor.computed(() => {
|
||||
var _a;
|
||||
return ((_a = rectifyData.rectifierName) == null ? void 0 : _a.trim()) || "暂无";
|
||||
});
|
||||
const showAssigneeSection = common_vendor.computed(() => {
|
||||
if (formData.result === 1 && hazardEndRadio.value === "yes")
|
||||
return false;
|
||||
if (formData.result === 2)
|
||||
return true;
|
||||
if (formData.result === 1 && formData.quickApproveRadio === "no")
|
||||
if (formData.result === 1 && quickApproveRadio.value === "no")
|
||||
return true;
|
||||
return false;
|
||||
});
|
||||
@@ -138,71 +125,18 @@ const _sfc_main = {
|
||||
const pickerAssigneeIdentityId = common_vendor.ref("");
|
||||
const pickerAssigneeName = common_vendor.ref("");
|
||||
const showAssigneePopup = common_vendor.ref(false);
|
||||
const assigneeList = common_vendor.ref([]);
|
||||
const assigneeLoading = common_vendor.ref(false);
|
||||
const resolveAssigneeIdentityId = (user) => {
|
||||
if (!user)
|
||||
return "";
|
||||
const id = user.identityId ?? user.userIdentityId ?? user.userId ?? "";
|
||||
return id === "" || id == null ? "" : String(id);
|
||||
};
|
||||
const getAssigneeItemKey = (user) => {
|
||||
const identityId = resolveAssigneeIdentityId(user);
|
||||
if (identityId)
|
||||
return `identity-${identityId}`;
|
||||
return `user-${user.userId || user.nickName || ""}`;
|
||||
};
|
||||
const formatAssigneeDisplayName = (user) => {
|
||||
if (!user)
|
||||
return "";
|
||||
const name = user.nickName || user.userName || user.name || "";
|
||||
const identityName = user.identityName || "";
|
||||
if (name && identityName)
|
||||
return `${name}(${identityName})`;
|
||||
return name || identityName || "未知人员";
|
||||
};
|
||||
const resolveAssigneeDeptUserType = () => formData.quickApproveRadio === "yes" ? 2 : 3;
|
||||
const fetchAssigneeList = async () => {
|
||||
const deptId = getCurrentDeptId();
|
||||
if (!deptId) {
|
||||
assigneeList.value = [];
|
||||
const openAssigneePopup = () => {
|
||||
if (!taskId.value) {
|
||||
common_vendor.index.showToast({ title: "缺少任务ID", icon: "none" });
|
||||
return;
|
||||
}
|
||||
assigneeLoading.value = true;
|
||||
try {
|
||||
const res = await request_api.getDeptUsers(deptId, { type: resolveAssigneeDeptUserType() });
|
||||
if (res.code === 0) {
|
||||
assigneeList.value = res.data || [];
|
||||
} else {
|
||||
assigneeList.value = [];
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/acceptance.vue:361", "获取部门人员失败:", error);
|
||||
assigneeList.value = [];
|
||||
} finally {
|
||||
assigneeLoading.value = false;
|
||||
}
|
||||
};
|
||||
const openAssigneePopup = async () => {
|
||||
pickerAssigneeIdentityId.value = selectedAssigneeIdentityId.value;
|
||||
pickerAssigneeName.value = selectedAssigneeName.value;
|
||||
showAssigneePopup.value = true;
|
||||
await fetchAssigneeList();
|
||||
};
|
||||
const onAssigneeItemClick = (user) => {
|
||||
const identityId = resolveAssigneeIdentityId(user);
|
||||
if (!identityId)
|
||||
return;
|
||||
pickerAssigneeIdentityId.value = String(identityId);
|
||||
pickerAssigneeName.value = formatAssigneeDisplayName(user);
|
||||
};
|
||||
const confirmAssigneeSelect = () => {
|
||||
if (!pickerAssigneeIdentityId.value) {
|
||||
common_vendor.index.showToast({ title: "请选择下一步处理人", icon: "none" });
|
||||
return;
|
||||
}
|
||||
selectedAssigneeIdentityId.value = pickerAssigneeIdentityId.value;
|
||||
selectedAssigneeName.value = pickerAssigneeName.value;
|
||||
const confirmAssigneeSelect = ({ identityId, name }) => {
|
||||
selectedAssigneeIdentityId.value = identityId;
|
||||
selectedAssigneeName.value = name;
|
||||
showAssigneePopup.value = false;
|
||||
};
|
||||
const cancelAssigneeSelect = () => {
|
||||
@@ -211,20 +145,33 @@ const _sfc_main = {
|
||||
const onResultChange = (result) => {
|
||||
formData.result = result;
|
||||
if (result === 2) {
|
||||
hazardEndRadio.value = "no";
|
||||
selectedAssigneeIdentityId.value = "";
|
||||
selectedAssigneeName.value = "";
|
||||
} else if (!formData.quickApproveRadio) {
|
||||
formData.quickApproveRadio = "yes";
|
||||
} else if (!quickApproveRadio.value) {
|
||||
quickApproveRadio.value = "yes";
|
||||
}
|
||||
fetchNextStep();
|
||||
};
|
||||
const onQuickApproveChange = (value) => {
|
||||
formData.quickApproveRadio = value;
|
||||
const onHazardEndChange = (value) => {
|
||||
if (value === "yes") {
|
||||
quickApproveRadio.value = "yes";
|
||||
selectedAssigneeIdentityId.value = "";
|
||||
selectedAssigneeName.value = "";
|
||||
} else {
|
||||
fetchNextStep();
|
||||
}
|
||||
};
|
||||
const onQuickApproveChange = () => {
|
||||
selectedAssigneeIdentityId.value = "";
|
||||
selectedAssigneeName.value = "";
|
||||
fetchNextStep();
|
||||
};
|
||||
const fetchNextStep = async () => {
|
||||
if (formData.result === 1 && hazardEndRadio.value === "yes") {
|
||||
nextStepName.value = "";
|
||||
return;
|
||||
}
|
||||
nextStepLoading.value = true;
|
||||
try {
|
||||
const currentTaskId = taskId.value;
|
||||
@@ -244,7 +191,7 @@ const _sfc_main = {
|
||||
nextStepName.value = "";
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/acceptance.vue:434", "获取下一步流程失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/acceptance.vue:376", "获取下一步流程失败:", error);
|
||||
nextStepName.value = "";
|
||||
} finally {
|
||||
nextStepLoading.value = false;
|
||||
@@ -285,13 +232,16 @@ const _sfc_main = {
|
||||
return `${num.toFixed(2)} 元`;
|
||||
};
|
||||
const rectifyAttachments = common_vendor.ref([]);
|
||||
const hazardEndRadio = common_vendor.ref("no");
|
||||
common_vendor.computed(() => hazardEndRadio.value === "yes");
|
||||
const normalizeHazardEndRadio = (value) => value === "yes" ? "yes" : "no";
|
||||
const quickApproveRadio = common_vendor.ref("yes");
|
||||
const normalizeQuickApproveRadio = (value) => value === "no" ? "no" : "yes";
|
||||
const formData = common_vendor.reactive({
|
||||
result: 1,
|
||||
// 验收结果 1.通过 2.不通过
|
||||
verifyRemark: "",
|
||||
verifyRemark: ""
|
||||
// 验收备注
|
||||
quickApproveRadio: "yes"
|
||||
// 是否快速审批 yes/no,仅通过时有效
|
||||
});
|
||||
const fileList1 = common_vendor.ref([]);
|
||||
const canvasWidth = common_vendor.ref(300);
|
||||
@@ -353,7 +303,8 @@ const _sfc_main = {
|
||||
formData: {
|
||||
result: formData.result,
|
||||
verifyRemark: formData.verifyRemark,
|
||||
quickApproveRadio: formData.quickApproveRadio
|
||||
hazardEndRadio: hazardEndRadio.value,
|
||||
quickApproveRadio: quickApproveRadio.value
|
||||
},
|
||||
selectedAssigneeIdentityId: selectedAssigneeIdentityId.value,
|
||||
selectedAssigneeName: selectedAssigneeName.value,
|
||||
@@ -370,7 +321,8 @@ const _sfc_main = {
|
||||
const form = data.formData || {};
|
||||
formData.result = form.result !== void 0 ? form.result : 1;
|
||||
formData.verifyRemark = form.verifyRemark || "";
|
||||
formData.quickApproveRadio = form.quickApproveRadio === "no" ? "no" : "yes";
|
||||
hazardEndRadio.value = normalizeHazardEndRadio(form.hazardEndRadio ?? (form.hazardEnd === true ? "yes" : "no"));
|
||||
quickApproveRadio.value = normalizeQuickApproveRadio(form.quickApproveRadio);
|
||||
selectedAssigneeIdentityId.value = data.selectedAssigneeIdentityId || "";
|
||||
selectedAssigneeName.value = data.selectedAssigneeName || "";
|
||||
fileList1.value = data.fileList1 || [];
|
||||
@@ -390,7 +342,8 @@ const _sfc_main = {
|
||||
clearForm: () => {
|
||||
formData.result = 1;
|
||||
formData.verifyRemark = "";
|
||||
formData.quickApproveRadio = "yes";
|
||||
hazardEndRadio.value = "no";
|
||||
quickApproveRadio.value = "yes";
|
||||
selectedAssigneeIdentityId.value = "";
|
||||
selectedAssigneeName.value = "";
|
||||
fileList1.value = [];
|
||||
@@ -423,7 +376,8 @@ const _sfc_main = {
|
||||
bindAutoSave(() => [
|
||||
formData.result,
|
||||
formData.verifyRemark,
|
||||
formData.quickApproveRadio,
|
||||
hazardEndRadio.value,
|
||||
quickApproveRadio.value,
|
||||
selectedAssigneeIdentityId.value,
|
||||
selectedAssigneeName.value,
|
||||
fileList1.value,
|
||||
@@ -503,7 +457,7 @@ const _sfc_main = {
|
||||
common_vendor.index.showToast({ title: res.msg || "获取整改详情失败", icon: "none" });
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/acceptance.vue:728", "获取整改详情失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/acceptance.vue:682", "获取整改详情失败:", error);
|
||||
common_vendor.index.showToast({ title: "获取整改详情失败", icon: "none" });
|
||||
}
|
||||
};
|
||||
@@ -533,7 +487,7 @@ const _sfc_main = {
|
||||
common_vendor.index.showToast({ title: res.msg || "获取详情失败", icon: "none" });
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/acceptance.vue:760", "获取隐患详情失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/acceptance.vue:714", "获取隐患详情失败:", error);
|
||||
common_vendor.index.showToast({ title: "请求失败", icon: "none" });
|
||||
}
|
||||
};
|
||||
@@ -546,11 +500,14 @@ const _sfc_main = {
|
||||
await fetchNextStep();
|
||||
};
|
||||
const validateFormBeforeSubmit = () => {
|
||||
if (formData.result === 1 && !formData.quickApproveRadio) {
|
||||
if (formData.result === 1 && hazardEndRadio.value === "yes") {
|
||||
return true;
|
||||
}
|
||||
if (formData.result === 1 && !quickApproveRadio.value) {
|
||||
common_vendor.index.showToast({ title: "请选择是否快速审批", icon: "none" });
|
||||
return false;
|
||||
}
|
||||
if (formData.result === 1 && formData.quickApproveRadio === "no" && !selectedAssigneeIdentityId.value) {
|
||||
if (formData.result === 1 && quickApproveRadio.value === "no" && !selectedAssigneeIdentityId.value) {
|
||||
common_vendor.index.showToast({ title: "请选择下一步处理人", icon: "none" });
|
||||
return false;
|
||||
}
|
||||
@@ -600,7 +557,7 @@ const _sfc_main = {
|
||||
} catch (err) {
|
||||
isSubmitting.value = false;
|
||||
common_vendor.index.hideLoading();
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/acceptance.vue:839", "签名上传失败:", err);
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/acceptance.vue:796", "签名上传失败:", err);
|
||||
common_vendor.index.showToast({ title: "签名上传失败,请重试", icon: "none" });
|
||||
}
|
||||
}
|
||||
@@ -612,17 +569,22 @@ const _sfc_main = {
|
||||
result: formData.result,
|
||||
verifyRemark: formData.verifyRemark || "",
|
||||
attachments,
|
||||
signPath: signatureServerPath.value || ""
|
||||
signPath: signatureServerPath.value || "",
|
||||
// 电子签名路径
|
||||
hazardEnd: formData.result === 1 && hazardEndRadio.value === "yes"
|
||||
// sendMsgFlag: sendMsgFlag.value
|
||||
};
|
||||
if (formData.result === 1) {
|
||||
params.quickApprove = formData.quickApproveRadio === "yes";
|
||||
if (formData.quickApproveRadio === "no") {
|
||||
params.assigneeIdentityId = selectedAssigneeIdentityId.value;
|
||||
if (hazardEndRadio.value === "yes") {
|
||||
params.quickApprove = null;
|
||||
} else {
|
||||
params.quickApprove = quickApproveRadio.value === "yes";
|
||||
if (quickApproveRadio.value === "no") {
|
||||
params.assigneeIdentityId = selectedAssigneeIdentityId.value;
|
||||
}
|
||||
}
|
||||
}
|
||||
common_vendor.index.__f__("log", "at pages/hiddendanger/acceptance.vue:868", "提交验收参数:", params);
|
||||
common_vendor.index.__f__("log", "at pages/hiddendanger/acceptance.vue:830", "提交验收参数:", params);
|
||||
try {
|
||||
const res = await request_api.acceptanceRectification(params);
|
||||
common_vendor.index.hideLoading();
|
||||
@@ -643,7 +605,7 @@ const _sfc_main = {
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.hideLoading();
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/acceptance.vue:890", "验收失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/acceptance.vue:852", "验收失败:", error);
|
||||
common_vendor.index.showToast({
|
||||
title: "请求失败",
|
||||
icon: "none"
|
||||
@@ -723,7 +685,7 @@ const _sfc_main = {
|
||||
} catch (err) {
|
||||
isSubmitting.value = false;
|
||||
common_vendor.index.hideLoading();
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/acceptance.vue:999", "签名上传失败:", err);
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/acceptance.vue:961", "签名上传失败:", err);
|
||||
common_vendor.index.showToast({ title: "签名上传失败,请重试", icon: "none" });
|
||||
}
|
||||
};
|
||||
@@ -739,7 +701,7 @@ const _sfc_main = {
|
||||
const sysInfo = common_vendor.index.getSystemInfoSync();
|
||||
signatureWidth.value = sysInfo.windowWidth - 40;
|
||||
} catch (e) {
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/acceptance.vue:1018", "获取系统信息失败:", e);
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/acceptance.vue:980", "获取系统信息失败:", e);
|
||||
}
|
||||
if (options.rectifyId) {
|
||||
rectifyId.value = options.rectifyId;
|
||||
@@ -753,9 +715,13 @@ const _sfc_main = {
|
||||
if (options.taskId) {
|
||||
taskId.value = options.taskId;
|
||||
}
|
||||
common_vendor.index.__f__("log", "at pages/hiddendanger/acceptance.vue:1032", "验收页面参数:", { rectifyId: rectifyId.value, hazardId: hazardId.value, assignId: assignId.value, taskId: taskId.value });
|
||||
common_vendor.index.__f__("log", "at pages/hiddendanger/acceptance.vue:994", "验收页面参数:", { rectifyId: rectifyId.value, hazardId: hazardId.value, assignId: assignId.value, taskId: taskId.value });
|
||||
loadPageData();
|
||||
restoreDraft();
|
||||
common_vendor.nextTick$1(() => {
|
||||
hazardEndRadio.value = normalizeHazardEndRadio(hazardEndRadio.value);
|
||||
quickApproveRadio.value = normalizeQuickApproveRadio(quickApproveRadio.value);
|
||||
});
|
||||
});
|
||||
return (_ctx, _cache) => {
|
||||
return common_vendor.e({
|
||||
@@ -797,75 +763,102 @@ const _sfc_main = {
|
||||
maxCount: 10
|
||||
}),
|
||||
v: formData.result === 1
|
||||
}, formData.result === 1 ? {} : {}, {
|
||||
w: formData.result === 1
|
||||
}, formData.result === 1 ? {
|
||||
x: common_vendor.n(formData.quickApproveRadio === "yes" ? "active" : ""),
|
||||
y: common_vendor.o(($event) => onQuickApproveChange("yes")),
|
||||
z: common_vendor.n(formData.quickApproveRadio === "no" ? "active" : ""),
|
||||
A: common_vendor.o(($event) => onQuickApproveChange("no"))
|
||||
} : {}, {
|
||||
B: canvasWidth.value,
|
||||
C: canvasHeight.value,
|
||||
D: canvasWidth.value + "px",
|
||||
E: canvasHeight.value + "px",
|
||||
F: common_vendor.t(nextStepDisplay.value),
|
||||
G: showAssigneeSection.value
|
||||
}, showAssigneeSection.value ? common_vendor.e({
|
||||
H: formData.result === 2
|
||||
}, formData.result === 2 ? {
|
||||
I: common_vendor.t(rectifierDisplayName.value)
|
||||
} : {
|
||||
J: common_vendor.t(selectedAssigneeName.value || "请选择下一步处理人"),
|
||||
K: !selectedAssigneeName.value ? 1 : "",
|
||||
L: common_vendor.o(openAssigneePopup)
|
||||
}) : {}, {
|
||||
M: common_vendor.o(cancelAssigneeSelect),
|
||||
N: assigneeLoading.value
|
||||
}, assigneeLoading.value ? {} : assigneeList.value.length === 0 ? {} : {
|
||||
P: common_vendor.f(assigneeList.value, (user, k0, i0) => {
|
||||
return common_vendor.e({
|
||||
a: common_vendor.t(formatAssigneeDisplayName(user)),
|
||||
b: String(pickerAssigneeIdentityId.value) === String(resolveAssigneeIdentityId(user))
|
||||
}, String(pickerAssigneeIdentityId.value) === String(resolveAssigneeIdentityId(user)) ? {} : {}, {
|
||||
c: getAssigneeItemKey(user),
|
||||
d: String(pickerAssigneeIdentityId.value) === String(resolveAssigneeIdentityId(user)) ? 1 : "",
|
||||
e: common_vendor.o(($event) => onAssigneeItemClick(user), getAssigneeItemKey(user))
|
||||
});
|
||||
})
|
||||
}, {
|
||||
O: assigneeList.value.length === 0,
|
||||
Q: common_vendor.o(cancelAssigneeSelect),
|
||||
R: common_vendor.o(confirmAssigneeSelect),
|
||||
S: common_vendor.o(cancelAssigneeSelect),
|
||||
T: common_vendor.p({
|
||||
show: showAssigneePopup.value,
|
||||
mode: "bottom",
|
||||
round: "20"
|
||||
w: common_vendor.p({
|
||||
label: "否",
|
||||
name: "no",
|
||||
customStyle: {
|
||||
marginRight: "48rpx"
|
||||
}
|
||||
}),
|
||||
U: showCanvas.value
|
||||
}, showCanvas.value ? {
|
||||
V: common_vendor.o(clearSignature)
|
||||
x: common_vendor.p({
|
||||
label: "是",
|
||||
name: "yes"
|
||||
}),
|
||||
y: "hazard-end-" + hazardEndRadio.value,
|
||||
z: common_vendor.o(onHazardEndChange),
|
||||
A: common_vendor.o(($event) => hazardEndRadio.value = $event),
|
||||
B: common_vendor.p({
|
||||
placement: "row",
|
||||
activeColor: "#2667e9",
|
||||
modelValue: hazardEndRadio.value
|
||||
})
|
||||
} : {}, {
|
||||
C: formData.result === 1 && hazardEndRadio.value !== "yes"
|
||||
}, formData.result === 1 && hazardEndRadio.value !== "yes" ? {
|
||||
D: common_vendor.p({
|
||||
label: "是",
|
||||
name: "yes",
|
||||
customStyle: {
|
||||
marginRight: "48rpx"
|
||||
}
|
||||
}),
|
||||
E: common_vendor.p({
|
||||
label: "否",
|
||||
name: "no"
|
||||
}),
|
||||
F: "quick-approve-" + quickApproveRadio.value,
|
||||
G: common_vendor.o(onQuickApproveChange),
|
||||
H: common_vendor.o(($event) => quickApproveRadio.value = $event),
|
||||
I: common_vendor.p({
|
||||
placement: "row",
|
||||
activeColor: "#2667e9",
|
||||
modelValue: quickApproveRadio.value
|
||||
})
|
||||
} : {}, {
|
||||
J: canvasWidth.value,
|
||||
K: canvasHeight.value,
|
||||
L: canvasWidth.value + "px",
|
||||
M: canvasHeight.value + "px",
|
||||
N: !(formData.result === 1 && hazardEndRadio.value === "yes")
|
||||
}, !(formData.result === 1 && hazardEndRadio.value === "yes") ? {} : {}, {
|
||||
O: !(formData.result === 1 && hazardEndRadio.value === "yes")
|
||||
}, !(formData.result === 1 && hazardEndRadio.value === "yes") ? {
|
||||
P: common_vendor.t(nextStepDisplay.value)
|
||||
} : {}, {
|
||||
Q: showAssigneeSection.value
|
||||
}, showAssigneeSection.value ? common_vendor.e({
|
||||
R: formData.result === 2
|
||||
}, formData.result === 2 ? {
|
||||
S: common_vendor.t(rectifierDisplayName.value)
|
||||
} : {
|
||||
W: common_vendor.o(reSign)
|
||||
T: common_vendor.t(selectedAssigneeName.value || "请选择下一步处理人"),
|
||||
U: !selectedAssigneeName.value ? 1 : "",
|
||||
V: common_vendor.o(openAssigneePopup)
|
||||
}) : {}, {
|
||||
W: common_vendor.o(cancelAssigneeSelect),
|
||||
X: common_vendor.o(confirmAssigneeSelect),
|
||||
Y: common_vendor.o(($event) => pickerAssigneeIdentityId.value = $event),
|
||||
Z: common_vendor.o(($event) => pickerAssigneeName.value = $event),
|
||||
aa: common_vendor.p({
|
||||
show: showAssigneePopup.value,
|
||||
["task-id"]: taskId.value,
|
||||
["picker-identity-id"]: pickerAssigneeIdentityId.value,
|
||||
["picker-name"]: pickerAssigneeName.value
|
||||
}),
|
||||
ab: showCanvas.value
|
||||
}, showCanvas.value ? {
|
||||
ac: common_vendor.o(clearSignature)
|
||||
} : {
|
||||
ad: common_vendor.o(reSign)
|
||||
}, {
|
||||
X: !showCanvas.value
|
||||
ae: !showCanvas.value
|
||||
}, !showCanvas.value ? common_vendor.e({
|
||||
Y: signatureUrl.value
|
||||
af: signatureUrl.value
|
||||
}, signatureUrl.value ? {
|
||||
Z: signatureUrl.value
|
||||
ag: signatureUrl.value
|
||||
} : {}) : {}, {
|
||||
aa: showCanvas.value && !showAssigneePopup.value
|
||||
ah: showCanvas.value && !showAssigneePopup.value
|
||||
}, showCanvas.value && !showAssigneePopup.value ? {
|
||||
ab: common_vendor.sr(signatureRef, "39f9b795-3", {
|
||||
ai: common_vendor.sr(signatureRef, "39f9b795-9", {
|
||||
"k": "signatureRef"
|
||||
}),
|
||||
ac: common_vendor.o((res) => onSignatureConfirm(res.tempFilePath)),
|
||||
ad: common_vendor.o(onSignatureStart),
|
||||
ae: common_vendor.o(onSignatureSigning),
|
||||
af: common_vendor.o(onSignatureEnd),
|
||||
ag: common_vendor.o(onSignatureClear),
|
||||
ah: common_vendor.p({
|
||||
aj: common_vendor.o((res) => onSignatureConfirm(res.tempFilePath)),
|
||||
ak: common_vendor.o(onSignatureStart),
|
||||
al: common_vendor.o(onSignatureSigning),
|
||||
am: common_vendor.o(onSignatureEnd),
|
||||
an: common_vendor.o(onSignatureClear),
|
||||
ao: common_vendor.p({
|
||||
width: signatureWidth.value,
|
||||
height: 160,
|
||||
backgroundColor: "#f8f8f8",
|
||||
@@ -874,9 +867,9 @@ const _sfc_main = {
|
||||
enableHistory: false
|
||||
})
|
||||
} : {}, {
|
||||
ai: common_vendor.o(handleCancel),
|
||||
aj: common_vendor.o(handleSubmit),
|
||||
ak: common_vendor.gei(_ctx, "")
|
||||
ap: common_vendor.o(handleCancel),
|
||||
aq: common_vendor.o(handleSubmit),
|
||||
ar: common_vendor.gei(_ctx, "")
|
||||
});
|
||||
};
|
||||
}
|
||||
|
||||
@@ -3,7 +3,9 @@
|
||||
"usingComponents": {
|
||||
"up-textarea": "../../uni_modules/uview-plus/components/u-textarea/u-textarea",
|
||||
"up-upload": "../../uni_modules/uview-plus/components/u-upload/u-upload",
|
||||
"u-popup": "../../uni_modules/uview-plus/components/u-popup/u-popup",
|
||||
"wd-signature": "../../node-modules/wot-design-uni/components/wd-signature/wd-signature"
|
||||
"up-radio": "../../uni_modules/uview-plus/components/u-radio/u-radio",
|
||||
"up-radio-group": "../../uni_modules/uview-plus/components/u-radio-group/u-radio-group",
|
||||
"wd-signature": "../../node-modules/wot-design-uni/components/wd-signature/wd-signature",
|
||||
"flow-assignee-picker-popup": "../../components/flow/FlowAssigneePickerPopup"
|
||||
}
|
||||
}
|
||||
File diff suppressed because one or more lines are too long
@@ -69,83 +69,6 @@
|
||||
font-size: 28rpx;
|
||||
color: #333;
|
||||
}
|
||||
.user-popup.data-v-39f9b795 {
|
||||
background: #fff;
|
||||
}
|
||||
.user-popup .popup-header.data-v-39f9b795 {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
padding: 30rpx;
|
||||
border-bottom: 1rpx solid #eee;
|
||||
}
|
||||
.user-popup .popup-header .popup-title.data-v-39f9b795 {
|
||||
font-size: 32rpx;
|
||||
color: #333;
|
||||
}
|
||||
.user-popup .popup-header .popup-close.data-v-39f9b795 {
|
||||
font-size: 40rpx;
|
||||
color: #999;
|
||||
line-height: 1;
|
||||
}
|
||||
.user-popup .user-list-scroll.data-v-39f9b795 {
|
||||
max-height: 600rpx;
|
||||
padding: 0 30rpx;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
.user-popup .empty-tip.data-v-39f9b795 {
|
||||
padding: 80rpx 20rpx;
|
||||
text-align: center;
|
||||
color: #909399;
|
||||
font-size: 26rpx;
|
||||
}
|
||||
.user-popup .user-item.data-v-39f9b795 {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
padding: 24rpx 0;
|
||||
border-bottom: 1rpx solid #f5f5f5;
|
||||
}
|
||||
.user-popup .user-item.data-v-39f9b795:last-child {
|
||||
border-bottom: none;
|
||||
}
|
||||
.user-popup .user-item.active .user-item-text.data-v-39f9b795 {
|
||||
color: #2667E9;
|
||||
font-weight: 600;
|
||||
}
|
||||
.user-popup .user-item .user-item-text.data-v-39f9b795 {
|
||||
flex: 1;
|
||||
font-size: 28rpx;
|
||||
color: #333;
|
||||
}
|
||||
.user-popup .popup-footer.data-v-39f9b795 {
|
||||
display: flex;
|
||||
gap: 24rpx;
|
||||
padding: 24rpx 30rpx;
|
||||
padding-bottom: calc(24rpx + env(safe-area-inset-bottom));
|
||||
background: #fff;
|
||||
}
|
||||
.user-popup .popup-footer button.data-v-39f9b795 {
|
||||
flex: 1;
|
||||
height: 80rpx;
|
||||
line-height: 80rpx;
|
||||
border-radius: 40rpx;
|
||||
font-size: 30rpx;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
.user-popup .popup-footer button.data-v-39f9b795::after {
|
||||
border: none;
|
||||
}
|
||||
.user-popup .popup-footer .btn-cancel.data-v-39f9b795 {
|
||||
background: #fff;
|
||||
color: #2667E9;
|
||||
border: 2rpx solid #2667E9;
|
||||
}
|
||||
.user-popup .popup-footer .btn-confirm.data-v-39f9b795 {
|
||||
color: #fff;
|
||||
border: none;
|
||||
}
|
||||
.signature-box.data-v-39f9b795 {
|
||||
width: 100%;
|
||||
min-height: 240rpx;
|
||||
|
||||
@@ -114,7 +114,7 @@ const _sfc_main = {
|
||||
nextStepName.value = "";
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:392", "获取下一步流程失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:407", "获取下一步流程失败:", error);
|
||||
nextStepName.value = "";
|
||||
} finally {
|
||||
nextStepLoading.value = false;
|
||||
@@ -195,7 +195,7 @@ const _sfc_main = {
|
||||
scheduleSignatureDraftExport();
|
||||
};
|
||||
const onSignatureImageError = () => {
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:502", "签名图片加载失败:", signatureUrl.value);
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:517", "签名图片加载失败:", signatureUrl.value);
|
||||
common_vendor.index.showToast({ title: "签名图片加载失败", icon: "none" });
|
||||
};
|
||||
const reSign = () => {
|
||||
@@ -229,6 +229,9 @@ const _sfc_main = {
|
||||
const showRectifyTimePicker = common_vendor.ref(false);
|
||||
const rectifyTimeValue = common_vendor.ref(Date.now());
|
||||
const selectedRectifyTime = common_vendor.ref("");
|
||||
const hazardEndRadio = common_vendor.ref("no");
|
||||
const hazardEnd = common_vendor.computed(() => hazardEndRadio.value === "yes");
|
||||
const normalizeHazardEndRadio = (value) => value === "yes" ? "yes" : "no";
|
||||
const sendMsgFlagRadio = common_vendor.ref("yes");
|
||||
const sendMsgFlag = common_vendor.computed(() => sendMsgFlagRadio.value === "yes");
|
||||
const formatDateValue = (timestamp) => {
|
||||
@@ -536,7 +539,7 @@ const _sfc_main = {
|
||||
}
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:881", "获取关联部门人员列表失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:901", "获取关联部门人员列表失败:", error);
|
||||
}
|
||||
};
|
||||
const fetchPersonnelLists = async () => {
|
||||
@@ -568,7 +571,8 @@ const _sfc_main = {
|
||||
memberIds: selectedIdentityIds.value.map((id) => Number(id)),
|
||||
rectifyTime: selectedRectifyTime.value || formatDateValue(rectifyTimeValue.value),
|
||||
signPath: signatureServerPath.value || "",
|
||||
sendMsgFlag: sendMsgFlag.value
|
||||
hazardEnd: hazardEnd.value,
|
||||
sendMsgFlag: hazardEnd.value ? null : sendMsgFlag.value
|
||||
};
|
||||
if (selectedDeadlineDate.value) {
|
||||
params.deadline = selectedDeadlineDate.value;
|
||||
@@ -613,7 +617,7 @@ const _sfc_main = {
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.hideLoading();
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:1000", isEdit.value ? "保存整改失败:" : "提交整改失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:1021", isEdit.value ? "保存整改失败:" : "提交整改失败:", error);
|
||||
common_vendor.index.showToast({
|
||||
title: "操作失败",
|
||||
icon: "none"
|
||||
@@ -639,7 +643,7 @@ const _sfc_main = {
|
||||
} catch (err) {
|
||||
isSubmitting.value = false;
|
||||
common_vendor.index.hideLoading();
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:1030", "签名上传失败:", err);
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:1051", "签名上传失败:", err);
|
||||
common_vendor.index.showToast({ title: "签名上传失败,请重试", icon: "none" });
|
||||
}
|
||||
};
|
||||
@@ -723,7 +727,7 @@ const _sfc_main = {
|
||||
} catch (err) {
|
||||
isSubmitting.value = false;
|
||||
common_vendor.index.hideLoading();
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:1121", "签名上传失败:", err);
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:1142", "签名上传失败:", err);
|
||||
common_vendor.index.showToast({ title: "签名上传失败,请重试", icon: "none" });
|
||||
}
|
||||
}
|
||||
@@ -748,7 +752,7 @@ const _sfc_main = {
|
||||
applyRectifyTimeValue(data.rectifyTime);
|
||||
}
|
||||
const signPath = resolveSignPathFromData(data);
|
||||
common_vendor.index.__f__("log", "at pages/hiddendanger/rectification.vue:1224", "整改详情签名路径:", signPath);
|
||||
common_vendor.index.__f__("log", "at pages/hiddendanger/rectification.vue:1245", "整改详情签名路径:", signPath);
|
||||
applySignatureFromServer(signPath);
|
||||
hazardId.value = data.hazardId || "";
|
||||
assignId.value = data.assignId || "";
|
||||
@@ -783,7 +787,7 @@ const _sfc_main = {
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.hideLoading();
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:1267", "获取整改详情失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:1288", "获取整改详情失败:", error);
|
||||
common_vendor.index.showToast({ title: "获取详情失败", icon: "none" });
|
||||
}
|
||||
};
|
||||
@@ -814,7 +818,7 @@ const _sfc_main = {
|
||||
common_vendor.index.showToast({ title: aiRes.msg || "AI生成失败", icon: "none" });
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:1304", "AI生成整改方案失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:1325", "AI生成整改方案失败:", error);
|
||||
common_vendor.index.showToast({ title: "AI生成失败,请重试", icon: "none" });
|
||||
} finally {
|
||||
aiGenerating.value = false;
|
||||
@@ -853,7 +857,8 @@ const _sfc_main = {
|
||||
signatureLocalPath: signatureLocalPath.value,
|
||||
showCanvas: showCanvas.value,
|
||||
signaturePaths: signaturePaths.value,
|
||||
sendMsgFlagRadio: sendMsgFlagRadio.value
|
||||
sendMsgFlagRadio: sendMsgFlagRadio.value,
|
||||
hazardEndRadio: hazardEndRadio.value
|
||||
}),
|
||||
hasContent: rectifyDraftHasContent,
|
||||
applyPayload: (data) => {
|
||||
@@ -874,6 +879,7 @@ const _sfc_main = {
|
||||
showCanvas.value = false;
|
||||
}
|
||||
sendMsgFlagRadio.value = data.sendMsgFlagRadio === "no" ? "no" : "yes";
|
||||
hazardEndRadio.value = normalizeHazardEndRadio(data.hazardEndRadio ?? (data.hazardEnd === true ? "yes" : "no"));
|
||||
},
|
||||
clearForm: () => {
|
||||
formData.rectifyPlan = "";
|
||||
@@ -892,6 +898,7 @@ const _sfc_main = {
|
||||
signatureRef.value.clear();
|
||||
}
|
||||
sendMsgFlagRadio.value = "yes";
|
||||
hazardEndRadio.value = "no";
|
||||
},
|
||||
canSave: () => !!(hazardId.value || rectifyId.value),
|
||||
onAfterRestore: (data) => {
|
||||
@@ -921,7 +928,8 @@ const _sfc_main = {
|
||||
signatureLocalPath.value,
|
||||
showCanvas.value,
|
||||
signaturePaths.value,
|
||||
sendMsgFlagRadio.value
|
||||
sendMsgFlagRadio.value,
|
||||
hazardEndRadio.value
|
||||
]);
|
||||
common_vendor.onHide(() => {
|
||||
if (showCanvas.value && !isSignatureEmpty.value && signatureRef.value && !isDraftExporting.value) {
|
||||
@@ -935,7 +943,7 @@ const _sfc_main = {
|
||||
const sysInfo = common_vendor.index.getSystemInfoSync();
|
||||
signatureWidth.value = sysInfo.windowWidth - 40;
|
||||
} catch (e) {
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:1442", "获取系统信息失败:", e);
|
||||
common_vendor.index.__f__("error", "at pages/hiddendanger/rectification.vue:1467", "获取系统信息失败:", e);
|
||||
}
|
||||
if (options.hazardId) {
|
||||
hazardId.value = options.hazardId;
|
||||
@@ -959,6 +967,9 @@ const _sfc_main = {
|
||||
restoreDraft();
|
||||
initRectifyTimeDefault();
|
||||
}
|
||||
common_vendor.nextTick$1(() => {
|
||||
hazardEndRadio.value = normalizeHazardEndRadio(hazardEndRadio.value);
|
||||
});
|
||||
if (options.deadline) {
|
||||
applyDeadlineFromOptions(options.deadline);
|
||||
}
|
||||
@@ -1149,48 +1160,69 @@ const _sfc_main = {
|
||||
at: canvasWidth.value + "px",
|
||||
av: canvasHeight.value + "px"
|
||||
} : {}, {
|
||||
aw: common_vendor.t(nextStepDisplay.value),
|
||||
aw: common_vendor.p({
|
||||
label: "否",
|
||||
name: "no",
|
||||
customStyle: {
|
||||
marginRight: "48rpx"
|
||||
}
|
||||
}),
|
||||
ax: common_vendor.p({
|
||||
label: "是",
|
||||
name: "yes"
|
||||
}),
|
||||
ay: "hazard-end-" + hazardEndRadio.value,
|
||||
az: common_vendor.o(($event) => hazardEndRadio.value = $event),
|
||||
aA: common_vendor.p({
|
||||
placement: "row",
|
||||
activeColor: "#2667e9",
|
||||
modelValue: hazardEndRadio.value
|
||||
}),
|
||||
aB: !hazardEnd.value
|
||||
}, !hazardEnd.value ? {
|
||||
aC: common_vendor.t(nextStepDisplay.value),
|
||||
aD: common_vendor.p({
|
||||
label: "是",
|
||||
name: "yes",
|
||||
customStyle: {
|
||||
marginRight: "48rpx"
|
||||
}
|
||||
}),
|
||||
ay: common_vendor.p({
|
||||
aE: common_vendor.p({
|
||||
label: "否",
|
||||
name: "no"
|
||||
}),
|
||||
az: common_vendor.o(($event) => sendMsgFlagRadio.value = $event),
|
||||
aA: common_vendor.p({
|
||||
aF: common_vendor.o(($event) => sendMsgFlagRadio.value = $event),
|
||||
aG: common_vendor.p({
|
||||
placement: "row",
|
||||
activeColor: "#2667e9",
|
||||
modelValue: sendMsgFlagRadio.value
|
||||
}),
|
||||
aB: showCanvas.value
|
||||
})
|
||||
} : {}, {
|
||||
aH: showCanvas.value
|
||||
}, showCanvas.value ? {
|
||||
aC: common_vendor.o(clearSignature)
|
||||
aI: common_vendor.o(clearSignature)
|
||||
} : {
|
||||
aD: common_vendor.o(reSign)
|
||||
aJ: common_vendor.o(reSign)
|
||||
}, {
|
||||
aE: !showCanvas.value
|
||||
aK: !showCanvas.value
|
||||
}, !showCanvas.value ? common_vendor.e({
|
||||
aF: signatureUrl.value
|
||||
aL: signatureUrl.value
|
||||
}, signatureUrl.value ? {
|
||||
aG: signatureUrl.value,
|
||||
aH: common_vendor.o(onSignatureImageError)
|
||||
aM: signatureUrl.value,
|
||||
aN: common_vendor.o(onSignatureImageError)
|
||||
} : {}) : {}, {
|
||||
aI: showCanvas.value && !showUserPopup.value && !showManagerPopup.value && !showRectifyTimePicker.value
|
||||
aO: showCanvas.value && !showUserPopup.value && !showManagerPopup.value && !showRectifyTimePicker.value
|
||||
}, showCanvas.value && !showUserPopup.value && !showManagerPopup.value && !showRectifyTimePicker.value ? {
|
||||
aJ: common_vendor.sr(signatureRef, "f18ba0ce-15", {
|
||||
aP: common_vendor.sr(signatureRef, "f18ba0ce-18", {
|
||||
"k": "signatureRef"
|
||||
}),
|
||||
aK: common_vendor.o((res) => onSignatureConfirm(res.tempFilePath)),
|
||||
aL: common_vendor.o(onSignatureStart),
|
||||
aM: common_vendor.o(onSignatureSigning),
|
||||
aN: common_vendor.o(onSignatureEnd),
|
||||
aO: common_vendor.o(onSignatureClear),
|
||||
aP: common_vendor.p({
|
||||
aQ: common_vendor.o((res) => onSignatureConfirm(res.tempFilePath)),
|
||||
aR: common_vendor.o(onSignatureStart),
|
||||
aS: common_vendor.o(onSignatureSigning),
|
||||
aT: common_vendor.o(onSignatureEnd),
|
||||
aU: common_vendor.o(onSignatureClear),
|
||||
aV: common_vendor.p({
|
||||
width: signatureWidth.value,
|
||||
height: 160,
|
||||
backgroundColor: "#f8f8f8",
|
||||
@@ -1199,9 +1231,9 @@ const _sfc_main = {
|
||||
enableHistory: false
|
||||
})
|
||||
} : {}, {
|
||||
aQ: common_vendor.t(isEdit.value ? "保存修改" : "提交整改"),
|
||||
aR: common_vendor.o(handleSubmit),
|
||||
aS: common_vendor.gei(_ctx, "")
|
||||
aW: common_vendor.t(isEdit.value ? "保存修改" : "提交整改"),
|
||||
aX: common_vendor.o(handleSubmit),
|
||||
aY: common_vendor.gei(_ctx, "")
|
||||
});
|
||||
};
|
||||
}
|
||||
|
||||
File diff suppressed because one or more lines are too long
109
unpackage/dist/dev/mp-weixin/pages/index/index.js
vendored
109
unpackage/dist/dev/mp-weixin/pages/index/index.js
vendored
@@ -39,6 +39,7 @@ const _sfc_main = {
|
||||
});
|
||||
const currentRoleKey = common_vendor.computed(() => utils_userInfo.resolveUserIdentityRoleKey(userInfo));
|
||||
const isApprovalRole = common_vendor.computed(() => currentRoleKey.value === "approval");
|
||||
const showCheckPlanSection = common_vendor.computed(() => !isApprovalRole.value && currentRoleKey.value !== "manage");
|
||||
const displayIdentityName = common_vendor.computed(() => {
|
||||
return utils_userInfo.resolveIdentityName(userInfo, userInfo.userIdentity);
|
||||
});
|
||||
@@ -49,7 +50,7 @@ const _sfc_main = {
|
||||
utils_userInfo.applyStoredUserInfo(userInfo, JSON.parse(storedUserInfo));
|
||||
}
|
||||
} catch (storageError) {
|
||||
common_vendor.index.__f__("error", "at pages/index/index.vue:318", "从本地存储获取用户信息失败:", storageError);
|
||||
common_vendor.index.__f__("error", "at pages/index/index.vue:328", "从本地存储获取用户信息失败:", storageError);
|
||||
}
|
||||
};
|
||||
const getImageUrl = (path) => {
|
||||
@@ -64,7 +65,7 @@ const _sfc_main = {
|
||||
utils_userInfo.applyProfileToUserInfo(userInfo, res.data);
|
||||
}
|
||||
} catch (e) {
|
||||
common_vendor.index.__f__("error", "at pages/index/index.vue:336", "获取用户信息失败:", e);
|
||||
common_vendor.index.__f__("error", "at pages/index/index.vue:346", "获取用户信息失败:", e);
|
||||
loadUserInfoFromStorage();
|
||||
}
|
||||
};
|
||||
@@ -103,14 +104,18 @@ const _sfc_main = {
|
||||
}
|
||||
];
|
||||
const commonMenuNames = ["隐患排查", "隐患销号"];
|
||||
const govEntityAdminHiddenMenuNames = ["成员管理", "信息填报", "区域设置", "证件管理"];
|
||||
const infoList = common_vendor.computed(() => {
|
||||
let list = allMenuList;
|
||||
if (currentRoleKey.value === "approval") {
|
||||
return allMenuList.filter((item) => item.name === "隐患排查");
|
||||
list = list.filter((item) => item.name === "隐患排查");
|
||||
} else if (currentRoleKey.value === "common") {
|
||||
list = list.filter((item) => commonMenuNames.includes(item.name));
|
||||
}
|
||||
if (currentRoleKey.value === "common") {
|
||||
return allMenuList.filter((item) => commonMenuNames.includes(item.name));
|
||||
if (utils_userInfo.isGovernmentEntityAdmin(userInfo)) {
|
||||
list = list.filter((item) => !govEntityAdminHiddenMenuNames.includes(item.name));
|
||||
}
|
||||
return allMenuList;
|
||||
return list;
|
||||
});
|
||||
const formatProgress = (progress) => {
|
||||
const num = Number(progress);
|
||||
@@ -168,6 +173,12 @@ const _sfc_main = {
|
||||
common_vendor.index.showToast({ title: "功能开发中", icon: "none" });
|
||||
}
|
||||
};
|
||||
const planTabs = [
|
||||
{ label: "全部", value: 0 },
|
||||
{ label: "未完成", value: 4 },
|
||||
{ label: "已完成", value: 3 }
|
||||
];
|
||||
const activePlanTab = common_vendor.ref(0);
|
||||
const checkPlanParams = common_vendor.ref({
|
||||
pageNum: 1,
|
||||
pageSize: PLAN_INITIAL_SIZE,
|
||||
@@ -177,6 +188,18 @@ const _sfc_main = {
|
||||
const checkPlanTotal = common_vendor.ref(0);
|
||||
const planShowAll = common_vendor.ref(false);
|
||||
const expandedPlanMap = common_vendor.ref({});
|
||||
const buildCheckPlanListParams = (pageSize) => ({
|
||||
pageNum: 1,
|
||||
pageSize,
|
||||
name: checkPlanParams.value.name,
|
||||
planStatus: planTabs[activePlanTab.value].value
|
||||
});
|
||||
const switchPlanTab = (index) => {
|
||||
if (activePlanTab.value === index)
|
||||
return;
|
||||
activePlanTab.value = index;
|
||||
getCheckPlanLists();
|
||||
};
|
||||
const hasMoreCheckPlans = common_vendor.computed(() => {
|
||||
return !planShowAll.value && checkPlanTotal.value > PLAN_INITIAL_SIZE;
|
||||
});
|
||||
@@ -202,11 +225,7 @@ const _sfc_main = {
|
||||
var _a, _b;
|
||||
planShowAll.value = false;
|
||||
try {
|
||||
const res = await request_api.getCheckPlanList({
|
||||
pageNum: 1,
|
||||
pageSize: PLAN_INITIAL_SIZE,
|
||||
name: checkPlanParams.value.name
|
||||
});
|
||||
const res = await request_api.getCheckPlanList(buildCheckPlanListParams(PLAN_INITIAL_SIZE));
|
||||
if (res.code === 0) {
|
||||
const records = ((_a = res.data) == null ? void 0 : _a.records) || [];
|
||||
checkPlanTotal.value = Number(((_b = res.data) == null ? void 0 : _b.total) ?? records.length);
|
||||
@@ -214,7 +233,7 @@ const _sfc_main = {
|
||||
initPlanExpandedState(records, { reset: true, expandFirst: true });
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/index/index.vue:509", error);
|
||||
common_vendor.index.__f__("error", "at pages/index/index.vue:539", error);
|
||||
} finally {
|
||||
loading.value = false;
|
||||
}
|
||||
@@ -224,11 +243,7 @@ const _sfc_main = {
|
||||
if (!hasMoreCheckPlans.value)
|
||||
return;
|
||||
try {
|
||||
const res = await request_api.getCheckPlanList({
|
||||
pageNum: 1,
|
||||
pageSize: checkPlanTotal.value,
|
||||
name: checkPlanParams.value.name
|
||||
});
|
||||
const res = await request_api.getCheckPlanList(buildCheckPlanListParams(checkPlanTotal.value));
|
||||
if (res.code === 0) {
|
||||
const records = ((_a = res.data) == null ? void 0 : _a.records) || [];
|
||||
initPlanExpandedState(records);
|
||||
@@ -238,7 +253,7 @@ const _sfc_main = {
|
||||
common_vendor.index.showToast({ title: res.msg || "加载失败", icon: "none" });
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/index/index.vue:532", error);
|
||||
common_vendor.index.__f__("error", "at pages/index/index.vue:558", error);
|
||||
common_vendor.index.showToast({ title: "加载失败", icon: "none" });
|
||||
}
|
||||
};
|
||||
@@ -253,7 +268,9 @@ const _sfc_main = {
|
||||
if (isApprovalRole.value) {
|
||||
fetchWorkbenchList();
|
||||
} else {
|
||||
getCheckPlanLists();
|
||||
if (showCheckPlanSection.value) {
|
||||
getCheckPlanLists();
|
||||
}
|
||||
resetHiddenDangerList();
|
||||
fetchHiddenDangerList();
|
||||
}
|
||||
@@ -327,7 +344,7 @@ const _sfc_main = {
|
||||
hiddenDangerLoadStatus.value = "nomore";
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/index/index.vue:635", error);
|
||||
common_vendor.index.__f__("error", "at pages/index/index.vue:663", error);
|
||||
if (hiddenDangerPageNum.value > 1) {
|
||||
hiddenDangerPageNum.value--;
|
||||
}
|
||||
@@ -417,7 +434,7 @@ const _sfc_main = {
|
||||
common_vendor.index.showToast({ title: res.msg || "获取工作台数据失败", icon: "none" });
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/index/index.vue:727", "获取工作台数据失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/index/index.vue:755", "获取工作台数据失败:", error);
|
||||
workbenchList.value = [];
|
||||
common_vendor.index.showToast({ title: "获取工作台数据失败", icon: "none" });
|
||||
} finally {
|
||||
@@ -503,11 +520,19 @@ const _sfc_main = {
|
||||
};
|
||||
})
|
||||
} : {}, {
|
||||
l: !isApprovalRole.value
|
||||
}, !isApprovalRole.value ? common_vendor.e({
|
||||
m: checkPlanData.value.length === 0
|
||||
l: showCheckPlanSection.value
|
||||
}, showCheckPlanSection.value ? common_vendor.e({
|
||||
m: common_vendor.f(planTabs, (tab, index, i0) => {
|
||||
return {
|
||||
a: common_vendor.t(tab.label),
|
||||
b: activePlanTab.value === index ? 1 : "",
|
||||
c: tab.value,
|
||||
d: common_vendor.o(($event) => switchPlanTab(index), tab.value)
|
||||
};
|
||||
}),
|
||||
n: checkPlanData.value.length === 0
|
||||
}, checkPlanData.value.length === 0 ? {} : {}, {
|
||||
n: common_vendor.f(checkPlanData.value, (item, k0, i0) => {
|
||||
o: common_vendor.f(checkPlanData.value, (item, k0, i0) => {
|
||||
return {
|
||||
a: common_vendor.t(item.name),
|
||||
b: "1cf27b2a-2-" + i0,
|
||||
@@ -535,13 +560,13 @@ const _sfc_main = {
|
||||
t: item.id
|
||||
};
|
||||
}),
|
||||
o: hasMoreCheckPlans.value
|
||||
p: hasMoreCheckPlans.value
|
||||
}, hasMoreCheckPlans.value ? {
|
||||
p: common_vendor.o(loadMoreCheckPlans)
|
||||
q: common_vendor.o(loadMoreCheckPlans)
|
||||
} : {}) : {}, {
|
||||
q: !isApprovalRole.value
|
||||
r: !isApprovalRole.value
|
||||
}, !isApprovalRole.value ? common_vendor.e({
|
||||
r: common_vendor.f(dangerTabs.value, (tab, index, i0) => {
|
||||
s: common_vendor.f(dangerTabs.value, (tab, index, i0) => {
|
||||
return {
|
||||
a: common_vendor.t(tab.label),
|
||||
b: activeDangerTab.value === index ? 1 : "",
|
||||
@@ -549,9 +574,9 @@ const _sfc_main = {
|
||||
d: common_vendor.o(($event) => switchDangerTab(index), index)
|
||||
};
|
||||
}),
|
||||
s: hiddenDangerData.value.length === 0 && !hiddenDangerLoading.value
|
||||
t: hiddenDangerData.value.length === 0 && !hiddenDangerLoading.value
|
||||
}, hiddenDangerData.value.length === 0 && !hiddenDangerLoading.value ? {} : {}, {
|
||||
t: common_vendor.f(hiddenDangerData.value, (item, index, i0) => {
|
||||
v: common_vendor.f(hiddenDangerData.value, (item, index, i0) => {
|
||||
return common_vendor.e({
|
||||
a: common_vendor.t(item.title),
|
||||
b: common_vendor.t(item.levelName),
|
||||
@@ -575,8 +600,8 @@ const _sfc_main = {
|
||||
}, item.statusName === "待验收" && item.canEdit ? {
|
||||
p: common_vendor.o(($event) => editRectification(item), item.hazardId)
|
||||
} : {}, {
|
||||
q: common_vendor.unref(utils_hazardNav.canShowAcceptanceButton)(item, currentRoleKey.value)
|
||||
}, common_vendor.unref(utils_hazardNav.canShowAcceptanceButton)(item, currentRoleKey.value) ? {
|
||||
q: common_vendor.unref(utils_hazardNav.canShowAcceptanceButton)(item)
|
||||
}, common_vendor.unref(utils_hazardNav.canShowAcceptanceButton)(item) ? {
|
||||
r: common_vendor.o(($event) => goAcceptance(item), item.hazardId)
|
||||
} : {}, {
|
||||
s: item.statusName === "待交办"
|
||||
@@ -594,15 +619,15 @@ const _sfc_main = {
|
||||
z: item.hazardId
|
||||
});
|
||||
}),
|
||||
v: hiddenDangerData.value.length > 0
|
||||
w: hiddenDangerData.value.length > 0
|
||||
}, hiddenDangerData.value.length > 0 ? {
|
||||
w: common_vendor.p({
|
||||
x: common_vendor.p({
|
||||
status: hiddenDangerLoadStatus.value
|
||||
})
|
||||
} : {}) : {}, {
|
||||
x: isApprovalRole.value
|
||||
y: isApprovalRole.value
|
||||
}, isApprovalRole.value ? common_vendor.e({
|
||||
y: common_vendor.f(workbenchTabs, (tab, index, i0) => {
|
||||
z: common_vendor.f(workbenchTabs, (tab, index, i0) => {
|
||||
return {
|
||||
a: common_vendor.t(tab.label),
|
||||
b: activeWorkbenchTab.value === index ? 1 : "",
|
||||
@@ -610,10 +635,10 @@ const _sfc_main = {
|
||||
d: common_vendor.o(($event) => switchWorkbenchTab(index), tab.value)
|
||||
};
|
||||
}),
|
||||
z: workbenchLoading.value
|
||||
A: workbenchLoading.value
|
||||
}, workbenchLoading.value ? {} : workbenchList.value.length === 0 ? {} : {}, {
|
||||
A: workbenchList.value.length === 0,
|
||||
B: common_vendor.f(workbenchList.value, (item, k0, i0) => {
|
||||
B: workbenchList.value.length === 0,
|
||||
C: common_vendor.f(workbenchList.value, (item, k0, i0) => {
|
||||
return common_vendor.e({
|
||||
a: common_vendor.t(item.title),
|
||||
b: common_vendor.t(item.levelName),
|
||||
@@ -631,9 +656,9 @@ const _sfc_main = {
|
||||
l: getWorkbenchItemKey(item)
|
||||
});
|
||||
}),
|
||||
C: activeWorkbenchTab.value === 0
|
||||
D: activeWorkbenchTab.value === 0
|
||||
}) : {}, {
|
||||
D: common_vendor.gei(_ctx, "")
|
||||
E: common_vendor.gei(_ctx, "")
|
||||
});
|
||||
};
|
||||
}
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -289,7 +289,8 @@
|
||||
gap: 42rpx;
|
||||
margin-left: 10rpx;
|
||||
}
|
||||
.workbench-tab-list.data-v-1cf27b2a {
|
||||
.workbench-tab-list.data-v-1cf27b2a,
|
||||
.plan-tab-list.data-v-1cf27b2a {
|
||||
margin-bottom: 20rpx;
|
||||
}
|
||||
.danger-tab-item.data-v-1cf27b2a {
|
||||
|
||||
@@ -2,19 +2,68 @@
|
||||
const common_vendor = require("../../common/vendor.js");
|
||||
const common_assets = require("../../common/assets.js");
|
||||
const request_api = require("../../request/api.js");
|
||||
if (!Array) {
|
||||
const _easycom_u_icon2 = common_vendor.resolveComponent("u-icon");
|
||||
_easycom_u_icon2();
|
||||
}
|
||||
const _easycom_u_icon = () => "../../uni_modules/uview-plus/components/u-icon/u-icon.js";
|
||||
if (!Math) {
|
||||
_easycom_u_icon();
|
||||
}
|
||||
const _sfc_main = {
|
||||
__name: "login",
|
||||
setup(__props) {
|
||||
const statusBarHeight = common_vendor.index.getSystemInfoSync().statusBarHeight || 0;
|
||||
const SUPERVISION_MINI_PROGRAM = {
|
||||
appId: "wxe3533791db8a8734",
|
||||
path: "pages/index/index",
|
||||
// develop=开发版 trial=体验版 release=正式版
|
||||
envVersion: "release"
|
||||
};
|
||||
const roleList = [
|
||||
{ id: "enterprise", name: "企业", icon: "home-fill" },
|
||||
{ id: "personal", name: "个人", icon: "account-fill" },
|
||||
{ id: "supervision", name: "督导组", icon: "man-add-fill" },
|
||||
{ id: "government", name: "政务", icon: "order" }
|
||||
// { id: 'family', name: '家庭', icon: 'home' }
|
||||
];
|
||||
const selectedRole = common_vendor.ref("enterprise");
|
||||
const username = common_vendor.ref("");
|
||||
const password = common_vendor.ref("");
|
||||
const showPassword = common_vendor.ref(true);
|
||||
const selectRole = (roleId) => {
|
||||
if (roleId === "supervision") {
|
||||
navigateToSupervisionMiniProgram();
|
||||
return;
|
||||
}
|
||||
selectedRole.value = roleId;
|
||||
};
|
||||
const navigateToSupervisionMiniProgram = () => {
|
||||
common_vendor.index.navigateToMiniProgram({
|
||||
appId: SUPERVISION_MINI_PROGRAM.appId,
|
||||
path: SUPERVISION_MINI_PROGRAM.path,
|
||||
extraData: {
|
||||
from: "threeonecheck",
|
||||
role: "supervision"
|
||||
},
|
||||
envVersion: SUPERVISION_MINI_PROGRAM.envVersion,
|
||||
success() {
|
||||
common_vendor.index.__f__("log", "at pages/login/login.vue:103", "跳转督导组小程序成功");
|
||||
},
|
||||
fail(err) {
|
||||
common_vendor.index.__f__("error", "at pages/login/login.vue:106", "跳转督导组小程序失败:", err);
|
||||
common_vendor.index.showModal({
|
||||
title: "跳转失败",
|
||||
content: "请确认两个小程序已关联,且目标小程序已添加您为开发者。开发阶段可在微信开发者工具中测试。",
|
||||
showCancel: false
|
||||
});
|
||||
}
|
||||
});
|
||||
};
|
||||
const changePassword = () => {
|
||||
showPassword.value = !showPassword.value;
|
||||
};
|
||||
const handleLogin = async () => {
|
||||
common_vendor.index.__f__("log", "at pages/login/login.vue:72", "点击登录按钮");
|
||||
common_vendor.index.__f__("log", "at pages/login/login.vue:73", "用户名:", username.value);
|
||||
common_vendor.index.__f__("log", "at pages/login/login.vue:74", "密码:", password.value);
|
||||
if (!username.value) {
|
||||
common_vendor.index.showToast({
|
||||
icon: "none",
|
||||
@@ -30,12 +79,10 @@ const _sfc_main = {
|
||||
return;
|
||||
}
|
||||
try {
|
||||
common_vendor.index.__f__("log", "at pages/login/login.vue:95", "开始调用登录接口...");
|
||||
const res = await request_api.login({
|
||||
username: username.value,
|
||||
password: password.value
|
||||
});
|
||||
common_vendor.index.__f__("log", "at pages/login/login.vue:102", "登录接口返回:", res);
|
||||
if (res.code === 0) {
|
||||
if (res.data.token) {
|
||||
common_vendor.index.setStorageSync("token", res.data.token);
|
||||
@@ -50,6 +97,7 @@ const _sfc_main = {
|
||||
isDept: res.data.isDept
|
||||
};
|
||||
common_vendor.index.setStorageSync("userInfo", JSON.stringify(userInfo));
|
||||
common_vendor.index.setStorageSync("loginRole", selectedRole.value);
|
||||
common_vendor.index.showToast({
|
||||
title: "登录成功",
|
||||
icon: "success"
|
||||
@@ -66,7 +114,7 @@ const _sfc_main = {
|
||||
});
|
||||
}
|
||||
} catch (error) {
|
||||
common_vendor.index.__f__("error", "at pages/login/login.vue:138", "登录失败:", error);
|
||||
common_vendor.index.__f__("error", "at pages/login/login.vue:185", "登录失败:", error);
|
||||
common_vendor.index.showToast({
|
||||
title: "网络请求失败",
|
||||
icon: "none"
|
||||
@@ -75,18 +123,33 @@ const _sfc_main = {
|
||||
};
|
||||
return (_ctx, _cache) => {
|
||||
return {
|
||||
a: common_assets._imports_0$6,
|
||||
b: common_assets._imports_0$7,
|
||||
c: username.value,
|
||||
d: common_vendor.o(($event) => username.value = $event.detail.value),
|
||||
e: common_assets._imports_1$4,
|
||||
f: showPassword.value,
|
||||
g: password.value,
|
||||
h: common_vendor.o(($event) => password.value = $event.detail.value),
|
||||
i: showPassword.value ? "/static/index/cl.png" : "/static/index/op.png",
|
||||
j: common_vendor.o(changePassword),
|
||||
k: common_vendor.o(handleLogin),
|
||||
l: common_vendor.gei(_ctx, "")
|
||||
a: common_vendor.unref(statusBarHeight) + "px",
|
||||
b: common_assets._imports_0$6,
|
||||
c: common_vendor.f(roleList, (item, k0, i0) => {
|
||||
return {
|
||||
a: "e4e4508d-0-" + i0,
|
||||
b: common_vendor.p({
|
||||
name: item.icon,
|
||||
size: 22,
|
||||
color: selectedRole.value === item.id ? "#ffffff" : "#b0b8c8"
|
||||
}),
|
||||
c: common_vendor.t(item.name),
|
||||
d: item.id,
|
||||
e: selectedRole.value === item.id ? 1 : "",
|
||||
f: common_vendor.o(($event) => selectRole(item.id), item.id)
|
||||
};
|
||||
}),
|
||||
d: common_assets._imports_0$7,
|
||||
e: username.value,
|
||||
f: common_vendor.o(($event) => username.value = $event.detail.value),
|
||||
g: common_assets._imports_1$4,
|
||||
h: showPassword.value,
|
||||
i: password.value,
|
||||
j: common_vendor.o(($event) => password.value = $event.detail.value),
|
||||
k: showPassword.value ? "/static/index/cl.png" : "/static/index/op.png",
|
||||
l: common_vendor.o(changePassword),
|
||||
m: common_vendor.o(handleLogin),
|
||||
n: common_vendor.gei(_ctx, "")
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
{
|
||||
"navigationBarTitleText": "登录页面",
|
||||
"navigationStyle": "custom",
|
||||
"usingComponents": {}
|
||||
"usingComponents": {
|
||||
"u-icon": "../../uni_modules/uview-plus/components/u-icon/u-icon"
|
||||
}
|
||||
}
|
||||
@@ -1 +1 @@
|
||||
<view class="{{['content', 'data-v-e4e4508d', virtualHostClass]}}" style="{{virtualHostStyle}}" hidden="{{virtualHostHidden || false}}" id="{{l}}"><view class="header data-v-e4e4508d"><image src="{{a}}" class="bg-image data-v-e4e4508d"></image><view class="padding login data-v-e4e4508d"><view class="text-xl text-black text-bold data-v-e4e4508d">账号登录</view><view class="padding-top data-v-e4e4508d">欢迎登录湘西州“三个一”安全管理平台</view></view></view><view class="list data-v-e4e4508d"><view class="list-call data-v-e4e4508d"><image class="img data-v-e4e4508d" src="{{b}}"></image><input class="sl-input data-v-e4e4508d" type="text" placeholder="请输入用户名" value="{{c}}" bindinput="{{d}}"/></view><view class="list-call data-v-e4e4508d"><image class="img data-v-e4e4508d" src="{{e}}"></image><input class="sl-input data-v-e4e4508d" type="text" maxlength="32" placeholder="请输入密码" password="{{f}}" value="{{g}}" bindinput="{{h}}"/><image class="eye-img data-v-e4e4508d" src="{{i}}" bindtap="{{j}}"></image></view></view><view class="padding-lr data-v-e4e4508d"><button class="button-login data-v-e4e4508d" hover-class="button-hover" bindtap="{{k}}"> 登录 </button></view></view>
|
||||
<view class="{{['content', 'data-v-e4e4508d', virtualHostClass]}}" style="{{virtualHostStyle}}" hidden="{{virtualHostHidden || false}}" id="{{n}}"><view class="status-bar data-v-e4e4508d" style="{{'height:' + a}}"></view><view class="brand-section data-v-e4e4508d"><view class="brand-logo data-v-e4e4508d"><image class="brand-logo-image data-v-e4e4508d" src="{{b}}" mode="aspectFit"></image></view><view class="brand-title data-v-e4e4508d">湘西州三个一安全管理平台</view><view class="brand-subtitle data-v-e4e4508d">隐患早发现、风险早处置,守护安全生产</view></view><view class="role-card data-v-e4e4508d"><view class="role-card-title data-v-e4e4508d">选择角色</view><view class="role-grid data-v-e4e4508d"><view wx:for="{{c}}" wx:for-item="item" wx:key="d" class="{{['role-item', 'data-v-e4e4508d', item.e && 'role-item--active']}}" bindtap="{{item.f}}"><view class="role-icon-wrap data-v-e4e4508d"><u-icon wx:if="{{item.b}}" class="data-v-e4e4508d" virtualHostClass="data-v-e4e4508d" u-i="{{item.a}}" bind:__l="__l" u-p="{{item.b}}"></u-icon></view><text class="role-name data-v-e4e4508d">{{item.c}}</text></view></view></view><view class="login-card data-v-e4e4508d"><view class="list data-v-e4e4508d"><view class="list-call data-v-e4e4508d"><image class="img data-v-e4e4508d" src="{{d}}"></image><input class="sl-input data-v-e4e4508d" type="text" placeholder="请输入用户名" value="{{e}}" bindinput="{{f}}"/></view><view class="list-call data-v-e4e4508d"><image class="img data-v-e4e4508d" src="{{g}}"></image><input class="sl-input data-v-e4e4508d" type="text" maxlength="32" placeholder="请输入密码" password="{{h}}" value="{{i}}" bindinput="{{j}}"/><image class="eye-img data-v-e4e4508d" src="{{k}}" bindtap="{{l}}"></image></view></view></view><view class="padding-lr data-v-e4e4508d"><button class="button-login data-v-e4e4508d" hover-class="button-hover" bindtap="{{m}}"> 登录 </button></view></view>
|
||||
193
unpackage/dist/dev/mp-weixin/pages/login/login.wxss
vendored
193
unpackage/dist/dev/mp-weixin/pages/login/login.wxss
vendored
@@ -25,38 +25,109 @@
|
||||
/* 透明度 */
|
||||
/* 文章场景相关 */
|
||||
page.data-v-e4e4508d {
|
||||
background-color: #FFFFFF;
|
||||
background: linear-gradient(180deg, #eef4ff 0%, #f8fbff 45%, #ffffff 100%);
|
||||
}
|
||||
.content.data-v-e4e4508d {
|
||||
min-height: 100vh;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
background: linear-gradient(180deg, #eef4ff 0%, #f8fbff 45%, #ffffff 100%);
|
||||
padding-bottom: 60rpx;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
.status-bar.data-v-e4e4508d {
|
||||
width: 100%;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
.brand-section.data-v-e4e4508d {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
padding: 120rpx 48rpx 32rpx;
|
||||
}
|
||||
.brand-logo.data-v-e4e4508d {
|
||||
margin-bottom: 28rpx;
|
||||
}
|
||||
.brand-logo-image.data-v-e4e4508d {
|
||||
width: 130rpx;
|
||||
height: 130rpx;
|
||||
display: block;
|
||||
}
|
||||
.brand-title.data-v-e4e4508d {
|
||||
font-size: 40rpx;
|
||||
font-weight: 700;
|
||||
color: #1a1a2e;
|
||||
text-align: center;
|
||||
line-height: 1.4;
|
||||
}
|
||||
.brand-subtitle.data-v-e4e4508d {
|
||||
margin-top: 16rpx;
|
||||
font-size: 26rpx;
|
||||
color: #8a94a6;
|
||||
text-align: center;
|
||||
line-height: 1.5;
|
||||
}
|
||||
.role-card.data-v-e4e4508d {
|
||||
margin: 0 40rpx 16rpx;
|
||||
padding: 32rpx 28rpx 28rpx;
|
||||
background: #ffffff;
|
||||
border-radius: 24rpx;
|
||||
box-shadow: 0 8rpx 32rpx rgba(47, 108, 242, 0.08);
|
||||
}
|
||||
.role-card-title.data-v-e4e4508d {
|
||||
font-size: 30rpx;
|
||||
font-weight: 600;
|
||||
color: #1a1a2e;
|
||||
margin-bottom: 24rpx;
|
||||
}
|
||||
.role-grid.data-v-e4e4508d {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: space-between;
|
||||
}
|
||||
.role-item.data-v-e4e4508d {
|
||||
width: 22%;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
margin-bottom: 8rpx;
|
||||
}
|
||||
.role-icon-wrap.data-v-e4e4508d {
|
||||
width: 88rpx;
|
||||
height: 88rpx;
|
||||
border-radius: 20rpx;
|
||||
background: #f5f7fb;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
background-color: #FFFFFF;
|
||||
transition: all 0.2s ease;
|
||||
}
|
||||
.header.data-v-e4e4508d {
|
||||
width: 100%;
|
||||
position: relative;
|
||||
margin-bottom: 0;
|
||||
.role-item--active .role-icon-wrap.data-v-e4e4508d {
|
||||
background: linear-gradient(145deg, #4a8af7 0%, #2f6cf2 100%);
|
||||
box-shadow: 0 8rpx 20rpx rgba(47, 108, 242, 0.3);
|
||||
}
|
||||
.header .bg-image.data-v-e4e4508d {
|
||||
width: 100%;
|
||||
vertical-align: bottom;
|
||||
.role-name.data-v-e4e4508d {
|
||||
margin-top: 12rpx;
|
||||
font-size: 24rpx;
|
||||
color: #8a94a6;
|
||||
line-height: 1.2;
|
||||
text-align: center;
|
||||
}
|
||||
.login.data-v-e4e4508d {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
color: #666666;
|
||||
font-size: 28rpx;
|
||||
.role-item--active .role-name.data-v-e4e4508d {
|
||||
color: #2f6cf2;
|
||||
font-weight: 600;
|
||||
}
|
||||
.login-card.data-v-e4e4508d {
|
||||
margin: 16rpx 40rpx 0;
|
||||
padding: 32rpx 28rpx;
|
||||
background: #ffffff;
|
||||
border-radius: 24rpx;
|
||||
box-shadow: 0 8rpx 32rpx rgba(47, 108, 242, 0.08);
|
||||
}
|
||||
.list.data-v-e4e4508d {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
padding-top: 50rpx;
|
||||
padding-left: 70rpx;
|
||||
padding-right: 70rpx;
|
||||
background-color: #FFFFFF;
|
||||
margin-top: -2rpx;
|
||||
/* 消除可能的间隙 */
|
||||
background-color: transparent;
|
||||
}
|
||||
.list .list-call.data-v-e4e4508d {
|
||||
display: flex;
|
||||
@@ -68,9 +139,12 @@ page.data-v-e4e4508d {
|
||||
background: #F5F7FB;
|
||||
border-radius: 16rpx;
|
||||
border: 2rpx solid #F5F7FB;
|
||||
margin-top: 30rpx;
|
||||
margin-top: 24rpx;
|
||||
padding: 0 30rpx;
|
||||
}
|
||||
.list .list-call.data-v-e4e4508d:first-child {
|
||||
margin-top: 0;
|
||||
}
|
||||
.list .list-call .img.data-v-e4e4508d {
|
||||
width: 30rpx;
|
||||
height: 36rpx;
|
||||
@@ -85,28 +159,9 @@ page.data-v-e4e4508d {
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
}
|
||||
.agreement.data-v-e4e4508d {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
font-size: 30rpx;
|
||||
margin-top: 30rpx;
|
||||
color: #3D83F6;
|
||||
text-align: center;
|
||||
height: 40rpx;
|
||||
line-height: 40rpx;
|
||||
}
|
||||
.agreement .link.data-v-e4e4508d {
|
||||
font-size: 30rpx;
|
||||
color: #3D83F6;
|
||||
}
|
||||
.agreement .link.data-v-e4e4508d:active {
|
||||
opacity: 0.8;
|
||||
}
|
||||
.padding-lr.data-v-e4e4508d {
|
||||
padding-left: 70rpx;
|
||||
padding-right: 70rpx;
|
||||
padding-left: 40rpx;
|
||||
padding-right: 40rpx;
|
||||
}
|
||||
.button-login.data-v-e4e4508d {
|
||||
color: #FFFFFF;
|
||||
@@ -119,64 +174,12 @@ page.data-v-e4e4508d {
|
||||
text-align: center;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
margin-top: 130rpx;
|
||||
margin-top: 48rpx;
|
||||
border: none;
|
||||
}
|
||||
.button-login.data-v-e4e4508d::after {
|
||||
border: none;
|
||||
}
|
||||
.button-report.data-v-e4e4508d {
|
||||
color: #FFFFFF;
|
||||
font-size: 34rpx;
|
||||
width: 100%;
|
||||
height: 100rpx;
|
||||
background: linear-gradient(90deg, #FF7878 0%, #F2505B 100%);
|
||||
border-radius: 50rpx;
|
||||
line-height: 100rpx;
|
||||
text-align: center;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
.margin-top.data-v-e4e4508d {
|
||||
margin-top: 30rpx;
|
||||
}
|
||||
.button-hover.data-v-e4e4508d {
|
||||
opacity: 0.8;
|
||||
}
|
||||
.text-blue.data-v-e4e4508d {
|
||||
color: #3D83F6;
|
||||
font-size: 28rpx;
|
||||
}
|
||||
.icon-image.data-v-e4e4508d {
|
||||
width: 36rpx;
|
||||
height: 36rpx;
|
||||
margin-right: 8rpx;
|
||||
}
|
||||
.text-xl.data-v-e4e4508d {
|
||||
font-size: 36rpx;
|
||||
}
|
||||
.text-black.data-v-e4e4508d {
|
||||
color: #000000;
|
||||
}
|
||||
.text-bold.data-v-e4e4508d {
|
||||
font-weight: bold;
|
||||
}
|
||||
.padding.data-v-e4e4508d {
|
||||
padding: 30rpx;
|
||||
}
|
||||
.padding-top.data-v-e4e4508d {
|
||||
padding-top: 15rpx;
|
||||
}
|
||||
.protocol-box.data-v-e4e4508d {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
margin-top: 40rpx;
|
||||
}
|
||||
.protocol-box .protocol-link.data-v-e4e4508d {
|
||||
font-size: 28rpx;
|
||||
color: #3D83F6;
|
||||
text-decoration: underline;
|
||||
}
|
||||
BIN
unpackage/dist/dev/mp-weixin/static/logo1.png
vendored
Normal file
BIN
unpackage/dist/dev/mp-weixin/static/logo1.png
vendored
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 138 KiB |
@@ -154,11 +154,8 @@ function buildWriteoffHazardFromOptions(options) {
|
||||
};
|
||||
}
|
||||
const isTruthyFlag = (value) => value === true || value === 1 || value === "1";
|
||||
function canShowAcceptanceButton(item, roleKey) {
|
||||
const canAcceptance = roleKey === "admin" || roleKey === "manage";
|
||||
const nodeType = item == null ? void 0 : item.nodeType;
|
||||
const canAcceptByNodeType = nodeType == null || nodeType === 1 || nodeType === "1" || nodeType === 2 || nodeType === "2" || nodeType === 3 || nodeType === "3";
|
||||
return (item == null ? void 0 : item.statusName) === "待验收" && canAcceptance && canAcceptByNodeType;
|
||||
function canShowAcceptanceButton(item) {
|
||||
return isTruthyFlag(item == null ? void 0 : item.verifyFlag);
|
||||
}
|
||||
function canShowWriteoffApplyButton(item) {
|
||||
return (item == null ? void 0 : item.statusName) === "待销号" && isTruthyFlag(item == null ? void 0 : item.applyFlag);
|
||||
|
||||
19
unpackage/dist/dev/mp-weixin/utils/userInfo.js
vendored
19
unpackage/dist/dev/mp-weixin/utils/userInfo.js
vendored
@@ -41,6 +41,24 @@ function resolveUserIdentityRoleKey(userInfo) {
|
||||
const identity = normalizeUserIdentity(userInfo.userIdentity);
|
||||
return normalizeRoleKey(identity == null ? void 0 : identity.roleKey);
|
||||
}
|
||||
function resolveOrganizationEntityType(userInfo) {
|
||||
if (!userInfo)
|
||||
return null;
|
||||
const identity = normalizeUserIdentity(userInfo.userIdentity);
|
||||
const currentIdentity = getCurrentIdentityFromStorage();
|
||||
const merged = identity || currentIdentity;
|
||||
if ((merged == null ? void 0 : merged.organizationEntityType) == null || (merged == null ? void 0 : merged.organizationEntityType) === "")
|
||||
return null;
|
||||
const entityType = Number(merged.organizationEntityType);
|
||||
return Number.isNaN(entityType) ? null : entityType;
|
||||
}
|
||||
const MANAGER_ROLE_KEYS = ["admin", "manage"];
|
||||
function isGovernmentEntityAdmin(userInfo) {
|
||||
const entityType = resolveOrganizationEntityType(userInfo);
|
||||
if (entityType !== 0 && entityType !== 1)
|
||||
return false;
|
||||
return MANAGER_ROLE_KEYS.includes(resolveUserIdentityRoleKey(userInfo));
|
||||
}
|
||||
function resolveUserRoleKey(userInfo) {
|
||||
if (!userInfo)
|
||||
return "";
|
||||
@@ -141,6 +159,7 @@ function applyStoredUserInfo(target, stored) {
|
||||
exports.applyProfileToUserInfo = applyProfileToUserInfo;
|
||||
exports.applyStoredUserInfo = applyStoredUserInfo;
|
||||
exports.getCurrentIdentityFromStorage = getCurrentIdentityFromStorage;
|
||||
exports.isGovernmentEntityAdmin = isGovernmentEntityAdmin;
|
||||
exports.resolveIdentityName = resolveIdentityName;
|
||||
exports.resolveUserIdentityRoleKey = resolveUserIdentityRoleKey;
|
||||
exports.saveUserInfoToStorage = saveUserInfoToStorage;
|
||||
|
||||
Reference in New Issue
Block a user