Browse Source

计划外入库、、供应商发票勾选颜色

master_hella_20240701
wangyufei 5 months ago
parent
commit
ac39a7b17e
  1. 14
      src/components/Table/src/Table.vue
  2. 3
      src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptRequestMain/index.vue
  3. 1
      src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/index.vue

14
src/components/Table/src/Table.vue

@ -61,6 +61,7 @@ export default defineComponent({
default: () => []
},
searchTableSelectionsList:[],//
selectionColor: propTypes.bool.def(false),
},
emits: ['update:pageSize', 'update:currentPage', 'register', 'update:sort','getSelectionRows'],
setup(props, { attrs, slots, emit, expose }) {
@ -369,6 +370,13 @@ export default defineComponent({
)
}
const selectionBg = ({row}) => {
if (unref(getProps).selectionColor&&elTableRef.value?.getSelectionRows().includes(row)) {
return 'selectionRow'
}
return 'tableRow'
}
return () => (
<div v-loading={unref(getProps).loading}>
<ElTable default-expand-all={true}
@ -376,7 +384,7 @@ export default defineComponent({
ref={elTableRef}
data={unref(getProps).data}
header-cell-class-name="tableHeader"
row-class-name="tableRow"
row-class-name={selectionBg}
cell-class-name="tableRow"
onSelect={selectRow}
onSelect-all={selectAll}
@ -418,6 +426,10 @@ export default defineComponent({
--el-bg-color:#f5f5f5;
}
.el-table .selectionRow{
--el-table-tr-bg-color: var(--el-color-primary-light-9);
}
</style>
<style lang="scss" scoped>
:deep(.el-button.is-text) {

3
src/views/wms/inventoryjobManage/unplannedreceipt/unplannedreceiptRequestMain/index.vue

@ -608,6 +608,9 @@ const tableSelectionDelete = (selection) => {
//
const submitForm = async (formType, data) => {
data.subList = tableData.value //
data.subList.forEach(row=>{
row['expireDate'] = row['validityDays']?addDay(row['produceDate'],row['validityDays']).format('YYYY-MM-DD'):''
})
try {
if (formType === 'create') {
console.log("【计划外入库子列表】",data.subList)

1
src/views/wms/supplierManage/supplierinvoice/supplierinvoiceRequestMain/index.vue

@ -19,6 +19,7 @@
<ContentWrap>
<Table ref="tableRef"
:selection="true"
:selectionColor="true"
v-clientTable :columns="tableColumns" :data="tableObject.tableList" :loading="tableObject.loading" :pagination="{
total: tableObject.total
}" v-model:pageSize="tableObject.pageSize" v-model:currentPage="tableObject.currentPage"

Loading…
Cancel
Save