祖安之光
2025-10-22 e6574955495c2063de3a20cf372ebb135f260753
src/views/build/conpanyFunctionConsult/qualityObjectives/table/index.vue
@@ -8,6 +8,7 @@
              plain
              icon="Plus"
              @click="openAddDialog"
              v-hasPermi="['qualityGoalTable:list:add']"
          >新增</el-button>
        </el-form-item>
        <el-form-item label="企业名称:" v-if="data.isAdmin" style="margin-left: 20px">
@@ -110,9 +111,9 @@
      </el-table-column>
      <el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="160">
        <template #default="scope">
          <el-button link type="primary"  @click="scope.row.type == 1?openDialog('review',scope.row):openDeptDialog('review',scope.row) " >查看</el-button>
          <el-button link type="primary"  @click="scope.row.type == 1?openDialog('edit',scope.row):openDeptDialog('edit',scope.row)  " >编辑</el-button>
          <el-button link type="danger"  @click="handleDelete(scope.row)" >删除</el-button>
          <el-button link type="primary"  @click="scope.row.type == 1?openDialog('review',scope.row):openDeptDialog('review',scope.row)">查看</el-button>
          <el-button link type="primary"  @click="scope.row.type == 1?openDialog('edit',scope.row):openDeptDialog('edit',scope.row)" v-hasPermi="['qualityGoalTable:list:edit']">编辑</el-button>
          <el-button link type="danger"  @click="handleDelete(scope.row)" v-hasPermi="['qualityGoalTable:list:del']">删除</el-button>
        </template>
      </el-table-column>
    </el-table>
@@ -328,7 +329,6 @@
  let name = ''
  data.forEach(item => {
    name = ''
    console.log('item',item)
    if(item.type == 1){
      templatePath.value = '/tableCompanyExample.docx'
      name = item.companyName
@@ -341,11 +341,15 @@
    const month = (now.getMonth() +1).toString().padStart(2, '0');
    item.nowDate = year + '-' + month
    item.tableData = item.qualityTargets.map((i,index) => {
      return {
      return{
        ...i,
        nuum: index+1,
        nuumRowSpan:`${i.qualityTargetMesses.length}cm`,
        messageRowSpan:`${i.qualityTargetMesses.length}cm`,
        qualityTargetMesses: i.qualityTargetMesses.map((q,qindex) => {
          return{
            ...q,
            first: qindex == 0,
            nuum: index+1
          }
        })
      }
    })
    try {