import { HTTPBody } from '@fastify-modular/route'; import { pito } from 'pito'; import { NeedLogin } from '../defines'; // ========================================================================== export const DeleteProductMatchByOwnerParam = pito.Obj({ prodId: pito.Num(), }); export type DeleteProductMatchByOwnerParam = pito.Type; // ========================================================================== export const DeleteProductMatchByOwnerInput = pito.Obj({}); export type DeleteProductMatchByOwnerInput = pito.Type; // ========================================================================== export const DeleteProductMatchByOwnerOption = pito.Obj({ fkUserSeller: pito.Num(), }); export type DeleteProductMatchByOwnerOption = pito.Type; // ========================================================================== export const DeleteProductMatchByOwnerOutput = pito.Obj({}); export type DeleteProductMatchByOwnerOutput = pito.Type; // ========================================================================== export const DeleteProductMatchByOwner = HTTPBody('DELETE', '/api/v1/product/product-match/owner/:prodId', 'product') .params(DeleteProductMatchByOwnerParam) .body(DeleteProductMatchByOwnerInput) .query(DeleteProductMatchByOwnerOption) .response(DeleteProductMatchByOwnerOutput) .presets(NeedLogin) .build(); // ==========================================================================