|
@@ -1079,12 +1079,12 @@ const {
|
|
|
visible = 0,
|
|
|
alreadyHasIndentCount = 0,
|
|
|
parentId = 0,
|
|
|
- dataForEdit = { vendor_name: '' } as any,
|
|
|
+ dataForEdit = [],
|
|
|
} = defineProps<{
|
|
|
visible: number
|
|
|
alreadyHasIndentCount?: number
|
|
|
parentId?: number | string
|
|
|
- dataForEdit?: object
|
|
|
+ dataForEdit?: any[]
|
|
|
}>()
|
|
|
const $mediaRegExp = inject('mediaRegExp') as RegExp
|
|
|
const prefix = 'order.indent_edit_info.'
|
|
@@ -1227,18 +1227,18 @@ const numberTableAddRow = function (index: number) {
|
|
|
forms.value[index].price.push('')
|
|
|
forms.value[index].days.push('')
|
|
|
}
|
|
|
-// 仅编辑报价信息时需要初始化
|
|
|
-const initData = function () {
|
|
|
+// 20250630.在编辑询价界面进来也要显示所有报价信息, 即除了新建报价时(询价为空), 其实时候都需要遍历数据展示已有报价.
|
|
|
+const initData = function (d: any, index: number) {
|
|
|
// 查询供应商候选列表, 不然下拉框无数据匹配, 下拉框界面上会显示成供应商的id
|
|
|
- queryVenderList(dataForEdit.vendor_name, 0)
|
|
|
+ queryVenderList(d.vendor_name || '', index)
|
|
|
|
|
|
- const temp = cloneDeep(dataForEdit)
|
|
|
+ const temp = cloneDeep(d)
|
|
|
|
|
|
productImageList.value.push([])
|
|
|
if (Array.isArray(temp.product_image) && temp.product_image.length) {
|
|
|
nextTick(() => {
|
|
|
productImageList.value.splice(
|
|
|
- 0,
|
|
|
+ index,
|
|
|
1,
|
|
|
temp.product_image.map((img: string) => {
|
|
|
return {
|
|
@@ -1317,7 +1317,10 @@ watch(
|
|
|
vendorList.value = []
|
|
|
|
|
|
if (visible > 1) {
|
|
|
- initData()
|
|
|
+ dataForEdit.forEach((i, index) => {
|
|
|
+ vendorList.value.push([])
|
|
|
+ initData(i, index)
|
|
|
+ })
|
|
|
} else if (visible > 0) {
|
|
|
addFormColumn()
|
|
|
}
|