| | |
| | | this.getLedgerType(now.add(-1, 'M').format('YYYY-MM-DD'), r => { |
| | | this.setData({ |
| | | lastMonthInfo: r[2] |
| | | }, true) |
| | | }) //上月 |
| | | }) |
| | | }, true) //上月 |
| | | }, |
| | | |
| | | /** |
| | |
| | | monthInfo.overtime = moment().date() - this.DEADLINEDAY |
| | | monthInfo.percent = Math.round(monthInfo.finishedMust / monthInfo.totalMust * 100) |
| | | |
| | | console.log(lastMonth); |
| | | console.log(monthInfo); |
| | | |
| | | //选项卡 |
| | | var t = [] |
| | | var p = [] |
| | |
| | | var i = e.currentTarget.dataset.index.split(',') |
| | | var indexGroup = [parseInt(i[0]), parseInt(i[1])] |
| | | var ledger = this.data.pageList[indexGroup[0]][indexGroup[1]] |
| | | console.log(indexGroup); |
| | | console.log(ledger); |
| | | |
| | | var that = this |
| | | wx.navigateTo({ |
| | |
| | | let that = this; |
| | | let query = wx.createSelectorQuery(); //必须要先创建一个查询 |
| | | query.select(element).boundingClientRect(function (rect) { |
| | | // let pageheight = that.data.pageheight.split('px')[0] |
| | | // pageheight = parseInt(pageheight) |
| | | // if (rect > pa) { |
| | | |
| | | // } |
| | | that.setData({ |
| | | pageheight: rect.height + 'px' |
| | | }); |
| | | console.log(rect.height); |
| | | let pageheight = that.data.pageheight.split('px')[0] |
| | | pageheight = parseInt(pageheight) |
| | | if (rect.height > pageheight) { |
| | | that.setData({ |
| | | pageheight: rect.height + 'px' |
| | | }); |
| | | } |
| | | }).exec(); |
| | | }, |
| | | swichNav: function (e) { |
| | |
| | | currentTab: e.target.dataset.current, |
| | | navScrollLeft: e.target.dataset.current >= 3 ? ((e.target.dataset.current) * 60) : 0 //判断当前选中的个数是否是第5个 |
| | | }) |
| | | that.tabsHeight('.page' + e.target.dataset.current); //查询哪一个元素 |
| | | // that.tabsHeight('.page' + e.target.dataset.current); //查询哪一个元素 |
| | | } |
| | | }, |
| | | bindChange: function (e) { |
| | |
| | | currentTab: e.detail.current, |
| | | navScrollLeft: e.detail.current >= 3 ? ((e.detail.current) * 60) : 0 //判断当前选中的个数是否是第5个 |
| | | }); |
| | | // that.tabsHeight('.page'+e.target.dataset.current); //查询哪一个元素 |
| | | that.tabsHeight('.page' + e.detail.current); //查询哪一个元素 |
| | | }, |
| | | |
| | | changeMonth(){ |