package com.ym.mec.biz.service;

import com.ym.mec.biz.dal.entity.SysUserContracts;
import com.ym.mec.common.service.BaseService;

import java.util.List;

public interface SysUserContractsService extends BaseService<Long, SysUserContracts> {

    /**
     * @describe 获取用户指定类型的协议记录
     * @author Joburgess
     * @date 2020.09.18
     * @param userId:
     * @param contractType:
     * @return java.util.List<com.ym.mec.biz.dal.entity.SysUserContracts>
     */
    List<SysUserContracts> getUserContractWithType(Integer userId, SysUserContracts.ContractType contractType, Integer contractVersion);

    /**
     * 获取最近一次的协议
     * @param userId
     * @return
     */
    SysUserContracts getLatestUserContract(Integer userId);

    List<SysUserContracts> getUserAllContracts(Integer userId);
}
