✨ 打卡时间轴不再为接单节点提供编辑入口
接单节点的完成由运单的接单事实决定,不落打卡流水:补录或取消打卡都改不动它, 放出去只会造出一条与运单事实打架的流水(时间轴显示已打卡、运单却还没人接单)。 后端已拒绝该节点的补录与取消,前端同步隐藏「编辑」链接。 判据与后端一致(key=accept / name=接单),优先取过程配置里的节点、回退记录上的节点标识。
This commit is contained in:
@@ -2216,7 +2216,7 @@
|
|||||||
>
|
>
|
||||||
</template>
|
</template>
|
||||||
<el-link
|
<el-link
|
||||||
v-if="canEditWaybillPunchRecord"
|
v-if="canEditWaybillPunchRecord && !isAcceptPunchRecord(record)"
|
||||||
class="waybill-manage-page__punch-record-edit-link"
|
class="waybill-manage-page__punch-record-edit-link"
|
||||||
type="primary"
|
type="primary"
|
||||||
:underline="false"
|
:underline="false"
|
||||||
@@ -5846,6 +5846,16 @@ export default {
|
|||||||
null
|
null
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
|
// 接单节点没有打卡流水,它的完成由运单的接单事实决定:补录或取消打卡都改不动它,
|
||||||
|
// 放出去只会造出一条与运单事实打架的流水。判据与后端一致(key=accept / name=接单)。
|
||||||
|
isAcceptPunchRecord(record = {}) {
|
||||||
|
const node = this.findWaybillPunchEditNodeConfig(record);
|
||||||
|
const key = String(node?.key || record?.nodeCode || '')
|
||||||
|
.trim()
|
||||||
|
.toLowerCase();
|
||||||
|
const name = String(node?.name || record?.nodeName || '').trim();
|
||||||
|
return key === 'accept' || name === '接单';
|
||||||
|
},
|
||||||
openWaybillPunchRecordEdit(record = {}) {
|
openWaybillPunchRecordEdit(record = {}) {
|
||||||
if (!this.detailRow?.id || !record) return;
|
if (!this.detailRow?.id || !record) return;
|
||||||
this.waybillPunchEditRecord = { ...record };
|
this.waybillPunchEditRecord = { ...record };
|
||||||
|
|||||||
Reference in New Issue
Block a user