提交
This commit is contained in:
@@ -2,9 +2,7 @@ import request from '@/utils/request'
|
||||
// 查询库存单据主列表
|
||||
export function listBill(data) {
|
||||
return request({
|
||||
// url: '/document/info/bill/groups',
|
||||
url: '/document/order/wisdom/rk/list',
|
||||
|
||||
method: 'get',
|
||||
params: data
|
||||
})
|
||||
|
||||
@@ -25,28 +25,19 @@
|
||||
|
||||
</el-form>
|
||||
|
||||
<!-- @selection-change="printSelectionChange" -->
|
||||
<el-table v-loading="loading" highlight-current-row :data="billList" @row-dblclick="billClick" >
|
||||
<!-- <el-table-column type="selection" width="55" align="center" /> -->
|
||||
<el-table-column label="单据号" align="center" prop="billNoCk" width="150" />
|
||||
<el-table-column label="单据号" align="center" prop="billNo" width="150" />
|
||||
<el-table-column label="库存状态" align="center" >
|
||||
<template #default="scope">
|
||||
<span>{{ isChukuFun(scope.row.isChuku) }}</span>
|
||||
<span>{{ isChukuFun(scope.row.isDelivery) }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="理货员" align="center" prop="ckLihuoY" />
|
||||
<!-- <el-table-column label="入库类型" align="center" prop="rkTypeName" width="100"/> -->
|
||||
<el-table-column label="出库时间" align="center" prop="lyTime" width="170">
|
||||
<el-table-column label="理货员" align="center" prop="operatorName" />
|
||||
<el-table-column label="出库时间" align="center" prop="operationTime" width="170">
|
||||
<template #default="scope">
|
||||
<span>{{ parseTime(scope.row.lyTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
|
||||
<span>{{ parseTime(scope.row.operationTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- <el-table-column label="操作" align="center" width="180">
|
||||
<template #default="scope">
|
||||
<el-button link type="primary" @click="delieryReceipt(scope.row.billNo)">生成配送单</el-button>
|
||||
</template>
|
||||
</el-table-column> -->
|
||||
<!-- <el-table-column label="所属仓库" align="center" prop="cangkuName" /> -->
|
||||
</el-table>
|
||||
<!-- 分页暂时注释掉 -->
|
||||
<!-- <pagination
|
||||
@@ -75,7 +66,7 @@
|
||||
<el-table-column type="selection" width="55" align="center" />
|
||||
<el-table-column label="库存状态" align="center" >
|
||||
<template #default="scope">
|
||||
<span>{{ isChukuFun(scope.row.isChuku) }}</span>
|
||||
<span>{{ isChukuFun(scope.row.bizType) }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="项目号" align="center" prop="xmNo" width="150"/>
|
||||
@@ -86,46 +77,21 @@
|
||||
<el-table-column label="合同单价" align="center" prop="htDj" />
|
||||
<el-table-column label="订单编号" align="center" prop="sapNo" width="150"/>
|
||||
<el-table-column label="计量单位" align="center" prop="dw" />
|
||||
<el-table-column label="实际入库数量" align="center" prop="realQty" width="120"/>
|
||||
<el-table-column label="实际出库数量" align="center" prop="realQty" width="120"/>
|
||||
<el-table-column label="库位码" align="center" prop="pcode" width="120"/>
|
||||
<el-table-column label="托盘码" align="center" prop="trayCode" />
|
||||
<el-table-column label="身份码" align="center" prop="entityId" width="200"/>
|
||||
<el-table-column label="入库类型" align="center" prop="rkTypeName" width="150"/>
|
||||
<el-table-column label="出库类型" align="center" prop="operationTypeName" width="150"/>
|
||||
<el-table-column label="物资类型" align="center" prop="wlTypeName" width="120"/>
|
||||
<el-table-column label="所属仓库" align="center" prop="cangkuName" width="150"/>
|
||||
<el-table-column label="入库时间" align="center" prop="rkTime" width="200">
|
||||
<template #default="scope">
|
||||
<span>{{ parseTime(scope.row.rkTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- <el-table-column label="还料时间" align="center" prop="returnTime" width="200">
|
||||
<template #default="scope">
|
||||
<span>{{ parseTime(scope.row.returnTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
|
||||
</template>
|
||||
</el-table-column> -->
|
||||
<el-table-column label="出库时间" align="center" prop="lyTime" width="200">
|
||||
<el-table-column label="操作时间" align="center" prop="operationTime" width="200">
|
||||
<template #default="scope">
|
||||
<span>{{ parseTime(scope.row.lyTime, '{y}-{m}-{d} {h}:{i}:{s}') }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- <el-table-column label="库龄" align="center" prop="stockAge" /> -->
|
||||
<el-table-column label="理货员" align="center" prop="lihuoYName" />
|
||||
<!-- <el-table-column label="现场图片" align="center" v-if="isExamine==1">
|
||||
<template #default="scope">
|
||||
<el-image :src="scope.row.scenePhotoUrl" style="width:50px;height: 50px;"
|
||||
:zoom-rate="1.2"
|
||||
:max-scale="7"
|
||||
:min-scale="0.2"
|
||||
:preview-src-list="srcList"
|
||||
show-progress
|
||||
:initial-index="4"
|
||||
:preview-teleported="true"
|
||||
@click="preview(scope.row.scenePhotoUrl)"/>
|
||||
</template>
|
||||
</el-table-column> -->
|
||||
<el-table-column label="备注" align="center" prop="remark" width="200"/>
|
||||
<!-- fixed="right" -->
|
||||
|
||||
</el-table>
|
||||
|
||||
</el-splitter-panel>
|
||||
@@ -285,18 +251,10 @@
|
||||
</template>
|
||||
|
||||
<script setup name="outWarehouse">
|
||||
// wisdomDelStock
|
||||
import {listBill,listStock,calculate,addDelivery} from "@/api/outWarehouse/outWarehouse";
|
||||
import { listType } from "@/api/document/type"
|
||||
// import { getToken } from "@/utils/auth";
|
||||
// import {warehousingDict} from "@/api/information/warehousingtype"; //入库类型
|
||||
// import {materialtypeDict} from "@/api/information/materialtype"; //物资类型
|
||||
// import {warehouseDict} from "@/api/information/warehouseinfo"; //所属仓库
|
||||
import {listUser} from "@/api/system/user"; //理货员
|
||||
// import {getKwList} from "@/api/information/pcdedetail"; //库位下拉数据
|
||||
import { Plus } from '@element-plus/icons-vue'
|
||||
// import { onMounted, onUnmounted } from "vue";
|
||||
// import AMapLoader from "@amap/amap-jsapi-loader";
|
||||
|
||||
// let map = null;
|
||||
|
||||
@@ -324,29 +282,16 @@
|
||||
// });
|
||||
const { proxy } = getCurrentInstance();
|
||||
|
||||
const billList = ref([]); //单据列表
|
||||
const stockList = ref([]); //明细列表
|
||||
|
||||
const loading = ref(true);
|
||||
const detailLoading = ref(false); //加载列表详情
|
||||
const showSearch = ref(true);
|
||||
|
||||
const total = ref(0); //单据
|
||||
const detailTotal = ref(0); //明细
|
||||
|
||||
const printList = ref([]) //要打印的数据列表
|
||||
|
||||
|
||||
|
||||
const rkTime = ref([])
|
||||
const isExamine = ref(0) //是否需要开启审核 1开启;0不开启
|
||||
|
||||
|
||||
const srcList = ref([])
|
||||
const personList = ref([]); //理货员下拉数据
|
||||
const carTypeList = ref([]) //推荐车型下拉数据
|
||||
// const itemList = ref([])
|
||||
// const fileList = ref([])
|
||||
|
||||
const dialogPicDetailVisible = ref(false)
|
||||
const multiple = ref(true)
|
||||
@@ -363,9 +308,6 @@
|
||||
},
|
||||
|
||||
queryParams: {
|
||||
// keyword:"",
|
||||
// pageNum: 1,
|
||||
// pageSize: 10,
|
||||
|
||||
},
|
||||
detailQueryParams:{
|
||||
@@ -397,7 +339,6 @@
|
||||
const { queryParams,detailQueryParams,delieryData,rules } = toRefs(data);
|
||||
//生成配送单弹框
|
||||
function delieryReceipt(){
|
||||
|
||||
dialogPicDetailVisible.value = true
|
||||
//理货员下拉数据
|
||||
listUser().then(response=>{
|
||||
@@ -412,96 +353,38 @@
|
||||
|
||||
//双击单据,查询明细
|
||||
function billClick(row){
|
||||
//console.log(row)
|
||||
// return
|
||||
|
||||
if(row.billNoCk){
|
||||
detailLoading.value = true;
|
||||
// detailQueryParams.value.id = row.id
|
||||
// detailQueryParams.value.billNoCk = row.billNoCk
|
||||
// detailList()
|
||||
let detailList = row.detailList
|
||||
for(let i=0;i<detailList.length;i++){
|
||||
detailList[i].deliveryTon = (Number(detailList[i].weightKg) * Number(detailList[i].realQty)).toFixed(3);
|
||||
detailList[i].goodsSize = (Number(detailList[i].volumeM3) * Number(detailList[i].realQty)).toFixed(3);
|
||||
}
|
||||
stockList.value = detailList
|
||||
// detailTotal.value = response.total;
|
||||
detailLoading.value = false;
|
||||
}
|
||||
|
||||
}
|
||||
//查询明细列表数据方法(不查了,改成从数据里直接取了)
|
||||
function detailList(){
|
||||
listStock(detailQueryParams.value).then(response => {
|
||||
// console.log(response)
|
||||
// return
|
||||
for(let i=0;i<response.rows.length;i++){
|
||||
response.rows[i].deliveryTon = (Number(response.rows[i].weightKg) * Number(response.rows[i].realQty)).toFixed(3);
|
||||
response.rows[i].goodsSize = (Number(response.rows[i].volumeM3) * Number(response.rows[i].realQty)).toFixed(3);
|
||||
}
|
||||
stockList.value = response.rows
|
||||
detailTotal.value = response.total;
|
||||
detailLoading.value = false;
|
||||
});
|
||||
stockList.value = row.recordList
|
||||
}
|
||||
function isChukuFun(isChuku){
|
||||
// scope.row.isChuku==0?"已入库":(scope.row.isChuku==1?"已出库":"审批中")
|
||||
return "已出库"
|
||||
}
|
||||
|
||||
|
||||
|
||||
function preview(url){
|
||||
srcList.value = [url]
|
||||
}
|
||||
|
||||
|
||||
|
||||
const stockList = ref([]); //明细列表
|
||||
const billList = ref([]); //单据列表
|
||||
const loading = ref(true);
|
||||
/** 查询库存单据主列表 */
|
||||
function getList() {
|
||||
loading.value = true;
|
||||
// console.log(333333)
|
||||
listBill(queryParams.value).then(response => {
|
||||
// console.log(response)
|
||||
billList.value = response.data;
|
||||
// total.value = response.total;
|
||||
loading.value = false;
|
||||
});
|
||||
|
||||
}
|
||||
/** 搜索按钮操作 */
|
||||
function handleQuery() {
|
||||
|
||||
if(rkTime.value && rkTime.value.length>0){
|
||||
queryParams.value.startTime = rkTime.value[0]
|
||||
queryParams.value.endTime = rkTime.value[1]
|
||||
}else{
|
||||
queryParams.value.startTime = ""
|
||||
queryParams.value.endTime = ""
|
||||
}
|
||||
queryParams.value.pageNum = 1;
|
||||
if(printList.value.length>0){
|
||||
queryParams.value.ids = printList.value.map( item => item.id )
|
||||
}
|
||||
// console.log(queryParams.value)
|
||||
getList();
|
||||
}
|
||||
|
||||
/** 重置按钮操作 */
|
||||
function resetQuery() {
|
||||
proxy.resetForm("queryRef");
|
||||
rkTime.value = []
|
||||
// queryParams.value.startTime = ""
|
||||
// queryParams.value.endTime = ""
|
||||
handleQuery();
|
||||
}
|
||||
|
||||
// 多选框选中数据
|
||||
function handleSelectionChange(selection) {
|
||||
|
||||
|
||||
// console.log(selection)
|
||||
delieryData.value.deliveryTon = 0
|
||||
delieryData.value.goodsSize = 0
|
||||
if(selection.length>0){
|
||||
@@ -525,8 +408,6 @@
|
||||
delieryData.value.deliveryTon = delieryData.value.deliveryTon.toFixed(3) / 1000
|
||||
delieryData.value.goodsSize = delieryData.value.goodsSize.toFixed(3)
|
||||
|
||||
// this.ids = selection.map(item => item.id)
|
||||
// single.value = selection.length!==1
|
||||
multiple.value = !selection.length
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user