package cn.superdesk.uniorder.dubbo.consumer.sys.notify;

import cn.superdesk.uniorder.common.rest.response.R;
import cn.superdesk.uniorder.dao.entity.sys.notify.SysNotifyTemplate;
import cn.superdesk.uniorder.dto.param.system.notify.SysNotifyTemplateParam;
import cn.superdesk.uniorder.dubbo.facade.sys.notify.DubboSysNotifyTemplateService;
import com.alibaba.dubbo.config.annotation.Reference;
import com.github.pagehelper.PageInfo;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

import java.util.List;
import java.util.Map;

/**
 * @Description:
 * @Author: linjinyu
 * @Email linjinyu@avic-s.com
 * @CreateDate: 2021-03-01 17:37:17
 * @UpdateUser: linjinyu
 * @UpdateDate: 2021-03-01 17:37:17
 * @UpdateRemark: 修改内容
 * @Version: 1.0
 */
@Slf4j
@Component
public class SysNotifyTemplateDubboConsumerService {

	@Reference(version = "1.0.0", timeout = 10000, retries = -1)
	private DubboSysNotifyTemplateService dubboSysNotifyTemplateService;


	/****************************************** extends BaseService 部分 start ******************************************/

	public void addObj(SysNotifyTemplateParam param) {

		dubboSysNotifyTemplateService.addObj(param);

	}

	public void updateObj(SysNotifyTemplateParam param) {

		dubboSysNotifyTemplateService.updateObj(param);
	}

	public void deleteObj(Long id) {

		dubboSysNotifyTemplateService.deleteObj(id);
	}

	public SysNotifyTemplate findById(Long id) {

		return dubboSysNotifyTemplateService.findById(id);
	}

	public PageInfo<SysNotifyTemplate> findByPaging(Map<String, Object> conditions, Integer pageNun, Integer pageSize) {

		return dubboSysNotifyTemplateService.findByPaging(conditions, pageNun, pageSize);
	}

	public List<SysNotifyTemplate> findAll(Map<String, Object> queryMap) {

		return dubboSysNotifyTemplateService.findAll(queryMap);
	}

	/****************************************** extends BaseService 部分   end ******************************************/


	public void addSysNotifyTemplate(SysNotifyTemplateParam param) {

		dubboSysNotifyTemplateService.addSysNotifyTemplate(param);
	}


	public void updateSysNotifyTemplate(SysNotifyTemplateParam param) {

		dubboSysNotifyTemplateService.updateSysNotifyTemplate(param);
	}


	public void deleteSysNotifyTemplate(Long id) {
		dubboSysNotifyTemplateService.deleteSysNotifyTemplate(id);
	}


	public SysNotifyTemplate findSysNotifyTemplateById(Long id) {

		return dubboSysNotifyTemplateService.findSysNotifyTemplateById(id);
	}


	public R<List<SysNotifyTemplate>> pageQuery(Map<String, Object> conditions, int pageNun, int pageSize) {

		return dubboSysNotifyTemplateService.pageQuery(conditions, pageNun, pageSize);
	}
}
