myqrcode.js
330 Bytes
'use strict';
const api = global.yoho.API;
const crypto = global.yoho.crypto;
exports.getQr = (params) => {
return api.get('', {
method: 'app.twoDimen.getCode',
uid: crypto.decrypt(undefined, params.token),
}).then(result => {
return (result && result.data && result.data.code) || '';
});
};