Commit 471f3d5a by LJM

移动端--理货记录--查询条件问题

parent fe426d4b
......@@ -201,6 +201,7 @@
export default {
data() {
return {
isFirst: false,
isZY: false, //区分是否自营
isInputFocus: false,
is_submit: true,
......@@ -363,9 +364,15 @@
if (res.data.list.length > 0) {
this.workingRuleList = res.data;
this.workingRule = res.data.list.map(item => item.position_code).join(',');
if (this.isFirst) {
//防止一直推荐
return false;
}
//默认自动填充到库位
if (this.workingRule) {
this.formParams.position_code = this.workingRule;
this.isFirst = true;
}
} else {
this.workingRuleList = '';
......
......@@ -43,16 +43,16 @@
<!-- 采购类型筛选 -->
<view class="radio-wrap row verCenter" style="padding-bottom: 0;">
<radio-group name="radio1" @change="radioChange($event, 1)">
<label>
<radio value="1" style="transform:scale(0.7)" color="#1969f9" />
<label @click="updatePurchaseTypeFilter(0,1)">
<radio value="1" style="transform:scale(0.7)" color="#1969f9" :checked="purchase_type_filter[0]" />
<text>采购入库</text>
</label>
<label>
<radio value="4" style="transform:scale(0.7)" color="#1969f9" />
<label @click="updatePurchaseTypeFilter(1,1)">
<radio value="4" style="transform:scale(0.7)" color="#1969f9" :checked="purchase_type_filter[1]" />
<text>委托入库</text>
</label>
<label>
<radio value="2" style="transform:scale(0.7)" color="#1969f9" />
<label @click="updatePurchaseTypeFilter(2,1)">
<radio value="2" style="transform:scale(0.7)" color="#1969f9" :checked="purchase_type_filter[2]" />
<text>退货入库</text>
</label>
</radio-group>
......@@ -65,7 +65,7 @@
<text>全部</text>
</label>
<label>
<radio value="0" style="transform:scale(0.7)" color="#1969f9" checked="true" />
<radio value="0" style="transform:scale(0.7)" color="#1969f9" checked />
<text>已理货</text>
</label>
<label>
......@@ -393,6 +393,7 @@
hasMoreData: true, //是否分页加载
image_list: [], //图片列表
maxNum: 10, //最大上传图片数量
purchase_type_filter: [false, false, false], //采购类型筛选状态标记
searchParams: {
create_time_begin: '', //起始日期
create_time_end: '', //结束日期
......@@ -446,18 +447,35 @@
this.curr = index;
},
/**
* @param {Object} inde
* @param {Object} type 1 采购单筛选 2理货状态筛选
*/
updatePurchaseTypeFilter(index, type) {
this.resetChange();
if (type == 1) {
this.purchase_type_filter[index] = !this.purchase_type_filter[index];
if (!this.purchase_type_filter[index]) {
this.searchParams.stock_tally_with_stock_in_stock_in_type_in = '';
}
this.$forceUpdate();
}
this.getData();
},
/**
* @param {Object} e
* @param {Object} type
* @param {Object} type(1:采购类型筛选 2:理货状态筛选)
* 筛选状态切换
*/
radioChange(e, type) {
let value = e.detail.value;
this.resetChange();
if (type == 1) {
this.searchParams.stock_tally_with_stock_in_stock_in_type_in = e.detail.value;
this.searchParams.stock_tally_with_stock_in_stock_in_type_in = value;
} else if (type == 2) {
this.searchParams.tally_status = e.detail.value;
}
//理货状态筛选
this.searchParams.tally_status = value;
this.getData();
}
},
/**
* 时间选择
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment