mirror of
https://github.com/YMFE/yapi.git
synced 2024-12-21 05:19:42 +08:00
17 lines
391 B
JavaScript
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);
|
|
};
|
|
|