add boxes

This commit is contained in:
Samandar Turg'unboev
2025-06-20 10:58:52 +05:00
parent 94ec72526a
commit 4c5df8007c
3 changed files with 122 additions and 57 deletions

View File

@@ -1,4 +1,4 @@
import { IBox, CreateBoxBodyType, UpdateBoxBodyType, IBoxDetail, BoxStatus } from '@/data/box/box.model';
import { BoxStatus, CreateBoxBodyType, IBox, IBoxDetail, UpdateBoxBodyType } from '@/data/box/box.model';
import { CommonResponseType, PageAble } from '@/helpers/types';
import { request } from '@/services/request';
import axios from 'axios';
@@ -7,6 +7,7 @@ export const box_requests = {
async getAll(params?: {
page?: number;
sort?: string;
pageable?: string | number;
direction?: string;
cargoId?: string;
partyId?: string | number;

View File

@@ -29,7 +29,7 @@ export const item_requests = {
async find(params: { itemId?: number | string }) {
return request.get<CommonResponseType<Product[]>>('/items/find', { params });
},
async list(params: { packetId?: number | string }) {
async list(params: { packetId?: number | string; page?: number | string }) {
return request.get<CommonResponseType<{ data: Product[] }>>('/items/list', { params });
},
async delete(params: { itemId: number | string }) {