package com.fdkankan.ucenter.service;

import com.fdkankan.ucenter.entity.ReceiverInfo;
import com.fdkankan.ucenter.entity.User;
import com.baomidou.mybatisplus.extension.service.IService;
import com.fdkankan.ucenter.vo.request.RegisterParam;
import com.fdkankan.ucenter.vo.request.ShipAddressParam;
import com.fdkankan.ucenter.vo.request.UserParam;
import com.fdkankan.ucenter.vo.response.CameraVo;
import com.fdkankan.ucenter.vo.response.UserVo;

import java.util.HashMap;
import java.util.List;

/**
 * <p>
 * 用户信息表 服务类
 * </p>
 *
 * @author 
 * @since 2022-07-01
 */
public interface IUserService extends IService<User> {

    User getByUserName(String phoneNum);

    User register(RegisterParam param);

    void updatePassword(String phoneNum, String password);

    UserVo getUserInfo(String userName);

    String uploadHead(String imgdata, String userName) throws Exception;

    void insertAddress(ShipAddressParam param, String userName);

    void updateAddress(ShipAddressParam param, String userName);

    void deleteAddress(Long id);

    void updateEmail(String email, String userName);

    ReceiverInfo getReceiverInfo(String userName);

    List<ReceiverInfo> getReceiverList(String userName);

    void updateNickName(String nickName, String userName);

    void updateUserDetail(UserParam param, String userName);

    HashMap<Long, User> getByIds(List<Long> userIds);

    Long getCountByNickName(String nickName);

    List<Long> getLikeUserName(String userName);

    User getByToken(String token);

    CameraVo findCameraDetailByChildName(String token, String childName);

    void updateDownloadNum(long userId, int num);
}
