修改流程 修改打包报错
This commit is contained in:
103
docs/hooks-table使用检查.md
Normal file
103
docs/hooks-table使用检查.md
Normal file
@@ -0,0 +1,103 @@
|
|||||||
|
# hooks/table 使用方法检查
|
||||||
|
|
||||||
|
## 一、useTable 源码要点(`src/hooks/table.ts`)
|
||||||
|
|
||||||
|
### 1. 入参 `BasicTableProps`
|
||||||
|
|
||||||
|
| 属性 | 类型 | 默认值 | 说明 |
|
||||||
|
|------|------|--------|------|
|
||||||
|
| `createdIsNeed` | `boolean` | **true** | 是否在 `onMounted` 时自动请求列表 |
|
||||||
|
| `isPage` | `boolean` | true | 是否分页 |
|
||||||
|
| `queryForm` | `any` | `{}` | 查询条件,会合并到请求参数 |
|
||||||
|
| `pageList` | `(...arg: any) => Promise<any>` | - | **必填**,分页接口方法 |
|
||||||
|
| `props` | `object` | `{ item: 'records', totalCount: 'total' }` | 列表/总数的数据路径 |
|
||||||
|
| `validate` | `Function` | - | 请求前校验,不通过则不请求 |
|
||||||
|
| `onLoaded` | `Function` | - | 请求成功、写入 `dataList` 后的回调 |
|
||||||
|
| `onCascaded` | `Function` | - | 级联回调 |
|
||||||
|
| `pagination` | `Pagination` | 见源码 | 分页配置 |
|
||||||
|
|
||||||
|
### 2. 内部逻辑
|
||||||
|
|
||||||
|
- **请求参数**:`query()` 调用 `state.pageList({ ...state.queryForm, current, size, descs, ascs })`。
|
||||||
|
- **响应处理**:用 `state.props.item`、`state.props.totalCount` 从 `res.data` 取列表和总数,写入 `state.dataList`、`state.pagination.total`。
|
||||||
|
- **首次加载**:在 **hooks 内部的 `onMounted`** 里,若 `state.createdIsNeed === true` 则执行一次 `query()`。
|
||||||
|
- **注意**:`useTable` **不 return state**,调用方需要自己持有一份 `state`(通常用 `reactive`)并传给 `useTable(state)`,表格数据、分页、loading 都写在这份 `state` 上。
|
||||||
|
|
||||||
|
### 3. 返回值
|
||||||
|
|
||||||
|
```ts
|
||||||
|
{
|
||||||
|
getDataList, // (refresh?: any) => void,默认重置到第 1 页再请求;getDataList(false) 不重置页码
|
||||||
|
currentChangeHandle, // 页码变化时调用
|
||||||
|
sizeChangeHandle, // 每页条数变化时调用
|
||||||
|
sortChangeHandle, // 排序变化时调用(若表格支持 sortable="custom")
|
||||||
|
tableStyle, // { cellStyle, headerCellStyle }
|
||||||
|
downBlobFile // 下载文件
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 二、推荐用法(与 search-form 配合)
|
||||||
|
|
||||||
|
### 1. 定义 state 并传入 useTable
|
||||||
|
|
||||||
|
```ts
|
||||||
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
|
|
||||||
|
const search = reactive({ deptCode: '', realName: '', teacherNo: '' })
|
||||||
|
|
||||||
|
const state = reactive<BasicTableProps>({
|
||||||
|
queryForm: search, // 与 search-form 的 :model 同一对象
|
||||||
|
pageList: fetchList, // 或自定义方法合并额外参数
|
||||||
|
// createdIsNeed 不写则默认为 true,首屏自动请求
|
||||||
|
})
|
||||||
|
|
||||||
|
const { getDataList, currentChangeHandle, sizeChangeHandle, tableStyle } = useTable(state)
|
||||||
|
```
|
||||||
|
|
||||||
|
- **state 由调用方定义并传入**,不要在解构时期望 `useTable` 返回 `state`(源码未返回)。
|
||||||
|
|
||||||
|
### 2. 模板绑定
|
||||||
|
|
||||||
|
- 表格:`:data="state.dataList"`、`v-loading="state.loading"`,`tableStyle` 用于 `cell-style` / `header-cell-style`。
|
||||||
|
- 分页:`v-bind="state.pagination"` 或分别绑定 `current`/`size`/`total`,事件用 `@current-change="currentChangeHandle"`、`@size-change="sizeChangeHandle"`。
|
||||||
|
|
||||||
|
### 3. 查询 / 重置 / 刷新
|
||||||
|
|
||||||
|
- 点击「查询」:先更新 `search`(或额外参数),再 `getDataList()`(会回到第 1 页)。
|
||||||
|
- 重置:清空 `search`(及 ref 里的额外参数),可选 `searchFormRef?.resetFields()`,再 `getDataList()`。
|
||||||
|
- 只刷新当前页:`getDataList(false)`。
|
||||||
|
|
||||||
|
### 4. 与 createdIsNeed 的关系
|
||||||
|
|
||||||
|
- **createdIsNeed: true(默认)**:hooks 内部 onMounted 会自动调一次 `query()`,**页面里不需要再在 onMounted 里调 getDataList()**,否则会重复请求。
|
||||||
|
- **createdIsNeed: false**:不在挂载时请求,需要自己在合适时机(例如 onMounted 或某个条件满足后)调用 `getDataList()`。
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 三、professionaltitlerelation/index.vue 检查结果
|
||||||
|
|
||||||
|
| 检查项 | 状态 | 说明 |
|
||||||
|
|--------|------|------|
|
||||||
|
| queryForm 使用 search | ✅ | 与 search-form 的 model 一致 |
|
||||||
|
| pageList 返回结构 | ✅ | 返回 `{ data: { records, total } }`,与默认 props 一致 |
|
||||||
|
| createdIsNeed | ✅ | 未配置即默认 true,首屏由 useTable 自动请求 |
|
||||||
|
| onMounted 不重复请求 | ✅ | 仅 `loadDictData()`,未再调 getDataList |
|
||||||
|
| 表格绑定 state.dataList / state.loading | ✅ | 正确 |
|
||||||
|
| 分页绑定 state.pagination + currentChangeHandle/sizeChangeHandle | ✅ | 正确 |
|
||||||
|
| 查询 handleFilter → getDataList() | ✅ | 正确 |
|
||||||
|
| 重置 resetQuery → 清空 search + getDataList() | ✅ | 正确 |
|
||||||
|
| 删除/审核后 getDataList() | ✅ | 正确 |
|
||||||
|
| tableStyle 用于 el-table | ✅ | 正确 |
|
||||||
|
|
||||||
|
**结论**:当前 `professionaltitlerelation/index.vue` 对 hooks/table 的使用符合上述规范,无需修改。
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 四、常见注意点
|
||||||
|
|
||||||
|
1. **不要从 useTable 解构 state**:源码未返回 state,应自己在页面里 `const state = reactive<BasicTableProps>({...})` 并传给 `useTable(state)`。
|
||||||
|
2. **文档中若写 `const { state } = useTable(state)`**:属于文档笔误,实际应使用调用方定义的 `state`。
|
||||||
|
3. **自定义 pageList 时**:返回结构需与 `props` 一致,默认即 `res.data.records`、`res.data.total`;若后端字段不同,可同时配置 `props: { item: 'xxx', totalCount: 'yyy' }`。
|
||||||
|
4. **需要额外请求参数时**:在 `pageList` 里对入参做合并,例如 `return await fetchList({ ...queryParams, ...params.value })`。
|
||||||
@@ -81,3 +81,12 @@ export const putObj = (obj: any) => {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
export const print = (id: string | number) => {
|
||||||
|
return request({
|
||||||
|
url: `/professional/professionalteacherstationchange/print`,
|
||||||
|
method: 'get',
|
||||||
|
params: {
|
||||||
|
id: id
|
||||||
|
}
|
||||||
|
});
|
||||||
|
};
|
||||||
|
|||||||
@@ -1,61 +0,0 @@
|
|||||||
import request from '/@/utils/request';
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 获取列表
|
|
||||||
* @param query
|
|
||||||
*/
|
|
||||||
export const fetchList = (query?: any) => {
|
|
||||||
return request({
|
|
||||||
url: '/recruit/recruitschoolcode/page',
|
|
||||||
method: 'get',
|
|
||||||
params: query,
|
|
||||||
});
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 新增
|
|
||||||
* @param obj
|
|
||||||
*/
|
|
||||||
export const addObj = (obj: any) => {
|
|
||||||
return request({
|
|
||||||
url: '/recruit/recruitschoolcode/add',
|
|
||||||
method: 'post',
|
|
||||||
data: obj,
|
|
||||||
});
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 获取详情
|
|
||||||
* @param id
|
|
||||||
*/
|
|
||||||
export const getObj = (id: string | number) => {
|
|
||||||
return request({
|
|
||||||
url: `/recruit/recruitschoolcode/getById`,
|
|
||||||
method: 'get',
|
|
||||||
params:{id:id}
|
|
||||||
});
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 删除
|
|
||||||
* @param id
|
|
||||||
*/
|
|
||||||
export const delObj = (id: string | number) => {
|
|
||||||
return request({
|
|
||||||
url: `/recruit/recruitschoolcode/deleteById`,
|
|
||||||
method: 'post',
|
|
||||||
data:{id:id}
|
|
||||||
});
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 更新
|
|
||||||
* @param obj
|
|
||||||
*/
|
|
||||||
export const putObj = (obj: any) => {
|
|
||||||
return request({
|
|
||||||
url: '/recruit/recruitschoolcode/edit',
|
|
||||||
method: 'post',
|
|
||||||
data: obj,
|
|
||||||
});
|
|
||||||
};
|
|
||||||
@@ -16,9 +16,9 @@ export const fetchList = (query?: any) => {
|
|||||||
* 列表(按组ID)
|
* 列表(按组ID)
|
||||||
* @param query
|
* @param query
|
||||||
*/
|
*/
|
||||||
export const list = (query?: any) => {
|
export const queryByGroupId = (query?: any) => {
|
||||||
return request({
|
return request({
|
||||||
url: '/recruit/recruitstudentschool/listByGroupId',
|
url: '/recruit/recruitstudentschool/queryByGroupId',
|
||||||
method: 'get',
|
method: 'get',
|
||||||
params: query,
|
params: query,
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -34,7 +34,8 @@ const props = withDefaults(defineProps<Props>(), {
|
|||||||
options: () => [
|
options: () => [
|
||||||
{ value: '1', label: '已通过', type: 'success', icon: 'fa-solid fa-circle-check' , effect:"dark" },
|
{ value: '1', label: '已通过', type: 'success', icon: 'fa-solid fa-circle-check' , effect:"dark" },
|
||||||
{ value: '-2', label: '已驳回', type: 'danger', icon: 'fa-solid fa-circle-xmark', effect:"dark" },
|
{ value: '-2', label: '已驳回', type: 'danger', icon: 'fa-solid fa-circle-xmark', effect:"dark" },
|
||||||
{ value: '0', label: '待审核', type: 'warning', icon: 'fa-regular fa-clock' ,effect:"light" }
|
{ value: '0', label: '待审核', type: 'warning', icon: 'fa-regular fa-clock' ,effect:"light" },
|
||||||
|
{ value: '10', label: '部门通过', type: 'warning', icon: 'fa-regular fa-clock' ,effect:"dark" }
|
||||||
],
|
],
|
||||||
showIcon: true,
|
showIcon: true,
|
||||||
emptyText: '-'
|
emptyText: '-'
|
||||||
|
|||||||
BIN
src/dept_change.docx
Normal file
BIN
src/dept_change.docx
Normal file
Binary file not shown.
@@ -58,6 +58,15 @@ export const dynamicRoutes: Array<RouteRecordRaw> = [
|
|||||||
isHide: true,
|
isHide: true,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
path: '/professional/professionalteacherstationchange/print',
|
||||||
|
name: 'professionalteacherstationchange.print',
|
||||||
|
component: () => import('/@/views/professional/professionalteacherstationchange/print.vue'),
|
||||||
|
meta: {
|
||||||
|
isHide: true, // 隐藏路由,不在菜单中显示
|
||||||
|
isAuth: true // 需要认证,在 layout 中显示
|
||||||
|
},
|
||||||
|
},
|
||||||
...dynamicRoutesFlow
|
...dynamicRoutesFlow
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|||||||
@@ -13,9 +13,8 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref } from 'vue'
|
import { ref, defineAsyncComponent } from 'vue';
|
||||||
// @ts-ignore - Vue 3 script setup component
|
const multiUpload = defineAsyncComponent(() => import('./multiUpload.vue'))
|
||||||
import multiUpload from './multiUpload.vue'
|
|
||||||
|
|
||||||
// Props
|
// Props
|
||||||
const props = defineProps<{
|
const props = defineProps<{
|
||||||
|
|||||||
@@ -47,8 +47,8 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts" name="showEvidence">
|
<script setup lang="ts" name="showEvidence">
|
||||||
import { ref, reactive, nextTick } from 'vue';
|
import { ref, reactive, nextTick, defineAsyncComponent } from 'vue';
|
||||||
import authImg from '/@/components/tools/auth-img.vue';
|
const authImg = defineAsyncComponent(() => import('/@/components/tools/auth-img.vue'))
|
||||||
|
|
||||||
interface ImageItem {
|
interface ImageItem {
|
||||||
url: string;
|
url: string;
|
||||||
|
|||||||
@@ -5,8 +5,8 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, nextTick } from 'vue'
|
import { ref, nextTick, defineAsyncComponent } from 'vue';
|
||||||
import authImg from '/@/components/tools/auth-img.vue'
|
const authImg = defineAsyncComponent(() => import('/@/components/tools/auth-img.vue'))
|
||||||
|
|
||||||
interface ImageItem {
|
interface ImageItem {
|
||||||
title: string
|
title: string
|
||||||
|
|||||||
@@ -129,7 +129,12 @@
|
|||||||
|
|
||||||
<el-table-column prop="inoutFlag" label="允许进出" width="100" align="center">
|
<el-table-column prop="inoutFlag" label="允许进出" width="100" align="center">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-tag v-if="scope.row.inoutFlag">{{ getDictLabel(scope.row.inoutFlag) }}</el-tag>
|
<el-tag
|
||||||
|
v-if="scope.row.inoutFlag"
|
||||||
|
:type="scope.row.inoutFlag === '1' ? 'success' : 'danger'"
|
||||||
|
>
|
||||||
|
{{ getDictLabel(scope.row.inoutFlag) }}
|
||||||
|
</el-tag>
|
||||||
<span v-else>-</span>
|
<span v-else>-</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
|||||||
@@ -81,7 +81,7 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
icon="FolderAdd"
|
icon="FolderAdd"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
v-if="permissions.professional_outercompanyemployee_add"
|
v-auth="'professional_outercompanyemployee_add'"
|
||||||
>
|
>
|
||||||
新 增
|
新 增
|
||||||
</el-button>
|
</el-button>
|
||||||
@@ -171,21 +171,21 @@
|
|||||||
<el-table-column label="操作" width="250" align="center" fixed="right">
|
<el-table-column label="操作" width="250" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_outercompanyemployee_edit"
|
v-auth="'professional_outercompanyemployee_edit'"
|
||||||
icon="edit-pen"
|
icon="edit-pen"
|
||||||
link
|
link
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="handleEdit(scope.row)">修改
|
@click="handleEdit(scope.row)">修改
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_outercompanyemployee_reset_pw"
|
v-auth="'professional_outercompanyemployee_reset_pw'"
|
||||||
icon="RefreshLeft"
|
icon="RefreshLeft"
|
||||||
link
|
link
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="resetPassword(scope.row)">重置密码
|
@click="resetPassword(scope.row)">重置密码
|
||||||
</el-button>
|
</el-button>
|
||||||
<!-- <el-button
|
<!-- <el-button
|
||||||
v-if="permissions.professional_outercompanyemployee_del"
|
v-auth="'professional_outercompanyemployee_del'"
|
||||||
icon="delete"
|
icon="delete"
|
||||||
link
|
link
|
||||||
type="primary"
|
type="primary"
|
||||||
@@ -250,14 +250,11 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, computed, onMounted } from 'vue'
|
import { ref, reactive, onMounted } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { useMessageBox } from '/@/hooks/message'
|
import { useMessageBox } from '/@/hooks/message'
|
||||||
import { useDict } from '/@/hooks/dict'
|
import { useDict } from '/@/hooks/dict'
|
||||||
import { Session } from '/@/utils/storage'
|
|
||||||
import { validateNull } from '/@/utils/validate'
|
import { validateNull } from '/@/utils/validate'
|
||||||
import axios from 'axios'
|
import axios from 'axios'
|
||||||
import request from '/@/utils/request'
|
import request from '/@/utils/request'
|
||||||
@@ -272,20 +269,8 @@ import {
|
|||||||
resetPassWord
|
resetPassWord
|
||||||
} from '/@/api/professional/stayschool/outercompanyemployee'
|
} from '/@/api/professional/stayschool/outercompanyemployee'
|
||||||
import { getList as getCompanyList } from '/@/api/professional/stayschool/outercompany'
|
import { getList as getCompanyList } from '/@/api/professional/stayschool/outercompany'
|
||||||
import FormTrain from './formTrain.vue'
|
import { defineAsyncComponent } from 'vue';
|
||||||
|
const FormTrain = defineAsyncComponent(() => import('./formTrain.vue'))
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
|
|||||||
@@ -82,7 +82,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, onMounted } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { defineAsyncComponent } from 'vue'
|
import { defineAsyncComponent } from 'vue'
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { fetchList } from '/@/api/professional/professionaluser/professionalpartychange'
|
import { fetchList } from '/@/api/professional/professionaluser/professionalpartychange'
|
||||||
@@ -130,10 +130,7 @@ const resetQuery = () => {
|
|||||||
getDataList()
|
getDataList()
|
||||||
}
|
}
|
||||||
|
|
||||||
// 初始化
|
// 表格数据由 useTable(createdIsNeed 默认 true)在挂载时自动请求
|
||||||
onMounted(() => {
|
|
||||||
getDataList()
|
|
||||||
})
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
|||||||
@@ -136,20 +136,36 @@
|
|||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-auth="'professional_professionalqualificationrelation_exam'"
|
v-auth="'professional_professionalqualificationrelation_exam'"
|
||||||
v-if="scope.row.state === '0'"
|
v-if="scope.row.canExam"
|
||||||
type="success"
|
type="success"
|
||||||
link
|
link
|
||||||
icon="CircleCheck"
|
icon="CircleCheck"
|
||||||
@click="changeState(scope.row, 1)">通过
|
@click="changeState(scope.row, 1)">通过
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
v-auth="'professional_professionalqualificationrelation_exam'"
|
||||||
|
v-if="scope.row.canDeptExam"
|
||||||
|
type="success"
|
||||||
|
link
|
||||||
|
icon="CircleCheck"
|
||||||
|
@click="changeState(scope.row, 1)">部门通过
|
||||||
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-auth="'professional_professionalqualificationrelation_exam'"
|
v-auth="'professional_professionalqualificationrelation_exam'"
|
||||||
v-if="scope.row.state === '0' || scope.row.state === '1'"
|
v-if="scope.row.canBack"
|
||||||
type="danger"
|
type="danger"
|
||||||
link
|
link
|
||||||
icon="CircleClose"
|
icon="CircleClose"
|
||||||
@click="changeState(scope.row, -2)">驳回
|
@click="changeState(scope.row, -2)">驳回
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
v-auth="'professional_professionalqualificationrelation_exam'"
|
||||||
|
v-if="scope.row.canDeptBack"
|
||||||
|
type="danger"
|
||||||
|
link
|
||||||
|
icon="CircleClose"
|
||||||
|
@click="changeState(scope.row, -2)">部门驳回
|
||||||
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-auth="'professional_professionalqualificationrelation_del'"
|
v-auth="'professional_professionalqualificationrelation_del'"
|
||||||
type="danger"
|
type="danger"
|
||||||
@@ -402,10 +418,9 @@ const loadDictData = async () => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 初始化
|
// 初始化:仅加载下拉字典,表格数据由 useTable(createdIsNeed 默认 true)自动请求
|
||||||
onMounted(async () => {
|
onMounted(async () => {
|
||||||
await loadDictData()
|
await loadDictData()
|
||||||
getDataList()
|
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@@ -162,20 +162,36 @@
|
|||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-auth="'professional_professionalteacheracademicrelation_exam'"
|
v-auth="'professional_professionalteacheracademicrelation_exam'"
|
||||||
v-if="scope.row.state === '0'"
|
v-if="scope.row.canExam"
|
||||||
type="success"
|
type="success"
|
||||||
link
|
link
|
||||||
icon="CircleCheck"
|
icon="CircleCheck"
|
||||||
@click="changeState(scope.row, 1)">通过
|
@click="changeState(scope.row, 1)">通过
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
v-auth="'professional_professionalteacheracademicrelation_exam'"
|
||||||
|
v-if="scope.row.canDeptExam"
|
||||||
|
type="success"
|
||||||
|
link
|
||||||
|
icon="CircleCheck"
|
||||||
|
@click="changeState(scope.row, 1)">部门通过
|
||||||
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-auth="'professional_professionalteacheracademicrelation_exam'"
|
v-auth="'professional_professionalteacheracademicrelation_exam'"
|
||||||
v-if="scope.row.state === '0' || scope.row.state === '1'"
|
v-if="scope.row.canBack"
|
||||||
type="danger"
|
type="danger"
|
||||||
link
|
link
|
||||||
icon="CircleClose"
|
icon="CircleClose"
|
||||||
@click="changeState(scope.row, -2)">驳回
|
@click="changeState(scope.row, -2)">驳回
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
v-auth="'professional_professionalteacheracademicrelation_exam'"
|
||||||
|
v-if="scope.row.canDeptBack"
|
||||||
|
type="danger"
|
||||||
|
link
|
||||||
|
icon="CircleClose"
|
||||||
|
@click="changeState(scope.row, -2)">部门驳回
|
||||||
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-auth="'professional_professionalteacheracademicrelation_del'"
|
v-auth="'professional_professionalteacheracademicrelation_del'"
|
||||||
type="danger"
|
type="danger"
|
||||||
@@ -456,10 +472,9 @@ const loadDictData = async () => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 初始化
|
// 初始化:仅加载下拉字典,表格数据由 useTable(createdIsNeed 默认 true)自动请求
|
||||||
onMounted(async () => {
|
onMounted(async () => {
|
||||||
await loadDictData()
|
await loadDictData()
|
||||||
getDataList()
|
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@@ -56,16 +56,16 @@
|
|||||||
<el-row>
|
<el-row>
|
||||||
<div class="mb15" style="width: 100%;">
|
<div class="mb15" style="width: 100%;">
|
||||||
<el-button
|
<el-button
|
||||||
|
v-auth="'professional_professionalteachercertificaterelation_add'"
|
||||||
type="primary"
|
type="primary"
|
||||||
icon="FolderAdd"
|
icon="FolderAdd"
|
||||||
@click="handleAdd"
|
@click="handleAdd">新 增
|
||||||
v-if="permissions.professional_professionalteachercertificaterelation_add">新 增
|
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
|
v-auth="'professional_teacherbase_export'"
|
||||||
type="warning"
|
type="warning"
|
||||||
plain
|
plain
|
||||||
icon="Download"
|
icon="Download"
|
||||||
v-if="permissions.professional_teacherbase_export"
|
|
||||||
@click="handleDownLoadWord"
|
@click="handleDownLoadWord"
|
||||||
:loading="exportLoading">导出信息
|
:loading="exportLoading">导出信息
|
||||||
</el-button>
|
</el-button>
|
||||||
@@ -123,31 +123,50 @@
|
|||||||
<el-table-column label="操作" width="280" align="center" fixed="right">
|
<el-table-column label="操作" width="280" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
|
v-auth="'professional_professionalteachercertificaterelation_edit'"
|
||||||
|
v-if="scope.row.state === '0' || scope.row.state === '-2'"
|
||||||
type="primary"
|
type="primary"
|
||||||
link
|
link
|
||||||
icon="edit-pen"
|
icon="edit-pen"
|
||||||
v-if="permissions.professional_professionalteachercertificaterelation_edit && (scope.row.state === '0' || scope.row.state === '-2')"
|
|
||||||
@click="handleEdit(scope.row)">编辑
|
@click="handleEdit(scope.row)">编辑
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
|
v-auth="'professional_professionalteachercertificaterelation_exam'"
|
||||||
|
v-if="scope.row.canExam"
|
||||||
type="success"
|
type="success"
|
||||||
link
|
link
|
||||||
icon="CircleCheck"
|
icon="CircleCheck"
|
||||||
v-if="permissions.professional_professionalteachercertificaterelation_exam && scope.row.state === '0'"
|
|
||||||
@click="changeState(scope.row, 1)">通过
|
@click="changeState(scope.row, 1)">通过
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
type="success"
|
||||||
|
link
|
||||||
|
v-auth="'professional_professionalteachercertificaterelation_exam'"
|
||||||
|
icon="CircleCheck"
|
||||||
|
v-if="scope.row.canDeptExam"
|
||||||
|
@click="changeState(scope.row, 1)">部门通过
|
||||||
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
|
v-auth="'professional_professionalteachercertificaterelation_exam'"
|
||||||
|
v-if="scope.row.canBack"
|
||||||
type="danger"
|
type="danger"
|
||||||
link
|
link
|
||||||
icon="CircleClose"
|
icon="CircleClose"
|
||||||
v-if="permissions.professional_professionalteachercertificaterelation_exam && (scope.row.state === '0' || scope.row.state === '1')"
|
|
||||||
@click="changeState(scope.row, -2)">驳回
|
@click="changeState(scope.row, -2)">驳回
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
type="danger"
|
||||||
|
link
|
||||||
|
icon="CircleClose"
|
||||||
|
v-auth="'professional_professionalteachercertificaterelation_exam'"
|
||||||
|
v-if="scope.row.canDeptBack"
|
||||||
|
@click="changeState(scope.row, -2)">部门驳回
|
||||||
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
|
v-auth="'professional_professionalteachercertificaterelation_del'"
|
||||||
type="danger"
|
type="danger"
|
||||||
link
|
link
|
||||||
icon="delete"
|
icon="delete"
|
||||||
v-if="permissions.professional_professionalteachercertificaterelation_del"
|
|
||||||
style="margin-left: 12px"
|
style="margin-left: 12px"
|
||||||
@click="handleDel(scope.row)">删除
|
@click="handleDel(scope.row)">删除
|
||||||
</el-button>
|
</el-button>
|
||||||
@@ -178,9 +197,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, computed, onMounted, nextTick } from 'vue'
|
import { ref, reactive, onMounted, nextTick } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { useMessageBox } from '/@/hooks/message'
|
import { useMessageBox } from '/@/hooks/message'
|
||||||
@@ -207,19 +224,6 @@ const auditStateOptions: StateOption[] = [
|
|||||||
{ value: '0', label: '待审核', type: 'warning', icon: 'fa-regular fa-clock', effect: 'light' }
|
{ value: '0', label: '待审核', type: 'warning', icon: 'fa-regular fa-clock', effect: 'light' }
|
||||||
]
|
]
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
const messageBox = useMessageBox()
|
const messageBox = useMessageBox()
|
||||||
@@ -397,10 +401,9 @@ const loadDictData = async () => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 初始化
|
// 初始化:仅加载下拉字典,表格数据由 useTable(createdIsNeed 默认 true)自动请求
|
||||||
onMounted(async () => {
|
onMounted(async () => {
|
||||||
await loadDictData()
|
await loadDictData()
|
||||||
getDataList()
|
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@@ -56,10 +56,10 @@
|
|||||||
<el-row>
|
<el-row>
|
||||||
<div class="mb15" style="width: 100%;">
|
<div class="mb15" style="width: 100%;">
|
||||||
<el-button
|
<el-button
|
||||||
|
v-auth="'professional_professionalteacherhonor_add'"
|
||||||
type="primary"
|
type="primary"
|
||||||
icon="FolderAdd"
|
icon="FolderAdd"
|
||||||
@click="handleAdd"
|
@click="handleAdd">新 增
|
||||||
v-if="permissions.professional_professionalteacherhonor_add">新 增
|
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
type="warning"
|
type="warning"
|
||||||
@@ -118,31 +118,50 @@
|
|||||||
<el-table-column label="操作" width="280" align="center" fixed="right">
|
<el-table-column label="操作" width="280" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
|
v-auth="'professional_professionalteacherhonor_edit'"
|
||||||
|
v-if="scope.row.state === '0' || scope.row.state === '-2'"
|
||||||
type="primary"
|
type="primary"
|
||||||
link
|
link
|
||||||
icon="edit-pen"
|
icon="edit-pen"
|
||||||
v-if="permissions.professional_professionalteacherhonor_edit && (scope.row.state === '0' || scope.row.state === '-2')"
|
@click="handleEdit(scope.row)">修改
|
||||||
@click="handleEdit(scope.row)">编辑
|
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
|
v-auth="'professional_professionalteacherhonor_exam'"
|
||||||
|
v-if="scope.row.canExam"
|
||||||
type="success"
|
type="success"
|
||||||
link
|
link
|
||||||
icon="CircleCheck"
|
icon="CircleCheck"
|
||||||
v-if="permissions.professional_professionalteacherhonor_exam && scope.row.state === '0'"
|
|
||||||
@click="changeState(scope.row, 1)">通过
|
@click="changeState(scope.row, 1)">通过
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
type="success"
|
||||||
|
link
|
||||||
|
v-auth="'professional_professionalteacherhonor_exam'"
|
||||||
|
icon="CircleCheck"
|
||||||
|
v-if="scope.row.canDeptExam"
|
||||||
|
@click="changeState(scope.row, 1)">部门通过
|
||||||
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
|
v-auth="'professional_professionalteacherhonor_exam'"
|
||||||
|
v-if="scope.row.canBack"
|
||||||
type="danger"
|
type="danger"
|
||||||
link
|
link
|
||||||
icon="CircleClose"
|
icon="CircleClose"
|
||||||
v-if="permissions.professional_professionalteacherhonor_exam && (scope.row.state === '0' || scope.row.state === '1')"
|
|
||||||
@click="changeState(scope.row, -2)">驳回
|
@click="changeState(scope.row, -2)">驳回
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
type="danger"
|
||||||
|
link
|
||||||
|
v-auth="'professional_professionalteacherhonor_exam'"
|
||||||
|
icon="CircleClose"
|
||||||
|
v-if="scope.row.canDeptBack"
|
||||||
|
@click="changeState(scope.row, -2)">部门驳回
|
||||||
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
|
v-auth="'professional_professionalteacherhonor_del'"
|
||||||
type="danger"
|
type="danger"
|
||||||
link
|
link
|
||||||
icon="delete"
|
icon="delete"
|
||||||
v-if="permissions.professional_professionalteacherhonor_del"
|
|
||||||
style="margin-left: 12px"
|
style="margin-left: 12px"
|
||||||
@click="handleDel(scope.row)">删除
|
@click="handleDel(scope.row)">删除
|
||||||
</el-button>
|
</el-button>
|
||||||
@@ -173,9 +192,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, computed, onMounted, nextTick } from 'vue'
|
import { ref, reactive, nextTick } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { useMessageBox } from '/@/hooks/message'
|
import { useMessageBox } from '/@/hooks/message'
|
||||||
@@ -185,6 +202,7 @@ import {
|
|||||||
examObj,
|
examObj,
|
||||||
delObj
|
delObj
|
||||||
} from '/@/api/professional/professionaluser/professionalteacherhonor'
|
} from '/@/api/professional/professionaluser/professionalteacherhonor'
|
||||||
|
import { PROFESSIONAL_AUDIT_STATE_OPTIONS } from '/@/config/global'
|
||||||
import { defineAsyncComponent } from 'vue'
|
import { defineAsyncComponent } from 'vue'
|
||||||
const TeacherNameNo = defineAsyncComponent(() => import('/@/components/TeacherNameNo/index.vue'))
|
const TeacherNameNo = defineAsyncComponent(() => import('/@/components/TeacherNameNo/index.vue'))
|
||||||
const AuditState = defineAsyncComponent(() => import('/@/components/AuditState/index.vue'))
|
const AuditState = defineAsyncComponent(() => import('/@/components/AuditState/index.vue'))
|
||||||
@@ -192,19 +210,6 @@ const ProfessionalBackResaon = defineAsyncComponent(() => import('/@/views/profe
|
|||||||
const DataForm = defineAsyncComponent(() => import('./form.vue'))
|
const DataForm = defineAsyncComponent(() => import('./form.vue'))
|
||||||
const previewFile = defineAsyncComponent(() => import('/@/components/tools/preview-file.vue'))
|
const previewFile = defineAsyncComponent(() => import('/@/components/tools/preview-file.vue'))
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
const messageBox = useMessageBox()
|
const messageBox = useMessageBox()
|
||||||
@@ -212,13 +217,8 @@ const messageBox = useMessageBox()
|
|||||||
// 字典数据
|
// 字典数据
|
||||||
const { professional_state: professionalState } = useDict('professional_state')
|
const { professional_state: professionalState } = useDict('professional_state')
|
||||||
|
|
||||||
// 审核状态选项(独立定义,防止其他页面修改时被波及)
|
// 审核状态选项
|
||||||
import type { StateOption } from '/@/components/AuditState/index.vue'
|
const auditStateOptions = PROFESSIONAL_AUDIT_STATE_OPTIONS
|
||||||
const auditStateOptions: StateOption[] = [
|
|
||||||
{ value: '1', label: '已通过', type: 'success', icon: 'fa-solid fa-circle-check', effect: 'dark' },
|
|
||||||
{ value: '-2', label: '已驳回', type: 'danger', icon: 'fa-solid fa-circle-xmark', effect: 'dark' },
|
|
||||||
{ value: '0', label: '待审核', type: 'warning', icon: 'fa-regular fa-clock', effect: 'light' }
|
|
||||||
]
|
|
||||||
|
|
||||||
// 表格引用
|
// 表格引用
|
||||||
const tableRef = ref()
|
const tableRef = ref()
|
||||||
@@ -365,10 +365,7 @@ const handleDownLoadWord = async () => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 初始化
|
// 表格数据由 useTable(createdIsNeed 默认 true)在挂载时自动请求
|
||||||
onMounted(() => {
|
|
||||||
getDataList()
|
|
||||||
})
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
|||||||
@@ -83,11 +83,15 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, onMounted } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { defineAsyncComponent } from 'vue'
|
import { defineAsyncComponent } from 'vue'
|
||||||
|
import { useRouter, useRoute } from 'vue-router'
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { fetchList } from '/@/api/professional/professionaluser/professionalteacherstationchange'
|
import { fetchList } from '/@/api/professional/professionaluser/professionalteacherstationchange'
|
||||||
|
|
||||||
|
const router = useRouter()
|
||||||
|
const route = useRoute()
|
||||||
|
|
||||||
const TeacherNameNo = defineAsyncComponent(() => import('/@/components/TeacherNameNo/index.vue'))
|
const TeacherNameNo = defineAsyncComponent(() => import('/@/components/TeacherNameNo/index.vue'))
|
||||||
|
|
||||||
// 表格引用
|
// 表格引用
|
||||||
@@ -133,13 +137,15 @@ const resetQuery = () => {
|
|||||||
|
|
||||||
// 打印部门调令
|
// 打印部门调令
|
||||||
const doPrint = (row: any) => {
|
const doPrint = (row: any) => {
|
||||||
window.open(`/professional/professionalteacherstationchange/print/${row.id}`)
|
// 直接使用固定路径跳转到 print 页面
|
||||||
|
const routeData = router.resolve({
|
||||||
|
path: '/professional/professionalteacherstationchange/print',
|
||||||
|
query: { id: row.id } // 使用 query 参数传递 id
|
||||||
|
})
|
||||||
|
window.open(routeData.href, '_blank')
|
||||||
}
|
}
|
||||||
|
|
||||||
// 初始化
|
// 表格数据由 useTable(createdIsNeed 默认 true)在挂载时自动请求
|
||||||
onMounted(() => {
|
|
||||||
getDataList()
|
|
||||||
})
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
|||||||
@@ -0,0 +1,515 @@
|
|||||||
|
<template>
|
||||||
|
<div class="print-container" id="print-container" ref="printContainerRef">
|
||||||
|
<div class="print-content" v-loading="loading" ref="printContentRef">
|
||||||
|
<!-- 上半部分:存根 -->
|
||||||
|
<div class="stub-section">
|
||||||
|
<!-- 大标题 -->
|
||||||
|
<div class="main-title">江苏省常州技师学院调令</div>
|
||||||
|
|
||||||
|
<!-- 副标题和编号 -->
|
||||||
|
<div class="subtitle-row">
|
||||||
|
<div class="subtitle">
|
||||||
|
<div class="subtitle-text">校内调配通知单</div>
|
||||||
|
<div class="stub-label">(存根)</div>
|
||||||
|
</div>
|
||||||
|
<div class="doc-number">编号:</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 存根内容 -->
|
||||||
|
<div class="stub-content">
|
||||||
|
<div class="content-line">
|
||||||
|
<span class="underline-field">{{ detailData.fromDeptName || '________' }}</span>
|
||||||
|
<span class="text">(院、部、中心、处室):</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="content-line indent">
|
||||||
|
<span class="text">经学校研究决定,调配</span>
|
||||||
|
<span class="underline-field">{{ detailData.realName || '________' }}</span>
|
||||||
|
<span class="text">同志到</span>
|
||||||
|
<span class="underline-field">{{ detailData.toDeptName1 || '________' }}</span>
|
||||||
|
<span class="text">(院、部、中心、处室)</span>
|
||||||
|
<span class="underline-field">{{ detailData.pos || '________' }}</span>
|
||||||
|
<span class="text">(专技、管理、工勤)岗位工作,请做好移交或安排。</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="content-line">
|
||||||
|
<span class="text">限</span>
|
||||||
|
<span class="underline-field">{{ detailData.year1 || '____' }}</span>
|
||||||
|
<span class="text">年</span>
|
||||||
|
<span class="underline-field">{{ detailData.month1 || '____' }}</span>
|
||||||
|
<span class="text">月</span>
|
||||||
|
<span class="underline-field">{{ detailData.day1 || '____' }}</span>
|
||||||
|
<span class="text">日前离岗。</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 存根底部 -->
|
||||||
|
<div class="stub-footer">
|
||||||
|
<div class="footer-right">
|
||||||
|
<div class="dept-name">组织人事处</div>
|
||||||
|
<div class="date-line">
|
||||||
|
<span class="underline-field">{{ detailData.year || '____' }}</span>
|
||||||
|
<span class="text">年</span>
|
||||||
|
<span class="underline-field">{{ detailData.month || '____' }}</span>
|
||||||
|
<span class="text">月</span>
|
||||||
|
<span class="underline-field">{{ detailData.day || '____' }}</span>
|
||||||
|
<span class="text">日</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 分隔线 -->
|
||||||
|
<div class="divider-line"></div>
|
||||||
|
|
||||||
|
<!-- 下半部分:正式通知单 -->
|
||||||
|
<div class="notice-section">
|
||||||
|
<!-- 顶部横线 -->
|
||||||
|
<div class="top-line"></div>
|
||||||
|
|
||||||
|
<!-- 标题和编号 -->
|
||||||
|
<div class="notice-title-row">
|
||||||
|
<div class="notice-title">校内调配通知单</div>
|
||||||
|
<div class="doc-number">编号:</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 通知单内容 -->
|
||||||
|
<div class="notice-content">
|
||||||
|
<div class="content-line">
|
||||||
|
<span class="underline-field">{{ detailData.fromDeptName || '________' }}</span>
|
||||||
|
<span class="text">(院、部、中心、处室):</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="content-line indent">
|
||||||
|
<span class="text">经学校研究决定,调配</span>
|
||||||
|
<span class="underline-field">{{ detailData.realName || '________' }}</span>
|
||||||
|
<span class="text">同志到</span>
|
||||||
|
<span class="underline-field">{{ detailData.toDeptName1 || '________' }}</span>
|
||||||
|
<span class="text">(院、部、中心、处室)</span>
|
||||||
|
<span class="underline-field">{{ detailData.pos || '________' }}</span>
|
||||||
|
<span class="text">(专技、管理、工勤)岗位工作,请做好工作安排。</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="content-line">
|
||||||
|
<span class="text">限</span>
|
||||||
|
<span class="underline-field">{{ detailData.year1 || '____' }}</span>
|
||||||
|
<span class="text">年</span>
|
||||||
|
<span class="underline-field">{{ detailData.month1 || '____' }}</span>
|
||||||
|
<span class="text">月</span>
|
||||||
|
<span class="underline-field">{{ detailData.day1 || '____' }}</span>
|
||||||
|
<span class="text">日前报到,并将该单交财务处。</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 通知单底部 -->
|
||||||
|
<div class="notice-footer">
|
||||||
|
<div class="footer-center">
|
||||||
|
<div class="dept-name-bold">组织人事处</div>
|
||||||
|
<div class="date-line">
|
||||||
|
<span class="underline-field">{{ detailData.year || '____' }}</span>
|
||||||
|
<span class="text">年</span>
|
||||||
|
<span class="underline-field">{{ detailData.month || '____' }}</span>
|
||||||
|
<span class="text">月</span>
|
||||||
|
<span class="underline-field">{{ detailData.day || '____' }}</span>
|
||||||
|
<span class="text">日</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 签字栏 -->
|
||||||
|
<div class="signature-section">
|
||||||
|
<div class="signature-left">
|
||||||
|
<div class="signature-label">调配(出)部门领导签字/日期:</div>
|
||||||
|
</div>
|
||||||
|
<div class="signature-right">
|
||||||
|
<div class="signature-label">接收部门领导签字/日期:</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 打印按钮 -->
|
||||||
|
<div class="print-actions" v-if="!loading">
|
||||||
|
<el-button type="primary" icon="Printer" @click="handlePrint">打印</el-button>
|
||||||
|
<el-button @click="handleClose">关闭</el-button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup lang="ts">
|
||||||
|
import { ref, onMounted, computed } from 'vue'
|
||||||
|
import { useRoute, useRouter } from 'vue-router'
|
||||||
|
import { print } from '/@/api/professional/professionaluser/professionalteacherstationchange'
|
||||||
|
import { useMessage } from '/@/hooks/message'
|
||||||
|
|
||||||
|
const route = useRoute()
|
||||||
|
const router = useRouter()
|
||||||
|
const message = useMessage()
|
||||||
|
|
||||||
|
const loading = ref(false)
|
||||||
|
const detailData = ref<any>({})
|
||||||
|
const printContainerRef = ref<HTMLElement>()
|
||||||
|
const printContentRef = ref<HTMLElement>()
|
||||||
|
|
||||||
|
// 解析日期
|
||||||
|
const parseDate = (dateStr: string) => {
|
||||||
|
if (!dateStr) return { year: '', month: '', day: '' }
|
||||||
|
const date = new Date(dateStr)
|
||||||
|
return {
|
||||||
|
year: date.getFullYear().toString(),
|
||||||
|
month: (date.getMonth() + 1).toString().padStart(2, '0'),
|
||||||
|
day: date.getDate().toString().padStart(2, '0')
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 签发日期
|
||||||
|
const issueDate = computed(() => {
|
||||||
|
return parseDate(detailData.value.changeDate || '')
|
||||||
|
})
|
||||||
|
|
||||||
|
const issueYear = computed(() => issueDate.value.year)
|
||||||
|
const issueMonth = computed(() => issueDate.value.month)
|
||||||
|
const issueDay = computed(() => issueDate.value.day)
|
||||||
|
|
||||||
|
// 报到日期(假设是调令日期,可根据实际需求调整)
|
||||||
|
const reportDate = computed(() => {
|
||||||
|
return parseDate(detailData.value.changeDate || '')
|
||||||
|
})
|
||||||
|
|
||||||
|
const reportYear = computed(() => reportDate.value.year)
|
||||||
|
const reportMonth = computed(() => reportDate.value.month)
|
||||||
|
const reportDay = computed(() => reportDate.value.day)
|
||||||
|
|
||||||
|
// 获取详情数据
|
||||||
|
const fetchDetail = async () => {
|
||||||
|
// 优先从 params 获取,如果没有则从 query 获取
|
||||||
|
const id = (route.params.id || route.query.id) as string
|
||||||
|
if (!id) {
|
||||||
|
message.error('缺少调令ID')
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
loading.value = true
|
||||||
|
try {
|
||||||
|
const response = await print(id)
|
||||||
|
if (response && response.data) {
|
||||||
|
detailData.value = response.data
|
||||||
|
} else {
|
||||||
|
message.error('获取调令信息失败')
|
||||||
|
}
|
||||||
|
} catch (error) {
|
||||||
|
console.error('获取调令详情失败:', error)
|
||||||
|
message.error('获取调令信息失败')
|
||||||
|
} finally {
|
||||||
|
loading.value = false
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 打印
|
||||||
|
const handlePrint = () => {
|
||||||
|
// 使用 ref 直接操作元素
|
||||||
|
if (printContainerRef.value) {
|
||||||
|
printContainerRef.value.style.display = 'flex'
|
||||||
|
printContainerRef.value.style.visibility = 'visible'
|
||||||
|
printContainerRef.value.style.opacity = '1'
|
||||||
|
}
|
||||||
|
if (printContentRef.value) {
|
||||||
|
printContentRef.value.style.display = 'block'
|
||||||
|
printContentRef.value.style.visibility = 'visible'
|
||||||
|
printContentRef.value.style.opacity = '1'
|
||||||
|
}
|
||||||
|
|
||||||
|
// 隐藏左侧菜单等元素
|
||||||
|
const asideElements = document.querySelectorAll('.layout-aside, .layout-header, .layout-navbars, .layout-tags-view, .layout-breadcrumb')
|
||||||
|
asideElements.forEach((el: any) => {
|
||||||
|
if (el) {
|
||||||
|
el.style.display = 'none'
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
// 调整主内容区
|
||||||
|
const mainElements = document.querySelectorAll('.layout-main')
|
||||||
|
mainElements.forEach((el: any) => {
|
||||||
|
if (el) {
|
||||||
|
el.style.marginLeft = '0'
|
||||||
|
el.style.width = '100%'
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
// 延迟打印,确保样式已应用
|
||||||
|
setTimeout(() => {
|
||||||
|
window.print()
|
||||||
|
}, 200)
|
||||||
|
}
|
||||||
|
|
||||||
|
// 关闭
|
||||||
|
const handleClose = () => {
|
||||||
|
router.back()
|
||||||
|
}
|
||||||
|
|
||||||
|
// 初始化
|
||||||
|
onMounted(() => {
|
||||||
|
fetchDetail()
|
||||||
|
})
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<!-- 全局打印样式,用于隐藏 layout 元素 -->
|
||||||
|
<style lang="scss">
|
||||||
|
/* 打印时隐藏左侧菜单和其他 layout 元素 */
|
||||||
|
@media print {
|
||||||
|
/* 只隐藏左侧菜单和头部,不影响其他内容 */
|
||||||
|
.layout-aside,
|
||||||
|
.layout-columns-aside,
|
||||||
|
.layout-header,
|
||||||
|
.layout-navbars,
|
||||||
|
.layout-tags-view,
|
||||||
|
.layout-breadcrumb,
|
||||||
|
.el-backtop {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 确保主内容区全宽 */
|
||||||
|
.layout-main {
|
||||||
|
margin-left: 0 !important;
|
||||||
|
width: 100% !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 隐藏打印按钮 */
|
||||||
|
.print-actions {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
||||||
|
<style lang="scss">
|
||||||
|
.print-container {
|
||||||
|
min-height: 100vh;
|
||||||
|
background: #f5f5f5;
|
||||||
|
padding: 20px;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.print-content {
|
||||||
|
background: #fff;
|
||||||
|
width: 100%;
|
||||||
|
max-width: 800px;
|
||||||
|
padding: 40px 60px;
|
||||||
|
box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
|
||||||
|
margin-bottom: 20px;
|
||||||
|
font-size: 16px;
|
||||||
|
line-height: 1.8;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 上半部分:存根 */
|
||||||
|
.stub-section {
|
||||||
|
margin-bottom: 30px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.main-title {
|
||||||
|
font-size: 24px;
|
||||||
|
font-weight: bold;
|
||||||
|
text-align: center;
|
||||||
|
margin-bottom: 20px;
|
||||||
|
letter-spacing: 2px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.subtitle-row {
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
align-items: flex-start;
|
||||||
|
margin-bottom: 30px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.subtitle {
|
||||||
|
flex: 1;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.subtitle-text {
|
||||||
|
font-size: 18px;
|
||||||
|
font-weight: 500;
|
||||||
|
margin-bottom: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.stub-label {
|
||||||
|
font-size: 14px;
|
||||||
|
color: #666;
|
||||||
|
}
|
||||||
|
|
||||||
|
.doc-number {
|
||||||
|
font-size: 16px;
|
||||||
|
white-space: nowrap;
|
||||||
|
}
|
||||||
|
|
||||||
|
.stub-content {
|
||||||
|
margin-bottom: 30px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.content-line {
|
||||||
|
margin-bottom: 15px;
|
||||||
|
line-height: 2;
|
||||||
|
|
||||||
|
&.indent {
|
||||||
|
padding-left: 2em;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.underline-field {
|
||||||
|
display: inline-block;
|
||||||
|
min-width: 80px;
|
||||||
|
border-bottom: 1px solid #333;
|
||||||
|
text-align: center;
|
||||||
|
padding: 0 5px;
|
||||||
|
margin: 0 3px;
|
||||||
|
font-weight: 500;
|
||||||
|
}
|
||||||
|
|
||||||
|
.text {
|
||||||
|
color: #333;
|
||||||
|
}
|
||||||
|
|
||||||
|
.stub-footer {
|
||||||
|
margin-top: 40px;
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer-right {
|
||||||
|
display: inline-block;
|
||||||
|
}
|
||||||
|
|
||||||
|
.footer-center {
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dept-name {
|
||||||
|
font-size: 16px;
|
||||||
|
margin-bottom: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.dept-name-bold {
|
||||||
|
font-size: 18px;
|
||||||
|
font-weight: bold;
|
||||||
|
margin-bottom: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.date-line {
|
||||||
|
font-size: 16px;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 分隔线 */
|
||||||
|
.divider-line {
|
||||||
|
width: 100%;
|
||||||
|
height: 1px;
|
||||||
|
background: #ddd;
|
||||||
|
margin: 30px 0;
|
||||||
|
border-top: 1px dashed #999;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 下半部分:正式通知单 */
|
||||||
|
.notice-section {
|
||||||
|
margin-top: 30px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.top-line {
|
||||||
|
width: 100%;
|
||||||
|
height: 1px;
|
||||||
|
background: #333;
|
||||||
|
margin-bottom: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.notice-title-row {
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
align-items: center;
|
||||||
|
margin-bottom: 30px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.notice-title {
|
||||||
|
flex: 1;
|
||||||
|
text-align: center;
|
||||||
|
font-size: 18px;
|
||||||
|
font-weight: 500;
|
||||||
|
}
|
||||||
|
|
||||||
|
.notice-content {
|
||||||
|
margin-bottom: 40px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.notice-footer {
|
||||||
|
margin-top: 50px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.signature-section {
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
margin-top: 60px;
|
||||||
|
padding-top: 20px;
|
||||||
|
border-top: 1px solid #ddd;
|
||||||
|
}
|
||||||
|
|
||||||
|
.signature-left,
|
||||||
|
.signature-right {
|
||||||
|
flex: 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.signature-label {
|
||||||
|
font-size: 14px;
|
||||||
|
color: #666;
|
||||||
|
margin-bottom: 40px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.print-actions {
|
||||||
|
display: flex;
|
||||||
|
gap: 10px;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 打印样式 */
|
||||||
|
@media print {
|
||||||
|
/* 打印容器样式 - 确保正常显示 */
|
||||||
|
.print-container {
|
||||||
|
display: flex !important;
|
||||||
|
flex-direction: column !important;
|
||||||
|
align-items: center !important;
|
||||||
|
background: #fff !important;
|
||||||
|
padding: 20px !important;
|
||||||
|
margin: 0 !important;
|
||||||
|
width: 100% !important;
|
||||||
|
min-height: auto !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.print-content {
|
||||||
|
display: block !important;
|
||||||
|
background: #fff !important;
|
||||||
|
box-shadow: none !important;
|
||||||
|
padding: 40px 60px !important;
|
||||||
|
margin: 0 0 20px 0 !important;
|
||||||
|
max-width: 800px !important;
|
||||||
|
width: 100% !important;
|
||||||
|
font-size: 16px !important;
|
||||||
|
line-height: 1.8 !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.divider-line {
|
||||||
|
margin: 20px 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 隐藏打印按钮 */
|
||||||
|
.print-actions {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
@page {
|
||||||
|
size: A4;
|
||||||
|
margin: 1.5cm;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* 确保上下两部分在同一页 */
|
||||||
|
.stub-section,
|
||||||
|
.notice-section {
|
||||||
|
page-break-inside: avoid;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -8,7 +8,7 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
icon="FolderAdd"
|
icon="FolderAdd"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
v-if="permissions.professional_professionalteachertype_add">新 增
|
v-auth="'professional_professionalteachertype_add'">新 增
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-row>
|
</el-row>
|
||||||
@@ -35,14 +35,14 @@
|
|||||||
<el-table-column label="操作" width="150" align="center" fixed="right">
|
<el-table-column label="操作" width="150" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_professionalteachertype_edit"
|
v-auth="'professional_professionalteachertype_edit'"
|
||||||
icon="edit-pen"
|
icon="edit-pen"
|
||||||
link
|
link
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="handleEdit(scope.row)">修改
|
@click="handleEdit(scope.row)">修改
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_professionalteachertype_del"
|
v-auth="'professional_professionalteachertype_del'"
|
||||||
icon="delete"
|
icon="delete"
|
||||||
link
|
link
|
||||||
type="danger"
|
type="danger"
|
||||||
@@ -63,7 +63,7 @@
|
|||||||
<!-- 新增/编辑弹窗 -->
|
<!-- 新增/编辑弹窗 -->
|
||||||
<el-dialog
|
<el-dialog
|
||||||
v-model="dialogVisible"
|
v-model="dialogVisible"
|
||||||
:title="form.id ? '编辑' : '新增'"
|
:title="form.id ? '修改' : '新增'"
|
||||||
width="600px"
|
width="600px"
|
||||||
:close-on-click-modal="false"
|
:close-on-click-modal="false"
|
||||||
destroy-on-close
|
destroy-on-close
|
||||||
@@ -114,27 +114,12 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, computed } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { useMessageBox } from '/@/hooks/message'
|
import { useMessageBox } from '/@/hooks/message'
|
||||||
import { fetchList, addObj, putObj, delObj } from '/@/api/professional/rsbase/professionalteachertype'
|
import { fetchList, addObj, putObj, delObj } from '/@/api/professional/rsbase/professionalteachertype'
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
const messageBox = useMessageBox()
|
const messageBox = useMessageBox()
|
||||||
@@ -235,7 +220,7 @@ const handleSubmit = async () => {
|
|||||||
getDataList()
|
getDataList()
|
||||||
} catch (error: any) {
|
} catch (error: any) {
|
||||||
// 处理业务错误
|
// 处理业务错误
|
||||||
message.error(error.msg)
|
|
||||||
} finally {
|
} finally {
|
||||||
submitLoading.value = false
|
submitLoading.value = false
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
icon="FolderAdd"
|
icon="FolderAdd"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
v-if="permissions.professional_professionalteachingmaterialconfig_add">新 增
|
v-auth="'professional_professionalteachingmaterialconfig_add'">新 增
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-row>
|
</el-row>
|
||||||
@@ -35,14 +35,14 @@
|
|||||||
<el-table-column label="操作" width="150" align="center" fixed="right">
|
<el-table-column label="操作" width="150" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_professionalteachingmaterialconfig_edit"
|
v-auth="'professional_professionalteachingmaterialconfig_edit'"
|
||||||
icon="edit-pen"
|
icon="edit-pen"
|
||||||
link
|
link
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="handleEdit(scope.row)">修改
|
@click="handleEdit(scope.row)">修改
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_professionalteachingmaterialconfig_del"
|
v-auth="'professional_professionalteachingmaterialconfig_del'"
|
||||||
icon="delete"
|
icon="delete"
|
||||||
link
|
link
|
||||||
type="danger"
|
type="danger"
|
||||||
@@ -114,27 +114,12 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, computed } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { useMessageBox } from '/@/hooks/message'
|
import { useMessageBox } from '/@/hooks/message'
|
||||||
import { fetchList, addObj, putObj, delObj } from '/@/api/professional/rsbase/professionalteachingmaterialconfig'
|
import { fetchList, addObj, putObj, delObj } from '/@/api/professional/rsbase/professionalteachingmaterialconfig'
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
const messageBox = useMessageBox()
|
const messageBox = useMessageBox()
|
||||||
@@ -235,7 +220,7 @@ const handleSubmit = async () => {
|
|||||||
getDataList()
|
getDataList()
|
||||||
} catch (error: any) {
|
} catch (error: any) {
|
||||||
// 处理业务错误
|
// 处理业务错误
|
||||||
message.error(error.msg)
|
|
||||||
} finally {
|
} finally {
|
||||||
submitLoading.value = false
|
submitLoading.value = false
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
icon="FolderAdd"
|
icon="FolderAdd"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
v-if="permissions.professional_professionaltitlelevelconfig_add">新 增
|
v-auth="'professional_professionaltitlelevelconfig_add'">新 增
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-row>
|
</el-row>
|
||||||
@@ -35,14 +35,14 @@
|
|||||||
<el-table-column label="操作" width="150" align="center" fixed="right">
|
<el-table-column label="操作" width="150" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_professionaltitlelevelconfig_edit"
|
v-auth="'professional_professionaltitlelevelconfig_edit'"
|
||||||
icon="edit-pen"
|
icon="edit-pen"
|
||||||
link
|
link
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="handleEdit(scope.row)">修改
|
@click="handleEdit(scope.row)">修改
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_professionaltitlelevelconfig_del"
|
v-auth="'professional_professionaltitlelevelconfig_del'"
|
||||||
icon="delete"
|
icon="delete"
|
||||||
link
|
link
|
||||||
type="danger"
|
type="danger"
|
||||||
@@ -114,27 +114,12 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, computed } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { useMessageBox } from '/@/hooks/message'
|
import { useMessageBox } from '/@/hooks/message'
|
||||||
import { fetchList, addObj, putObj, delObj } from '/@/api/professional/rsbase/professionaltitlelevelconfig'
|
import { fetchList, addObj, putObj, delObj } from '/@/api/professional/rsbase/professionaltitlelevelconfig'
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
const messageBox = useMessageBox()
|
const messageBox = useMessageBox()
|
||||||
@@ -235,7 +220,6 @@ const handleSubmit = async () => {
|
|||||||
getDataList()
|
getDataList()
|
||||||
} catch (error: any) {
|
} catch (error: any) {
|
||||||
// 处理业务错误
|
// 处理业务错误
|
||||||
message.error(error.msg)
|
|
||||||
} finally {
|
} finally {
|
||||||
submitLoading.value = false
|
submitLoading.value = false
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<el-dialog v-model="dialogVisible" title="编辑职称" width="600px" append-to-body :close-on-click-modal="false" destroy-on-close>
|
<el-dialog v-model="dialogVisible" title="修改职称" width="600px" append-to-body :close-on-click-modal="false" destroy-on-close>
|
||||||
<div v-if="showForm">
|
<div v-if="showForm">
|
||||||
<el-form
|
<el-form
|
||||||
ref="formRef"
|
ref="formRef"
|
||||||
|
|||||||
@@ -88,17 +88,17 @@
|
|||||||
<el-row>
|
<el-row>
|
||||||
<div class="mb15" style="width: 100%;">
|
<div class="mb15" style="width: 100%;">
|
||||||
<el-button
|
<el-button
|
||||||
|
v-auth="'professional_professionaltitlerelation_add'"
|
||||||
type="primary"
|
type="primary"
|
||||||
icon="FolderAdd"
|
icon="FolderAdd"
|
||||||
@click="handleAdd"
|
@click="handleAdd">新 增
|
||||||
v-if="permissions.professional_professionaltitlerelation_add">新 增
|
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
|
v-auth="'professional_teacherbase_export'"
|
||||||
class="ml10"
|
class="ml10"
|
||||||
type="warning"
|
type="warning"
|
||||||
plain
|
plain
|
||||||
icon="Download"
|
icon="Download"
|
||||||
v-if="permissions.professional_teacherbase_export"
|
|
||||||
@click="handleDownLoadWord"
|
@click="handleDownLoadWord"
|
||||||
:loading="exportLoading">导出信息
|
:loading="exportLoading">导出信息
|
||||||
</el-button>
|
</el-button>
|
||||||
@@ -162,31 +162,50 @@
|
|||||||
<el-table-column label="操作" width="280" align="center" fixed="right">
|
<el-table-column label="操作" width="280" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
|
v-auth="'professional_professionaltitlerelation_edit'"
|
||||||
|
v-if="scope.row.state === '0' || scope.row.state === '-2'"
|
||||||
type="primary"
|
type="primary"
|
||||||
link
|
link
|
||||||
icon="edit-pen"
|
icon="edit-pen"
|
||||||
v-if="permissions.professional_professionaltitlerelation_edit && (scope.row.state === '0' || scope.row.state === '-2')"
|
@click="handleEdit(scope.row)">修改
|
||||||
@click="handleEdit(scope.row)">编辑
|
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
|
v-auth="'professional_professionaltitlerelation_exam'"
|
||||||
|
v-if="scope.row.canExam"
|
||||||
type="success"
|
type="success"
|
||||||
link
|
link
|
||||||
icon="CircleCheck"
|
icon="CircleCheck"
|
||||||
v-if="permissions.professional_professionaltitlerelation_exam && scope.row.state === '0'"
|
|
||||||
@click="changeState(scope.row, 1)">通过
|
@click="changeState(scope.row, 1)">通过
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
type="success"
|
||||||
|
link
|
||||||
|
icon="CircleCheck"
|
||||||
|
v-auth="'professional_professionaltitlerelation_exam'"
|
||||||
|
v-if="scope.row.canDeptExam"
|
||||||
|
@click="changeState(scope.row, 1)">部门通过
|
||||||
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
|
v-auth="'professional_professionaltitlerelation_exam'"
|
||||||
|
v-if="scope.row.canBack"
|
||||||
type="danger"
|
type="danger"
|
||||||
link
|
link
|
||||||
icon="CircleClose"
|
icon="CircleClose"
|
||||||
v-if="permissions.professional_professionaltitlerelation_exam && (scope.row.state === '0' || scope.row.state === '1')"
|
|
||||||
@click="changeState(scope.row, -2)">驳回
|
@click="changeState(scope.row, -2)">驳回
|
||||||
</el-button>
|
</el-button>
|
||||||
|
<el-button
|
||||||
|
type="danger"
|
||||||
|
link
|
||||||
|
v-auth="'professional_professionaltitlerelation_exam'"
|
||||||
|
icon="CircleClose"
|
||||||
|
v-if="scope.row.canDeptBack"
|
||||||
|
@click="changeState(scope.row, -2)">部门驳回
|
||||||
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
|
v-auth="'professional_professionaltitlerelation_del'"
|
||||||
type="danger"
|
type="danger"
|
||||||
link
|
link
|
||||||
icon="delete"
|
icon="delete"
|
||||||
v-if="permissions.professional_professionaltitlerelation_del"
|
|
||||||
style="margin-left: 12px"
|
style="margin-left: 12px"
|
||||||
@click="handleDel(scope.row)">删除
|
@click="handleDel(scope.row)">删除
|
||||||
</el-button>
|
</el-button>
|
||||||
@@ -218,9 +237,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, computed, onMounted, nextTick } from 'vue'
|
import { ref, reactive, onMounted, nextTick } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { useMessageBox } from '/@/hooks/message'
|
import { useMessageBox } from '/@/hooks/message'
|
||||||
@@ -244,18 +261,6 @@ const ProfessionalBackResaon = defineAsyncComponent(() => import('/@/views/profe
|
|||||||
const previewFile = defineAsyncComponent(() => import('/@/components/tools/preview-file.vue'))
|
const previewFile = defineAsyncComponent(() => import('/@/components/tools/preview-file.vue'))
|
||||||
|
|
||||||
// 使用 Pinia store
|
// 使用 Pinia store
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
const messageBox = useMessageBox()
|
const messageBox = useMessageBox()
|
||||||
@@ -452,11 +457,9 @@ const loadDictData = async () => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 初始化
|
// 初始化:仅加载下拉字典,表格数据由 useTable 在 createdIsNeed: true 时自动请求
|
||||||
onMounted(async () => {
|
onMounted(async () => {
|
||||||
await loadDictData()
|
await loadDictData()
|
||||||
dataFormRef.value?.init()
|
|
||||||
getDataList()
|
|
||||||
})
|
})
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
icon="FolderAdd"
|
icon="FolderAdd"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
v-if="permissions.professional_professionaltopiclevelconfig_add">新 增
|
v-auth="'professional_professionaltopiclevelconfig_add'">新 增
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-row>
|
</el-row>
|
||||||
@@ -35,14 +35,14 @@
|
|||||||
<el-table-column label="操作" width="150" align="center" fixed="right">
|
<el-table-column label="操作" width="150" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_professionaltopiclevelconfig_edit"
|
v-auth="'professional_professionaltopiclevelconfig_edit'"
|
||||||
icon="edit-pen"
|
icon="edit-pen"
|
||||||
link
|
link
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="handleEdit(scope.row)">修改
|
@click="handleEdit(scope.row)">修改
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_professionaltopiclevelconfig_del"
|
v-auth="'professional_professionaltopiclevelconfig_del'"
|
||||||
icon="delete"
|
icon="delete"
|
||||||
link
|
link
|
||||||
type="danger"
|
type="danger"
|
||||||
@@ -63,7 +63,7 @@
|
|||||||
<!-- 新增/编辑弹窗 -->
|
<!-- 新增/编辑弹窗 -->
|
||||||
<el-dialog
|
<el-dialog
|
||||||
v-model="dialogVisible"
|
v-model="dialogVisible"
|
||||||
:title="form.id ? '编辑' : '新增'"
|
:title="form.id ? '修改' : '新增'"
|
||||||
width="600px"
|
width="600px"
|
||||||
:close-on-click-modal="false"
|
:close-on-click-modal="false"
|
||||||
destroy-on-close
|
destroy-on-close
|
||||||
@@ -114,27 +114,12 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, computed } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { useMessageBox } from '/@/hooks/message'
|
import { useMessageBox } from '/@/hooks/message'
|
||||||
import { fetchList, addObj, putObj, delObj } from '/@/api/professional/rsbase/professionaltopiclevelconfig'
|
import { fetchList, addObj, putObj, delObj } from '/@/api/professional/rsbase/professionaltopiclevelconfig'
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
const messageBox = useMessageBox()
|
const messageBox = useMessageBox()
|
||||||
@@ -235,7 +220,6 @@ const handleSubmit = async () => {
|
|||||||
getDataList()
|
getDataList()
|
||||||
} catch (error: any) {
|
} catch (error: any) {
|
||||||
// 处理业务错误
|
// 处理业务错误
|
||||||
message.error(error.msg)
|
|
||||||
} finally {
|
} finally {
|
||||||
submitLoading.value = false
|
submitLoading.value = false
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
icon="FolderAdd"
|
icon="FolderAdd"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
v-if="permissions.professional_professionaltopicsourceconfig_add">新 增
|
v-auth="'professional_professionaltopicsourceconfig_add'">新 增
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-row>
|
</el-row>
|
||||||
@@ -35,14 +35,14 @@
|
|||||||
<el-table-column label="操作" width="150" align="center" fixed="right">
|
<el-table-column label="操作" width="150" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_professionaltopicsourceconfig_edit"
|
v-auth="'professional_professionaltopicsourceconfig_edit'"
|
||||||
icon="edit-pen"
|
icon="edit-pen"
|
||||||
link
|
link
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="handleEdit(scope.row)">修改
|
@click="handleEdit(scope.row)">修改
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_professionaltopicsourceconfig_del"
|
v-auth="'professional_professionaltopicsourceconfig_del'"
|
||||||
icon="delete"
|
icon="delete"
|
||||||
link
|
link
|
||||||
type="danger"
|
type="danger"
|
||||||
@@ -63,7 +63,7 @@
|
|||||||
<!-- 新增/编辑弹窗 -->
|
<!-- 新增/编辑弹窗 -->
|
||||||
<el-dialog
|
<el-dialog
|
||||||
v-model="dialogVisible"
|
v-model="dialogVisible"
|
||||||
:title="form.id ? '编辑' : '新增'"
|
:title="form.id ? '修改' : '新增'"
|
||||||
width="600px"
|
width="600px"
|
||||||
:close-on-click-modal="false"
|
:close-on-click-modal="false"
|
||||||
destroy-on-close
|
destroy-on-close
|
||||||
@@ -114,27 +114,12 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, computed } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { useMessageBox } from '/@/hooks/message'
|
import { useMessageBox } from '/@/hooks/message'
|
||||||
import { fetchList, addObj, putObj, delObj } from '/@/api/professional/rsbase/professionaltopicsourceconfig'
|
import { fetchList, addObj, putObj, delObj } from '/@/api/professional/rsbase/professionaltopicsourceconfig'
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
const messageBox = useMessageBox()
|
const messageBox = useMessageBox()
|
||||||
@@ -235,7 +220,6 @@ const handleSubmit = async () => {
|
|||||||
getDataList()
|
getDataList()
|
||||||
} catch (error: any) {
|
} catch (error: any) {
|
||||||
// 处理业务错误
|
// 处理业务错误
|
||||||
message.error(error.msg)
|
|
||||||
} finally {
|
} finally {
|
||||||
submitLoading.value = false
|
submitLoading.value = false
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
icon="FolderAdd"
|
icon="FolderAdd"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
v-if="permissions.professional_worktype_add">新 增
|
v-auth="'professional_worktype_add'">新 增
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-row>
|
</el-row>
|
||||||
@@ -31,14 +31,14 @@
|
|||||||
<el-table-column label="操作" width="150" align="center" fixed="right">
|
<el-table-column label="操作" width="150" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_worktype_edit"
|
v-auth="'professional_worktype_edit'"
|
||||||
icon="edit-pen"
|
icon="edit-pen"
|
||||||
link
|
link
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="handleEdit(scope.row)">修改
|
@click="handleEdit(scope.row)">修改
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_worktype_del"
|
v-auth="'professional_worktype_del'"
|
||||||
icon="delete"
|
icon="delete"
|
||||||
link
|
link
|
||||||
type="danger"
|
type="danger"
|
||||||
@@ -59,7 +59,7 @@
|
|||||||
<!-- 新增/编辑弹窗 -->
|
<!-- 新增/编辑弹窗 -->
|
||||||
<el-dialog
|
<el-dialog
|
||||||
v-model="dialogVisible"
|
v-model="dialogVisible"
|
||||||
:title="form.id ? '编辑' : '新增'"
|
:title="form.id ? '修改' : '新增'"
|
||||||
width="600px"
|
width="600px"
|
||||||
:close-on-click-modal="false"
|
:close-on-click-modal="false"
|
||||||
destroy-on-close
|
destroy-on-close
|
||||||
@@ -91,27 +91,12 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, computed } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { useMessageBox } from '/@/hooks/message'
|
import { useMessageBox } from '/@/hooks/message'
|
||||||
import { fetchList, addObj, putObj, delObj } from '/@/api/professional/rsbase/professionalworktype'
|
import { fetchList, addObj, putObj, delObj } from '/@/api/professional/rsbase/professionalworktype'
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
const messageBox = useMessageBox()
|
const messageBox = useMessageBox()
|
||||||
@@ -203,7 +188,6 @@ const handleSubmit = async () => {
|
|||||||
getDataList()
|
getDataList()
|
||||||
} catch (error: any) {
|
} catch (error: any) {
|
||||||
// 处理业务错误
|
// 处理业务错误
|
||||||
message.error(error.msg)
|
|
||||||
} finally {
|
} finally {
|
||||||
submitLoading.value = false
|
submitLoading.value = false
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
icon="FolderAdd"
|
icon="FolderAdd"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
v-if="permissions.professional_professionalyearbounds_add">新 增
|
v-auth="'professional_professionalyearbounds_add'">新 增
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-row>
|
</el-row>
|
||||||
@@ -46,14 +46,14 @@
|
|||||||
<el-table-column label="操作" min-width="150" align="center" fixed="right">
|
<el-table-column label="操作" min-width="150" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_professionalyearbounds_edit"
|
v-auth="'professional_professionalyearbounds_edit'"
|
||||||
icon="edit-pen"
|
icon="edit-pen"
|
||||||
link
|
link
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="handleEdit(scope.row)">修改
|
@click="handleEdit(scope.row)">修改
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_professionalyearbounds_del"
|
v-auth="'professional_professionalyearbounds_del'"
|
||||||
icon="delete"
|
icon="delete"
|
||||||
link
|
link
|
||||||
type="danger"
|
type="danger"
|
||||||
@@ -74,7 +74,7 @@
|
|||||||
<!-- 新增/编辑弹窗 -->
|
<!-- 新增/编辑弹窗 -->
|
||||||
<el-dialog
|
<el-dialog
|
||||||
v-model="dialogVisible"
|
v-model="dialogVisible"
|
||||||
:title="form.id ? '编辑' : '新增'"
|
:title="form.id ? '修改' : '新增'"
|
||||||
width="800px"
|
width="800px"
|
||||||
:close-on-click-modal="false"
|
:close-on-click-modal="false"
|
||||||
destroy-on-close
|
destroy-on-close
|
||||||
@@ -175,29 +175,14 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, computed } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { defineAsyncComponent } from 'vue'
|
import { defineAsyncComponent } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage, useMessageBox } from '/@/hooks/message'
|
import { useMessage, useMessageBox } from '/@/hooks/message'
|
||||||
import { fetchList, addObj, putObj, delObj } from '/@/api/professional/salaries/professionalyearbounds'
|
import { fetchList, addObj, putObj, delObj } from '/@/api/professional/salaries/professionalyearbounds'
|
||||||
|
|
||||||
const TeacherNameNo = defineAsyncComponent(() => import('/@/components/TeacherNameNo/index.vue'))
|
const TeacherNameNo = defineAsyncComponent(() => import('/@/components/TeacherNameNo/index.vue'))
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
const messageBox = useMessageBox()
|
const messageBox = useMessageBox()
|
||||||
@@ -317,7 +302,7 @@ const handleSubmit = async () => {
|
|||||||
dialogVisible.value = false
|
dialogVisible.value = false
|
||||||
getDataList(false) // 提交后保持当前页
|
getDataList(false) // 提交后保持当前页
|
||||||
} catch (error: any) {
|
} catch (error: any) {
|
||||||
message.error(error.msg)
|
// 错误处理已在数据请求层统一处理,此处不需要提示
|
||||||
} finally {
|
} finally {
|
||||||
submitLoading.value = false
|
submitLoading.value = false
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -72,7 +72,7 @@
|
|||||||
<el-table-column label="操作" min-width="80" align="center" fixed="right">
|
<el-table-column label="操作" min-width="80" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_salaryexportrecord_del"
|
v-auth="'professional_salaryexportrecord_del'"
|
||||||
icon="delete"
|
icon="delete"
|
||||||
link
|
link
|
||||||
type="primary"
|
type="primary"
|
||||||
@@ -93,26 +93,11 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, computed } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage, useMessageBox } from '/@/hooks/message'
|
import { useMessage, useMessageBox } from '/@/hooks/message'
|
||||||
import { fetchList, delObj } from '/@/api/professional/salaries/salaryexportrecord'
|
import { fetchList, delObj } from '/@/api/professional/salaries/salaryexportrecord'
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
const messageBox = useMessageBox()
|
const messageBox = useMessageBox()
|
||||||
@@ -169,7 +154,7 @@ const handleDel = (row: any) => {
|
|||||||
message.success('删除成功')
|
message.success('删除成功')
|
||||||
getDataList(false) // 删除后保持当前页
|
getDataList(false) // 删除后保持当前页
|
||||||
} catch (error: any) {
|
} catch (error: any) {
|
||||||
message.error(error.msg)
|
// 错误处理已在数据请求层统一处理,此处不需要提示
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
// 用户取消
|
// 用户取消
|
||||||
|
|||||||
@@ -27,7 +27,7 @@
|
|||||||
</template>
|
</template>
|
||||||
<el-button
|
<el-button
|
||||||
size="small"
|
size="small"
|
||||||
v-if="permissions.professional_salary_import"
|
v-auth="'teacher_award_import'"
|
||||||
type="primary">选择文件
|
type="primary">选择文件
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-upload>
|
</el-upload>
|
||||||
@@ -45,8 +45,6 @@
|
|||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, computed } from 'vue'
|
import { ref, computed } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { Session } from '/@/utils/storage'
|
import { Session } from '/@/utils/storage'
|
||||||
import request from '/@/utils/request'
|
import request from '/@/utils/request'
|
||||||
@@ -56,19 +54,6 @@ const emit = defineEmits<{
|
|||||||
(e: 'refreshData'): void
|
(e: 'refreshData'): void
|
||||||
}>()
|
}>()
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示
|
// 消息提示
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
|
|
||||||
|
|||||||
@@ -55,7 +55,7 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
plain
|
plain
|
||||||
icon="UploadFilled"
|
icon="UploadFilled"
|
||||||
v-if="permissions.teacher_award_import"
|
v-auth="'teacher_award_import'"
|
||||||
@click="handleImportBaseSalary">绩效导入
|
@click="handleImportBaseSalary">绩效导入
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
@@ -107,25 +107,10 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, computed } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { fetchList } from '/@/api/professional/salaries/teacherawardtax'
|
import { fetchList } from '/@/api/professional/salaries/teacherawardtax'
|
||||||
import ImportAwardTax from './importAwardTax.vue'
|
const ImportAwardTax = defineAsyncComponent(() => import('./importAwardTax.vue'))
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 表格引用
|
// 表格引用
|
||||||
const tableRef = ref()
|
const tableRef = ref()
|
||||||
|
|||||||
@@ -1492,7 +1492,7 @@
|
|||||||
import {updateStatus} from '/@/api/professional/professionalstatuslock'
|
import {updateStatus} from '/@/api/professional/professionalstatuslock'
|
||||||
import {resetPassWord} from "/@/api/professional/professionaluser/teacherbase"
|
import {resetPassWord} from "/@/api/professional/professionaluser/teacherbase"
|
||||||
// 组件配置已不再需要(已从 avue-crud 迁移到 el-table)
|
// 组件配置已不再需要(已从 avue-crud 迁移到 el-table)
|
||||||
import authImg from "/@/components/tools/auth-img.vue"
|
const authImg = defineAsyncComponent(() => import("/@/components/tools/auth-img.vue"))
|
||||||
|
|
||||||
// 导入工具
|
// 导入工具
|
||||||
import { Session } from '/@/utils/storage'
|
import { Session } from '/@/utils/storage'
|
||||||
|
|||||||
@@ -27,7 +27,7 @@
|
|||||||
</template>
|
</template>
|
||||||
<el-button
|
<el-button
|
||||||
size="small"
|
size="small"
|
||||||
v-if="permissions.professional_salary_import"
|
v-auth="'professional_salary_import'"
|
||||||
type="primary">选择文件
|
type="primary">选择文件
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-upload>
|
</el-upload>
|
||||||
@@ -45,8 +45,6 @@
|
|||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, computed } from 'vue'
|
import { ref, computed } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { Session } from '/@/utils/storage'
|
import { Session } from '/@/utils/storage'
|
||||||
import request from '/@/utils/request'
|
import request from '/@/utils/request'
|
||||||
@@ -56,19 +54,6 @@ const emit = defineEmits<{
|
|||||||
(e: 'refreshData'): void
|
(e: 'refreshData'): void
|
||||||
}>()
|
}>()
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示
|
// 消息提示
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
|
|
||||||
|
|||||||
@@ -27,7 +27,7 @@
|
|||||||
</template>
|
</template>
|
||||||
<el-button
|
<el-button
|
||||||
size="small"
|
size="small"
|
||||||
v-if="permissions.professional_salary_import"
|
v-auth="'professional_salary_import'"
|
||||||
type="primary">选择文件
|
type="primary">选择文件
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-upload>
|
</el-upload>
|
||||||
@@ -45,8 +45,6 @@
|
|||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, computed } from 'vue'
|
import { ref, computed } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { Session } from '/@/utils/storage'
|
import { Session } from '/@/utils/storage'
|
||||||
import request from '/@/utils/request'
|
import request from '/@/utils/request'
|
||||||
@@ -56,19 +54,6 @@ const emit = defineEmits<{
|
|||||||
(e: 'refreshData'): void
|
(e: 'refreshData'): void
|
||||||
}>()
|
}>()
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示
|
// 消息提示
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
|
|
||||||
|
|||||||
@@ -90,19 +90,19 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
plain
|
plain
|
||||||
icon="UploadFilled"
|
icon="UploadFilled"
|
||||||
v-if="permissions.professional_salary_import"
|
v-auth="'professional_salary_import'"
|
||||||
@click="handleImportBaseSalary">工资条导入
|
@click="handleImportBaseSalary">工资条导入
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
icon="View"
|
icon="View"
|
||||||
class="ml10"
|
class="ml10"
|
||||||
v-if="permissions.professional_seach_auth"
|
v-auth="'professional_seach_auth'"
|
||||||
@click="canSearch(1)">设置可查询
|
@click="canSearch(1)">设置可查询
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
icon="Hide"
|
icon="Hide"
|
||||||
class="ml10"
|
class="ml10"
|
||||||
v-if="permissions.professional_seach_auth"
|
v-auth="'professional_seach_auth'"
|
||||||
@click="canSearch(0)">设置不可查询
|
@click="canSearch(0)">设置不可查询
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
@@ -110,7 +110,7 @@
|
|||||||
plain
|
plain
|
||||||
icon="Delete"
|
icon="Delete"
|
||||||
class="ml10"
|
class="ml10"
|
||||||
v-if="permissions.professional_professionalsalaries_del"
|
v-auth="'professional_professionalsalaries_del'"
|
||||||
@click="delbatch">批量删除
|
@click="delbatch">批量删除
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
@@ -186,33 +186,19 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, computed, onMounted } from 'vue'
|
import { ref, reactive, onMounted } from 'vue'
|
||||||
import { defineAsyncComponent } from 'vue'
|
import { defineAsyncComponent } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage, useMessageBox } from '/@/hooks/message'
|
import { useMessage, useMessageBox } from '/@/hooks/message'
|
||||||
import { fetchList, delBatch, setCanSearch } from '/@/api/professional/salaries/teacherpayslip'
|
import { fetchList, delBatch, setCanSearch } from '/@/api/professional/salaries/teacherpayslip'
|
||||||
import { checkAuth } from '/@/api/professional/salaries/teachersalary'
|
import { checkAuth } from '/@/api/professional/salaries/teachersalary'
|
||||||
import { getStationLevelList } from '/@/api/professional/professionalstationlevelconfig'
|
import { getStationLevelList } from '/@/api/professional/professionalstationlevelconfig'
|
||||||
import SalaryInfo from './salaryInfo.vue'
|
const SalaryInfo = defineAsyncComponent(() => import('./salaryInfo.vue'))
|
||||||
import ImportBaseSalary from './importBaseSalary.vue'
|
const ImportBaseSalary = defineAsyncComponent(() => import('./importBaseSalary.vue'))
|
||||||
import ExportBaseSalary from './exportBaseSalary.vue'
|
const ExportBaseSalary = defineAsyncComponent(() => import('./exportBaseSalary.vue'))
|
||||||
|
|
||||||
const TeacherNameNo = defineAsyncComponent(() => import('/@/components/TeacherNameNo/index.vue'))
|
const TeacherNameNo = defineAsyncComponent(() => import('/@/components/TeacherNameNo/index.vue'))
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
@@ -339,7 +325,7 @@ const delbatch = () => {
|
|||||||
getDataList(false) // 删除后保持当前页
|
getDataList(false) // 删除后保持当前页
|
||||||
}
|
}
|
||||||
} catch (error: any) {
|
} catch (error: any) {
|
||||||
message.error(error?.msg || '删除失败')
|
// 错误处理已在数据请求层统一处理,此处不需要提示
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
// 用户取消
|
// 用户取消
|
||||||
@@ -359,7 +345,7 @@ const canSearch = (val: number) => {
|
|||||||
message.success("设置成功")
|
message.success("设置成功")
|
||||||
getDataList(false) // 设置后保持当前页
|
getDataList(false) // 设置后保持当前页
|
||||||
} catch (error: any) {
|
} catch (error: any) {
|
||||||
message.error(error?.msg || '设置失败')
|
// 错误处理已在数据请求层统一处理,此处不需要提示
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
// 用户取消
|
// 用户取消
|
||||||
|
|||||||
@@ -27,7 +27,7 @@
|
|||||||
</template>
|
</template>
|
||||||
<el-button
|
<el-button
|
||||||
size="small"
|
size="small"
|
||||||
v-if="permissions.professional_salary_import"
|
v-auth="'professional_salary_import'"
|
||||||
type="primary">选择文件
|
type="primary">选择文件
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-upload>
|
</el-upload>
|
||||||
@@ -45,8 +45,6 @@
|
|||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, computed } from 'vue'
|
import { ref, computed } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { Session } from '/@/utils/storage'
|
import { Session } from '/@/utils/storage'
|
||||||
import request from '/@/utils/request'
|
import request from '/@/utils/request'
|
||||||
@@ -56,19 +54,6 @@ const emit = defineEmits<{
|
|||||||
(e: 'refreshData'): void
|
(e: 'refreshData'): void
|
||||||
}>()
|
}>()
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示
|
// 消息提示
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
|
|
||||||
|
|||||||
@@ -27,7 +27,7 @@
|
|||||||
</template>
|
</template>
|
||||||
<el-button
|
<el-button
|
||||||
size="small"
|
size="small"
|
||||||
v-if="permissions.professional_salary_import"
|
v-auth="'professional_salary_import'"
|
||||||
type="primary">选择文件
|
type="primary">选择文件
|
||||||
</el-button>
|
</el-button>
|
||||||
</el-upload>
|
</el-upload>
|
||||||
@@ -45,8 +45,6 @@
|
|||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, computed } from 'vue'
|
import { ref, computed } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { Session } from '/@/utils/storage'
|
import { Session } from '/@/utils/storage'
|
||||||
import request from '/@/utils/request'
|
import request from '/@/utils/request'
|
||||||
@@ -56,19 +54,6 @@ const emit = defineEmits<{
|
|||||||
(e: 'refreshData'): void
|
(e: 'refreshData'): void
|
||||||
}>()
|
}>()
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示
|
// 消息提示
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
|
|
||||||
|
|||||||
@@ -96,7 +96,7 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
plain
|
plain
|
||||||
icon="UploadFilled"
|
icon="UploadFilled"
|
||||||
v-if="permissions.professional_salary_import"
|
v-auth="'professional_salary_import'"
|
||||||
@click="handleImportBaseSalary">人事薪资导入
|
@click="handleImportBaseSalary">人事薪资导入
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
@@ -104,7 +104,7 @@
|
|||||||
plain
|
plain
|
||||||
icon="Download"
|
icon="Download"
|
||||||
class="ml10"
|
class="ml10"
|
||||||
v-if="permissions.professional_salary_finance_import"
|
v-auth="'professional_salary_finance_import'"
|
||||||
@click="handleExportSalart">薪资导出
|
@click="handleExportSalart">薪资导出
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
@@ -112,19 +112,19 @@
|
|||||||
plain
|
plain
|
||||||
icon="UploadFilled"
|
icon="UploadFilled"
|
||||||
class="ml10"
|
class="ml10"
|
||||||
v-if="permissions.professional_salary_finance_import"
|
v-auth="'professional_salary_finance_import'"
|
||||||
@click="handleImportTaxSalary">税金导入
|
@click="handleImportTaxSalary">税金导入
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
icon="View"
|
icon="View"
|
||||||
class="ml10"
|
class="ml10"
|
||||||
v-if="permissions.professional_seach_auth"
|
v-auth="'professional_seach_auth'"
|
||||||
@click="canSearch(1)">设置可查询
|
@click="canSearch(1)">设置可查询
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
icon="Hide"
|
icon="Hide"
|
||||||
class="ml10"
|
class="ml10"
|
||||||
v-if="permissions.professional_seach_auth"
|
v-auth="'professional_seach_auth'"
|
||||||
@click="canSearch(0)">设置不可查询
|
@click="canSearch(0)">设置不可查询
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
@@ -132,7 +132,7 @@
|
|||||||
plain
|
plain
|
||||||
icon="Delete"
|
icon="Delete"
|
||||||
class="ml10"
|
class="ml10"
|
||||||
v-if="permissions.professional_professionalsalaries_del"
|
v-auth="'professional_professionalsalaries_del'"
|
||||||
@click="delbatch">批量删除
|
@click="delbatch">批量删除
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
@@ -208,33 +208,18 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, computed, onMounted } from 'vue'
|
import { ref, reactive, onMounted } from 'vue'
|
||||||
import { defineAsyncComponent } from 'vue'
|
import { defineAsyncComponent } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage, useMessageBox } from '/@/hooks/message'
|
import { useMessage, useMessageBox } from '/@/hooks/message'
|
||||||
import { fetchList, delBatch, setCanSearch, checkAuth } from '/@/api/professional/salaries/teachersalary'
|
import { fetchList, delBatch, setCanSearch, checkAuth } from '/@/api/professional/salaries/teachersalary'
|
||||||
import { getStationLevelList } from '/@/api/professional/professionalstationlevelconfig'
|
import { getStationLevelList } from '/@/api/professional/professionalstationlevelconfig'
|
||||||
import SalaryInfo from './salaryInfo.vue'
|
const SalaryInfo = defineAsyncComponent(() => import('./salaryInfo.vue'))
|
||||||
import ImportBaseSalary from './importBaseSalary.vue'
|
const ImportBaseSalary = defineAsyncComponent(() => import('./importBaseSalary.vue'))
|
||||||
|
const ExportBaseSalary = defineAsyncComponent(() => import('./exportBaseSalary.vue'))
|
||||||
|
const ImportTaxSalary = defineAsyncComponent(() => import('./importTaxSalary.vue'))
|
||||||
|
|
||||||
const TeacherNameNo = defineAsyncComponent(() => import('/@/components/TeacherNameNo/index.vue'))
|
const TeacherNameNo = defineAsyncComponent(() => import('/@/components/TeacherNameNo/index.vue'))
|
||||||
import ExportBaseSalary from './exportBaseSalary.vue'
|
|
||||||
import ImportTaxSalary from './importTaxSalary.vue'
|
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
@@ -396,7 +381,7 @@ const canSearch = (val: number) => {
|
|||||||
message.success("设置成功")
|
message.success("设置成功")
|
||||||
getDataList(false) // 设置后保持当前页
|
getDataList(false) // 设置后保持当前页
|
||||||
} catch (error: any) {
|
} catch (error: any) {
|
||||||
message.error(error?.msg || '设置失败')
|
// 错误处理已在数据请求层统一处理,此处不需要提示
|
||||||
}
|
}
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
// 用户取消
|
// 用户取消
|
||||||
|
|||||||
@@ -341,7 +341,7 @@ const searchUserInfo = async () => {
|
|||||||
message.success('查询成功')
|
message.success('查询成功')
|
||||||
}
|
}
|
||||||
} catch (error: any) {
|
} catch (error: any) {
|
||||||
message.error(error?.msg || '查询失败')
|
// 错误处理已在数据请求层统一处理,此处不需要提示
|
||||||
} finally {
|
} finally {
|
||||||
baseLoading.value = false
|
baseLoading.value = false
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -8,7 +8,7 @@
|
|||||||
type="primary"
|
type="primary"
|
||||||
icon="FolderAdd"
|
icon="FolderAdd"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
v-if="permissions.professional_typeofworkconfig_add">新 增
|
v-auth="'professional_typeofworkconfig_add'">新 增
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-row>
|
</el-row>
|
||||||
@@ -35,14 +35,14 @@
|
|||||||
<el-table-column label="操作" width="150" align="center" fixed="right">
|
<el-table-column label="操作" width="150" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_typeofworkconfig_edit"
|
v-auth="'professional_typeofworkconfig_edit'"
|
||||||
icon="edit-pen"
|
icon="edit-pen"
|
||||||
link
|
link
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="handleEdit(scope.row)">修改
|
@click="handleEdit(scope.row)">修改
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.professional_typeofworkconfig_del"
|
v-auth="'professional_typeofworkconfig_del'"
|
||||||
icon="delete"
|
icon="delete"
|
||||||
link
|
link
|
||||||
type="danger"
|
type="danger"
|
||||||
@@ -63,7 +63,7 @@
|
|||||||
<!-- 新增/编辑弹窗 -->
|
<!-- 新增/编辑弹窗 -->
|
||||||
<el-dialog
|
<el-dialog
|
||||||
v-model="dialogVisible"
|
v-model="dialogVisible"
|
||||||
:title="form.id ? '编辑' : '新增'"
|
:title="form.id ? '修改' : '新增'"
|
||||||
width="600px"
|
width="600px"
|
||||||
:close-on-click-modal="false"
|
:close-on-click-modal="false"
|
||||||
destroy-on-close
|
destroy-on-close
|
||||||
@@ -114,27 +114,12 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, computed } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { useMessageBox } from '/@/hooks/message'
|
import { useMessageBox } from '/@/hooks/message'
|
||||||
import { fetchList, addObj, putObj, delObj } from '/@/api/professional/rsbase/typeofworkconfig'
|
import { fetchList, addObj, putObj, delObj } from '/@/api/professional/rsbase/typeofworkconfig'
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
const messageBox = useMessageBox()
|
const messageBox = useMessageBox()
|
||||||
@@ -235,7 +220,7 @@ const handleSubmit = async () => {
|
|||||||
getDataList()
|
getDataList()
|
||||||
} catch (error: any) {
|
} catch (error: any) {
|
||||||
// 处理业务错误
|
// 处理业务错误
|
||||||
message.error(error.msg)
|
// 错误处理已在数据请求层统一处理,此处不需要提示
|
||||||
} finally {
|
} finally {
|
||||||
submitLoading.value = false
|
submitLoading.value = false
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -57,7 +57,7 @@
|
|||||||
|
|
||||||
<div class="mb15">
|
<div class="mb15">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.recruit_newstucheckin_statistics_output"
|
v-auth="'recruit_newstucheckin_statistics_output'"
|
||||||
type="warning"
|
type="warning"
|
||||||
plain
|
plain
|
||||||
icon="Download"
|
icon="Download"
|
||||||
@@ -97,8 +97,6 @@
|
|||||||
|
|
||||||
<script setup lang="ts" name="backSchoolCheckin-statistics">
|
<script setup lang="ts" name="backSchoolCheckin-statistics">
|
||||||
import { ref, reactive, computed, onMounted } from 'vue'
|
import { ref, reactive, computed, onMounted } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { getDataStatistics } from '/@/api/recruit/newstucheckin'
|
import { getDataStatistics } from '/@/api/recruit/newstucheckin'
|
||||||
import { getList } from '/@/api/recruit/recruitstudentplangroup'
|
import { getList } from '/@/api/recruit/recruitstudentplangroup'
|
||||||
@@ -106,19 +104,6 @@ import { getDeptList } from '/@/api/basic/basicclass'
|
|||||||
import { queryAllClass } from '/@/api/basic/basicclass'
|
import { queryAllClass } from '/@/api/basic/basicclass'
|
||||||
import axios from 'axios'
|
import axios from 'axios'
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
|
|
||||||
|
|||||||
@@ -57,7 +57,7 @@
|
|||||||
|
|
||||||
<div class="mb15">
|
<div class="mb15">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.recruit_newstucheckin_statistics_output"
|
v-auth="'recruit_newstucheckin_statistics_output'"
|
||||||
type="warning"
|
type="warning"
|
||||||
plain
|
plain
|
||||||
icon="Download"
|
icon="Download"
|
||||||
@@ -96,9 +96,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts" name="newstucheckin-statistics">
|
<script setup lang="ts" name="newstucheckin-statistics">
|
||||||
import { ref, reactive, computed, onMounted } from 'vue'
|
import { ref, reactive, onMounted } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { getDataStatistics } from '/@/api/recruit/newstucheckin'
|
import { getDataStatistics } from '/@/api/recruit/newstucheckin'
|
||||||
import { getList } from '/@/api/recruit/recruitstudentplangroup'
|
import { getList } from '/@/api/recruit/recruitstudentplangroup'
|
||||||
@@ -106,19 +104,6 @@ import { getDeptList } from '/@/api/basic/basicclass'
|
|||||||
import { queryAllClass } from '/@/api/basic/basicclass'
|
import { queryAllClass } from '/@/api/basic/basicclass'
|
||||||
import axios from 'axios'
|
import axios from 'axios'
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
|
|
||||||
|
|||||||
@@ -44,7 +44,7 @@
|
|||||||
<el-button icon="Refresh" @click="resetQuery">重置</el-button>
|
<el-button icon="Refresh" @click="resetQuery">重置</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<div class="mb15" v-if="permissions.recruit_recruitexampeople_add">
|
<div class="mb15" v-auth="'recruit_recruitexampeople_add'">
|
||||||
<el-button
|
<el-button
|
||||||
type="primary"
|
type="primary"
|
||||||
icon="FolderAdd"
|
icon="FolderAdd"
|
||||||
@@ -74,7 +74,7 @@
|
|||||||
<el-table-column label="操作" align="center" width="150px" fixed="right">
|
<el-table-column label="操作" align="center" width="150px" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.recruit_recruitexampeople_del"
|
v-auth="'recruit_recruitexampeople_del'"
|
||||||
type="danger"
|
type="danger"
|
||||||
link
|
link
|
||||||
icon="Delete"
|
icon="Delete"
|
||||||
@@ -107,28 +107,13 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts" name="recruitexampeople">
|
<script setup lang="ts" name="recruitexampeople">
|
||||||
import { ref, reactive, computed, nextTick, defineAsyncComponent } from 'vue'
|
import { ref, reactive, nextTick, defineAsyncComponent } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage, useMessageBox } from '/@/hooks/message'
|
import { useMessage, useMessageBox } from '/@/hooks/message'
|
||||||
import { addObj, delObj, fetchList } from '/@/api/recruit/recruitexampeople'
|
import { addObj, delObj, fetchList } from '/@/api/recruit/recruitexampeople'
|
||||||
|
|
||||||
const AddForm = defineAsyncComponent(() => import('./add-form.vue'))
|
const AddForm = defineAsyncComponent(() => import('./add-form.vue'))
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
const messageBox = useMessageBox()
|
const messageBox = useMessageBox()
|
||||||
|
|||||||
@@ -204,7 +204,7 @@ import { User } from '@element-plus/icons-vue'
|
|||||||
import { delObj, fetchList, sureDJ } from '/@/api/recruit/recruitprestudent'
|
import { delObj, fetchList, sureDJ } from '/@/api/recruit/recruitprestudent'
|
||||||
import { getList } from '/@/api/recruit/recruitstudentplangroup'
|
import { getList } from '/@/api/recruit/recruitstudentplangroup'
|
||||||
import { listcz } from '/@/api/recruit/recruitstudentplan'
|
import { listcz } from '/@/api/recruit/recruitstudentplan'
|
||||||
import { list as schoolListApi } from '/@/api/recruit/recruitstudentschool'
|
import { queryByGroupId as schoolListApi} from '/@/api/recruit/recruitstudentschool'
|
||||||
import { getDeptListByLevelTwo } from '/@/api/basic/basicdept'
|
import { getDeptListByLevelTwo } from '/@/api/basic/basicdept'
|
||||||
|
|
||||||
const TableForm = defineAsyncComponent(() => import('./enrolplantemplate-form.vue'))
|
const TableForm = defineAsyncComponent(() => import('./enrolplantemplate-form.vue'))
|
||||||
|
|||||||
@@ -24,7 +24,7 @@
|
|||||||
<el-button type="primary" icon="Search" @click="getDataList">查询</el-button>
|
<el-button type="primary" icon="Search" @click="getDataList">查询</el-button>
|
||||||
<el-button type="primary" plain icon="Refresh" class="ml10" @click="resetQuery">重置</el-button>
|
<el-button type="primary" plain icon="Refresh" class="ml10" @click="resetQuery">重置</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="permissions.recruit_recruitstudentplan_add">
|
<el-form-item v-auth="'recruit_recruitstudentplan_add'">
|
||||||
<el-button type="primary" icon="FolderAdd" class="ml10" @click="handleAdd">新增</el-button>
|
<el-button type="primary" icon="FolderAdd" class="ml10" @click="handleAdd">新增</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
@@ -60,7 +60,7 @@
|
|||||||
<el-table-column label="操作" width="150" align="center" fixed="right">
|
<el-table-column label="操作" width="150" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.recruit_recruitstudentplan_edit"
|
v-auth="'recruit_recruitstudentplan_edit'"
|
||||||
type="primary"
|
type="primary"
|
||||||
link
|
link
|
||||||
icon="EditPen"
|
icon="EditPen"
|
||||||
@@ -69,7 +69,7 @@
|
|||||||
编辑
|
编辑
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.recruit_recruitstudentplan_del"
|
v-auth="'recruit_recruitstudentplan_del'"
|
||||||
type="danger"
|
type="danger"
|
||||||
link
|
link
|
||||||
icon="Delete"
|
icon="Delete"
|
||||||
@@ -167,26 +167,11 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts" name="recruitstudentplan">
|
<script setup lang="ts" name="recruitstudentplan">
|
||||||
import { ref, reactive, computed, onMounted } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage, useMessageBox } from '/@/hooks/message'
|
import { useMessage, useMessageBox } from '/@/hooks/message'
|
||||||
import { addObj, delObj, fetchList, putObj } from '/@/api/recruit/recruitstudentplan'
|
import { addObj, delObj, fetchList, putObj } from '/@/api/recruit/recruitstudentplan'
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
const messageBox = useMessageBox()
|
const messageBox = useMessageBox()
|
||||||
@@ -312,9 +297,7 @@ const handleSubmit = async () => {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
// 表格数据由 useTable(createdIsNeed 默认 true)在挂载时自动请求
|
||||||
getDataList()
|
|
||||||
})
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
|||||||
@@ -24,7 +24,7 @@
|
|||||||
<el-button type="primary" icon="Search" @click="getDataList">查询</el-button>
|
<el-button type="primary" icon="Search" @click="getDataList">查询</el-button>
|
||||||
<el-button type="primary" plain icon="Refresh" class="ml10" @click="resetQuery">重置</el-button>
|
<el-button type="primary" plain icon="Refresh" class="ml10" @click="resetQuery">重置</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item v-if="permissions.recruit_recruitstudentplandegreeofeducation_add">
|
<el-form-item v-auth="'recruit_recruitstudentplandegreeofeducation_add'">
|
||||||
<el-button type="primary" icon="FolderAdd" class="ml10" @click="handleAdd">新增</el-button>
|
<el-button type="primary" icon="FolderAdd" class="ml10" @click="handleAdd">新增</el-button>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
@@ -48,7 +48,7 @@
|
|||||||
<el-table-column label="操作" width="150" align="center" fixed="right">
|
<el-table-column label="操作" width="150" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.recruit_recruitstudentplandegreeofeducation_edit"
|
v-auth="'recruit_recruitstudentplandegreeofeducation_edit'"
|
||||||
type="primary"
|
type="primary"
|
||||||
link
|
link
|
||||||
icon="EditPen"
|
icon="EditPen"
|
||||||
@@ -57,7 +57,7 @@
|
|||||||
编辑
|
编辑
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.recruit_recruitstudentplandegreeofeducation_del"
|
v-auth="'recruit_recruitstudentplandegreeofeducation_del'"
|
||||||
type="danger"
|
type="danger"
|
||||||
link
|
link
|
||||||
icon="Delete"
|
icon="Delete"
|
||||||
@@ -113,26 +113,11 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts" name="recruitstudentplandegreeofeducation">
|
<script setup lang="ts" name="recruitstudentplandegreeofeducation">
|
||||||
import { ref, reactive, computed, onMounted } from 'vue'
|
import { ref, reactive } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage, useMessageBox } from '/@/hooks/message'
|
import { useMessage, useMessageBox } from '/@/hooks/message'
|
||||||
import { addObj, delObj, fetchList, putObj } from '/@/api/recruit/recruitstudentplandegreeofeducation'
|
import { addObj, delObj, fetchList, putObj } from '/@/api/recruit/recruitstudentplandegreeofeducation'
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
const messageBox = useMessageBox()
|
const messageBox = useMessageBox()
|
||||||
@@ -242,9 +227,7 @@ const handleSubmit = async () => {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
// 表格数据由 useTable(createdIsNeed 默认 true)在挂载时自动请求
|
||||||
getDataList()
|
|
||||||
})
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
|||||||
@@ -307,9 +307,9 @@ const resetQuery = () => {
|
|||||||
getDataList();
|
getDataList();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// 表格数据由 useTable(createdIsNeed 默认 true)自动请求,onMounted 仅执行 init
|
||||||
onMounted(() => {
|
onMounted(() => {
|
||||||
init();
|
init();
|
||||||
getDataList();
|
|
||||||
});
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
|
|||||||
@@ -16,6 +16,9 @@
|
|||||||
</el-option>
|
</el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
<el-form-item label="学校代码" prop="schoolCode">
|
||||||
|
<el-input v-model="dataForm.schoolCode" placeholder="学校代码"></el-input>
|
||||||
|
</el-form-item>
|
||||||
<el-form-item label="学校名称" prop="schoolName">
|
<el-form-item label="学校名称" prop="schoolName">
|
||||||
<el-input v-model="dataForm.schoolName" placeholder="学校名称"></el-input>
|
<el-input v-model="dataForm.schoolName" placeholder="学校名称"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
@@ -88,6 +91,10 @@ const dataRule = {
|
|||||||
{ required: true, message: '学校名称不能为空', trigger: 'blur' },
|
{ required: true, message: '学校名称不能为空', trigger: 'blur' },
|
||||||
{ min: 1, max: 20, message: '学校名称长度不大于20个字符', trigger: 'blur' }
|
{ min: 1, max: 20, message: '学校名称长度不大于20个字符', trigger: 'blur' }
|
||||||
],
|
],
|
||||||
|
schoolCode:[
|
||||||
|
{ required: true, message: '学校代码不能为空', trigger: 'blur' },
|
||||||
|
{ min: 1, max: 20, message: '学校代码长度不大于20个字符', trigger: 'blur' }
|
||||||
|
],
|
||||||
area: [
|
area: [
|
||||||
{ required: true, message: '地区不能为空', trigger: 'blur' },
|
{ required: true, message: '地区不能为空', trigger: 'blur' },
|
||||||
],
|
],
|
||||||
|
|||||||
@@ -62,6 +62,7 @@
|
|||||||
:header-cell-style="tableStyle.headerCellStyle"
|
:header-cell-style="tableStyle.headerCellStyle"
|
||||||
>
|
>
|
||||||
<el-table-column type="index" label="序号" width="60" align="center" />
|
<el-table-column type="index" label="序号" width="60" align="center" />
|
||||||
|
<el-table-column prop="schoolCode" label="学校代码" align="center" show-overflow-tooltip />
|
||||||
<el-table-column prop="schoolName" label="学校名称" align="center" show-overflow-tooltip />
|
<el-table-column prop="schoolName" label="学校名称" align="center" show-overflow-tooltip />
|
||||||
<el-table-column prop="deptCode" label="对接学院" align="center" show-overflow-tooltip>
|
<el-table-column prop="deptCode" label="对接学院" align="center" show-overflow-tooltip>
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
|
|||||||
@@ -28,7 +28,12 @@
|
|||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="8">
|
<el-col :span="8">
|
||||||
<el-form-item label="联系人" prop="contactName">
|
<el-form-item label="联系人" prop="contactName">
|
||||||
<el-select v-model="dataForm.contactName" filterable clearable placeholder="" :disabled="!(permissions.recruit_recruitprestudent_dj_sure || dataForm.auditStatus != '20')">
|
<el-select
|
||||||
|
v-model="dataForm.contactName"
|
||||||
|
filterable
|
||||||
|
clearable
|
||||||
|
placeholder=""
|
||||||
|
:disabled="!(auth('recruit_recruitprestudent_dj_sure') || dataForm.auditStatus != '20')">
|
||||||
<el-option
|
<el-option
|
||||||
v-for="item in contactNameList"
|
v-for="item in contactNameList"
|
||||||
:key="item.teacherNo"
|
:key="item.teacherNo"
|
||||||
@@ -193,11 +198,10 @@
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { ref, reactive, nextTick, computed, onMounted } from 'vue'
|
import { ref, reactive, nextTick, computed, onMounted } from 'vue'
|
||||||
import { Plus } from '@element-plus/icons-vue'
|
import { Plus } from '@element-plus/icons-vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { useMessage } from '/@/hooks/message'
|
import { useMessage } from '/@/hooks/message'
|
||||||
import { Session } from '/@/utils/storage'
|
import { Session } from '/@/utils/storage'
|
||||||
import axios from 'axios'
|
import axios from 'axios'
|
||||||
|
import { auth } from '/@/utils/authFunction'
|
||||||
import { getObj, materialExam } from '/@/api/recruit/recruitstudentsignup'
|
import { getObj, materialExam } from '/@/api/recruit/recruitstudentsignup'
|
||||||
import { getList } from '/@/api/recruit/recruitstudentplangroup'
|
import { getList } from '/@/api/recruit/recruitstudentplangroup'
|
||||||
import { queryAllTeacher } from '/@/api/professional/professionaluser/teacherbase'
|
import { queryAllTeacher } from '/@/api/professional/professionaluser/teacherbase'
|
||||||
@@ -207,21 +211,9 @@ const auditStatusList = AUDIT_STATUS_LIST
|
|||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
const baseUrl = import.meta.env.VITE_API_URL
|
const baseUrl = import.meta.env.VITE_API_URL
|
||||||
const uploadUrl = baseUrl + '/recruit/file/uploadAttachment'
|
const uploadUrl = baseUrl + '/recruit/file/uploadAttachment'
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 请求头
|
// 请求头
|
||||||
const headers = computed(() => {
|
const headers = computed(() => {
|
||||||
return {
|
return {
|
||||||
|
|||||||
@@ -30,7 +30,7 @@
|
|||||||
<el-row>
|
<el-row>
|
||||||
<div>
|
<div>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.recruit_recruitstudentsignupturnovermoneychange_add"
|
v-auth="'recruit_recruitstudentsignupturnovermoneychange_add'"
|
||||||
type="primary"
|
type="primary"
|
||||||
icon="FolderAdd"
|
icon="FolderAdd"
|
||||||
@click="handleAdd">新 增
|
@click="handleAdd">新 增
|
||||||
@@ -62,7 +62,7 @@
|
|||||||
<el-table-column label="操作" width="150" align="center" fixed="right">
|
<el-table-column label="操作" width="150" align="center" fixed="right">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.recruit_recruitstudentsignupturnovermoneychange_edit"
|
v-auth="'recruit_recruitstudentsignupturnovermoneychange_edit'"
|
||||||
type="primary"
|
type="primary"
|
||||||
link
|
link
|
||||||
icon="EditPen"
|
icon="EditPen"
|
||||||
@@ -71,7 +71,7 @@
|
|||||||
编辑
|
编辑
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button
|
||||||
v-if="permissions.recruit_recruitstudentsignupturnovermoneychange_del"
|
v-auth="'recruit_recruitstudentsignupturnovermoneychange_del'"
|
||||||
type="danger"
|
type="danger"
|
||||||
link
|
link
|
||||||
icon="Delete"
|
icon="Delete"
|
||||||
@@ -97,9 +97,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup lang="ts" name="recruitstudentsignupturnovermoneychange">
|
<script setup lang="ts" name="recruitstudentsignupturnovermoneychange">
|
||||||
import { ref, reactive, computed, onMounted, defineAsyncComponent, nextTick } from 'vue'
|
import { ref, reactive, defineAsyncComponent, nextTick } from 'vue'
|
||||||
import { storeToRefs } from 'pinia'
|
|
||||||
import { useUserInfo } from '/@/stores/userInfo'
|
|
||||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||||
import { useMessage, useMessageBox } from '/@/hooks/message'
|
import { useMessage, useMessageBox } from '/@/hooks/message'
|
||||||
import { delObj, fetchList } from '/@/api/recruit/recruitstudentsignupturnovermoneychange'
|
import { delObj, fetchList } from '/@/api/recruit/recruitstudentsignupturnovermoneychange'
|
||||||
@@ -107,19 +105,6 @@ import { delObj, fetchList } from '/@/api/recruit/recruitstudentsignupturnovermo
|
|||||||
// 定义组件
|
// 定义组件
|
||||||
const FormDialog = defineAsyncComponent(() => import('./form.vue'))
|
const FormDialog = defineAsyncComponent(() => import('./form.vue'))
|
||||||
|
|
||||||
// 使用 Pinia store
|
|
||||||
const userInfoStore = useUserInfo()
|
|
||||||
const { userInfos } = storeToRefs(userInfoStore)
|
|
||||||
|
|
||||||
// 创建权限对象
|
|
||||||
const permissions = computed(() => {
|
|
||||||
const perms: Record<string, boolean> = {}
|
|
||||||
userInfos.value.authBtnList.forEach((perm: string) => {
|
|
||||||
perms[perm] = true
|
|
||||||
})
|
|
||||||
return perms
|
|
||||||
})
|
|
||||||
|
|
||||||
// 消息提示 hooks
|
// 消息提示 hooks
|
||||||
const message = useMessage()
|
const message = useMessage()
|
||||||
const messageBox = useMessageBox()
|
const messageBox = useMessageBox()
|
||||||
@@ -182,9 +167,7 @@ const handleDel = async (row: any) => {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
onMounted(() => {
|
// 表格数据由 useTable(createdIsNeed 默认 true)在挂载时自动请求
|
||||||
getDataList()
|
|
||||||
})
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
|
|||||||
Reference in New Issue
Block a user