Files
kintone-attendance-system/src/学年別保育計画/main.js
2025-02-17 20:45:54 +08:00

18 lines
547 B
JavaScript

(function () {
"use strict";
kintone.events.on("app.record.detail.process.proceed", (event) => {
event.record[getUpdateFieldByNextFlow(event.nextStatus.value)].value = kintone.getLoginUser().name;
return event;
});
const statusFieldMap = {
'指導教諭確認中': '担任',
'主幹確認中': '指導',
'園長確認中': '主幹',
'完了': '園長'
}
function getUpdateFieldByNextFlow(nextStatus) {
return statusFieldMap[nextStatus];
}
})();