对前几个更新的优化
This commit is contained in:
parent
72861a649a
commit
fa90439fb0
@ -64,20 +64,24 @@
|
||||
<el-option v-for="item in postOptions" :key="item.id" :label="item.name" :value="item.id" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item
|
||||
v-if="userTaskForm.candidateStrategy == 30"
|
||||
label="用户部门"
|
||||
prop="candidateParam"
|
||||
span="24"
|
||||
>
|
||||
<DeptTree @node-click="handleDeptNodeClick" />
|
||||
</el-form-item>
|
||||
<!-- <el-form-item-->
|
||||
<!-- v-if="userTaskForm.candidateStrategy == 30"-->
|
||||
<!-- label="用户部门"-->
|
||||
<!-- prop="candidateParam"-->
|
||||
<!-- span="24"-->
|
||||
<!-- >-->
|
||||
<!-- <el-input v-model="input" placeholder="选择部门" @click="drawer = true"/>-->
|
||||
<!-- </el-form-item>-->
|
||||
<el-form-item
|
||||
v-if="userTaskForm.candidateStrategy == 30"
|
||||
label="指定用户"
|
||||
prop="candidateParam"
|
||||
span="24"
|
||||
>
|
||||
<el-button
|
||||
@click="drawer = true"
|
||||
style="margin-bottom: 10px; height: auto; width: auto"
|
||||
>选择用户部门</el-button>
|
||||
<el-select
|
||||
v-model="userTaskForm.candidateParam"
|
||||
clearable
|
||||
@ -132,6 +136,24 @@
|
||||
<ProcessExpressionDialog ref="processExpressionDialogRef" @select="selectProcessExpression" />
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
|
||||
<el-drawer v-model="drawer" :direction="direction">
|
||||
<template #header>
|
||||
<h2>部门选择</h2>
|
||||
</template>
|
||||
<template #default>
|
||||
<el-divider border-style="dashed" />
|
||||
<div>
|
||||
<DeptTree @node-click="handleDeptNodeClick" />
|
||||
</div>
|
||||
</template>
|
||||
<template #footer>
|
||||
<div style="flex: auto">
|
||||
<el-button type="primary" @click="cancelClick">确定</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</el-drawer>
|
||||
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
@ -144,6 +166,14 @@ import * as UserApi from '@/api/system/user'
|
||||
import * as UserGroupApi from '@/api/bpm/userGroup'
|
||||
import ProcessExpressionDialog from './ProcessExpressionDialog.vue'
|
||||
import DeptTree from '@/components/bpmnProcessDesigner/package/penal/task/task-components/DeptTree_Task.vue'
|
||||
// import { ElMessageBox } from 'element-plus'
|
||||
import type { DrawerProps } from 'element-plus'
|
||||
|
||||
const drawer = ref(false)
|
||||
const direction = ref<DrawerProps['direction']>('rtl')
|
||||
function cancelClick() {
|
||||
drawer.value = false
|
||||
}
|
||||
|
||||
defineOptions({ name: 'UserTask' })
|
||||
const props = defineProps({
|
||||
@ -179,7 +209,6 @@ const getList = async () => {
|
||||
try {
|
||||
const data = await UserApi.getUserPage(queryParams)
|
||||
userOptions.value = data.list
|
||||
// console.log('userOptions.value',userOptions.value)
|
||||
} finally {
|
||||
}
|
||||
}
|
||||
|
@ -14,7 +14,10 @@
|
||||
<el-input v-model="formData.description" placeholder="请输入描述" type="textarea" />
|
||||
</el-form-item>
|
||||
<el-form-item label="部门">
|
||||
<el-input v-model="input" placeholder="选择部门" @click="drawer = true"/>
|
||||
<el-button
|
||||
@click="drawer = true"
|
||||
style="margin-bottom: 10px; height: auto; width: auto"
|
||||
>选择用户部门</el-button>
|
||||
</el-form-item>
|
||||
<el-form-item label="成员" prop="userIds">
|
||||
<el-select v-model="formData.userIds" multiple placeholder="请选择成员">
|
||||
@ -56,8 +59,7 @@
|
||||
</template>
|
||||
<template #footer>
|
||||
<div style="flex: auto">
|
||||
<el-button @click="cancelClick">取消</el-button>
|
||||
<el-button type="primary" @click="confirmClick">确认</el-button>
|
||||
<el-button type="primary" @click="cancelClick">确定</el-button>
|
||||
</div>
|
||||
</template>
|
||||
</el-drawer>
|
||||
@ -70,7 +72,7 @@ import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
|
||||
import { CommonStatusEnum } from '@/utils/constants'
|
||||
import * as UserGroupApi from '@/api/bpm/userGroup'
|
||||
import * as UserApi from '@/api/system/user'
|
||||
import { ElMessageBox } from 'element-plus'
|
||||
// import { ElMessageBox } from 'element-plus'
|
||||
import type { DrawerProps } from 'element-plus'
|
||||
|
||||
defineOptions({ name: 'UserGroupForm' })
|
||||
@ -78,21 +80,11 @@ defineOptions({ name: 'UserGroupForm' })
|
||||
const { t } = useI18n() // 国际化
|
||||
const message = useMessage() // 消息弹窗
|
||||
|
||||
const input = ref('')
|
||||
const drawer = ref(false)
|
||||
const direction = ref<DrawerProps['direction']>('rtl')
|
||||
function cancelClick() {
|
||||
drawer.value = false
|
||||
}
|
||||
function confirmClick() {
|
||||
ElMessageBox.confirm(`点击确定?`)
|
||||
.then(() => {
|
||||
drawer.value = false
|
||||
})
|
||||
.catch(() => {
|
||||
// catch error
|
||||
})
|
||||
}
|
||||
|
||||
const dialogVisible = ref(false) // 弹窗的是否展示
|
||||
const dialogTitle = ref('') // 弹窗的标题
|
||||
@ -128,11 +120,8 @@ const queryParams = reactive({
|
||||
/** 查询列表 */
|
||||
const getList = async () => {
|
||||
try {
|
||||
input.value = ''
|
||||
const data = await UserApi.getUserPage(queryParams)
|
||||
userList.value = data.list
|
||||
input.value = data.list[0].deptName
|
||||
// console.log('userList',userList.value)
|
||||
} finally {
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user