Blame view

CollectInfoController.java 1.46 KB
涂亚平 committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46
package com.subsidy.controller;


import com.subsidy.common.ResponseData;
import com.subsidy.common.ResponseVO;
import com.subsidy.dto.collect.InfoDTO;
import com.subsidy.model.CollectInfoDO;
import com.subsidy.service.CollectInfoService;
import io.swagger.annotations.ApiOperation;
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 io.swagger.annotations.Api;

/**
 * <p>
 * 首页手机信息 前端控制器
 * </p>
 *
 * @author Tuyp
 * @since 2024-11-02
 */
@RestController
@Api(tags = "首页收集信息")
@RequestMapping("/collectInfo")
public class CollectInfoController {

    @Autowired
    private CollectInfoService collectInfoService;

    @PostMapping("collect")
    @ApiOperation("收集信息  collegeName 院校名称 dept  部门/院系   jobName 职位   userName 称呼  telephone 联系方式")
    public ResponseVO collect(@RequestBody CollectInfoDO collectInfoDO){
        return ResponseData.generateCreatedResponse(0,collectInfoService.collect(collectInfoDO));
    }

    @PostMapping("info")
    @ApiOperation("需求单--查询  pageSize pageNum")
    public ResponseVO info(@RequestBody InfoDTO infoDTO){
        return ResponseData.generateCreatedResponse(0,collectInfoService.info(infoDTO));
    }

}