package com.yonge.cooleshow.student.controller;


import com.yonge.cooleshow.biz.dal.dto.ImGroupNoticeDto;
import com.yonge.cooleshow.biz.dal.service.ImGroupNoticeService;
import com.yonge.cooleshow.common.controller.BaseController;
import com.yonge.cooleshow.common.entity.HttpResponseResult;
import com.yonge.toolset.base.page.PageInfo;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiImplicitParam;
import io.swagger.annotations.ApiImplicitParams;
import io.swagger.annotations.ApiOperation;
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 javax.annotation.Resource;
import java.util.Map;

/**
 * 群公告(ImGroupNotice)表控制层
 *
 * @author zx
 * @since 2022-03-22 10:45:58
 */
@Api(tags = "群公告")
@RestController
@RequestMapping("/imGroupNotice")
public class ImGroupNoticeController extends BaseController {
    /**
     * 服务对象
     */
    @Resource
    private ImGroupNoticeService imGroupNoticeService;

    @ApiImplicitParams({
            @ApiImplicitParam(name = "groupId", dataType = "Long", value = "群编号",required = true)
    })
    @ApiOperation("分页查询")
    @PostMapping(value = "/queryPage")
    public HttpResponseResult<PageInfo<ImGroupNoticeDto>> queryPage(@RequestBody Map<String,Object> params) throws Exception {
        return succeed(imGroupNoticeService.queryPage(params));
    }
}

