import { IntfPlatform } from '@imedx/ics-imedx-chromely-plugin-intf-platform' import constants from './constants' import { showTestDialog } from './components/test-dialog' export default class IcsImedxXXXXXJsSdk { /** * 功能接口1 * @param visitId 就诊编码 * @param deptId 科室编码 * @param typeId 类型编码 */ public async Func1(visitId: string, deptId: string, typeId: string): Promise { const data = [ { id: 1, code: '001', name: '类型1', type: 'T1' }, { id: 2, code: '002', name: '类型2', type: 'T2' } ] // 弹出对话框选择类型 const result = await showTestDialog(data) return IntfPlatform.bussiness(constants.INTERFACE_CORE, constants.FUNC1, { visitId, deptId, typeId, result }) } /** * 功能接口2 * @param visitId 就诊编码 * @param deptId 科室编码 * @param doctorId 医生编码 */ public Func2(visitId: string, deptId: string, doctorId: string): Promise { return IntfPlatform.bussiness(constants.INTERFACE_CORE, constants.FUNC1, { visitId, deptId }) } /* . . . */ /** * 功能接口N * @param visitId 就诊编码 * @param deptId 科室编码 * @param doctorId 医生编码 */ public FuncN(visitId: string, deptId: string, doctorId: string): Promise { return IntfPlatform.bussiness(constants.INTERFACE_CORE, constants.FUNC1, { visitId, deptId }) } }