liu
2026-10-27 62f4cc1d7bc19fd3bb7b9eb7477c15266e580ffd
src/views/bpm/components/bpmn-process-designer/package/penal/task/task-components/UserTask.vue
@@ -73,6 +73,18 @@
// @ts-expect-error: tree ref instance type is provided by the UI library at runtime
const treeRef = ref<any>();
/**
 * 用户下拉的搜索过滤:按昵称模糊匹配(忽略大小写)。
 */
function filterUserOption(input: string, option: any) {
  const keyword = (input || '').trim().toLowerCase();
  if (!keyword) {
    return true;
  }
  const label = String(option?.label ?? option?.nickname ?? '');
  return label.toLowerCase().includes(keyword);
}
const { formFieldOptions } = useFormFieldsPermission(FieldPermissionType.READ);
// 定义 TreeSelect 的默认属性映射
@@ -438,12 +450,17 @@
        v-model:value="userTaskForm.candidateParam"
        allow-clear
        mode="multiple"
        show-search
        option-filter-prop="label"
        :filter-option="filterUserOption"
        placeholder="请输入用户名称搜索"
        style="width: 100%"
        @change="updateElementTask"
      >
        <SelectOption
          v-for="item in userOptions"
          :key="item.id"
          :label="item.nickname"
          :value="item.id"
        >
          {{ item.nickname }}