6868_createLogin #2598
|
@ -30,17 +30,14 @@ module.exports = Self => {
|
|||
}
|
||||
});
|
||||
|
||||
Self.loginApp = async(ctx, android_id, versionApp, nameApp, options) => {
|
||||
Self.handleUser = async(ctx, android_id, versionApp, nameApp, options) => {
|
||||
const models = Self.app.models;
|
||||
const myOptions = {};
|
||||
if (typeof options == 'object')
|
||||
Object.assign(myOptions, options);
|
||||
|
||||
// const login = await models.Account.login(ctx, user, password, myOptions);
|
||||
|
||||
const accessToken = ctx.req.accessToken;
|
||||
let user = await models.VnUser.findById(accessToken.userId);
|
||||
console.log(user.id);
|
||||
|
||||
const [[{vIsAuthorized, vMessage}]] =
|
||||
await Self.rawSql('CALL vn.device_checkLogin(?, ?);',
|
||||
|
|
|
@ -10,7 +10,6 @@ module.exports = Self => {
|
|||
require('../methods/account/logout')(Self);
|
||||
require('../methods/account/change-password')(Self);
|
||||
require('../methods/account/set-password')(Self);
|
||||
require('../methods/account/login-app')(Self);
|
||||
require('../methods/account/handle-user')(Self);
|
||||
|
||||
Self.setUnverifiedPassword = async(id, pass, options) => {
|
||||
|
|
Loading…
Reference in New Issue