|
@@ -207,10 +207,12 @@ export default {
|
|
|
this.curTab = uni.getStorageSync('curTab');
|
|
|
} else {
|
|
|
let systemList = this.$store.state.vuex_systemSetList;
|
|
|
- let cycleObj = systemList.find(item => {
|
|
|
- return item.remarks == 'sales_bill_period';
|
|
|
- });
|
|
|
- this.curTab = this.placeTab.findIndex(con => con.name == cycleObj.valueShow);
|
|
|
+ if(systemList){
|
|
|
+ let cycleObj = systemList.find(item => {
|
|
|
+ return item.remarks == 'sales_bill_period';
|
|
|
+ });
|
|
|
+ this.curTab = this.placeTab.findIndex(con => con.name == cycleObj.valueShow);
|
|
|
+ }
|
|
|
}
|
|
|
this.cycleName = this.changeShowTime();
|
|
|
// 获取选择客户
|
|
@@ -304,18 +306,22 @@ export default {
|
|
|
const _this = this;
|
|
|
queryUnsettleSaleList(this.params).then(res => {
|
|
|
if (res.status == 200) {
|
|
|
- this.bill = res.data;
|
|
|
let chooseArr = uni.getStorageSync('chooseList');
|
|
|
if (chooseArr && chooseArr.length > 0) {
|
|
|
- res.data.map(item => {
|
|
|
+ res.data.forEach(item => {
|
|
|
const row = chooseArr.findIndex(k => k.bizSn == item.bizSn);
|
|
|
item.checked = row > -1;
|
|
|
});
|
|
|
}
|
|
|
+ this.bill = res.data;
|
|
|
this.$refs.bill.setData(res.data);
|
|
|
+ this.getChooseList()
|
|
|
}
|
|
|
});
|
|
|
},
|
|
|
+ getChooseList(){
|
|
|
+ this.chooseList=this.bill.filter(item=>item.checked);
|
|
|
+ },
|
|
|
// 时间 change
|
|
|
dateChange(date) {
|
|
|
this.dateArray = date.startDate + ' ~ ' + date.endDate;
|