add approve flow action

This commit is contained in:
2025-02-17 17:39:54 +08:00
parent a8f36062d7
commit b71b258569
12 changed files with 29 additions and 2 deletions

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@@ -2,6 +2,8 @@
"use strict";
const APP_ENV = env["0,1歳日誌出力用"];
addApproveFlowAction();
kintone.events.on("app.record.detail.show", (event) => {
const headerSpace = getHeaderSpace('', true);

View File

@@ -2,6 +2,8 @@
"use strict";
const APP_ENV = env["2歳以上日誌出力用"];
addApproveFlowAction();
kintone.events.on("app.record.detail.show", (event) => {
const headerSpace = getHeaderSpace('', true);

View File

@@ -48,9 +48,11 @@
.customized-record-header-space {
padding-top: 16px;
padding-left: 8px;
}
.customized-record-header-space > .btn-group-area{
padding-right: 0;
.customized-record-header-space > .btn-group-area {
padding: 0;
margin: 0;
}
.customized-header-space-wrapper.single-label-line {
margin-top: 33px;

View File

@@ -499,4 +499,21 @@ function groupingBySex(list) {
}
return [male, female];
}, [[], []]);
}
const statusFieldMap = {
'指導教諭確認中': '担任',
'主幹確認中': '指導',
'園長確認中': '主幹',
'完了': '園長'
}
function getUpdateFieldByNextFlow(nextStatus) {
return statusFieldMap[nextStatus];
}
function addApproveFlowAction() {
return kintone.events.on("app.record.detail.process.proceed", (event) => {
event.record[getUpdateFieldByNextFlow(event.nextStatus.value)].value = kintone.getLoginUser().name;
return event;
});
}

View File

@@ -2,6 +2,8 @@
"use strict";
const APP_ENV = env["個別配慮"];
addApproveFlowAction();
kintone.events.on("app.record.index.show", (event) => {
const headerSpace = getHeaderSpace('single-label-line');

View File

@@ -2,6 +2,8 @@
"use strict";
const APP_ENV = env["園児別出欠簿入力"];
addApproveFlowAction();
kintone.events.on("app.record.index.show", (event) => {
const headerSpace = getHeaderSpace('single-label-line');