更新
This commit is contained in:
parent
4ba7a55b2e
commit
91d78873a1
@ -1,6 +1,12 @@
|
||||
<template>
|
||||
<div class="mod-config">
|
||||
<el-form style="display: flex; align-items: center; justify-content: right;" :inline="true" :model="dataForm" @keyup.enter.native="getDataList()">
|
||||
<el-form-item>
|
||||
<el-button size="small" type="primary" style="float:left" @click="open()">
|
||||
<icon-svg class="iconClass" name="system"></icon-svg>
|
||||
重置
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<!-- <el-select size="small" v-model="dataForm.paramKey" filterable placeholder="名称">
|
||||
<el-option
|
||||
@ -51,6 +57,18 @@
|
||||
prop="code"
|
||||
label="编码">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="status"
|
||||
label="状态"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<span>{{
|
||||
scope.row.status === 0
|
||||
? "空闲"
|
||||
: "占用"
|
||||
}}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="vehicleAlias"
|
||||
label="缩写">
|
||||
@ -120,6 +138,34 @@
|
||||
this.getDataList()
|
||||
},
|
||||
methods: {
|
||||
open () {
|
||||
this.$confirm('执行此操作前请确定当前没有任务在使用车辆!是否继续?', '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.$http({
|
||||
url: this.$http.adornUrl('/resetStatus'),
|
||||
method: 'post'
|
||||
}).then(({data}) => {
|
||||
if (data && data.code === 0) {
|
||||
this.$message({
|
||||
message: '操作成功',
|
||||
type: 'success',
|
||||
duration: 1500,
|
||||
onClose: () => {
|
||||
this.getDataList()
|
||||
}
|
||||
})
|
||||
}
|
||||
})
|
||||
}).catch(() => {
|
||||
this.$message({
|
||||
type: 'info',
|
||||
message: '已取消操作'
|
||||
})
|
||||
})
|
||||
},
|
||||
// 获取数据列表
|
||||
getDataList () {
|
||||
this.dataListLoading = true
|
||||
|
@ -2,7 +2,7 @@
|
||||
* @Author: zwq
|
||||
* @Date: 2021-11-15 15:17:30
|
||||
* @LastEditors: zwq
|
||||
* @LastEditTime: 2022-03-18 15:00:32
|
||||
* @LastEditTime: 2022-07-08 23:18:46
|
||||
* @Description:
|
||||
-->
|
||||
<template>
|
||||
@ -34,9 +34,9 @@
|
||||
</el-card>
|
||||
<el-card class="base-container" style="margin-top: 20px; min-height: 200px">
|
||||
<el-row :gutter="30" style="padding: 20px;">
|
||||
<el-col class="footer-item-container" :span="6" v-for="count in 4" :key="count">
|
||||
<el-col class="footer-item-container" :span="6" v-for="count in 2" :key="count">
|
||||
<el-card class="footer-item-box base-container" @click.native="selectPlat(count)">
|
||||
<div class="plat" style="font-size: 24px">液压台{{ count }}</div>
|
||||
<div class="plat" style="font-size: 24px">出库液压台{{ count }}</div>
|
||||
</el-card>
|
||||
</el-col>
|
||||
</el-row>
|
||||
@ -63,7 +63,7 @@ export default {
|
||||
components: {
|
||||
ExWarehouseInfo
|
||||
},
|
||||
created () {
|
||||
activated () {
|
||||
this.getWarehouseList()
|
||||
},
|
||||
methods: {
|
||||
|
@ -2,31 +2,77 @@
|
||||
<el-dialog
|
||||
:title="!row ? '新增' : '修改'"
|
||||
:close-on-click-modal="false"
|
||||
:visible.sync="visible">
|
||||
<el-form :model="dataForm" v-loading="formLoading" :rules="dataRule" ref="dataForm" label-width="80px">
|
||||
:visible.sync="visible"
|
||||
>
|
||||
<el-form
|
||||
:model="dataForm"
|
||||
v-loading="formLoading"
|
||||
:rules="dataRule"
|
||||
ref="dataForm"
|
||||
label-width="80px"
|
||||
>
|
||||
<el-form-item label="标识卡号" prop="idenCardNum">
|
||||
<el-input v-model="dataForm.idenCardNum" @change="setIdenCardNum" ref="idenCardNum" placeholder="标识卡号"></el-input>
|
||||
<el-input
|
||||
v-model="dataForm.idenCardNum"
|
||||
@change="setIdenCardNum"
|
||||
ref="idenCardNum"
|
||||
placeholder="标识卡号"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="客户名称" prop="customerName">
|
||||
<el-input v-model="dataForm.customerName" disabled placeholder="客户名称"></el-input>
|
||||
<el-input
|
||||
v-model="dataForm.customerName"
|
||||
disabled
|
||||
placeholder="客户名称"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="材料牌号" prop="materialDes">
|
||||
<el-input v-model="dataForm.materialDes" disabled placeholder="材料牌号"></el-input>
|
||||
<el-input
|
||||
v-model="dataForm.materialDes"
|
||||
disabled
|
||||
placeholder="材料牌号"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="订单号" prop="orderNo">
|
||||
<el-input v-model="dataForm.orderNo" disabled placeholder="订单号"></el-input>
|
||||
<el-input
|
||||
v-model="dataForm.orderNo"
|
||||
disabled
|
||||
placeholder="订单号"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="产品名称" prop="productName">
|
||||
<el-input v-model="dataForm.productName" disabled placeholder="产品名称"></el-input>
|
||||
<el-input
|
||||
v-model="dataForm.productName"
|
||||
disabled
|
||||
placeholder="产品名称"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="数量" prop="quantity">
|
||||
<el-input v-model="dataForm.quantity" placeholder="数量"></el-input>
|
||||
<el-input
|
||||
v-model="dataForm.quantity"
|
||||
:max="dataForm.quantity - dataForm.finishQuantity"
|
||||
@change="changes"
|
||||
oninput = "value=value.replace(/[^\d.]/g,'')"
|
||||
type="number"
|
||||
placeholder="数量"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="单位" prop="unit">
|
||||
<el-input v-model="dataForm.unit" disabled placeholder="单位"></el-input>
|
||||
<el-input
|
||||
v-model="dataForm.unit"
|
||||
disabled
|
||||
placeholder="单位"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="重量" prop="weight">
|
||||
<el-input v-model="dataForm.weight" placeholder="重量"></el-input>
|
||||
<el-input
|
||||
v-model="dataForm.weight"
|
||||
type="number"
|
||||
:max="dataForm.targetWeight - dataForm.finishWeight"
|
||||
@change="changeWeight"
|
||||
oninput = "value=value.replace(/[^\d.]/g,'')"
|
||||
placeholder="重量"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
@ -37,7 +83,7 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
export default {
|
||||
data () {
|
||||
return {
|
||||
visible: false,
|
||||
@ -47,8 +93,10 @@
|
||||
materialDes: null,
|
||||
orderNo: null,
|
||||
productName: null,
|
||||
targetQuantity: null,
|
||||
quantity: null,
|
||||
unit: null,
|
||||
targetWeight: null,
|
||||
weight: null
|
||||
},
|
||||
dataRule: {
|
||||
@ -58,9 +106,7 @@
|
||||
quantity: [
|
||||
{ required: true, message: '数量不能为空', trigger: 'blur' }
|
||||
],
|
||||
weight: [
|
||||
{ required: true, message: '重量不能为空', trigger: 'blur' }
|
||||
]
|
||||
weight: [{ required: true, message: '重量不能为空', trigger: 'blur' }]
|
||||
},
|
||||
formLoading: false,
|
||||
row: null,
|
||||
@ -68,6 +114,16 @@
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
changes (value) {
|
||||
if (value > this.dataForm.quantity - this.dataForm.finishQuantity) {
|
||||
this.dataForm.quantity = this.dataForm.quantity - this.dataForm.finishQuantity
|
||||
}
|
||||
},
|
||||
changeWeight (value) {
|
||||
if (value > this.dataForm.targetWeight - this.dataForm.finishWeight) {
|
||||
this.dataForm.weight = this.dataForm.targetWeight - this.dataForm.finishWeight
|
||||
}
|
||||
},
|
||||
init (row, idx) {
|
||||
this.visible = true
|
||||
this.formLoading = false
|
||||
@ -88,10 +144,9 @@
|
||||
url: this.$http.adornUrl(`/orderInfo/getTaskInfoByIdenCardNum`),
|
||||
method: 'get',
|
||||
params: this.$http.adornParams({
|
||||
'idenCardNum': this.dataForm.idenCardNum
|
||||
idenCardNum: this.dataForm.idenCardNum
|
||||
})
|
||||
}).then(({data}) => {
|
||||
console.log(data)
|
||||
}).then(({ data }) => {
|
||||
if (data && data.code === 0) {
|
||||
this.dataForm = data.data
|
||||
this.dataForm.targetQuantity = data.data.quantity
|
||||
@ -109,7 +164,7 @@
|
||||
},
|
||||
// 表单提交
|
||||
dataFormSubmit () {
|
||||
this.$refs['dataForm'].validate((valid) => {
|
||||
this.$refs['dataForm'].validate(valid => {
|
||||
if (valid) {
|
||||
if (this.editIndex || this.editIndex === 0) {
|
||||
const taskList = JSON.parse(sessionStorage.getItem('autoTaskList'))
|
||||
@ -136,5 +191,5 @@
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
@ -2,7 +2,7 @@
|
||||
* @Author: gtz
|
||||
* @Date: 2022-03-04 10:22:13
|
||||
* @LastEditors: zwq
|
||||
* @LastEditTime: 2022-07-08 09:41:08
|
||||
* @LastEditTime: 2022-07-08 23:10:55
|
||||
* @Description: file content
|
||||
* @FilePath: \mt-qj-wms-ui\src\views\common\order-auto-submit.vue
|
||||
-->
|
||||
@ -15,7 +15,7 @@
|
||||
<el-form :model="dataForm" v-loading="formLoading" :rules="dataRule" ref="dataForm" label-width="120px">
|
||||
<el-form-item label="自动任务类型" prop="autoTaskType">
|
||||
<el-select v-model="dataForm.autoTaskType" clearable @change="changeAutoTaskType">
|
||||
<el-option :value="1" label="淡化炉加工"></el-option>
|
||||
<el-option :value="1" label="氮化炉加工"></el-option>
|
||||
<el-option :value="2" label="多功能炉加工"></el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
@ -55,11 +55,11 @@
|
||||
<el-option v-for="item in kilnList" :key="item.id" :value="item.id + ',' + item.code" :label="item.kilnName" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="工艺" prop="secProcess" style="margin-bottom: 24px">
|
||||
<!-- <el-form-item label="工艺" prop="secProcess" style="margin-bottom: 24px">
|
||||
<el-select v-model="dataForm.secProcess" :disabled="!(dataForm.autoTaskType)">
|
||||
<el-option v-for="item in processList" :key="item.id" :value="item.code" :label="item.craftCode" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form-item> -->
|
||||
</el-form-item>
|
||||
<el-form-item label="结束加工炉">
|
||||
<el-form-item label="加工炉" prop="thirdPosition" style="margin-bottom: 24px">
|
||||
@ -76,7 +76,7 @@
|
||||
</el-form>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button @click="visible = false">取消</el-button>
|
||||
<el-button type="primary" @click="dataFormSubmit()">确定</el-button>
|
||||
<el-button type="primary" :loading="btnLoad" @click="dataFormSubmit()">确定</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</template>
|
||||
@ -96,6 +96,7 @@
|
||||
data () {
|
||||
return {
|
||||
visible: false,
|
||||
btnLoad: false,
|
||||
dataForm: {
|
||||
autoTaskType: null,
|
||||
processType: null,
|
||||
@ -103,7 +104,7 @@
|
||||
firstPosition: null,
|
||||
firstProcess: null,
|
||||
secPosition: null,
|
||||
secProcess: null,
|
||||
secProcess: 1,
|
||||
thirdPosition: null,
|
||||
thirdProcess: null
|
||||
},
|
||||
@ -126,9 +127,6 @@
|
||||
secPosition: [
|
||||
{ required: true, message: '加工炉不能为空', trigger: 'blur' }
|
||||
],
|
||||
secProcess: [
|
||||
{ required: true, message: '工艺不能为空', trigger: 'blur' }
|
||||
],
|
||||
thirdPosition: [
|
||||
{ required: true, message: '加工炉不能为空', trigger: 'blur' }
|
||||
],
|
||||
@ -146,6 +144,7 @@
|
||||
init (list) {
|
||||
this.dataList.splice(0, this.dataList.length)
|
||||
this.dataList = list
|
||||
this.btnLoad = false
|
||||
this.visible = true
|
||||
this.$nextTick(() => {
|
||||
this.$refs['dataForm'].resetFields()
|
||||
@ -156,7 +155,7 @@
|
||||
this.dataForm.firstPosition = null
|
||||
this.dataForm.firstProcess = null
|
||||
this.dataForm.secPosition = null
|
||||
this.dataForm.secProcess = null
|
||||
this.dataForm.secProcess = 1
|
||||
this.dataForm.thirdPosition = null
|
||||
this.dataForm.thirdProcess = null
|
||||
},
|
||||
@ -246,24 +245,26 @@
|
||||
targetPosition: this.dataForm.thirdPosition.split(',')[1]
|
||||
})
|
||||
}
|
||||
this.btnLoad = true
|
||||
this.$http({
|
||||
url: this.$http.adornUrl(`/currTask/createAutoTask`),
|
||||
method: 'post',
|
||||
data: this.$http.adornData(requestData)
|
||||
}).then(({data}) => {
|
||||
console.log(data)
|
||||
if (data && data.code === 0) {
|
||||
this.$message({
|
||||
message: '操作成功',
|
||||
type: 'success',
|
||||
duration: 1500,
|
||||
onClose: () => {
|
||||
this.btnLoad = false
|
||||
this.visible = false
|
||||
sessionStorage.setItem('autoTaskList', '')
|
||||
this.$emit('refreshDataList')
|
||||
}
|
||||
})
|
||||
} else {
|
||||
this.btnLoad = false
|
||||
this.$message.warning(data.msg)
|
||||
}
|
||||
})
|
||||
|
@ -34,7 +34,7 @@
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item style="margin-left:1%">
|
||||
<el-button type="primary" size="small" @click="submitTask()">提交任务</el-button>
|
||||
<el-button type="primary" size="small" :loading="btnLoad" @click="submitTask()">提交任务</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<el-table
|
||||
@ -120,6 +120,7 @@
|
||||
export default {
|
||||
data () {
|
||||
return {
|
||||
btnLoad: false,
|
||||
startPosition: '',
|
||||
kilnId: '',
|
||||
craftCode: '',
|
||||
@ -229,6 +230,7 @@
|
||||
} else if (this.processType !== 0 && this.processType !== 1) {
|
||||
this.$message.warning('请选择加工类型')
|
||||
} else {
|
||||
this.btnLoad = true
|
||||
this.$confirm(`确定提交任务?`, '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
@ -249,12 +251,14 @@
|
||||
}).then(({data}) => {
|
||||
if (data && data.code === 0) {
|
||||
this.$message.success('任务提交成功')
|
||||
this.btnLoad = false
|
||||
this.dataList = []
|
||||
sessionStorage.setItem('taskList', '')
|
||||
this.startPosition = '选择起点'
|
||||
this.kilnId = '选择窑炉'
|
||||
this.targetPosition = null
|
||||
} else {
|
||||
this.btnLoad = false
|
||||
this.$message.warning(data.msg)
|
||||
}
|
||||
})
|
||||
|
@ -73,10 +73,6 @@
|
||||
prop="weight"
|
||||
label="物料重量">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="waitWeight"
|
||||
label="实际重量">
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
fixed="right"
|
||||
header-align="center"
|
||||
@ -174,7 +170,7 @@
|
||||
components: {
|
||||
orderDetail
|
||||
},
|
||||
created () {
|
||||
activated () {
|
||||
this.getDataList()
|
||||
},
|
||||
methods: {
|
||||
|
@ -158,7 +158,7 @@ export default {
|
||||
statusList
|
||||
}
|
||||
},
|
||||
created () {
|
||||
activated () {
|
||||
this.getDataList()
|
||||
this.timer = setInterval(this.getDataList, 180000)
|
||||
},
|
||||
|
@ -94,7 +94,7 @@
|
||||
carList: []
|
||||
}
|
||||
},
|
||||
created () {
|
||||
activated () {
|
||||
this.getCarList()
|
||||
},
|
||||
methods: {
|
||||
|
@ -102,7 +102,7 @@ export default {
|
||||
kilnList: []
|
||||
}
|
||||
},
|
||||
created () {
|
||||
activated () {
|
||||
this.getKilnList()
|
||||
},
|
||||
methods: {
|
||||
|
@ -86,12 +86,12 @@
|
||||
<template slot-scope="scope">
|
||||
<span>{{
|
||||
scope.row.taskType === 0
|
||||
? "缓存到窑炉加工"
|
||||
? "入库到窑炉"
|
||||
: scope.row.taskType === 1
|
||||
? "出炉到缓存"
|
||||
? "入库到缓存"
|
||||
: scope.row.taskType === 2
|
||||
? "缓存出库"
|
||||
: "入库缓存"
|
||||
? "窑炉出库到缓存区"
|
||||
: "缓存区出库"
|
||||
}}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
@ -173,7 +173,7 @@ export default {
|
||||
statusList
|
||||
}
|
||||
},
|
||||
created () {
|
||||
activated () {
|
||||
this.getDataList()
|
||||
},
|
||||
methods: {
|
||||
|
Loading…
Reference in New Issue
Block a user