export interface ListNearExpireItemsParams {
	clientCode: string; // 客户编号
	isContainsStuff: 0 | 1; // 是否包含耗材 , 默认0
	itemTypeCode: string; // 库存分类类型编号
	itemName: string; // 物品名称(可模糊查询)
	page: number;
	size: number;
}

export interface ItemType {
	clientCode: string;
	code: string;
	createTime: string;
	createUser: any;
	deletedTime: any;
	id: number;
	isDeleted: number;
	isEditable: number;
	isShow: boolean;
	remark: string;
	sortOrder: number;
	typeName: string;
	updateTime: string;
	updateUser: any;
}

export interface ListNearExpireItemsItem {
	itemCode: string;
	供货商: string;
	医保编码: string;
	厂家: string;
	批号: string;
	有效日期: string;
	有效期: number;
	药品名称: string;
	药品编号: string;
	规格: string;
	进货价: string;
	零售价: string;
}

export interface ListNearExpireItemsReponse {
	list: ListNearExpireItemsItem[];
	total: number;
	[key: string]: any;
}

export interface ListInandOutDetailsParams {
	clientCode: string;
	itemName: string;
	itemTypeCodes: string;
	date1: string;
	date2: string;
	page: number;
	size: number;
}

export interface InandOutDetailsItem {
	本期购入金额: number;
	剂型: string;
	名称: string;
	规格: string;
	上期结存量: number;
	上期结存金额: number;
	本期销售退库金额: number;
	单位: string;
	本期结存金额: number;
	本期销售量: number;
	本期购入量: number;
	本期销售金额: number;
	医保编码: string;
	本期销售退库量: number;
	批准文号: string;
	本期结存量: number;
}

export interface ListInandOutDetailsReponse {
	list: InandOutDetailsItem[];
	total: number;
}

export interface InventoryMonitoringItem {
	itemCode: string;
	医保编码: string;
	单位: string;
	可用库存: string;
	药品名称: string;
	药品编号: string;
	规格: string;
}


export interface ListReadyRowsParams {
	clientCode: string;
	isContainsOutStockInfos: number;
	queryDateBegin: string;
	queryDateEnd: string;
	timeSlot: number;
	wards: string[];
}

export interface ListOutStockGroupByPatOrItemParams {
	groupby: string;
	clientCode: string;
	date1: string;
	date2: string;
}

// 0入库 1入库退库 2出库 3出库退库
type OperateType = 0 | 1 | 2 | 3;
export interface ListOperate2DetailsParams {
	itemCode: string;
	date1: string;
	date2: string;
	operateType: OperateType;
	page: number;
	size: number;
	patientCode: string;
	timeSlot: string;
}


export interface GetDiffDetailsParams {
	page: number;
	size: number;
	date1: string;
	date2: string;
	itemCode: string; // 物品编号
}


export interface DiffDetails {
	盘点时间: string;
	盘盈数量: number | null;
	盘亏数量: number | null;
	操作人: string;
	备注: string;
}

export interface IInventoryCheckQueryParams {
	page: number;
	size: number;
	types: string;
	itemName: string;
	startTime: string;
	endTime: string;
	clientCode: string;
}

// 1：厂家；2是经销商
export type IInventoryItemUpdateManufacturerDealerDictParamsManufacturerDealerType = 1 | 2;

export interface IInventoryItemUpdateManufacturerDealerDictParams {
	clientCode: string;
	manufacturerDealerName: string;
	manufacturerDealerType: IInventoryItemUpdateManufacturerDealerDictParamsManufacturerDealerType;
}


export interface ICopyFromParams {
	fromClientCode: string;
	toClientCode: string;
	typeCode: string;
	isOverride: number;
}


export interface IInventoryListByTypesParams {
	clientCode: string;
	itemTypes: string;
	itemName?: string;
	isShow?: number; // -1 | 0 | 1
	page?: number;
	size?: number;
}