|
@@ -71,12 +71,12 @@
|
|
|
:min="0"
|
|
|
:max="999999999"
|
|
|
placeholder="请输入"
|
|
|
- :precision="0"
|
|
|
+ :precision="pageType === 'REGIONAL_ESTIMATED_ORDER'?2:0"
|
|
|
:value="text"
|
|
|
:id="'estimatedOrderList-input-'+record.id"
|
|
|
- @change="e => handleChange(e,record, col)" />
|
|
|
+ @blur="e => handleChange(e.target.value,record, col)" />
|
|
|
<template v-else>
|
|
|
- {{ text }}
|
|
|
+ {{ pageType === 'REGIONAL_ESTIMATED_ORDER'?toThousands(text) :text }}
|
|
|
</template>
|
|
|
</div>
|
|
|
</template>
|
|
@@ -117,7 +117,6 @@
|
|
|
|
|
|
<script>
|
|
|
import { commonMixin } from '@/utils/mixin'
|
|
|
-import debounce from 'lodash/debounce'
|
|
|
// 组件
|
|
|
import { STable } from '@/components'
|
|
|
// 接口
|
|
@@ -133,8 +132,6 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
data () {
|
|
|
- const _this = this
|
|
|
- _this.handleChange = debounce(_this.handleChange, 800)
|
|
|
return {
|
|
|
spinning: false,
|
|
|
disabled: false, // 查询、重置按钮是否可操作
|
|
@@ -205,7 +202,7 @@ export default {
|
|
|
{ title: '10月', dataIndex: 'value10', width: '8%', align: 'right', scopedSlots: { customRender: 'month10' } },
|
|
|
{ title: '11月', dataIndex: 'value11', width: '8%', align: 'right', scopedSlots: { customRender: 'month11' } },
|
|
|
{ title: '12月', dataIndex: 'value12', width: '8%', align: 'right', scopedSlots: { customRender: 'month12' } },
|
|
|
- { title: '合计', dataIndex: 'summation', width: '11%', align: 'right', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
|
|
|
+ { title: '合计', dataIndex: 'summation', width: '11%', align: 'right', customRender: function (text) { return ((text || text == 0) ? (_this.pageType === 'REGIONAL_ESTIMATED_ORDER' ? _this.toThousands(text) : text) : '--') } },
|
|
|
{ title: '操作', scopedSlots: { customRender: 'action' }, width: '11%', align: 'center' }
|
|
|
]
|
|
|
if (_this.pageType === 'REGIONAL_ESTIMATED_ORDER') {
|
|
@@ -246,6 +243,7 @@ export default {
|
|
|
handleSearch () {
|
|
|
this.$refs.ruleForm.validate(valid => {
|
|
|
if (valid) {
|
|
|
+ this.editingKey = ''
|
|
|
this.$refs.table.refresh(true)
|
|
|
} else {
|
|
|
this.$message.error('请选择年份')
|
|
@@ -301,7 +299,6 @@ export default {
|
|
|
calculateTotal (rowData) {
|
|
|
const keys = Array.from({ length: 12 }, (_, i) => 'value' + this.padZero(i + 1))
|
|
|
const totalNum = keys.reduce((sum, key) => sum + (Number(rowData[key]) || 0), 0)
|
|
|
- console.log('sdsdsd:', totalNum)
|
|
|
return totalNum
|
|
|
},
|
|
|
// 重置
|
|
@@ -331,7 +328,10 @@ export default {
|
|
|
}
|
|
|
</script>
|
|
|
<style lang="less" scoped>
|
|
|
-::v-deep.button-info[disabled] {
|
|
|
+/deep/.button-info[disabled] {
|
|
|
color: gray;
|
|
|
}
|
|
|
+/deep/.ant-input-number-handler-wrap {
|
|
|
+ display: none;
|
|
|
+}
|
|
|
</style>
|