|
@@ -24,7 +24,7 @@
|
|
|
<template #table-header="{}">
|
|
|
<div style="width: 100%" class="min">
|
|
|
<el-row style="padding: 0 0 0 80px">
|
|
|
- <el-col :span="12" style="width: 300px">
|
|
|
+ <!-- <el-col :span="12" style="width: 300px">
|
|
|
<search-work-company
|
|
|
:value="parmValue.companyNo"
|
|
|
:names="''"
|
|
@@ -33,7 +33,7 @@
|
|
|
:placeholder="'业务公司'"
|
|
|
@searchChange="supplierChange"
|
|
|
/>
|
|
|
- </el-col>
|
|
|
+ </el-col> -->
|
|
|
<el-col :span="10" style="width: 330px; padding: 0 0 0 10px">
|
|
|
<el-input
|
|
|
v-model="parmValue.type_code"
|
|
@@ -43,6 +43,20 @@
|
|
|
/>
|
|
|
</el-col>
|
|
|
|
|
|
+ <el-col :span="12" style="width: 330px; padding: 0 0 0 10px">
|
|
|
+ <search-stock
|
|
|
+ :isDetail="true"
|
|
|
+ :size="searchSize"
|
|
|
+ :value="parmValue.stock_code"
|
|
|
+ :disabled="parmValue.companyNo === ''"
|
|
|
+ :placeholder="'出库仓库'"
|
|
|
+ :isRelation="true"
|
|
|
+ :companyNo="parmValue.companyNo"
|
|
|
+ :names="''"
|
|
|
+ @searchChange="selectStock"
|
|
|
+ />
|
|
|
+ </el-col>
|
|
|
+
|
|
|
<!-- 重置 -->
|
|
|
<el-col :span="4" style="width: 66px" class="fr">
|
|
|
<el-button
|
|
@@ -53,6 +67,12 @@
|
|
|
>重置</el-button
|
|
|
>
|
|
|
</el-col>
|
|
|
+
|
|
|
+ <el-col :span="4" style="width: 66px" class="fr">
|
|
|
+ <el-button :size="searchSize" type="primary" label="" @click="searchList"
|
|
|
+ >刷新</el-button
|
|
|
+ >
|
|
|
+ </el-col>
|
|
|
</el-row>
|
|
|
<el-row style="padding: 10px 0 0 0">
|
|
|
<!-- <el-col :span="12" style="width: 380px">
|
|
@@ -64,25 +84,9 @@
|
|
|
@searchChange="selectSupplier"
|
|
|
/>
|
|
|
</el-col> -->
|
|
|
- <el-col :span="12" style="width: 330px; padding: 0 0 0 10px">
|
|
|
- <search-stock
|
|
|
- :isDetail="true"
|
|
|
- :size="searchSize"
|
|
|
- :value="parmValue.stock_code"
|
|
|
- :disabled="parmValue.companyNo === ''"
|
|
|
- :placeholder="'出库仓库'"
|
|
|
- :isRelation="true"
|
|
|
- :companyNo="parmValue.companyNo"
|
|
|
- :names="''"
|
|
|
- @searchChange="selectStock"
|
|
|
- />
|
|
|
- </el-col>
|
|
|
+
|
|
|
<!-- 刷新 -->
|
|
|
- <el-col :span="4" style="width: 66px" class="fr">
|
|
|
- <el-button :size="searchSize" type="primary" label="" @click="searchList"
|
|
|
- >刷新</el-button
|
|
|
- >
|
|
|
- </el-col>
|
|
|
+
|
|
|
</el-row>
|
|
|
</div>
|
|
|
</template>
|
|
@@ -107,11 +111,12 @@
|
|
|
import mixinPage from "@/mixins/elPaginationHandle";
|
|
|
import resToken from "@/mixins/resToken";
|
|
|
import asyncRequest from "@/apis/service/stock/spaceCount";
|
|
|
+import companyHelper from "@/mixins/companyHelper"
|
|
|
import columns from "./columns";
|
|
|
import { mapGetters } from "vuex";
|
|
|
export default {
|
|
|
name: "spaceCount",
|
|
|
- mixins: [mixinPage, resToken],
|
|
|
+ mixins: [mixinPage, resToken, companyHelper],
|
|
|
components: {},
|
|
|
computed: {
|
|
|
...mapGetters(["tablebtnSize", "searchSize", "size"]),
|
|
@@ -156,10 +161,21 @@ export default {
|
|
|
};
|
|
|
},
|
|
|
mounted() {
|
|
|
+ // this.onCompanyChange()
|
|
|
this.searchList();
|
|
|
},
|
|
|
-
|
|
|
+ watch:{
|
|
|
+ currentCompany:{
|
|
|
+ handler(newVal){
|
|
|
+ this.parmValue.companyNo = newVal
|
|
|
+ },
|
|
|
+ immediate:true
|
|
|
+ }
|
|
|
+ },
|
|
|
methods: {
|
|
|
+ // onCompanyChange(){
|
|
|
+ // this.parmValue.companyNo = this.currentCompany
|
|
|
+ // },
|
|
|
//业务公司选择
|
|
|
async supplierChange(e) {
|
|
|
const { code } = e;
|
|
@@ -212,7 +228,7 @@ export default {
|
|
|
this.parmValue = {
|
|
|
start: "",
|
|
|
end: "",
|
|
|
- companyNo: "",
|
|
|
+ companyNo: this.currentCompany,
|
|
|
type_code: "", //商品编码
|
|
|
supplier_code: [],
|
|
|
stock_code: [], //仓库编码
|
|
@@ -229,7 +245,11 @@ export default {
|
|
|
model.wsm_code = model.stock_code.toString() || "";
|
|
|
delete model["supplier_code"];
|
|
|
delete model["stock_code"];
|
|
|
- const res = await asyncRequest.list(model);
|
|
|
+ const res = await asyncRequest.list({
|
|
|
+ ...model,
|
|
|
+ needRela: true,
|
|
|
+ companyNo: this.currentCompany
|
|
|
+ });
|
|
|
if (res && res.code === 0 && res.data) {
|
|
|
this.tableData = res.data.list;
|
|
|
this.tableData.forEach((e) => {
|