diff --git a/components.d.ts b/components.d.ts index 4d00738..3088a38 100644 --- a/components.d.ts +++ b/components.d.ts @@ -14,7 +14,6 @@ declare module 'vue' { ArtBreadcrumb: typeof import('./src/components/core/layouts/art-breadcrumb/index.vue')['default'] ArtButtonMore: typeof import('./src/components/core/forms/ArtButtonMore.vue')['default'] ArtButtonTable: typeof import('./src/components/core/forms/ArtButtonTable.vue')['default'] - ArtCardBanner: typeof import('./src/components/core/banners/ArtCardBanner.vue')['default'] ArtChatWindow: typeof import('./src/components/core/layouts/art-chat-window/index.vue')['default'] ArtCutterImg: typeof import('./src/components/core/media/ArtCutterImg.vue')['default'] ArtDataListCard: typeof import('./src/components/core/cards/ArtDataListCard.vue')['default'] diff --git a/openspec/changes/add-asset-gateway-extend-display/proposal.md b/openspec/changes/add-asset-gateway-extend-display/proposal.md index 1df5cd1..71f7922 100644 --- a/openspec/changes/add-asset-gateway-extend-display/proposal.md +++ b/openspec/changes/add-asset-gateway-extend-display/proposal.md @@ -5,6 +5,7 @@ 当前后台“资产信息”页还没有消费接口新增的 `gateway_extend` 字段,因此运营人员无法在资产详情中直接看到运营商侧实际停机原因。 最新接口契约已经补充两类返回: + - 设备资产的绑定卡列表项新增 `gateway_extend` - 卡资产详情新增 `gateway_extend` diff --git a/openspec/changes/add-payment-configuration-management/design.md b/openspec/changes/add-payment-configuration-management/design.md index 5ad6b18..ac8451d 100644 --- a/openspec/changes/add-payment-configuration-management/design.md +++ b/openspec/changes/add-payment-configuration-management/design.md @@ -33,15 +33,19 @@ ## Decisions - Decision: 能力名称使用 `payment-configuration-management`,而不是沿用页面路径中的 `wechat-config` + - Rationale: 该能力已经覆盖微信、小程序、公众号、支付宝和富友相关字段,业务边界明显大于“微信配置”。 - Decision: `provider_type` 在本次 spec 中严格按文档限定为 `wechat`、`wechat_v2`、`fuiou` + - Rationale: 这是文档明确枚举出的渠道主类型,spec 不应凭猜测新增 `alipay`。 - Decision: `ali_*` 字段在本次 spec 中被视为支付配置对象支持的可选扩展字段,但不单独引入新的 `provider_type` + - Rationale: 文档已经明确给出这些字段;在没有更正枚举之前,先把它们作为统一字段模型的一部分记录下来。 - Decision: 所有读取响应中的敏感信息都必须采用脱敏或配置状态标记,不能返回明文密钥 + - Rationale: 文档的详情和当前生效配置示例已经给出了 `***`、`已配置`、`未配置` 这类语义。 - Decision: 更新接口采用部分更新语义,只要求提交实际需要修改的字段 @@ -50,6 +54,7 @@ ## Risks / Trade-offs - 风险: 当前前端类型定义尚未覆盖 `ali_*` 字段,按 spec 对齐后会触发类型和页面联动修改。 + - Mitigation: 实施时先调整 `src/types/api/wechatConfig.ts`,再逐步修改列表、表单和详情展示。 - 风险: 文档没有给出“如何切换当前生效配置”的写接口,只有 `is_active` 状态和 `/active` 查询接口。 diff --git a/openspec/changes/update-device-activation-status-filter-and-display/proposal.md b/openspec/changes/update-device-activation-status-filter-and-display/proposal.md index 26f86dc..cdd5965 100644 --- a/openspec/changes/update-device-activation-status-filter-and-display/proposal.md +++ b/openspec/changes/update-device-activation-status-filter-and-display/proposal.md @@ -5,6 +5,7 @@ 当前后台设备管理和企业设备授权流程还没有完整接入新的设备激活状态字段,导致运营人员无法按“已激活 / 未激活”筛选设备,也无法在资产详情中直接看到设备激活状态名称。 最新接口契约补充了以下内容: + - 设备列表接口新增可选过滤参数 `activation_status` - 设备列表与资产解析相关响应新增 `activation_status_name` - 企业设备授权弹窗中的可选设备列表也需要沿用这套激活状态筛选与展示规则 diff --git a/openspec/changes/update-exchange-flow-direct-type/design.md b/openspec/changes/update-exchange-flow-direct-type/design.md index d1f6a33..8b93cfd 100644 --- a/openspec/changes/update-exchange-flow-direct-type/design.md +++ b/openspec/changes/update-exchange-flow-direct-type/design.md @@ -26,7 +26,7 @@ ```typescript export enum ExchangeFlowType { SHIPPING = 'shipping', // 物流换货 - DIRECT = 'direct' // 直接换货 + DIRECT = 'direct' // 直接换货 } export const EXCHANGE_FLOW_TYPE_MAP = { @@ -47,6 +47,7 @@ export const EXCHANGE_FLOW_TYPE_MAP = { **Rationale**: 符合 Element Plus 表单最佳实践,避免不必要的字段提交。 **Alternatives considered**: + - 使用 `v-show` 隐藏:会导致隐藏字段仍参与表单验证 - 使用动态表单项:增加复杂度,不够直观 @@ -55,16 +56,16 @@ export const EXCHANGE_FLOW_TYPE_MAP = { 在详情页组件中定义计算属性: ```typescript -const canShip = computed(() => - exchange.value.flow_type === 'shipping' && exchange.value.status === 2 +const canShip = computed( + () => exchange.value.flow_type === 'shipping' && exchange.value.status === 2 ) -const canComplete = computed(() => - exchange.value.flow_type === 'shipping' && exchange.value.status === 3 +const canComplete = computed( + () => exchange.value.flow_type === 'shipping' && exchange.value.status === 3 ) -const canCancel = computed(() => - exchange.value.flow_type === 'shipping' && [1, 2].includes(exchange.value.status) +const canCancel = computed( + () => exchange.value.flow_type === 'shipping' && [1, 2].includes(exchange.value.status) ) ``` @@ -78,6 +79,7 @@ const canCancel = computed(() => - **原因**: direct 类型这些字段为 null,显示空白区块或"不适用"会造成页面冗余 **Alternatives considered**: + - 显示"不适用"占位:增加不必要的视觉噪音 - 显示空区块:用户体验不佳 @@ -105,6 +107,7 @@ const flowType = exchange.flow_type || 'shipping' 引入流程类型后,详情页的条件渲染逻辑增多。 **Mitigation**: + - 使用计算属性封装权限判断逻辑 - 添加单元测试覆盖不同流程类型的渲染场景 diff --git a/src/api/articleApi.ts b/src/api/articleApi.ts deleted file mode 100644 index 623cf61..0000000 --- a/src/api/articleApi.ts +++ /dev/null @@ -1,45 +0,0 @@ -import request from '@/utils/http' -import { PaginationResponse, BaseResponse } from '@/types/api' -import { ArticleType, ArticleCategoryType, ArticleQueryParams } from '@/api/modules' - -// 文章 -export class ArticleService { - // 获取文章列表 - static getArticleList(params: ArticleQueryParams) { - const { page, size, searchVal, year } = params - return request.get>({ - url: `/api/articles/${page}/${size}?title=${searchVal}&year=${year}` - }) - } - - // 获取文章类型 - static getArticleTypes(params: object) { - return request.get>({ - url: '/api/articles/types', - params - }) - } - - // 获取文章详情 - static getArticleDetail(id: number) { - return request.get>({ - url: `/api/articles/${id}` - }) - } - - // 新增文章 - static addArticle(params: any) { - return request.post({ - url: '/api/articles/', - data: params - }) - } - - // 编辑文章 - static editArticle(id: number, params: any) { - return request.put({ - url: `/api/articles/${id}`, - data: params - }) - } -} diff --git a/src/api/menuApi.ts b/src/api/menuApi.ts deleted file mode 100644 index b0a458b..0000000 --- a/src/api/menuApi.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { asyncRoutes } from '@/router/routes/asyncRoutes' -import { menuDataToRouter } from '@/router/utils/menuToRouter' -import { AppRouteRecord } from '@/types/router' - -interface MenuResponse { - menuList: AppRouteRecord[] -} - -// 菜单接口 -export const menuService = { - async getMenuList(delay = 300): Promise { - try { - // 模拟接口返回的菜单数据 - const menuData = asyncRoutes - // 处理菜单数据 - const menuList = menuData.map((route) => menuDataToRouter(route)) - // 模拟接口延迟 - await new Promise((resolve) => setTimeout(resolve, delay)) - - return { menuList } - } catch (error) { - throw error instanceof Error ? error : new Error('获取菜单失败') - } - } -} diff --git a/src/api/modules/article.ts b/src/api/modules/article.ts deleted file mode 100644 index c457433..0000000 --- a/src/api/modules/article.ts +++ /dev/null @@ -1,72 +0,0 @@ -/** - * 文章相关类型定义 - */ - -// 文章类型 (新命名规范) -export interface Article { - id?: number - blogClass: string - title: string - count?: number - htmlContent: string - createTime: string - homeImg: string - brief: string - typeName?: string - status?: number - author?: string - tags?: string[] -} - -// 兼容原有的文章类型命名 -export interface ArticleType { - id?: number - blog_class: string - title: string - count?: number - html_content: string - create_time: string - home_img: string - brief: string - type_name?: string -} - -// 文章分类类型 (新命名规范) -export interface ArticleCategory { - id: number - name: string - icon: string - count: number - description?: string - sortOrder?: number -} - -// 兼容原有的文章分类类型命名 -export interface ArticleCategoryType { - id: number - name: string - icon: string - count: number -} - -// 文章查询参数 -export interface ArticleQueryParams { - page?: number - size?: number - searchVal?: string - year?: string - categoryId?: number - status?: number -} - -// 文章创建/更新参数 -export interface ArticleFormData { - blogClass: string - title: string - htmlContent: string - homeImg: string - brief: string - author?: string - tags?: string[] - status?: number -} diff --git a/src/api/modules/card.ts b/src/api/modules/card.ts index 6c0d622..7cb6ea8 100644 --- a/src/api/modules/card.ts +++ b/src/api/modules/card.ts @@ -17,6 +17,7 @@ import type { SuspendResumeRecord, CardOrder, BaseResponse, + PaginationParams, PaginationResponse, ListResponse, GatewayRealnameLinkResponse, @@ -24,12 +25,36 @@ import type { ImportIotCardResponse, IotCardImportTask, IotCardImportTaskDetail, + IotCardImportTaskQueryParams, StandaloneCardQueryParams, StandaloneIotCard, + AllocateStandaloneCardsRequest, + AllocateStandaloneCardsResponse, + RecallStandaloneCardsRequest, + AssetAllocationRecordQueryParams, + AssetAllocationRecord, + AssetAllocationRecordDetail, BatchSetCardSeriesBindingRequest, BatchSetCardSeriesBindingResponse } from '@/types/api' +type ApiQueryParams = PaginationParams & Record + +interface ImportFailureRecord { + line?: number + row?: number + iccid?: string + reason: string +} + +interface CardChangeNotice { + id: string | number + iccids: string[] + reason: string + createTime?: string + operatorName?: string +} + export class CardService extends BaseService { // ========== 号卡商品管理 ========== @@ -37,7 +62,7 @@ export class CardService extends BaseService { * 获取号卡商品列表 * @param params 查询参数 */ - static getSimCardProducts(params?: any): Promise> { + static getSimCardProducts(params?: ApiQueryParams): Promise> { return this.getPage('/api/simcard-products', params) } @@ -95,15 +120,6 @@ export class CardService extends BaseService { return this.getOne(`/api/cards/iccid/${iccid}`) } - /** - * 通过ICCID查询单卡详情(旧接口,已废弃) - * @deprecated 使用 AssetService.resolveAsset 替代 - * @param iccid ICCID - */ - static getIotCardDetailByIccid(iccid: string): Promise> { - return this.getOne(`/api/admin/iot-cards/by-iccid/${iccid}`) - } - /** * 网卡操作(充值、停复机、增减流量等) * @param params 操作参数 @@ -214,7 +230,7 @@ export class CardService extends BaseService { * 获取导入批次列表 * @param params 查询参数 */ - static getImportBatches(params?: any): Promise> { + static getImportBatches(params?: ApiQueryParams): Promise> { return this.getPage('/api/cards/import-batches', params) } @@ -223,7 +239,7 @@ export class CardService extends BaseService { * @param file Excel文件 * @param params 额外参数 */ - static importCards(file: File, params?: Record): Promise { + static importCards(file: File, params?: Record): Promise { return this.upload('/api/cards/import', file, params) } @@ -231,15 +247,17 @@ export class CardService extends BaseService { * 获取导入失败记录 * @param batchId 批次ID */ - static getImportFailures(batchId: string | number): Promise> { - return this.getList(`/api/cards/import-batches/${batchId}/failures`) + static getImportFailures(batchId: string | number): Promise> { + return this.getList(`/api/cards/import-batches/${batchId}/failures`) } /** * 批量充值记录列表 * @param params 查询参数 */ - static getBatchRechargeRecords(params?: any): Promise> { + static getBatchRechargeRecords( + params?: ApiQueryParams + ): Promise> { return this.getPage('/api/cards/batch-recharge-records', params) } @@ -258,7 +276,7 @@ export class CardService extends BaseService { * @param params 查询参数 */ static getCardChangeApplications( - params?: any + params?: ApiQueryParams ): Promise> { return this.getPage('/api/card-change-applications', params) } @@ -284,8 +302,10 @@ export class CardService extends BaseService { * 获取换卡通知记录 * @param params 查询参数 */ - static getCardChangeNotices(params?: any): Promise> { - return this.getPage('/api/card-change-notices', params) + static getCardChangeNotices( + params?: ApiQueryParams + ): Promise> { + return this.getPage('/api/card-change-notices', params) } // ========== ICCID批量导入相关 ========== @@ -302,8 +322,10 @@ export class CardService extends BaseService { * 获取导入任务列表 * @param params 查询参数 */ - static getIotCardImportTasks(params?: any): Promise> { - return this.getPage('/api/admin/iot-cards/import-tasks', params) + static getIotCardImportTasks( + params?: IotCardImportTaskQueryParams + ): Promise> { + return this.getPage('/api/admin/iot-cards/import-tasks', params) } /** @@ -330,16 +352,26 @@ export class CardService extends BaseService { * 批量分配单卡 * @param data 分配参数 */ - static allocateStandaloneCards(data: any): Promise> { - return this.post('/api/admin/iot-cards/standalone/allocate', data) + static allocateStandaloneCards( + data: Partial + ): Promise> { + return this.post>( + '/api/admin/iot-cards/standalone/allocate', + data + ) } /** * 批量回收单卡 * @param data 回收参数 */ - static recallStandaloneCards(data: any): Promise> { - return this.post('/api/admin/iot-cards/standalone/recall', data) + static recallStandaloneCards( + data: Partial + ): Promise> { + return this.post>( + '/api/admin/iot-cards/standalone/recall', + data + ) } // ========== 资产分配记录相关 ========== @@ -348,16 +380,20 @@ export class CardService extends BaseService { * 获取资产分配记录列表 * @param params 查询参数 */ - static getAssetAllocationRecords(params?: any): Promise> { - return this.getPage('/api/admin/asset-allocation-records', params) + static getAssetAllocationRecords( + params?: AssetAllocationRecordQueryParams + ): Promise> { + return this.getPage('/api/admin/asset-allocation-records', params) } /** * 获取资产分配记录详情 * @param id 记录ID */ - static getAssetAllocationRecordDetail(id: number): Promise> { - return this.getOne(`/api/admin/asset-allocation-records/${id}`) + static getAssetAllocationRecordDetail( + id: number + ): Promise> { + return this.getOne(`/api/admin/asset-allocation-records/${id}`) } // ========== 批量设置卡的套餐系列绑定相关 ========== diff --git a/src/api/modules/commission.ts b/src/api/modules/commission.ts index a578ff2..49e8500 100644 --- a/src/api/modules/commission.ts +++ b/src/api/modules/commission.ts @@ -13,8 +13,6 @@ import type { WithdrawalSettingItem, CreateWithdrawalSettingParams, CommissionRecordQueryParams, - MyCommissionRecordPageResult, - MyCommissionSummary, SubmitWithdrawalParams, ShopCommissionRecordPageResult, ShopFundSummaryQueryParams, diff --git a/src/api/modules/customerAccount.ts b/src/api/modules/customerAccount.ts deleted file mode 100644 index 14dd1f1..0000000 --- a/src/api/modules/customerAccount.ts +++ /dev/null @@ -1,74 +0,0 @@ -/** - * 客户账号管理 API (企业账号) - * - * @deprecated 此 API 已废弃,请使用统一的 AccountService 代替 - * @see AccountService - 统一账号管理接口 (/api/admin/accounts) - * - * 迁移说明: - * - 所有账号类型统一使用 /api/admin/accounts 接口 - * - 通过 user_type 参数区分账号类型 (2=平台, 3=代理, 4=企业) - * - customer-accounts 已改名为 enterprise(企业账号) - * - 详见:docs/迁移指南.md - */ - -import { BaseService } from '../BaseService' -import type { BaseResponse } from '@/types/api' -import type { - CustomerAccountItem, - CustomerAccountPageResult, - CustomerAccountQueryParams, - CreateCustomerAccountParams, - UpdateCustomerAccountParams, - UpdateCustomerAccountPasswordParams, - UpdateCustomerAccountStatusParams -} from '@/types/api/customerAccount' - -export class CustomerAccountService extends BaseService { - /** - * 查询客户账号列表 - */ - static getCustomerAccounts( - params?: CustomerAccountQueryParams - ): Promise> { - return this.get>('/api/admin/customer-accounts', params) - } - - /** - * 新增代理商账号 - */ - static createCustomerAccount( - data: CreateCustomerAccountParams - ): Promise> { - return this.post>('/api/admin/customer-accounts', data) - } - - /** - * 编辑账号 - */ - static updateCustomerAccount( - id: number, - data: UpdateCustomerAccountParams - ): Promise> { - return this.put>(`/api/admin/customer-accounts/${id}`, data) - } - - /** - * 修改账号密码 - */ - static updateCustomerAccountPassword( - id: number, - data: UpdateCustomerAccountPasswordParams - ): Promise { - return this.put(`/api/admin/customer-accounts/${id}/password`, data) - } - - /** - * 修改账号状态 - */ - static updateCustomerAccountStatus( - id: number, - data: UpdateCustomerAccountStatusParams - ): Promise { - return this.put(`/api/admin/customer-accounts/${id}/status`, data) - } -} diff --git a/src/api/modules/device.ts b/src/api/modules/device.ts index 89959cf..f7be7ac 100644 --- a/src/api/modules/device.ts +++ b/src/api/modules/device.ts @@ -241,7 +241,7 @@ export class DeviceService extends BaseService { /** * 设置切卡模式 * @param identifier 设备标识(虚拟号 / IMEI / SN) - * @param switchMode 切卡模式(0=自动切卡,1=手动切卡) + * @param data */ static setSwitchMode( identifier: string, diff --git a/src/api/modules/exchange.ts b/src/api/modules/exchange.ts index dc432e2..d6ae11f 100644 --- a/src/api/modules/exchange.ts +++ b/src/api/modules/exchange.ts @@ -3,7 +3,7 @@ */ import { BaseService } from '../BaseService' -import type { BaseResponse, PaginationResponse } from '@/types/api' +import type { BaseResponse } from '@/types/api' // 换货单查询参数 export interface ExchangeQueryParams { diff --git a/src/api/modules/index.ts b/src/api/modules/index.ts index bdca63d..5c44745 100644 --- a/src/api/modules/index.ts +++ b/src/api/modules/index.ts @@ -2,21 +2,15 @@ * API 服务模块统一导出 */ -// 旧模块(待重构) -export * from './article' - // 新模块 export { AuthService } from './auth' export { RoleService } from './role' export { PermissionService } from './permission' export { AccountService } from './account' -export { PlatformAccountService } from './platformAccount' -export { ShopAccountService } from './shopAccount' export { ShopService } from './shop' export { CardService } from './card' export { CommissionService } from './commission' export { EnterpriseService } from './enterprise' -export { CustomerAccountService } from './customerAccount' export { StorageService } from './storage' export { AuthorizationService } from './authorization' export { DeviceService } from './device' diff --git a/src/api/modules/packageManage.ts b/src/api/modules/packageManage.ts index d150df7..77004f9 100644 --- a/src/api/modules/packageManage.ts +++ b/src/api/modules/packageManage.ts @@ -10,10 +10,8 @@ import type { UpdatePackageRequest, UpdatePackageStatusRequest, UpdatePackageShelfStatusRequest, - SeriesSelectOption, BaseResponse, PaginationResponse, - ListResponse } from '@/types/api' export class PackageManageService extends BaseService { diff --git a/src/api/modules/permission.ts b/src/api/modules/permission.ts index 373bce6..3df47d3 100644 --- a/src/api/modules/permission.ts +++ b/src/api/modules/permission.ts @@ -6,23 +6,12 @@ import { BaseService } from '../BaseService' import type { Permission, PermissionTreeNode, - PermissionQueryParams, CreatePermissionParams, UpdatePermissionParams, - BaseResponse, - PaginationResponse + BaseResponse } from '@/types/api' export class PermissionService extends BaseService { - /** - * 获取权限列表(分页) - * GET /api/admin/permissions - * @param params 查询参数 - */ - static getPermissions(params?: PermissionQueryParams): Promise> { - return this.getPage('/api/admin/permissions', params) - } - /** * 获取权限树 * GET /api/admin/permissions/tree diff --git a/src/api/modules/platformAccount.ts b/src/api/modules/platformAccount.ts deleted file mode 100644 index 385de36..0000000 --- a/src/api/modules/platformAccount.ts +++ /dev/null @@ -1,140 +0,0 @@ -/** - * 平台账号相关 API - 匹配后端实际接口 - * - * @deprecated 此 API 已废弃,请使用统一的 AccountService 代替 - * @see AccountService - 统一账号管理接口 (/api/admin/accounts) - * - * 迁移说明: - * - 所有账号类型统一使用 /api/admin/accounts 接口 - * - 通过 user_type 参数区分账号类型 (2=平台, 3=代理, 4=企业) - * - 详见:docs/迁移指南.md - */ - -import { BaseService } from '../BaseService' -import type { - PlatformAccountResponse, - PlatformAccountQueryParams, - CreatePlatformAccountParams, - UpdatePlatformAccountParams, - ChangePlatformAccountPasswordParams, - AssignRolesParams, - UpdateAccountStatusParams, - PlatformAccountRoleResponse, - BaseResponse, - PaginationResponse -} from '@/types/api' - -export class PlatformAccountService extends BaseService { - /** - * 1. 获取平台账号列表 - * GET /api/admin/platform-accounts - * @param params 查询参数 - */ - static getPlatformAccounts( - params?: PlatformAccountQueryParams - ): Promise> { - return this.getPage('/api/admin/platform-accounts', params) - } - - /** - * 2. 新增平台账号 - * POST /api/admin/platform-accounts - * @param data 账号数据 - */ - static createPlatformAccount( - data: CreatePlatformAccountParams - ): Promise> { - return this.post>('/api/admin/platform-accounts', data) - } - - /** - * 3. 移除角色 - * DELETE /api/admin/platform-accounts/{account_id}/roles/{role_id} - * @param accountId 账号ID - * @param roleId 角色ID - */ - static removeRoleFromPlatformAccount(accountId: number, roleId: number): Promise { - return this.delete(`/api/admin/platform-accounts/${accountId}/roles/${roleId}`) - } - - /** - * 4. 删除平台账号 - * DELETE /api/admin/platform-accounts/{id} - * @param id 账号ID - */ - static deletePlatformAccount(id: number): Promise { - return this.remove(`/api/admin/platform-accounts/${id}`) - } - - /** - * 5. 获取平台账号详情 - * GET /api/admin/platform-accounts/{id} - * @param id 账号ID - */ - static getPlatformAccountDetail(id: number): Promise> { - return this.getOne(`/api/admin/platform-accounts/${id}`) - } - - /** - * 6. 编辑平台账号 - * PUT /api/admin/platform-accounts/{id} - * @param id 账号ID - * @param data 更新数据 - */ - static updatePlatformAccount( - id: number, - data: UpdatePlatformAccountParams - ): Promise> { - return this.put>( - `/api/admin/platform-accounts/${id}`, - data - ) - } - - /** - * 7. 修改密码 - * PUT /api/admin/platform-accounts/{id}/password - * @param id 账号ID - * @param data 新密码 - */ - static changePlatformAccountPassword( - id: number, - data: ChangePlatformAccountPasswordParams - ): Promise { - return this.put(`/api/admin/platform-accounts/${id}/password`, data) - } - - /** - * 8. 获取账号角色 - * GET /api/admin/platform-accounts/{id}/roles - * @param id 账号ID - */ - static getPlatformAccountRoles(id: number): Promise> { - return this.get>( - `/api/admin/platform-accounts/${id}/roles` - ) - } - - /** - * 9. 分配角色 - * POST /api/admin/platform-accounts/{id}/roles - * @param id 账号ID - * @param data 角色ID列表 - */ - static assignRolesToPlatformAccount(id: number, data: AssignRolesParams): Promise { - return this.post(`/api/admin/platform-accounts/${id}/roles`, data) - } - - /** - * 10. 启用/禁用账号 - * PUT /api/admin/platform-accounts/{id}/status - * @param id 账号ID - * @param data 状态 - */ - static updatePlatformAccountStatus( - id: number, - data: UpdateAccountStatusParams - ): Promise { - return this.put(`/api/admin/platform-accounts/${id}/status`, data) - } -} diff --git a/src/api/modules/shopAccount.ts b/src/api/modules/shopAccount.ts deleted file mode 100644 index bef88bf..0000000 --- a/src/api/modules/shopAccount.ts +++ /dev/null @@ -1,86 +0,0 @@ -/** - * 代理账号相关 API - 匹配后端实际接口 - * - * @deprecated 此 API 已废弃,请使用统一的 AccountService 代替 - * @see AccountService - 统一账号管理接口 (/api/admin/accounts) - * - * 迁移说明: - * - 所有账号类型统一使用 /api/admin/accounts 接口 - * - 通过 user_type 参数区分账号类型 (2=平台, 3=代理, 4=企业) - * - 详见:docs/迁移指南.md - */ - -import { BaseService } from '../BaseService' -import type { - ShopAccountResponse, - ShopAccountQueryParams, - CreateShopAccountParams, - UpdateShopAccountParams, - UpdateShopAccountPasswordParams, - UpdateShopAccountStatusParams, - BaseResponse, - PaginationResponse -} from '@/types/api' - -export class ShopAccountService extends BaseService { - /** - * 获取代理账号列表 - * GET /api/admin/shop-accounts - * @param params 查询参数 - */ - static getShopAccounts( - params?: ShopAccountQueryParams - ): Promise> { - return this.getPage('/api/admin/shop-accounts', params) - } - - /** - * 创建代理账号 - * POST /api/admin/shop-accounts - * @param data 代理账号数据 - */ - static createShopAccount( - data: CreateShopAccountParams - ): Promise> { - return this.post>('/api/admin/shop-accounts', data) - } - - /** - * 更新代理账号 - * PUT /api/admin/shop-accounts/{id} - * @param id 账号ID - * @param data 更新数据 - */ - static updateShopAccount( - id: number, - data: UpdateShopAccountParams - ): Promise> { - return this.put>(`/api/admin/shop-accounts/${id}`, data) - } - - /** - * 重置代理账号密码 - * PUT /api/admin/shop-accounts/{id}/password - * @param id 账号ID - * @param data 密码数据 - */ - static updateShopAccountPassword( - id: number, - data: UpdateShopAccountPasswordParams - ): Promise { - return this.put(`/api/admin/shop-accounts/${id}/password`, data) - } - - /** - * 启用/禁用代理账号 - * PUT /api/admin/shop-accounts/{id}/status - * @param id 账号ID - * @param data 状态数据 - */ - static updateShopAccountStatus( - id: number, - data: UpdateShopAccountStatusParams - ): Promise { - return this.put(`/api/admin/shop-accounts/${id}/status`, data) - } -} diff --git a/src/assets/img/3d/icon1.webp b/src/assets/img/3d/icon1.webp deleted file mode 100644 index 631094c..0000000 Binary files a/src/assets/img/3d/icon1.webp and /dev/null differ diff --git a/src/assets/img/3d/icon2.webp b/src/assets/img/3d/icon2.webp deleted file mode 100644 index a9e4742..0000000 Binary files a/src/assets/img/3d/icon2.webp and /dev/null differ diff --git a/src/assets/img/3d/icon3.webp b/src/assets/img/3d/icon3.webp deleted file mode 100644 index 5e5994d..0000000 Binary files a/src/assets/img/3d/icon3.webp and /dev/null differ diff --git a/src/assets/img/3d/icon4.webp b/src/assets/img/3d/icon4.webp deleted file mode 100644 index 522108f..0000000 Binary files a/src/assets/img/3d/icon4.webp and /dev/null differ diff --git a/src/assets/img/3d/icon5.webp b/src/assets/img/3d/icon5.webp deleted file mode 100644 index b8f794d..0000000 Binary files a/src/assets/img/3d/icon5.webp and /dev/null differ diff --git a/src/assets/img/3d/icon6.webp b/src/assets/img/3d/icon6.webp deleted file mode 100644 index c955494..0000000 Binary files a/src/assets/img/3d/icon6.webp and /dev/null differ diff --git a/src/assets/img/3d/icon7.webp b/src/assets/img/3d/icon7.webp deleted file mode 100644 index 8aa26ee..0000000 Binary files a/src/assets/img/3d/icon7.webp and /dev/null differ diff --git a/src/assets/img/3d/icon8.webp b/src/assets/img/3d/icon8.webp deleted file mode 100644 index 609c4ee..0000000 Binary files a/src/assets/img/3d/icon8.webp and /dev/null differ diff --git a/src/assets/img/avatar/avatar.webp b/src/assets/img/avatar/avatar.webp deleted file mode 100644 index bea307b..0000000 Binary files a/src/assets/img/avatar/avatar.webp and /dev/null differ diff --git a/src/assets/img/avatar/avatar1.webp b/src/assets/img/avatar/avatar1.webp deleted file mode 100644 index 68e256c..0000000 Binary files a/src/assets/img/avatar/avatar1.webp and /dev/null differ diff --git a/src/assets/img/avatar/avatar10.webp b/src/assets/img/avatar/avatar10.webp deleted file mode 100644 index a813d4c..0000000 Binary files a/src/assets/img/avatar/avatar10.webp and /dev/null differ diff --git a/src/assets/img/avatar/avatar2.webp b/src/assets/img/avatar/avatar2.webp deleted file mode 100644 index 6716e3f..0000000 Binary files a/src/assets/img/avatar/avatar2.webp and /dev/null differ diff --git a/src/assets/img/avatar/avatar3.webp b/src/assets/img/avatar/avatar3.webp deleted file mode 100644 index 7355ad4..0000000 Binary files a/src/assets/img/avatar/avatar3.webp and /dev/null differ diff --git a/src/assets/img/avatar/avatar4.webp b/src/assets/img/avatar/avatar4.webp deleted file mode 100644 index 56a9549..0000000 Binary files a/src/assets/img/avatar/avatar4.webp and /dev/null differ diff --git a/src/assets/img/avatar/avatar5.webp b/src/assets/img/avatar/avatar5.webp deleted file mode 100644 index f78400c..0000000 Binary files a/src/assets/img/avatar/avatar5.webp and /dev/null differ diff --git a/src/assets/img/avatar/avatar6.webp b/src/assets/img/avatar/avatar6.webp deleted file mode 100644 index 9771b78..0000000 Binary files a/src/assets/img/avatar/avatar6.webp and /dev/null differ diff --git a/src/assets/img/avatar/avatar7.webp b/src/assets/img/avatar/avatar7.webp deleted file mode 100644 index e5ef6fe..0000000 Binary files a/src/assets/img/avatar/avatar7.webp and /dev/null differ diff --git a/src/assets/img/avatar/avatar8.webp b/src/assets/img/avatar/avatar8.webp deleted file mode 100644 index b66e48f..0000000 Binary files a/src/assets/img/avatar/avatar8.webp and /dev/null differ diff --git a/src/assets/img/avatar/avatar9.webp b/src/assets/img/avatar/avatar9.webp deleted file mode 100644 index 7974139..0000000 Binary files a/src/assets/img/avatar/avatar9.webp and /dev/null differ diff --git a/src/assets/img/ceremony/hb.png b/src/assets/img/ceremony/hb.png deleted file mode 100644 index 4103324..0000000 Binary files a/src/assets/img/ceremony/hb.png and /dev/null differ diff --git a/src/assets/img/ceremony/sd.png b/src/assets/img/ceremony/sd.png deleted file mode 100644 index 75ec838..0000000 Binary files a/src/assets/img/ceremony/sd.png and /dev/null differ diff --git a/src/assets/img/ceremony/xc.png b/src/assets/img/ceremony/xc.png deleted file mode 100644 index 9c7ab67..0000000 Binary files a/src/assets/img/ceremony/xc.png and /dev/null differ diff --git a/src/assets/img/ceremony/yd.png b/src/assets/img/ceremony/yd.png deleted file mode 100644 index 426912d..0000000 Binary files a/src/assets/img/ceremony/yd.png and /dev/null differ diff --git a/src/components/business/CreateRefundDialog.vue b/src/components/business/CreateRefundDialog.vue index 73035c3..6d52d12 100644 --- a/src/components/business/CreateRefundDialog.vue +++ b/src/components/business/CreateRefundDialog.vue @@ -362,8 +362,8 @@ color: var(--el-text-color-regular); em { - color: var(--el-color-primary); font-style: normal; + color: var(--el-color-primary); } } } diff --git a/src/components/core/banners/ArtCardBanner.vue b/src/components/core/banners/ArtCardBanner.vue deleted file mode 100644 index bff113f..0000000 --- a/src/components/core/banners/ArtCardBanner.vue +++ /dev/null @@ -1,140 +0,0 @@ - - - - - diff --git a/src/components/core/layouts/art-chat-window/index.vue b/src/components/core/layouts/art-chat-window/index.vue index 75b9905..b4dcd0c 100644 --- a/src/components/core/layouts/art-chat-window/index.vue +++ b/src/components/core/layouts/art-chat-window/index.vue @@ -20,7 +20,9 @@
diff --git a/src/views/asset-management/enterprise-cards/index.vue b/src/views/asset-management/enterprise-cards/index.vue index 7284813..1a933fe 100644 --- a/src/views/asset-management/enterprise-cards/index.vue +++ b/src/views/asset-management/enterprise-cards/index.vue @@ -86,7 +86,7 @@
已选择 {{ selectedAvailableCards.length }} 张卡
已选择 {{ selectedAvailableDevices.length }} 台设备 data.flow_type_name || (flowType === 'direct' ? '直接换货' : '物流换货') + formatter: (_, data) => + data.flow_type_name || (flowType === 'direct' ? '直接换货' : '物流换货') }, { label: '换货原因', diff --git a/src/views/asset-management/exchange-management/index.vue b/src/views/asset-management/exchange-management/index.vue index ef55bf4..a341a31 100644 --- a/src/views/asset-management/exchange-management/index.vue +++ b/src/views/asset-management/exchange-management/index.vue @@ -514,7 +514,8 @@ prop: 'flow_type', label: '流程类型', width: 120, - formatter: (row: any) => row.flow_type_name || (row.flow_type === 'direct' ? '直接换货' : '物流换货') + formatter: (row: any) => + row.flow_type_name || (row.flow_type === 'direct' ? '直接换货' : '物流换货') }, { prop: 'old_asset_type', diff --git a/src/views/asset-management/iot-card-management/index.vue b/src/views/asset-management/iot-card-management/index.vue index 439faff..c68eb17 100644 --- a/src/views/asset-management/iot-card-management/index.vue +++ b/src/views/asset-management/iot-card-management/index.vue @@ -2,32 +2,65 @@
- + - + - +