add
This commit is contained in:
parent
cde45cf5ee
commit
c1417005f6
2
.gitignore
vendored
2
.gitignore
vendored
@ -33,3 +33,5 @@ components.d.ts
|
||||
*.sln
|
||||
*.sw?
|
||||
.zip
|
||||
|
||||
helper.json
|
26
src/api/oa_examine_temp_item.ts
Normal file
26
src/api/oa_examine_temp_item.ts
Normal file
@ -0,0 +1,26 @@
|
||||
import request from "@/utils/request";
|
||||
|
||||
// 考核模板-考核项列表
|
||||
export function apiOaExamineTempItemLists(params: any) {
|
||||
return request.get({ url: "/jxgl.oa_examine_temp_item/lists", params });
|
||||
}
|
||||
|
||||
// 添加考核模板-考核项
|
||||
export function apiOaExamineTempItemAdd(params: any) {
|
||||
return request.post({ url: "/jxgl.oa_examine_temp_item/add", params });
|
||||
}
|
||||
|
||||
// 编辑考核模板-考核项
|
||||
export function apiOaExamineTempItemEdit(params: any) {
|
||||
return request.post({ url: "/jxgl.oa_examine_temp_item/edit", params });
|
||||
}
|
||||
|
||||
// 删除考核模板-考核项
|
||||
export function apiOaExamineTempItemDelete(params: any) {
|
||||
return request.post({ url: "/jxgl.oa_examine_temp_item/delete", params });
|
||||
}
|
||||
|
||||
// 考核模板-考核项详情
|
||||
export function apiOaExamineTempItemDetail(params: any) {
|
||||
return request.get({ url: "/jxgl.oa_examine_temp_item/detail", params });
|
||||
}
|
@ -5,7 +5,17 @@
|
||||
<el-form ref="formRef" :model="formData" label-width="120px" :rules="formRules">
|
||||
<el-row>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="考核类别" prop="type">
|
||||
<el-form-item label="自评人" prop="industry">
|
||||
<el-input v-model="formData.admin_user" readonly />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="被考核人" prop="industry">
|
||||
<el-input v-model="formData.admin_user" readonly placeholder="请选择被考核人" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="考核类型" prop="type">
|
||||
<el-select class="flex-1" v-model="formData.type" clearable placeholder="请选择考核类别">
|
||||
<el-option v-for="(item, index) in dictData.jxgl_check_type" :key="index"
|
||||
:label="item.name" :value="parseInt(item.value)" />
|
||||
@ -13,19 +23,16 @@
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="模版名称" prop="name">
|
||||
<el-input v-model="formData.name" clearable placeholder="请输入模版名称" readonly />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="创建人" prop="industry">
|
||||
<el-input v-model="formData.admin_user" readonly />
|
||||
<el-form-item label="考核月份" prop="name">
|
||||
<el-input v-model="formData.name" clearable placeholder="请输入模版名称" readonly
|
||||
:disabled="!formData.type" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</el-form>
|
||||
</el-card>
|
||||
|
||||
|
||||
<el-card>
|
||||
<el-row>
|
||||
<el-table :data="formData.detail">
|
||||
@ -47,6 +54,11 @@
|
||||
<el-input v-model="row.admin_user" placeholder="请输入考核说明" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="自评得分" prop="progress" show-overflow-tooltip>
|
||||
<template #default="{ row }">
|
||||
<el-input v-model="row.admin_user" placeholder="请输入自评得分" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" prop="progress" show-overflow-tooltip>
|
||||
<template #default="{ row }">
|
||||
<el-button @click="handleAdd" size="small">+</el-button>
|
||||
@ -61,6 +73,9 @@
|
||||
<el-descriptions-item label="考核总分" label-align="left" align="left">
|
||||
{ formData.org_name }
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="自评得分" label-align="left" align="left">
|
||||
{ formData.org_name }
|
||||
</el-descriptions-item>
|
||||
</el-descriptions>
|
||||
</el-card>
|
||||
</popup>
|
||||
@ -104,6 +119,7 @@ const formData = reactive({
|
||||
name: '',
|
||||
admin: useStore.id,
|
||||
admin_user: useStore.name,
|
||||
month: "",
|
||||
detail: []
|
||||
|
||||
})
|
||||
|
@ -72,7 +72,7 @@
|
||||
<pagination v-model="pager" @change="getLists" />
|
||||
</div>
|
||||
</el-card>
|
||||
<edit-popup v-if="showEdit" ref="editRef" :dict-data="dictData" @success="success()" @close="success()"
|
||||
<edit-popup v-if="showEdit" ref="editRef" :dict-data="dictData" @success="success()" @close="showEdit = false"
|
||||
:deptList="deptList" />
|
||||
|
||||
</div>
|
||||
|
@ -5,23 +5,19 @@
|
||||
<el-form ref="formRef" :model="formData" label-width="120px" :rules="formRules">
|
||||
<el-row>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="考核类别" prop="type">
|
||||
<el-select class="flex-1" v-model="formData.type" clearable placeholder="请选择考核类别">
|
||||
<el-form-item label="考核类别" prop="examine_type">
|
||||
<el-select class="flex-1" v-model="formData.examine_type" clearable placeholder="请选择考核类别">
|
||||
<el-option v-for="(item, index) in dictData.jxgl_check_type" :key="index"
|
||||
:label="item.name" :value="parseInt(item.value)" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="模版名称" prop="name">
|
||||
<el-input v-model="formData.name" clearable placeholder="请输入模版名称" readonly />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="创建人" prop="industry">
|
||||
<el-input v-model="formData.admin_user" readonly />
|
||||
<el-form-item label="模版名称" prop="temp_name">
|
||||
<el-input v-model="formData.temp_name" clearable placeholder="请输入模版名称" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<createUserLable :form-data="formData" flag></createUserLable>
|
||||
</el-row>
|
||||
</el-form>
|
||||
</el-card>
|
||||
@ -34,17 +30,17 @@
|
||||
</template>
|
||||
<el-table-column label="考核项" prop="progress" show-overflow-tooltip>
|
||||
<template #default="{ row }">
|
||||
<el-input v-model="row.admin_user" placeholder="请输入考核项" />
|
||||
<el-input v-model="row.examine_item" placeholder="请输入考核项" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="分数" prop="progress" show-overflow-tooltip>
|
||||
<template #default="{ row }">
|
||||
<el-input v-model="row.admin_user" placeholder="请输入分数" />
|
||||
<el-input v-model="row.score" placeholder="请输入分数" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="考核说明" prop="progress" show-overflow-tooltip>
|
||||
<template #default="{ row }">
|
||||
<el-input v-model="row.admin_user" placeholder="请输入考核说明" />
|
||||
<el-input v-model="row.examine_desc" placeholder="请输入考核说明" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" prop="progress" show-overflow-tooltip>
|
||||
@ -70,12 +66,9 @@
|
||||
<script lang="ts" setup name="manageProjectEdit">
|
||||
import type { FormInstance } from 'element-plus'
|
||||
import Popup from '@/components/popup/index.vue'
|
||||
import { apiManageProjectAdd, apiManageProjectEdit, apiManageProjectDetail } from '@/api/manage_project'
|
||||
import { apiOaExamineTempItemAdd, apiOaExamineTempItemEdit } from '@/api/oa_examine_temp_item.ts'
|
||||
import type { PropType } from 'vue'
|
||||
import { timeFormat } from '@/utils/util'
|
||||
import useUserStore from "@/stores/modules/user";
|
||||
import { apiCostApprovedProjectDetail } from "@/api/cost_approved_project";
|
||||
import { marketing_custom } from "@/components/dialogTable/dialogTableConfig";
|
||||
|
||||
|
||||
defineProps({
|
||||
@ -88,8 +81,6 @@ const emit = defineEmits(['success', 'close'])
|
||||
const formRef = shallowRef<FormInstance>()
|
||||
const popupRef = shallowRef<InstanceType<typeof Popup>>()
|
||||
const mode = ref('add')
|
||||
const useStore = useUserStore().userInfo
|
||||
|
||||
|
||||
|
||||
// 弹窗标题
|
||||
@ -100,10 +91,10 @@ const popupTitle = computed(() => {
|
||||
// 表单数据
|
||||
const formData = reactive({
|
||||
id: '',
|
||||
nature: '',
|
||||
name: '',
|
||||
admin: useStore.id,
|
||||
admin_user: useStore.name,
|
||||
examine_type: '',
|
||||
temp_name: '',
|
||||
create_user: '',
|
||||
cretate_time: '',
|
||||
detail: []
|
||||
|
||||
})
|
||||
@ -123,7 +114,7 @@ const formRules = reactive<any>({
|
||||
})
|
||||
|
||||
const setRules = () => {
|
||||
let lists = ['project_name']
|
||||
let lists = ['examine_type', 'temp_name', 'create_user', 'cretate_time']
|
||||
lists.forEach((item) => {
|
||||
formRules[item] = [{
|
||||
required: true,
|
||||
@ -144,8 +135,6 @@ const setFormData = async (data: Record<any, any>) => {
|
||||
formData[key] = data[key]
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -154,8 +143,8 @@ const handleSubmit = async () => {
|
||||
await formRef.value?.validate()
|
||||
const data = { ...formData, }
|
||||
mode.value == 'edit'
|
||||
? await apiManageProjectEdit(data)
|
||||
: await apiManageProjectAdd(data)
|
||||
? await apiOaExamineTempItemEdit(data)
|
||||
: await apiOaExamineTempItemAdd(data)
|
||||
popupRef.value?.close()
|
||||
emit('success')
|
||||
}
|
||||
|
@ -42,7 +42,6 @@
|
||||
</el-button>
|
||||
<div class="mt-4">
|
||||
<el-table border :data="pager.lists" @selection-change="handleSelectionChange">
|
||||
<el-table-column type="selection" width="55" />
|
||||
<el-table-column label="考核类别" prop="progress" show-overflow-tooltip />
|
||||
<el-table-column label="模版名称" prop="build_area_text" show-overflow-tooltip />
|
||||
<el-table-column label="考核总分" prop="project_level_text" show-overflow-tooltip />
|
||||
@ -50,12 +49,10 @@
|
||||
<el-table-column label="创建时间" prop="engineering_status_text" show-overflow-tooltip />
|
||||
<el-table-column label="操作" width="170" fixed="right">
|
||||
<template #default="{ row }">
|
||||
<el-button v-perms="['manage_basic.manage_project/edit']" type="primary" link
|
||||
@click="handleEdit(row)">
|
||||
<el-button type="primary" link @click="handleEdit(row)">
|
||||
编辑
|
||||
</el-button>
|
||||
<el-button v-perms="['manage_basic.manage_project/delete']" type="danger" link
|
||||
@click="handleDelete(row.id)">
|
||||
<el-button type="danger" link @click="handleDelete(row.id)">
|
||||
删除
|
||||
</el-button>
|
||||
</template>
|
||||
@ -75,10 +72,9 @@
|
||||
<script lang="ts" setup name="manageProjectLists">
|
||||
import { usePaging } from '@/hooks/usePaging'
|
||||
import { useDictData } from '@/hooks/useDictOptions'
|
||||
import { apiManageProjectLists, apiManageProjectDelete, apiManageProjectDetail } from '@/api/manage_project'
|
||||
import { apiOaExamineTempItemLists, apiOaExamineTempItemAdd, apiOaExamineTempItemDetail } from '@/api/oa_examine_temp_item.ts'
|
||||
import feedback from '@/utils/feedback'
|
||||
import EditPopup from './edit.vue'
|
||||
import { deptLists } from "@/api/org/department";
|
||||
|
||||
const route = useRoute()
|
||||
const router = useRouter()
|
||||
@ -113,7 +109,7 @@ const { dictData } = useDictData('jxgl_check_type')
|
||||
|
||||
// 分页相关
|
||||
const { pager, getLists, resetParams, resetPage } = usePaging({
|
||||
fetchFun: apiManageProjectLists,
|
||||
fetchFun: apiOaExamineTempItemLists,
|
||||
params: queryParams
|
||||
})
|
||||
|
||||
@ -126,7 +122,7 @@ const handleAdd = async () => {
|
||||
|
||||
// 编辑
|
||||
const handleEdit = async (data: any) => {
|
||||
let res = await apiManageProjectDetail({ id: data.id })
|
||||
let res = await apiOaExamineTempItemDetail({ id: data.id })
|
||||
showEdit.value = true
|
||||
await nextTick()
|
||||
editRef.value?.open('edit')
|
||||
|
@ -71,7 +71,7 @@
|
||||
@click="handledetail(row)">
|
||||
详情
|
||||
</el-button>
|
||||
<el-button type="primary" v-if="row.is_generate">
|
||||
<el-button type="primary" link v-if="row.is_generate">
|
||||
已生成合同
|
||||
</el-button>
|
||||
<el-button type=" primary" link @click="handleContract(row)" v-else>
|
||||
|
Loading…
x
Reference in New Issue
Block a user