import request from '@/utils/request';

// 修改手机号
export function changeTelphone(data) {
  return request({
    url: '/local/seller/editMobile',
    method: 'post',
    data: data
  })
}

// 设置登录密码
export function changeLoginPassword(data) {
  return request({
    url: '/local/seller/setPass',
    method: 'post',
    data: data
  })
}

// 设置支付密码
export function changePayPassword(data) {
  return request({
    url: '/local/seller/setPayPass',
    method: 'post',
    data: data
  })
}

// 获取验证码 有两个接口
// 1-修改登录账号/密码，获取验证码
export function getTelphoneCode(id) {
  return request({
    url: '/local/seller/sendCodeMobile?mobile=' + id,
    method: 'get'
  })
}
// 2-修改 支付密码，获取验证码
export function getEditPayPasswordCode(query) {
  return request({
    url: '/local/seller/sendMobile',
    method: 'get',
    params: query
  })
}
