chore: 修复最后一批导入路径错误
- 修复 wallet API 中的 orders 导入 - 修复 admin API 中的 authStorage 导入 - 修复 seller composables 和测试文件导入 - 修复 admin index.ts 导出名称 类型错误:113 → 108
This commit is contained in:
@@ -2,7 +2,7 @@ import axios from 'axios'
|
|||||||
|
|
||||||
import { apiClient } from '@/shared/api/client'
|
import { apiClient } from '@/shared/api/client'
|
||||||
import type { ApiResponse } from '@/shared/types/types'
|
import type { ApiResponse } from '@/shared/types/types'
|
||||||
import { getRefreshToken, setAuthTokens } from '@/utils/authStorage'
|
import { getRefreshToken, setAuthTokens } from '@/shared/utils/authStorage'
|
||||||
import type { UserStatus } from '@/shared/types/status'
|
import type { UserStatus } from '@/shared/types/status'
|
||||||
|
|
||||||
export interface AdminRole {
|
export interface AdminRole {
|
||||||
|
|||||||
@@ -8,15 +8,27 @@ export * from './api/systemConfigs'
|
|||||||
export * from './composables/useAdminTable'
|
export * from './composables/useAdminTable'
|
||||||
export * from './composables/useAdminPaginatedTable'
|
export * from './composables/useAdminPaginatedTable'
|
||||||
|
|
||||||
// adminAuth 和 adminRoles 都导出 AdminRole,需要显式导出避免冲突
|
// adminAuth 导出(不包括 AdminRole,避免与 adminRoles 冲突)
|
||||||
export { loginAdmin, logoutAdmin, fetchCurrentAdmin, type AdminUser } from './api/adminAuth'
|
export {
|
||||||
|
fetchAdminCaptcha,
|
||||||
|
loginAdmin,
|
||||||
|
logoutAdmin,
|
||||||
|
refreshAdminAccessToken,
|
||||||
|
getAdminInfo,
|
||||||
|
type AdminUser,
|
||||||
|
type AdminTokenPair,
|
||||||
|
type AdminLoginData,
|
||||||
|
type AdminCaptcha
|
||||||
|
} from './api/adminAuth'
|
||||||
|
|
||||||
|
// adminRoles 导出
|
||||||
export {
|
export {
|
||||||
fetchRoles,
|
fetchRoles,
|
||||||
fetchRole,
|
fetchRole,
|
||||||
createRole,
|
createRole,
|
||||||
updateRole,
|
updateRole,
|
||||||
deleteRole,
|
deleteRole,
|
||||||
fetchAllPermissions,
|
fetchPermissions,
|
||||||
type AdminRole,
|
type AdminRole,
|
||||||
type Permission
|
type Permission
|
||||||
} from './api/adminRoles'
|
} from './api/adminRoles'
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import { describe, it, expect } from 'vitest'
|
import { describe, it, expect } from 'vitest'
|
||||||
import { useHomeFilters } from '@/features/listings/composables/useHomeFilters'
|
import { useHomeFilters } from '@/features/listings/composables/useHomeFilters'
|
||||||
import { ref } from 'vue'
|
import { ref } from 'vue'
|
||||||
import { emptyListingPublishOptions } from '@/api/listingOptions'
|
import { emptyListingPublishOptions } from '@/features/listings/api/listingOptions'
|
||||||
|
|
||||||
describe('useHomeFilters', () => {
|
describe('useHomeFilters', () => {
|
||||||
it('应该初始化空的筛选器', () => {
|
it('应该初始化空的筛选器', () => {
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import type { ChargeMode, QuantityKey, ScreenshotKey } from '@/api/listingOptions'
|
import type { ChargeMode, QuantityKey, ScreenshotKey } from '@/features/listings/api/listingOptions'
|
||||||
import type { PublishDraft, PublishForm } from '@/types/publish'
|
import type { PublishDraft, PublishForm } from '@/types/publish'
|
||||||
|
|
||||||
export function defaultPublishForm(): PublishForm {
|
export function defaultPublishForm(): PublishForm {
|
||||||
|
|||||||
@@ -11,8 +11,8 @@ import {
|
|||||||
type ListingPublishOptions,
|
type ListingPublishOptions,
|
||||||
type PublishSalePriceConfig,
|
type PublishSalePriceConfig,
|
||||||
type ScreenshotKey,
|
type ScreenshotKey,
|
||||||
} from '@/api/listingOptions'
|
} from '@/features/listings/api/listingOptions'
|
||||||
import { createListing } from '@/api/listings'
|
import { createListing } from '@/features/listings/api/listings'
|
||||||
import { usePricingCalculator } from '@/composables/usePricingCalculator'
|
import { usePricingCalculator } from '@/composables/usePricingCalculator'
|
||||||
import {
|
import {
|
||||||
buildPublishDraft,
|
buildPublishDraft,
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ import { apiClient } from '@/shared/api/client'
|
|||||||
|
|
||||||
import type { ApiResponse, PaginatedResult } from '@/shared/types/types'
|
import type { ApiResponse, PaginatedResult } from '@/shared/types/types'
|
||||||
import type { BalanceType, LedgerDirection, WalletStatus } from '@/shared/types/status'
|
import type { BalanceType, LedgerDirection, WalletStatus } from '@/shared/types/status'
|
||||||
import type { PaymentOrder } from '@/api/orders'
|
import type { PaymentOrder } from '@/features/orders/api/orders'
|
||||||
|
|
||||||
export interface WalletAccount {
|
export interface WalletAccount {
|
||||||
user_id: number
|
user_id: number
|
||||||
|
|||||||
Reference in New Issue
Block a user