package com.kcim.endPoint;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

/**
 * @program: pfm_manager
 * @description: 中台方法调用
 * @author: Wang.YS
 * @create: 2023-10-11 14:38
 **/
@FeignClient(name = "center-provider")
@RequestMapping("centerSys")
public interface CenterEndPoint {

    /**
     * 中台获取用户信息
     *
     * @return 用户信息
     */
    @GetMapping("/api/getUser")
    Object getUserInfo(@RequestParam(required = false,name = "filter") String filter);

    @GetMapping("/api/getDict")
    Object getDict(@RequestParam(required = false,name = "dictType")String dictType,
                   @RequestParam(required = false,name="systemId") Long systemId);


    @GetMapping("/api/getAllDict")
    Object getAllDict();

    @GetMapping("/api/getAllDictBySystemId")
    Object getAllDictBySystemId(@RequestParam(required = false,name="systemId") Long systemId);

    @GetMapping("/sysdepartment/getDepartment")
    Object getDepartment();

    @GetMapping("/api/getDepartmentFilter")
    Object getDepartmentFilter(@RequestParam(required = false,name = "departName") String departName);


    @GetMapping("/api/getParameter")
    Object getParameter(@RequestParam(required = false,name = "systemId")Long systemId,
                 @RequestParam(required = false,name="parameterCode") Long parameterCode);

    @GetMapping("/api/getKCClass")
    Object getKCClass(@RequestParam(required = false,name = "className") String className);
    @GetMapping("/sysdepartment/getDepartmentByDepartmentIds")
    Object getDepartmentByDepartmentIds(@RequestParam(required = false,name = "departmentIds")List<Long> departmentIds);
}
