zzq
2023-10-07 36f65570d93cced7996e337e0b8d289db61662bc
fix:表格合计动态添加单位
2个文件已修改
8 ■■■■■ 已修改文件
src/components/makepager/TableCommonView.vue 5 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/reportForm/locationReport/index.vue 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/components/makepager/TableCommonView.vue
@@ -238,10 +238,11 @@
                  if (!isNaN(value)) {
                    return prev + curr
                  } else {
                    return prev
                    return prev
                  }
                }, 0)
                sums[index] = this.tableList.tableColumn[index - 1].unit + "" + sums[index]
                let unitIndex = this.tableList.tableColumn.findIndex(obj => obj.label === column.label);
                sums[index]+=this.tableList.tableColumn[unitIndex].unit
              } else {
                sums[index] = ""
              }
src/views/reportForm/locationReport/index.vue
@@ -21,6 +21,7 @@
          :table-list="tableList"
          @selTableCol="selTableCol"
          @tableRowClick="tableRowClick"
          :showSummary="true"
        >
          <template slot="tableButton">
            <el-table-column label="操作" width="210" align="center">
@@ -179,7 +180,7 @@
          prop: "unit",
          width: 120,
          default: false,
          isShowColumn: showcol.includes("价值")
          isShowColumn: showcol.includes("单位")
        },
        {
          label: "价值",