|
@ -90,19 +90,18 @@ export const tableMixins = { |
|
|
this.displayDialog.detailsDialog = true; |
|
|
this.displayDialog.detailsDialog = true; |
|
|
let _url = this.detailURL ? this.detailURL : this.URL |
|
|
let _url = this.detailURL ? this.detailURL : this.URL |
|
|
getDetailed(val.id, _url).then(res => { |
|
|
getDetailed(val.id, _url).then(res => { |
|
|
if (res.details) { |
|
|
if (res.details) { |
|
|
// 前端分页处理
|
|
|
// 前端分页处理
|
|
|
this.tableDataDetails = JSON.parse(JSON.stringify(res)) |
|
|
this.tableDataDetails = JSON.parse(JSON.stringify(res)) |
|
|
let linshiTableDataDetails = JSON.parse(JSON.stringify(this.tableDataDetails)) |
|
|
let linshiTableDataDetails = JSON.parse(JSON.stringify(this.tableDataDetails)) |
|
|
this.totalCountDetails = res.details.length |
|
|
this.totalCountDetails = res.details.length |
|
|
// 删除除当前页面最大数以外数据
|
|
|
// 删除除当前页面最大数以外数据
|
|
|
linshiTableDataDetails.details.splice(this.MaxResultCountDetails,this.totalCountDetails); |
|
|
linshiTableDataDetails.details.splice(this.MaxResultCountDetails,this.totalCountDetails); |
|
|
this.propsData = linshiTableDataDetails |
|
|
this.propsData = linshiTableDataDetails |
|
|
} else { |
|
|
} else { |
|
|
this.propsData = res |
|
|
this.propsData = res |
|
|
} |
|
|
} |
|
|
console.log(105,this.propsData) |
|
|
this.inlineDialogCallback() |
|
|
this.inlineDialogCallback() |
|
|
|
|
|
}).catch(err => { |
|
|
}).catch(err => { |
|
|
this.Loading.DrawerLoading = false |
|
|
this.Loading.DrawerLoading = false |
|
|
}) |
|
|
}) |
|
@ -199,6 +198,59 @@ export const tableMixins = { |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
|
|
|
// 明细-获取物品信息【配置(configuration)】参数
|
|
|
|
|
|
// 此方法暂时仅仅支持1000条以内的数据,如果有需要1000以外,需要优化
|
|
|
|
|
|
getConfigByItemHandle_props() { |
|
|
|
|
|
let _data = { |
|
|
|
|
|
condition: {filters: []}, |
|
|
|
|
|
Sorting: "", |
|
|
|
|
|
SkipCount: 0, |
|
|
|
|
|
MaxResultCount: 1000 |
|
|
|
|
|
} |
|
|
|
|
|
this.propsData.details.forEach((item)=>{ |
|
|
|
|
|
let _filt = { |
|
|
|
|
|
logic: 'Or', |
|
|
|
|
|
column: "code", |
|
|
|
|
|
action: "==", |
|
|
|
|
|
value: item.itemCode |
|
|
|
|
|
} |
|
|
|
|
|
_data.condition.filters.push(_filt) |
|
|
|
|
|
}) |
|
|
|
|
|
getPageList(_data, 'basedata/item-basic').then(res => { |
|
|
|
|
|
console.log(items) |
|
|
|
|
|
this.propsData.details.forEach(item=>{ |
|
|
|
|
|
let _config = res.items.filters(base=>{ |
|
|
|
|
|
return base.code == item.itemCode |
|
|
|
|
|
}) |
|
|
|
|
|
console.log(225,_config) |
|
|
|
|
|
}) |
|
|
|
|
|
this.Loading.DrawerLoading = false |
|
|
|
|
|
}).catch(err => { |
|
|
|
|
|
this.Loading.DrawerLoading = false |
|
|
|
|
|
}) |
|
|
|
|
|
// if(!this.propsData.supplierCode){
|
|
|
|
|
|
// this.Loading.DrawerLoading = false
|
|
|
|
|
|
// return
|
|
|
|
|
|
// }
|
|
|
|
|
|
// if(this.tabsDesTions[i].prop == 'supplierName' || this.tabsDesTions[i].prop == "supplierAddress"){
|
|
|
|
|
|
// let _allSuCode = [this.propsData.supplierCode]
|
|
|
|
|
|
// this.Loading.DrawerLoading = true
|
|
|
|
|
|
// allSupplierByCodes(_allSuCode).then(res => {
|
|
|
|
|
|
// this.Loading.DrawerLoading = false
|
|
|
|
|
|
// if(res.length > 0){
|
|
|
|
|
|
// this.$set(this.propsData,"supplierName", res[0].name)
|
|
|
|
|
|
// this.$set(this.propsData,"supplierAddress", res[0].address)
|
|
|
|
|
|
// this.$set(this.propsData,"supplierShortName", res[0].shortName)
|
|
|
|
|
|
// }
|
|
|
|
|
|
// }).catch(err => {
|
|
|
|
|
|
// console.log(err)
|
|
|
|
|
|
// this.Loading.DrawerLoading = false
|
|
|
|
|
|
// })
|
|
|
|
|
|
// return
|
|
|
|
|
|
// }else{
|
|
|
|
|
|
// this.Loading.DrawerLoading = false
|
|
|
|
|
|
// }
|
|
|
|
|
|
}, |
|
|
// 主列表操作列按钮执行方法
|
|
|
// 主列表操作列按钮执行方法
|
|
|
/** |
|
|
/** |
|
|
* |
|
|
* |
|
@ -254,7 +306,12 @@ export const tableMixins = { |
|
|
}, |
|
|
}, |
|
|
// 点击抽屉,获取明细后全局通用操作
|
|
|
// 点击抽屉,获取明细后全局通用操作
|
|
|
inlineDialogCallback(){ |
|
|
inlineDialogCallback(){ |
|
|
this.Loading.DrawerLoading = false |
|
|
// 插入配置数据
|
|
|
|
|
|
if(this.showConfiguration){ |
|
|
|
|
|
// this.getConfigByItemHandle_props()
|
|
|
|
|
|
}else{ |
|
|
|
|
|
this.Loading.DrawerLoading = false |
|
|
|
|
|
} |
|
|
// this.getSupplierByCodesHandle_props()
|
|
|
// this.getSupplierByCodesHandle_props()
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|