package com.crm.manager.controller;

import com.crm.manager.service.activity.ActivityRaceRuleFeignService;
import com.crm.rely.backend.core.dto.base.BaseLongSelectDto;
import com.crm.rely.backend.core.dto.base.BaseResultDto;
import com.crm.rely.backend.model.entity.activity.ActivityRaceRuleDropDownEntity;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author y
 * @create 2022/7/21
 */
@RestController
@RequestMapping("/activity/race/rule")
public class ActivityRaceRuleController {

    @Autowired
    private ActivityRaceRuleFeignService activityRaceRuleFeignService;

    @PostMapping("/dropdown")
    public BaseResultDto<List<BaseLongSelectDto>> dropdown(@RequestBody ActivityRaceRuleDropDownEntity entity) throws Exception {
        return activityRaceRuleFeignService.dropdown(entity);
    }
}
