|
|
|
@ -3,7 +3,6 @@
|
|
|
|
|
|
|
|
|
|
<el-form :model="formData" :rules="formRules" ref="dataForm">
|
|
|
|
|
<el-button-group style="display: flex;margin: -50px 0 10px 80%; height: 35px">
|
|
|
|
|
|
|
|
|
|
<el-button
|
|
|
|
|
type="primary"
|
|
|
|
|
@click.native="saveOrder()"
|
|
|
|
@ -17,7 +16,6 @@
|
|
|
|
|
</el-button
|
|
|
|
|
>
|
|
|
|
|
</el-button-group>
|
|
|
|
|
|
|
|
|
|
<el-row :gutter="20">
|
|
|
|
|
<el-col :span="2">
|
|
|
|
|
<div class="ao-text">
|
|
|
|
@ -49,7 +47,6 @@
|
|
|
|
|
</el-col>
|
|
|
|
|
</el-row>
|
|
|
|
|
<el-row :gutter="20">
|
|
|
|
|
|
|
|
|
|
<el-col :span="2">
|
|
|
|
|
<div class="ao-text">
|
|
|
|
|
<span>单据类型:</span>
|
|
|
|
@ -73,28 +70,29 @@
|
|
|
|
|
|
|
|
|
|
<el-col :span="2">
|
|
|
|
|
<div class="ao-text">
|
|
|
|
|
<span>当前分库:</span>
|
|
|
|
|
<span>当前仓库:</span>
|
|
|
|
|
</div>
|
|
|
|
|
</el-col>
|
|
|
|
|
|
|
|
|
|
<el-col :span="8">
|
|
|
|
|
<el-form-item prop="invWarehouseCode">
|
|
|
|
|
<el-select v-model="formData.invWarehouseCode" placeholder="当前分库信息"
|
|
|
|
|
:disabled="corpOrderIdDisabled" @change="findSubStorageMethod" filterable>
|
|
|
|
|
<el-select v-model="formData.invWarehouseCode" placeholder="当前仓库信息"
|
|
|
|
|
:disabled="corpOrderIdDisabled" @change="findSubStorageMethod" filterable>
|
|
|
|
|
<el-option
|
|
|
|
|
v-for="item in subInvList"
|
|
|
|
|
:key="item.name"
|
|
|
|
|
:label="item.name"
|
|
|
|
|
:value="item.code">
|
|
|
|
|
<span style="float: left">{{ item.name }}</span>
|
|
|
|
|
<span style="float: right; color: #8492a6; font-size: 13px">{{ item.warehouseName }}</span>
|
|
|
|
|
<span style="float: right; color: #8492a6; font-size: 13px">{{
|
|
|
|
|
item.warehouseName
|
|
|
|
|
}}</span>
|
|
|
|
|
</el-option>
|
|
|
|
|
</el-select>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</el-col>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</el-row>
|
|
|
|
|
|
|
|
|
|
<el-row :gutter="20">
|
|
|
|
@ -120,6 +118,7 @@
|
|
|
|
|
:loading="loading"
|
|
|
|
|
:disabled="corpOrderIdDisabled"
|
|
|
|
|
@change="unitChange"
|
|
|
|
|
@focus="findMethod('')"
|
|
|
|
|
>
|
|
|
|
|
<el-option
|
|
|
|
|
v-for="item in fromOptions"
|
|
|
|
@ -135,8 +134,8 @@
|
|
|
|
|
v-if="curAction.corpType ==1"
|
|
|
|
|
>
|
|
|
|
|
|
|
|
|
|
<el-select v-model="formData.fromSubInvCode" placeholder="请选择仓库" clearable="true"
|
|
|
|
|
:disabled="corpOrderIdDisabled" @change="getFormCorp" filterable
|
|
|
|
|
<el-select v-model="formData.fromSubInvCode" placeholder="请选择分库" clearable="true"
|
|
|
|
|
:disabled="corpOrderIdDisabled" filterable @change="getFormStorageCode"
|
|
|
|
|
>
|
|
|
|
|
<el-option
|
|
|
|
|
v-for="item in fromSubStorageOptions"
|
|
|
|
@ -144,7 +143,9 @@
|
|
|
|
|
:label="item.name"
|
|
|
|
|
:value="item.code">
|
|
|
|
|
<span style="float: left">{{ item.name }}</span>
|
|
|
|
|
<span style="float: right; color: #8492a6; font-size: 13px">{{ item.warehouseName }}</span>
|
|
|
|
|
<span style="float: right; color: #8492a6; font-size: 13px">{{
|
|
|
|
|
item.warehouseName
|
|
|
|
|
}}</span>
|
|
|
|
|
<!--<span style="float: right; color: #8492a6; font-size: 13px">{{ item.action }}</span>-->
|
|
|
|
|
</el-option>
|
|
|
|
|
</el-select>
|
|
|
|
@ -158,7 +159,10 @@
|
|
|
|
|
placeholder="请输入病人住院号"
|
|
|
|
|
></el-input>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
|
|
|
|
|
</el-col>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</el-row>
|
|
|
|
|
|
|
|
|
|
<el-row :gutter="20" v-if="enableDept">
|
|
|
|
@ -194,27 +198,27 @@
|
|
|
|
|
</el-row>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<!-- <el-row :gutter="20">-->
|
|
|
|
|
<!-- <el-col :span="20" class="el-col">-->
|
|
|
|
|
<!-- <div class="text item">-->
|
|
|
|
|
<!-- <el-checkbox v-model="formData.outChangeEnable"-->
|
|
|
|
|
<!-- :disabled="!curAction.changeEnable || corpOrderIdDisabled">允许出库自动缺量补单-->
|
|
|
|
|
<!-- </el-checkbox>-->
|
|
|
|
|
|
|
|
|
|
<!-- <el-checkbox v-model="formData.preCheck"-->
|
|
|
|
|
<!-- :disabled="corpOrderIdDisabled || curAction.corpType !=2"-->
|
|
|
|
|
<!-- >出入库必须校验预验收库-->
|
|
|
|
|
<!-- </el-checkbox>-->
|
|
|
|
|
<!-- <el-checkbox v-model="formData.vailInv"-->
|
|
|
|
|
<!-- >是否查询库存-->
|
|
|
|
|
<!-- </el-checkbox>-->
|
|
|
|
|
<!-- <el-checkbox v-model="formData.codeFillCheck"-->
|
|
|
|
|
<!-- >采集UDI码时进行三期校验-->
|
|
|
|
|
<!-- </el-checkbox>-->
|
|
|
|
|
<!-- </div>-->
|
|
|
|
|
|
|
|
|
|
<!-- </el-col>-->
|
|
|
|
|
<!-- </el-row>-->
|
|
|
|
|
<!-- <el-row :gutter="20">-->
|
|
|
|
|
<!-- <el-col :span="20" class="el-col">-->
|
|
|
|
|
<!-- <div class="text item">-->
|
|
|
|
|
<!-- <el-checkbox v-model="formData.outChangeEnable"-->
|
|
|
|
|
<!-- :disabled="!curAction.changeEnable || corpOrderIdDisabled">允许出库自动缺量补单-->
|
|
|
|
|
<!-- </el-checkbox>-->
|
|
|
|
|
|
|
|
|
|
<!-- <el-checkbox v-model="formData.preCheck"-->
|
|
|
|
|
<!-- :disabled="corpOrderIdDisabled || curAction.corpType !=2"-->
|
|
|
|
|
<!-- >出入库必须校验预验收库-->
|
|
|
|
|
<!-- </el-checkbox>-->
|
|
|
|
|
<!-- <el-checkbox v-model="formData.vailInv"-->
|
|
|
|
|
<!-- >是否查询库存-->
|
|
|
|
|
<!-- </el-checkbox>-->
|
|
|
|
|
<!-- <el-checkbox v-model="formData.codeFillCheck"-->
|
|
|
|
|
<!-- >采集UDI码时进行三期校验-->
|
|
|
|
|
<!-- </el-checkbox>-->
|
|
|
|
|
<!-- </div>-->
|
|
|
|
|
|
|
|
|
|
<!-- </el-col>-->
|
|
|
|
|
<!-- </el-row>-->
|
|
|
|
|
<el-row :gutter="20" style="margin-top: 12px">
|
|
|
|
|
<el-col :span="2">
|
|
|
|
|
<div class="ao-text">
|
|
|
|
@ -246,12 +250,9 @@
|
|
|
|
|
</el-button
|
|
|
|
|
>
|
|
|
|
|
</el-col>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</el-row>
|
|
|
|
|
<el-row :gutter="20">
|
|
|
|
|
<el-col :span="14" style="margin-left: 40px">
|
|
|
|
|
|
|
|
|
|
</el-col>
|
|
|
|
|
<el-col :span="3">
|
|
|
|
|
<div class="text item" style="margin-left: 30px"> 条码数量:{{ total }}
|
|
|
|
@ -357,6 +358,8 @@
|
|
|
|
|
<el-dialog
|
|
|
|
|
:title="selectUnitTitle"
|
|
|
|
|
:visible.sync="dialogTableVisible"
|
|
|
|
|
:close-on-click-modal="false"
|
|
|
|
|
:close-on-press-escape="false"
|
|
|
|
|
v-if="dialogTableVisible"
|
|
|
|
|
width="70%"
|
|
|
|
|
append-to-body
|
|
|
|
@ -371,6 +374,8 @@
|
|
|
|
|
:title="selectRlTitle"
|
|
|
|
|
:visible.sync="selectRlVisible"
|
|
|
|
|
width="80%"
|
|
|
|
|
:close-on-click-modal="false"
|
|
|
|
|
:close-on-press-escape="false"
|
|
|
|
|
v-if="selectRlVisible"
|
|
|
|
|
append-to-body
|
|
|
|
|
>
|
|
|
|
@ -385,9 +390,9 @@
|
|
|
|
|
<el-dialog
|
|
|
|
|
:title="editTitle"
|
|
|
|
|
:visible.sync="editCodeVisible"
|
|
|
|
|
append-to-body width="70%"
|
|
|
|
|
:close-on-click-modal="false"
|
|
|
|
|
:close-on-press-escape="false"
|
|
|
|
|
append-to-body width="70%"
|
|
|
|
|
v-if="editCodeVisible"
|
|
|
|
|
>
|
|
|
|
|
<editCodeDialog
|
|
|
|
@ -401,6 +406,8 @@
|
|
|
|
|
:title="editTitle"
|
|
|
|
|
:visible.sync="editOriginCodeVisible"
|
|
|
|
|
append-to-body width="70%"
|
|
|
|
|
:close-on-click-modal="false"
|
|
|
|
|
:close-on-press-escape="false"
|
|
|
|
|
v-if="editOriginCodeVisible">
|
|
|
|
|
<editCodeDialog
|
|
|
|
|
:closeCodeDialog="closeCodeDialog"
|
|
|
|
@ -432,6 +439,7 @@ import selectRlDialog from "./DialogSelectRl";
|
|
|
|
|
import editCodeDialog from "./editCode";
|
|
|
|
|
import A from "../../plugin/KeyScaner"
|
|
|
|
|
import {isBlank} from "@/utils/strUtil";
|
|
|
|
|
import {filterDepts} from "@/api/auth/authDept";
|
|
|
|
|
import {selectSysParamByKey} from "@/api/param/systemParamConfig";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@ -484,6 +492,7 @@ export default {
|
|
|
|
|
codeFillCheck: null,
|
|
|
|
|
vailInv: null,
|
|
|
|
|
deptCode: null,
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
editOriginCodeVisible: false,
|
|
|
|
|
curId: null,
|
|
|
|
@ -506,6 +515,7 @@ export default {
|
|
|
|
|
deleteLoading: false,
|
|
|
|
|
orderNo: null,
|
|
|
|
|
fromOptions: [],
|
|
|
|
|
fromStorageOptions: [],
|
|
|
|
|
fromSubStorageOptions: [],
|
|
|
|
|
curAction: {
|
|
|
|
|
corpType: 0,
|
|
|
|
@ -522,6 +532,7 @@ export default {
|
|
|
|
|
checkSuccess: false,
|
|
|
|
|
codeDetail: null,
|
|
|
|
|
editTitle: "编辑条码",
|
|
|
|
|
fromDeptOptions: [],
|
|
|
|
|
enableDept: false
|
|
|
|
|
};
|
|
|
|
|
},
|
|
|
|
@ -540,14 +551,13 @@ export default {
|
|
|
|
|
orderId: this.idQuery.id,
|
|
|
|
|
locStorageCode: this.formData.locStorageCode,
|
|
|
|
|
invWarehouseCode: this.formData.invWarehouseCode,
|
|
|
|
|
invStorageCode:this.formData.invStorageCode,
|
|
|
|
|
fromSubInvCode: this.formData.fromSubInvCode,
|
|
|
|
|
subInvCode: this.formData.subInvCode,
|
|
|
|
|
action: this.formData.action,
|
|
|
|
|
fromCorp: this.formData.fromCorp,
|
|
|
|
|
fromCorpId: this.formData.fromCorpId,
|
|
|
|
|
outChangeEnable: this.formData.outChangeEnable,
|
|
|
|
|
preCheck: this.formData.preCheck,
|
|
|
|
|
deptCode: this.formData.deptCode,
|
|
|
|
|
}
|
|
|
|
|
submitOrderWeb(tQuery)
|
|
|
|
|
.then((response) => {
|
|
|
|
@ -561,11 +571,16 @@ export default {
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
saveOrder() {
|
|
|
|
|
if (this.total < 1) {
|
|
|
|
|
this.$message.error('未添加条码');
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
if (this.formData.action == null || this.formData.action == '') {
|
|
|
|
|
this.$message.error('未选择扫码单据类型');
|
|
|
|
|
return
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (this.formData.invWarehouseCode == null || this.formData.invWarehouseCode == '') {
|
|
|
|
|
this.$message.error('当前分库不能为空');
|
|
|
|
|
return;
|
|
|
|
@ -583,7 +598,6 @@ export default {
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
closeCodeDialog() {
|
|
|
|
|
//编辑完,获取编辑之后的条码
|
|
|
|
|
this.editCodeVisible = false;
|
|
|
|
|
this.editOriginCodeVisible = false;
|
|
|
|
|
this.getCodeList();
|
|
|
|
@ -610,7 +624,6 @@ export default {
|
|
|
|
|
code: this.formData.code.trim(),
|
|
|
|
|
}
|
|
|
|
|
enterCodeWeb(tQuery).then((response) => {
|
|
|
|
|
|
|
|
|
|
if (response.code === 20000) {
|
|
|
|
|
this.$refs.inputRef.focus();
|
|
|
|
|
this.$refs.inputRef.select();
|
|
|
|
@ -643,6 +656,7 @@ export default {
|
|
|
|
|
} else if (response.code == 508) {
|
|
|
|
|
this.originCode = "";
|
|
|
|
|
this.formData.code = "01" + response.data.nameCode;
|
|
|
|
|
this.originCode = this.formData.code;
|
|
|
|
|
} else {
|
|
|
|
|
this.$alert(response.message, '提示', {
|
|
|
|
|
confirmButtonText: '确定',
|
|
|
|
@ -659,7 +673,6 @@ export default {
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
addCode(event) {
|
|
|
|
|
|
|
|
|
|
this.originCode = "";
|
|
|
|
|
this.sictomText = "";
|
|
|
|
|
this.formData.corpOrderId = this.formData.corpOrderId.trim();
|
|
|
|
@ -667,10 +680,9 @@ export default {
|
|
|
|
|
this.formData.produceDate = "";
|
|
|
|
|
this.formData.expireDate = "";
|
|
|
|
|
this.formData.serialNo = "";
|
|
|
|
|
if (event != null) {
|
|
|
|
|
event.target.select();
|
|
|
|
|
}
|
|
|
|
|
this.actionEnable = true;
|
|
|
|
|
if (event == null) {
|
|
|
|
|
} else event.target.select();
|
|
|
|
|
this.$refs.inputRef.select();
|
|
|
|
|
if (this.$isBlank(this.formData.action)) {
|
|
|
|
|
this.$message.warning("请选择单据类型!");
|
|
|
|
@ -682,11 +694,6 @@ export default {
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// if (this.$isBlank(this.formData.fromCorp)) {
|
|
|
|
|
// this.$message.error('当前往来单位不能为空');
|
|
|
|
|
// return;
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
if (this.curAction.corpType == 1) {
|
|
|
|
|
if (this.$isBlank(this.formData.fromSubInvCode)) {
|
|
|
|
|
this.$message.error('当前往来分库不能为空');
|
|
|
|
@ -720,7 +727,6 @@ export default {
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
addCodeSubmit(tQuery) {
|
|
|
|
|
|
|
|
|
|
addOrderWeb(tQuery).then((response) => {
|
|
|
|
|
if (response.code === 20000) {
|
|
|
|
|
this.idQuery.id = response.data.orderId;
|
|
|
|
@ -774,8 +780,8 @@ export default {
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
} else if (response.code == 507) {
|
|
|
|
|
this.editTitle = response.message;
|
|
|
|
|
this.editOriginCodeVisible = true;
|
|
|
|
|
this.editTitle = response.message;
|
|
|
|
|
this.formData.produceDate = response.data.produceDate;
|
|
|
|
|
this.formData.expireDate = response.data.expireDate;
|
|
|
|
|
this.formData.batchNo = response.data.batchNo;
|
|
|
|
@ -786,6 +792,10 @@ export default {
|
|
|
|
|
message: "提交失败!" + this.editTitle,
|
|
|
|
|
customClass: 'messageIndex'
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
// this.$message.error("提交失败!" + this.editTitle);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} else {
|
|
|
|
|
this.$alert(response.message, '提示', {
|
|
|
|
|
confirmButtonText: '确定',
|
|
|
|
@ -793,6 +803,7 @@ export default {
|
|
|
|
|
closeOnClickModal: true,
|
|
|
|
|
callback: action => {
|
|
|
|
|
this.$refs.inputRef.focus();
|
|
|
|
|
this.$refs.inputRef.select();
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
@ -806,13 +817,14 @@ export default {
|
|
|
|
|
this.formData.fromCorp = row.name;
|
|
|
|
|
this.curRow = row;
|
|
|
|
|
},
|
|
|
|
|
storageChange(row) {
|
|
|
|
|
this.formData.fromSubInvCode = "";
|
|
|
|
|
this.formData.fromCorpId = row.code;
|
|
|
|
|
getFormStorageCode(code) {
|
|
|
|
|
var row= this.fromSubStorageOptions.find(item => item.code == code)
|
|
|
|
|
this.formData.fromSubInvCode = row.code
|
|
|
|
|
this.formData.fromCorpId = row.parentId;
|
|
|
|
|
this.formData.fromCorp = row.name;
|
|
|
|
|
this.findSubStorageMethod();
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
deleteCode(index, row) {
|
|
|
|
|
this.$confirm("是否确定移除一个条码?", "提示", {
|
|
|
|
|
confirmButtonText: "确定",
|
|
|
|
@ -876,53 +888,48 @@ export default {
|
|
|
|
|
this.$router.go(-1);
|
|
|
|
|
},
|
|
|
|
|
getBusType() {
|
|
|
|
|
this.formData.billType=null;
|
|
|
|
|
let query = {
|
|
|
|
|
code: this.formData.invWarehouseCode,
|
|
|
|
|
enabled: true,
|
|
|
|
|
type: 1
|
|
|
|
|
};
|
|
|
|
|
if (isBlank(query.code)) {
|
|
|
|
|
query.code = this.$store.getters.locSubInvCode;
|
|
|
|
|
}
|
|
|
|
|
getLocalJoinByUser(query)
|
|
|
|
|
.then((response) => {
|
|
|
|
|
|
|
|
|
|
this.busTypes = response.data.list || [];
|
|
|
|
|
if (this.formData.action != null) {
|
|
|
|
|
this.curAction = this.getActionItem(this.formData.action);
|
|
|
|
|
if (this.curAction != null) {
|
|
|
|
|
this.formData.vailInv = this.curAction.vailInv;
|
|
|
|
|
this.formData.codeFillCheck = this.curAction.codeFillCheck;
|
|
|
|
|
}
|
|
|
|
|
this.busTypes = response.data.list || [];
|
|
|
|
|
if (this.formData.action != null) {
|
|
|
|
|
this.curAction = this.getActionItem(this.formData.action);
|
|
|
|
|
if (this.curAction != null) {
|
|
|
|
|
this.formData.vailInv = this.curAction.vailInv;
|
|
|
|
|
this.formData.codeFillCheck = this.curAction.codeFillCheck;
|
|
|
|
|
} else {
|
|
|
|
|
this.curAction = {corpType: 0, genUnit: false, changeEnable: false,};
|
|
|
|
|
this.formData.action = null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
)
|
|
|
|
|
})
|
|
|
|
|
.catch(() => {
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
subStorageChange() {
|
|
|
|
|
this.getBusType();
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
geActionName(action) {
|
|
|
|
|
this.busTypes.forEach((obj) => {
|
|
|
|
|
if (obj.action == action) {
|
|
|
|
|
return obj.name;
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
locCHange() {
|
|
|
|
|
|
|
|
|
|
if (this.$isNotBlank(this.formData.invWarehouseCode)) {
|
|
|
|
|
this.formData.invWarehouseCode = "";
|
|
|
|
|
}
|
|
|
|
|
this.findStorageMethod();
|
|
|
|
|
this.findSubInvByInv(this.formData.locStorageCode);
|
|
|
|
|
}
|
|
|
|
|
,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
findMethod(query) {
|
|
|
|
|
|
|
|
|
|
this.fromOptions = [];
|
|
|
|
@ -959,13 +966,41 @@ export default {
|
|
|
|
|
.catch(() => {
|
|
|
|
|
this.loading = false;
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
findDeptMethod() {
|
|
|
|
|
let query = {
|
|
|
|
|
flag: 1
|
|
|
|
|
};
|
|
|
|
|
filterDepts(query)
|
|
|
|
|
.then((response) => {
|
|
|
|
|
this.loading = false;
|
|
|
|
|
this.fromDeptOptions = response.data.list || [];
|
|
|
|
|
})
|
|
|
|
|
.catch(() => {
|
|
|
|
|
this.loading = false;
|
|
|
|
|
this.fromDeptOptions = [];
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
findStorageMethod() {
|
|
|
|
|
|
|
|
|
|
if (this.formData.locStorageCode == null)
|
|
|
|
|
return;
|
|
|
|
|
this.fromStorageOptions = [];
|
|
|
|
|
let cQuery = {
|
|
|
|
|
locInvCode: this.formData.locStorageCode,
|
|
|
|
|
};
|
|
|
|
|
filterAllByLoc(cQuery)
|
|
|
|
|
.then((response) => {
|
|
|
|
|
this.fromStorageOptions = response.data || [];
|
|
|
|
|
})
|
|
|
|
|
.catch(() => {
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
findSubStorageMethod() {
|
|
|
|
|
this.formData.invStorageCode= this.subInvList.find(item => item.code == this.formData.invWarehouseCode).parentId
|
|
|
|
|
this.formData.locStorageCode= this.subInvList.find(item => item.code == this.formData.invWarehouseCode).parentId
|
|
|
|
|
findSubStorageMethod(val) {
|
|
|
|
|
this.getBusType();
|
|
|
|
|
let cQuery = {
|
|
|
|
|
code: this.formData.invWarehouseCode,
|
|
|
|
@ -973,48 +1008,45 @@ export default {
|
|
|
|
|
};
|
|
|
|
|
filterSubByInv(cQuery)
|
|
|
|
|
.then((response) => {
|
|
|
|
|
|
|
|
|
|
this.fromSubStorageOptions = response.data || [];
|
|
|
|
|
if (val == 1) {
|
|
|
|
|
|
|
|
|
|
} else
|
|
|
|
|
this.formData.fromSubInvCode = this.fromSubStorageOptions[0].code;
|
|
|
|
|
})
|
|
|
|
|
.catch(() => {
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
,
|
|
|
|
|
getFormCorp(){
|
|
|
|
|
this.formData.subInvCode= this.fromSubStorageOptions.find(item => item.code == this.formData.fromSubInvCode).parentId
|
|
|
|
|
this.formData.fromCorp=this.fromSubStorageOptions.find(item => item.code == this.formData.fromSubInvCode).warehouseName
|
|
|
|
|
this.formData.fromCorpId=this.fromSubStorageOptions.find(item => item.code == this.formData.fromSubInvCode).code
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
findSubInvByInv(invCode) {
|
|
|
|
|
|
|
|
|
|
findSubInvByInv() {
|
|
|
|
|
|
|
|
|
|
this.subInvList = [];
|
|
|
|
|
let query = {
|
|
|
|
|
filter:3
|
|
|
|
|
filter: 3
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
filterSubByInv(query)
|
|
|
|
|
.then((response) => {
|
|
|
|
|
this.subInvList = response.data || [];
|
|
|
|
|
if (this.subInvList != null) {
|
|
|
|
|
if (this.subInvList != null && this.subInvList.length == 1) {
|
|
|
|
|
this.formData.invWarehouseCode = this.subInvList[0].code;
|
|
|
|
|
this.getBusType();
|
|
|
|
|
this.findSubStorageMethod();
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
.catch(() => {
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
findDeptMethod() {
|
|
|
|
|
let query = {
|
|
|
|
|
flag: 1
|
|
|
|
|
};
|
|
|
|
|
filterDepts(query)
|
|
|
|
|
|
|
|
|
|
getStorage(event) {
|
|
|
|
|
this.storageList = [];
|
|
|
|
|
filterAllByUser()
|
|
|
|
|
.then((response) => {
|
|
|
|
|
this.loading = false;
|
|
|
|
|
this.fromDeptOptions = response.data.list || [];
|
|
|
|
|
this.storageList = response.data || [];
|
|
|
|
|
})
|
|
|
|
|
.catch(() => {
|
|
|
|
|
this.loading = false;
|
|
|
|
|
this.fromDeptOptions = [];
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
getActionName(action) {
|
|
|
|
@ -1023,16 +1055,14 @@ export default {
|
|
|
|
|
return this.busTypes[i].advanceType;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
,
|
|
|
|
|
},
|
|
|
|
|
getActionItem(action) {
|
|
|
|
|
for (let i = 0; i < this.busTypes.length; i++) {
|
|
|
|
|
if (this.busTypes[i].action == action) {
|
|
|
|
|
return this.busTypes[i];
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
,
|
|
|
|
|
},
|
|
|
|
|
actionChange(item) {
|
|
|
|
|
|
|
|
|
|
this.curAction = this.getActionItem(item);
|
|
|
|
@ -1042,21 +1072,25 @@ export default {
|
|
|
|
|
this.$set(this.formData, "preCheck", this.curAction.scanPreIn);
|
|
|
|
|
this.$set(this.formData, "outChangeEnable", this.curAction.ullageFill);
|
|
|
|
|
this.$set(this.formData, "codeFillCheck", this.curAction.codeFillCheck);
|
|
|
|
|
this.formData.fromCorp = null;
|
|
|
|
|
this.formData.fromSubInvCode = null;
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
,
|
|
|
|
|
// this.formData.vailIn = this.curAction.vailInv;
|
|
|
|
|
// this.formData.preCheck = this.curAction.scanPreIn;
|
|
|
|
|
// this.formData.outChangeEnable = this.curAction.ullageFill;
|
|
|
|
|
// this.formData.codeFillCheck = this.curAction.codeFillCheck;
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
//绑定数据
|
|
|
|
|
//绑定数据
|
|
|
|
|
bindRl(val) {
|
|
|
|
|
this.curRow = val;
|
|
|
|
|
this.selectRlVisible = true;
|
|
|
|
|
}
|
|
|
|
|
,
|
|
|
|
|
},
|
|
|
|
|
handleUnitClick(row) {
|
|
|
|
|
this.curRow = row;
|
|
|
|
|
this.dialogTableVisible = true;
|
|
|
|
|
}
|
|
|
|
|
,
|
|
|
|
|
},
|
|
|
|
|
selectSupUnit(row) {
|
|
|
|
|
let query = {
|
|
|
|
|
id: this.curRow.id,
|
|
|
|
@ -1073,8 +1107,7 @@ export default {
|
|
|
|
|
}).catch(() => {
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
selectBindRl(row) {
|
|
|
|
@ -1101,30 +1134,25 @@ export default {
|
|
|
|
|
}).catch(() => {
|
|
|
|
|
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
,
|
|
|
|
|
},
|
|
|
|
|
closeBindDialog(val) {
|
|
|
|
|
this.selectRlVisible = false;
|
|
|
|
|
this.dialogTableVisible = false;
|
|
|
|
|
}
|
|
|
|
|
,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
rowStyle({row, rowIndex}) {
|
|
|
|
|
let rowBackground = {};
|
|
|
|
|
if (!this.$isNotBlank(row.supId) || !this.$isNotBlank(row.relId)) {
|
|
|
|
|
//rowBackground.background="#f6f5ee";
|
|
|
|
|
rowBackground.color = '#f60303';
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
return rowBackground;
|
|
|
|
|
}
|
|
|
|
|
,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
filters: {}
|
|
|
|
|
,
|
|
|
|
|
filters: {},
|
|
|
|
|
mounted() {
|
|
|
|
|
document.body.ondrop = function (event) {
|
|
|
|
|
event.preventDefault();
|
|
|
|
@ -1155,16 +1183,13 @@ export default {
|
|
|
|
|
};
|
|
|
|
|
inputer.focus();
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
,
|
|
|
|
|
},
|
|
|
|
|
created() {
|
|
|
|
|
|
|
|
|
|
this.formData.code = '';
|
|
|
|
|
this.formData.actDate = new Date();
|
|
|
|
|
this.codeArray = [];
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.getStorage(this.formData.action);
|
|
|
|
|
if (this.$isNotBlank(this.idQuery.id)) {
|
|
|
|
|
this.formData.actDate = new Date(this.idQuery.actDate);
|
|
|
|
|
this.formData.corpOrderId = this.idQuery.corpOrderId;
|
|
|
|
@ -1179,7 +1204,7 @@ export default {
|
|
|
|
|
this.formData.preCheck = this.idQuery.preCheck;
|
|
|
|
|
this.actionEnable = true;
|
|
|
|
|
this.getCodeList();
|
|
|
|
|
this.findSubStorageMethod();
|
|
|
|
|
this.findSubStorageMethod(1);
|
|
|
|
|
} else {
|
|
|
|
|
this.corpOrderIdDisabled = false;
|
|
|
|
|
if (JSON.stringify(this.$route.query) === '{}') {
|
|
|
|
@ -1190,18 +1215,20 @@ export default {
|
|
|
|
|
// 将参数拷贝进查询对象
|
|
|
|
|
let query = this.$route.query;
|
|
|
|
|
this.orderNo = query.id;
|
|
|
|
|
|
|
|
|
|
this.query = Object.assign(this.query, query);
|
|
|
|
|
this.query.limit = parseInt(this.query.limit);
|
|
|
|
|
this.query.corpOrderId = query.id;
|
|
|
|
|
// 加载表格数据
|
|
|
|
|
// this.getCodeList();
|
|
|
|
|
}
|
|
|
|
|
this.formData.invWarehouseCode = this.$store.getters.locSubInvCode;
|
|
|
|
|
this.formData.invStorageCode=this.$store.getters.locInvCode;
|
|
|
|
|
this.formData.locStorageCode = this.$store.getters.locInvCode;
|
|
|
|
|
if (this.$isNotBlank(this.formData.locStorageCode)) {
|
|
|
|
|
this.findStorageMethod();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
this.findSubInvByInv(this.formData.locStorageCode);
|
|
|
|
|
this.findSubInvByInv();
|
|
|
|
|
this.findSubStorageMethod();
|
|
|
|
|
this.getBusType();
|
|
|
|
|
|
|
|
|
|
//查询是否启用多级仓库,判断是否启用部门
|
|
|
|
|
selectSysParamByKey({paramKey: "muti_inv_mode"}).then((res) => {
|
|
|
|
|
if (res.code === 20000) {
|
|
|
|
@ -1210,13 +1237,13 @@ export default {
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
};
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<style>
|
|
|
|
|
|
|
|
|
|
.messageIndex {
|
|
|
|
|
z-index: 9999 !important;
|
|
|
|
|
}
|
|
|
|
|