/** * API 类型定义 */ declare namespace Api { namespace Auth { interface UserInfo { userId?: string id?: string username: string realName?: string phone?: string email?: string sex?: string remark?: string role: string roleNames?: string[] regionId?: string regionName?: string roles?: string[] /** 自定义头像 URL,空则前端使用 `/avatart.png` */ avatarUrl?: string | null } interface LoginParams { username: string password: string } interface LoginResponse { token: string refreshToken: string expiresIn: number userInfo: UserInfo } } namespace User { interface UserItem { id: string deptId: string supervisorUserId?: string userNo: string nickName: string email: string phoneNo: string hireDate?: string probationMonths?: number | null lastWorkDay?: string sex: string avatar: string status: string tenantNo: string orderNum: number remark: string createTime: string updateTime: string deptName?: string roleIds?: string[] postIds?: string[] /** 经启用职位继承的启用角色 ID */ postInheritedRoleIds?: string[] /** 有效角色 ID(启用直接绑定 ∪ 职位继承) */ effectiveRoleIds?: string[] /** 有效角色名称 */ effectiveRoleNames?: string[] } } namespace Region { interface RegionItem { id: string name: string code: string description?: string sortOrder: number isActive: boolean createAt: string } interface RegionDetail extends RegionItem { updateAt: string updateBy: string } } namespace Category { interface CategoryItem { id: string name: string imageUrl?: string parentId?: string parentName?: string sortOrder: number isActive: boolean createAt: string } } namespace Unit { interface UnitItem { id: string name: string code: string isActive: boolean createAt: string } } namespace Tenant { interface TenantItem { id: string tenantNo: string tenantName: string contactName: string contactPhone: string orderNum: number remark: string createTime: string updateTime: string } } namespace Product { interface ProductItem { id: string name: string categoryId?: string categoryName?: string unitId?: string unitName?: string description?: string imageUrl?: string isActive: boolean createAt: string } interface ProductDetail extends ProductItem { updateAt: string updateBy: string } // 商品轮播图 interface ProductBanner { id: string productId: string mediaType: string fileUrl: string thumbnailUrl?: string sortOrder: number createAt: string } interface ProductBannerCreate { mediaType?: string fileUrl: string thumbnailUrl?: string sortOrder?: number } interface ProductBannerUpdate { mediaType?: string fileUrl?: string thumbnailUrl?: string sortOrder?: number } // 商品详情媒体 interface ProductDetailMedia { id: string productId: string contentType: string contentText?: string fileUrl?: string thumbnailUrl?: string description?: string sortOrder: number createAt: string } interface ProductDetailMediaCreate { contentType?: string contentText?: string fileUrl?: string thumbnailUrl?: string description?: string sortOrder?: number } interface ProductDetailMediaUpdate { contentType?: string contentText?: string fileUrl?: string thumbnailUrl?: string description?: string sortOrder?: number } // 商品参数模板 interface ProductParameter { id: string name: string code: string paramType: string options?: string placeholder?: string isRequired: number isActive: number sortOrder: number remark?: string createAt: string } interface ProductParameterSimple { id: string name: string code: string paramType: string options?: string } interface ProductParameterCreate { name: string code: string paramType?: string options?: string placeholder?: string isRequired?: number isActive?: number sortOrder?: number remark?: string } interface ProductParameterUpdate { name?: string code?: string paramType?: string options?: string placeholder?: string isRequired?: number isActive?: number sortOrder?: number remark?: string } // 分类参数关联 interface CategoryParameter { id: string categoryId: string parameterId: string parameterName: string parameterCode: string paramType: string options?: string placeholder?: string isRequired: number defaultValue?: string sortOrder: number } interface CategoryParameterCreate { categoryId: string parameterId: string isRequired?: number defaultValue?: string sortOrder?: number } // 商品参数值 interface ProductParameterValue { id: string productId: string parameterId: string parameterName?: string parameterCode?: string paramType?: string options?: string placeholder?: string paramValue?: string sortOrder: number } interface ProductParameterValueCreate { productId: string parameterId: string paramValue?: string } // 售后评价 interface ProductReview { id: string productId: string orderId?: string orderItemId?: string userId: string userName?: string rating: number ratingTags?: string content?: string isAnonymous: number replyContent?: string replyTime?: string replyBy?: string replyByName?: string likeCount: number isTop: number status: string rejectReason?: string createAt: string mediaList?: ProductReviewMedia[] } interface ProductReviewMedia { id: string reviewId: string mediaType: string fileUrl: string thumbnailUrl?: string sortOrder: number } interface ProductReviewStatistics { totalCount: number pendingCount: number approvedCount: number rejectedCount: number avgRating: number ratingDistribution: Record } } namespace Order { interface OrderItem { id: string orderNo: string clientId: string clientName: string regionId: string regionName: string priceListId: string totalAmount: string paidAmount: string receivableAmount: string refundAmount: string status: string paymentMethod?: string contactPerson?: string contactPhone?: string deliveryAddress?: string createAt: string } interface OrderDetail extends OrderItem { items: OrderItemDetail[] cancelReason?: string cancelReviewTime?: string completedTime?: string remark?: string } interface OrderItemDetail { id: string productId: string productName: string unitId: string unitName: string quantity: string unitPrice: string amount: string deliveredQuantity: string status: string } } namespace Delivery { interface DeliveryTask { id: string taskNo: string orderId: string orderNo: string regionId: string regionName: string deliverId?: string deliverName?: string status: string pickupTime?: string deliveryTime?: string createAt: string } interface DeliveryTaskDetail extends DeliveryTask { items: DeliveryTaskItem[] } interface DeliveryTaskItem { id: string productName: string quantity: string deliveredQuantity: string status: string } } namespace Dept { interface DeptItem { id: string parentId: string deptName: string deptCategoryCode: string status: string leaderUserId?: string leader: string leaderPhone: string tenantNo: string orderNum: number remark: string createTime: string updateTime: string children?: DeptItem[] } } namespace Dict { interface DictTypeItem { id: string dictName: string dictType: string tenantNo: string orderNum: number remark: string createTime: string updateTime: string } interface DictDataItem { id: string dictLabel: string dictValue: string dictType: string tenantNo: string orderNum: number remark: string createTime: string updateTime: string } interface DictDataOption { label: string value: string } } namespace Site { interface SiteItem { id: string siteName: string siteCode: string siteType: string status: string address: string contactName: string contactPhone: string businessScope: string siteImage: string tenantNo: string orderNum: number remark: string createTime: string updateTime: string } } namespace Post { interface PostItem { id: string postName: string postCode: string status: string tenantNo: string orderNum: number remark: string boundUserNames?: string[] createTime: string updateTime: string } } namespace ItemUnit { interface ItemUnitItem { id: string unitCode: string unitName: string tenantNo: string orderNum: number remark: string createTime: string updateTime: string } } namespace BizCustomer { interface CustomerItem { id: string customerName: string sex: string idCardNo: string age: number | null phoneNo: string customerTags: string tenantNo: string orderNum: number remark: string createTime: string updateTime: string } type PartyRole = 'mother' | 'father' | 'newborn' type RelationBizType = 'cell_storage' | 'research_donation' interface RelationMember { role: PartyRole customerId: string name: string phone: string idCardNo: string } interface RelationGroup { bizType: RelationBizType protocolId: string protocolNo: string protocolStatus: string registerDate: string myRole: PartyRole members: RelationMember[] } interface ProtocolSummary { bizType: RelationBizType protocolId: string protocolNo: string protocolStatus: string registerDate: string myRole: PartyRole } interface CustomerRelations { customer: CustomerItem relatedGroups: RelationGroup[] protocols: ProtocolSummary[] } } namespace BizCellSampleType { interface CellSampleTypeItem { id: string typeCode: string typeName: string typeLogo: string storageYears: number | null storagePrice: number | null /** 样本编码过滤文本,空则协议单选编码时不过滤 */ sampleCodeFilter: string tenantNo: string orderNum: number remark: string createTime: string updateTime: string } } namespace BizCollectionRegion { interface RegionItem { id: string regionName: string hospitalNames: string[] staffNames?: string[] leaderNames?: string[] tenantNo: string orderNum: number remark: string createTime: string updateTime: string } } namespace BizCollectionHospital { interface HospitalItem { id: string regionId: string hospitalName: string regionName?: string tenantNo: string orderNum: number remark: string createTime: string updateTime: string } } namespace BizCollectionRegionStaff { interface StaffItem { id: string regionId: string userId: string userName: string nickName: string userNo: string deptName: string isLeader: boolean tenantNo: string orderNum: number remark: string createTime: string updateTime: string } } namespace BizCollectionProtocolNo { interface ProtocolNoItem { id: string protocolNo: string issued: number /** 是否已在采集协议单或科研捐赠单中占用(与号池「是否下发」无关) */ usedInProtocol?: boolean issuedUserId: string issuedUserName: string issuedTime: string tenantNo: string orderNum: number remark: string createTime: string updateTime: string } } namespace BizSampleCode { interface SampleCodeItem { id: string sampleCode: string sampleCodeType: string issued: number labStorageCode?: string /** 是否已在采集协议单或科研捐赠单样本表中占用(与号池「是否下发」无关) */ usedInProtocol?: boolean issuedUserId: string issuedUserName: string issuedTime: string tenantNo: string orderNum: number remark: string createTime: string updateTime: string } } namespace Menu { interface MenuItem { id: string menuName: string parentId: string menuType: string path: string component: string perms: string isFrame: number visible: string status: string tenantNo: string orderNum: number remark: string createTime: string updateTime: string children?: MenuItem[] } } namespace ExpressCompany { interface ExpressCompanyItem { id: string expressCode: string expressName: string expressLogo: string tenantNo: string orderNum: number remark: string createTime: string updateTime: string } } namespace Role { interface RoleItem { id: string roleName: string dataScope: string status: string tenantNo: string orderNum: number remark: string boundUserNames?: string[] boundPostNames?: string[] createTime: string updateTime: string } } namespace Leave { interface LeaveItem { id: string leaveType: string leaveTypeLabel?: string startDate: string endDate: string days: number reason: string wfInstanceId: string status: string tenantNo?: string orderNum?: number remark?: string createBy?: string createTime?: string updateBy?: string updateTime?: string } } namespace Workflow { interface ProcessDefItem { id: string processCode: string processName: string status: string latestVersion: number | null tenantNo: string orderNum: number remark: string createTime: string updateTime: string } interface VersionItem { id: string versionNo: number isLatest: string remark: string createTime: string updateTime: string } interface NodeData { nodeKey: string nodeType: string nodeName: string | null configJson: string | null } interface TransitionData { fromNodeKey: string toNodeKey: string conditionExpr: string | null } interface DesignerData { graphJson: string | null versionNo: number nodes: NodeData[] transitions: TransitionData[] } interface TaskItem { id: string instanceId: string nodeKey: string | null assigneeUserId: string | null status: string | null commentText: string | null createTime: string updateTime: string processName: string | null businessType: string | null businessId: string | null starterUserId: string | null instanceStatus: string | null instanceCreateTime: string | null } interface MyInstanceItem { id: string processName: string | null businessType: string | null businessId: string | null starterUserId: string | null status: string createTime: string updateTime: string businessTypeLabel?: string starterUserName?: string } interface TaskDetail { id: string nodeKey: string | null nodeName?: string | null assigneeUserId: string | null assigneeUserName?: string | null status: string | null commentText: string | null createTime: string updateTime: string } interface InstanceDetail { id: string processVersionId: string businessType: string | null businessId: string | null starterUserId: string | null status: string | null variables: string createTime: string tasks: TaskDetail[] } interface BusinessAllTasks { businessType: string businessId: string businessFormFields: Array<{ label: string; value: string }> tasks: Array<{ id: string instanceId: string instanceStatus: string nodeKey: string | null nodeName: string assigneeUserId: string | null assigneeUserName: string status: string | null commentText: string | null createTime: string updateTime: string }> } } namespace CellProductType { interface CellProductTypeItem { id: string productTypeCode: string productTypeName: string tenantNo: string orderNum: number remark: string createTime: string updateTime: string } } namespace CellProductSpec { interface CellProductSpecItem { id: string specCode: string specName: string tenantNo: string orderNum: number remark: string createTime: string updateTime: string } } } declare module '*.vue' { import type { DefineComponent } from 'vue' const component: DefineComponent<{}, {}, any> export default component }