| | |
| | | }, |
| | | }; |
| | | app.MG.store.getStoreChannelList(query).then((res) => { |
| | | if (!res.datas.length) { |
| | | this.setData({ |
| | | disabledSecondList: true |
| | | }) |
| | | } else { |
| | | this.setData({ |
| | | disabledSecondList: false |
| | | }) |
| | | } |
| | | for (let index = 0; index < res.datas.length; index++) { |
| | | const item = res.datas[index]; |
| | | options.push({ |
| | |
| | | BaseType: 'DateTime' |
| | | } |
| | | } else if (this.data.sortList.value == 'time-desc') { |
| | | debugger |
| | | sort = { |
| | | PublicationDate: 'Desc', |
| | | BaseType: 'DateTime' |
| | |
| | | this.setData({ |
| | | noData: true, |
| | | }) |
| | | if (!this.data.pathList.length) { |
| | | // 未选择二级分类,且无图书 |
| | | this.setData({ |
| | | disabledSecondList: true |
| | | }) |
| | | } else { |
| | | this.setData({ |
| | | disabledSecondList: false |
| | | }) |
| | | } |
| | | } |
| | | if (this.data.triggered) { |
| | | this.setData({ |
| | |
| | | `${this.data.assortCheck.code}\\${e.detail.value}` : |
| | | this.data.assortCheck.code; |
| | | console.log(this.data.path); |
| | | |
| | | this.setData({ |
| | | pathList: [], |
| | | stairCode: e.detail.value, |
| | |
| | | path: path, |
| | | 'stairList.value': e.detail.value, |
| | | }); |
| | | this.getBookList(path); |
| | | this.getSecondList(path); |
| | | |
| | | if (e.detail.value == '') { |
| | | this.setData({ |
| | | disabledSecondList: true |
| | | }) |
| | | }); |
| | | } else { |
| | | this.setData({ |
| | | disabledSecondList: false |
| | | }) |
| | | this.getSecondList(path); |
| | | } |
| | | this.getBookList(path); |
| | | console.log(this.data.disabledSecondList); |
| | | }, |
| | | // 二级分类切换 |