package com.sqx.modules.resumes.controller.app;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.sqx.common.utils.DateUtils;
import com.sqx.common.utils.PageUtils;
import com.sqx.common.utils.Result;
import com.sqx.modules.resumes.entity.RuleClassify;
import com.sqx.modules.resumes.entity.RulePost;
import com.sqx.modules.resumes.service.RuleClassifyService;
import com.sqx.modules.resumes.service.RulePostService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.apache.commons.lang.StringUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.Date;
import java.util.List;

@RestController
@Api(value = "岗位分类", tags = {"岗位分类"})
@RequestMapping(value = "/app/rule/")
public class AppRuleController {
    @Autowired
    private RuleClassifyService ruleClassifyService;

    @ApiOperation("获取岗位列表")
    @GetMapping("getClassifyList")
    public Result getClassifyList(RuleClassify classify) {
        return Result.success().put("data", ruleClassifyService.getClassifyList(classify));
    }

    @ApiOperation("用户获取岗位")
    @GetMapping("userGetClassify")
    public Result userGetClassify(RuleClassify classify) {
        return Result.success().put("data", ruleClassifyService.userGetClassify(classify));
    }
    @ApiOperation("获取岗位信息")
    @GetMapping("ruleClassifyId")
    public Result getClassify(Long ruleClassifyId){
        return Result.success().put("data",ruleClassifyService.getById(ruleClassifyId));
    }
}
