2016-07-28 10:33:30 +05:30
|
|
|
import request from 'services/request';
|
|
|
|
|
|
|
|
export default {
|
2019-11-27 14:33:32 +05:30
|
|
|
register({
|
|
|
|
email = '',
|
|
|
|
username = '',
|
|
|
|
password = '',
|
|
|
|
rePassword = '',
|
|
|
|
rulesAgreement = false,
|
|
|
|
lang = '',
|
|
|
|
captcha = '',
|
|
|
|
}) {
|
|
|
|
return request.post(
|
|
|
|
'/api/signup',
|
|
|
|
{ email, username, password, rePassword, rulesAgreement, lang, captcha },
|
|
|
|
{ token: null },
|
|
|
|
);
|
|
|
|
},
|
2016-07-28 10:33:30 +05:30
|
|
|
|
2019-11-27 14:33:32 +05:30
|
|
|
activate({ key = '' }) {
|
|
|
|
return request.post('/api/signup/confirm', { key }, { token: null });
|
|
|
|
},
|
2016-07-28 10:33:30 +05:30
|
|
|
|
2019-11-27 14:33:32 +05:30
|
|
|
resendActivation({ email = '', captcha }) {
|
|
|
|
return request.post('/api/signup/repeat-message', { email, captcha });
|
|
|
|
},
|
2016-07-28 10:33:30 +05:30
|
|
|
};
|