|
@@ -48,26 +48,26 @@ export default {
|
|
res.data.records.forEach(item => { item.flg = false })
|
|
res.data.records.forEach(item => { item.flg = false })
|
|
// this.planList = res.data.records;
|
|
// this.planList = res.data.records;
|
|
this.planList = []
|
|
this.planList = []
|
|
- res.data.records.forEach((item => {
|
|
|
|
- const newProgress = item.progress.split('%')[0]
|
|
|
|
- const progressFlag = newProgress ? (newProgress > 0 && newProgress < 100) ? true : false : false
|
|
|
|
- if(item.progress) {
|
|
|
|
- item.newProgress = newProgress
|
|
|
|
- }
|
|
|
|
- const { hasAllocation, hasAllAllocation } = item
|
|
|
|
- if(hasAllocation && !hasAllAllocation) {
|
|
|
|
- item.backgroundClass = 'blues'
|
|
|
|
- return
|
|
|
|
- }
|
|
|
|
- if(progressFlag) {
|
|
|
|
- item.backgroundClass = 'reds'
|
|
|
|
- return
|
|
|
|
- }
|
|
|
|
- if(hasAllocation && hasAllAllocation) {
|
|
|
|
- item.backgroundClass = 'greens'
|
|
|
|
- return
|
|
|
|
- }
|
|
|
|
- }))
|
|
|
|
|
|
+ // res.data.records.forEach((item => {
|
|
|
|
+ // const newProgress = item.progress && item.progress.split('%')[0]
|
|
|
|
+ // const progressFlag = newProgress ? (newProgress > 0 && newProgress < 100) ? true : false : false
|
|
|
|
+ // if(item.progress) {
|
|
|
|
+ // item.newProgress = newProgress
|
|
|
|
+ // }
|
|
|
|
+ // const { hasAllocation, hasAllAllocation } = item
|
|
|
|
+ // if(hasAllocation && !hasAllAllocation) {
|
|
|
|
+ // item.backgroundClass = 'blues'
|
|
|
|
+ // return
|
|
|
|
+ // }
|
|
|
|
+ // if(progressFlag) {
|
|
|
|
+ // item.backgroundClass = 'reds'
|
|
|
|
+ // return
|
|
|
|
+ // }
|
|
|
|
+ // if(hasAllocation && hasAllAllocation) {
|
|
|
|
+ // item.backgroundClass = 'greens'
|
|
|
|
+ // return
|
|
|
|
+ // }
|
|
|
|
+ // }))
|
|
setTimeout(() => {
|
|
setTimeout(() => {
|
|
this.$set(this, 'planList', res.data.records)
|
|
this.$set(this, 'planList', res.data.records)
|
|
}, 100)
|
|
}, 100)
|