Browse Source

新增预入库车次页面

dev-xx
qb 10 months ago
parent
commit
2236f4c73b
  1. 27
      src/api/finance/CustomerSettlement.js
  2. 18
      src/api/warehouse/PreStoragePackage.js
  3. 737
      src/option/finance/CustomerSettlement.js
  4. 10
      src/option/warehouse/PreStoragePackage.js
  5. 97
      src/option/warehouse/PreStorageTrainNumber.js
  6. 17
      src/router/views/index.js
  7. 7
      src/views/finance/CustomerSettlement.vue
  8. 22
      src/views/warehouse/prewarehousing/PreStoragePackage.vue
  9. 347
      src/views/warehouse/prewarehousing/PreStorageTrainNumber.vue

27
src/api/finance/CustomerSettlement.js

@ -0,0 +1,27 @@
import request from '@/axios';
/**
* 获取商家结算单列表
* @param {*} data
* @returns
*/
export const postPageList = data => {
return request({
url: '/api/logpm-statisticsdata-zhy/merchantBalance/pageList',
method: 'post',
data,
});
};
/**
* 确认结算
* @param {*} data
* @returns
*/
export const postCheckBalance = data => {
return request({
url: '/api/logpm-statisticsdata-zhy/merchantStatistics/checkBalance',
method: 'post',
data,
});
};

18
src/api/warehouse/PreStoragePackage.js

@ -2,8 +2,6 @@ import request from '@/axios';
/**
* 获取未入库数据
* @param {*} current
* @param {*} size
* @param {*} params
* @returns
*/
@ -17,8 +15,6 @@ export const getList = params => {
/**
* 批量入库
* @param {*} current
* @param {*} size
* @param {*} params
* @returns
*/
@ -29,3 +25,17 @@ export const getInOrder = params => {
params,
});
};
/**
* 根据车次获取未入库数据
* @param {*} params
* @returns
*/
export const getPageByCarNum = params => {
return request({
url: '/api/logpm-distribution/businessPreOrder/pageByCarNum',
method: 'get',
params,
});
};
// pageByCarNum

737
src/option/finance/CustomerSettlement.js

File diff suppressed because it is too large Load Diff

10
src/option/warehouse/PreStoragePackage.js

