去掉单据类型与第三方单据类型关联,更改为在第三方接口设置关联

prod
anthonywj 2 years ago
parent c57d056f5f
commit 6470d6c911

@ -111,30 +111,30 @@
</el-col> </el-col>
</el-row> </el-row>
<el-row type="flex"> <!-- <el-row type="flex">-->
<el-col :span="11"> <!-- <el-col :span="11">-->
<el-form-item label="第三方单据类型" prop="prefix"> <!-- <el-form-item label="第三方单据类型" prop="prefix">-->
<el-select v-model="inputQuery.originAction" <!-- <el-select v-model="inputQuery.originAction"-->
size="small" <!-- size="small"-->
clearable <!-- clearable-->
style="width: 90%" <!-- style="width: 90%"-->
filterable <!-- filterable-->
placeholder="请选择第三方系统单据类型" <!-- placeholder="请选择第三方系统单据类型"-->
> <!-- >-->
<el-option <!-- <el-option-->
v-for="item in originTypes" <!-- v-for="item in originTypes"-->
:key="item.id" <!-- :key="item.id"-->
:label="item.name" <!-- :label="item.name"-->
:value="item.action"> <!-- :value="item.action">-->
<span style="float: left;font-size: 13px">{{ item.name }}</span> <!-- <span style="float: left;font-size: 13px">{{ item.name }}</span>-->
<span style="float: right; color: #8492a6; font-size: 13px;margin-left: 10px">{{ <!-- <span style="float: right; color: #8492a6; font-size: 13px;margin-left: 10px">{{-->
item.thirdSysName <!-- item.thirdSysName-->
}}</span> <!-- }}</span>-->
</el-option> <!-- </el-option>-->
</el-select> <!-- </el-select>-->
</el-form-item> <!-- </el-form-item>-->
</el-col> <!-- </el-col>-->
</el-row> <!-- </el-row>-->
<el-row type="flex"> <el-row type="flex">
<el-col :span="23" type="flex"> <el-col :span="23" type="flex">

