/** * 店铺套餐分配 API 服务 */ import { BaseService } from '../BaseService' import type { BaseResponse, CreateShopPackageAllocationRequest, ShopPackageAllocationResponse, UpdateShopPackageAllocationExpiryBaseRequest } from '@/types/api' export class ShopPackageAllocationService extends BaseService { /** * 创建店铺套餐分配 * POST /api/admin/shop-package-allocations */ static createShopPackageAllocation( data: CreateShopPackageAllocationRequest ): Promise> { return this.post>( '/api/admin/shop-package-allocations', data ) } /** * 更新店铺套餐分配生效条件 * PATCH /api/admin/shop-package-allocations/{id}/expiry-base */ static updateShopPackageAllocationExpiryBase( id: number, data: UpdateShopPackageAllocationExpiryBaseRequest ): Promise> { return this.patch>( `/api/admin/shop-package-allocations/${id}/expiry-base`, data ) } }