yapi/plugins/yapi-plugin-qsso/client.js
2017-09-06 10:18:13 +08:00

17 lines
391 B
JavaScript

import React from 'react';
const Qsso = require('./qsso-lib');
class QssoComponent extends React.Component{
componentDidMount(){
Qsso.attach('qsso-login', '/api/user/login_by_token');
}
render(){
return <button id="qsso-login" className="btn-home btn-home-normal" >QSSO 登录</button>;
}
}
module.exports = function(){
this.bindHook('third_login', QssoComponent);
};