123456789101112131415161718192021222324252627282930313233343536373839404142 |
- /*
- * @Author: PoJun
- * @Date: 2023-08-28 11:22:46
- * @LastEditors: XuanJi
- * @LastEditTime: 2024-05-08 19:46:23
- * @Message: 产品目录相关
- */
- import { $get, $post } from "../config/http.js";
- /** 产品目录树 */
- export const getProductsTree = reqConfig => {
- return $get({ url: "/product_dirs/tree", reqConfig });
- };
- /** 获取产品目录树(无需权限) */
- export const getProductsTreeNoAuth = reqConfig => {
- return $get({ url: "/product_dirs/tree_noauth", reqConfig });
- };
- /** 新建产品目录 */
- export const addProductsDir = data => {
- return $post({ url: `/product_dirs/`, data, reqConfig: { showMsg: true } });
- };
- /** 编辑产品目录 */
- export const editProductsDir = (data, id) => {
- return $post({ url: `/product_dirs/${id}/info`, data, reqConfig: { showMsg: true } });
- };
- /** 删除产品目录 */
- export const deleteProductsDir = id => {
- return $post({ url: `/product_dirs/${id}/`, reqConfig: { showMsg: true } });
- };
- /** 根据id查找产品目录表 */
- export const getProductsInfo = (id, reqConfig) => {
- return $get({ url: `/product_dirs/${id}/info`, reqConfig });
- };
- /** 根据id集合查找产品目录表 */
- export const getProductsInfoFromIds = params => {
- return $get({ url: `/product_dirs/batch_info`, params });
- };
|