style: 格式修改
This commit is contained in:
parent
8bdb6fc270
commit
c92fab3cbd
101
1.html
Normal file
101
1.html
Normal file
|
|
@ -0,0 +1,101 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="zh-CN">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>秋日出行推荐 | 小众宝藏旅行地</title>
|
||||
<style>
|
||||
body {
|
||||
font-family: 'PingFang SC', 'Helvetica Neue', Arial, sans-serif;
|
||||
background-color: #f9f9f9;
|
||||
color: #333;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
.container {
|
||||
max-width: 800px;
|
||||
margin: 0 auto;
|
||||
padding: 20px;
|
||||
background-color: #fff;
|
||||
border-radius: 10px;
|
||||
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
h1 {
|
||||
font-size: 28px;
|
||||
color: #ff6b6b;
|
||||
text-align: center;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
h2 {
|
||||
font-size: 24px;
|
||||
color: #333;
|
||||
margin-top: 30px;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
p {
|
||||
font-size: 16px;
|
||||
line-height: 1.6;
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
ul {
|
||||
list-style-type: none;
|
||||
padding: 0;
|
||||
}
|
||||
li {
|
||||
background-color: #f1f1f1;
|
||||
margin-bottom: 10px;
|
||||
padding: 15px;
|
||||
border-radius: 5px;
|
||||
font-size: 16px;
|
||||
line-height: 1.6;
|
||||
}
|
||||
.highlight {
|
||||
color: #ff6b6b;
|
||||
font-weight: bold;
|
||||
}
|
||||
.footer {
|
||||
text-align: center;
|
||||
margin-top: 30px;
|
||||
font-size: 14px;
|
||||
color: #999;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="container">
|
||||
<h1>🌟 秋日出行推荐!5个小众宝藏旅行地 🌟</h1>
|
||||
<p>🍂 秋天是旅行的最佳季节,天气凉爽,景色宜人。如果你厌倦了人挤人的热门景点,不妨看看这些小众宝藏旅行地,避开人潮,享受属于你的秋日时光!</p>
|
||||
|
||||
<h2>1️⃣ 云南·元阳梯田</h2>
|
||||
<p><span class="highlight">推荐理由:</span>秋天的元阳梯田金黄一片,宛如大地的调色盘,清晨的云雾更是如梦如幻。</p>
|
||||
<p><span class="highlight">玩法:</span>徒步梯田、拍摄日出、体验哈尼族文化。</p>
|
||||
<p><span class="highlight">最佳时间:</span>10月-11月</p>
|
||||
|
||||
<h2>2️⃣ 四川·稻城亚丁</h2>
|
||||
<p><span class="highlight">推荐理由:</span>秋天的稻城亚丁被誉为“最后的香格里拉”,雪山、草甸、湖泊交相辉映。</p>
|
||||
<p><span class="highlight">玩法:</span>徒步牛奶海、五色海,感受高原秋色。</p>
|
||||
<p><span class="highlight">最佳时间:</span>9月-10月</p>
|
||||
|
||||
<h2>3️⃣ 广西·龙脊梯田</h2>
|
||||
<p><span class="highlight">推荐理由:</span>秋天的龙脊梯田金黄一片,层层叠叠,宛如大地的波浪。</p>
|
||||
<p><span class="highlight">玩法:</span>徒步梯田、体验瑶族风情、品尝当地美食。</p>
|
||||
<p><span class="highlight">最佳时间:</span>9月-10月</p>
|
||||
|
||||
<h2>4️⃣ 甘肃·张掖丹霞</h2>
|
||||
<p><span class="highlight">推荐理由:</span>秋天的张掖丹霞色彩更加浓郁,宛如上帝打翻的调色盘。</p>
|
||||
<p><span class="highlight">玩法:</span>拍摄丹霞地貌、体验沙漠越野、参观马蹄寺。</p>
|
||||
<p><span class="highlight">最佳时间:</span>9月-10月</p>
|
||||
|
||||
<h2>5️⃣ 浙江·楠溪江</h2>
|
||||
<p><span class="highlight">推荐理由:</span>秋天的楠溪江山水如画,古村落与秋色相映成趣,适合慢旅行。</p>
|
||||
<p><span class="highlight">玩法:</span>泛舟江上、探访古村落、品尝农家菜。</p>
|
||||
<p><span class="highlight">最佳时间:</span>10月-11月</p>
|
||||
|
||||
<p class="highlight">💡 这些小众旅行地不仅风景绝美,还能避开人潮,享受静谧的秋日时光。如果觉得有用,记得点赞收藏,分享给更多需要的朋友哦~</p>
|
||||
|
||||
<div class="footer">
|
||||
#秋日旅行 #小众旅行地 #宝藏景点 #旅行推荐 #秋天去哪儿
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
|
|
@ -49,12 +49,17 @@ const queryPartNo = (params) => {
|
|||
|
||||
const deleteCurrentPartInfo = (params) => {
|
||||
return request({
|
||||
url: '/goods/deletePartInfo',
|
||||
url: '/goods/deleteGoodInfo',
|
||||
method: 'post',
|
||||
data: params
|
||||
})
|
||||
}
|
||||
|
||||
const clearGoodsInfo =()=> {
|
||||
return request({
|
||||
url: '/goods/clearGoodsInfo',
|
||||
method: 'get',
|
||||
})
|
||||
}
|
||||
export {
|
||||
getAllGoods,
|
||||
updateGoodsInfo,
|
||||
|
|
@ -62,5 +67,6 @@ export {
|
|||
getPartInfo,
|
||||
updatePartInfo,
|
||||
queryPartNo,
|
||||
deleteCurrentPartInfo
|
||||
deleteCurrentPartInfo,
|
||||
clearGoodsInfo
|
||||
}
|
||||
|
|
@ -24,8 +24,33 @@ const getAvailableLocations = (params) => {
|
|||
})
|
||||
}
|
||||
|
||||
const updateArea = (params) => {
|
||||
return request({
|
||||
url: '/location/updateArea',
|
||||
method: 'post',
|
||||
data: params
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
const getStockList = () => {
|
||||
return request({
|
||||
url: '/stock/getStockList',
|
||||
method: 'get',
|
||||
})
|
||||
}
|
||||
|
||||
const getVehicleList = (params) => {
|
||||
return request({
|
||||
url: '/location/getVehicleList',
|
||||
method: 'get',
|
||||
})
|
||||
}
|
||||
export {
|
||||
getLocations,
|
||||
updateLocation,
|
||||
getAvailableLocations
|
||||
getAvailableLocations,
|
||||
updateArea,
|
||||
getStockList,
|
||||
getVehicleList
|
||||
}
|
||||
|
|
@ -8,6 +8,14 @@ const getAllStocks = (params) => {
|
|||
})
|
||||
}
|
||||
|
||||
const getStockByLocation = (params) => {
|
||||
return request({
|
||||
url: '/stock/getStockByLocation',
|
||||
method: 'post',
|
||||
data: params
|
||||
})
|
||||
}
|
||||
|
||||
const getAllStocksByGoodsId = (params) => {
|
||||
return request({
|
||||
url: '/stock/getAllStocksByGoodsId',
|
||||
|
|
@ -23,9 +31,26 @@ const updateStockInfo = (params) => {
|
|||
data: params
|
||||
})
|
||||
}
|
||||
const addStockInfo = (params) => {
|
||||
return request({
|
||||
url: '/stock/addNewStock',
|
||||
method: 'post',
|
||||
data: params
|
||||
})
|
||||
}
|
||||
|
||||
const deleteStockInfo = (params) => {
|
||||
return request({
|
||||
url: '/stock/deleteStockInfo',
|
||||
method: 'post',
|
||||
data: params
|
||||
})
|
||||
}
|
||||
export {
|
||||
getAllStocks,
|
||||
updateStockInfo,
|
||||
getAllStocksByGoodsId
|
||||
getAllStocksByGoodsId,
|
||||
addStockInfo,
|
||||
getStockByLocation,
|
||||
deleteStockInfo
|
||||
}
|
||||
|
|
@ -193,7 +193,7 @@ const callEmptyVehicle = (params) => {
|
|||
|
||||
const changeTaskStatus = (params) => {
|
||||
return request({
|
||||
url: '/taskDeal/changeTaskStatus',
|
||||
url: '/taskDeal/updateTaskStatus',
|
||||
method: 'post',
|
||||
data: params
|
||||
})
|
||||
|
|
|
|||
|
|
@ -7,7 +7,13 @@ const getAllVehicles = (params) => {
|
|||
data: params
|
||||
})
|
||||
}
|
||||
|
||||
const getVehiclesByLocation = (params)=> {
|
||||
return request({
|
||||
url: '/location/getVehiclesByLocation',
|
||||
method: 'post',
|
||||
data: params
|
||||
})
|
||||
}
|
||||
const updateVehicleInfo = (params) => {
|
||||
return request({
|
||||
url: '/location/updateVehicleInfo',
|
||||
|
|
@ -27,5 +33,6 @@ const deleteCurrentVehicle = (params) => {
|
|||
export {
|
||||
getAllVehicles,
|
||||
updateVehicleInfo,
|
||||
deleteCurrentVehicle
|
||||
deleteCurrentVehicle,
|
||||
getVehiclesByLocation
|
||||
}
|
||||
|
|
@ -13,7 +13,6 @@
|
|||
<el-form-item label="载具号:" required>
|
||||
<el-input class="form-input" v-model="bindingData.vehicleNo" clearable/>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="零件号:">
|
||||
<el-input class="form-input" v-model="bindingData.goodsId" clearable/>
|
||||
</el-form-item>
|
||||
|
|
@ -22,16 +21,10 @@
|
|||
</el-form-item>
|
||||
<el-form-item label="库区选择:" prop="abcSelect" required>
|
||||
<el-select v-model="bindingData.abcSelect" placeholder="请选择" style="width: 100%;">
|
||||
<el-option label="A" value="A"></el-option>
|
||||
<el-option label="B" value="B"></el-option>
|
||||
<el-option label="C" value="C"></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="物料种类:" prop="efSelect" required>
|
||||
<el-select v-model="bindingData.efSelect" placeholder="请选择" style="width: 120%;">
|
||||
<el-option label="单种" value="E"></el-option>
|
||||
<el-option label="多种" value="F"></el-option>
|
||||
<el-option label="空托" value="G"></el-option>
|
||||
<el-option label="毛坯区域" value="A"></el-option>
|
||||
<el-option label="待置区域" value="B"></el-option>
|
||||
<el-option label="半成品区域" value="C"></el-option>
|
||||
<el-option label="空托盘区域" value="D"></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<div style="margin-top: 50px">
|
||||
|
|
@ -76,7 +69,6 @@ export default {
|
|||
goodsId: '',
|
||||
goodsNum: '',
|
||||
abcSelect: '',
|
||||
efSelect: ''
|
||||
},
|
||||
bindOrderInList: []
|
||||
}
|
||||
|
|
|
|||
|
|
@ -10,6 +10,11 @@
|
|||
<el-button type="warning" @click="reset()">重置</el-button>
|
||||
<el-button type="success" @click="search()">刷新</el-button>
|
||||
<el-button type="success" @click="exportExcel()">导出信息</el-button>
|
||||
<el-popconfirm title="确认清空信息吗" @confirm="confirmEvent">
|
||||
<template #reference>
|
||||
<el-button type="danger">清空信息</el-button>
|
||||
</template>
|
||||
</el-popconfirm>
|
||||
</el-row>
|
||||
<br/>
|
||||
<el-table :data="partInfos" stripe border v-loading="loading" class="table-class" max-height="650px"
|
||||
|
|
@ -20,24 +25,10 @@
|
|||
<el-radio :label="scope.row.material" v-model="material"> </el-radio>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="material" label="零件号" fixed="left" sortable min-width="120px" />
|
||||
<el-table-column prop="itemDesc" label="描述" fixed="left" min-width="120px" />
|
||||
<el-table-column prop="category" label="零件类型" fixed="left" sortable min-width="120px" />
|
||||
<el-table-column prop="categoryRemark" label="策略" min-width="120px" />
|
||||
<el-table-column prop="unloadPlace" label="卸货点" min-width="120px" />
|
||||
<el-table-column prop="kittingPoint" label="配料点" min-width="120px" />
|
||||
<el-table-column prop="property" label="可用性" min-width="120px" />
|
||||
<el-table-column prop="vendorId" label="供应商代码" min-width="120px" />
|
||||
<el-table-column prop="dataOwner" label="数据负责人" min-width="120px" />
|
||||
<el-table-column prop="partWeight" label="重量" min-width="120px" />
|
||||
<el-table-column prop="storageLocation" label="库位" min-width="120px" />
|
||||
<el-table-column prop="storageType" label="存储类型" min-width="120px" />
|
||||
<el-table-column prop="storageBin" label="BIN位" min-width="120px" />
|
||||
<el-table-column prop="vendorNameEN" label="供应商名称(英文)" min-width="120px" />
|
||||
<el-table-column prop="vendorNameCN" label="供应商名称(中文)" min-width="120px" />
|
||||
<el-table-column prop="vendorCountry" label="供应商国家/地区" min-width="120px" />
|
||||
<el-table-column prop="SLED" label="SLED" min-width="120px" />
|
||||
<el-table-column prop="updateDate" label="更新日期" min-width="120px" />
|
||||
<el-table-column prop="goodsId" label="物料号" fixed="left" sortable min-width="120px"/>
|
||||
<el-table-column prop="goodsUnit" label="规格型号" fixed="left" sortable min-width="120px"/>
|
||||
<el-table-column prop="singleWeight" label="单重(kg)" fixed="left" sortable min-width="120px"/>
|
||||
<el-table-column prop="remark" label="描述" fixed="left" sortable min-width="120px"/>
|
||||
<el-table-column fixed="right" label="操作" width="240px">
|
||||
<template v-slot="scope">
|
||||
<el-button plain type="primary" @click="editCurrentRowGoods(scope.row)">编辑</el-button>
|
||||
|
|
@ -55,113 +46,27 @@
|
|||
style="max-width: 100%" :rules="rules" status-icon>
|
||||
<el-row :gutter="16">
|
||||
<el-col :span="12" :offset="0">
|
||||
<el-form-item label="零件号" prop="material">
|
||||
<el-input v-model="goodsFormEntity.material" disabled />
|
||||
<el-form-item label="零件号" prop="goodsId">
|
||||
<el-input v-model="goodsFormEntity.goodsId" disabled/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="描述" prop="itemDesc">
|
||||
<el-input v-model="goodsFormEntity.itemDesc" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row :gutter="16">
|
||||
<el-col :span="12" :offset="0">
|
||||
<el-form-item label="零件类型" prop="category">
|
||||
<el-input v-model="goodsFormEntity.category" clearable />
|
||||
<el-form-item label="规格" prop="goodsUnit">
|
||||
<el-input v-model="goodsFormEntity.goodsUnit" clearable/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="策略" prop="categoryRemark">
|
||||
<el-input v-model="goodsFormEntity.categoryRemark" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row :gutter="16">
|
||||
<el-col :span="12" :offset="0">
|
||||
<el-form-item label="卸货点" prop="unloadPlace">
|
||||
<el-input v-model="goodsFormEntity.unloadPlace" clearable />
|
||||
<el-form-item label="单重" prop="singleWeight">
|
||||
<el-input v-model="goodsFormEntity.singleWeight" clearable/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="配料点" prop="kittingPoint">
|
||||
<el-input v-model="goodsFormEntity.kittingPoint" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row :gutter="16">
|
||||
<el-col :span="12" :offset="0">
|
||||
<el-form-item label="可用性" prop="property">
|
||||
<el-input v-model="goodsFormEntity.property" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="供应商代码" prop="vendorId">
|
||||
<el-input v-model="goodsFormEntity.vendorId" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row :gutter="16">
|
||||
<el-col :span="12" :offset="0">
|
||||
<el-form-item label="数据负责人" prop="dataOwner">
|
||||
<el-input v-model="goodsFormEntity.dataOwner" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="重量" prop="partWeight">
|
||||
<el-input v-model="goodsFormEntity.partWeight" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row :gutter="16">
|
||||
<el-col :span="12" :offset="0">
|
||||
<el-form-item label="库位" prop="storageLocation">
|
||||
<el-input v-model="goodsFormEntity.storageLocation" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="存储类型" prop="storageType">
|
||||
<el-input v-model="goodsFormEntity.storageType" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row :gutter="16">
|
||||
<el-col :span="12" :offset="0">
|
||||
<el-form-item label="BIN位" prop="storageBin">
|
||||
<el-input v-model="goodsFormEntity.storageBin" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="供应商名称(英文)" prop="vendorNameEN">
|
||||
<el-input v-model="goodsFormEntity.vendorNameEN" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row :gutter="16">
|
||||
<el-col :span="12" :offset="0">
|
||||
<el-form-item label="供应商名称(中文)" prop="vendorNameCN">
|
||||
<el-input v-model="goodsFormEntity.vendorNameCN" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="供应商国家/地区" prop="vendorCountry">
|
||||
<el-input v-model="goodsFormEntity.vendorCountry" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row :gutter="16">
|
||||
<el-col :span="12" :offset="0">
|
||||
<el-form-item label="SLED" prop="SLED">
|
||||
<el-input-number v-model.number="goodsFormEntity.SLED" clearable controls-position="right"
|
||||
:min="0" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="更新日期" prop="updateDate">
|
||||
<el-input v-model="goodsFormEntity.updateDate" clearable />
|
||||
<el-form-item label="描述" prop="remark">
|
||||
<el-input v-model="goodsFormEntity.remark" clearable/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
</el-form>
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
|
|
@ -186,6 +91,8 @@ import UploadExcelPart from '@/excel/UploadExcelPart.vue'
|
|||
import {downloadMaterialExcel} from '@/api/excel.js'
|
||||
</script>
|
||||
<script>
|
||||
import {clearGoodsInfo, updateGoodsInfo} from "@/api/goods";
|
||||
|
||||
export default {
|
||||
name: 'goods',
|
||||
data() {
|
||||
|
|
@ -209,6 +116,21 @@ export default {
|
|||
this.search()
|
||||
},
|
||||
methods: {
|
||||
confirmEvent() {
|
||||
clearGoodsInfo().then(res => {
|
||||
if (res.data.code == 0) {
|
||||
ElMessage({
|
||||
message: '清空所有零件信息成功',
|
||||
type: 'success',
|
||||
})
|
||||
this.search()
|
||||
} else {
|
||||
ElMessage.error(res.data.message)
|
||||
}
|
||||
}).catch(err => {
|
||||
ElMessage.error('清空所有零件信息信息失败:' + err)
|
||||
})
|
||||
},
|
||||
search() {
|
||||
this.loading = true
|
||||
this.pageInfo.pageNum = this.currentPage
|
||||
|
|
@ -216,13 +138,12 @@ export default {
|
|||
const tableRequest = {
|
||||
page: this.pageInfo,
|
||||
param: {
|
||||
material: this.queryKey.trim()
|
||||
goodsName: this.queryKey.trim()
|
||||
},
|
||||
}
|
||||
getPartInfo(tableRequest).then(res => {
|
||||
const tableResponse = res.data
|
||||
if (tableResponse.code != 0) {
|
||||
console.log(tableResponse.code + ':' + tableResponse.message)
|
||||
ElMessage.error(tableResponse.message)
|
||||
}
|
||||
this.partInfos = tableResponse.rows
|
||||
|
|
@ -247,9 +168,8 @@ export default {
|
|||
this.dialogVisible = true
|
||||
},
|
||||
deleteCurrentRowGoods(row) {
|
||||
this.material = row.material
|
||||
const goods = {
|
||||
material: row.material
|
||||
goodsId: row.goodsId
|
||||
}
|
||||
deleteCurrentPartInfo(goods).then(res => {
|
||||
if (res.data.code == 0) {
|
||||
|
|
@ -266,7 +186,7 @@ export default {
|
|||
})
|
||||
},
|
||||
submitGoodsInfo(formData) {
|
||||
updatePartInfo(formData).then(res => {
|
||||
updateGoodsInfo(formData).then(res => {
|
||||
if (res.data.code == 0) {
|
||||
this.dialogVisible = false
|
||||
ElMessage({
|
||||
|
|
|
|||
|
|
@ -5,10 +5,12 @@
|
|||
<el-row style="width: 100%">
|
||||
<el-form :model="searchParams" label-width="120" label-position="left">
|
||||
<el-form-item style="width: 600px" label="查询关键字:">
|
||||
<el-input placeholder="输入 料箱号/库位/任务号 查询..." v-model="searchParams.searchStr" clearable></el-input>
|
||||
<el-input placeholder="输入 料箱号/库位/任务号 查询..." v-model="searchParams.searchStr"
|
||||
clearable></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item style="width: 600px" label="任务状态:">
|
||||
<el-select style="width: 600px" v-model="searchParams.orderStatus" multiple placeholder="请选择需要查询的任务状态">
|
||||
<el-select style="width: 600px" v-model="searchParams.orderStatus" multiple
|
||||
placeholder="请选择需要查询的任务状态">
|
||||
<el-option v-for="item in orderInEnum" :key="item.value" :label="item.label" :value="item.value"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
|
@ -34,13 +36,15 @@
|
|||
<el-table-column prop="orderStatus" label="入库单状态" width="95px" align="center">
|
||||
<template #default="scope">
|
||||
<el-tag class="ml-2" :type=formatterOrderInEnum(scope.row.orderStatus).type>
|
||||
{{formatterOrderInEnum(scope.row.orderStatus).label }}</el-tag>
|
||||
{{ formatterOrderInEnum(scope.row.orderStatus).label }}
|
||||
</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="createPerson" label="创建人" width="100px" align="center" show-overflow-tooltip/>
|
||||
<el-table-column prop="createTime" label="创建时间" :formatter="formatCellValueTime" width="180px"
|
||||
align="center" show-overflow-tooltip/>
|
||||
<el-table-column prop="updateTime" label="更新时间" :formatter="formatCellValueTime" width="180px" align="center" show-overflow-tooltip/>
|
||||
<el-table-column prop="updateTime" label="更新时间" :formatter="formatCellValueTime" width="180px"
|
||||
align="center" show-overflow-tooltip/>
|
||||
<el-table-column prop="remark" label="备注" show-overflow-tooltip min-width="120px"/>
|
||||
<el-table-column fixed="right" label="操作" align="center" width="190">
|
||||
<template #default="scope">
|
||||
|
|
@ -52,12 +56,16 @@
|
|||
</el-tooltip> -->
|
||||
<el-tooltip content="更新数量" placement="top" effect="light">
|
||||
<el-button type="success" size="small" @click="updateGoodsNum(scope.row)">
|
||||
<el-icon><Edit/></el-icon>
|
||||
<el-icon>
|
||||
<Edit/>
|
||||
</el-icon>
|
||||
</el-button>
|
||||
</el-tooltip>
|
||||
<el-tooltip content="删除" placement="top" effect="light">
|
||||
<el-button type="danger" size="small" @click="deleteOrder(scope.row)">
|
||||
<el-icon><Delete/></el-icon>
|
||||
<el-icon>
|
||||
<Delete/>
|
||||
</el-icon>
|
||||
</el-button>
|
||||
</el-tooltip>
|
||||
</el-button-group>
|
||||
|
|
@ -71,7 +79,8 @@
|
|||
<el-input v-model="updateFormEntity.rowId" readonly/>
|
||||
</el-form-item>
|
||||
<el-form-item label="实际数量" prop="realNum">
|
||||
<el-input-number v-model.number="updateFormEntity.realNum" controls-position="right" :min="0" clearable />
|
||||
<el-input-number v-model.number="updateFormEntity.realNum" controls-position="right" :min="0"
|
||||
clearable/>
|
||||
</el-form-item>
|
||||
<!-- 其他表单项 -->
|
||||
</el-form>
|
||||
|
|
@ -100,6 +109,7 @@ import zhCn from 'element-plus/dist/locale/zh-cn.mjs';
|
|||
import en from 'element-plus/dist/locale/en.mjs';
|
||||
import {ref} from "vue";
|
||||
import BindingGoods from "@/components/BindingGoods.vue";
|
||||
|
||||
const language = ref('zh-cn');
|
||||
|
||||
export default {
|
||||
|
|
@ -136,7 +146,8 @@ export default {
|
|||
|
||||
}
|
||||
},
|
||||
mounted() {},
|
||||
mounted() {
|
||||
},
|
||||
methods: {
|
||||
formatCellValueTime,
|
||||
formatterOrderInEnum,
|
||||
|
|
@ -208,7 +219,11 @@ export default {
|
|||
this.updateFormEntity = row;
|
||||
},
|
||||
test() {
|
||||
console.log({rowId:this.updateFormEntity.rowId,realNum:this.updateFormEntity.realNum,orderStatus:this.updateFormEntity.orderStatus});
|
||||
console.log({
|
||||
rowId: this.updateFormEntity.rowId,
|
||||
realNum: this.updateFormEntity.realNum,
|
||||
orderStatus: this.updateFormEntity.orderStatus
|
||||
});
|
||||
},
|
||||
// 提交更新入库单
|
||||
submitUpdate() {
|
||||
|
|
@ -226,7 +241,10 @@ export default {
|
|||
});
|
||||
return;
|
||||
}
|
||||
apiOrderIn.updateForNum({rowId:this.updateFormEntity.rowId,realNum:this.updateFormEntity.realNum}).then(res => {
|
||||
apiOrderIn.updateForNum({
|
||||
rowId: this.updateFormEntity.rowId,
|
||||
realNum: this.updateFormEntity.realNum
|
||||
}).then(res => {
|
||||
const responseData = res.data
|
||||
if (responseData.code === 0) {
|
||||
// 正确请求
|
||||
|
|
|
|||
|
|
@ -11,6 +11,9 @@
|
|||
<el-button color="green">空闲</el-button>
|
||||
<el-button color="red">占用</el-button>
|
||||
<el-button color="yellow">锁定</el-button>
|
||||
<el-tag style="margin-left: 15px;font-size: 20px;color: black" type="success" size="large">A: 毛坯区域 B: 待置区域
|
||||
C:半成品区域 D:空托盘区域
|
||||
</el-tag>
|
||||
<span style="margin-left: 20px;">层数选择:</span>
|
||||
<el-select v-model="chooseLayer" placeholder="层数选择" @change="getAllLocations">
|
||||
<el-option
|
||||
|
|
@ -20,18 +23,39 @@
|
|||
:value="item.value">
|
||||
</el-option>
|
||||
</el-select>
|
||||
<el-button type="primary" style="margin-left: 16px" @click="openDrawer = true">
|
||||
区域划分
|
||||
</el-button>
|
||||
<el-button type="warning" style="margin-left: 16px" @click="resetArea">
|
||||
重置区域
|
||||
</el-button>
|
||||
<el-button color="#00BFFF" style="margin: 0 0 0 auto;" @click="getAllLocations">刷新</el-button>
|
||||
</el-row>
|
||||
<hr style="border: 1px solid #ff0000"/>
|
||||
<div>
|
||||
<el-scrollbar max-height="600px" :native="true" >
|
||||
<el-scrollbar max-height="900px" :native="true">
|
||||
<div v-for="currentRowLocation in allLocations" class="scrollbar-flex-content">
|
||||
<span class="row" v-for="currentLayerLocation in currentRowLocation.currentLayerLocations">
|
||||
<span class="col" v-for="currentColLocation in currentLayerLocation.currentColLocations">
|
||||
<el-button :color="getLocationStatus(currentColLocation)"
|
||||
<el-button :class="getStyle(currentColLocation)"
|
||||
:color="getLocationStatus(currentColLocation)"
|
||||
@click="showDialog(currentColLocation)">
|
||||
<span style="font-size: 13px;">{{ currentColLocation.queue}}排{{ currentColLocation.line}}列{{ currentColLocation.layer}}层 -{{ currentColLocation.wareArea}}</span>
|
||||
<el-icon style="position: relative; left: 3px"
|
||||
v-if="isException(currentColLocation)"><WarningFilled/></el-icon>
|
||||
<!-- <span style="font-size: 13px;"> {{ currentColLocation.queue}}排{{ currentColLocation.line}}列{{ currentColLocation.layer}}层 - {{ currentColLocation.wareArea}} </span>-->
|
||||
<span
|
||||
style="font-size: 13px;"> {{ currentColLocation.wareArea }} {{ currentColLocation.locationId.slice(1, 9) }}</span>
|
||||
</el-button>
|
||||
<span v-if="currentColLocation.line >= 41 && currentColLocation.line < 43"
|
||||
style="width: 12px;height: 50px;margin-left: 19px"></span>
|
||||
<span v-if="currentColLocation.line >= 34 && currentColLocation.line < 36"
|
||||
style="width: 12px;height: 50px;margin-left: 19px"></span>
|
||||
<span v-if="currentColLocation.line >= 27 && currentColLocation.line < 29"
|
||||
style="width: 12px;height: 50px;margin-left: 19px"></span>
|
||||
<span v-if="currentColLocation.line >= 20 && currentColLocation.line < 22"
|
||||
style="width: 12px;height: 50px;margin-left: 19px"></span>
|
||||
<span v-if="currentColLocation.line >= 13 && currentColLocation.line < 15"
|
||||
style="width: 12px;height: 50px;margin-left: 19px"></span>
|
||||
</span>
|
||||
</span>
|
||||
</div>
|
||||
|
|
@ -66,9 +90,16 @@
|
|||
</el-form-item>
|
||||
<el-form-item label="库区选择" :label-width="140">
|
||||
<el-select v-model="location.wareArea" placeholder="选择库区" style="width: 70%;">
|
||||
<el-option label="A" value="A" />
|
||||
<el-option label="B" value="B" />
|
||||
<el-option label="C" value="C" />
|
||||
<el-option label="毛坯区域" value="A"/>
|
||||
<el-option label="待置区域" value="B"/>
|
||||
<el-option label="半成品区域" value="C"/>
|
||||
<el-option label="空托盘区域" value="D"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="移库交换区域" :label-width="140">
|
||||
<el-select v-model="location.isChangeArea" style="width: 70%;">
|
||||
<el-option label="否" :value="0"/>
|
||||
<el-option label="是" :value="1"/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
|
|
@ -89,15 +120,45 @@
|
|||
</el-form-item>
|
||||
</el-form>
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="托盘信息" name="vehicle">Config</el-tab-pane>
|
||||
<el-tab-pane label="托盘信息" name="vehicle">
|
||||
<el-form :model="vehicle">
|
||||
<el-form-item label="托盘号" :label-width="140">
|
||||
<el-input v-model="vehicle.vehicleId" style="width: 70%;"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="托盘当前位置" :label-width="140">
|
||||
<el-input v-model="vehicle.currentLocation" style="width: 70%;"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="托盘状态" :label-width="140">
|
||||
<el-select v-model="vehicle.vehicleStatus" placeholder="区域选择" @change="getAllLocations">
|
||||
<el-option
|
||||
v-for="item in vehicleStatusOptions"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value">
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="是否是空托盘" :label-width="140">
|
||||
<el-select v-model="vehicle.isEmpty" placeholder="区域选择" @change="getAllLocations">
|
||||
<el-option
|
||||
v-for="item in emptyOptions"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value">
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</el-tab-pane>
|
||||
</el-tabs>
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<el-button @click="dialogVisible = false">取消</el-button>
|
||||
<el-button v-if="activeTabName == 'location'" type="primary" @click="submitLocationStatus()">
|
||||
<el-button v-if="activeTabName == 'location'" type="primary"
|
||||
@click="submitLocationStatus()">
|
||||
更新库位信息
|
||||
</el-button>
|
||||
<el-button v-if="activeTabName == 'stock'" type="primary" @click="submitLocationStatus()">
|
||||
<el-button v-if="activeTabName == 'stock'" type="primary">
|
||||
<span v-if="isAddStock" @click="handleAddStock">
|
||||
添加物料信息
|
||||
</span>
|
||||
|
|
@ -105,7 +166,8 @@
|
|||
更新物料信息
|
||||
</span>
|
||||
</el-button>
|
||||
<el-button v-if="activeTabName == 'vehicle'" type="primary" @click="submitLocationStatus()">
|
||||
<el-button v-if="activeTabName == 'vehicle'" type="primary"
|
||||
@click="updateCurrentVehicleInfo">
|
||||
更新托盘信息
|
||||
</el-button>
|
||||
</span>
|
||||
|
|
@ -113,6 +175,53 @@
|
|||
</el-dialog>
|
||||
</div>
|
||||
</el-config-provider>
|
||||
<!--区域选择 -->
|
||||
<el-drawer v-model="openDrawer" :direction="direction">
|
||||
<template #header>
|
||||
<h4>区域划分</h4>
|
||||
</template>
|
||||
<template #default>
|
||||
<div>
|
||||
<el-form ref="areaForm" :model="areaForm" label-width="100px">
|
||||
<el-form-item label="区域选择">
|
||||
<el-select v-model="areaForm.chooseArea" placeholder="区域选择" @change="getAllLocations">
|
||||
<el-option
|
||||
v-for="item in areaOptions"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value">
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item label="开始排">
|
||||
<el-input v-model="areaForm.startQueue" placeholder="请输入排编号(如13)"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="结束排">
|
||||
<el-input v-model="areaForm.endQueue" placeholder="请输入排编号(如13)"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="开始列">
|
||||
<el-input v-model="areaForm.startLine" placeholder="请输入列编号(如42)"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="结束列">
|
||||
<el-input v-model="areaForm.endLine" placeholder="请输入列编号(如42)"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="开始层">
|
||||
<el-input v-model="areaForm.startLayer" placeholder="请输入层编号(如02)"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="结束层">
|
||||
<el-input v-model="areaForm.endLayer" placeholder="请输入层编号(如02)"></el-input>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</div>
|
||||
</template>
|
||||
<template #footer>
|
||||
<div style="flex: auto">
|
||||
<el-button @click="cancelClick">取消</el-button>
|
||||
<el-button type="primary" @click="confirmClick">确认划分</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</el-drawer>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
|
@ -124,16 +233,55 @@ import { reactive } from 'vue'
|
|||
</script>
|
||||
<script>
|
||||
import {reactive} from "vue";
|
||||
import {addStockInfo, getStockByLocation, updateStockInfo} from "@/api/stock";
|
||||
import {addStockInfo, getAllStocks, getStockByLocation, updateStockInfo} from "@/api/stock";
|
||||
import {ElLoading, ElMessage} from "element-plus";
|
||||
import {getStockList, getVehicleList, updateArea} from "@/api/location";
|
||||
import {getAllVehicles, getVehiclesByLocation, updateVehicleInfo} from "@/api/vehicle";
|
||||
|
||||
export default {
|
||||
name: 'location',
|
||||
data() {
|
||||
return {
|
||||
vehicle: {},
|
||||
stockList: [],
|
||||
vehicleList: [],
|
||||
vehicleStatusOptions: [{
|
||||
value: 1,
|
||||
label: '入库中'
|
||||
}, {
|
||||
value: 2,
|
||||
label: '在库中',
|
||||
}, {
|
||||
value: 3,
|
||||
label: '出库中',
|
||||
}],
|
||||
emptyOptions: [{
|
||||
value: 1,
|
||||
label: '空托盘'
|
||||
}, {
|
||||
value: 0,
|
||||
label: '非空托盘'
|
||||
}],
|
||||
areaOptions: [{
|
||||
value: 'A',
|
||||
label: '毛坯区域'
|
||||
}, {
|
||||
value: 'B',
|
||||
label: '待置区域'
|
||||
}, {
|
||||
value: 'C',
|
||||
label: '半成品区域'
|
||||
},
|
||||
{
|
||||
value: 'D',
|
||||
label: '空托盘区域'
|
||||
}],
|
||||
areaForm: {},
|
||||
direction: 'rtl',
|
||||
openDrawer: false,
|
||||
isAddStock: true,
|
||||
stock: {},
|
||||
activeTabName:'stock',
|
||||
activeTabName: 'location',
|
||||
options: [{
|
||||
value: 1,
|
||||
label: '第一层'
|
||||
|
|
@ -156,7 +304,8 @@ export default {
|
|||
locationStatus: '',
|
||||
isLock: '',
|
||||
vehicleId: '',
|
||||
wareArea: ''
|
||||
wareArea: '',
|
||||
isChangeArea: 0
|
||||
}),
|
||||
currentLocationTitle: '',
|
||||
areaId: 1
|
||||
|
|
@ -164,10 +313,131 @@ export default {
|
|||
},
|
||||
mounted() {
|
||||
this.getAllLocations()
|
||||
this.getAllStock()
|
||||
this.getAllVechicle()
|
||||
},
|
||||
methods: {
|
||||
getAllStock() {
|
||||
getStockList().then(res => {
|
||||
if (res.data.code == 0) {
|
||||
ElMessage.success(res.data.message)
|
||||
this.stockList = res.data.returnData
|
||||
} else {
|
||||
ElMessage.error(res.data.message)
|
||||
}
|
||||
}).catch(err => {
|
||||
ElMessage.error('查询所有托盘信息失败!', err)
|
||||
})
|
||||
},
|
||||
getAllVechicle() {
|
||||
getVehicleList().then(res => {
|
||||
if (res.data.code == 0) {
|
||||
ElMessage.success(res.data.message)
|
||||
this.vehicleList = res.data.returnData;
|
||||
} else {
|
||||
ElMessage.error(res.data.message)
|
||||
}
|
||||
}).catch(err => {
|
||||
ElMessage.error('查询所有托盘信息失败!', err)
|
||||
})
|
||||
},
|
||||
isException(locationInfo) {
|
||||
if (locationInfo.locationStatus == 1) {
|
||||
const vehicleList = this.vehicleList.filter(item => item.currentLocation == locationInfo.locationId)
|
||||
const stockList = this.stockList.filter(item => item.locationId == locationInfo.locationId)
|
||||
console.log(locationInfo.locationId)
|
||||
console.log(this.vehicleList)
|
||||
console.log(stockList)
|
||||
console.log(vehicleList)
|
||||
if (vehicleList.length == 0 || stockList.length == 0) {
|
||||
return true
|
||||
}
|
||||
} else {
|
||||
return false
|
||||
}
|
||||
|
||||
},
|
||||
updateCurrentVehicleInfo() {
|
||||
updateVehicleInfo(this.vehicle).then(res => {
|
||||
console.log(res.data.code)
|
||||
if (res.data.code == 0) {
|
||||
ElMessage.success(res.data.message)
|
||||
this.getCurrentVehicleInfo(this.currentSelectedLocation.locationId)
|
||||
} else {
|
||||
ElMessage.error(res.data.message)
|
||||
}
|
||||
}).catch(err => {
|
||||
ElMessage.error('更新托盘信息失败!', err)
|
||||
})
|
||||
},
|
||||
getChangeAreaStyle(val) {
|
||||
return 'change-area-style'
|
||||
},
|
||||
getCurrentVehicleInfo(locationId) {
|
||||
getVehiclesByLocation({locationId: locationId}).then(res => {
|
||||
if (res.data.code === 0) {
|
||||
this.vehicle = res.data.returnData
|
||||
} else {
|
||||
ElMessage.error(res.data.message)
|
||||
}
|
||||
}).catch(err => {
|
||||
ElMessage.error('查询托盘信息失败!', err)
|
||||
})
|
||||
},
|
||||
resetArea() {
|
||||
updateArea({chooseArea: 'reset'}).then(res => {
|
||||
if (res.data.code == 0) {
|
||||
this.dialogVisible = false
|
||||
ElMessage({
|
||||
message: '重置成功!',
|
||||
type: 'success',
|
||||
})
|
||||
this.getAllLocations()
|
||||
} else {
|
||||
ElMessage.error(res.data.message)
|
||||
}
|
||||
}).catch(err => {
|
||||
ElMessage.error('重置失败', err)
|
||||
})
|
||||
},
|
||||
getStyle(val) {
|
||||
let colorClass = [];
|
||||
if (val.wareArea === 'A') {
|
||||
colorClass.push('red-text');
|
||||
} else if (val.wareArea === 'B') {
|
||||
colorClass.push('green-text');
|
||||
} else if (val.wareArea === 'C') {
|
||||
colorClass.push('blue-text');
|
||||
} else if (val.wareArea === 'D') {
|
||||
colorClass.push('purple-text');
|
||||
}
|
||||
if (val.isChangeArea == 1) {
|
||||
colorClass.push('change-area-style')
|
||||
}
|
||||
return colorClass;
|
||||
},
|
||||
cancelClick() {
|
||||
this.openDrawer = false
|
||||
},
|
||||
confirmClick() {
|
||||
updateArea(this.areaForm).then(res => {
|
||||
if (res.data.code == 0) {
|
||||
this.dialogVisible = false
|
||||
ElMessage({
|
||||
message: '划分区域成功!',
|
||||
type: 'success',
|
||||
})
|
||||
this.getAllLocations()
|
||||
} else {
|
||||
ElMessage.error(res.data.message)
|
||||
}
|
||||
}).catch(err => {
|
||||
ElMessage.error('划分失败', err)
|
||||
})
|
||||
},
|
||||
handleAddStock() {
|
||||
if (this.isAddStock) {
|
||||
this.stock.locationId = this.location.locationId
|
||||
addStockInfo(this.stock).then(res => {
|
||||
if (res.data.code == 0) {
|
||||
this.dialogVisible = false
|
||||
|
|
@ -246,20 +516,19 @@ export default {
|
|||
loading.close()
|
||||
ElMessage.error('查询库位失败!')
|
||||
})
|
||||
},
|
||||
test() {
|
||||
console.log(this.location);
|
||||
},
|
||||
showDialog(currentColLocation) {
|
||||
this.dialogVisible = true
|
||||
this.currentSelectedLocation = currentColLocation
|
||||
this.getStockLocation(this.currentSelectedLocation.locationId)
|
||||
this.getCurrentVehicleInfo(this.currentSelectedLocation.locationId)
|
||||
this.setCurrentLocationTitle()
|
||||
this.location.locationId = this.currentSelectedLocation.locationId
|
||||
this.location.locationStatus = this.currentSelectedLocation.locationStatus
|
||||
this.location.isLock = this.currentSelectedLocation.isLock
|
||||
this.location.vehicleId = this.currentSelectedLocation.vehicleId
|
||||
this.location.wareArea = this.currentSelectedLocation.wareArea
|
||||
this.location.isChangeArea = this.currentSelectedLocation.isChangeArea
|
||||
},
|
||||
submitLocationStatus() {
|
||||
const loading = ElLoading.service({
|
||||
|
|
@ -272,6 +541,7 @@ export default {
|
|||
this.currentSelectedLocation.isLock = this.location.isLock
|
||||
this.currentSelectedLocation.vehicleId = this.location.vehicleId
|
||||
this.currentSelectedLocation.wareArea = this.location.wareArea
|
||||
this.currentSelectedLocation.isChangeArea = this.location.isChangeArea
|
||||
updateLocation(this.currentSelectedLocation).then(res => {
|
||||
if (res.data.code == 0) {
|
||||
loading.close()
|
||||
|
|
@ -304,9 +574,7 @@ export default {
|
|||
}
|
||||
|
||||
.row {
|
||||
//display: flex;
|
||||
//justify-content: space-between;
|
||||
margin: 5px;
|
||||
//display: flex; //justify-content: space-between; margin: 5px;
|
||||
}
|
||||
|
||||
.col {
|
||||
|
|
@ -319,14 +587,37 @@ export default {
|
|||
.col .el-button {
|
||||
width: 100px;
|
||||
height: 50px;
|
||||
padding: 4px;
|
||||
}
|
||||
|
||||
.scrollbar-flex-content {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
.demo-tabs > .el-tabs__content {
|
||||
padding: 32px;
|
||||
color: #6b778c;
|
||||
font-size: 32px;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.red-text {
|
||||
color: white;
|
||||
}
|
||||
|
||||
.green-text {
|
||||
color: black;
|
||||
}
|
||||
|
||||
.blue-text {
|
||||
color: blue;
|
||||
}
|
||||
|
||||
.purple-text {
|
||||
color: purple;
|
||||
}
|
||||
|
||||
.change-area-style {
|
||||
border: 4px solid black;
|
||||
}
|
||||
</style>
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@
|
|||
<el-config-provider :locale="zhCn">
|
||||
<el-row>
|
||||
<el-input v-model="queryKey" v-if="dataType == 1" style="width: 256px; margin-right: 10px;"
|
||||
placeholder="零件号/箱号/零件名称" :suffix-icon="Search" />
|
||||
placeholder="零件号/箱号/零件名称/时间" :suffix-icon="Search"/>
|
||||
<el-input v-if="dataType == 2" v-model="goodsIdQuery" style="width: 256px; margin-right: 10px;"
|
||||
placeholder="零件号" :suffix-icon="Search"/>
|
||||
<el-button type="primary" @click="search()">搜索</el-button>
|
||||
|
|
@ -23,27 +23,28 @@
|
|||
</el-table-column>
|
||||
<el-table-column prop="stockId" label="库存ID" min-width="120px" show-overflow-tooltip/>
|
||||
<el-table-column prop="goodsId" label="物料号" min-width="120px"/>
|
||||
<el-table-column prop="batchNo" v-if="dataType == 1" label="批次号" min-width="120px" />
|
||||
<el-table-column prop="goodsName" label="零件描述" min-width="120px" />
|
||||
<el-table-column prop="singleWeight" label="单重" min-width="120px"/>
|
||||
<el-table-column prop="availableNum" v-if="dataType == 1" label="可用数量" min-width="120px"/>
|
||||
<el-table-column prop="remainNum" v-if="dataType == 1" label="剩余数量" min-width="120px" />
|
||||
<el-table-column prop="realNum" label="实际数量" min-width="120px" />
|
||||
<!-- <el-table-column prop="remainNum" v-if="dataType == 1" label="剩余数量" min-width="120px" />-->
|
||||
<!-- <el-table-column prop="realNum" label="实际数量" min-width="120px" />-->
|
||||
<el-table-column prop="vehicleId" v-if="dataType == 1" label="料箱号" fixed="left" min-width="120px"/>
|
||||
<el-table-column prop="providerId" v-if="dataType == 1" label="供应商编号" min-width="130px" />
|
||||
<el-table-column prop="providerName" v-if="dataType == 1" label="供应商名称" min-width="130px" />
|
||||
<el-table-column prop="shelfLife" v-if="dataType == 1" label="保质期" min-width="120px" />
|
||||
<el-table-column prop="expirationDate" v-if="dataType == 1" label="有效日期" :formatter="dateFormat" min-width="140px" />
|
||||
<el-table-column prop="locationId" v-if="dataType == 1" label="库位" :formatter="locationFormat" min-width="160px" />
|
||||
<el-table-column prop="currentLocation" v-if="dataType == 1" label="当前位置" min-width="120px" />
|
||||
<el-table-column prop="isInventory" v-if="dataType == 1" label="是否盘点" min-width="120px" />
|
||||
<el-table-column prop="createTime" v-if="dataType == 1" label="上架时间" :formatter="timeFormat" min-width="140px" />
|
||||
<el-table-column prop="goodsStatus" v-if="dataType == 1" label="物料状态" :formatter="goodsStatusFormat" min-width="120px" />
|
||||
<el-table-column prop="stockStatus" v-if="dataType == 1" label="库存状态" :formatter="stockStatusFormat" fixed="right"
|
||||
<!-- <el-table-column prop="shelfLife" v-if="dataType == 1" label="保质期" min-width="120px" />-->
|
||||
<!-- <el-table-column prop="expirationDate" v-if="dataType == 1" label="有效日期" :formatter="dateFormat" min-width="140px" />-->
|
||||
<el-table-column prop="locationId" v-if="dataType == 1" label="库位" :formatter="locationFormat"
|
||||
min-width="160px"/>
|
||||
<el-table-column prop="createTime" v-if="dataType == 1" label="上架时间" :formatter="timeFormat"
|
||||
min-width="140px"/>
|
||||
<el-table-column prop="stockStatus" v-if="dataType == 1" label="库存状态" :formatter="stockStatusFormat"
|
||||
fixed="right"
|
||||
min-width="120px"/>
|
||||
<el-table-column fixed="right" label="操作" width="135px" v-if="selStock == null">
|
||||
<template v-slot="scope">
|
||||
<el-button size="small" plain type="primary" @click="editCurrentRowStock(scope.row)">编辑</el-button>
|
||||
<!--<el-button size="small" plain type="warning" @click="outRowStock(scope.row)">出库</el-button>-->
|
||||
<el-popconfirm title="你确定删除了?" @confirm="deleteCurrentRowStock(scope.row)">
|
||||
<template #reference>
|
||||
<el-button size="small" plain type="warning">删除</el-button>
|
||||
</template>
|
||||
</el-popconfirm>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- <el-table-column prop="areaCode" label="库区代码" fixed="right" sortable min-width="120px" /> -->
|
||||
|
|
@ -60,61 +61,55 @@
|
|||
<el-form-item label="零件号" prop="goodsId">
|
||||
<el-input v-model="stockFormEntity.goodsId"/>
|
||||
</el-form-item>
|
||||
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="零件描述" prop="goodsName">
|
||||
<el-input v-model="stockFormEntity.goodsName" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row :gutter="16">
|
||||
<el-col :span="12" :offset="0">
|
||||
<el-form-item label="可用数量" prop="availableNum">
|
||||
<el-input-number v-model.number="stockFormEntity.availableNum" clearable
|
||||
controls-position="right" :min="0"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="剩余数量" prop="remainNum">
|
||||
<el-input-number v-model.number="stockFormEntity.remainNum" clearable
|
||||
controls-position="right" :min="0" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row :gutter="16">
|
||||
<el-col :span="12" :offset="0">
|
||||
<el-form-item label="实际数量(为0时删除库存)" prop="realNum">
|
||||
<el-input-number v-model.number="stockFormEntity.realNum" controls-position="right"
|
||||
:min="0" clearable />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="货箱号" prop="vehicleId">
|
||||
<el-input v-model="stockFormEntity.vehicleId" clearable readonly/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row :gutter="16">
|
||||
<el-col :span="12" :offset="0">
|
||||
<el-form-item label="库存状态" prop="stockStatus">
|
||||
<el-select-v2 v-model="stockFormEntity.stockStatus" placeholder="请选择库存状态"
|
||||
:options="stockStatusOptions"></el-select-v2>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
<el-row :gutter="16">
|
||||
|
||||
<el-col :span="12">
|
||||
<el-form-item label="物料状态" prop="goodsStatus">
|
||||
<el-select-v2 v-model="stockFormEntity.goodsStatus" placeholder="请选择物料状态"
|
||||
:options="goodsStatusOptions"></el-select-v2>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="单重" prop="singleWeight">
|
||||
<el-input v-model="stockFormEntity.singleWeight"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
<template #footer>
|
||||
<span class="dialog-footer">
|
||||
<div v-if="isAddStock">
|
||||
<el-button @click="dialogVisible = false">取消</el-button>
|
||||
<el-button type="primary" @click="submitStockInfo(stockFormEntity)">
|
||||
添加
|
||||
</el-button>
|
||||
</div>
|
||||
<div v-else>
|
||||
<el-button @click="dialogVisible = false">取消</el-button>
|
||||
<el-button type="primary" @click="submitStockInfo(stockFormEntity)">
|
||||
确定
|
||||
</el-button>
|
||||
</div>
|
||||
</span>
|
||||
</template>
|
||||
</el-dialog>
|
||||
|
|
@ -136,6 +131,9 @@ import apiOrderOut from '@/api/order.out'
|
|||
// import * as XLSX from 'xlsx';
|
||||
</script>
|
||||
<script>
|
||||
import {deleteStockInfo} from "@/api/stock";
|
||||
import {ElMessage} from "element-plus";
|
||||
|
||||
export default {
|
||||
name: 'stock',
|
||||
props: ['selStock'],
|
||||
|
|
@ -155,6 +153,7 @@ export default {
|
|||
rules: reactive({}),
|
||||
labelPosition: 'top',
|
||||
dialogVisible: false,
|
||||
isAddStock: false,
|
||||
goodsStatusOptions: [
|
||||
{
|
||||
value: 0,
|
||||
|
|
@ -229,6 +228,52 @@ export default {
|
|||
this.refresh()
|
||||
},
|
||||
methods: {
|
||||
getFormattedDate() {
|
||||
let date = new Date(),
|
||||
year = date.getFullYear(),
|
||||
month = (date.getMonth() + 1).toString().padStart(2, '0'),
|
||||
day = date.getDate().toString().padStart(2, '0');
|
||||
return `${year}-${month}-${day}`;
|
||||
},
|
||||
selectNowdayStock() {
|
||||
this.loading = true
|
||||
this.pageInfo.pageNum = this.currentPage
|
||||
this.pageInfo.pageSize = this.pageSize
|
||||
if (this.dataType == 1) {
|
||||
const tableRequest = {
|
||||
page: this.pageInfo,
|
||||
param: this.getFormattedDate(),
|
||||
}
|
||||
getAllStocks(tableRequest).then(res => {
|
||||
const tableResponse = res.data
|
||||
if (tableResponse.code != 0) {
|
||||
ElMessage.error(tableResponse.message)
|
||||
}
|
||||
this.displayStocks = tableResponse.rows
|
||||
this.total = tableResponse.total
|
||||
}).catch(err => {
|
||||
console.log(err)
|
||||
ElMessage.error('查询库存错误')
|
||||
})
|
||||
} else if (this.dataType == 2) {
|
||||
const tableRequest = {
|
||||
page: this.pageInfo,
|
||||
param: this.getFormattedDate(),
|
||||
}
|
||||
getAllStocksByGoodsId(tableRequest).then(res => {
|
||||
const tableResponse = res.data
|
||||
if (tableResponse.code != 0) {
|
||||
ElMessage.error(tableResponse.message)
|
||||
}
|
||||
this.displayStocks = tableResponse.rows
|
||||
this.total = tableResponse.total
|
||||
}).catch(err => {
|
||||
console.log(err)
|
||||
ElMessage.error('查询库存错误')
|
||||
})
|
||||
}
|
||||
this.loading = false
|
||||
},
|
||||
locationFormat: (row, column, cellValue, index) => {
|
||||
return locationFormatter(cellValue)
|
||||
},
|
||||
|
|
@ -251,6 +296,7 @@ export default {
|
|||
return '长时间未使用'
|
||||
}
|
||||
},
|
||||
|
||||
stockStatusFormat: (row, column, cellValue, index) => {
|
||||
switch (cellValue) {
|
||||
case 0:
|
||||
|
|
@ -372,7 +418,25 @@ export default {
|
|||
this.stockFormEntity = row
|
||||
this.dialogVisible = true
|
||||
},
|
||||
|
||||
deleteCurrentRowStock(row) {
|
||||
deleteStockInfo({stockId: row.stockId}).then(res => {
|
||||
if (res.data.code === 0) {
|
||||
// 正确请求
|
||||
ElMessage({
|
||||
message: '删除成功',
|
||||
type: 'success',
|
||||
});
|
||||
this.refresh()
|
||||
} else {
|
||||
// 服务报错
|
||||
ElMessageBox.alert(`服务器返回失败:${responseData.message}`, '执行失败', {
|
||||
type: 'warning',
|
||||
confirmButtonText: '确定',
|
||||
showClose: false
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
outRowStock(row) {
|
||||
const stockId = row.stockId;
|
||||
ElMessageBox.confirm(`是否执行 ${stockId} 的出库?`, '提示')
|
||||
|
|
@ -404,11 +468,8 @@ export default {
|
|||
})
|
||||
.catch(() => {
|
||||
})
|
||||
|
||||
|
||||
},
|
||||
submitStockInfo(stockFormEntity) {
|
||||
console.log(stockFormEntity)
|
||||
updateStockInfo(stockFormEntity).then(res => {
|
||||
if (res.data.code == 0) {
|
||||
this.dialogVisible = false
|
||||
|
|
|
|||
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
<template>
|
||||
<div style="margin-bottom: 15px">
|
||||
<el-config-provider :locale="zhCn">
|
||||
|
|
@ -11,7 +10,8 @@
|
|||
</el-row>
|
||||
<br/>
|
||||
<el-table :data="tasks" stripe border v-loading="loading" style="width: 100%" max-height="684px"
|
||||
class="table-class" :header-cell-style="{ 'text-align': 'center' }" :cell-style="{ 'text-align': 'center' }"
|
||||
class="table-class" :header-cell-style="{ 'text-align': 'center' }"
|
||||
:cell-style="{ 'text-align': 'center' }"
|
||||
@row-click="getCurrentRow">
|
||||
<el-table-column width="65px" fixed="left">
|
||||
<template v-slot="scope">
|
||||
|
|
@ -20,19 +20,19 @@
|
|||
</el-table-column>
|
||||
<el-table-column prop="goodsId" label="零件号" fixed="left" min-width="120px"/>
|
||||
<el-table-column prop="vehicleNo" label="箱号" fixed="left" min-width="120px"/>
|
||||
<el-table-column prop="goodsName" label="零件名称" min-width="120px" />
|
||||
<!-- <el-table-column prop="goodsName" label="零件名称" min-width="120px" />-->
|
||||
<el-table-column prop="taskType" label="任务类型" :formatter="taskTypeFormat" min-width="120px"/>
|
||||
<el-table-column prop="taskGroup" label="任务组" min-width="120px"/>
|
||||
<el-table-column prop="origin" label="起点" min-width="120px"/>
|
||||
<el-table-column prop="destination" label="终点" min-width="120px"/>
|
||||
<el-table-column prop="pickStand" label="拣选站台" min-width="120px" />
|
||||
<!-- <el-table-column prop="pickStand" label="拣选站台" min-width="120px" />-->
|
||||
<el-table-column prop="weight" label="重量" min-width="120px"/>
|
||||
<el-table-column prop="productionDate" label="生产日期" :formatter="dateFormat" min-width="120px" />
|
||||
<el-table-column prop="expirationDate" label="有效日期" :formatter="dateFormat" min-width="120px" />
|
||||
<el-table-column prop="operateNum" label="操作数量" min-width="120px" />
|
||||
<el-table-column prop="totalNum" label="库存数量" min-width="120px" />
|
||||
<!-- <el-table-column prop="productionDate" label="生产日期" :formatter="dateFormat" min-width="120px" />-->
|
||||
<!-- <el-table-column prop="expirationDate" label="有效日期" :formatter="dateFormat" min-width="120px" />-->
|
||||
<!-- <el-table-column prop="operateNum" label="操作数量" min-width="120px" />-->
|
||||
<!-- <el-table-column prop="totalNum" label="库存数量" min-width="120px" />-->
|
||||
<el-table-column prop="taskPriority" label="任务优先级" min-width="120px"/>
|
||||
<el-table-column prop="kateTaskId" label="配件任务号" min-width="140px" />
|
||||
<!-- <el-table-column prop="kateTaskId" label="配件任务号" min-width="140px" />-->
|
||||
<el-table-column prop="createTime" label="创建时间" :formatter="timeFormat" min-width="120px"/>
|
||||
<el-table-column prop="createTime" label="运行时长" :formatter="dueFormat" min-width="120px"/>
|
||||
<el-table-column prop="userName" label="操作人员姓名" min-width="120px"/>
|
||||
|
|
@ -151,18 +151,26 @@ export default {
|
|||
value: 3,
|
||||
label: '盘点'
|
||||
},
|
||||
{
|
||||
value: 9,
|
||||
label: '移库'
|
||||
},
|
||||
],
|
||||
taskStatusOptions: [
|
||||
{
|
||||
value: 0,
|
||||
label: '任务重置'
|
||||
label: '任务新建'
|
||||
},
|
||||
{
|
||||
value: 1,
|
||||
label: '任务已下发'
|
||||
},
|
||||
{
|
||||
value: 998,
|
||||
label: '任务取消'
|
||||
},
|
||||
{
|
||||
value: 2,
|
||||
value: 100,
|
||||
label: '任务完成'
|
||||
}
|
||||
],
|
||||
|
|
@ -190,9 +198,14 @@ export default {
|
|||
} else {
|
||||
return '入库'
|
||||
}
|
||||
case 2: return '出库'
|
||||
case 3: return '盘点'
|
||||
default: return '未知'
|
||||
case 2:
|
||||
return '出库'
|
||||
case 3:
|
||||
return '盘点'
|
||||
case 9:
|
||||
return '移库'
|
||||
default:
|
||||
return '未知'
|
||||
}
|
||||
},
|
||||
dueFormat: (row, column, cellValue, index) => {
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user