Merge branch 'developer' of ssh://code.cyweb.top:30033/scj/zhxy/v3/cloud-ui into developer

This commit is contained in:
zhoutianchi
2026-01-07 18:34:23 +08:00
11 changed files with 277 additions and 155 deletions

View File

@@ -1,91 +0,0 @@
<template>
<el-dropdown
v-if="hasVisibleItems"
trigger="click"
@command="handleCommand"
:style="dropdownStyle"
>
<el-button
:type="buttonType"
link
:style="buttonStyle"
>
<slot name="button">
{{ buttonText }}
<el-icon v-if="buttonIcon" class="el-icon--right" :style="iconStyle">
<component :is="buttonIcon" v-if="buttonIcon" />
</el-icon>
</slot>
</el-button>
<template #dropdown>
<el-dropdown-menu>
<el-dropdown-item
v-for="item in visibleItems"
:key="item.command"
:command="item.command"
>
<el-icon v-if="item.icon">
<component :is="item.icon" />
</el-icon>
<span :style="item.icon ? { marginLeft: '8px' } : {}">{{ item.label }}</span>
</el-dropdown-item>
</el-dropdown-menu>
</template>
</el-dropdown>
</template>
<script setup lang="ts">
import { computed } from 'vue'
import { Operation } from '@element-plus/icons-vue'
interface MenuItem {
command: string
label: string
icon?: any
visible?: boolean | (() => boolean)
}
interface Props {
items: MenuItem[]
buttonText?: string
buttonIcon?: any
buttonType?: 'primary' | 'success' | 'warning' | 'danger' | 'info' | 'text'
buttonStyle?: string | Record<string, any>
dropdownStyle?: string | Record<string, any>
iconStyle?: string | Record<string, any>
}
const props = withDefaults(defineProps<Props>(), {
buttonText: '更多',
buttonIcon: Operation,
buttonType: 'primary',
buttonStyle: () => ({ whiteSpace: 'nowrap' }),
dropdownStyle: () => ({ marginLeft: '12px' }),
iconStyle: () => ({ marginLeft: '4px' })
})
const emit = defineEmits<{
command: [command: string]
}>()
// 计算可见的菜单项
const visibleItems = computed(() => {
return props.items.filter(item => {
if (item.visible === undefined) return true
if (typeof item.visible === 'boolean') return item.visible
if (typeof item.visible === 'function') return item.visible()
return false
})
})
// 是否有可见的菜单项
const hasVisibleItems = computed(() => {
return visibleItems.value.length > 0
})
// 处理命令
const handleCommand = (command: string) => {
emit('command', command)
}
</script>

View File

@@ -1449,7 +1449,7 @@
const PoliticsDialog = defineAsyncComponent(() => import('./politics-dialog.vue'));
const RelationDialog = defineAsyncComponent(() => import('./relation-dialog.vue'));
const StatusLockDialog = defineAsyncComponent(() => import('./status-lock-dialog.vue'));
const ActionDropdown = defineAsyncComponent(() => import('./action-dropdown.vue'));
const ActionDropdown = defineAsyncComponent(() => import('/@/components/tools/action-dropdown.vue'));
const TableColumnControl = defineAsyncComponent(() => import('/@/components/TableColumnControl/index.vue'));
const TableColumn = defineAsyncComponent(() => import('/@/components/TableColumn/index.vue'));
const TableColumnProvider = defineAsyncComponent(() => import('/@/components/TableColumn/Provider.vue'));

View File

@@ -367,7 +367,7 @@
<el-tag disabled>{{waitShenheForm.form.deptName}}</el-tag>
</el-form-item>
<el-form-item label="现二级部门*">
<el-form-item label="现二级部门" prop="newDeptCode">
<el-select v-model="newSecDeptCode" @change="getDeptListByParent" placeholder="请选择二级部门" style="width: 100%">
<el-option v-for="item in secDeptList"
:key="item.deptCode"
@@ -392,9 +392,8 @@
v-model="waitShenheForm.form.changeDate"
type="date"
placeholder="选择日期"
format="yyyy-MM-dd"
value-format="yyyy-MM-dd HH:mm:ss"
style="width: 100%"
format="YYYY-MM-DD"
value-format="YYYY-MM-DD"
/>
</el-form-item>
@@ -461,9 +460,8 @@
v-model="waitShenheForm.form.changeTime"
type="date"
placeholder="选择日期"
format="yyyy-MM-dd"
value-format="yyyy-MM-dd HH:mm:ss"
style="width: 100%"
format="YYYY-MM-DD"
value-format="YYYY-MM-DD HH:mm:ss"
/>
</el-form-item>
@@ -490,7 +488,9 @@
import { getTeacherCertificateList } from '/@/api/professional/rsbase/professionalteachercertificateconf'
import { getAllTypeList } from '/@/api/professional/rsbase/professionalacademiceducationtypeconfig'
import { getQualificationList } from '/@/api/professional/rsbase/academicqualificationsconfig'
import { getDegreeList } from '/@/api/professional/rsbase/professionalacademicdegreeconfig'
import { getDegreeList } from '/@/api/professional/rsbase/professionalacademicdegreeconfig'
import { addObj as addStationChangeObj } from '/@/api/professional/professionaluser/professionalteacherstationchange'
import { addObj as addPartyChangeObj } from '/@/api/professional/professionaluser/professionalpartychange'
import global from '/@/components/tools/commondict.vue'
import { Session } from '/@/utils/storage'
@@ -556,7 +556,8 @@
}
const stationChangeRules = {
changeDate: [{ required: true, message: '请选择日期', trigger: 'change' }],
newDeptCode: [{ required: true, message: '请选择要调入的二级部门', trigger: 'change' }],
changeDate: [{ required: true, message: '请选择调令日期', trigger: 'change' }],
pos: [{ required: true, message: '请选择岗位类型', trigger: 'change' }]
}
@@ -870,7 +871,17 @@
try {
await messageBox.confirm('确认提交?')
const res = await updateOtherInfo(waitShenheForm.form)
let res
if (val === 5) {
// 人员调动:使用人员调动接口
res = await addStationChangeObj(waitShenheForm.form)
} else if (val === 6) {
// 党员调动:使用党员调动接口
res = await addPartyChangeObj(waitShenheForm.form)
} else {
// 其他类型:走通用“其他信息”更新接口
res = await updateOtherInfo(waitShenheForm.form)
}
if (res.data === '-1') {
message.warning("当前不允许提交")
} else {