package com.ssj.service.weixin.problem.service.impl;

import com.ssj.bean.weixin.problem.domain.ValidVip;
import com.ssj.dao.weixin.problem.dao.ProblemQueryDao;
import com.ssj.dao.weixin.problem.dao.ValidVipDao;
import com.ssj.framework.core.common.service.BaseServiceImpl;
import com.ssj.service.weixin.problem.service.ValidVipService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.repository.PagingAndSortingRepository;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

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

@Service
@Transactional
public class ValidVipServiceImpl extends BaseServiceImpl<ValidVip, String> implements ValidVipService{
	@Autowired
	private ValidVipDao  validVipDao;
	@Autowired
	private ProblemQueryDao  problemQueryDao;
	@Override
	public Page<Map<String, Object>> findValidVipPage(
			Map<String, Object> searchParams, Pageable pageable) {
		return problemQueryDao.findValidVipPage(searchParams, pageable);
	}

	@Override
	public PagingAndSortingRepository<ValidVip, String> getDao() {
		return validVipDao;
	}

	@Override
	public List<Map<String, Object>> getValidVipList(
			Map<String, Object> searchParams) {
		return problemQueryDao.getValidVipList(searchParams);
		}

	@Override
	public void saveValidVip() {
		validVipDao.saveValidVip();
		
	}

	@Override
	public void saveMonthValidVip() {
		validVipDao.saveMonthValidVip();
		
	}

	@Override
	public Page<Map<String, Object>> findValidVip2Page(
			Map<String, Object> searchParams, Pageable pageable) {
		 return problemQueryDao.findValidVip2Page(searchParams, pageable);
	}

	@Override
	public List<Map<String, Object>> getValidVipList2(
			Map<String, Object> searchParams) {
		return problemQueryDao.getValidVipList2(searchParams);
	}
	
	
}