@ -13,7 +13,7 @@ export const columnList = [
{
prop: 'waybillNumber',
label: '运单号',
type: 2,
type: 1,
values: '',
width: '150',
checkarr: [],
@ -24,7 +24,7 @@ export const columnList = [
{
prop: 'serviceNumber',
label: '服务号',
type: 2,
type: 1,
values: '',
width: '150',
checkarr: [],
@ -35,7 +35,7 @@ export const columnList = [
{
prop: 'orderCode',
label: '订单自编号',
type: 2,
type: 1,
values: '',
width: '240',
checkarr: [],
@ -66,7 +66,7 @@ export const columnList = [
{
prop: 'distrCarNumber',
label: '配送车次号',
type: 2,
type: 1,
values: '',
width: '180',
checkarr: [],
@ -119,7 +119,7 @@ export const columnList = [
{
prop: 'trainNumber',
label: '入库车次',
type: 2,
type: 1,
values: '',
width: '180',
checkarr: [],

97
src/option/warehouse/PreStorageTrainNumber.js

@ -0,0 +1,97 @@
export const columnList = [
{
prop: '',
label: '复选框',
type: 0,
values: '',
width: '55',
checkarr: [],
fixed: true,
sortable: true,
head: false,
},
{
prop: '',
label: '序号',
type: 12,
values: '',
width: '55',
checkarr: [],
fixed: true,
sortable: true,
head: false,
},
{
prop: 'waybillNumber',
label: '运单号',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'distrCarNumber',
label: '配送车次',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'orderCode',
label: '订单自编号',
type: 2,
values: '',
width: '240',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'totalNum',
label: '总件数',
type: 1,
values: '',
width: '180',
checkarr: [],
fixed: false,
sortable: true,
},
{
prop: 'inNum',
label: '入库件数',
type: 1,
values: '',
width: '180',
checkarr: [],
fixed: false,
sortable: true,
},
{
prop: 'restNum',
label: '待入库件数',
type: 1,
values: '',
width: '180',
checkarr: [],
fixed: false,
sortable: true,
},
{
prop: '',
label: '操作',
type: 6,
values: '',
width: '250',
checkarr: [],
fixed: 'right',
sortable: false,
},
];

17
src/router/views/index.js

@ -1662,7 +1662,22 @@ export default [
},
],
},
{
path: '/warehouse',
component: Layout,
children: [
// 预入库包件
{
meta: {
i18n: 'dict',
keepAlive: true,
},
path: '/warehouse/prewarehousing/PreStoragePackage',
name: '预入库包件',
component: () => import('@/views/warehouse/prewarehousing/PreStoragePackage.vue'),
},
],
},
// 工单新增重构页面
// {

7
src/views/finance/CustomerSettlement.vue

@ -112,6 +112,7 @@ import {
getopenOrderAdvancePageList,
postOpenOrderFreezeByAdvanceIds,
} from '@/api/waybill/TemporaryStorageList';
import { postPageList } from '@/api/finance/CustomerSettlement';
import {
downloadXls,
setNodeHeight,
@ -168,7 +169,7 @@ const details = reactive<any>({
/** 列表 */
columnList: deepClone(columnList),
/** 列表数据 */
data: [],
data: [{}],
/** 页面loading */
loadingObj: {
/** 列表加载loading */
@ -212,8 +213,10 @@ const onLoad = async (params = {}) => {
// loading
details.loadingObj.list = true;
const submitData = { ...details.query, ...params, ...details.page };
//
const res = await getopenOrderAdvancePageList(details.page, { ...details.query, ...params });
const res = await postPageList(submitData);
console.log('res :>> ', res);
const { code, data } = res.data;
if (code !== 200) return;

22
src/views/warehouse/prewarehousing/PreStoragePackage.vue

@ -2,8 +2,7 @@
<basic-container v-loading="details.loadingObj.pageLoading">
<div class="avue-crud">
<!-- 搜索模块 -->
<div v-h5uShow="!search">
<!-- 查询模块 -->
<!-- <div v-h5uShow="!search">
<el-form :inline="true" :model="query" class="header_search">
<el-form-item label="交期:" class="el-times">
<el-date-picker
@ -32,13 +31,13 @@
clearable
/>
</el-form-item>
<!-- 查询按钮 -->
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="searchChange"> </el-button>
<el-button icon="el-icon-delete" @click="searchReset"> </el-button>
</el-form-item>
</el-form>
</div>
</div> -->
<div class="avue-crud__header">
<!-- 头部左侧按钮模块 -->
@ -58,7 +57,7 @@
<div class="avue-crud__right">
<el-button icon="el-icon-refresh" @click="searchChange" circle></el-button>
<el-button icon="Operation" @click="showdrawer(true)" circle></el-button>
<el-button icon="Search" @click="searchHide" circle></el-button>
<!-- <el-button icon="Search" @click="searchHide" circle></el-button> -->
</div>
</div>
@ -145,7 +144,7 @@ import {
handleTranslationDataSeclect,
} from '@/utils/util';
import { columnList } from '@/option/warehouse/PreStoragePackage';
import { useRouter } from 'vue-router';
import { useRouter, useRoute } from 'vue-router';
import { deepClone } from '@/utils/util';
import { showOrderPackgeCode } from '@/api/distribution/distributionStockArticle';
import { getList, getInOrder } from '@/api/warehouse/PreStoragePackage';
@ -153,6 +152,7 @@ import { ElMessage, ElMessageBox } from 'element-plus';
//
const $router = useRouter();
const $route = useRoute();
const details = reactive<any>({
/** 是否开启搜索 */
@ -241,7 +241,15 @@ const onLoad = async (params = {}) => {
try {
// loading
details.loadingObj.list = true;
const submitData = { ...details.page, ...details.query, ...params };
const { orderCode, waybillNumber, distrCarNumber } = $route.query;
const submitData = {
...details.page,
...details.query,
...params,
orderCode,
waybillNumber,
distrCarNumber,
};
//
const res = await getList(submitData);

347
src/views/warehouse/prewarehousing/PreStorageTrainNumber.vue

@ -0,0 +1,347 @@
<template>
<basic-container v-loading="details.loadingObj.pageLoading">
<div class="avue-crud">
<!-- 搜索模块 -->
<!-- <div v-h5uShow="!search">
<el-form :inline="true" :model="query" class="header_search">
<el-form-item label="交期:" class="el-times">
<el-date-picker
v-model="stockupDate"
type="daterange"
unlink-panels
range-separator="至"
start-placeholder="开始时间"
end-placeholder="结束时间"
:shortcuts="shortcuts"
value-format="YYYY-MM-DD"
clearable
/>
</el-form-item>
<el-form-item label="创建时间:" class="el-times">
<el-date-picker
v-model="stockupDate"
type="daterange"
unlink-panels
range-separator="至"
start-placeholder="开始时间"
end-placeholder="结束时间"
:shortcuts="shortcuts"
value-format="YYYY-MM-DD"
clearable
/>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="searchChange"> </el-button>
<el-button icon="el-icon-delete" @click="searchReset"> </el-button>
</el-form-item>
</el-form>
</div> -->
<div class="avue-crud__header">
<!-- 头部左侧按钮模块 -->
<div class="avue-crud__left"></div>
<!-- 头部右侧按钮模块 -->
<div class="avue-crud__right">
<el-button icon="el-icon-refresh" @click="searchChange" circle></el-button>
<el-button icon="Operation" @click="showdrawer(true)" circle></el-button>
<!-- <el-button icon="Search" @click="searchHide" circle></el-button> -->
</div>
</div>
<!-- 表格 -->
<tablecmt
ref="tableNodeRef"
:columnList="details.columnList"
:tableData="details.data"
:loading="details.loadingObj.list"
@inputTxt="inputsc"
@timeCheck="timesc"
@selectCheck="selectsc"
@selection="selectionChange"
>
<template #default="slotProps">
<template v-if="slotProps.scope.column.label === '操作'">
<!-- 车次详情 -->
<el-text
v-if="Number(slotProps.scope.row.inWarehouse) !== 1"
@click="() => viewDetails(slotProps.scope)"
>
</el-text>
</template>
</template>
</tablecmt>
<!-- 分页模块 -->
<div class="avue-crud__pagination flex-c-sb" style="width: 100%">
<div style="font-size: 14px">勾选数量: {{ selectionList.length }}</div>
<!-- 分页模块 -->
<el-pagination
align="right"
background
@size-change="sizeChange"
@current-change="currentChange"
:current-page="page.current"
:page-sizes="[30, 50, 80, 120]"
:page-size="page.size"
layout="total, sizes, prev, pager, next, jumper"
:total="page.total"
>
</el-pagination>
</div>
</div>
</basic-container>
<MyPrint
width="780px"
:html="details.html"
v-model="details.popUpShow.dialogVisible"
:isShowExport="false"
/>
<!-- 列表配置显示 -->
<edittablehead
@closce="showdrawer"
:drawerShow="drawerShow"
v-model="details.columnList"
></edittablehead>
</template>
<script setup lang="ts">
import { ref, reactive, toRefs, computed, onMounted, nextTick } from 'vue';
import functions from '@/utils/functions.js';
import dayjs from 'dayjs';
import { mapGetters } from 'vuex';
/** 获取字典 */
import { getDictionaryBiz } from '@/api/system/dict';
import {
getopenOrderAdvancePageList,
postOpenOrderFreezeByAdvanceIds,
} from '@/api/waybill/TemporaryStorageList';
import {
downloadXls,
setNodeHeight,
getHtmls,
handleClearTableQuery,
handleInputQuery,
handleSelectQuery,
handleTranslationDataSeclect,
} from '@/utils/util';
import { columnList } from '@/option/warehouse/PreStorageTrainNumber';
import { useRouter } from 'vue-router';
import { deepClone } from '@/utils/util';
import { showOrderPackgeCode } from '@/api/distribution/distributionStockArticle';
import { getPageByCarNum } from '@/api/warehouse/PreStoragePackage';
import { ElMessage, ElMessageBox } from 'element-plus';
//
const $router = useRouter();
const details = reactive<any>({
/** 是否开启搜索 */
search: true,
/** 表格搜索条件 */
query: {},
/** 时间快捷选择设置 */
shortcuts: [
{
text: '最近一周',
value: () => {
const end = new Date();
const start = new Date();
start.setTime(start.getTime() - 3600 * 1000 * 24 * 7);
return [start, end];
},
},
{
text: '最近一个月',
value: () => {
const end = new Date();
const start = new Date();
start.setTime(start.getTime() - 3600 * 1000 * 24 * 30);
return [start, end];
},
},
{
text: '最近三个月',
value: () => {
const end = new Date();
const start = new Date();
start.setTime(start.getTime() - 3600 * 1000 * 24 * 90);
return [start, end];
},
},
],
/** 时间选择器数据 */
stockupDate: [],
/** 列表 */
columnList: deepClone(columnList),
/** 列表数据 */
data: [],
/** 页面loading */
loadingObj: {
/** 列表加载loading */
list: false,
pageLoading: false,
},
/** 列表复选框选中的数据 */
selectionList: [],
/** 是否显示设置表格 */
drawerShow: false,
/** 分页参数 */
page: {
current: 1,
size: 30,
total: 0,
},
/** 列表Dom节点 */
listNode: '',
form: {},
popUpShow: {
/** 查看二维码 */
dialogVisible: false,
},
});
const tableNodeRef = ref();
const { search, query, shortcuts, stockupDate, selectionList, drawerShow, page } = toRefs(details);
/** vuex */
const permission = computed(() => mapGetters(['permission', 'tagWel', 'tagList']));
console.log('permission :>> ', permission);
onMounted(() => {
const timer = setTimeout(() => {
details.listNode = document.querySelector('.maboxhi');
details.listNode.style.transition = 'all .5s ease-out';
clearTimeout(timer);
}, 100);
});
/** 请求页面数据 */
const onLoad = async (params = {}) => {
try {
// loading
details.loadingObj.list = true;
const submitData = { ...details.page, ...details.query, ...params };
//
const res = await getPageByCarNum(submitData);
console.log('res :>> ', res);
const { code, data } = res.data;
if (code !== 200) return;
details.data = data.records;
details.page.total = data.total;
handleTranslationDataSeclect(details.data, details.columnList);
return res.data;
} catch (error) {
console.log('error :>> ', error);
} finally {
details.loadingObj.list = false;
}
};
const initOnLoad = (params = {}) => {
details.page.current = 1;
details.page.total = 0;
onLoad(params);
};
initOnLoad();
/** 搜索 */
const searchChange = () => {
initOnLoad();
};
/** 清空表单 */
const searchReset = () => {
details.query = {};
details.stockupDate = [];
details.page.current = 1;
handleClearTableQuery(details.columnList);
initOnLoad();
};
/** 展开列表控件 */
const showdrawer = (_flag?: boolean) => {
details.drawerShow = _flag;
};
/** 是否开启搜索区 */
const searchHide = () => {
details.search = !details.search;
setNodeHeight(tableNodeRef.value.$el, '', true);
};
/** 表格表头输入框搜索 */
const inputsc = (index, col) => {
handleInputQuery(index, col, details.query);
initOnLoad();
};
/** 表格表头时间选择 */
const timesc = (index, row) => {
console.log(index, row);
if (!!index) {
index = dayjs(index).format('YYYY-MM-DD');
}
details.query[row.prop] = index;
if (!index) {
delete details.query[row.prop];
}
initOnLoad();
};
/** 表格表头下拉框选择 */
const selectsc = (index, colors) => {
handleSelectQuery(index, colors, details.query);
initOnLoad();
};
/** 表格表头复选框选择 */
const selectionChange = (list: any) => {
details.selectionList = list;
};
/** 每页数量改变执行的回调 */
const sizeChange = (size: number) => {
details.page.size = size;
initOnLoad();
};
/** 页码改变执行的回调 */
const currentChange = current => {
details.page.current = current;
onLoad();
};
/** 查看详情 */
const viewDetails = ({ row }) => {
$router.push({
path: '/warehouse/prewarehousing/PreStoragePackage',
query: {
waybillNumber: row.waybillNumber,
distrCarNumber: row.distrCarNumber,
orderCode: row.orderCode,
},
});
};
</script>
<style scoped lang="scss">
//
:deep(.el-date-editor.el-input) {
height: 100% !important;
width: 100% !important;
}
:deep(.el-range-editor.el-input__wrapper) {
height: 100% !important;
}
</style>
Loading…
Cancel
Save