package com.ifish.service;

import org.springframework.web.multipart.MultipartFile;

import com.ifish.dto.JsonResult;
import com.ifish.entity.User;
import com.ifish.validator.LoginParam;
import com.ifish.validator.RegisterParam;

/** 
 * @ClassName: UserService 
 * @Description: TODO 
 * @author ggw
 *  
 */
public interface UserService {
	
	/**
	 * 获取手机验证码
	 * @param phoneNumber
	 * @param sendType
	 * @return
	 */
	public JsonResult<?> getVerificateCode(String phoneNumber,String sendType);
	
	/**
	 * 登录
	 * @param loginParam
	 * @return
	 */
	@Deprecated
	public JsonResult<?> login(LoginParam loginParam);
	
	/**
	 * 优化后登录验证
	 * @param loginParam
	 * @return
	 */
	public JsonResult<?> loginValidate(LoginParam loginParam);
	
	/**
	 * 更多用户数据信息
	 * @param userId
	 * @return
	 */
	public JsonResult<?> moreUserData(Integer userId);
	/**
	 * 绑定设备
	 * @param userId
	 * @param macAddress
	 * @return
	 */
	public JsonResult<?> bindDevice(Integer userId,String macAddress);
	/**
	 * 扫一扫分享设备
	 * @param userId
	 * @param deviceId
	 * @return
	 */
	public JsonResult<?> shareDevice(Integer userId,Integer deviceId);
	/**
	 * 注册
	 * @param registerParam
	 * @return
	 */
	public JsonResult<?> register(RegisterParam registerParam);
	
	/**
	 * 修改用户信息
	 * @param user
	 * @return
	 */
	public JsonResult<?> updateInfo(User user);
	
	/**
	 * 上传头像
	 * @param userId
	 * @param fileUpload
	 * @return
	 */
	public JsonResult<?> uploadUserImg(Integer userId,MultipartFile fileUpload);
	
}
