|
|
@@ -70,6 +70,18 @@ export default {
|
|
|
*/
|
|
|
async handleView(row) {
|
|
|
await this.loadOrderDetail(row.id)
|
|
|
+ // 先加载客户选项
|
|
|
+ await this.loadCustomerOptions()
|
|
|
+
|
|
|
+ this.orderForm.customerId = this.orderForm.customerId.toString()
|
|
|
+ // 如果当前订单有客户ID,确保该客户在选项列表中
|
|
|
+ if (this.orderForm.customerId && this.orderForm.customerCode) {
|
|
|
+ this.ensureCustomerInOptions(
|
|
|
+ this.orderForm.customerId,
|
|
|
+ this.orderForm.customerCode,
|
|
|
+ this.orderForm.customerName
|
|
|
+ )
|
|
|
+ }
|
|
|
this.showViewDialog(this.orderForm)
|
|
|
},
|
|
|
|