@ -9,29 +9,35 @@
<el-col :span="6"> <el-col :span="6">
<el-form-item class="query-form-item" label="单据号:"> <el-form-item class="query-form-item" label="单据号:">
<el-input <el-input
v-model="listQuery.billNo" v-model="listQuery.billNo"
placeholder="单据号" placeholder="单据号"
clearable clearable
></el-input> ></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="6"> <el-col :span="6">
<el-form-item class="query-form-item" label="往来单位:"> <el-form-item label="外部系统:">
<el-input <el-select v-model="listQuery.thirdSysFk" style="width: 90%" placeholder="请选择第三方系统"
v-model="listQuery.corpName" clearable="true" @change="thirdSysChange">
placeholder="往来单位" <el-option
clearable v-for="item in thirdSys"
></el-input> :key="item.thirdId"
:label="item.thirdName"
:value="item.thirdId">
<span style="float: left;font-size: 13px">{{ item.thirdName }}</span>
</el-option>
</el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="6"> <el-col :span="6">
<el-form-item class="query-form-item" label="单据类型:"> <el-form-item class="query-form-item" label="单据类型:">
<el-select v-model="listQuery.billAction" placeholder="请选择第三方系统单据类型" filterable clearable="true"> <el-select v-model="listQuery.billAction" placeholder="请选择第三方系统单据类型" filterable clearable="true">
<el-option <el-option
v-for="item in originTypes" v-for="item in originTypes"
:key="item.name" :key="item.name"
:label="item.name" :label="item.name"
:value="item.action"> :value="item.action">
<span style="float: left;font-size: 13px">{{ item.name }}</span> <span style="float: left;font-size: 13px">{{ item.name }}</span>
<span style="float: right; color: #8492a6; font-size: 13px;margin-left: 10px">{{ <span style="float: right; color: #8492a6; font-size: 13px;margin-left: 10px">{{
item.thirdSysName item.thirdSysName
@ -45,14 +51,14 @@
<el-col :span="6"> <el-col :span="6">
<el-form-item class="query-form-item" label="单据日期:"> <el-form-item class="query-form-item" label="单据日期:">
<el-date-picker <el-date-picker
:picker-options="pickerOptions" :picker-options="pickerOptions"
v-model="actDateRange" v-model="actDateRange"
type="daterange" type="daterange"
format="yyyy 年 MM 月 dd 日" format="yyyy 年 MM 月 dd 日"
value-format="yyyy-MM-dd" value-format="yyyy-MM-dd"
range-separator="至" range-separator="至"
start-placeholder="开始日期" start-placeholder="开始日期"
end-placeholder="结束日期" end-placeholder="结束日期"
> >
</el-date-picker> </el-date-picker>
</el-form-item> </el-form-item>
@ -64,9 +70,9 @@
<el-button icon="el-icon-view" type="primary" @click="hideSearch">/</el-button> <el-button icon="el-icon-view" type="primary" @click="hideSearch">/</el-button>
<el-button <el-button
type="primary" type="primary"
icon="el-icon-refresh" icon="el-icon-refresh"
@click="onReset" @click="onReset"
>重置 >重置
</el-button> </el-button>
<el-button type="primary" icon="el-icon-search" @click="submitFind"></el-button> <el-button type="primary" icon="el-icon-search" @click="submitFind"></el-button>
@ -78,13 +84,13 @@
</div> </div>
<el-divider style="margin: 15px"></el-divider> <el-divider style="margin: 15px"></el-divider>
<el-table <el-table
:data="dataList" :data="dataList"
style="width: 100%" style="width: 100%"
highlight-current-row="true" highlight-current-row="true"
v-loading="loading" v-loading="loading"
border border
:row-class-name="tableRowClassName" :row-class-name="tableRowClassName"
@current-change="handleChange" @current-change="handleChange"
> >
<el-table-column label="序号" type="index"></el-table-column> <el-table-column label="序号" type="index"></el-table-column>
<el-table-column label="单据号" prop="billNo"></el-table-column> <el-table-column label="单据号" prop="billNo"></el-table-column>
@ -95,11 +101,11 @@
<el-table-column label="单据日期" prop="billdate"></el-table-column> <el-table-column label="单据日期" prop="billdate"></el-table-column>
</el-table> </el-table>
<el-pagination <el-pagination
:page-size="listQuery.limit" :page-size="listQuery.limit"
@current-change="handleErpPageChange" @current-change="handleErpPageChange"
layout="prev, pager, next" layout="prev, pager, next"
:total="pageTotal" :total="pageTotal"
:current-page="listQuery.page" :current-page="listQuery.page"
></el-pagination> ></el-pagination>
</div> </div>
</el-card> </el-card>
@ -119,17 +125,17 @@
<el-dialog <el-dialog
v-if="storageVisible" v-if="storageVisible"
title="请选择单据所属仓库信息" title="请选择单据所属仓库信息"
:close-on-click-modal="false" :close-on-click-modal="false"
:close-on-press-escape="false" :close-on-press-escape="false"
append-to-body append-to-body
:visible.sync="storageVisible"> :visible.sync="storageVisible">
<selectInvDialog <selectInvDialog
:closeInvDialog="closeInvDialog" :closeInvDialog="closeInvDialog"
:billData="currentRow" :billData="currentRow"
:closeSubmitDialog="closeSubmitDialog" :closeSubmitDialog="closeSubmitDialog"
></selectInvDialog> ></selectInvDialog>
</el-dialog> </el-dialog>
@ -142,6 +148,7 @@ import store from "../../store";
import {getOriginBusType} from "@/api/basic/busOriginType"; import {getOriginBusType} from "@/api/basic/busOriginType";
import {filterAllByUser} from "@/api/system/invWarehouse"; import {filterAllByUser} from "@/api/system/invWarehouse";
import selectInvDialog from "./DialogSelectInv"; import selectInvDialog from "./DialogSelectInv";
import {getBasicThirdSys} from "@/api/basic/basicThirdSys";
export default { export default {
name: "closeDialog", name: "closeDialog",
@ -269,23 +276,23 @@ export default {
} }
this.listQuery.customerId = store.getters.customerId; this.listQuery.customerId = store.getters.customerId;
getCloudErp(this.listQuery) getCloudErp(this.listQuery)
.then((response) => { .then((response) => {
console.log(response) console.log(response)
this.loading = false; this.loading = false;
if (response.code === 20000) { if (response.code === 20000) {
this.dataList = response.data.list || []; this.dataList = response.data.list || [];
this.pageTotal = response.data.total || 0; this.pageTotal = response.data.total || 0;
} else { } else {
this.$message.error(response.message); this.$message.error(response.message);
this.dataList = [];
this.pageTotal = 0;
}
})
.catch(() => {
this.loading = false;
this.dataList = []; this.dataList = [];
this.pageTotal = 0; this.pageTotal = 0;
}); }
})
.catch(() => {
this.loading = false;
this.dataList = [];
this.pageTotal = 0;
});
}, },
intentBack() { intentBack() {
this.closeDialog(); this.closeDialog();
@ -304,15 +311,15 @@ export default {
invWarehouseCode: this.currentRow.invWarehouseCode, invWarehouseCode: this.currentRow.invWarehouseCode,
} }
addStockOrder(tQuery) addStockOrder(tQuery)
.then((response) => { .then((response) => {
if (response.code === 20000) { if (response.code === 20000) {
this.closeDialog(); this.closeDialog();
} else { } else {
this.$message.error(response.message); this.$message.error(response.message);
} }
}) })
.catch(() => { .catch(() => {
}); });
} }
}, },
hideSearch() { hideSearch() {
@ -329,16 +336,16 @@ export default {
locStorageCode: this.curLocInv, locStorageCode: this.curLocInv,
} }
addStockOrder(tQuery) addStockOrder(tQuery)
.then((response) => { .then((response) => {
if (response.code === 20000) { if (response.code === 20000) {
this.storageVisible = false; this.storageVisible = false;
this.closeDialog(); this.closeDialog();
} else { } else {
this.$message.error(response.message); this.$message.error(response.message);
} }
}) })
.catch(() => { .catch(() => {
}); });
}, },
handleSelectionUdiChange(val) { handleSelectionUdiChange(val) {
@ -348,25 +355,26 @@ export default {
getBusType() { getBusType() {
let query = { let query = {
enabled: true, enabled: true,
thirdSys: this.listQuery.thirdSysFk,
}; };
getOriginBusType(query) getOriginBusType(query)
.then((response) => { .then((response) => {
this.originTypes = response.data.list || []; this.originTypes = response.data.list || [];
}) })
.catch(() => { .catch(() => {
}); });
}, },
getStorage(event) { getStorage(event) {
this.storageList = []; this.storageList = [];
filterAllByUser() filterAllByUser()
.then((response) => { .then((response) => {
this.storageList = response.data || []; this.storageList = response.data || [];
if (this.storageList.length == 1) { if (this.storageList.length == 1) {
this.curLocInv = this.storageList[0].code; this.curLocInv = this.storageList[0].code;
} }
}) })
.catch(() => { .catch(() => {
}); });
}, },
@ -374,15 +382,41 @@ export default {
this.storageVisible = false; this.storageVisible = false;
}, },
thirdSysChange() {
this.listQuery.billAction = "";
this.getBusType();
},
closeSubmitDialog() { closeSubmitDialog() {
this.storageVisible = false; this.storageVisible = false;
this.combine(); this.combine();
}, },
getBasicThirdSys() {
let query = {
enabled: true,
};
getBasicThirdSys(query)
.then((response) => {
this.thirdSys = response.data.list || [];
this.listQuery.thirdSysFk = this.thirdSys[0].thirdId;
this.uploadData.thirdSys = this.listQuery.thirdSysFk;
this.selectSysParam();
this.getBusType();
})
.catch(() => {
this.loading = false;
this.list = [];
});
},
}, },
created() { created() {
this.getBusType();
this.getBasicThirdSys();
this.getStorage(); this.getStorage();
this.getList();
}, },
components: {selectInvDialog} components: {selectInvDialog}

