优化
This commit is contained in:
@@ -60,4 +60,12 @@ export function handFinish(jobIds) {
|
||||
})
|
||||
}
|
||||
|
||||
export function confirmOut(thePlatoon,theColumn,theFloor,exitId) {
|
||||
return request({
|
||||
url: '/job/mydoJob/confirmOut',
|
||||
method: 'post',
|
||||
params: { thePlatoon: thePlatoon, theColumn:theColumn,theFloor:theFloor,exitId:exitId}
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -7,17 +7,17 @@
|
||||
|
||||
<div class="right-menu">
|
||||
<template v-if="device!=='mobile'">
|
||||
<el-tooltip :content="$t('top.read')" effect="dark" placement="bottom">
|
||||
<el-button class="right-menu-item hover-effect" :type="plcReadStatus ? 'success' : 'info'" size="mini" @click="togglePlcRead">
|
||||
{{ plcReadStatus ? $t('top.stopRead') : $t('top.startRead') }}
|
||||
</el-button>
|
||||
</el-tooltip>
|
||||
<!-- <el-tooltip :content="$t('top.read')" effect="dark" placement="bottom">-->
|
||||
<!-- <el-button class="right-menu-item hover-effect" :type="plcReadStatus ? 'success' : 'info'" size="mini" @click="togglePlcRead">-->
|
||||
<!-- {{ plcReadStatus ? $t('top.stopRead') : $t('top.startRead') }}-->
|
||||
<!-- </el-button>-->
|
||||
<!-- </el-tooltip>-->
|
||||
|
||||
<el-tooltip :content="$t('top.task')" effect="dark" placement="bottom">
|
||||
<el-button class="right-menu-item hover-effect" :type="plcScheduleStatus ? 'success' : 'info'" size="mini" @click="togglePlcSchedule">
|
||||
{{ plcScheduleStatus ? $t('top.stopTask') : $t('top.startTask') }}
|
||||
</el-button>
|
||||
</el-tooltip>
|
||||
<!-- <el-tooltip :content="$t('top.task')" effect="dark" placement="bottom">-->
|
||||
<!-- <el-button class="right-menu-item hover-effect" :type="plcScheduleStatus ? 'success' : 'info'" size="mini" @click="togglePlcSchedule">-->
|
||||
<!-- {{ plcScheduleStatus ? $t('top.stopTask') : $t('top.startTask') }}-->
|
||||
<!-- </el-button>-->
|
||||
<!-- </el-tooltip>-->
|
||||
|
||||
|
||||
<search id="header-search" class="right-menu-item" />
|
||||
|
||||
@@ -27,102 +27,15 @@
|
||||
@keyup.enter.native="handleQuery"
|
||||
/>
|
||||
</el-form-item>
|
||||
<!-- <el-form-item label="货位ID" prop="cargoSpaceId">-->
|
||||
<!-- <el-input-->
|
||||
<!-- v-model="queryParams.cargoSpaceId"-->
|
||||
<!-- placeholder="请输入货位ID"-->
|
||||
<!-- clearable-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="去向" prop="targetRoadwayId">-->
|
||||
<!-- <el-input-->
|
||||
<!-- v-model="queryParams.targetRoadwayId"-->
|
||||
<!-- placeholder="请输入去向"-->
|
||||
<!-- clearable-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="目标货位ID" prop="targetCargoSpaceId">-->
|
||||
<!-- <el-input-->
|
||||
<!-- v-model="queryParams.targetCargoSpaceId"-->
|
||||
<!-- placeholder="请输入目标货位ID"-->
|
||||
<!-- clearable-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="优先级" prop="priority">-->
|
||||
<!-- <el-input-->
|
||||
<!-- v-model="queryParams.priority"-->
|
||||
<!-- placeholder="请输入优先级"-->
|
||||
<!-- clearable-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="执行阶段" prop="executionPhase">-->
|
||||
<!-- <el-input-->
|
||||
<!-- v-model="queryParams.executionPhase"-->
|
||||
<!-- placeholder="请输入执行阶段"-->
|
||||
<!-- clearable-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="任务类型" prop="inOrOut">-->
|
||||
<!-- <el-input-->
|
||||
<!-- v-model="queryParams.inOrOut"-->
|
||||
<!-- placeholder="请输入任务类型"-->
|
||||
<!-- clearable-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="开始时间" prop="startTime">-->
|
||||
<!-- <el-input-->
|
||||
<!-- v-model="queryParams.startTime"-->
|
||||
<!-- placeholder="请输入开始时间"-->
|
||||
<!-- clearable-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="结束时间" prop="finishTime">-->
|
||||
<!-- <el-input-->
|
||||
<!-- v-model="queryParams.finishTime"-->
|
||||
<!-- placeholder="请输入结束时间"-->
|
||||
<!-- clearable-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="入口ID" prop="entranceId">-->
|
||||
<!-- <el-input-->
|
||||
<!-- v-model="queryParams.entranceId"-->
|
||||
<!-- placeholder="请输入入口ID"-->
|
||||
<!-- clearable-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="出口ID" prop="exitId">-->
|
||||
<!-- <el-input-->
|
||||
<!-- v-model="queryParams.exitId"-->
|
||||
<!-- placeholder="请输入出口ID"-->
|
||||
<!-- clearable-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
<!--<!– <el-form-item label="仓库ID" prop="warehouseId">-->
|
||||
<!-- <el-input-->
|
||||
<!-- v-model="queryParams.warehouseId"-->
|
||||
<!-- placeholder="请输入仓库ID"-->
|
||||
<!-- clearable-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>-->
|
||||
<!-- <el-form-item label="重分标志" prop="faultFlag">-->
|
||||
<!-- <el-input-->
|
||||
<!-- v-model="queryParams.faultFlag"-->
|
||||
<!-- placeholder="请输入重分标志"-->
|
||||
<!-- clearable-->
|
||||
<!-- @keyup.enter.native="handleQuery"-->
|
||||
<!-- />-->
|
||||
<!-- </el-form-item>–>-->
|
||||
<el-form-item label="货位-排" prop="thePlatoon">
|
||||
<el-input v-model="queryParams.thePlatoon" placeholder="请输入货位-排" clearable/>
|
||||
</el-form-item>
|
||||
<el-form-item label="货位-列" prop="theColumn">
|
||||
<el-input v-model="queryParams.theColumn" placeholder="请输入货位-列" clearable/>
|
||||
</el-form-item>
|
||||
<el-form-item label="货位-层" prop="theFloor">
|
||||
<el-input v-model="queryParams.theFloor" placeholder="请输入货位-层" clearable/>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
||||
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
||||
@@ -141,6 +54,17 @@
|
||||
v-hasPermi="['job:mydoJob:OuthandFinish']"
|
||||
>手动完成</el-button>
|
||||
</el-col>
|
||||
|
||||
<el-col :span="1.5">
|
||||
<el-button
|
||||
type="danger"
|
||||
plain
|
||||
icon="el-icon-plus"
|
||||
size="mini"
|
||||
@click="confirmOut"
|
||||
v-hasPermi="['job:mydoJob:confirmOut']"
|
||||
>手动出库</el-button>
|
||||
</el-col>
|
||||
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
|
||||
</el-row>
|
||||
|
||||
@@ -226,17 +150,39 @@
|
||||
<el-form-item label="优先级" prop="priority">
|
||||
<el-input v-model="form.priority" placeholder="请输入优先级" type="number" style="width: 220px"/>
|
||||
</el-form-item>
|
||||
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="submitForm">确 定</el-button>
|
||||
<el-button @click="cancel">取 消</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
<!-- 出口选择弹窗 -->
|
||||
<el-dialog title="选择出口" :visible.sync="exitDialogVisible" width="400px" append-to-body>
|
||||
<el-form ref="exitForm" :model="exitForm" :rules="exitRules" label-width="80px">
|
||||
<el-form-item label="选择出口" prop="exitId">
|
||||
<el-select v-model="exitForm.exitId" placeholder="请选择出口" clearable>
|
||||
<el-option
|
||||
v-for="item in exitOptions"
|
||||
:key="item.exitId"
|
||||
:label="item.exitName"
|
||||
:value="item.exitId"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="submitPointOut">确定</el-button>
|
||||
<el-button @click="cancelExit">取消</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {listMydoJob, getMydoJob, delMydoJob, addMydoJob, updateMydoJob, listMydoJobFinish,handFinish} from "@/api/job/mydoJob"
|
||||
import {listMydoJob, getMydoJob, delMydoJob, addMydoJob, updateMydoJob, listMydoJobFinish,handFinish,confirmOut} from "@/api/job/mydoJob"
|
||||
|
||||
export default {
|
||||
name: "MydoJob",
|
||||
@@ -280,7 +226,10 @@ export default {
|
||||
exitId: null,
|
||||
warehouseId: null,
|
||||
faultFlag: null,
|
||||
trayCode: null
|
||||
trayCode: null,
|
||||
thePlatoon: null,
|
||||
theColumn: null,
|
||||
theFloor: null
|
||||
},
|
||||
// 表单参数
|
||||
form: {},
|
||||
@@ -292,7 +241,25 @@ export default {
|
||||
taskNo: [
|
||||
{ required: true, message: "任务号不能为空", trigger: "blur" }
|
||||
],
|
||||
}
|
||||
},
|
||||
// 出口选择弹窗显示状态
|
||||
exitDialogVisible: false,
|
||||
// 出口表单数据
|
||||
exitForm: {
|
||||
exitId: null
|
||||
},
|
||||
// 出口表单验证规则
|
||||
exitRules: {
|
||||
exitId: [
|
||||
{required: true, message: "请选择出口", trigger: 'change'}
|
||||
]
|
||||
},
|
||||
// 出口选项
|
||||
exitOptions: [
|
||||
{exitId: '1', exitName: '一楼'},
|
||||
{exitId: '2', exitName: '二楼'},
|
||||
|
||||
],
|
||||
}
|
||||
},
|
||||
created() {
|
||||
@@ -424,6 +391,44 @@ export default {
|
||||
this.getList();
|
||||
}).catch(() => {});
|
||||
},
|
||||
confirmOut() {
|
||||
this.loading = true
|
||||
var thePlatoon = this.queryParams.thePlatoon;
|
||||
var theColumn = this.queryParams.theColumn;
|
||||
var theFloor = this.queryParams.theFloor;
|
||||
// 显示出口选择弹窗
|
||||
this.exitDialogVisible = true;
|
||||
this.exitForm.exitId = null;
|
||||
|
||||
if (thePlatoon == null || theColumn == null || theFloor == null) {
|
||||
this.$modal.msgError("请输入货位排列层");
|
||||
return;
|
||||
}
|
||||
},
|
||||
/** 提交指定货位出库 */
|
||||
submitPointOut() {
|
||||
this.$refs["exitForm"].validate(valid => {
|
||||
if (valid) {
|
||||
var thePlatoon = this.queryParams.thePlatoon;
|
||||
var theColumn = this.queryParams.theColumn;
|
||||
var theFloor = this.queryParams.theFloor;
|
||||
|
||||
this.$modal.confirm('是否确认手动出库该货位?').then(() => {
|
||||
return confirmOut(thePlatoon,theColumn,theFloor,this.exitForm.exitId);
|
||||
}).then(() => {
|
||||
this.$modal.msgSuccess("手动出库成功");
|
||||
this.getList();
|
||||
this.exitDialogVisible = false;
|
||||
}).catch(() => {});
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
/** 取消出口选择 */
|
||||
cancelExit() {
|
||||
this.exitDialogVisible = false;
|
||||
this.exitForm.exitId = null;
|
||||
},
|
||||
/** 导出按钮操作 */
|
||||
handleExport() {
|
||||
this.download('job/mydoJob/export', {
|
||||
|
||||
Reference in New Issue
Block a user