Commit 0100b9e1 by LJM

移动端--【理货记录】增加理货时间筛选

parent b3d57bda
...@@ -17,6 +17,7 @@ ...@@ -17,6 +17,7 @@
<text class="iconfont icon-a-juxing11" @click="clearInput('end')" v-if="searchParams.create_time_end != ''"></text> <text class="iconfont icon-a-juxing11" @click="clearInput('end')" v-if="searchParams.create_time_end != ''"></text>
</view> </view>
</view> </view>
<!-- 全量搜索 -->
<view class="radio-search-box row verCenter"> <view class="radio-search-box row verCenter">
<radio-group @change="radioChange" class="row verCenter"> <radio-group @change="radioChange" class="row verCenter">
<label class="radio row verCenter"> <label class="radio row verCenter">
...@@ -260,7 +261,9 @@ ...@@ -260,7 +261,9 @@
</scroll-view> </scroll-view>
</view> </view>
</template> </template>
<view class="btn row rowCenter verCenter"><view class="row btn1 row rowCenter verCenter" style="width:100%" @click="addStockInRegister(2, detail.stock_in_id)">到货登记</view></view> <view class="btn row rowCenter verCenter">
<view class="row btn1 row rowCenter verCenter" style="width:100%" @click="addStockInRegister(2, detail.stock_in_id)">到货登记</view>
</view>
</view> </view>
</uni-drawer> </uni-drawer>
<!-- 无单号登记弹窗 --> <!-- 无单号登记弹窗 -->
...@@ -477,11 +480,11 @@ ...@@ -477,11 +480,11 @@
</template> </template>
<script> <script>
import { API } from '@/util/api.js'; import { API } from '@/util/api.js';
import { createArray } from '@/util/util.js'; import { createArray } from '@/util/util.js';
import debounce from 'lodash/debounce'; import debounce from 'lodash/debounce';
export default { export default {
data() { data() {
return { return {
indicatorDots: true, indicatorDots: true,
...@@ -507,8 +510,8 @@ export default { ...@@ -507,8 +510,8 @@ export default {
zyGoodsData: [], //自营货品信息 zyGoodsData: [], //自营货品信息
saveZyGoodsParams: [], //自营数据参数集合 saveZyGoodsParams: [], //自营数据参数集合
searchParams: { searchParams: {
create_time_begin: '', create_time_begin: '', //起始日期
create_time_end: '', create_time_end: '', //结束日期
mobile_register_all_search: '', //全量搜索 mobile_register_all_search: '', //全量搜索
stock_in_with_stock_in_items_inhouse: '', //入仓单号 stock_in_with_stock_in_items_inhouse: '', //入仓单号
tracking_no: '' //fedex tracking_no: '' //fedex
...@@ -1087,9 +1090,9 @@ export default { ...@@ -1087,9 +1090,9 @@ export default {
this.page = 1; this.page = 1;
} }
} }
}; };
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">
@import '@/assets/css/arrivalRegister/index.scss'; @import '@/assets/css/arrivalRegister/index.scss';
</style> </style>
\ No newline at end of file
<template> <template>
<view class="tallyReceive"> <view class="tallyReceive">
<view class="search-box row bothSide verCenter"> <!-- 时间筛选 -->
<view class="time-interval row bothSide verCenter">
<view class="time-interval-box row verCenter bothSide">
<view class="row verCenter">
<text class="iconfont icon-juxing4"></text>
<picker mode="date" @change="bindTimeChange(1, $event)"><input type="text" class="uni-input" placeholder="请选择起始时间" placeholder-style="color:#919399" v-model="searchParams.create_time_begin" /></picker>
</view>
<text class="iconfont icon-a-juxing11" @click="clearInput('start')" v-if="searchParams.create_time_begin != ''"></text>
</view>
<view class="time-interval-box row verCenter bothSide">
<view class="row verCenter">
<text class="iconfont icon-juxing4"></text>
<picker mode="date" @change="bindTimeChange(2, $event)"><input type="text" class="uni-input" placeholder="请选择结束时间" placeholder-style="color:#919399" v-model="searchParams.create_time_end" /></picker>
</view>
<text class="iconfont icon-a-juxing11" @click="clearInput('end')" v-if="searchParams.create_time_end != ''"></text>
</view>
</view>
<!-- 全量搜索 -->
<view class="search-box row bothSide verCenter" style="margin-top: 15rpx;">
<view class="sn row rowCenter verCenter"> <view class="sn row rowCenter verCenter">
<picker @change="bindPickerChange" :value="index" :range="array"> <picker @change="bindPickerChange" :value="index" :range="array">
<view class="row verCenter"> <view class="row verCenter">
...@@ -106,7 +124,9 @@ ...@@ -106,7 +124,9 @@
<text class="label">明细备注:</text> <text class="label">明细备注:</text>
<text class="desc">{{ item.upstream_remark }}</text> <text class="desc">{{ item.upstream_remark }}</text>
</view> </view>
<view class="btn-box row"><view class="detail-btn row rowCenter verCenter" @click="showDrawer(item)">详情</view></view> <view class="btn-box row">
<view class="detail-btn row rowCenter verCenter" @click="showDrawer(item)">详情</view>
</view>
</view> </view>
</view> </view>
<view class="no-date column rowCenter verCenter" v-else> <view class="no-date column rowCenter verCenter" v-else>
...@@ -265,7 +285,9 @@ ...@@ -265,7 +285,9 @@
<view class="pic-list"> <view class="pic-list">
<view class="pic-title">理货照片:</view> <view class="pic-title">理货照片:</view>
<view class="row pic-wrap"> <view class="row pic-wrap">
<view class="box" v-for="(item, index) in image_list" :key="index"><image @click="previewChange(image_list, index)" :src="item" mode="aspectFill" lazy-load="true"></image></view> <view class="box" v-for="(item, index) in image_list" :key="index">
<image @click="previewChange(image_list, index)" :src="item" mode="aspectFill" lazy-load="true"></image>
</view>
</view> </view>
</view> </view>
</template> </template>
...@@ -329,7 +351,9 @@ ...@@ -329,7 +351,9 @@
</view> </view>
</view> </view>
</template> </template>
<view class="btn row verCenter bothSide"><view class="btn1 row rowCenter verCenter" @click="cancelTallyReceive(2, detail.tally_id, detail.stock_in_item_id)">取消理货</view></view> <view class="btn row verCenter bothSide">
<view class="btn1 row rowCenter verCenter" @click="cancelTallyReceive(2, detail.tally_id, detail.stock_in_item_id)">取消理货</view>
</view>
</view> </view>
</uni-drawer> </uni-drawer>
<!-- 修改容器 --> <!-- 修改容器 -->
...@@ -338,11 +362,11 @@ ...@@ -338,11 +362,11 @@
</template> </template>
<script> <script>
import { API } from '@/util/api.js'; import { API } from '@/util/api.js';
import debounce from 'lodash/debounce'; import debounce from 'lodash/debounce';
import { createArray } from '@/util/util.js'; import { createArray } from '@/util/util.js';
export default { export default {
data() { data() {
return { return {
page: 1, page: 1,
...@@ -359,6 +383,8 @@ export default { ...@@ -359,6 +383,8 @@ export default {
image_list: [], //图片列表 image_list: [], //图片列表
hasMoreData: true, //是否分页加载 hasMoreData: true, //是否分页加载
searchParams: { searchParams: {
create_time_begin: '', //起始日期
create_time_end: '', //结束日期
mobile_have_tally_all_search: '', //全量搜索 mobile_have_tally_all_search: '', //全量搜索
stock_in_with_stock_in_items_inhouse: '', //入仓单号 stock_in_with_stock_in_items_inhouse: '', //入仓单号
container_id: '', //容器, container_id: '', //容器,
...@@ -402,6 +428,29 @@ export default { ...@@ -402,6 +428,29 @@ export default {
} }
this.getData(); this.getData();
}, },
/**
* 时间选择
*/
bindTimeChange(type, e) {
this.resetChange();
if (type == 1) {
this.searchParams.create_time_begin = e.detail.value;
} else if (type == 2) {
this.searchParams.create_time_end = e.detail.value;
}
var timeA = new Date(this.searchParams.create_time_begin).getTime();
var timeB = new Date(this.searchParams.create_time_end).getTime();
if (timeB < timeA) {
uni.showToast({
title: '不能小于开始时间',
icon: 'none'
});
this.searchParams.create_time_end = this.searchParams.create_time_begin;
return false;
}
this.getData();
},
bindPickerChange: function(e) { bindPickerChange: function(e) {
console.log('picker发送选择改变,携带值为', e.detail.value); console.log('picker发送选择改变,携带值为', e.detail.value);
this.index = e.detail.value; this.index = e.detail.value;
...@@ -477,7 +526,14 @@ export default { ...@@ -477,7 +526,14 @@ export default {
/** /**
* 清空数据 * 清空数据
*/ */
clearInput() { clearInput(type) {
if (type == 'start') {
//起始时间清空
this.searchParams.create_time_begin = '';
} else if (type == 'end') {
//结束时间清空
this.searchParams.create_time_end = '';
} else {
this.resetChange(); this.resetChange();
this.input_flag = false; this.input_flag = false;
if (this.index == 0) { if (this.index == 0) {
...@@ -486,6 +542,7 @@ export default { ...@@ -486,6 +542,7 @@ export default {
this.searchParams.stock_in_with_stock_in_items_inhouse = ''; this.searchParams.stock_in_with_stock_in_items_inhouse = '';
} }
this.getData(); this.getData();
}
}, },
/** /**
* 单号搜索 * 单号搜索
...@@ -693,9 +750,9 @@ export default { ...@@ -693,9 +750,9 @@ export default {
this.page = 1; this.page = 1;
} }
} }
}; };
</script> </script>
<style scoped lang="scss"> <style scoped lang="scss">
@import '@/assets/css/tallyReceive/index.scss'; @import '@/assets/css/tallyReceive/index.scss';
</style> </style>
\ No newline at end of file
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