Browse Source

要货计划

hella_online_20240829
wangyufei 4 months ago
parent
commit
96a0d495a5
  1. 38
      src/views/wms/purchasereceiptManage/supplierdeliver/purchasePlanMain/index.vue

38
src/views/wms/purchasereceiptManage/supplierdeliver/purchasePlanMain/index.vue

@ -7,7 +7,14 @@
<!-- 列表头部 --> <!-- 列表头部 -->
<TableHead :HeadButttondata="HeadButttondata" @button-base-click="buttonBaseClick" :routeName="routeName" <TableHead :HeadButttondata="HeadButttondata" @button-base-click="buttonBaseClick" :routeName="routeName"
@updataTableColumns="updataTableColumns" @searchFormClick="searchFormClick" @updataTableColumns="updataTableColumns" @searchFormClick="searchFormClick"
:allSchemas="PurchasePlanMain.allSchemas" :detailAllSchemas="PurchasePlanDetail.allSchemas"/> :allSchemas="PurchasePlanMain.allSchemas" :detailAllSchemas="PurchasePlanDetail.allSchemas">
<template #rightBtn>
<div style="display:flex;justify-content: center;align-items: center">
<span>计划数量包含0</span>
<el-switch v-model="isZero" style="margin:0 5px" @change="zeroChange"/>
</div>
</template>
</TableHead>
<!-- 列表 --> <!-- 列表 -->
<ContentWrap> <ContentWrap>
@ -281,6 +288,7 @@ const getSearchTableData = async (number,formField,searchField)=>{
} }
const { tableObject, tableMethods } = useTable({ const { tableObject, tableMethods } = useTable({
defaultParams:{isZero:1},
getListApi: PurchasePlanDetailApi.getPurchasePlanDetailPage // getListApi: PurchasePlanDetailApi.getPurchasePlanDetailPage //
}) })
@ -332,6 +340,7 @@ const getSearchTableData = async (number,formField,searchField)=>{
} else if (val=='mainOrderSelectionPub'){// } else if (val=='mainOrderSelectionPub'){//
handleSelectionPublish() handleSelectionPublish()
} else if (val == 'filtrate') { // } else if (val == 'filtrate') { //
console.log('筛选',tableObject)
} else { // } else { //
console.log('其他按钮', item) console.log('其他按钮', item)
} }
@ -510,7 +519,26 @@ const { wsCache } = useCache()
tableObject.loading = false tableObject.loading = false
} }
} }
const isZero = ref(false)
const zeroChange = ()=>{
// isZero.value
if(tableObject.params.isSearch){
tableObject.params.filters = tableObject.params.filters.filter(item=>item.column!='isZero')
tableObject.params.filters = [...tableObject.params.filters,{
action: "==",
column: "isZero",
value: isZero.value?0:1
}]
}else{
tableObject.params.isZero = isZero.value?0:1
}
getList()
console.log('tableObject',tableObject)
}
const searchList = (model)=>{ const searchList = (model)=>{
model.isZero = isZero.value?0:1
console.log('model',model)
selectionRows.value = [] selectionRows.value = []
setSearchParams(model) setSearchParams(model)
} }
@ -634,6 +662,7 @@ const handleSelectionPublish = async ()=>{
} }
const handleExportDetails = async () => { const handleExportDetails = async () => {
console.log('tableObject.params',tableObject.params)
try { try {
// //
await message.exportConfirm() await message.exportConfirm()
@ -807,9 +836,14 @@ const handleSelectionPublish = async ()=>{
// //
const searchFormClick = (searchData) => { const searchFormClick = (searchData) => {
searchData.filters = searchData.filters.filter(item=>item.column!='isZero')
tableObject.params = { tableObject.params = {
isSearch: true, isSearch: true,
filters: searchData.filters filters: [...searchData.filters,{
action: "==",
column: "isZero",
value: isZero.value?0:1
}]
} }
getList() // getList() //
} }

Loading…
Cancel
Save