import request from '@/utils/request';
import { AxiosPromise } from 'axios';
import { GoodsStockQuery, GoodsStockVO } from './types';

/**
 * 分页查询成品库存列表
 * @param query
 * @Author: Antigravity
 */
export function listGoodsStockPage(query: GoodsStockQuery): AxiosPromise<any> {
  return request({
    url: '/erp/goodsStock/page',
    method: 'get',
    params: query
  });
}

/**
 * 查询成品库存列表（不分页）
 * @param query
 * @Author: Antigravity
 */
export function listGoodsStock(query: GoodsStockQuery): AxiosPromise<GoodsStockVO[]> {
  return request({
    url: '/erp/goodsStock/list',
    method: 'get',
    params: query
  });
}
