import { fetch } from '../../../utils/util'; export class Params { /** id */ id?: number; } export type ResponseType = Promise>; export const URL = '/api/menu/detail'; /** * @desc 获取菜单详情 */ export function request( params: Params, options?: WechatMiniprogram.RequestOption, ): ResponseType { let url = '/api/menu/detail'; const fetchOption = Object.assign( { url: url, method: 'POST', headers: { 'Content-Type': 'application/json', }, params: params, }, options, ); return fetch(fetchOption); }