Commit 4ceba86b by wangyalan-git

库存统计,领用记录,库存统计,领用详情

parent 40355709
...@@ -127,11 +127,14 @@ export default { ...@@ -127,11 +127,14 @@ export default {
// 数据 // 数据
getHomeData () { getHomeData () {
const d = new Date() const d = new Date()
const queryTime = d.getFullYear() + '-' + (d.getMonth() + 1) + '-' + d.getDate() const queryTime = d.getFullYear() + '-' + this.completion((d.getMonth() + 1)) + '-' + this.completion(d.getDate())
getHomeData({ queryTime: queryTime }).then(res => { getHomeData({ queryTime: queryTime }).then(res => {
this.homeData = res.data this.homeData = res.data
}) })
}, },
completion (s) {
return s < 10 ? '0' + s : s
},
// 类别 // 类别
getCategoryList () { getCategoryList () {
getCategoryList().then(res => { getCategoryList().then(res => {
......
...@@ -155,13 +155,16 @@ export default { ...@@ -155,13 +155,16 @@ export default {
// 日期 // 日期
confirmDate (data) { confirmDate (data) {
const d = new Date(data) const d = new Date(data)
this.params.queryTime = d.getFullYear() + '-' + (d.getMonth() + 1) + '-' + d.getDate() this.params.queryTime = d.getFullYear() + '-' + this.completion((d.getMonth() + 1)) + '-' + this.completion(d.getDate())
this.timeTitle = this.params.queryTime this.timeTitle = this.params.queryTime
this.$refs.myPicker.toggle() this.$refs.myPicker.toggle()
this.list = [] this.list = []
this.params.pageNum = 1 this.params.pageNum = 1
this.getList() this.getList()
}, },
completion (s) {
return s < 10 ? '0' + s : s
},
// 全部记录 // 全部记录
queryAll () { queryAll () {
this.params.queryTime = null this.params.queryTime = null
......
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 to comment