|
|
@@ -109,14 +109,25 @@ function onCardAction(action) {
|
|
|
const prefill = row.identityPayload || row
|
|
|
if (action.kind === 'event') {
|
|
|
eventStore.closeEvent()
|
|
|
- return entityDetailStore.show({ kind: 'event', id, family: row.identityFamily || row.family || eventStore.mode }, prefill, { side: side.value })
|
|
|
+ const opened = entityDetailStore.show({ kind: 'event', id, family: row.identityFamily || row.family || eventStore.mode }, prefill, { side: side.value })
|
|
|
+ refreshAfterOpen(opened)
|
|
|
+ return opened
|
|
|
}
|
|
|
if (action.kind === 'work-order') {
|
|
|
- return entityDetailStore.show({ kind: 'work-order', id }, prefill, { side: side.value })
|
|
|
+ const opened = entityDetailStore.show({ kind: 'work-order', id }, prefill, { side: side.value })
|
|
|
+ refreshAfterOpen(opened)
|
|
|
+ return opened
|
|
|
}
|
|
|
return false
|
|
|
}
|
|
|
|
|
|
+/** 详情打开后顺手重取当前事件:外部管理端刚改完状态时,列表不会停留在旧快照。 */
|
|
|
+function refreshAfterOpen(opened) {
|
|
|
+ Promise.resolve(opened)
|
|
|
+ .then((ok) => { if (ok) return eventStore.loadCurrentEvents() })
|
|
|
+ .catch(() => {})
|
|
|
+}
|
|
|
+
|
|
|
</script>
|
|
|
|
|
|
<style scoped>
|