import { BasicFetchResult } from '../typing'; import { MenuTypeEnum } from './index'; namespace DictionaryService { export type DatadictsFields = | 'currencyType' | 'templateType' | 'newTalkChannelType' | 'NewProPoType' | 'nation' | 'useTranslationType' | 'newProcessType' | 'platformType' | 'hrIsPass' | 'crmClientType' | 'clientContractType' | 'orgType' | 'mailDealType' | 'clientPhaseType' | 'SaleStage' | 'leaveType' | 'osmOrderAttTypeQuery' | 'valueType' | 'crmFinancialMailType' | 'osmOrderAttTypeAdd' | 'hrSpokenEnglish' | 'hrGenderType' | 'deliveryWaitType' | 'genderType' | 'omsOrderStatus' | 'bfFreeType' | 'contCustType' | 'contractRenewalType' | 'newRivalLevelType' | 'accountType' | 'crmContactType' | 'degree' | 'financialMailType' | 'crmAcceptanceType' | 'talkChannelType' | 'hireState' | 'empVirtualType' | 'newPurchaseMoType' | 'hrLeaveType' | 'proPoType' | 'rivalLevelType' | 'crmProcessType' | 'leaveContractType' | 'leaveTypeEntCulture' | 'menuType' | 'purchaseMoType' | 'hrEmpEffeStationType' | 'clientStatusType' | 'productLineType' | 'hrRole' | 'remindNext' | 'timezone' | 'crmClientContactType' | 'hrHolidayType' | 'crmClientFrozen' | 'roleType' | 'pcHardDiscDealType' | 'empHireState' | 'strategyType' | 'resourceDifficulty' | 'crmClientStatusType' | 'leaveTypeManage' | 'sourceLevelType' | 'adminSpItemType' | 'crmPayMethodType' | 'crmClientTier' | 'aboutReviewType' | 'empCostDept' | 'crmClientOperateType' | 'catToolType' | 'contVerifyCycleType' | 'crmCustomerType' | 'talkModeType' | 'empKpiPayMethod' | 'leaveTypeCareerPlan' | 'rivalType' | 'marital' | 'leaveTypeSalary' | 'attachTypeOptions' | 'crmClientFashionType' | 'businessDirection' | 'clientOperateType' | 'transdoc_upload_file_suffix' | 'supportLang' | 'crmClientTouchType' | 'htQzsx' | 'hrIm'; export type LangType = 'en_Us' | 'zh_CN'; export type DataDicts = { [K in DatadictsFields]?: { code: string; name: string; }; }; /** * @description 获取数据字典数据接口响应结果 */ export type GetDatadictsResult = { [K in LangType]: DataDicts; }; /** * @description 字典表-语言 */ export interface LanguageCountry { /** * 国家ID */ countryId?: number; /** * 删除标志:0-未删除;1-已删除 */ deleted?: boolean; /** * 英文名称 */ enName?: string; /** * 商业分类id */ id?: number; /** * 公共源语种 */ isCommonSLang?: boolean; /** * 公共目标语种 */ isCommonTLang?: boolean; /** * 语种ID */ languageId?: number; /** * 在线支持源语种 */ onlineSupportSLang?: boolean; /** * 在线支持目标语种 */ onlineSupportTLang?: boolean; /** * 简写 */ shortName?: string; /** * Transdoc简写 */ shortNameTransDoc?: string; /** * 中文名称 */ zhName?: string; } /** * @description 获取语种和国家字典接口响应结果 */ export type GetLanguageCountryListResult = BasicFetchResult; /** * @description 通用数据字典类的表数据查询请求参数 */ export interface DictTableSearchParams { /** * 需要中文结果?否-即英文结果[默认:false] */ chineseResult?: boolean; /** * 是否包含失效的数据[默认:false] */ containDisabled?: boolean; /** * 额外的字段名 */ extColumns?: string[]; /** * platform库里的数据库表名 */ tableName?: string; } /** * @description 通用数据字典类的表数据查询接口响应结果 */ export interface DictTableSearchResult { id: number; name: string; [key: string]: string | number; } /** * @description 菜单类型 */ export interface MenuItem { authority: null; checked: null; /** * 是否可用 */ enabled: boolean; /** * 图标 */ icon: string; /** * 菜单id */ id: string; /** * 超管是否可见 */ isAdminVisible: boolean; /** * 路由名称(route name) */ name: string; /** * 菜单名称json eg:[{\"lang\": \"en_US\", \"text\": \"Admin\"},{\"lang\": \"zh_CN\", \"text\": \"平台配置\"}] */ nameJson: string; /** * 父级菜单id */ pid: string; /** * 备注 */ remarks: string; reserve1: null; reserve2: null; /** * 排序号 */ sortNo: number; /** * 所属子系统id */ subsysId: string; /** * 菜单类型 */ type: MenuTypeEnum; /** * 组件路径 */ url: string; } /** * @description 获取当前人在指定应用系统里的菜单权限列表接口响应结果 */ export type GetSystemMenuResult = { [K in LangType]: MenuItem[]; }; /** * @description 公司接口类型 */ export interface CompanyItem { /** * 归属品牌ID */ brandId?: number; /** * 币种 */ currency?: number; /** * 状态位 */ enabled?: boolean; /** * 公司地址(英文) */ englishAddress?: string; /** * 公司名称(英文) */ englishName?: string; /** * 主键ID */ id?: number; /** * 是否是成本中心 */ isCostCenter?: boolean; /** * 是否在中国境内 */ isInChina?: boolean; /** * 是否在中国大陆 */ isInMainland?: boolean; /** * 是否是生产中心 */ isProdCenter?: boolean; /** * 是否是销售中心 */ isSalesCenter?: boolean; /** * 是否支持云账户支付 */ isSupportCloudpay?: boolean; /** * 公司法人ID */ legalEmp?: string; /** * 所在地(国家或者地区) */ nation?: number; /** * 公司地址(当地语言) */ nativeAddress?: string; /** * 公司名称(当地语言) */ nativeName?: string; /** * 公司拼音缩写 */ shortName?: string; /** * 顺序号 */ sortNo?: number; /** * 税率 */ taxRate?: number; /** * 时区 */ timezone?: string; } /** * @description 获取所有公司下拉列表数据接口响应结果 */ export type GetAllOrganOptionsResult = BasicFetchResult; /** * @description 根据条件筛选出能看到的公司列表接口参数 */ export interface SearchOrganOptionsParams { /** * 职工ID(数字型) */ earlyId?: number; /** * 职工ID(字符型) */ empId?: string; /** * 职位定义IDS */ postDefIds?: number[]; /** * 角色IDS */ roleIds?: number[]; } } export type { DictionaryService };