提交“
This commit is contained in:
1 parent
69ee0f505c
commit
9b88581450
614 files changed
+90318
-689022
No files matched your search
+24
-1738
File diff suppressed because it is too large.
Load diff
@@ -1,238 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
/**
|
||||
* 订单与订单页依赖的少量接口(其余业务 API 已移除,需要时再加回)。
|
||||
*/
|
||||
|
||||
export function fetchOrderList(params: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
status?: string
|
||||
orderStatus?: string
|
||||
deliveryStatus?: string
|
||||
payStatus?: string
|
||||
paymentMethod?: string
|
||||
regionId?: string
|
||||
clientId?: string
|
||||
startDate?: string
|
||||
endDate?: string
|
||||
}) {
|
||||
return request.get<{
|
||||
list: Api.Order.OrderItem[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}>({
|
||||
url: '/web/admin/orders',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchOrderDetail(id: string) {
|
||||
return request.get<Api.Order.OrderDetail>({
|
||||
url: `/web/admin/orders/${id}`
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchAssignDelivery(data: {
|
||||
orderId: string
|
||||
deliverId: string
|
||||
deliveryDeadlineAt: string
|
||||
dispatchRemark?: string
|
||||
}) {
|
||||
return request.post({
|
||||
url: `/web/admin/orders/${data.orderId}/assign-deliverer`,
|
||||
params: {
|
||||
deliverId: data.deliverId,
|
||||
deliveryDeadlineAt: data.deliveryDeadlineAt,
|
||||
dispatchRemark: data.dispatchRemark || ''
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchReviewCancel(data: { orderId: string; approved: boolean; note?: string }) {
|
||||
return request.post({
|
||||
url: `/web/admin/orders/${data.orderId}/review-cancel`,
|
||||
params: { approved: data.approved, note: data.note }
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchCancelOrder(data: {
|
||||
orderId: string
|
||||
reason: string
|
||||
note?: string
|
||||
evidenceImageUrls?: string[]
|
||||
}) {
|
||||
return request.post({
|
||||
url: `/web/admin/orders/${data.orderId}/cancel`,
|
||||
params: {
|
||||
reason: data.reason,
|
||||
note: data.note,
|
||||
evidenceImageUrls: data.evidenceImageUrls || []
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchOrderAdjusts(orderId: string) {
|
||||
return request.get({
|
||||
url: `/web/admin/orders/${orderId}/adjusts`
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchAdjustOrder(data: {
|
||||
orderId: string
|
||||
adjustments?: Array<{
|
||||
orderItemId: string
|
||||
adjustType: 'reduce' | 'delete' | 'substitute' | 'increase'
|
||||
newQuantity?: number
|
||||
newProductId?: string
|
||||
reason: string
|
||||
}>
|
||||
addressUpdate?: {
|
||||
deliveryAddress?: string
|
||||
contactPerson?: string
|
||||
contactPhone?: string
|
||||
reason?: string
|
||||
}
|
||||
}) {
|
||||
return request.post({
|
||||
url: `/web/admin/orders/${data.orderId}/adjust`,
|
||||
params: {
|
||||
adjustments: data.adjustments || [],
|
||||
addressUpdate: data.addressUpdate || undefined
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchOrderItems(orderId: string) {
|
||||
return request.get({
|
||||
url: `/web/admin/orders/${orderId}/items`
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchPriceVersionDetail(id: string) {
|
||||
return request.get({
|
||||
url: `/web/admin/price-versions/${id}`
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchUploadAttachment(data: FormData) {
|
||||
return request.post<{
|
||||
id: string
|
||||
fileName: string
|
||||
fileUrl: string
|
||||
fileSize: number
|
||||
fileSizeDisplay?: string
|
||||
fileType?: string
|
||||
}>({
|
||||
url: '/web/admin/attachment/upload',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchAttachmentDownloadUrl(data: { fileUrl: string; fileName?: string }) {
|
||||
return request.post<{ downloadUrl: string }>({
|
||||
url: '/web/admin/attachment/download-url',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchUploadProductImage(data: FormData) {
|
||||
return request.post({
|
||||
url: '/web/admin/products/upload-image',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchSystemConfig() {
|
||||
return request.get({
|
||||
url: '/web/admin/system-config/settings'
|
||||
})
|
||||
}
|
||||
|
||||
// ─── 临床应用缴费 ─────────────────────────────────────
|
||||
|
||||
export function fetchClinicalPayments(params: any) {
|
||||
return request.get({
|
||||
url: '/web/admin/clinical-payments',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchClinicalPaymentDetail(id: string) {
|
||||
return request.get({
|
||||
url: `/web/admin/clinical-payments/${id}`
|
||||
})
|
||||
}
|
||||
|
||||
export function submitClinicalReceipt(id: string, data?: Record<string, unknown>) {
|
||||
return request.post({
|
||||
url: `/web/admin/clinical-payments/${id}/submit-receipt`,
|
||||
params: data
|
||||
})
|
||||
}
|
||||
|
||||
export function batchSubmitClinicalReceipt(ids: string[], data?: Record<string, unknown>) {
|
||||
return request.post({
|
||||
url: '/web/admin/clinical-payments/submit-receipt-batch',
|
||||
params: { paymentIds: ids, ...data }
|
||||
})
|
||||
}
|
||||
|
||||
export function confirmClinicalReceipt(id: string, data: any) {
|
||||
return request.post({
|
||||
url: `/web/admin/clinical-payments/${id}/confirm-receipt`,
|
||||
params: data
|
||||
})
|
||||
}
|
||||
|
||||
export function submitClinicalRefund(id: string, data: any) {
|
||||
return request.post({
|
||||
url: `/web/admin/clinical-payments/${id}/submit-refund`,
|
||||
params: data
|
||||
})
|
||||
}
|
||||
|
||||
export function batchSubmitClinicalRefund(ids: string[], data: any) {
|
||||
return request.post({
|
||||
url: '/web/admin/clinical-payments/submit-refund-batch',
|
||||
params: { ...data, paymentIds: ids }
|
||||
})
|
||||
}
|
||||
|
||||
export function confirmClinicalRefund(id: string, data: any) {
|
||||
return request.post({
|
||||
url: `/web/admin/clinical-payments/${id}/confirm-refund`,
|
||||
params: data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchClinicalReceiptPending(params: any) {
|
||||
return request.get({
|
||||
url: '/web/admin/clinical-payments/receipt-pending',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchClinicalReceiptConfirmed(params: any) {
|
||||
return request.get({
|
||||
url: '/web/admin/clinical-payments/receipt-confirmed',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchClinicalRefundPending(params: any) {
|
||||
return request.get({
|
||||
url: '/web/admin/clinical-payments/refund-pending',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchClinicalRefundConfirmed(params: any) {
|
||||
return request.get({
|
||||
url: '/web/admin/clinical-payments/refund-confirmed',
|
||||
params
|
||||
})
|
||||
}
|
||||
@@ -1,45 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
export function fetchCellProductList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
productStatus?: string
|
||||
passage?: string
|
||||
sourceType?: string
|
||||
}) {
|
||||
return request.get<{
|
||||
list: any[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}>({ url: '/web/admin/cell-products', params })
|
||||
}
|
||||
|
||||
export function fetchCellProductDetail(id: string) {
|
||||
return request.get<any>({ url: `/web/admin/cell-products/${id}` })
|
||||
}
|
||||
|
||||
export function fetchCreateCellProduct(data: Record<string, any>) {
|
||||
return request.post({ url: '/web/admin/cell-products', params: data })
|
||||
}
|
||||
|
||||
export function fetchUpdateCellProduct(id: string, data: Record<string, any>) {
|
||||
return request.put({ url: `/web/admin/cell-products/${id}`, params: data })
|
||||
}
|
||||
|
||||
export function fetchDeleteCellProduct(id: string) {
|
||||
return request.del({ url: `/web/admin/cell-products/${id}` })
|
||||
}
|
||||
|
||||
export function fetchNextCellProductCode(count = 1) {
|
||||
return request.get<{ code: string; codes?: string[] }>({
|
||||
url: '/web/admin/cell-products/next-code',
|
||||
params: count > 1 ? { count } : undefined
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchCellProductChain(productId: string) {
|
||||
return request.get<any>({ url: `/web/admin/cell-products/${productId}/chain` })
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
/** 与小程序端一致:value=区划代码,label=名称,children=下级 */
|
||||
export interface ChinaRegionTreeNode {
|
||||
value: string
|
||||
label: string
|
||||
children?: ChinaRegionTreeNode[]
|
||||
}
|
||||
|
||||
/** 运营端:数据源 bas_china_region */
|
||||
export function fetchChinaRegionTree() {
|
||||
return request.get<{ tree: ChinaRegionTreeNode[] }>({
|
||||
url: '/web/admin/china-region-tree'
|
||||
})
|
||||
}
|
||||
@@ -1,222 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
type PageList<T> = {
|
||||
list: T[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}
|
||||
|
||||
/** 采集协议单列表项(camelCase,与后端一致) */
|
||||
export type CollectionProtocolRow = Record<string, unknown>
|
||||
|
||||
export function fetchCollectionProtocolList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
protocolStatus?: string
|
||||
createTimeStart?: string
|
||||
createTimeEnd?: string
|
||||
sampleCollectTimeStart?: string
|
||||
sampleCollectTimeEnd?: string
|
||||
}) {
|
||||
return request.get<PageList<CollectionProtocolRow>>({
|
||||
url: '/web/admin/collection-protocols',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchCollectionProtocolDetail(id: string) {
|
||||
return request.get<{
|
||||
protocol: Record<string, unknown>
|
||||
partyCustomer: Record<string, unknown> | null
|
||||
collectionInfo: Record<string, unknown> | null
|
||||
samples: Array<Record<string, unknown>> | null
|
||||
payment: Record<string, unknown> | null
|
||||
paymentDetails: Array<Record<string, unknown>> | null
|
||||
attachments?: Array<Record<string, unknown>>
|
||||
storageCert?: Record<string, unknown> | null
|
||||
}>({
|
||||
url: `/web/admin/collection-protocols/${id}`
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchCollectionProtocolAuditList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
auditStatus?: string
|
||||
}) {
|
||||
return request.get<PageList<Record<string, unknown>>>({
|
||||
url: '/web/admin/collection-protocol-audits',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchSubmitProtocolAudit(
|
||||
protocolId: string,
|
||||
data: { auditStatus: string; auditRemark?: string },
|
||||
options?: { showSuccessMessage?: boolean }
|
||||
) {
|
||||
return request.post({
|
||||
url: `/web/admin/collection-protocols/${protocolId}/audit`,
|
||||
data,
|
||||
showSuccessMessage: options?.showSuccessMessage ?? true
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchReceiptConfirmList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
installmentDueDateStart?: string
|
||||
installmentDueDateEnd?: string
|
||||
}) {
|
||||
return request.get<PageList<Record<string, unknown>>>({
|
||||
url: '/web/admin/protocol-payment-details/receipt-confirm',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchReceiptConfirmedList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
installmentDueDateStart?: string
|
||||
installmentDueDateEnd?: string
|
||||
}) {
|
||||
return request.get<PageList<Record<string, unknown>>>({
|
||||
url: '/web/admin/protocol-payment-details/receipt-confirmed',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchReceiptConfirmSubmit(
|
||||
detailId: string,
|
||||
data?: { financeConfirmAttachments?: string; financeRemark?: string }
|
||||
) {
|
||||
return request.post({
|
||||
url: `/web/admin/protocol-payment-details/${detailId}/receipt-confirm`,
|
||||
data: data || {},
|
||||
showSuccessMessage: true
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchRefundConfirmList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
installmentDueDateStart?: string
|
||||
installmentDueDateEnd?: string
|
||||
}) {
|
||||
return request.get<PageList<Record<string, unknown>>>({
|
||||
url: '/web/admin/protocol-payment-details/refund-confirm',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchRefundConfirmedList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
installmentDueDateStart?: string
|
||||
installmentDueDateEnd?: string
|
||||
}) {
|
||||
return request.get<PageList<Record<string, unknown>>>({
|
||||
url: '/web/admin/protocol-payment-details/refund-confirmed',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchRefundConfirmSubmit(
|
||||
detailId: string,
|
||||
data?: { refundFinanceConfirmAttachments?: string; refundFinanceRemark?: string }
|
||||
) {
|
||||
return request.post({
|
||||
url: `/web/admin/protocol-payment-details/${detailId}/refund-confirm`,
|
||||
data: data || {},
|
||||
showSuccessMessage: true
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchSubmitReceiptFinance(detailId: string) {
|
||||
return request.post({
|
||||
url: `/web/admin/protocol-payment-details/${detailId}/submit-receipt-finance`,
|
||||
showSuccessMessage: true
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchSubmitReceiptFinanceBatch(detailIds: string[]) {
|
||||
return request.post({
|
||||
url: '/web/admin/protocol-payment-details/submit-receipt-finance-batch',
|
||||
data: { detailIds },
|
||||
showSuccessMessage: true
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchSubmitRefundFinance(
|
||||
detailId: string,
|
||||
data: {
|
||||
refundAmount: number
|
||||
refundRemark?: string
|
||||
refundAttachments?: string
|
||||
}
|
||||
) {
|
||||
return request.post({
|
||||
url: `/web/admin/protocol-payment-details/${detailId}/submit-refund-finance`,
|
||||
data,
|
||||
showSuccessMessage: true
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchSubmitRefundFinanceBatch(data: {
|
||||
detailIds: string[]
|
||||
refundAmount: number
|
||||
refundRemark?: string
|
||||
refundAttachments?: string
|
||||
}) {
|
||||
return request.post({
|
||||
url: '/web/admin/protocol-payment-details/submit-refund-finance-batch',
|
||||
data,
|
||||
showSuccessMessage: true
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchPaymentDetailList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
payStatus?: string
|
||||
keyword?: string
|
||||
transferType?: string
|
||||
installmentDueDateStart?: string
|
||||
installmentDueDateEnd?: string
|
||||
}) {
|
||||
return request.get<PageList<Record<string, unknown>>>({
|
||||
url: '/web/admin/protocol-payment-details',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchCreateCollectionProtocol(data: Record<string, unknown>) {
|
||||
return request.post({
|
||||
url: '/web/admin/collection-protocols',
|
||||
data,
|
||||
showSuccessMessage: true
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchUpdateCollectionProtocol(id: string, data: Record<string, unknown>) {
|
||||
return request.put({
|
||||
url: `/web/admin/collection-protocols/${id}`,
|
||||
data,
|
||||
showSuccessMessage: true
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchDeleteCollectionProtocol(id: string) {
|
||||
return request.del({
|
||||
url: `/web/admin/collection-protocols/${id}`,
|
||||
showSuccessMessage: true
|
||||
})
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
export type EthnicOption = {
|
||||
id: string
|
||||
ethnicName: string
|
||||
ethnicCode: string
|
||||
orderNum?: number | null
|
||||
}
|
||||
|
||||
export function fetchEthnicList(params?: { keyword?: string; limit?: number }) {
|
||||
return request.get<{ list: EthnicOption[] }>({
|
||||
url: '/web/admin/ethnics',
|
||||
params
|
||||
})
|
||||
}
|
||||
@@ -1,60 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
export type OutboundHandoverInfo = {
|
||||
handoverUserId?: string
|
||||
handoverPerson?: string
|
||||
handoverTime?: string
|
||||
handoverLocation?: string
|
||||
receiverPerson?: string
|
||||
remark?: string
|
||||
}
|
||||
|
||||
export type OutboundHandoverDetail = {
|
||||
scheduleSummary?: {
|
||||
applicationNo?: string
|
||||
patientName?: string
|
||||
infusionTime?: string
|
||||
}
|
||||
outboundMaterial?: {
|
||||
remark?: string
|
||||
cells?: Array<{ cellProductId?: string; remark?: string }>
|
||||
qcMaterials?: Array<{ qcMaterialId?: string; qty?: number; remark?: string }>
|
||||
paperMaterials?: Array<{
|
||||
paperName?: string
|
||||
copies?: number
|
||||
attachmentUrl?: string
|
||||
remark?: string
|
||||
}>
|
||||
}
|
||||
handover?: OutboundHandoverInfo
|
||||
}
|
||||
|
||||
export function fetchInfusionScheduleOutboundHandover(scheduleId: string) {
|
||||
return request.get<OutboundHandoverDetail>({
|
||||
url: `/web/admin/pilot-infusion-schedule-mgmt/${scheduleId}/outbound-handover`
|
||||
})
|
||||
}
|
||||
|
||||
export function saveInfusionScheduleOutboundHandover(
|
||||
scheduleId: string,
|
||||
data: {
|
||||
outboundMaterial: {
|
||||
remark?: string
|
||||
cells: { cellProductId: string; remark?: string }[]
|
||||
qcMaterials: { materialId: string; qty: number; remark?: string }[]
|
||||
paperMaterials: { paperName: string; copies: number; attachmentUrl: string; remark?: string }[]
|
||||
}
|
||||
handover: {
|
||||
handoverUserId: string
|
||||
handoverTime: string
|
||||
handoverLocation?: string
|
||||
receiverPerson: string
|
||||
remark?: string
|
||||
}
|
||||
}
|
||||
) {
|
||||
return request.put<OutboundHandoverDetail>({
|
||||
url: `/web/admin/pilot-infusion-schedule-mgmt/${scheduleId}/outbound-handover`,
|
||||
data
|
||||
})
|
||||
}
|
||||
@@ -1,6 +1,5 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
/** 请假申请列表 */
|
||||
export function fetchLeaveList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
@@ -19,7 +18,6 @@ export function fetchLeaveList(params?: {
|
||||
})
|
||||
}
|
||||
|
||||
/** 创建请假申请 */
|
||||
export function fetchCreateLeave(data: {
|
||||
leaveType: string
|
||||
startDate: string
|
||||
@@ -35,7 +33,6 @@ export function fetchCreateLeave(data: {
|
||||
})
|
||||
}
|
||||
|
||||
/** 编辑请假申请 */
|
||||
export function fetchUpdateLeave(
|
||||
id: string,
|
||||
data: Partial<{
|
||||
@@ -54,7 +51,6 @@ export function fetchUpdateLeave(
|
||||
})
|
||||
}
|
||||
|
||||
/** 删除请假申请 */
|
||||
export function fetchDeleteLeave(id: string) {
|
||||
return request.del({
|
||||
url: `/web/admin/leave/${id}`,
|
||||
@@ -62,7 +58,6 @@ export function fetchDeleteLeave(id: string) {
|
||||
})
|
||||
}
|
||||
|
||||
/** 提交请假申请并发起审批 */
|
||||
export function fetchSubmitLeave(id: string) {
|
||||
return request.post<{ instanceId: string; status: string }>({
|
||||
url: `/web/admin/leave/${id}/submit`,
|
||||
@@ -70,7 +65,6 @@ export function fetchSubmitLeave(id: string) {
|
||||
})
|
||||
}
|
||||
|
||||
/** 请假详情 */
|
||||
export function fetchLeaveDetail(id: string) {
|
||||
return request.get<Api.Leave.LeaveItem>({
|
||||
url: `/web/admin/leave/${id}`
|
||||
|
||||
@@ -1,144 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
type PageList<T> = {
|
||||
list: T[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}
|
||||
|
||||
export type Material = {
|
||||
id: string
|
||||
materialCode: string
|
||||
materialName: string
|
||||
category: string
|
||||
specModel: string
|
||||
unit: string
|
||||
stockQty: number
|
||||
warningQty: number
|
||||
status: string
|
||||
imageUrls: string
|
||||
tenantNo: string
|
||||
orderNum: number
|
||||
remark: string
|
||||
createBy: string
|
||||
createTime: string
|
||||
updateTime: string
|
||||
}
|
||||
|
||||
export type MaterialStockLog = {
|
||||
id: string
|
||||
materialId: string
|
||||
materialCode: string
|
||||
materialName: string
|
||||
changeType: string
|
||||
changeQty: number
|
||||
stockBefore: number
|
||||
stockAfter: number
|
||||
receiver: string
|
||||
purpose: string
|
||||
remark: string
|
||||
createBy: string
|
||||
createByName?: string
|
||||
createTime: string
|
||||
updateTime: string
|
||||
}
|
||||
|
||||
export function fetchMaterialList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
category?: string
|
||||
status?: string
|
||||
}) {
|
||||
return request.get<PageList<Material>>({
|
||||
url: '/web/admin/materials',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchMaterialOptions() {
|
||||
return request.get<{ id: string; label: string; materialCode: string }[]>({
|
||||
url: '/web/admin/materials/options'
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchCreateMaterial(data: Record<string, any>) {
|
||||
return request.post<Material>({
|
||||
url: '/web/admin/materials',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchUpdateMaterial(id: string, data: Record<string, any>) {
|
||||
return request.put<Material>({
|
||||
url: `/web/admin/materials/${id}`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchDeleteMaterial(id: string) {
|
||||
return request.delete<void>({
|
||||
url: `/web/admin/materials/${id}`
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchStockInMaterial(
|
||||
id: string,
|
||||
data: { qty: number; remark?: string; stockInTime?: string }
|
||||
) {
|
||||
return request.post<Material>({
|
||||
url: `/web/admin/materials/${id}/stock-in`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchStockOutMaterial(
|
||||
id: string,
|
||||
data: { qty: number; receiver?: string; purpose?: string; remark?: string; stockOutTime?: string }
|
||||
) {
|
||||
return request.post<Material>({
|
||||
url: `/web/admin/materials/${id}/stock-out`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchBatchStockInMaterial(data: {
|
||||
items: { materialId: string; qty: number; remark?: string }[]
|
||||
remark?: string
|
||||
stockInTime?: string
|
||||
}) {
|
||||
return request.post<{ count: number }>({
|
||||
url: '/web/admin/materials/batch-stock-in',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchBatchStockOutMaterial(data: {
|
||||
items: { materialId: string; qty: number; remark?: string }[]
|
||||
receiver?: string
|
||||
purpose?: string
|
||||
remark?: string
|
||||
stockOutTime?: string
|
||||
}) {
|
||||
return request.post<{ count: number }>({
|
||||
url: '/web/admin/materials/batch-stock-out',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchMaterialStockLogList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
materialId?: string
|
||||
changeType?: string
|
||||
startTime?: string
|
||||
endTime?: string
|
||||
keyword?: string
|
||||
}) {
|
||||
return request.get<PageList<MaterialStockLog>>({
|
||||
url: '/web/admin/material-stock-logs',
|
||||
params
|
||||
})
|
||||
}
|
||||
@@ -1,242 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
import type {
|
||||
OutboundQcDetailApplication,
|
||||
OutboundQcDetailPatient,
|
||||
OutboundQcDetailInfusionPlan,
|
||||
OutboundQcDetailInfusionSchedule,
|
||||
OutboundQcDetailProduct,
|
||||
} from '@/api/qc-work-order'
|
||||
|
||||
type PageList<T> = {
|
||||
list: T[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}
|
||||
|
||||
export type OutboundReleaseReview = {
|
||||
id: string
|
||||
scheduleId?: string
|
||||
/** pilot_service=中试服务 clinical_application=临床应用 */
|
||||
bizType?: string
|
||||
bizTypeLabel?: string
|
||||
applicationNo?: string
|
||||
patientName?: string
|
||||
cellType?: string
|
||||
specText?: string
|
||||
infusionTime?: string
|
||||
scheduleStatus?: string
|
||||
scheduleStatusLabel?: string
|
||||
qcStatus?: string
|
||||
qcStatusLabel?: string
|
||||
reviewConclusion?: string
|
||||
reviewConclusionLabel?: string
|
||||
reviewRemark?: string
|
||||
reviewAttachments?: string
|
||||
reviewByName?: string
|
||||
reviewTime?: string
|
||||
createTime?: string
|
||||
updateTime?: string
|
||||
}
|
||||
|
||||
export type {
|
||||
OutboundQcDetailApplication,
|
||||
OutboundQcDetailPatient,
|
||||
OutboundQcDetailInfusionPlan,
|
||||
OutboundQcDetailInfusionSchedule,
|
||||
OutboundQcDetailProduct,
|
||||
}
|
||||
|
||||
export type OutboundReviewInfo = {
|
||||
id?: string
|
||||
scheduleId?: string
|
||||
reviewConclusion?: string
|
||||
reviewRemark?: string
|
||||
reviewAttachments?: string
|
||||
reviewByName?: string
|
||||
reviewTime?: string
|
||||
}
|
||||
|
||||
export type OutboundProductionTask = {
|
||||
id?: string
|
||||
taskNo?: string
|
||||
taskName?: string
|
||||
taskStatus?: string
|
||||
taskStatusLabel?: string
|
||||
conclusion?: string
|
||||
conclusionLabel?: string
|
||||
startedTime?: string
|
||||
completedTime?: string
|
||||
}
|
||||
|
||||
export type OutboundProductionInfo = {
|
||||
workOrderNo?: string
|
||||
workOrderStatus?: string
|
||||
workOrderStatusLabel?: string
|
||||
tasks?: OutboundProductionTask[]
|
||||
}
|
||||
|
||||
export type OutboundQcTask = {
|
||||
id?: string
|
||||
taskType?: string
|
||||
taskTypeLabel?: string
|
||||
taskStatus?: string
|
||||
taskStatusLabel?: string
|
||||
conclusion?: string
|
||||
conclusionLabel?: string
|
||||
}
|
||||
|
||||
export type OutboundQcInfo = {
|
||||
workOrderNo?: string
|
||||
workOrderStatus?: string
|
||||
workOrderStatusLabel?: string
|
||||
tasks?: OutboundQcTask[]
|
||||
}
|
||||
|
||||
export type OutboundReleaseReviewDetail = {
|
||||
application?: OutboundQcDetailApplication
|
||||
patient?: OutboundQcDetailPatient
|
||||
infusionPlan?: OutboundQcDetailInfusionPlan
|
||||
infusionSchedule?: OutboundQcDetailInfusionSchedule
|
||||
products?: OutboundQcDetailProduct[]
|
||||
productionInfo?: OutboundProductionInfo
|
||||
qcInfo?: OutboundQcInfo
|
||||
reviewInfo?: OutboundReviewInfo
|
||||
outboundMaterial?: OutboundReleaseMaterialDetail
|
||||
}
|
||||
|
||||
export type OutboundReleaseCellRow = {
|
||||
id?: string
|
||||
cellProductId?: string
|
||||
productCode?: string
|
||||
productName?: string
|
||||
productTypeName?: string
|
||||
specName?: string
|
||||
passage?: string
|
||||
batchNo?: string
|
||||
storageSlotName?: string
|
||||
productStatus?: string
|
||||
remark?: string
|
||||
}
|
||||
|
||||
export type OutboundReleaseQcMaterialRow = {
|
||||
id?: string
|
||||
qcMaterialId?: string
|
||||
qty?: number
|
||||
materialCode?: string
|
||||
materialName?: string
|
||||
specModel?: string
|
||||
unit?: string
|
||||
remark?: string
|
||||
}
|
||||
|
||||
export type OutboundReleasePaperRow = {
|
||||
id?: string
|
||||
paperName?: string
|
||||
copies?: number
|
||||
attachmentUrl?: string
|
||||
remark?: string
|
||||
}
|
||||
|
||||
export type OutboundReleaseMaterialDetail = {
|
||||
id?: string
|
||||
infusionScheduleId?: string
|
||||
paperAttachments?: string
|
||||
paperMaterials?: OutboundReleasePaperRow[]
|
||||
remark?: string
|
||||
cells?: OutboundReleaseCellRow[]
|
||||
qcMaterials?: OutboundReleaseQcMaterialRow[]
|
||||
createTime?: string
|
||||
updateTime?: string
|
||||
}
|
||||
|
||||
export function fetchOutboundReleaseReviewList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
scheduleStatus?: string
|
||||
reviewConclusion?: string
|
||||
qcStatus?: string
|
||||
keyword?: string
|
||||
/** pilot_service | clinical_application */
|
||||
bizType?: string
|
||||
infusionTimeStart?: string
|
||||
infusionTimeEnd?: string
|
||||
}) {
|
||||
return request.get<PageList<OutboundReleaseReview>>({
|
||||
url: '/web/admin/pilot-release-reviews',
|
||||
params,
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchOutboundReleaseReviewDetail(scheduleId: string) {
|
||||
return request.get<OutboundReleaseReviewDetail>({
|
||||
url: `/web/admin/pilot-release-reviews/${scheduleId}/detail`,
|
||||
})
|
||||
}
|
||||
|
||||
export function submitOutboundReleaseReview(
|
||||
scheduleId: string,
|
||||
data: {
|
||||
reviewConclusion: string
|
||||
reviewRemark?: string
|
||||
reviewAttachments?: string
|
||||
}
|
||||
) {
|
||||
return request.put<OutboundReleaseReview>({
|
||||
url: `/web/admin/pilot-release-reviews/${scheduleId}/review`,
|
||||
data,
|
||||
})
|
||||
}
|
||||
|
||||
export function batchReviewOutboundRelease(data: {
|
||||
scheduleIds: string[]
|
||||
reviewConclusion: string
|
||||
reviewRemark?: string
|
||||
reviewAttachments?: string
|
||||
}) {
|
||||
return request.put<void>({
|
||||
url: '/web/admin/pilot-release-reviews/batch-review',
|
||||
data,
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchOutboundReleaseMaterial(scheduleId: string) {
|
||||
return request.get<OutboundReleaseMaterialDetail>({
|
||||
url: `/web/admin/pilot-release-reviews/${scheduleId}/outbound-materials`,
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchReleaseReviewList(params: { scheduleId: string }) {
|
||||
return request.get<any>({
|
||||
url: `/web/admin/pilot-release-reviews/${params.scheduleId}/detail`,
|
||||
})
|
||||
}
|
||||
|
||||
export function updateReleaseReview(data: { id: string; reviewConclusion: string }) {
|
||||
return request.put<any>({
|
||||
url: `/web/admin/pilot-release-reviews/${data.id}/review`,
|
||||
data: { reviewConclusion: data.reviewConclusion },
|
||||
})
|
||||
}
|
||||
|
||||
export function deleteReleaseReview(data: { id: string }) {
|
||||
return request.delete<any>({
|
||||
url: `/web/admin/pilot-release-reviews/${data.id}`,
|
||||
})
|
||||
}
|
||||
|
||||
export function saveOutboundReleaseMaterial(
|
||||
scheduleId: string,
|
||||
data: {
|
||||
paperMaterials?: { paperName: string; copies: number; attachmentUrl: string; remark?: string }[]
|
||||
remark?: string
|
||||
cells: { cellProductId: string; remark?: string }[]
|
||||
qcMaterials: { materialId: string; qty: number; remark?: string }[]
|
||||
}
|
||||
) {
|
||||
return request.put<OutboundReleaseMaterialDetail>({
|
||||
url: `/web/admin/pilot-release-reviews/${scheduleId}/outbound-materials`,
|
||||
data,
|
||||
})
|
||||
}
|
||||
@@ -1,98 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
export function fetchCreateProductionTask(data: Record<string, any>) {
|
||||
return request.post({ url: '/web/admin/production-tasks', params: data })
|
||||
}
|
||||
|
||||
export function fetchProductionTaskList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
taskStatus?: string
|
||||
workOrderId?: string
|
||||
startedTimeStart?: string
|
||||
startedTimeEnd?: string
|
||||
}) {
|
||||
return request.get<{
|
||||
list: any[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}>({ url: '/web/admin/production-tasks', params })
|
||||
}
|
||||
|
||||
export function fetchProductionTaskDetail(id: string) {
|
||||
return request.get<any>({ url: `/web/admin/production-tasks/${id}` })
|
||||
}
|
||||
|
||||
export function fetchUpdateProductionTask(id: string, data: Record<string, any>) {
|
||||
return request.put({ url: `/web/admin/production-tasks/${id}`, params: data })
|
||||
}
|
||||
|
||||
export function fetchUpdateProductionTaskStatus(id: string, data: Record<string, any>) {
|
||||
return request.put({ url: `/web/admin/production-tasks/${id}/status`, params: data })
|
||||
}
|
||||
|
||||
export function fetchDeleteProductionTask(id: string) {
|
||||
return request.del({ url: `/web/admin/production-tasks/${id}` })
|
||||
}
|
||||
|
||||
export function fetchAddTaskStep(taskId: string, data: Record<string, any>) {
|
||||
return request.post({ url: `/web/admin/production-tasks/${taskId}/steps`, params: data })
|
||||
}
|
||||
|
||||
export function fetchUpdateTaskStep(taskId: string, stepId: string, data: Record<string, any>) {
|
||||
return request.put({ url: `/web/admin/production-tasks/${taskId}/steps/${stepId}`, params: data })
|
||||
}
|
||||
|
||||
export function fetchDeleteTaskStep(taskId: string, stepId: string) {
|
||||
return request.del({ url: `/web/admin/production-tasks/${taskId}/steps/${stepId}` })
|
||||
}
|
||||
|
||||
export function fetchReplaceStepReagents(taskId: string, stepId: string, data: any[]) {
|
||||
return request.put({
|
||||
url: `/web/admin/production-tasks/${taskId}/steps/${stepId}/reagents`,
|
||||
params: data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchReplaceStepConsumables(taskId: string, stepId: string, data: any[]) {
|
||||
return request.put({
|
||||
url: `/web/admin/production-tasks/${taskId}/steps/${stepId}/consumables`,
|
||||
params: data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchReplaceStepDataCollection(taskId: string, stepId: string, data: any[]) {
|
||||
return request.put({
|
||||
url: `/web/admin/production-tasks/${taskId}/steps/${stepId}/data-collection`,
|
||||
params: data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchSetTaskInputs(taskId: string, data: any[] | Record<string, any>) {
|
||||
return request.post({ url: `/web/admin/production-tasks/${taskId}/inputs`, params: data })
|
||||
}
|
||||
|
||||
export function fetchSetTaskOutputs(taskId: string, data: any[] | Record<string, any>) {
|
||||
return request.post({ url: `/web/admin/production-tasks/${taskId}/outputs`, params: data })
|
||||
}
|
||||
|
||||
export function fetchReorderTaskSteps(data: { taskId: string; stepIds: string[] }) {
|
||||
return request.put({ url: '/web/admin/production-tasks/step/reorder', params: data })
|
||||
}
|
||||
|
||||
export function fetchCopyTaskStep(data: { taskId: string; stepId: string }) {
|
||||
return request.post({
|
||||
url: `/web/admin/production-tasks/${data.taskId}/steps/${data.stepId}/copy`,
|
||||
params: data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchReplaceStepOutputs(taskId: string, stepId: string, data: any[]) {
|
||||
return request.put({
|
||||
url: `/web/admin/production-tasks/${taskId}/steps/${stepId}/outputs`,
|
||||
params: data
|
||||
})
|
||||
}
|
||||
@@ -1,129 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
import type {
|
||||
QcWorkOrderReceptionDetail,
|
||||
OutboundQcDetailApplication,
|
||||
OutboundQcDetailPatient,
|
||||
OutboundQcDetailInfusionPlan,
|
||||
OutboundQcDetailInfusionSchedule,
|
||||
OutboundQcDetailProduct
|
||||
} from '@/api/qc-work-order'
|
||||
|
||||
export interface ProductionWorkOrderItem {
|
||||
id: string
|
||||
workOrderNo: string
|
||||
workOrderType?: string
|
||||
protocolNo?: string
|
||||
sampleCode?: string
|
||||
receptionSource?: string
|
||||
receptionSourceLabel?: string
|
||||
sampleTypeName?: string
|
||||
handlerName?: string
|
||||
receptionTime?: string
|
||||
workOrderStatus: string
|
||||
createTime?: string
|
||||
remark?: string
|
||||
/** 出库工单:关联申请单号 */
|
||||
applicationNo?: string
|
||||
/** 出库工单:患者/用户姓名 */
|
||||
patientName?: string
|
||||
/** 出库工单:当前为第几次输注计划 */
|
||||
sortNo?: number | null
|
||||
/** 出库工单:输注计划总次数 */
|
||||
totalCourseCount?: number | null
|
||||
infusionTime?: string
|
||||
}
|
||||
|
||||
export type ProductionWorkOrderDetail = ProductionWorkOrderItem & {
|
||||
reception?: QcWorkOrderReceptionDetail
|
||||
bizType?: string
|
||||
bizTypeLabel?: string
|
||||
/** 临床应用出库:简要申请单 */
|
||||
pilotApplication?: {
|
||||
applicationNo?: string
|
||||
applicationName?: string
|
||||
applicationStatus?: string
|
||||
applicationStatusLabel?: string
|
||||
}
|
||||
/** 临床应用出库:简要输注计划 */
|
||||
infusionSchedule?: {
|
||||
cellType?: string
|
||||
specText?: string
|
||||
infusionTime?: string
|
||||
infusionLocation?: string
|
||||
infusionMethod?: string
|
||||
scheduleStatus?: string
|
||||
}
|
||||
/** 中试服务出库:与出库质检工单查看弹窗一致 */
|
||||
application?: OutboundQcDetailApplication
|
||||
patient?: OutboundQcDetailPatient
|
||||
infusionPlan?: OutboundQcDetailInfusionPlan
|
||||
products?: OutboundQcDetailProduct[]
|
||||
}
|
||||
|
||||
export function fetchProductionWorkOrderList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
workOrderStatus?: string
|
||||
workOrderType?: string
|
||||
createTimeStart?: string
|
||||
createTimeEnd?: string
|
||||
infusionTimeStart?: string
|
||||
infusionTimeEnd?: string
|
||||
}) {
|
||||
return request.get<{
|
||||
list: ProductionWorkOrderItem[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}>({ url: '/web/admin/production-work-orders', params })
|
||||
}
|
||||
|
||||
export function fetchProductionWorkOrderDetail(id: string) {
|
||||
return request.get<ProductionWorkOrderDetail>({ url: `/web/admin/production-work-orders/${id}` })
|
||||
}
|
||||
|
||||
export function fetchCompleteProductionWorkOrder(id: string, data: Record<string, any>) {
|
||||
return request.put({ url: `/web/admin/production-work-orders/${id}/complete`, params: data })
|
||||
}
|
||||
|
||||
export function fetchCreateProductionWorkOrder(data: {
|
||||
workOrderType?: string
|
||||
protocolNo?: string
|
||||
sampleCode?: string
|
||||
receptionSource?: string
|
||||
remark?: string
|
||||
}) {
|
||||
return request.post<ProductionWorkOrderItem>({
|
||||
url: '/web/admin/production-work-orders',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchConfigureProductionWorkOrder(
|
||||
id: string,
|
||||
data: {
|
||||
taskName?: string
|
||||
taskType?: string
|
||||
routeId?: string
|
||||
description?: string
|
||||
remark?: string
|
||||
}
|
||||
) {
|
||||
return request.post<ProductionWorkOrderItem>({
|
||||
url: `/web/admin/production-work-orders/${id}/configure`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchUpdateProductionWorkOrder(id: string, data: { remark?: string }) {
|
||||
return request.put<ProductionWorkOrderItem>({
|
||||
url: `/web/admin/production-work-orders/${id}`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchDeleteProductionWorkOrder(id: string) {
|
||||
return request.del({ url: `/web/admin/production-work-orders/${id}` })
|
||||
}
|
||||
@@ -1,435 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// 耗材管理
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
export function fetchConsumableList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
}) {
|
||||
return request.get<{
|
||||
list: any[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}>({ url: '/web/admin/consumables', params })
|
||||
}
|
||||
|
||||
export function fetchAllConsumables() {
|
||||
return request.get<any[]>({ url: '/web/admin/consumables/all' })
|
||||
}
|
||||
|
||||
export function fetchCreateConsumable(data: Record<string, any>) {
|
||||
return request.post({ url: '/web/admin/consumables', params: data })
|
||||
}
|
||||
|
||||
export function fetchUpdateConsumable(id: string, data: Record<string, any>) {
|
||||
return request.put({ url: `/web/admin/consumables/${id}`, params: data })
|
||||
}
|
||||
|
||||
export function fetchDeleteConsumable(id: string) {
|
||||
return request.del({ url: `/web/admin/consumables/${id}` })
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// 试剂管理
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
export function fetchReagentList(params?: { page?: number; pageSize?: number; keyword?: string }) {
|
||||
return request.get<{
|
||||
list: any[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}>({ url: '/web/admin/reagents', params })
|
||||
}
|
||||
|
||||
export function fetchAllReagents() {
|
||||
return request.get<any[]>({ url: '/web/admin/reagents/all' })
|
||||
}
|
||||
|
||||
export function fetchCreateReagent(data: Record<string, any>) {
|
||||
return request.post({ url: '/web/admin/reagents', params: data })
|
||||
}
|
||||
|
||||
export function fetchUpdateReagent(id: string, data: Record<string, any>) {
|
||||
return request.put({ url: `/web/admin/reagents/${id}`, params: data })
|
||||
}
|
||||
|
||||
export function fetchDeleteReagent(id: string) {
|
||||
return request.del({ url: `/web/admin/reagents/${id}` })
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// SOP文档
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
export function fetchSopList(params?: { page?: number; pageSize?: number; keyword?: string }) {
|
||||
return request.get<{
|
||||
list: any[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}>({ url: '/web/admin/sop-documents', params })
|
||||
}
|
||||
|
||||
export function fetchAllSopDocuments() {
|
||||
return request.get<any[]>({ url: '/web/admin/sop-documents/all' })
|
||||
}
|
||||
|
||||
export function fetchCreateSop(data: Record<string, any>) {
|
||||
return request.post({ url: '/web/admin/sop-documents', params: data })
|
||||
}
|
||||
|
||||
export function fetchUpdateSop(id: string, data: Record<string, any>) {
|
||||
return request.put({ url: `/web/admin/sop-documents/${id}`, params: data })
|
||||
}
|
||||
|
||||
export function fetchDeleteSop(id: string) {
|
||||
return request.del({ url: `/web/admin/sop-documents/${id}` })
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// 工艺工序分类
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
export function fetchProcessCategoryList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
}) {
|
||||
return request.get<{
|
||||
list: any[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}>({ url: '/web/admin/process-categories', params })
|
||||
}
|
||||
|
||||
export function fetchAllProcessCategories() {
|
||||
return request.get<any[]>({ url: '/web/admin/process-categories/all' })
|
||||
}
|
||||
|
||||
export function fetchCreateProcessCategory(data: Record<string, any>) {
|
||||
return request.post({ url: '/web/admin/process-categories', params: data })
|
||||
}
|
||||
|
||||
export function fetchUpdateProcessCategory(id: string, data: Record<string, any>) {
|
||||
return request.put({ url: `/web/admin/process-categories/${id}`, params: data })
|
||||
}
|
||||
|
||||
export function fetchDeleteProcessCategory(id: string) {
|
||||
return request.del({ url: `/web/admin/process-categories/${id}` })
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// 工艺产出物类型
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
export function fetchOutputTypeList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
}) {
|
||||
return request.get<{
|
||||
list: any[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}>({ url: '/web/admin/output-types', params })
|
||||
}
|
||||
|
||||
export function fetchAllOutputTypes() {
|
||||
return request.get<any[]>({ url: '/web/admin/output-types/all' })
|
||||
}
|
||||
|
||||
export function fetchCreateOutputType(data: Record<string, any>) {
|
||||
return request.post({ url: '/web/admin/output-types', params: data })
|
||||
}
|
||||
|
||||
export function fetchUpdateOutputType(id: string, data: Record<string, any>) {
|
||||
return request.put({ url: `/web/admin/output-types/${id}`, params: data })
|
||||
}
|
||||
|
||||
export function fetchDeleteOutputType(id: string) {
|
||||
return request.del({ url: `/web/admin/output-types/${id}` })
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// 耗材包管理
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
export function fetchConsumablePackList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
}) {
|
||||
return request.get<{
|
||||
list: any[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}>({ url: '/web/admin/consumable-packs', params })
|
||||
}
|
||||
|
||||
export function fetchAllConsumablePacks() {
|
||||
return request.get<any[]>({ url: '/web/admin/consumable-packs/all' })
|
||||
}
|
||||
|
||||
export function fetchCreateConsumablePack(data: Record<string, any>) {
|
||||
return request.post({ url: '/web/admin/consumable-packs', params: data })
|
||||
}
|
||||
|
||||
export function fetchUpdateConsumablePack(id: string, data: Record<string, any>) {
|
||||
return request.put({ url: `/web/admin/consumable-packs/${id}`, params: data })
|
||||
}
|
||||
|
||||
export function fetchDeleteConsumablePack(id: string) {
|
||||
return request.del({ url: `/web/admin/consumable-packs/${id}` })
|
||||
}
|
||||
|
||||
export function fetchConsumablePackDetail(id: string) {
|
||||
return request.get<any>({ url: `/web/admin/consumable-packs/${id}` })
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// 工艺库管理
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
export function fetchProcessList(params?: { page?: number; pageSize?: number; keyword?: string }) {
|
||||
return request.get<{
|
||||
list: any[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}>({ url: '/web/admin/processes', params })
|
||||
}
|
||||
|
||||
export function fetchAllProcesses() {
|
||||
return request.get<any[]>({ url: '/web/admin/processes/all' })
|
||||
}
|
||||
|
||||
export function fetchCreateProcess(data: Record<string, any>) {
|
||||
return request.post({ url: '/web/admin/processes', params: data })
|
||||
}
|
||||
|
||||
export function fetchUpdateProcess(id: string, data: Record<string, any>) {
|
||||
return request.put({ url: `/web/admin/processes/${id}`, params: data })
|
||||
}
|
||||
|
||||
export function fetchDeleteProcess(id: string) {
|
||||
return request.del({ url: `/web/admin/processes/${id}` })
|
||||
}
|
||||
|
||||
export function fetchProcessDetail(id: string) {
|
||||
return request.get<any>({ url: `/web/admin/processes/${id}` })
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// 工艺路线管理
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
export function fetchProcessRouteList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
routeName?: string
|
||||
routeCode?: string
|
||||
productTypeId?: string
|
||||
}) {
|
||||
return request.get<{
|
||||
list: any[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}>({ url: '/web/admin/process-routes', params })
|
||||
}
|
||||
|
||||
export function fetchProcessRouteDetail(id: string) {
|
||||
return request.get<any>({ url: `/web/admin/process-routes/${id}` })
|
||||
}
|
||||
|
||||
export function fetchCreateProcessRoute(data: Record<string, any>) {
|
||||
return request.post({ url: '/web/admin/process-routes', params: data })
|
||||
}
|
||||
|
||||
export function fetchUpdateProcessRoute(id: string, data: Record<string, any>) {
|
||||
return request.put({ url: `/web/admin/process-routes/${id}`, params: data })
|
||||
}
|
||||
|
||||
export function fetchSetCurrentProcessRoute(routeId: string) {
|
||||
return request.put({ url: '/web/admin/process-routes/set-current', params: { routeId } })
|
||||
}
|
||||
|
||||
export function fetchDeleteProcessRoute(id: string) {
|
||||
return request.del({ url: `/web/admin/process-routes/${id}` })
|
||||
}
|
||||
|
||||
// 步骤操作
|
||||
export function fetchAddRouteStep(data: {
|
||||
routeId: string
|
||||
processId: string
|
||||
stepOrder?: number
|
||||
}) {
|
||||
return request.post({ url: '/web/admin/process-routes/step/add', params: data })
|
||||
}
|
||||
|
||||
export function fetchCopyRouteStep(data: { stepId: string }) {
|
||||
return request.post({ url: '/web/admin/process-routes/step/copy', params: data })
|
||||
}
|
||||
|
||||
export function fetchUpdateRouteStep(data: Record<string, any>) {
|
||||
return request.put({ url: '/web/admin/process-routes/step/update', params: data })
|
||||
}
|
||||
|
||||
export function fetchReorderRouteSteps(data: { routeId: string; stepIds: string[] }) {
|
||||
return request.put({ url: '/web/admin/process-routes/step/reorder', params: data })
|
||||
}
|
||||
|
||||
export function fetchDeleteRouteStep(stepId: string) {
|
||||
return request.del({ url: `/web/admin/process-routes/step/${stepId}` })
|
||||
}
|
||||
|
||||
// 步骤子表
|
||||
export function fetchUpdateStepReagents(data: { stepId: string; items: any[] }) {
|
||||
return request.put({ url: '/web/admin/process-routes/step/reagent/update', params: data })
|
||||
}
|
||||
|
||||
export function fetchUpdateStepConsumables(data: { stepId: string; items: any[] }) {
|
||||
return request.put({ url: '/web/admin/process-routes/step/consumable/update', params: data })
|
||||
}
|
||||
|
||||
export function fetchUpdateStepOutputs(data: { stepId: string; items: any[] }) {
|
||||
return request.put({ url: '/web/admin/process-routes/step/output/update', params: data })
|
||||
}
|
||||
|
||||
export function fetchUpdateStepDataCollections(data: { stepId: string; items: any[] }) {
|
||||
return request.put({ url: '/web/admin/process-routes/step/data-collection/update', params: data })
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// 试剂库存操作
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
export function fetchReagentStockIn(id: string, data: { qty: number; remark?: string }) {
|
||||
return request.post({ url: `/web/admin/reagents/${id}/stock-in`, data })
|
||||
}
|
||||
|
||||
export function fetchReagentStockOut(
|
||||
id: string,
|
||||
data: { qty: number; receiver: string; purpose?: string; remark?: string }
|
||||
) {
|
||||
return request.post({ url: `/web/admin/reagents/${id}/stock-out`, data })
|
||||
}
|
||||
|
||||
export function fetchReagentBatchStockIn(data: {
|
||||
items: Array<{ materialId: string; qty: number; remark?: string }>
|
||||
remark?: string
|
||||
}) {
|
||||
return request.post<{ count: number }>({ url: '/web/admin/reagents/batch-stock-in', data })
|
||||
}
|
||||
|
||||
export function fetchReagentBatchStockOut(data: {
|
||||
items: Array<{ materialId: string; qty: number }>
|
||||
receiver: string
|
||||
purpose?: string
|
||||
remark?: string
|
||||
}) {
|
||||
return request.post<{ count: number }>({ url: '/web/admin/reagents/batch-stock-out', data })
|
||||
}
|
||||
|
||||
export function fetchReagentStockLogs(
|
||||
id: string,
|
||||
params: { page: number; pageSize: number; changeType?: string }
|
||||
) {
|
||||
return request.get<{
|
||||
list: any[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
}>({ url: `/web/admin/reagents/${id}/stock-logs`, params })
|
||||
}
|
||||
|
||||
export function fetchAllReagentStockLogs(params: {
|
||||
page: number
|
||||
pageSize: number
|
||||
keyword?: string
|
||||
changeType?: string
|
||||
startTime?: string
|
||||
endTime?: string
|
||||
}) {
|
||||
return request.get<{
|
||||
list: any[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
}>({ url: '/web/admin/reagents/stock-logs', params })
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// 耗材库存操作
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
export function fetchConsumableStockIn(id: string, data: { qty: number; remark?: string }) {
|
||||
return request.post({ url: `/web/admin/consumables/${id}/stock-in`, data })
|
||||
}
|
||||
|
||||
export function fetchConsumableStockOut(
|
||||
id: string,
|
||||
data: { qty: number; receiver?: string; purpose?: string; remark?: string }
|
||||
) {
|
||||
return request.post({ url: `/web/admin/consumables/${id}/stock-out`, data })
|
||||
}
|
||||
|
||||
export function fetchConsumableBatchStockIn(data: {
|
||||
items: { materialId: string; qty: number; remark?: string }[]
|
||||
remark?: string
|
||||
}) {
|
||||
return request.post<{ count: number }>({ url: '/web/admin/consumables/batch-stock-in', data })
|
||||
}
|
||||
|
||||
export function fetchConsumableBatchStockOut(data: {
|
||||
items: { materialId: string; qty: number }[]
|
||||
receiver?: string
|
||||
purpose?: string
|
||||
remark?: string
|
||||
}) {
|
||||
return request.post<{ count: number }>({ url: '/web/admin/consumables/batch-stock-out', data })
|
||||
}
|
||||
|
||||
export function fetchConsumableStockLogs(
|
||||
id: string,
|
||||
params: { page: number; pageSize: number; changeType?: string }
|
||||
) {
|
||||
return request.get<{
|
||||
list: any[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
}>({ url: `/web/admin/consumables/${id}/stock-logs`, params })
|
||||
}
|
||||
|
||||
export function fetchAllConsumableStockLogs(params: {
|
||||
page: number
|
||||
pageSize: number
|
||||
keyword?: string
|
||||
changeType?: string
|
||||
startTime?: string
|
||||
endTime?: string
|
||||
}) {
|
||||
return request.get<{
|
||||
list: any[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
}>({ url: '/web/admin/consumables/stock-logs', params })
|
||||
}
|
||||
@@ -1,26 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
export type QcItemParam = {
|
||||
id?: string
|
||||
paramName: string
|
||||
paramCode: string
|
||||
paramUnit?: string
|
||||
paramType: string
|
||||
requiredFlag: string
|
||||
orderNum?: number
|
||||
}
|
||||
|
||||
export function fetchQcItemParams(itemSource: string, itemId: string) {
|
||||
return request.get<QcItemParam[]>({
|
||||
url: '/web/admin/qc-item-params',
|
||||
params: { itemSource, itemId }
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchSaveQcItemParams(itemSource: string, itemId: string, params: QcItemParam[]) {
|
||||
return request.put<QcItemParam[]>({
|
||||
url: '/web/admin/qc-item-params',
|
||||
params: { itemSource, itemId },
|
||||
data: { params }
|
||||
})
|
||||
}
|
||||
@@ -1,74 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
type PageList<T> = {
|
||||
list: T[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}
|
||||
|
||||
export type QcLabTestItem = {
|
||||
id: string
|
||||
itemCode: string
|
||||
itemName: string
|
||||
description?: string
|
||||
status: string
|
||||
orderNum: number
|
||||
remark?: string
|
||||
createTime?: string
|
||||
updateTime?: string
|
||||
}
|
||||
|
||||
export function fetchQcLabTestItemList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
status?: string
|
||||
}) {
|
||||
return request.get<PageList<QcLabTestItem>>({
|
||||
url: '/web/admin/qc-lab-test-items',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchQcLabTestItemsActive() {
|
||||
return request.get<QcLabTestItem[]>({
|
||||
url: '/web/admin/qc-lab-test-items/active'
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchCreateQcLabTestItem(data: {
|
||||
itemCode: string
|
||||
itemName: string
|
||||
description?: string
|
||||
status?: string
|
||||
orderNum?: number
|
||||
remark?: string
|
||||
}) {
|
||||
return request.post<QcLabTestItem>({
|
||||
url: '/web/admin/qc-lab-test-items',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchUpdateQcLabTestItem(
|
||||
id: string,
|
||||
data: Partial<{
|
||||
itemCode: string
|
||||
itemName: string
|
||||
description: string
|
||||
status: string
|
||||
orderNum: number
|
||||
remark: string
|
||||
}>
|
||||
) {
|
||||
return request.put<QcLabTestItem>({
|
||||
url: `/web/admin/qc-lab-test-items/${id}`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchDeleteQcLabTestItem(id: string) {
|
||||
return request.del({ url: `/web/admin/qc-lab-test-items/${id}` })
|
||||
}
|
||||
@@ -1,43 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
type PageList<T> = {
|
||||
list: T[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}
|
||||
|
||||
export type QcMaterialUsage = {
|
||||
id: string
|
||||
materialId: string
|
||||
materialCode: string
|
||||
materialName: string
|
||||
changeType: string
|
||||
changeQty: number
|
||||
stockAfter: number
|
||||
qcTaskId: string
|
||||
qcTaskNo: string
|
||||
receiver?: string
|
||||
purpose?: string
|
||||
useTime?: string
|
||||
sourceType: string
|
||||
remark: string
|
||||
createBy: string
|
||||
createByName?: string
|
||||
createTime: string
|
||||
}
|
||||
|
||||
export function fetchQcMaterialUsageList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
materialId?: string
|
||||
changeType?: string
|
||||
startTime?: string
|
||||
endTime?: string
|
||||
}) {
|
||||
return request.get<PageList<QcMaterialUsage>>({
|
||||
url: '/web/admin/qc-material-usages',
|
||||
params
|
||||
})
|
||||
}
|
||||
@@ -1,124 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
type PageList<T> = {
|
||||
list: T[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}
|
||||
|
||||
export type QcMaterial = {
|
||||
id: string
|
||||
materialCode: string
|
||||
materialName: string
|
||||
specModel: string
|
||||
unit: string
|
||||
stockQty: number
|
||||
warningQty: number
|
||||
status: string
|
||||
tenantNo: string
|
||||
orderNum: number
|
||||
remark: string
|
||||
createBy: string
|
||||
createTime: string
|
||||
updateTime: string
|
||||
}
|
||||
|
||||
export type QcMaterialOption = {
|
||||
id: string
|
||||
label: string
|
||||
materialCode: string
|
||||
materialName: string
|
||||
specModel: string
|
||||
unit: string
|
||||
stockQty: number
|
||||
}
|
||||
|
||||
export function fetchQcMaterialList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
status?: string
|
||||
}) {
|
||||
return request.get<PageList<QcMaterial>>({
|
||||
url: '/web/admin/qc-materials',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchQcMaterialOptions() {
|
||||
return request.get<QcMaterialOption[]>({
|
||||
url: '/web/admin/qc-materials/options'
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchCreateQcMaterial(data: Record<string, any>) {
|
||||
return request.post<QcMaterial>({
|
||||
url: '/web/admin/qc-materials',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchUpdateQcMaterial(id: string, data: Record<string, any>) {
|
||||
return request.put<QcMaterial>({
|
||||
url: `/web/admin/qc-materials/${id}`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchDeleteQcMaterial(id: string) {
|
||||
return request.delete<void>({
|
||||
url: `/web/admin/qc-materials/${id}`
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchStockInQcMaterial(
|
||||
id: string,
|
||||
data: { qty: number; remark?: string; stockInTime?: string }
|
||||
) {
|
||||
return request.post<QcMaterial>({
|
||||
url: `/web/admin/qc-materials/${id}/stock-in`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchStockOutQcMaterial(
|
||||
id: string,
|
||||
data: {
|
||||
qty: number
|
||||
receiver?: string
|
||||
purpose?: string
|
||||
remark?: string
|
||||
stockOutTime?: string
|
||||
}
|
||||
) {
|
||||
return request.post<QcMaterial>({
|
||||
url: `/web/admin/qc-materials/${id}/stock-out`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchBatchStockInQcMaterial(data: {
|
||||
items: { materialId: string; qty: number; remark?: string }[]
|
||||
remark?: string
|
||||
stockInTime?: string
|
||||
}) {
|
||||
return request.post<{ count: number }>({
|
||||
url: '/web/admin/qc-materials/batch-stock-in',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchBatchStockOutQcMaterial(data: {
|
||||
items: { materialId: string; qty: number; remark?: string }[]
|
||||
receiver?: string
|
||||
purpose?: string
|
||||
remark?: string
|
||||
stockOutTime?: string
|
||||
}) {
|
||||
return request.post<{ count: number }>({
|
||||
url: '/web/admin/qc-materials/batch-stock-out',
|
||||
data
|
||||
})
|
||||
}
|
||||
@@ -1,46 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
export type QcTaskResultItem = {
|
||||
paramId?: string
|
||||
paramName: string
|
||||
paramCode?: string
|
||||
paramUnit?: string
|
||||
paramType: string
|
||||
paramValue: string
|
||||
}
|
||||
|
||||
export function fetchQcTaskResults(taskId: string) {
|
||||
return request.get<QcTaskResultItem[]>({
|
||||
url: `/web/admin/qc-tasks/${taskId}/results`
|
||||
})
|
||||
}
|
||||
|
||||
/** 任务已保存的物料使用(用于填写结果弹窗回显) */
|
||||
export type QcTaskMaterialUsageItem = {
|
||||
materialId: string
|
||||
materialName: string
|
||||
changeQty: number
|
||||
remark?: string
|
||||
}
|
||||
|
||||
export function fetchQcTaskMaterialUsages(taskId: string) {
|
||||
return request.get<QcTaskMaterialUsageItem[]>({
|
||||
url: `/web/admin/qc-tasks/${taskId}/material-usages`
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchCompleteTaskWithResult(
|
||||
taskId: string,
|
||||
data: {
|
||||
conclusion: string
|
||||
results: QcTaskResultItem[]
|
||||
remark?: string
|
||||
thirdPartyAttachments?: string
|
||||
materialUsages?: Array<{ materialId: string; qty: number; remark?: string }>
|
||||
}
|
||||
) {
|
||||
return request.post({
|
||||
url: `/web/admin/qc-tasks/${taskId}/complete-with-result`,
|
||||
data
|
||||
})
|
||||
}
|
||||
@@ -1,152 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
type PageList<T> = {
|
||||
list: T[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}
|
||||
|
||||
export type QcTaskReceptionDetail = {
|
||||
protocolNo?: string
|
||||
sampleCode?: string
|
||||
sampleTypeName?: string
|
||||
sourceType?: string
|
||||
sourceTypeLabel?: string
|
||||
receptionTime?: string
|
||||
handlerName?: string
|
||||
receiveTemperature?: string
|
||||
volumeMl?: number
|
||||
netWeightG?: number
|
||||
acceptConclusion?: string
|
||||
acceptConclusionLabel?: string
|
||||
remark?: string
|
||||
transportType?: string
|
||||
expressCompanyName?: string
|
||||
waybillNo?: string
|
||||
carrierName?: string
|
||||
carrierPhone?: string
|
||||
etaTime?: string
|
||||
checkResults?: Array<{ itemName?: string; checked?: boolean }>
|
||||
receiveAttachments?: string
|
||||
receiveAttachmentFiles?: Array<{
|
||||
id?: string
|
||||
fileUrl?: string
|
||||
fileName?: string
|
||||
fileType?: string
|
||||
}>
|
||||
}
|
||||
|
||||
export type QcTask = {
|
||||
id: string
|
||||
workOrderId: string
|
||||
workOrderNo?: string
|
||||
orderSource?: string
|
||||
taskNo: string
|
||||
taskType: string
|
||||
itemCode: string
|
||||
itemName: string
|
||||
companyId?: string
|
||||
companyName?: string
|
||||
feeAmount?: number
|
||||
taskStatus: string
|
||||
conclusion?: string
|
||||
conclusionLabel?: string
|
||||
qcBizType?: string
|
||||
qcBizTypeLabel?: string
|
||||
receptionSource?: string
|
||||
receptionSourceLabel?: string
|
||||
protocolNo?: string
|
||||
sampleCode?: string
|
||||
sampleTypeName?: string
|
||||
receptionTime?: string
|
||||
handlerName?: string
|
||||
workOrderStatus?: string
|
||||
cellProductId?: string
|
||||
cellProductCode?: string
|
||||
cellProductName?: string
|
||||
cellProductTypeName?: string
|
||||
cellProductPassage?: string
|
||||
cellProductSpecName?: string
|
||||
thirdPartyAttachments?: string
|
||||
attachmentFiles?: Array<{ id?: string; fileUrl: string; fileName?: string; fileType?: string }>
|
||||
completedTime?: string
|
||||
completedBy?: string
|
||||
remark?: string
|
||||
createTime?: string
|
||||
updateTime?: string
|
||||
}
|
||||
|
||||
export type QcTaskDetail = QcTask & {
|
||||
reception?: QcTaskReceptionDetail
|
||||
attachmentFiles?: Array<{ id?: string; fileUrl: string; fileName?: string }>
|
||||
results?: Array<{
|
||||
paramName: string
|
||||
paramUnit?: string
|
||||
paramType: string
|
||||
paramValue: string
|
||||
}>
|
||||
}
|
||||
|
||||
export function fetchQcTaskList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
taskType?: string
|
||||
taskStatus?: string
|
||||
workOrderId?: string
|
||||
qcBizType?: string
|
||||
}) {
|
||||
return request.get<PageList<QcTask>>({
|
||||
url: '/web/admin/qc-tasks',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchQcTaskDetail(id: string) {
|
||||
return request.get<QcTaskDetail>({
|
||||
url: `/web/admin/qc-tasks/${id}`
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchStartQcTask(id: string) {
|
||||
return request.post<QcTask>({
|
||||
url: `/web/admin/qc-tasks/${id}/start`
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchCompleteQcTask(id: string) {
|
||||
return request.post<QcTask>({
|
||||
url: `/web/admin/qc-tasks/${id}/complete`
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchUpdateQcTaskAttachments(id: string, thirdPartyAttachments: string) {
|
||||
return request.put<QcTask>({
|
||||
url: `/web/admin/qc-tasks/${id}/attachments`,
|
||||
data: { thirdPartyAttachments }
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchCreateQcTask(data: {
|
||||
taskType: string
|
||||
itemCode: string
|
||||
itemName: string
|
||||
companyId?: string
|
||||
companyName?: string
|
||||
feeAmount?: number
|
||||
sampleCode?: string
|
||||
qcBizType?: string
|
||||
workOrderId?: string
|
||||
remark?: string
|
||||
}) {
|
||||
return request.post<QcTask>({
|
||||
url: '/web/admin/qc-tasks',
|
||||
params: data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchDeleteQcTask(id: string) {
|
||||
return request.del({ url: `/web/admin/qc-tasks/${id}` })
|
||||
}
|
||||
@@ -1,92 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
type PageList<T> = {
|
||||
list: T[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}
|
||||
|
||||
export type QcThirdPartyCompany = {
|
||||
id: string
|
||||
companyCode: string
|
||||
companyName: string
|
||||
contactName?: string
|
||||
contactPhone?: string
|
||||
address?: string
|
||||
invoiceTitle?: string
|
||||
taxId?: string
|
||||
bankName?: string
|
||||
bankAccount?: string
|
||||
status: string
|
||||
orderNum: number
|
||||
remark?: string
|
||||
createTime?: string
|
||||
updateTime?: string
|
||||
}
|
||||
|
||||
export function fetchQcThirdPartyCompanyList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
status?: string
|
||||
}) {
|
||||
return request.get<PageList<QcThirdPartyCompany>>({
|
||||
url: '/web/admin/qc-third-party-companies',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchQcThirdPartyCompanyOptions() {
|
||||
return request.get<Array<{ id: string; companyCode: string; companyName: string }>>({
|
||||
url: '/web/admin/qc-third-party-companies/options'
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchCreateQcThirdPartyCompany(data: {
|
||||
companyCode: string
|
||||
companyName: string
|
||||
contactName?: string
|
||||
contactPhone?: string
|
||||
address?: string
|
||||
invoiceTitle?: string
|
||||
taxId?: string
|
||||
bankName?: string
|
||||
bankAccount?: string
|
||||
status?: string
|
||||
orderNum?: number
|
||||
remark?: string
|
||||
}) {
|
||||
return request.post<QcThirdPartyCompany>({
|
||||
url: '/web/admin/qc-third-party-companies',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchUpdateQcThirdPartyCompany(
|
||||
id: string,
|
||||
data: Partial<{
|
||||
companyCode: string
|
||||
companyName: string
|
||||
contactName: string
|
||||
contactPhone: string
|
||||
address: string
|
||||
invoiceTitle: string
|
||||
taxId: string
|
||||
bankName: string
|
||||
bankAccount: string
|
||||
status: string
|
||||
orderNum: number
|
||||
remark: string
|
||||
}>
|
||||
) {
|
||||
return request.put<QcThirdPartyCompany>({
|
||||
url: `/web/admin/qc-third-party-companies/${id}`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchDeleteQcThirdPartyCompany(id: string) {
|
||||
return request.del({ url: `/web/admin/qc-third-party-companies/${id}` })
|
||||
}
|
||||
@@ -1,80 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
type PageList<T> = {
|
||||
list: T[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}
|
||||
|
||||
export type QcThirdPartyItem = {
|
||||
id: string
|
||||
companyId: string
|
||||
companyName?: string
|
||||
itemCode: string
|
||||
itemName: string
|
||||
feeAmount: number
|
||||
status: string
|
||||
orderNum: number
|
||||
remark?: string
|
||||
createTime?: string
|
||||
updateTime?: string
|
||||
}
|
||||
|
||||
export function fetchQcThirdPartyItemList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
status?: string
|
||||
companyId?: string
|
||||
}) {
|
||||
return request.get<PageList<QcThirdPartyItem>>({
|
||||
url: '/web/admin/qc-third-party-items',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchQcThirdPartyItemsActive(companyId?: string) {
|
||||
return request.get<QcThirdPartyItem[]>({
|
||||
url: '/web/admin/qc-third-party-items/active',
|
||||
params: companyId ? { companyId } : undefined
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchCreateQcThirdPartyItem(data: {
|
||||
companyId: string
|
||||
itemCode: string
|
||||
itemName: string
|
||||
feeAmount: number
|
||||
status?: string
|
||||
orderNum?: number
|
||||
remark?: string
|
||||
}) {
|
||||
return request.post<QcThirdPartyItem>({
|
||||
url: '/web/admin/qc-third-party-items',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchUpdateQcThirdPartyItem(
|
||||
id: string,
|
||||
data: Partial<{
|
||||
companyId: string
|
||||
itemCode: string
|
||||
itemName: string
|
||||
feeAmount: number
|
||||
status: string
|
||||
orderNum: number
|
||||
remark: string
|
||||
}>
|
||||
) {
|
||||
return request.put<QcThirdPartyItem>({
|
||||
url: `/web/admin/qc-third-party-items/${id}`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchDeleteQcThirdPartyItem(id: string) {
|
||||
return request.del({ url: `/web/admin/qc-third-party-items/${id}` })
|
||||
}
|
||||
@@ -1,257 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
type PageList<T> = {
|
||||
list: T[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}
|
||||
|
||||
export type SampleReceptionCheckResult = {
|
||||
itemCode: string
|
||||
itemName: string
|
||||
checked: boolean
|
||||
checkItemId?: string
|
||||
}
|
||||
|
||||
export type QcWorkOrderReceptionDetail = {
|
||||
protocolNo?: string
|
||||
sampleCode?: string
|
||||
sampleTypeName?: string
|
||||
sourceType?: string
|
||||
sourceTypeLabel?: string
|
||||
receptionTime?: string
|
||||
handlerName?: string
|
||||
receiveTemperature?: string
|
||||
volumeMl?: number
|
||||
netWeightG?: number
|
||||
acceptConclusion?: string
|
||||
acceptConclusionLabel?: string
|
||||
remark?: string
|
||||
etaTime?: string
|
||||
transportType?: string
|
||||
expressCompanyName?: string
|
||||
waybillNo?: string
|
||||
carrierName?: string
|
||||
carrierPhone?: string
|
||||
checkResults?: SampleReceptionCheckResult[]
|
||||
receiveAttachments?: string
|
||||
receiveAttachmentFiles?: Array<{
|
||||
id?: string
|
||||
fileUrl?: string
|
||||
fileName?: string
|
||||
fileType?: string
|
||||
fileSize?: number
|
||||
fileSizeDisplay?: string
|
||||
}>
|
||||
}
|
||||
|
||||
export type QcWorkOrder = {
|
||||
id: string
|
||||
workOrderNo: string
|
||||
workOrderType?: string
|
||||
receptionId: string
|
||||
protocolSampleId: string
|
||||
collectionProtocolId: string
|
||||
protocolNo: string
|
||||
sampleCode: string
|
||||
receptionSource?: string
|
||||
receptionSourceLabel?: string
|
||||
qcBizType?: string
|
||||
qcBizTypeLabel?: string
|
||||
cellProductId?: string
|
||||
cellProductCode?: string
|
||||
cellProductName?: string
|
||||
cellProductTypeName?: string
|
||||
cellProductPassage?: string
|
||||
cellProductSpecName?: string
|
||||
sampleTypeName?: string
|
||||
receptionTime?: string
|
||||
handlerName?: string
|
||||
workOrderStatus: string
|
||||
hasLab: boolean
|
||||
hasThirdParty: boolean
|
||||
configuredTime?: string
|
||||
configuredBy?: string
|
||||
configuredByName?: string
|
||||
thirdPartyFeeTotal?: number
|
||||
remark?: string
|
||||
createTime?: string
|
||||
updateTime?: string
|
||||
bizType?: string
|
||||
bizTypeLabel?: string
|
||||
applicationNo?: string
|
||||
applicationName?: string
|
||||
channelName?: string
|
||||
/** 出库工单:患者/用户姓名 */
|
||||
patientName?: string
|
||||
/** 出库工单:当前为第几次输注计划 */
|
||||
sortNo?: number | null
|
||||
/** 出库工单:输注计划总次数 */
|
||||
totalCourseCount?: number | null
|
||||
infusionTime?: string
|
||||
}
|
||||
|
||||
export type QcWorkOrderDetail = QcWorkOrder & {
|
||||
reception?: QcWorkOrderReceptionDetail
|
||||
labItems?: Array<{ id: string; labTestItemId: string; itemCode: string; itemName: string }>
|
||||
thirdPartyItems?: Array<{
|
||||
id: string
|
||||
thirdPartyItemId: string
|
||||
companyId: string
|
||||
companyName: string
|
||||
itemCode: string
|
||||
itemName: string
|
||||
feeAmount: number
|
||||
}>
|
||||
tasks?: Array<{
|
||||
id: string
|
||||
taskNo: string
|
||||
taskType: string
|
||||
itemCode?: string
|
||||
itemName?: string
|
||||
companyId?: string
|
||||
companyName?: string
|
||||
feeAmount?: number
|
||||
taskStatus: string
|
||||
conclusion?: string
|
||||
conclusionLabel?: string
|
||||
remark?: string
|
||||
completedTime?: string
|
||||
attachmentFiles?: Array<{ id?: string; fileUrl?: string; fileName?: string }>
|
||||
}>
|
||||
}
|
||||
|
||||
export function fetchQcWorkOrderList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
workOrderStatus?: string
|
||||
workOrderType?: string
|
||||
bizType?: string
|
||||
createTimeStart?: string
|
||||
createTimeEnd?: string
|
||||
infusionTimeStart?: string
|
||||
infusionTimeEnd?: string
|
||||
}) {
|
||||
return request.get<PageList<QcWorkOrder>>({
|
||||
url: '/web/admin/qc-work-orders',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchQcWorkOrderDetail(id: string) {
|
||||
return request.get<QcWorkOrderDetail>({
|
||||
url: `/web/admin/qc-work-orders/${id}`
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchConfigureQcWorkOrder(
|
||||
id: string,
|
||||
data: {
|
||||
hasLab: boolean
|
||||
hasThirdParty: boolean
|
||||
labItemIds: string[]
|
||||
thirdPartyItemIds: string[]
|
||||
}
|
||||
) {
|
||||
return request.post<QcWorkOrder>({
|
||||
url: `/web/admin/qc-work-orders/${id}/configure`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchCreateQcWorkOrder(data: {
|
||||
workOrderType?: string
|
||||
protocolNo?: string
|
||||
sampleCode?: string
|
||||
receptionSource?: string
|
||||
qcBizType?: string
|
||||
cellProductId?: string
|
||||
remark?: string
|
||||
}) {
|
||||
return request.post<QcWorkOrder>({
|
||||
url: '/web/admin/qc-work-orders',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchUpdateQcWorkOrder(
|
||||
id: string,
|
||||
data: { cellProductId?: string; workOrderStatus?: string; remark?: string }
|
||||
) {
|
||||
return request.put<QcWorkOrder>({
|
||||
url: `/web/admin/qc-work-orders/${id}`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchDeleteQcWorkOrder(id: string) {
|
||||
return request.del({ url: `/web/admin/qc-work-orders/${id}` })
|
||||
}
|
||||
|
||||
export type OutboundQcDetailApplication = {
|
||||
applicationNo?: string
|
||||
applicationName?: string
|
||||
applicationStatus?: string
|
||||
channelName?: string
|
||||
}
|
||||
|
||||
export type OutboundQcDetailPatient = {
|
||||
patientName?: string
|
||||
sex?: string
|
||||
age?: string
|
||||
phoneNo?: string
|
||||
idCardNo?: string
|
||||
emergencyContact?: string
|
||||
emergencyPhone?: string
|
||||
clinicalDiagnosis?: string
|
||||
diagnosisAttachments?: string
|
||||
}
|
||||
|
||||
export type OutboundQcDetailInfusionPlan = {
|
||||
cellType?: string
|
||||
specText?: string
|
||||
totalCourseCount?: number
|
||||
courseInterval?: string
|
||||
infusionRoute?: string
|
||||
infusionStartDate?: string
|
||||
}
|
||||
|
||||
export type OutboundQcDetailInfusionSchedule = {
|
||||
infusionTime?: string
|
||||
infusionLocation?: string
|
||||
infusionMethod?: string
|
||||
scheduleStatus?: string
|
||||
infusionStatus?: string
|
||||
qcStatus?: string
|
||||
cancelReason?: string
|
||||
}
|
||||
|
||||
export type OutboundQcDetailProduct = {
|
||||
projectCode?: string
|
||||
projectName?: string
|
||||
cellTypeName?: string
|
||||
specText?: string
|
||||
agreementPrice?: number
|
||||
actualPrice?: number
|
||||
quantity?: number
|
||||
productStatus?: string
|
||||
}
|
||||
|
||||
export type OutboundQcDetail = {
|
||||
workOrder: QcWorkOrderDetail
|
||||
application?: OutboundQcDetailApplication
|
||||
patient?: OutboundQcDetailPatient
|
||||
infusionPlan?: OutboundQcDetailInfusionPlan
|
||||
infusionSchedule?: OutboundQcDetailInfusionSchedule
|
||||
products?: OutboundQcDetailProduct[]
|
||||
tasks?: QcWorkOrderDetail['tasks']
|
||||
}
|
||||
|
||||
export function fetchOutboundQcDetail(id: string) {
|
||||
return request.get<OutboundQcDetail>({
|
||||
url: `/web/admin/qc-work-orders/${id}/outbound-detail`
|
||||
})
|
||||
}
|
||||
@@ -1,132 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
type PageList<T> = {
|
||||
list: T[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}
|
||||
|
||||
export type ResearchDonationRow = Record<string, unknown>
|
||||
|
||||
// 列表
|
||||
export function fetchResearchDonationList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
donationStatus?: string
|
||||
createTimeStart?: string
|
||||
createTimeEnd?: string
|
||||
sampleCollectTimeStart?: string
|
||||
sampleCollectTimeEnd?: string
|
||||
}) {
|
||||
return request.get<PageList<ResearchDonationRow>>({
|
||||
url: '/web/admin/research-donations',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
// 详情
|
||||
export function fetchResearchDonationDetail(id: string) {
|
||||
return request.get<{
|
||||
donation: Record<string, unknown>
|
||||
party: Record<string, unknown> | null
|
||||
collection: Record<string, unknown> | null
|
||||
samples: Array<Record<string, unknown>> | null
|
||||
attachments?: Array<Record<string, unknown>>
|
||||
}>({
|
||||
url: `/web/admin/research-donations/${id}`
|
||||
})
|
||||
}
|
||||
|
||||
// 创建
|
||||
export function fetchCreateResearchDonation(data: Record<string, unknown>) {
|
||||
return request.post({
|
||||
url: '/web/admin/research-donations',
|
||||
data,
|
||||
showSuccessMessage: true
|
||||
})
|
||||
}
|
||||
|
||||
// 更新
|
||||
export function fetchUpdateResearchDonation(id: string, data: Record<string, unknown>) {
|
||||
return request.put({
|
||||
url: `/web/admin/research-donations/${id}`,
|
||||
data,
|
||||
showSuccessMessage: true
|
||||
})
|
||||
}
|
||||
|
||||
// 删除
|
||||
export function fetchDeleteResearchDonation(id: string) {
|
||||
return request.del({
|
||||
url: `/web/admin/research-donations/${id}`,
|
||||
showSuccessMessage: true
|
||||
})
|
||||
}
|
||||
|
||||
// 批量删除
|
||||
export function fetchBatchDeleteResearchDonation(ids: string[]) {
|
||||
return request.post({
|
||||
url: '/web/admin/research-donations/batch-delete',
|
||||
data: { ids },
|
||||
showSuccessMessage: true
|
||||
})
|
||||
}
|
||||
|
||||
// 审核列表
|
||||
export function fetchResearchDonationAuditList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
auditStatus?: string
|
||||
}) {
|
||||
return request.get<PageList<Record<string, unknown>>>({
|
||||
url: '/web/admin/research-donations/audits',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
// 提交审核
|
||||
export function fetchSubmitDonationAudit(
|
||||
donationId: string,
|
||||
data: { auditStatus: string; auditRemark?: string },
|
||||
options?: { showSuccessMessage?: boolean }
|
||||
) {
|
||||
return request.post({
|
||||
url: `/web/admin/research-donations/${donationId}/audit`,
|
||||
data,
|
||||
showSuccessMessage: options?.showSuccessMessage ?? true
|
||||
})
|
||||
}
|
||||
|
||||
// 状态变更
|
||||
export function fetchDonationStatusChange(
|
||||
donationId: string,
|
||||
data: { newStatus: string; desc?: string; timeVal?: string }
|
||||
) {
|
||||
return request.post({
|
||||
url: `/web/admin/research-donations/${donationId}/status-change`,
|
||||
data,
|
||||
showSuccessMessage: true
|
||||
})
|
||||
}
|
||||
|
||||
// 从细胞存储转化
|
||||
export function fetchConvertFromStorage(protocolId: string) {
|
||||
return request.post({
|
||||
url: '/web/admin/research-donations/convert-from-storage',
|
||||
data: { protocolId },
|
||||
showSuccessMessage: true
|
||||
})
|
||||
}
|
||||
|
||||
// 转为细胞存储
|
||||
export function fetchConvertToStorage(donationId: string, data?: { desc?: string }) {
|
||||
return request.post({
|
||||
url: `/web/admin/research-donations/${donationId}/convert-to-storage`,
|
||||
data: data || {},
|
||||
showSuccessMessage: true
|
||||
})
|
||||
}
|
||||
@@ -1,73 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
type PageList<T> = {
|
||||
list: T[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}
|
||||
|
||||
export type SampleReceptionCheckItem = {
|
||||
id: string
|
||||
itemCode: string
|
||||
itemName: string
|
||||
status: string
|
||||
orderNum: number
|
||||
remark?: string
|
||||
createTime?: string
|
||||
updateTime?: string
|
||||
}
|
||||
|
||||
export function fetchSampleReceptionCheckItemList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
status?: string
|
||||
}) {
|
||||
return request.get<PageList<SampleReceptionCheckItem>>({
|
||||
url: '/web/admin/sample-reception-check-items',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchSampleReceptionCheckItemsActive() {
|
||||
return request.get<SampleReceptionCheckItem[]>({
|
||||
url: '/web/admin/sample-reception-check-items/active'
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchCreateSampleReceptionCheckItem(data: {
|
||||
itemCode: string
|
||||
itemName: string
|
||||
status?: string
|
||||
orderNum?: number
|
||||
remark?: string
|
||||
}) {
|
||||
return request.post<SampleReceptionCheckItem>({
|
||||
url: '/web/admin/sample-reception-check-items',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchUpdateSampleReceptionCheckItem(
|
||||
id: string,
|
||||
data: {
|
||||
itemCode?: string
|
||||
itemName?: string
|
||||
status?: string
|
||||
orderNum?: number
|
||||
remark?: string
|
||||
}
|
||||
) {
|
||||
return request.put<SampleReceptionCheckItem>({
|
||||
url: `/web/admin/sample-reception-check-items/${id}`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchDeleteSampleReceptionCheckItem(id: string) {
|
||||
return request.del({
|
||||
url: `/web/admin/sample-reception-check-items/${id}`
|
||||
})
|
||||
}
|
||||
@@ -1,94 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
type PageList<T> = {
|
||||
list: T[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}
|
||||
|
||||
export function fetchSampleReceptionPendingList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
sourceType?: string
|
||||
etaTimeStart?: string
|
||||
etaTimeEnd?: string
|
||||
}) {
|
||||
return request.get<PageList<Record<string, unknown>>>({
|
||||
url: '/web/admin/sample-receptions/pending',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchSampleReceptionReceivedList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
sourceType?: string
|
||||
receptionTimeStart?: string
|
||||
receptionTimeEnd?: string
|
||||
}) {
|
||||
return request.get<PageList<Record<string, unknown>>>({
|
||||
url: '/web/admin/sample-receptions/received',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchSampleReceptionDetail(receptionId: string) {
|
||||
return request.get<Record<string, unknown>>({
|
||||
url: `/web/admin/sample-receptions/${receptionId}`
|
||||
})
|
||||
}
|
||||
|
||||
export type SampleReceptionCheckResult = {
|
||||
id?: string
|
||||
checkItemId?: string
|
||||
itemCode: string
|
||||
itemName: string
|
||||
checked: boolean
|
||||
orderNum?: number
|
||||
}
|
||||
|
||||
export function fetchSampleReceptionUpdate(
|
||||
receptionId: string,
|
||||
data: {
|
||||
receptionTime: string
|
||||
handlerUserId?: string
|
||||
handlerName?: string
|
||||
receiveTemperature?: string
|
||||
volumeMl?: number
|
||||
netWeightG?: number
|
||||
checks: Array<{ checkItemId: string; checked: boolean }>
|
||||
acceptConclusion: 'js' | 'bj'
|
||||
receiveAttachments?: string
|
||||
remark?: string
|
||||
}
|
||||
) {
|
||||
return request.put({
|
||||
url: `/web/admin/sample-receptions/${receptionId}`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchSampleReceptionSubmit(data: {
|
||||
protocolSampleId?: string
|
||||
sourceType?: 'cell_storage' | 'research_donation'
|
||||
donationSampleId?: string
|
||||
receptionTime: string
|
||||
handlerUserId?: string
|
||||
handlerName?: string
|
||||
receiveTemperature?: string
|
||||
volumeMl?: number
|
||||
netWeightG?: number
|
||||
checks: Array<{ checkItemId: string; checked: boolean }>
|
||||
acceptConclusion: 'js' | 'bj'
|
||||
receiveAttachments?: string
|
||||
remark?: string
|
||||
}) {
|
||||
return request.post({
|
||||
url: '/web/admin/sample-receptions',
|
||||
data
|
||||
})
|
||||
}
|
||||
@@ -1,44 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
type PageList<T> = {
|
||||
list: T[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}
|
||||
|
||||
/** 查询列表(联查 sample_reception + sms_notification) */
|
||||
export function fetchSampleSmsNotificationList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
acceptConclusion?: string
|
||||
smsNotified?: string
|
||||
receptionTimeStart?: string
|
||||
receptionTimeEnd?: string
|
||||
}) {
|
||||
return request.get<PageList<Record<string, unknown>>>({
|
||||
url: '/web/admin/sample-sms-notifications/list',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
/** 切换通知状态 */
|
||||
export function fetchToggleSmsNotified(
|
||||
id: string,
|
||||
data: { smsNotified: number; sampleReceptionId?: string }
|
||||
) {
|
||||
return request.put({
|
||||
url: `/web/admin/sample-sms-notifications/${id}/toggle-status`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
/** 生成短信内容 */
|
||||
export function fetchGenerateSms(id: string, sampleReceptionId?: string) {
|
||||
return request.post<{ smsContent: string }>({
|
||||
url: `/web/admin/sample-sms-notifications/${id}/generate-sms`,
|
||||
params: sampleReceptionId ? { sampleReceptionId } : undefined
|
||||
})
|
||||
}
|
||||
@@ -1,44 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
type PageList<T> = {
|
||||
list: T[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}
|
||||
|
||||
/** 查询列表(联查 storage_release_review + sms_notification) */
|
||||
export function fetchStorageEntrySmsList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
keyword?: string
|
||||
storageStatus?: string
|
||||
smsNotified?: string
|
||||
storageTimeStart?: string
|
||||
storageTimeEnd?: string
|
||||
}) {
|
||||
return request.get<PageList<Record<string, unknown>>>({
|
||||
url: '/web/admin/storage-entry-sms-notifications/list',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
/** 切换通知状态 */
|
||||
export function fetchToggleStorageEntrySmsNotified(
|
||||
id: string,
|
||||
data: { smsNotified: number; storageReviewId?: string }
|
||||
) {
|
||||
return request.put({
|
||||
url: `/web/admin/storage-entry-sms-notifications/${id}/toggle-status`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
/** 生成短信内容 */
|
||||
export function fetchGenerateStorageEntrySms(id: string, storageReviewId?: string) {
|
||||
return request.post<{ smsContent: string }>({
|
||||
url: `/web/admin/storage-entry-sms-notifications/${id}/generate-sms`,
|
||||
params: storageReviewId ? { storageReviewId } : undefined
|
||||
})
|
||||
}
|
||||
@@ -1,177 +0,0 @@
|
||||
import request from '@/utils/http'
|
||||
import type { QcWorkOrderReceptionDetail } from '@/api/qc-work-order'
|
||||
|
||||
type PageList<T> = {
|
||||
list: T[]
|
||||
total: number
|
||||
page: number
|
||||
pageSize: number
|
||||
totalPages: number
|
||||
}
|
||||
|
||||
export type StorageReleaseReview = {
|
||||
id: string
|
||||
sampleCode?: string
|
||||
sampleName?: string
|
||||
protocolNo?: string
|
||||
receptionSource?: string
|
||||
receptionSourceLabel?: string
|
||||
reviewConclusion?: string
|
||||
reviewConclusionLabel?: string
|
||||
reviewRemark?: string
|
||||
reviewAttachments?: string
|
||||
reviewBy?: string
|
||||
reviewByName?: string
|
||||
reviewTime?: string
|
||||
storageStatus?: string
|
||||
storageStatusLabel?: string
|
||||
sampleTypeName?: string
|
||||
handlerName?: string
|
||||
receptionTime?: string
|
||||
motherName?: string
|
||||
protocolStatus?: string
|
||||
protocolStatusLabel?: string
|
||||
storageBy?: string
|
||||
storageByName?: string
|
||||
storageTime?: string
|
||||
remark?: string
|
||||
createTime?: string
|
||||
updateTime?: string
|
||||
}
|
||||
|
||||
export type ProtocolInfo = {
|
||||
protocolNo?: string
|
||||
protocolStatus?: string
|
||||
motherName?: string
|
||||
motherPhone?: string
|
||||
fatherName?: string
|
||||
fatherPhone?: string
|
||||
newbornName?: string
|
||||
sampleCode?: string
|
||||
sampleTypeName?: string
|
||||
collectAmount?: number | null
|
||||
storageYears?: number | null
|
||||
}
|
||||
|
||||
export type TransportInfo = {
|
||||
transportType?: string
|
||||
waybillNo?: string
|
||||
expressFee?: number | null
|
||||
etaTime?: string
|
||||
carrierName?: string
|
||||
carrierPhone?: string
|
||||
}
|
||||
|
||||
export type ReceptionInfo = {
|
||||
receptionTime?: string
|
||||
handlerName?: string
|
||||
receiveTemperature?: string
|
||||
volumeMl?: number | null
|
||||
netWeightG?: number | null
|
||||
acceptConclusion?: string
|
||||
}
|
||||
|
||||
export type QcInfoTask = {
|
||||
id?: string
|
||||
taskType?: string
|
||||
taskTypeLabel?: string
|
||||
taskStatus?: string
|
||||
taskStatusLabel?: string
|
||||
conclusion?: string
|
||||
conclusionLabel?: string
|
||||
}
|
||||
|
||||
export type QcInfo = {
|
||||
workOrderNo?: string
|
||||
workOrderStatus?: string
|
||||
workOrderStatusLabel?: string
|
||||
tasks?: QcInfoTask[]
|
||||
}
|
||||
|
||||
export type ProductionInfoTask = {
|
||||
id?: string
|
||||
taskNo?: string
|
||||
taskName?: string
|
||||
taskStatus?: string
|
||||
taskStatusLabel?: string
|
||||
conclusion?: string
|
||||
conclusionLabel?: string
|
||||
startedTime?: string
|
||||
completedTime?: string
|
||||
}
|
||||
|
||||
export type ProductionInfo = {
|
||||
workOrderNo?: string
|
||||
workOrderStatus?: string
|
||||
workOrderStatusLabel?: string
|
||||
tasks?: ProductionInfoTask[]
|
||||
}
|
||||
|
||||
export type StorageReleaseReviewDetail = {
|
||||
review: StorageReleaseReview
|
||||
protocolInfo?: ProtocolInfo
|
||||
transportInfo?: TransportInfo
|
||||
receptionInfo?: ReceptionInfo
|
||||
reception?: QcWorkOrderReceptionDetail
|
||||
qcInfo?: QcInfo
|
||||
productionInfo?: ProductionInfo
|
||||
}
|
||||
|
||||
export function fetchStorageReleaseReviewList(params?: {
|
||||
page?: number
|
||||
pageSize?: number
|
||||
receptionSource?: string
|
||||
reviewConclusion?: string
|
||||
storageStatus?: string
|
||||
keyword?: string
|
||||
}) {
|
||||
return request.get<PageList<StorageReleaseReview>>({
|
||||
url: '/web/admin/storage-release-reviews',
|
||||
params
|
||||
})
|
||||
}
|
||||
|
||||
export function fetchStorageReleaseReviewDetail(id: string) {
|
||||
return request.get<StorageReleaseReviewDetail>({
|
||||
url: `/web/admin/storage-release-reviews/${id}`
|
||||
})
|
||||
}
|
||||
|
||||
export function submitStorageReleaseReview(
|
||||
id: string,
|
||||
data: {
|
||||
reviewConclusion: string
|
||||
reviewRemark?: string
|
||||
reviewAttachments?: string
|
||||
}
|
||||
) {
|
||||
return request.put<StorageReleaseReview>({
|
||||
url: `/web/admin/storage-release-reviews/${id}/review`,
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function batchReviewStorageRelease(data: {
|
||||
ids: string[]
|
||||
reviewConclusion: string
|
||||
reviewRemark?: string
|
||||
reviewAttachments?: string
|
||||
}) {
|
||||
return request.put<void>({
|
||||
url: '/web/admin/storage-release-reviews/batch-review',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function storeSample(id: string) {
|
||||
return request.put<StorageReleaseReview>({
|
||||
url: `/web/admin/storage-release-reviews/${id}/store`
|
||||
})
|
||||
}
|
||||
|
||||
export function batchStoreSample(data: { ids: string[] }) {
|
||||
return request.put<void>({
|
||||
url: '/web/admin/storage-release-reviews/batch-store',
|
||||
data
|
||||
})
|
||||
}
|
||||
Reference in new issue
Block a user