Commit 8bd4ecec by 李伟康

commit 提交

1 parent f8d64cce
...@@ -99,7 +99,8 @@ export default { ...@@ -99,7 +99,8 @@ export default {
value: 'profitSituation', value: 'profitSituation',
percent: 'profitSituationRatio', percent: 'profitSituationRatio',
tips: '毛利率', tips: '毛利率',
tipsValue: 'grossProfitMargin' tipsValue: 'grossProfitMargin',
tipsUnit:'%'
} }
], ],
boardList: [ boardList: [
...@@ -169,6 +170,7 @@ export default { ...@@ -169,6 +170,7 @@ export default {
if (res[key] != null) { if (res[key] != null) {
if (key == 'outputCompletionProgress') res[key] = NP.times(res[key], 0.01) if (key == 'outputCompletionProgress') res[key] = NP.times(res[key], 0.01)
if (key == 'budget') res[key] = '¥' + res[key].toLocaleString() if (key == 'budget') res[key] = '¥' + res[key].toLocaleString()
if(key == 'grossProfitMargin') res[key] += '%'
} }
// else res[key] = '-' // else res[key] = '-'
}) })
......
...@@ -107,9 +107,14 @@ export default { ...@@ -107,9 +107,14 @@ export default {
// 在beforeDestroy钩子中移除事件监听 // 在beforeDestroy钩子中移除事件监听
beforeDestroy () { beforeDestroy () {
window.removeEventListener('popstate', this.preventBack) window.removeEventListener('popstate', this.preventBack)
window.onresize = null
}, },
// 在你的Vue组件的mounted钩子中添加事件监听 // 在你的Vue组件的mounted钩子中添加事件监听
mounted () { mounted () {
// window.onresize = () => {
// this.tabboxWidth = this.$refs.tabbox.offsetWidth
// this.checkEl()
// }
history.pushState(null, null, document.URL) history.pushState(null, null, document.URL)
window.addEventListener('popstate', this.preventBack) window.addEventListener('popstate', this.preventBack)
if (this.tabboxWidth == 0) this.tabboxWidth = this.$refs.tabbox.offsetWidth if (this.tabboxWidth == 0) this.tabboxWidth = this.$refs.tabbox.offsetWidth
...@@ -181,6 +186,10 @@ export default { ...@@ -181,6 +186,10 @@ export default {
this.dropdownList.push(tab[len]) this.dropdownList.push(tab[len])
this.tab.splice(len, 1) this.tab.splice(len, 1)
} }
if (this.dropdownList.length && offsetLeft + offsetWidth / 2 < tabboxWidth - 54) {
this.tab.push(this.dropdownList[0])
this.closeDrop(0)
}
} }
}) })
}, },
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!