tenant: admin order export csv
This commit is contained in:
@@ -187,6 +187,18 @@ definitions:
|
||||
- $ref: '#/definitions/models.Order'
|
||||
description: Order is the order with items preloaded.
|
||||
type: object
|
||||
dto.AdminOrderExportResponse:
|
||||
properties:
|
||||
content_type:
|
||||
description: ContentType 内容类型:当前固定为 text/csv。
|
||||
type: string
|
||||
csv:
|
||||
description: CSV CSV 文本内容:UTF-8 编码,包含表头与数据行;前端可直接下载为文件。
|
||||
type: string
|
||||
filename:
|
||||
description: Filename 建议文件名:前端可用于下载时的默认文件名。
|
||||
type: string
|
||||
type: object
|
||||
dto.AdminOrderRefundForm:
|
||||
properties:
|
||||
force:
|
||||
@@ -1926,6 +1938,112 @@ paths:
|
||||
summary: 订单退款(租户管理)
|
||||
tags:
|
||||
- Tenant
|
||||
/t/{tenantCode}/v1/admin/orders/export:
|
||||
get:
|
||||
consumes:
|
||||
- application/json
|
||||
parameters:
|
||||
- description: Tenant Code
|
||||
in: path
|
||||
name: tenantCode
|
||||
required: true
|
||||
type: string
|
||||
- description: AmountPaidMax 实付金额上限(可选):amount_paid <= 该值(单位分)。
|
||||
in: query
|
||||
name: amount_paid_max
|
||||
type: integer
|
||||
- description: AmountPaidMin 实付金额下限(可选):amount_paid >= 该值(单位分)。
|
||||
in: query
|
||||
name: amount_paid_min
|
||||
type: integer
|
||||
- description: Asc specifies comma-separated field names to sort ascending by.
|
||||
in: query
|
||||
name: asc
|
||||
type: string
|
||||
- description: ContentID 内容ID(可选):通过 order_items 关联过滤。
|
||||
in: query
|
||||
name: content_id
|
||||
type: integer
|
||||
- description: ContentTitle 内容标题关键字(可选):通过 order_items + contents 关联,模糊匹配 contents.title(like)。
|
||||
in: query
|
||||
name: content_title
|
||||
type: string
|
||||
- description: CreatedAtFrom 创建时间起(可选):created_at >= 该时间(用于按创建时间筛选)。
|
||||
in: query
|
||||
name: created_at_from
|
||||
type: string
|
||||
- description: CreatedAtTo 创建时间止(可选):created_at <= 该时间(用于按创建时间筛选)。
|
||||
in: query
|
||||
name: created_at_to
|
||||
type: string
|
||||
- description: Desc specifies comma-separated field names to sort descending
|
||||
by.
|
||||
in: query
|
||||
name: desc
|
||||
type: string
|
||||
- description: Limit is page size; only values in {10,20,50,100} are accepted
|
||||
(otherwise defaults to 10).
|
||||
in: query
|
||||
name: limit
|
||||
type: integer
|
||||
- description: Page is 1-based page index; values <= 0 are normalized to 1.
|
||||
in: query
|
||||
name: page
|
||||
type: integer
|
||||
- description: PaidAtFrom 支付时间起(可选):paid_at >= 该时间(用于按支付时间筛选)。
|
||||
in: query
|
||||
name: paid_at_from
|
||||
type: string
|
||||
- description: PaidAtTo 支付时间止(可选):paid_at <= 该时间(用于按支付时间筛选)。
|
||||
in: query
|
||||
name: paid_at_to
|
||||
type: string
|
||||
- description: Status 订单状态(可选):created/paid/refunding/refunded/canceled/failed。
|
||||
enum:
|
||||
- created
|
||||
- paid
|
||||
- refunding
|
||||
- refunded
|
||||
- canceled
|
||||
- failed
|
||||
in: query
|
||||
name: status
|
||||
type: string
|
||||
x-enum-varnames:
|
||||
- OrderStatusCreated
|
||||
- OrderStatusPaid
|
||||
- OrderStatusRefunding
|
||||
- OrderStatusRefunded
|
||||
- OrderStatusCanceled
|
||||
- OrderStatusFailed
|
||||
- description: Type 订单类型(可选):content_purchase/topup 等。
|
||||
enum:
|
||||
- content_purchase
|
||||
- topup
|
||||
in: query
|
||||
name: type
|
||||
type: string
|
||||
x-enum-varnames:
|
||||
- OrderTypeContentPurchase
|
||||
- OrderTypeTopup
|
||||
- description: UserID 下单用户ID(可选):按买家用户ID精确过滤。
|
||||
in: query
|
||||
name: user_id
|
||||
type: integer
|
||||
- description: Username 下单用户用户名关键字(可选):模糊匹配 users.username(like)。
|
||||
in: query
|
||||
name: username
|
||||
type: string
|
||||
produces:
|
||||
- application/json
|
||||
responses:
|
||||
"200":
|
||||
description: OK
|
||||
schema:
|
||||
$ref: '#/definitions/dto.AdminOrderExportResponse'
|
||||
summary: 订单导出(租户管理)
|
||||
tags:
|
||||
- Tenant
|
||||
/t/{tenantCode}/v1/admin/users:
|
||||
get:
|
||||
consumes:
|
||||
|
||||
Reference in New Issue
Block a user