9 changed files with 898 additions and 372 deletions
@ -0,0 +1,106 @@ |
|||
|
|||
<template> |
|||
<el-drawer |
|||
:size="size" |
|||
:title="title" |
|||
:visible="show" |
|||
:direction="direction" |
|||
@close="close" |
|||
> |
|||
<div class="tableDrawerContent"> |
|||
<umyTable |
|||
:tableBorder="true" |
|||
:tableData="tableData" |
|||
:tableColumns="tableColumns" |
|||
:selectionTable="selectionTable" |
|||
:requiredRules="false" |
|||
:setUTableHeight="260" |
|||
@sortChange="sortChange" |
|||
@handleSelectionChange="handleSelectionChange" |
|||
> |
|||
<template> |
|||
<slot></slot> |
|||
</template> |
|||
</umyTable> |
|||
</div> |
|||
</el-drawer> |
|||
</template> |
|||
<script> |
|||
import { LoadingMixins } from "@/mixins/LoadingMixins" |
|||
export default { |
|||
name: "tableDrawer", |
|||
mixins: [ |
|||
LoadingMixins, |
|||
], |
|||
watch:{ |
|||
isShow(n,o){ |
|||
this.show = n; |
|||
}, |
|||
}, |
|||
data () { |
|||
return { |
|||
show:false, |
|||
}; |
|||
}, |
|||
props:{ |
|||
size:{ |
|||
type: String, |
|||
default: "40%", |
|||
}, |
|||
isShow:{ |
|||
type: Boolean, |
|||
default: false, |
|||
}, |
|||
// 标题 |
|||
title: { |
|||
type: String, |
|||
default: "详情", |
|||
}, |
|||
// 开口方式 |
|||
direction: { |
|||
type: String, |
|||
default: "rtl", |
|||
}, |
|||
// 列表数据 |
|||
tableData: { |
|||
type: Array, |
|||
default: () => { |
|||
return []; |
|||
}, |
|||
}, |
|||
// 表头信息 |
|||
tableColumns: { |
|||
type: Array, |
|||
default: () => { |
|||
return []; |
|||
}, |
|||
}, |
|||
// 是否多选 |
|||
selectionTable: { |
|||
type: Boolean, |
|||
default: false, |
|||
}, |
|||
}, |
|||
mounted () { |
|||
}, |
|||
methods:{ |
|||
close(){ |
|||
this.show=false |
|||
this.$emit("setClose",this.show) |
|||
}, |
|||
//排序 |
|||
sortChange (data) { |
|||
this.$emit('sortChange', data) |
|||
}, |
|||
//点击selection框 |
|||
handleSelectionChange (val) { |
|||
this.$emit("handleSelectionChange", val) |
|||
}, |
|||
} |
|||
}; |
|||
</script> |
|||
<style lang="scss" scoped> |
|||
.tableDrawerContent{ |
|||
padding:0 20px |
|||
} |
|||
</style> |
@ -0,0 +1,94 @@ |
|||
<template> |
|||
<div class="page-box" v-loading="Loading.appMainLoading"> |
|||
<tablePagination |
|||
:currenButtonData="currenButtonData" |
|||
:tableData="tableData" |
|||
:tableLoading="Loading.tableLoading" |
|||
:tableColumns="tableColumns" |
|||
@rowDrop="rowDrop" |
|||
:totalCount="totalCount" |
|||
:multipleSelection="multipleSelection" |
|||
:MaxResultCount="PageListParams.MaxResultCount" |
|||
@topbutton="topbutton" |
|||
@inlineDialog="inlineDialog" |
|||
@sortChange="sortChange" |
|||
@alertoldSkipCount="alertoldSkipCount" |
|||
@alterResultCount="alterResultCount" |
|||
@handleSelectionChange="handleSelectionChange" |
|||
:currentPageProps="oldSkipCount" |
|||
:quicklySearchOption="quicklySearchOption" |
|||
@quicklySearchClick="quicklySearchClick" |
|||
@quicklySearchClear="quicklySearchClear" |
|||
:primarySearchOption="primarySearchOption" |
|||
@overallSearchFormClick="overallSearchFormClick" |
|||
:httpOverallSearchData="httpOverallSearchData" |
|||
> |
|||
</tablePagination> |
|||
<curren-Drawer |
|||
:title="tableColumns" |
|||
:DrawerLoading="Loading.DrawerLoading" |
|||
:drawer="displayDialog.detailsDialog" |
|||
:propsData="propsData" |
|||
:tabsDesTions="tabsDesTions" |
|||
:Butttondata="[]" |
|||
@drawerShut="(val) => (displayDialog.detailsDialog = val)" |
|||
@drawerbutton="drawerbutton" |
|||
@close-value="closeValue" |
|||
:currenButtonData="currenButtonData" |
|||
:tableColumns="detailsTableColumns" |
|||
:totalCount="totalCountDetails" |
|||
:MaxResultCount="MaxResultCountDetails" |
|||
@alterResultCountDetails="alterResultCountDetails" |
|||
@alertoldSkipCountDetails="alertoldSkipCountDetails" |
|||
></curren-Drawer> |
|||
</div> |
|||
</template> |
|||
<script> |
|||
import { materialRequestByType,processRequest,getDetailed } from "@/api/wms-api" |
|||
import { tableMixins } from "@/mixins/TableMixins" |
|||
import { LoadingMixins } from "@/mixins/LoadingMixins" |
|||
import { drawerMixins } from "@/mixins/drawerMixins" |
|||
import { TableHeaderMixins } from "@/mixins/TableHeaderMixins" |
|||
import { mixins } from "@/mixins/mixins" |
|||
import { requestData } from "@/utils/processButtonData" |
|||
import requestDataNames from "@/utils/processButtonData" |
|||
export default { |
|||
name: "InventoryBilling", |
|||
mixins: [ |
|||
tableMixins, |
|||
LoadingMixins, |
|||
drawerMixins, |
|||
TableHeaderMixins, |
|||
mixins, |
|||
], |
|||
computed: { |
|||
editDialog: { |
|||
get: function () { |
|||
return this.displayDialog.newDialog || this.displayDialog.editDialog; |
|||
}, |
|||
}, |
|||
}, |
|||
data () { |
|||
let _this = this; |
|||
return { |
|||
URL: 'basedata/erpLocation-item', |
|||
tableLoading: false, |
|||
handleMultipleSelection: [], |
|||
//常用按钮数据 |
|||
currenButtonData: [ |
|||
this.defaultExportBtn(),//导出 |
|||
// this.defaultImportBtn(),//导入 |
|||
this.defaultFieldSettingBtn(),//字段设置 |
|||
this.defaultFreshBtn(),//刷新 |
|||
this.defaultFilterBtn(),//筛选 |
|||
], |
|||
}; |
|||
}, |
|||
mounted () { |
|||
this.paging() |
|||
}, |
|||
}; |
|||
</script> |
|||
<style lang="scss" scoped> |
|||
@import "../../../styles/basicData.scss"; |
|||
</style> |
@ -0,0 +1,271 @@ |
|||
|
|||
<template> |
|||
<div class="page-box" v-loading="Loading.appMainLoading"> |
|||
<tablePagination |
|||
ref="tablePagination_Ref" |
|||
:currenButtonData="currenButtonData" |
|||
:tableData="tableData" |
|||
:tableLoading="Loading.tableLoading" |
|||
:tableColumns="tableColumns" |
|||
@rowDrop="rowDrop" |
|||
:totalCount="totalCount" |
|||
:multipleSelection="multipleSelection" |
|||
:MaxResultCount="PageListParams.MaxResultCount" |
|||
@topbutton="topbutton" |
|||
@inlineDialog="inlineDialog" |
|||
@sortChange="sortChange" |
|||
@alertoldSkipCount="alertoldSkipCount" |
|||
@alterResultCount="alterResultCount" |
|||
@handleSelectionChange="handleSelectionChange" |
|||
@buttonOperationClick="buttonOperationClick" |
|||
:currentPageProps="oldSkipCount" |
|||
:quicklySearchOption="quicklySearchOption" |
|||
@quicklySearchClick="quicklySearchClick" |
|||
@quicklySearchClear="quicklySearchClear" |
|||
:primarySearchOption="primarySearchOption" |
|||
@overallSearchFormClick="overallSearchFormClick" |
|||
:httpOverallSearchData="httpOverallSearchData" |
|||
> |
|||
<!-- <div slot="tableTopSlot"> |
|||
上方按钮插槽位置预留 |
|||
</div> |
|||
<div slot="searchPrimarySlot"> |
|||
普通初级搜索插槽位置预留 |
|||
</div> --> |
|||
<template> |
|||
<u-table-column |
|||
fixed="right" |
|||
label="查看" |
|||
align="center" |
|||
width="200" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<!-- 不使用el-button是因为固定左右时候,行高度会窜行 --> |
|||
<span class="controlBarButton" @click="showDrawer('parent',scope)">总成汇总</span> |
|||
<span class="controlBarButton" @click="showDrawer('son',scope)">子物料汇总</span> |
|||
</template> |
|||
</u-table-column> |
|||
<u-table-column |
|||
fixed="right" |
|||
label="操作" |
|||
align="center" |
|||
width="100" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<!-- todo:v-if参数确定 --> |
|||
<span class="controlBarButton" v-if="scope.row.status == 1" @click="operationHandel('close',scope)">关闭</span> |
|||
<span class="controlBarButton" v-if="scope.row.status == 2" @click="operationHandel('handle',scope)">执行</span> |
|||
</template> |
|||
</u-table-column> |
|||
</template> |
|||
</tablePagination> |
|||
<!-- 搜索按钮——窗体组件 --> |
|||
<searchPage |
|||
ref="searchTable" |
|||
:tableLoading="Loading.autoTableLoading" |
|||
:advancedFilter="advancedFilter()" |
|||
:filterPageListParams="filterPageListParams" |
|||
:formTitle="searchTitle" |
|||
:displayDialog="displayDialog.AddNewDialog" |
|||
:searchTableData="searchData" |
|||
:searchTableColumns="searchColumns" |
|||
:searchTotalCount="searchTotalCount" |
|||
:supplierItemPage="searchPageListParams" |
|||
@handleSelectionChange="prepareFormData" |
|||
@SizeChange="searchAlterResultCount($event, searchPageListParams)" |
|||
@CurrentChange="searchAlertoldSkipCount($event, searchPageListParams)" |
|||
@tableButtonClick="searchSubmit(arguments)" |
|||
></searchPage> |
|||
<!-- 总成弹窗 --> |
|||
<tableDrawer |
|||
:title="currentTitle" |
|||
:isShow="isShow_parent" |
|||
@setClose="closeDrawer('parent')" |
|||
:tableData="tableData_parent" |
|||
:tableColumns="tableColumns_parent" |
|||
> |
|||
<template> |
|||
<u-table-column |
|||
fixed="right" |
|||
label="操作" |
|||
align="center" |
|||
width="120" |
|||
> |
|||
<template slot-scope="scope"> |
|||
<!-- 不使用el-button是因为固定左右时候,行高度会窜行 --> |
|||
<span class="controlBarButton" @click="showDrawer('bom',scope)">查看bom</span> |
|||
</template> |
|||
</u-table-column> |
|||
</template> |
|||
</tableDrawer> |
|||
<!-- 子物料弹窗 --> |
|||
<tableDrawer |
|||
:title="currentTitle" |
|||
:isShow="isShow_son" |
|||
@setClose="closeDrawer('son')" |
|||
:tableData="tableData_son" |
|||
:tableColumns="tableColumns_son" |
|||
></tableDrawer> |
|||
<!-- bom弹窗 --> |
|||
<tableDrawer |
|||
:size="'30%'" |
|||
:title="currentTitle" |
|||
:isShow="isShow_bom" |
|||
@setClose="closeDrawer('bom')" |
|||
:tableData="tableData_bom" |
|||
:tableColumns="tableColumns_bom" |
|||
></tableDrawer> |
|||
</div> |
|||
</template> |
|||
<script> |
|||
import { tableMixins } from "@/mixins/TableMixins" |
|||
import { LoadingMixins } from "@/mixins/LoadingMixins" |
|||
import { TableHeaderMixins } from "@/mixins/TableHeaderMixins" |
|||
import { mixins } from "@/mixins/mixins" |
|||
import { filterSelectMixins } from '@/mixins/filter-Select' |
|||
import tableDrawer from "@/components/tableDrawer/tableDrawer.vue" |
|||
export default { |
|||
name: "IssuePlanZS", |
|||
mixins: [ |
|||
tableMixins, |
|||
LoadingMixins, |
|||
TableHeaderMixins, |
|||
mixins, |
|||
filterSelectMixins, |
|||
], |
|||
components:{ |
|||
tableDrawer |
|||
}, |
|||
data () { |
|||
return { |
|||
URL: 'basedata/item-basic', |
|||
//常用按钮数据 |
|||
currenButtonData: [ |
|||
this.defaultFieldSettingBtn(),//字段设置 |
|||
this.defaultFreshBtn(),//刷新 |
|||
this.defaultFilterBtn(),//筛选 |
|||
], |
|||
currentTitle:null, |
|||
//总成汇总弹窗显示 |
|||
isShow_parent:false, |
|||
// 总成汇总表头 |
|||
tableColumns_parent:[ |
|||
{ label: "总成号", prop: "number",width:'auto' }, |
|||
{ label: "数量", prop: "qty",width:'auto' }, |
|||
], |
|||
// 总成汇总数据 |
|||
tableData_parent:[], |
|||
//子物料汇总弹窗显示 |
|||
isShow_son:false, |
|||
// 子物料汇总表头 |
|||
tableColumns_son:[ |
|||
{ label: "son总成号", prop: "number",width:'auto' }, |
|||
{ label: "son数量", prop: "qty",width:'auto' }, |
|||
], |
|||
// 子物料汇总数据 |
|||
tableData_son:[], |
|||
// bom弹窗显示 |
|||
isShow_bom:false, |
|||
// bom汇总表头 |
|||
tableColumns_bom:[ |
|||
{ label: "bom总成号", prop: "number",width:'auto' }, |
|||
{ label: "bom数量", prop: "qty",width:'auto' }, |
|||
], |
|||
// bom汇总数据 |
|||
tableData_bom:[], |
|||
}; |
|||
}, |
|||
mounted () { |
|||
this.paging(); |
|||
}, |
|||
methods:{ |
|||
// 显示弹窗 |
|||
showDrawer(type,scope){ |
|||
console.log(type,scope) |
|||
// 总成汇总 |
|||
if(type == "parent"){ |
|||
// todo:获取接口 |
|||
this.currentTitle="parent" |
|||
this.tableData_parent = [ |
|||
{number:'number1',qty:1}, |
|||
{number:'number2',qty:2}, |
|||
] |
|||
this.isShow_parent = true |
|||
} |
|||
// 子零件汇总 |
|||
if(type == "son"){ |
|||
// todo:获取接口 |
|||
this.currentTitle="son" |
|||
this.tableData_son = [ |
|||
{number:'sonnumber1',qty:11}, |
|||
{number:'sonnumber2',qty:22}, |
|||
] |
|||
this.isShow_son = true |
|||
} |
|||
// 总成汇总-bom |
|||
if(type == "bom"){ |
|||
// todo:获取接口 |
|||
this.currentTitle="bom" |
|||
this.tableData_bom = [ |
|||
{number:'bomnumber1',qty:11}, |
|||
{number:'bomnumber2',qty:22}, |
|||
] |
|||
this.isShow_bom = true |
|||
} |
|||
}, |
|||
// 关闭弹窗 |
|||
closeDrawer(type){ |
|||
console.log(type) |
|||
// 总成汇总 |
|||
if(type == "parent"){ |
|||
this.isShow_parent = false |
|||
} |
|||
// 子零件汇总 |
|||
if(type == "son"){ |
|||
this.isShow_son = false |
|||
} |
|||
// 子零件汇总 |
|||
if(type == "bom"){ |
|||
this.isShow_bom = false |
|||
} |
|||
}, |
|||
// 操作列 |
|||
operationHandel(type,data){ |
|||
// 关闭 |
|||
if(type == "close"){ |
|||
this.$confirm('您确定要关闭吗?', '提示', { |
|||
confirmButtonText: '确定', |
|||
cancelButtonText: '取消', |
|||
type: 'warning' |
|||
}).then(() => { |
|||
|
|||
}).catch(() => { |
|||
|
|||
}); |
|||
} |
|||
// 执行 |
|||
if(type == "handle"){ |
|||
this.$confirm('您确定要执行吗?', '提示', { |
|||
confirmButtonText: '确定', |
|||
cancelButtonText: '取消', |
|||
type: 'warning' |
|||
}).then(() => { |
|||
|
|||
}).catch(() => { |
|||
|
|||
}); |
|||
} |
|||
console.log(type,data) |
|||
} |
|||
} |
|||
}; |
|||
</script> |
|||
<style lang="scss" scoped> |
|||
@import "../../../styles/basicData.scss"; |
|||
.controlBarButton{ |
|||
color:#409EFF; |
|||
cursor:pointer; |
|||
user-select: none; |
|||
margin:0 10px; |
|||
} |
|||
</style> |
Loading…
Reference in new issue