盘点差异屏蔽按钮

master
Mr.sun 2 years ago
parent a4ff493251
commit 036cdd90d3
  1. 2
      .env.project
  2. 155
      src/views/libraryManage/inventory/InventoryDifference.vue
  3. 8
      src/views/libraryManage/lockOutStore/index.vue
  4. 151
      src/views/taskManagement/index.vue
  5. 2
      vue.config.js

@ -5,4 +5,4 @@ VUE_APP_TITLE = 管理系统
ENV = 'production' ENV = 'production'
# 管理系统/生产环境 # 管理系统/生产环境
VUE_APP_BASE_API = 'http://192.168.1.199:8040' VUE_APP_BASE_API = 'http://192.168.7.4:8030'

@ -2,7 +2,10 @@
<!-- 盘点差异处理 --> <!-- 盘点差异处理 -->
<div class="app-container"> <div class="app-container">
<div class="search-box"> <div class="search-box">
<el-form :inline="true" :model="enterForm"> <el-form
:inline="true"
:model="enterForm"
>
<el-form-item label="单据编号"> <el-form-item label="单据编号">
<el-input <el-input
v-model="enterForm.invOrderNo" v-model="enterForm.invOrderNo"
@ -11,7 +14,10 @@
></el-input> ></el-input>
</el-form-item> </el-form-item>
<el-form-item label="操作员" prop="userName"> <el-form-item
label="操作员"
prop="userName"
>
<el-select <el-select
v-model="enterForm.userName" v-model="enterForm.userName"
filterable filterable
@ -28,7 +34,10 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item> <el-form-item>
<el-button type="primary" @click="queryTable">搜索</el-button> <el-button
type="primary"
@click="queryTable"
>搜索</el-button>
<el-button @click="resetQuery">重置</el-button> <el-button @click="resetQuery">重置</el-button>
</el-form-item> </el-form-item>
</el-form> </el-form>
@ -36,7 +45,7 @@
<div class="opt-box"> <div class="opt-box">
<div class="opt-box-right"> <div class="opt-box-right">
<el-row :gutter="10"> <el-row :gutter="10">
<el-col :span="1.5"> <!-- <el-col :span="1.5">
<el-button <el-button
type="primary" type="primary"
@click="calce" @click="calce"
@ -51,14 +60,13 @@
:disabled="!handleSelect.length != 0" :disabled="!handleSelect.length != 0"
>取消盘点</el-button >取消盘点</el-button
> >
</el-col> </el-col> -->
<el-col :span="1.5"> <el-col :span="1.5">
<el-button <el-button
type="primary" type="primary"
@click="quren" @click="quren"
:disabled="!handleSelect.length != 0" :disabled="!handleSelect.length != 0"
>盘点确认</el-button >盘点确认</el-button>
>
</el-col> </el-col>
</el-row> </el-row>
</div> </div>
@ -80,28 +88,23 @@
</div> </div>
</template> </template>
<script> <script>
import { mapGetters } from "vuex"; import { mapGetters } from 'vuex'
import { tableConfig } from "./config.js"; import { tableConfig } from './config.js'
import { Debounce, getDictLabel } from "@/utils/index"; import { Debounce, getDictLabel } from '@/utils/index'
import { listUser } from "@/api/libraryManage/common"; import { listUser } from '@/api/libraryManage/common'
import { import { differenceList, generatorCheckInv, confirm, cancel } from '@/api/libraryManage/inventory'
differenceList,
generatorCheckInv,
confirm,
cancel,
} from "@/api/libraryManage/inventory";
export default { export default {
name: "Inventory", name: 'Inventory',
dicts: ["goods_unit", "inv_type_dict"], dicts: ['goods_unit', 'inv_type_dict'],
computed: { computed: {
...mapGetters(["user"]), ...mapGetters(['user'])
}, },
data() { data() {
return { return {
options2: [], // options2: [], //
enterForm: { enterForm: {
invOrderNo: "", invOrderNo: '',
userName: "", userName: ''
}, },
tableData: [], tableData: [],
handleSelect: [], handleSelect: [],
@ -110,125 +113,121 @@ export default {
paging: { paging: {
page: 1, // page: 1, //
size: 10, // size: 10, //
total: 0, total: 0
}, }
}; }
}, },
mounted() {}, mounted() {},
async created() { async created() {
this.tableConfig = await this.getTableHeaderCom( this.tableConfig = await this.getTableHeaderCom('busin_inventory_different', tableConfig.call(this), 'configInventoryDifference')
"busin_inventory_different", await this.getList()
tableConfig.call(this), this.queryTable()
"configInventoryDifference"
);
await this.getList();
this.queryTable();
}, },
methods: { methods: {
/** 查询用户列表 */ /** 查询用户列表 */
async getList() { async getList() {
listUser({}).then((response) => { listUser({}).then((response) => {
this.options2 = response.data; this.options2 = response.data
this.enterForm.userName = this.user.userName; this.enterForm.userName = this.user.userName
}); })
}, },
// //
handleselection(val) { handleselection(val) {
this.handleSelect = val.map((ele) => ele.id); this.handleSelect = val.map((ele) => ele.id)
}, },
// //
resetQuery() { resetQuery() {
this.enterForm = {}; this.enterForm = {}
}, },
// //
queryTable() { queryTable() {
this.loading = true; this.loading = true
differenceList({ differenceList({
pageSize: this.paging.size, pageSize: this.paging.size,
pageNum: this.paging.page, pageNum: this.paging.page,
...this.enterForm, ...this.enterForm
}) })
.then((response) => { .then((response) => {
if (response.code === 200) { if (response.code === 200) {
this.loading = false; this.loading = false
this.paging.total = response.total; this.paging.total = response.total
this.tableData = response.rows; this.tableData = response.rows
} }
}) })
.catch(() => { .catch(() => {
this.loading = false; this.loading = false
}); })
}, },
// //
quren() { quren() {
let obj = { let obj = {
userName: this.enterForm.userName, userName: this.enterForm.userName,
ids: this.handleSelect, ids: this.handleSelect
}; }
confirm(obj) confirm(obj)
.then((response) => { .then((response) => {
if (response.code === 200) { if (response.code === 200) {
this.loading = false; this.loading = false
this.$message({ this.$message({
message: "操作成功!", message: '操作成功!',
type: "success", type: 'success'
}); })
this.queryTable(); this.queryTable()
} }
}) })
.catch(() => { .catch(() => {
this.loading = false; this.loading = false
}); })
}, },
// //
calce() { calce() {
let obj = { let obj = {
userName: this.enterForm.userName, userName: this.enterForm.userName,
ids: this.handleSelect, ids: this.handleSelect
}; }
generatorCheckInv(obj) generatorCheckInv(obj)
.then((response) => { .then((response) => {
if (response.code === 200) { if (response.code === 200) {
this.loading = false; this.loading = false
this.$message({ this.$message({
message: "操作成功!", message: '操作成功!',
type: "success", type: 'success'
}); })
this.queryTable(); this.queryTable()
} }
}) })
.catch(() => { .catch(() => {
this.loading = false; this.loading = false
}); })
}, },
// //
generateThePlan() { generateThePlan() {
this.$confirm("是否确认删除所选明细?", "提示", { this.$confirm('是否确认删除所选明细?', '提示', {
confirmButtonText: "确定", confirmButtonText: '确定',
cancelButtonText: "取消", cancelButtonText: '取消',
type: "warning", type: 'warning'
}).then(async () => { }).then(async () => {
this.remove(); this.remove()
}); })
}, },
// //
remove() { remove() {
cancel(this.handleSelect) cancel(this.handleSelect)
.then((response) => { .then((response) => {
if (response.code === 200) { if (response.code === 200) {
this.loading = false; this.loading = false
this.$message({ this.$message({
message: "操作成功!", message: '操作成功!',
type: "success", type: 'success'
}); })
this.queryTable(); this.queryTable()
} }
}) })
.catch(() => { .catch(() => {
this.loading = false; this.loading = false
}); })
}, }
}, }
}; }
</script> </script>
<style rel="stylesheet/scss" lang="scss" scoped></style> <style rel="stylesheet/scss" lang="scss" scoped></style>

@ -20,7 +20,7 @@
/> />
</el-form-item> </el-form-item>
<el-form-item <!-- <el-form-item
label="批次号" label="批次号"
prop="batch" prop="batch"
> >
@ -38,7 +38,7 @@
> >
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item> -->
<el-button <el-button
type="primary" type="primary"
@ -103,7 +103,7 @@
@keyup.enter.native="handleQuery" @keyup.enter.native="handleQuery"
/> />
</el-form-item> </el-form-item>
<el-form-item <!-- <el-form-item
label="批次号" label="批次号"
prop="batch" prop="batch"
> >
@ -123,7 +123,7 @@
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item> -->
<!-- <el-form-item <!-- <el-form-item
label="叫料位置" label="叫料位置"
prop="trolleyType" prop="trolleyType"

@ -286,7 +286,8 @@ export default {
size: 50, // size: 50, //
total: 0 total: 0
}, },
value1: [moment().locale('zh-cn').format('yyyy-MM-DD 00:00:00'), moment().locale('zh-cn').add(1, 'days').format('yyyy-MM-DD 00:00:00')], // value1: [moment().locale('zh-cn').format('yyyy-MM-DD 00:00:00'), moment().locale('zh-cn').add(1, 'days').format('yyyy-MM-DD 00:00:00')],
value1: [],
// //
devNameArr: [], devNameArr: [],
@ -298,14 +299,6 @@ export default {
istrue: true, istrue: true,
isActive: '' isActive: ''
}, },
// {
// label: '',
// prop: 'isActivity',
// type: 'slot',
// istrue: true,
// name: 'switchChange'
// },
{ {
label: '任务单号', label: '任务单号',
prop: 'taskCode', prop: 'taskCode',
@ -318,25 +311,6 @@ export default {
filter(row, value) { filter(row, value) {
return getDictLabel(value, _that.dict.type.task_status) return getDictLabel(value, _that.dict.type.task_status)
} }
// filter(row) {
// // console.log(row, value)
// // console.log(row)
// if (row.taskStatus == '0') {
// return ''
// } else if (row.taskStatus == '1') {
// return ''
// } else if (row.taskStatus == '2') {
// return ''
// } else if (row.taskStatus == '3') {
// return ''
// } else if (row.taskStatus == '-1') {
// return ''
// } else if (row.taskStatus == '4') {
// return 'ab'
// } else {
// return row.taskStatus
// }
// }
}, },
{ {
label: '任务类型', label: '任务类型',
@ -356,6 +330,11 @@ export default {
prop: 'locationCode', prop: 'locationCode',
istrue: true istrue: true
}, },
{
label: 'rcs/agv下发任务',
prop: 'punchNo',
istrue: true
},
{ {
label: 'AGV目标码头', label: 'AGV目标码头',
prop: 'agvNo', prop: 'agvNo',
@ -378,26 +357,24 @@ export default {
buttons: [ buttons: [
{ {
name: '重新下发', name: '重新下发',
event: 'handleUpdate', event: 'handleUpdate'
disable(row, prop) { // disable(row, prop) {
if (row.taskStatus == '2') { // if (row.taskStatus == '2') {
return true // return true
} else if (row.taskStatus == '0') { // }
return true // }
}
}
}, },
{ {
name: '取消任务', name: '取消任务',
event: 'handleDelete', event: 'handleDelete',
disable(row, prop) { disable(row, prop) {
if (row.taskStatus == '2') { // if (row.taskStatus == '2') {
return true // return true
} else if (row.taskStatus == '0') { // } else if (row.taskStatus == '0') {
return true // return true
} else if (row.taskStatus == '3') { // } else if (row.taskStatus == '3') {
return true // return true
} // }
} }
} }
] ]
@ -477,92 +454,8 @@ export default {
getBasePointGroup().then((res) => { getBasePointGroup().then((res) => {
this.pointGroupNameList = res.data this.pointGroupNameList = res.data
}) })
// getTableHeader('task_management').then((res) => {
// res.data.forEach((item) => {
// item.minWidth = 140
// })
// res.data[4].filter = function (row) {
// if (row.taskType == '0') {
// return ''
// } else if (row.taskType == '1') {
// return ''
// } else if (row.taskType == '2') {
// return ''
// } else {
// return '--'
// }
// }
// res.data[5].filter = function (row) {
// if (row.abnormalStatus == '0') {
// return ''
// } else if (row.abnormalStatus == '1') {
// return ''
// } else {
// return '--'
// }
// }
// res.data[8].filter = function (row) {
// if (row.taskStatus == '0') {
// return ''
// } else if (row.taskStatus == '1') {
// return ''
// } else if (row.taskStatus == '2') {
// return ''
// } else if (row.taskStatus == '3') {
// return ''
// } else {
// return '--'
// }
// }
// res.data[9].filter = function (row) {
// if (row.taskStyle == '0') {
// return 'PDA'
// } else if (row.taskStyle == '1') {
// return 'CTU'
// } else if (row.taskStyle == '2') {
// return 'AGV'
// } else {
// return '--'
// }
// }
// this.tableConfig = [
// ...res.data,
// {
// label: '',
// prop: 'operating',
// istrue: true,
// type: 'button',
// width: 180,
// fixed: 'right',
// buttons: [
// {
// name: '',
// event: 'handleUpdate'
// },
// {
// name: '',
// event: 'handleDelete'
// }
// ]
// }
// ]
// })
},
// },
computed: {
// numCn() {
// const obj = {}
// this.devNameArr.forEach((item, index) => {
// obj[item.devName] = item.devCode
// })
// console.log(obj)
// return obj[this.form.devCode]
// }
}, },
computed: {},
methods: { methods: {
// //
@ -581,7 +474,6 @@ export default {
formatStringToTimestamp(formattedString) { formatStringToTimestamp(formattedString) {
// Date // Date
let date = new Date(formattedString) let date = new Date(formattedString)
// Date // Date
if (!isNaN(date.getTime())) { if (!isNaN(date.getTime())) {
// //
@ -606,7 +498,6 @@ export default {
res.rows = res.rows.sort((a, b) => { res.rows = res.rows.sort((a, b) => {
return this.formatStringToTimestamp(b['createTime']) - this.formatStringToTimestamp(a['createTime']) return this.formatStringToTimestamp(b['createTime']) - this.formatStringToTimestamp(a['createTime'])
}) })
console.log(res.rows)
this.cheshiList = res.rows this.cheshiList = res.rows
this.paging.total = res.total this.paging.total = res.total
this.loading = false this.loading = false

@ -36,7 +36,7 @@ module.exports = {
// detail: https://cli.vuejs.org/config/#devserver-proxy // detail: https://cli.vuejs.org/config/#devserver-proxy
[process.env.VUE_APP_BASE_API]: { [process.env.VUE_APP_BASE_API]: {
// target: `http://127.0.0.1:8031`, // target: `http://127.0.0.1:8031`,
target: `http://127.0.0.1:8031`, target: `http://192.168.7.4:8030`,
// target: `http://192.168.0.110:8030`, // target: `http://192.168.0.110:8030`,
// target: `http://192.168.0.105:8030`, // target: `http://192.168.0.105:8030`,
// target: `http://120.77.94.227:8030`, // target: `http://120.77.94.227:8030`,

Loading…
Cancel
Save