/** * 这是所有模块公用业务逻辑的服务 */ export default class PublicService { constructor(AjaxService) { Object.assign(this, { AjaxService }) this.name = 'PublicService' } /** * 获取地址 */ GetAllAddressData (data = {}) { return this.AjaxService.get({ url:'/order/address/select/all', data, isLoading: false, }) } /** * 获取图形验证码 * platformType:小程序 2 WWW 0 CRM 1 */ GetImgVerifyCode (data = {platformType:2}) { return this.AjaxService.get({ url:'/user/captcha', data, isLoading: true, }) } /** * 获取图形验证码 * activateCodeType:机构 2 供应商 3 找回密码 1 */ GetMobileCode (data = {}) { return this.AjaxService.get({ url:'/user/activateCodeByReg', data, isLoading: true }) } /** * 获取图形验证码 * activateCodeType:机构 2 供应商 3 找回密码 1 */ GetMobileCode (data = {}) { return this.AjaxService.get({ url:'/user/activateCodeByReg', data, isLoading: true }) } /** * 获取手机短信验证码 * isCheckCaptcha 是否需要图形验证码:1:不检查 , 0:检查 * mobile 手机号 * activateCodeType 短信类型 :1:找回密码, 2:手机号注册机构, 3:供应商注册 6:二手发布 * imgCode 图片验证码 * token 图片验证码token * platformType: 来源:0:www,1:crm/h5,2:小程序 */ GetRegisterMobileCode (data = {}) { return this.AjaxService.get({ url:'/user/sms/code', data, isLoading: true, }) } /** * 获取邮箱短信验证码 * email 邮箱 * status 1:绑定邮箱,2邮箱注册,3邮箱找回秘密 */ GetUserEmailCode (data = {}) { return this.AjaxService.get({ url:'/user/mail/code', data, isLoading: true, }) } /** * 获取手机短信验证码 * bindMobile 机构手机号 * isCheckCaptcha 是否需要图形验证码:1:检查 , 0:不检查z * mobile 运营人员手机号 * userId 机构用户UserId * imgCode 图片验证码 * token 图片验证码token * platformType: 来源:0:www,1:crm/h5,2:小程序 */ GetBindMobileCode (data = {}) { return this.AjaxService.get({ url:'/user/sms/bind', data, isLoading: true, }) } }