Merge remote-tracking branch 'origin/dev_ksck_z' into dev_ksck_z

20240912_adapter_z
yewj 8 months ago
commit 83ea4171dc

@ -8,6 +8,13 @@ export function orderPage(query) {
params: query
});
}
export function findByBill(query) {
return axios({
url: "/udiwms/basic/collect/order/findByBill",
method: "get",
params: query
});
}
export function getNextOrder(query) {
return axios({

@ -228,10 +228,10 @@ export default {
{ required: true, message: '请选择异常方式提醒', trigger: 'blur' }
],
corpType: [
{ required: true, message: '请选择往来单位类型', trigger: 'blur' }
// { required: true, message: '', trigger: 'blur' }
],
unitTittle: [
{ required: true, message: '请输入往来类型标题', trigger: 'blur' }
// { required: true, message: '', trigger: 'blur' }
],
}
}
@ -311,8 +311,8 @@ export default {
}
})
} else {
this.$refs['dataForm'].validate((valid) => {
if (valid){
this.$refs['dataForm'].validate((rules) => {
if (rules){
addBusType(this.formData).then(res => {
if (res.code == 20000) {
this.$message.success('新增成功')
@ -332,6 +332,25 @@ export default {
},
hideForm() {
this.closeDialog()
},
// scanType
updateFormRules() {
if (this.formData.scanType === 1) {
// scanType1corpTypeunitTittle
this.$set(this.formRules.corpType, 0, { required: false });
this.$set(this.formRules.unitTittle, 0, { required: false });
} else {
//
this.$set(this.formRules.corpType, 0, { required: true, message: '请选择往来单位类型', trigger: 'blur' });
this.$set(this.formRules.unitTittle, 0, { required: true, message: '请输入往来类型标题', trigger: 'blur' });
}
},
},
watch: {
// scanType
'formData.scanType': function(newVal, oldVal) {
this.updateFormRules();
}
},
created() {

@ -218,14 +218,14 @@
</pagination>
</el-tab-pane>
<el-tab-pane>
<span slot="label">{{ workplaceName }}-单据类型</span>
<span slot="label">{{ workplaceName }}-业务类型</span>
<el-form :inline="true" :model="busQuery" class="query-form" size="mini"
style="margin-bottom: 10px"
>
<el-form-item class="query-form-item" label="单据类型编号/业务名称:">
<el-form-item class="query-form-item" label="业务类型编号/业务名称:">
<el-input
v-model="busQuery.busKey"
placeholder="请输入单据类型编号/业务名称"
placeholder="请输入业务类型编号/业务名称"
clearable
></el-input>
</el-form-item>
@ -244,7 +244,7 @@
>
<el-button type="primary" @click="chooseBusType"
icon="el-icon-plus"
>新增单据类型
>新增业务类型
</el-button
>
</el-button-group>
@ -254,7 +254,7 @@
highlight-current-row
>
<el-table-column type="index" label="序号"></el-table-column>
<el-table-column label="单据类型编码 " prop="documentTypeCode"></el-table-column>
<el-table-column label="业务类型编码 " prop="documentTypeCode"></el-table-column>
<el-table-column label="业务名称 " prop="busName"></el-table-column>
<el-table-column label="仓库名称 " prop="invName"></el-table-column>
<el-table-column label="是否配套系统" prop="isMatching">
@ -700,8 +700,8 @@ export default {
},
busName: '',
busTypeMap: {
'add': '新增单据类型',
'edit': '编辑单据类型'
'add': '新增业务类型',
'edit': '编辑业务类型'
},
formData: {
operationType: 1,

@ -208,6 +208,7 @@
:total="total"
:limit.sync="filterQuery.limit"
:page.sync="filterQuery.page"
:page-sizes="[12, 24, 48]"
@pagination="handleCurrentChange"
></pagination>
</el-card>
@ -306,6 +307,7 @@
:total="total"
:limit.sync="filterQuery.limit"
:page.sync="filterQuery.page"
:page-sizes="[12, 24, 48]"
@pagination="handleCurrentChange"
></pagination>
</div>
@ -408,7 +410,7 @@ export default {
billNo: null,
tagStatus: null,
page: 1,
limit: 10,
limit: 12,
},
defaultSort: {prop: 'createTime', order: 'desc'},
loading: false,
@ -488,7 +490,12 @@ export default {
this.showSearch = !this.showSearch;
},
onReset() {
this.filterQuery = {};
this.filterQuery = {
billNo: null,
tagStatus: null,
page: 1,
limit: 12,
};
this.actDateRange = [];
this.getList();
},

@ -326,7 +326,7 @@ import {enterCodeWeb} from "@/api/inout/order";
import {draftOrder, finishOrder, startSplit, tagCode, updateOrder} from "@/api/collect/splitCreateOrder";
import {selectCorpList} from "@/api/basic/basicUnitMaintain";
import {delDrugLevel} from "@/api/basic/product/drugUdiinfos";
import {getCurOrder, getNextOrder} from "@/api/collect/collectOrder";
import {getCurOrder, getNextOrder,findByBill} from "@/api/collect/collectOrder";
import PanelOrderAllDetail from "@/views/collect/PanelOrderAllDetail";
import {getWorkBindBusTypes, removeBusTypeById} from '@/api/basic/workPlace/sysWorkplaceDocuments'
@ -365,6 +365,7 @@ export default {
curWorkPlaces: [],
erpList: [],
formData: {
billNo:null,
tagStatus: -1,
invCode: null,
busType: null,
@ -416,6 +417,21 @@ export default {
PanelOrderAllDetail
},
methods: {
getBillNo(billNo){
let post = {
billNo: billNo,
page: 1,
limit: 10,
}
findByBill(post).then(res => {
if (res.code == 20000) {
if (res.data.list.length > 0){
this.formData = res.data.list[0]
}
}
})
},
selectBusType(val) {
this.formData.busType = val
this.selectBusTypeDisabled = false
@ -438,7 +454,12 @@ export default {
if (this.formDataVisible.scanType == 1) {
this.findFromInvList("");
}
if (this.formData.billNo != null){
this.getBillNo(this.formData.billNo)
}else {
this.findCurOrder();
}
} else {
this.formData.busType = null
}
@ -844,15 +865,21 @@ export default {
});
this.findCurWorkPlaces();
this.formData.invCode = this.$store.getters.locInvCode;
if (this.$route.query.billNo != null) {
this.formData.billNo = this.$route.query.billNo
}
if (this.$route.query.workplaceId != null) {
this.isLinkDisabled = true
this.selectBusTypeDisabled = true
this.corpOrderIdDisabled = true
this.workplaceId = Number(this.$route.query.workplaceId);
this.formData.workPlaceCode = Number(this.$route.query.workplaceId);
this.getWorkBindBusTypes(this.formData.workPlaceCode);
}
}
}

@ -326,7 +326,7 @@ import {enterCodeWeb} from "@/api/inout/order";
import {draftOrder, finishOrder, startSplit, tagCode, updateOrder} from "@/api/collect/splitCreateOrder";
import {selectCorpList} from "@/api/basic/basicUnitMaintain";
import {delDrugLevel} from "@/api/basic/product/drugUdiinfos";
import {getCurOrder, getNextOrder} from "@/api/collect/collectOrder";
import {getCurOrder, getNextOrder,findByBill} from "@/api/collect/collectOrder";
import PanelOrderAllDetail from "@/views/collect/PanelOrderAllDetail";
import {getWorkBindBusTypes, removeBusTypeById} from '@/api/basic/workPlace/sysWorkplaceDocuments'
@ -365,6 +365,7 @@ export default {
curWorkPlaces: [],
erpList: [],
formData: {
billNo:null,
tagStatus: -1,
invCode: null,
busType: null,
@ -416,6 +417,21 @@ export default {
PanelOrderAllDetail
},
methods: {
getBillNo(billNo){
let post = {
billNo: billNo,
page: 1,
limit: 10,
}
findByBill(post).then(res => {
if (res.code == 20000) {
if (res.data.list.length > 0){
this.formData = res.data.list[0]
}
}
})
},
selectBusType(val) {
this.formData.busType = val
this.selectBusTypeDisabled = false
@ -438,7 +454,12 @@ export default {
if (this.formDataVisible.scanType == 1) {
this.findFromInvList("");
}
if (this.formData.billNo != null){
this.getBillNo(this.formData.billNo)
}else {
this.findCurOrder();
}
} else {
this.formData.busType = null
}
@ -844,15 +865,21 @@ export default {
});
this.findCurWorkPlaces();
this.formData.invCode = this.$store.getters.locInvCode;
if (this.$route.query.billNo != null) {
this.formData.billNo = this.$route.query.billNo
}
if (this.$route.query.workplaceId != null) {
this.isLinkDisabled = true
this.selectBusTypeDisabled = true
this.corpOrderIdDisabled = true
this.workplaceId = Number(this.$route.query.workplaceId);
this.formData.workPlaceCode = Number(this.$route.query.workplaceId);
this.getWorkBindBusTypes(this.formData.workPlaceCode);
}
}
}

@ -42,8 +42,16 @@
style="display: flex; margin: 0px 0 15px 0; float: right"
>
<!--<el-button size="mini" type="primary" @click.native="saveOrder()" :loading="saveLoading"-->
<!-- >草稿保存-->
<!--&gt;草稿保存-->
<!--</el-button>-->
<el-button size="mini" type="primary" @click.native="chooseDraftOrder()" :loading="submitLoading"
v-if="splitType=='out'"style="margin-right: 8px;border-radius: 5%;"
>选入草稿单据
</el-button>
<el-button size="mini" type="primary" @click.native="draftOrder()" :loading="submitLoading"
v-if="splitType=='out'"style="margin-right: 8px;border-radius: 5%;"
>草稿保存
</el-button>
<el-button size="mini" type="primary" @click.native="submit()" :loading="submitLoading"
v-if="splitType=='out'" style="margin-right: 8px;border-radius: 5%;"
>上货完成
@ -252,6 +260,23 @@
></codesPanel>
</el-tab-pane>
</el-tabs>
<el-dialog
title="选入草稿单据"
:visible.sync="chooseDraftOrderVisible"
width="80%"
append-to-body
:close-on-click-modal="false"
:close-on-press-escape="false"
v-if="chooseDraftOrderVisible"
>
<chooseDraftOrderDialog
:rowData="rowData"
:closeChooseDialog="closeChooseDialog"
:handleChoose="handleChoose"
>
</chooseDraftOrderDialog>
</el-dialog>
</div>
</template>
@ -287,6 +312,7 @@ import dialogInvProduct from "@/views/inout/DialogSelectInvProduct";
import {listPage} from "@/api/basic/workPlace/sysWorkplaceManage";
import {printSplitLabel} from "@/api/collect/splitCreateOrder";
import {findInvRemind} from "@/api/inout/splitCode";
import chooseDraftOrderDialog from "./chooseDraftOrderDialog"
export default {
name: "ioCreateOrder",
@ -480,6 +506,7 @@ export default {
//
selectInvProductVisible: false,
chooseDraftOrderVisible: false,
invQueryData: {
invCode: null,
},
@ -490,6 +517,7 @@ export default {
scanResultType: "success",
msgTip: "当前工位存量提醒:",
splitType: null,
rowData: {}
};
},
components: {
@ -497,7 +525,7 @@ export default {
codeDetailPanel,
editCodeDialog,
DialogCreateOrderSelect,
DialogSelectUnit, DialogSelectSpace, selectRlDialog, dialogInvProduct
DialogSelectUnit, DialogSelectSpace, selectRlDialog, dialogInvProduct,chooseDraftOrderDialog
},
methods: {
changeInvRemind(val) {
@ -1415,11 +1443,29 @@ export default {
});
}
},
saveOrder() {
//稿
chooseDraftOrder(){
if (this.$isBlank(this.orderFormData.workPlaceCode)) {
this.$message.warning("请选择工位!");
return;
}
this.rowData.workPlaceCode = this.orderFormData.workPlaceCode
this.rowData.fifoSplit = this.orderFormData.fifoSplit
this.chooseDraftOrderVisible = true
},
closeChooseDialog(){
this.chooseDraftOrderVisible = false
},
handleChoose(billNo){
this.orderFormData.billNo = billNo
this.refreshCodesPanel();
},
draftOrder() {
let tQuery = Object.assign(
JSON.parse(JSON.stringify(this.orderFormData))
);
tQuery.billNo = this.orderFormData.billNo;
tQuery.orderType = 2;
console.log("tQuery:");
console.log(tQuery);
if (this.orderFormData.billNo == null) {
@ -1427,12 +1473,12 @@ export default {
return;
}
this.saveLoading = true
saveOrderWeb(tQuery).then((response) => {
this.saveLoading = false
if (response.code === 20000) {
if (this.closeDialog != undefined) {
this.closeDialog();
}
this.$message.success("保存成功")
this.successCloseData()
} else {
this.$message.error(response.message);
}
@ -1440,7 +1486,6 @@ export default {
this.saveLoading = false
});
},
//
resetForm() {
if (this.$refs["dataForm"]) {

File diff suppressed because it is too large Load Diff
Loading…
Cancel
Save