@ -9,12 +9,21 @@
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="往来单位:"> <el-form-item label="外部系统:">
<el-input v-model="filterQuery.corpName" style="width: 90%" placeholder="请输入往来单位" clearable></el-input> <el-select v-model="filterQuery.thirdSysFk" style="width: 90%" placeholder="请选择第三方系统"
clearable="true" @change="thirdSysChange">
<el-option
v-for="item in thirdSys"
:key="item.thirdId"
:label="item.thirdName"
:value="item.thirdId">
<span style="float: left;font-size: 13px">{{ item.thirdName }}</span>
</el-option>
</el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="外部系统:"> <el-form-item label="单据类型:">
<el-select v-model="filterQuery.billAction" style="width: 90%" placeholder="请选择第三方系统单据类型" <el-select v-model="filterQuery.billAction" style="width: 90%" placeholder="请选择第三方系统单据类型"
clearable="true"> clearable="true">
<el-option <el-option
@ -30,12 +39,15 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
</el-row>
<el-row>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="单据日期:"> <el-form-item label="单据日期:">
<el-date-picker <el-date-picker
:picker-options="pickerOptions" :picker-options="pickerOptions"
v-model="actDateRange" v-model="actDateRange"
style="width: 90%"
type="daterange" type="daterange"
format="yyyy 年 MM 月 dd 日" format="yyyy 年 MM 月 dd 日"
value-format="yyyy-MM-dd" value-format="yyyy-MM-dd"
@ -316,6 +328,8 @@ export default {
thirdSysChange() { thirdSysChange() {
this.uploadData.thirdSys = this.filterQuery.thirdSysFk; this.uploadData.thirdSys = this.filterQuery.thirdSysFk;
this.getThirdSysDetail(); this.getThirdSysDetail();
this.filterQuery.billAction = "";
this.getBusType();
}, },
getThirdSysDetail() { getThirdSysDetail() {
let query = { let query = {
@ -363,6 +377,7 @@ export default {
getBusType() { getBusType() {
let query = { let query = {
enabled: true, enabled: true,
thirdSys: this.filterQuery.thirdSysFk,
}; };
getBussinessType(query) getBussinessType(query)
.then((response) => { .then((response) => {

Loading…
Cancel
Save