package com.sptg.ad.api.feigns;

import com.baomidou.mybatisplus.plugins.Page;
import com.sptg.ad.api.entity.EarlyWarning;
import com.sptg.common.core.beans.PageBean;
import com.sptg.common.core.beans.ResultBean;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 *            
 *                
 * description:
 */
@FeignClient(value = "smart-house-ad")
public interface EarlyWarningFeign {

    /**
     * 分页查询预警记录
     * @param pageBean 分页条件
     * @return Page<EarlyWarning>
     */
    @PostMapping(value = "/early_warning/pagingQuery")
    Page<EarlyWarning> pagingQuery(@RequestBody PageBean<EarlyWarning,EarlyWarning> pageBean);

    /**
     * 添加预警
     * @param warning 预警记录
     * @return Boolean
     */
    @PostMapping(value = "/early_warning/add")
    ResultBean<Boolean> addEntity(@RequestBody EarlyWarning warning);

}
