mirror of
https://github.com/ENSL/ensl_gathers.git
synced 2024-11-23 12:52:15 +00:00
Implemented hive integration fixes #7
This commit is contained in:
parent
1e347d26e5
commit
87faeab649
3 changed files with 19 additions and 6 deletions
|
@ -634,13 +634,20 @@ var Gatherers = React.createClass({
|
|||
};
|
||||
|
||||
if (gatherer.user.profile.skill) {
|
||||
var skill = (<span className="label label-primary">{gatherer.user.profile.skill}</span>);
|
||||
var skill = (<span className="label label-default">{gatherer.user.profile.skill}</span>);
|
||||
}
|
||||
|
||||
var abilities = [];
|
||||
for (let attr in gatherer.user.profile.abilities) {
|
||||
if (gatherer.user.profile.abilities[attr]) abilities.push(_.capitalize(attr));
|
||||
}
|
||||
|
||||
if (gatherer.user.hive.skill) abilities.push("ELO: " + gatherer.user.hive.skill);
|
||||
|
||||
if (gatherer.user.hive.playTime) {
|
||||
abilities.push(Math.floor(gatherer.user.hive.playTime / 3600) + " Hours");
|
||||
}
|
||||
|
||||
var lifeform = (
|
||||
abilities.map(lifeform => {
|
||||
return (<span className="label label-default add-right"
|
||||
|
@ -650,7 +657,7 @@ var Gatherers = React.createClass({
|
|||
|
||||
var team;
|
||||
if (gatherer.user.team) {
|
||||
team = (<span className="label label-primary">{gatherer.user.team.name}</span>);
|
||||
team = (<span className="label label-default">{gatherer.user.team.name}</span>);
|
||||
}
|
||||
|
||||
var action;
|
||||
|
@ -685,8 +692,8 @@ var Gatherers = React.createClass({
|
|||
return (
|
||||
<tr key={gatherer.user.id} data-userid={gatherer.user.id}>
|
||||
<td className="col-md-9">
|
||||
<p className="gatherer">{gatherer.user.username}</p>
|
||||
<p className="gatherer">{country} {lifeform} {skill} {team}</p>
|
||||
<p className="gatherer">{country} {gatherer.user.username}</p>
|
||||
<p className="gatherer-ability">{lifeform} {skill} {team}</p>
|
||||
</td>
|
||||
<td className="col-md-3 text-right">{action} </td>
|
||||
</tr>
|
||||
|
|
|
@ -94,7 +94,6 @@ User.find = (id, callback) => {
|
|||
}
|
||||
], function (error, result) {
|
||||
if (error) return callback(error);
|
||||
console.log(user);
|
||||
return callback(null, user);
|
||||
})
|
||||
});
|
||||
|
|
|
@ -7,10 +7,17 @@ html, body {
|
|||
}
|
||||
|
||||
.gatherer {
|
||||
margin-bottom: 3px;
|
||||
margin-bottom: 5px;
|
||||
padding: 0px;
|
||||
}
|
||||
|
||||
.gatherer-ability {
|
||||
font-size: 12px;
|
||||
line-height: 25px;
|
||||
padding: 0px;
|
||||
margin: 0px;
|
||||
}
|
||||
|
||||
#chatroom {
|
||||
margin-top: 20px;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue