zhizhi/node_modules/dingtalk-jsapi/api/biz/contact/complexPicker.d.ts

90 lines
3.2 KiB
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import { ICommonAPIParams } from '../../../constant/types';
/**
* 选人与部门 请求参数定义
* @apiName biz.contact.complexPicker
*/
export interface IBizContactComplexPickerParams extends ICommonAPIParams {
/** 标题 */
title?: string;
/** 企业的corpId */
corpId?: string;
/** 是否多选 */
multiple?: boolean;
/** 超过限定人数返回提示 */
limitTips?: string;
/** 选人组件,用户未选择人的时候,左下角的提示文案 */
pickTips?: string;
/** 最大可选人数 */
maxUsers?: number;
/** 已选用户 */
pickedUsers?: string[];
/** 已选部门 */
pickedDepartments?: string[];
/** 不可选用户 */
disabledUsers?: string[];
/** 不可选部门 */
disabledDepartments?: string[];
/** 必选用户(不可取消选中状态) */
requiredUsers?: string[];
/** 必选部门(不可取消选中状态) */
requiredDepartments?: string[];
/** 微应用的Id */
appId?: number;
/** 选人权限目前只有GLOBAL这个参数 */
permissionType?: string;
/** 返回人,或者返回人和部门 */
responseUserOnly?: boolean;
/** 0表示从企业最上层开始 */
startWithDepartmentId?: number;
/** 上游业务来源 */
origin?: number;
/** 上游业务来源描述 */
originMeta?: string;
/** 只支持移动端,可以直接跳到具体部门。-1 表示根部门0 表示当前部门startWithDepartmentId需要传2depId才生效 */
deptId?: number;
/** 初始页面是组织架构或组织列表页 */
rootPage?: string;
/** 组织列表上是否展示按角色选择 */
showLabelPick?: boolean;
/** 组织列表上是否展示组织关联的上下游组织入口 */
showOrgEcological?: boolean;
/** 显示指定企业的上下游组织列表 */
filterOrgEcological?: boolean;
}
/**
* 选人与部门 返回结果定义
* @apiName biz.contact.complexPicker
*/
export interface IBizContactComplexPickerResult {
/** 选择人数 */
selectedCount: number;
/** 返回选人的列表列表中的对象包含name用户名avatar用户头像emplId用户工号三个字段 */
users?: Array<{
name: string;
avatar: string;
/** 用户工号 */
emplId: string;
/** 员工部门 id */
selectDeptId?: number;
/** 员工部门名称 */
selectDeptName?: string;
/** 用户所在企业 */
corpId?: string;
}>;
/** 返回已选部门列表列表中每个对象包含id部门id、name部门名称、number部门人数 */
departments?: Array<{
id: string;
name: string;
number: string;
}>;
}
/**
* 选人与部门
* 支持选择部门后把所选部门转换成对应部门下的人permissionType可以添加权限校验
* @apiName biz.contact.complexPicker
* @supportVersion ios: 2.9.0 android: 2.9.0 pc: 4.3.5
* @author iOS晓毒; Android几米;
*/
export declare function complexPicker$(params: IBizContactComplexPickerParams): Promise<IBizContactComplexPickerResult>;
export default complexPicker$;