hasnur
unknown
typescript
9 days ago
2.7 kB
2
Indexable
Never
import { ApiResponseData } from '../global'; // Interface Create Asset Request & Response export interface CreateAssetRequest { poNumber: string; mdaNumber: string; itemName: string; itemPrice: number; condition: string | 'good' | 'not_good'; clasification: string | 'inventory' | 'lva'; poDate: string; locationId: string; } export interface CreateAssetResponse extends ApiResponseData { id: string; } // Interface Update Asset Request & Response export interface UpdateAssetRequest { poNumber: string; mdaNumber: string; itemName: string; itemPrice: number; condition: string | 'good' | 'not_good'; clasification: string | 'inventory' | 'lva'; poDate: string; locationId: string; } // Interface Get All Asset Request & Response interface Asset { id: string; poNumber: string; mdaNumber: string; itemName: string; itemPrice: number; condition: string; clasification: string; poDate: string; asetLocation: { id: string; name: string; }; notes: string; } interface Links { next: string | null; prev: string | null; } export interface GetAllAssetResponse extends ApiResponseData { pageSize: number; currentPage: number; totalPages: number; asets: Asset[]; links: Links; } // Interface Get Asset By Id Request & Response interface AssetLocationHistory { id: string; now: { id: string; name: string; }; old: { id: string; name: string; }; pic: string; createdAt: string; } export interface GetAssetByIdResponse extends ApiResponseData { id: string; poNumber: string; mdaNumber: string; itemName: string; itemPrice: number; condition: string; clasification: string; poDate: string; BAK: string | null; photo: string | null; asetLocation: { id: string; name: string; }; asetLocationHistory: AssetLocationHistory[]; userCreated: string; userUpdated: string; createdAt: string; updatedAt: string; notes: string; } // Interface Get Asset Summary Request & Response export interface GetAssetSummaryResponse extends ApiResponseData { totalCount: number; totalValue: number; } // Interface Import Asset Request & Response export interface ImportAssetRequest { poNumber: string; mdaNumber: string; itemName: string; itemPrice: number; condition: string | 'good' | 'not_good'; clasification: string | 'lva' | 'inventory'; poDate: string; locationId: string; } // Interface Export Asset Request & Response export interface ExportAssetResponse extends ApiResponseData { url: string; } // Interface Qr Asset Request & Response export interface QrAssetResponse extends ApiResponseData { id: string; mdaNumber: string; itemName: string; }
Leave a Comment