|
@@ -39,11 +39,11 @@
|
|
{{parameter.endDate?parameter.startDate+' - '+parameter.endDate:'请选择查询日期'}}
|
|
{{parameter.endDate?parameter.startDate+' - '+parameter.endDate:'请选择查询日期'}}
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
- <view class="modal-row">
|
|
|
|
|
|
+ <view @click='show1=true' class="modal-row">
|
|
<view class="">仓库名称</view>
|
|
<view class="">仓库名称</view>
|
|
<view>{{parameter.warehouseName}}</view>
|
|
<view>{{parameter.warehouseName}}</view>
|
|
</view>
|
|
</view>
|
|
-
|
|
|
|
|
|
+ <u-picker mode="selector" v-model="show1" @confirm='warehouseConfirm' range-key='warehouseName' :default-selector="[0]" :range="warehouseList"></u-picker>
|
|
</view>
|
|
</view>
|
|
</u-modal>
|
|
</u-modal>
|
|
<u-calendar v-model="show" :mode="mode" @change="change" range-color='#22C572' btn-type='success'
|
|
<u-calendar v-model="show" :mode="mode" @change="change" range-color='#22C572' btn-type='success'
|
|
@@ -63,7 +63,9 @@
|
|
data() {
|
|
data() {
|
|
return {
|
|
return {
|
|
isShowAlert: false,
|
|
isShowAlert: false,
|
|
|
|
+ show1:false,
|
|
content: '当前登录身份已失效,请重新登录!',
|
|
content: '当前登录身份已失效,请重新登录!',
|
|
|
|
+ warehouseList:[],
|
|
parameter: {
|
|
parameter: {
|
|
startDate: "",
|
|
startDate: "",
|
|
endDate: '',
|
|
endDate: '',
|
|
@@ -90,12 +92,27 @@
|
|
onLoad: function(option) {
|
|
onLoad: function(option) {
|
|
console.log(option)
|
|
console.log(option)
|
|
this.searchMonth = option.searchMonth
|
|
this.searchMonth = option.searchMonth
|
|
- this.init()
|
|
|
|
|
|
+ this.init()
|
|
|
|
+ },
|
|
|
|
+ onNavigationBarButtonTap() {
|
|
|
|
+ this.parameter.warehouseName = this.costList[0].warehouseName
|
|
|
|
+ this.parameter.startDate = helper.getNowFormatDate()
|
|
|
|
+ this.parameter.endDate = helper.getNowFormatDate()
|
|
|
|
+ this.$api.doRequest('get', '/warehouseBaseInfo/selectWarehouseSelf', {
|
|
|
|
+ compId: uni.getStorageSync('pcUserInfo').compId,
|
|
|
|
+ }).then(res => {
|
|
|
|
+ this.warehouseList=res.data.data
|
|
|
|
+ this.isShowDetailBtn = true
|
|
|
|
+ })
|
|
},
|
|
},
|
|
computed: {
|
|
computed: {
|
|
...mapState(['hasLogin', 'userInfo']),
|
|
...mapState(['hasLogin', 'userInfo']),
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
|
|
+ warehouseConfirm(e){
|
|
|
|
+ console.log(e)
|
|
|
|
+ this.parameter.warehouseName = this.warehouseList[e[0]].warehouseName
|
|
|
|
+ },
|
|
alertBtn() {
|
|
alertBtn() {
|
|
uni.navigateTo({
|
|
uni.navigateTo({
|
|
url: '/pages/public/login'
|
|
url: '/pages/public/login'
|
|
@@ -131,8 +148,8 @@
|
|
title: '正在加载'
|
|
title: '正在加载'
|
|
})
|
|
})
|
|
this.$api.doRequest('post', _url, {
|
|
this.$api.doRequest('post', _url, {
|
|
- startDate: this.parameter.startDate,
|
|
|
|
- endDate: this.parameter.endDate,
|
|
|
|
|
|
+ startDate: this.parameter.startDate+' 00:00:00',
|
|
|
|
+ endDate: this.parameter.endDate+' 00:00:00',
|
|
warehouseName: this.parameter.warehouseName
|
|
warehouseName: this.parameter.warehouseName
|
|
}).then(res => {
|
|
}).then(res => {
|
|
uni.hideLoading()
|
|
uni.hideLoading()
|
|
@@ -158,10 +175,8 @@
|
|
this.isShowDetailBtn = false
|
|
this.isShowDetailBtn = false
|
|
},
|
|
},
|
|
toDetail(warehouseName) {
|
|
toDetail(warehouseName) {
|
|
- this.parameter.warehouseName = warehouseName
|
|
|
|
- this.parameter.startDate = helper.getNowFormatDate()
|
|
|
|
- this.parameter.endDate = helper.getNowFormatDate()
|
|
|
|
- this.isShowDetailBtn = true
|
|
|
|
|
|
+ // this.parameter.warehouseName = warehouseName
|
|
|
|
+
|
|
},
|
|
},
|
|
init() {
|
|
init() {
|
|
if (!this.hasLogin) {
|
|
if (!this.hasLogin) {
|