| | |
| | | plain |
| | | icon="Plus" |
| | | @click="openDialog('add',{})" |
| | | v-hasPermi="['controlFactors:list:add']" |
| | | >新增</el-button> |
| | | </el-form-item> |
| | | <el-form-item label="企业名称:" v-if="data.isAdmin" style="margin-left: 20px"> |
| | | <el-form-item label="单位名称:" v-if="data.isAdmin" style="margin-left: 20px"> |
| | | <el-select v-model="data.queryParams.companyId" placeholder="请选择" filterable clearable> |
| | | <el-option |
| | | v-for="item in data.companyList" |
| | |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="年份:" style="margin-left: 20px"> |
| | | <el-select |
| | | <el-date-picker |
| | | v-model="data.queryParams.year" |
| | | placeholder="请选择年份" |
| | | style="width: 240px" |
| | | filterable |
| | | allow-create |
| | | default-first-option |
| | | :reserve-keyword="false" |
| | | @change="handleChangeNum" |
| | | > |
| | | <el-option |
| | | v-for="item in data.yearList" |
| | | :key="item.value" |
| | | :label="item.label" |
| | | :value="item.label" |
| | | /> |
| | | </el-select> |
| | | type="year" |
| | | value-format="YYYY" |
| | | /> |
| | | <!-- <el-select--> |
| | | <!-- v-model="data.queryParams.year"--> |
| | | <!-- placeholder="请选择年份"--> |
| | | <!-- style="width: 240px"--> |
| | | <!-- filterable--> |
| | | <!-- allow-create--> |
| | | <!-- default-first-option--> |
| | | <!-- :reserve-keyword="false"--> |
| | | <!-- @change="handleChangeNum"--> |
| | | <!-- >--> |
| | | <!-- <el-option--> |
| | | <!-- v-for="item in data.yearList"--> |
| | | <!-- :key="item.value"--> |
| | | <!-- :label="item.label"--> |
| | | <!-- :value="item.label"--> |
| | | <!-- />--> |
| | | <!-- </el-select>--> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" style="margin-left: 30px" @click="searchClick">查询</el-button> |
| | |
| | | <el-table-column label="操作" align="center" class-name="small-padding fixed-width" width="160"> |
| | | <template #default="scope"> |
| | | <el-button link type="primary" @click="openDialog('review',scope.row)" >查看</el-button> |
| | | <el-button link type="primary" @click="openDialog('edit',scope.row)" >编辑</el-button> |
| | | <el-button link type="danger" @click="handleDelete(scope.row)" >删除</el-button> |
| | | <el-button link type="primary" @click="openDialog('edit',scope.row)" v-hasPermi="['controlFactors:list:edit']">编辑</el-button> |
| | | <el-button link type="danger" @click="handleDelete(scope.row)" v-hasPermi="['controlFactors:list:del']">删除</el-button> |
| | | </template> |
| | | </el-table-column> |
| | | </el-table> |
| | |
| | | }else { |
| | | data.queryParams.companyId = userInfo.companyId |
| | | } |
| | | getNowYear() |
| | | getList(); |
| | | if(data.isAdmin){ |
| | | getCompanyList() |
| | | } |
| | | }); |
| | | const getNowYear = () =>{ |
| | | data.queryParams.year = new Date().getFullYear().toString() |
| | | } |
| | | const getList = async () => { |
| | | loading.value = true; |
| | | const res = await getControl(data.queryParams); |
| | |
| | | type: '' |
| | | } |
| | | } |
| | | getNowYear() |
| | | getList(); |
| | | |
| | | } |
| | |
| | | type: 'warning', |
| | | }) |
| | | .then( async() => { |
| | | const res = await delControl(val.id); |
| | | const res = await delControl(val.id,val.factorDiscernId); |
| | | if(res.code === 200){ |
| | | ElMessage({ |
| | | type: 'success', |