单独修改状态接口

This commit is contained in:
2025-07-19 10:49:29 +08:00
parent c2b6e54a09
commit 0ad3f3f3c8
6 changed files with 217 additions and 20 deletions

View File

@@ -191,7 +191,10 @@
append-to-body
@close="onDetailClosed"
>
<StockIoDetailPanel :stockIo="detailStockIo" />
<StockIoDetailPanel
:stockIo="detailStockIo"
@status-changed="onStatusChanged"
/>
</el-dialog>
</div>
</template>
@@ -390,6 +393,15 @@ export default {
},
onDetailClosed() {
this.getList();
},
onStatusChanged(updatedStockIo) {
// 更新主表中的对应记录状态
const index = this.stockIoList.findIndex(item => item.stockIoId === updatedStockIo.stockIoId);
if (index !== -1) {
this.$set(this.stockIoList, index, updatedStockIo);
}
// 刷新列表
this.getList();
}
}
};