diff --git a/src/api/shop/order.ts b/src/api/shop/order.ts index 888dfd6..1ab09c0 100644 --- a/src/api/shop/order.ts +++ b/src/api/shop/order.ts @@ -136,4 +136,57 @@ export const exportOrderExcelApi = (params: OrderQuery, fileName: string) => { payTime: params?.payTime ? params.payTime : undefined } }); +}; + +export interface BorrowReturnRecordQuery extends BasePageQuery { + /** 商品ID */ + goodsId?: number; + /** + * 状态 + * @remarks + * 0-未退还 | 1-待审批 | 2-已通过 | 3-已驳回 + */ + status?: number; +} + +export interface BorrowReturnRecordDTO { + /** 订单ID */ + orderId: number; + /** 审批ID */ + approvalId?: number; + /** 订单创建时间 */ + orderTime?: Date; + /** 归还图片 */ + returnImages?: string; + /** 审核图片 */ + auditImages?: string; + /** 订单商品价格 */ + goodsPrice: number; + /** 支付方式 */ + paymentMethod?: string; + /** 订单姓名 */ + orderName?: string; + /** 订单手机号 */ + orderMobile?: string; + /** 订单商品数量 */ + quantity: number; + /** 审批人 */ + auditName?: string; + /** 审核说明 */ + auditRemark?: string; + /** + * 状态 + * @remarks + * 0-未退还 | 1-待审批 | 2-已通过 | 3-已驳回 + */ + status: number; + /** 状态描述 */ + statusStr: string; +} + +/** 获取借还记录分页列表 */ +export const getBorrowReturnRecordListApi = (params?: BorrowReturnRecordQuery) => { + return http.request>>("get", "/shop/order/borrow-return-record", { + params + }); }; \ No newline at end of file diff --git a/src/views/shop/goods/borrow-return-record.vue b/src/views/shop/goods/borrow-return-record.vue new file mode 100644 index 0000000..d658e5a --- /dev/null +++ b/src/views/shop/goods/borrow-return-record.vue @@ -0,0 +1,180 @@ + + + + + diff --git a/src/views/shop/goods/detail.vue b/src/views/shop/goods/detail.vue index 41d3f1c..d7f3e37 100644 --- a/src/views/shop/goods/detail.vue +++ b/src/views/shop/goods/detail.vue @@ -7,6 +7,7 @@ import { ElMessage } from "element-plus"; import { useRenderIcon } from '@/components/ReIcon/src/hooks'; import EditPen from '@iconify-icons/ep/edit-pen'; import GoodsEditModal from "./goods-edit-modal.vue"; +import BorrowReturnRecord from "./borrow-return-record.vue"; import { useBtnPermissionStore } from "@/store/modules/btnPermission"; const handleEdit = (row: GoodsDTO) => { @@ -120,6 +121,7 @@ watch(goodsId, () => { + @@ -197,6 +199,10 @@ watch(goodsId, () => {
+ +
+ +