Merge branch 'release/v1.5.2' of hardi/opt-cc into master

pull/13/head v1.5.2
hardi 2017-10-07 21:13:10 +02:00 committed by HardiReady
commit 8799a1cdcd
38 changed files with 120 additions and 191 deletions

View File

@ -1,6 +1,6 @@
{
"name": "opt-cc",
"version": "1.5.1",
"version": "1.5.2",
"license": "MIT",
"private": true,
"scripts": {

View File

@ -1,13 +1,5 @@
.overview {
position: fixed;
overflow-y: scroll;
overflow-x: hidden;
bottom: 20px;
width: 100%;
padding-left: 50px;
padding-top: 190px;
margin-left: 10px;
height: 100vh;
padding: 80px 0 0 10%!important;
}
.trash {
@ -22,6 +14,7 @@
.table-container {
margin-top: 10px;
overflow-x: auto;
padding: 5px;
}
.table-head {

View File

@ -3,8 +3,7 @@
<h2>Admin Panel</h2>
<span *ngIf="showSuccessLabel"
class="label label-success label-small"
style="margin-left: inherit">
class="absolute-label label label-success label-small">
Erfolgreich gespeichert
</span>

View File

@ -8,7 +8,7 @@ import {SquadService} from "../services/squad-service/squad.service";
@Component({
selector: 'admin-panel',
templateUrl: './admin.component.html',
styleUrls: ['./admin.component.css']
styleUrls: ['./admin.component.css', '../style/overview.css']
})
export class AdminComponent {

View File

@ -1,14 +1,14 @@
.overview {
height: 100vh;
.army-member-view {
width: 90%;
height: 100vh;
padding: 5px;
margin: auto;
position: relative;
left: -1%;
}
:host /deep/ #right {
padding-left: 0;
.army-member-view-container {
width: 90%;
min-width: 870px;
margin:auto
}
.return-button {

View File

@ -1,5 +1,5 @@
<div class="overview">
<div style="width: 90%; min-width: 870px; margin:auto">
<div class="army-member-view">
<div class="army-member-view-container">
<div class="return-button">
<span class="btn btn-default" style="position:absolute;" (click)="backToOverview()">< zurück zur Übersicht</span>
<h3 class="text-center" [ngClass]="user.squad?.fraction === 'BLUFOR' ? 'blufor' : 'opfor'">

View File

@ -55,7 +55,6 @@ img {
.member-link {
cursor: pointer;
display: block;
text-decoration: underline;
}

View File

@ -11,10 +11,13 @@
</div>
<div class="row middle-row">
<div class="squad-cell name-cell">
<span class="member-link text-blufor"
*ngFor="let member of squad.members"
(click)="select(member._id)">
{{member.rank}} {{member.username}}
<span class="text-blufor"
style="display: block"
*ngFor="let member of squad.members">
<span class="member-link"
(click)="select(member._id)">
{{member.rank}} {{member.username}}
</span>
</span>
</div>
</div>
@ -37,10 +40,13 @@
</div>
<div class="row middle-row">
<div class="squad-cell name-cell">
<span class="member-link text-opfor"
*ngFor="let member of squad.members"
(click)="select(member._id)">
{{member.rank}} {{member.username}}
<span class="text-opfor"
style="display: block"
*ngFor="let member of squad.members">
<span class="member-link"
(click)="select(member._id)">
{{member.rank}} {{member.username}}
</span>
</span>
</div>
</div>

View File

@ -7,7 +7,7 @@ import {Subscription} from "rxjs/Subscription";
@Component({
templateUrl: './edit-decoration.component.html',
styleUrls: ['./edit-decoration.component.css', '../../style/entry-form.css']
styleUrls: ['./edit-decoration.component.css', '../../style/entry-form.css', '../../style/overview.css']
})
export class EditDecorationComponent {

View File

@ -8,7 +8,7 @@ import {Subscription} from "rxjs/Subscription";
@Component({
templateUrl: './edit-rank.component.html',
styleUrls: ['./edit-rank.component.css', '../../style/entry-form.css']
styleUrls: ['./edit-rank.component.css', '../../style/entry-form.css', '../../style/overview.css']
})
export class EditRankComponent {

View File

@ -1,3 +1,8 @@
.overview {
width: 100%!important;
margin-left: 25px!important;
}
.decoration-preview {
padding: 5px;
}
@ -14,30 +19,16 @@
.table-container {
margin-top: 40px;
overflow-x: auto;
width: 65%;
}
/* enable scrolling for long list of awardings */
.overview {
position: fixed;
overflow-y: scroll;
overflow-x: hidden;
width: 100%;
border-left: thin solid lightgrey;
padding: 20px 0 0 50px;
margin-left: 10px;
height: 100vh;
bottom: 10px;
width: 75%;
min-width: 800px;
padding: 5px;
}
.form-group {
width: 25%;
min-width: 300px;
}
h3 {
margin: 80px 0 20px -20px;
}
label {
display: block;
}

View File

@ -17,7 +17,6 @@
</select>
</div>
<div class="form-group">
<label for="decoration">Auszeichnung</label>
<select class="form-control"
@ -64,8 +63,7 @@
</button>
<span *ngIf="showSuccessLabel"
class="label label-success label-small"
style="margin-left: inherit">
class="absolute-label label label-success label-small">
Erfolgreich gespeichert
</span>

View File

@ -10,7 +10,7 @@ import {LoginService} from "../../services/login-service/login-service";
@Component({
templateUrl: './req-award.component.html',
styleUrls: ['./req-award.component.css'],
styleUrls: ['./req-award.component.css', '../../style/overview.css'],
})
export class RequestAwardComponent {

View File

@ -1,3 +1,7 @@
.overview {
margin-left: 25px!important;
}
.decoration-preview {
padding: 5px;
}
@ -15,19 +19,7 @@
margin-top: 40px;
overflow-x: auto;
width: 75%;
}
/* enable scrolling for long list of awardings */
.overview {
position: fixed;
overflow-y: scroll;
overflow-x: hidden;
width: 100%;
border-left: thin solid lightgrey;
padding: 20px 0 0 50px;
margin-left: 10px;
height: 100vh;
bottom: 10px;
padding: 5px;
}
.form-group {
@ -37,7 +29,3 @@
h3 {
margin: 80px 0 20px -20px;
}
label {
display: block;
}

View File

@ -2,8 +2,7 @@
<h3>Offene Anträge - Auszeichnungen</h3>
<span *ngIf="showSuccessLabel"
class="label label-success label-small"
style="margin-left: inherit">
class="absolute-label label label-success label-small">
Erfolgreich gespeichert
</span>

View File

@ -6,7 +6,7 @@ import {LoginService} from "../../services/login-service/login-service";
@Component({
templateUrl: './confirm-award.component.html',
styleUrls: ['./confirm-award.component.css'],
styleUrls: ['./confirm-award.component.css', '../../style/overview.css'],
})
export class ConfirmAwardComponent {

View File

@ -1,3 +1,7 @@
.overview {
margin-left: 25px!important;
}
.decoration-preview {
padding: 5px;
}
@ -15,19 +19,7 @@
margin-top: 40px;
overflow-x: auto;
width: 65%;
}
/* enable scrolling for long list of awardings */
.overview {
position: fixed;
overflow-y: scroll;
overflow-x: hidden;
width: 100%;
border-left: thin solid lightgrey;
padding: 20px 0 0 50px;
margin-left: 10px;
height: 100vh;
bottom: 10px;
padding: 5px;
}
.form-group {
@ -37,7 +29,3 @@
h3 {
margin: 80px 0 20px -20px;
}
label {
display: block;
}

View File

@ -2,8 +2,7 @@
<h3>Offene Anträge - Beförderung</h3>
<span *ngIf="showSuccessLabel"
class="label label-success label-small"
style="margin-left: inherit">
class="absolute-label label label-success label-small">
Erfolgreich gespeichert
</span>

View File

@ -7,7 +7,7 @@ import {LoginService} from "../../services/login-service/login-service";
@Component({
templateUrl: './confirm-promotion.component.html',
styleUrls: ['./confirm-promotion.component.css'],
styleUrls: ['./confirm-promotion.component.css', '../../style/overview.css'],
})
export class ConfirmPromotionComponent {

View File

@ -1,3 +1,7 @@
.overview {
margin-left: 25px!important;
}
.decoration-preview {
padding: 5px;
}
@ -15,29 +19,15 @@
margin-top: 40px;
overflow-x: auto;
width: 65%;
}
/* enable scrolling for long list of awardings */
.overview {
position: fixed;
overflow-y: scroll;
overflow-x: hidden;
width: 100%;
border-left: thin solid lightgrey;
padding: 20px 0 0 50px;
margin-left: 10px;
height: 100vh;
bottom: 10px;
min-width: 800px;
padding: 5px;
}
.form-group {
width: 25%;
min-width: 300px;
}
h3 {
margin: 80px 0 20px -20px;
}
label {
display: block;
}

View File

@ -58,8 +58,7 @@
</button>
<span *ngIf="showSuccessLabel"
class="label label-success label-small"
style="margin-left: inherit">
class="absolute-label label label-success label-small">
Erfolgreich gespeichert
</span>

View File

@ -10,7 +10,7 @@ import {LoginService} from "../../services/login-service/login-service";
@Component({
templateUrl: './req-promotion.component.html',
styleUrls: ['./req-promotion.component.css'],
styleUrls: ['./req-promotion.component.css', '../../style/overview.css'],
})
export class RequestPromotionComponent {

View File

@ -8,7 +8,7 @@ import {Subscription} from "rxjs/Subscription";
@Component({
templateUrl: './edit-squad.component.html',
styleUrls: ['./edit-squad.component.css', '../../style/entry-form.css']
styleUrls: ['./edit-squad.component.css', '../../style/entry-form.css', '../../style/overview.css']
})
export class EditSquadComponent {

View File

@ -1,13 +1,3 @@
.overview {
position: fixed;
overflow-y: scroll;
overflow-x: hidden;
border-left: thin solid lightgrey;
bottom: 20px;
padding: 70px 1% 0 1%;
height: 100vh;
}
h2 {
padding: 10px;
}

View File

@ -1,4 +1,4 @@
<div class="overview fade-in" xmlns="http://www.w3.org/1999/html">
<div class="overview fade-in" style="padding: 70px 1% 0 1%;" xmlns="http://www.w3.org/1999/html">
<h2 class="pull-left">Spielerstatistik - {{campaignPlayer.name}}</h2>
<h2 class="pull-right">{{campaignPlayer.campaign.title}} Kampagne</h2>

View File

@ -9,7 +9,8 @@ import {Location} from '@angular/common';
@Component({
selector: 'campaign-player-detail',
templateUrl: './campaign-player-detail.component.html',
styleUrls: ['./campaign-player-detail.component.css', '../../style/list-entry.css', '../../style/hide-scrollbar.css']
styleUrls: ['./campaign-player-detail.component.css', '../../style/list-entry.css',
'../../style/hide-scrollbar.css', '../../style/overview.css']
})
export class CampaignPlayerDetailComponent {

View File

@ -1,8 +0,0 @@
.overview {
position: fixed;
width: 25%;
min-width: 300px;
padding-left: 50px;
padding-top: 70px;
margin-left: 10px;
}

View File

@ -8,7 +8,7 @@ import {CampaignService} from "../../services/campaign-service/campaign.service"
@Component({
selector: 'campaign-submit',
templateUrl: './campaign-submit.component.html',
styleUrls: ['./campaign-submit.component.css']
styleUrls: ['./campaign-submit.component.css', '../../style/entry-form.css', '../../style/overview.css']
})
export class CampaignSubmitComponent {

View File

@ -1,15 +1,15 @@
<div class="slide-chart-container" style="height: 150px;">
<h2 style="margin-bottom: 20px">{{title}}</h2>
<div class="btn btn-default" [style.background]="isActiveSlide(0)"
(click)="goToSlide(0)" *ngIf="id != 'all'">Gesamtpunktzahl
</div>
<div class="btn btn-default" [style.background]="isActiveSlide(1)"
(click)="goToSlide(1)">Punkte je Schlacht
</div>
<div class="btn btn-default" [style.background]="isActiveSlide(2)"
(click)="goToSlide(2)">Spielerzahlen
</div>
<div class="btn btn-default" [style.background]="isActiveSlide(0)"
(click)="goToSlide(0)" *ngIf="id != 'all'">Gesamtpunktzahl
</div>
<div class="btn btn-default" [style.background]="isActiveSlide(1)"
(click)="goToSlide(1)">Punkte je Schlacht
</div>
<div class="btn btn-default" [style.background]="isActiveSlide(2)"
(click)="goToSlide(2)">Spielerzahlen
</div>
</div>
<div class="fade-in">
<div class="slide-chart-container">
@ -25,7 +25,8 @@
[showYAxisLabel]="showYAxisLabel"
[yAxisLabel]="yAxisLabel"
[autoScale]="autoscale"
[timeline]="timeline">
[timeline]="timeline"
[roundDomains]="roundDomains">
</ngx-charts-line-chart>
</div>
</div>

View File

@ -8,7 +8,7 @@ import {ChartUtils} from "../../utils/chart-utils";
@Component({
selector: 'stats-overview',
templateUrl: './stats-overview.component.html',
styleUrls: ['./stats-overview.component.css', '../../style/list-entry.css'],
styleUrls: ['./stats-overview.component.css', '../../style/list-entry.css', '../../style/overview.css'],
inputs: ['campaigns'],
providers: [{provide: CarouselConfig, useValue: {interval: false}}]
})
@ -38,7 +38,6 @@ export class StatisticOverviewComponent {
autoscale = true;
timeline = false;
constructor(private route: ActivatedRoute,
private campaignService: CampaignService) {
}
@ -63,14 +62,20 @@ export class StatisticOverviewComponent {
let itemsProcessed = 0;
campaigns = campaigns.filter(campaign => this.id === 'all' || campaign._id === this.id);
campaigns.forEach(campaign => {
if (this.id === 'all') {
this.title = "Gesamtübersicht";
} else {
this.title = campaign.title;
}
wars = wars.concat(campaign.wars);
itemsProcessed++;
if (itemsProcessed === campaigns.length) {
if (this.id === 'all') {
this.title = "Gesamtübersicht";
wars.sort((a, b) => {
// sort by dates, because older campaign can contain newer war
if (a['date'] > (b['date'])) return -1;
if (a['date'] < (b['date'])) return 1;
return 0;
})
} else {
this.title = campaign.title;
}
this.initChart(wars);
}
})

View File

@ -1,8 +0,0 @@
.overview {
position: fixed;
width: 25%;
min-width: 300px;
padding-left: 50px;
padding-top: 70px;
margin-left: 10px;
}

View File

@ -9,7 +9,8 @@ import {CampaignService} from "../../services/campaign-service/campaign.service"
@Component({
selector: 'war-submit',
templateUrl: './war-submit.component.html',
styleUrls: ['./war-submit.component.css', '../../style/load-indicator.css']
styleUrls: ['./war-submit.component.css', '../../style/load-indicator.css',
'../../style/entry-form.css', '../../style/overview.css']
})
export class WarSubmitComponent {

View File

@ -1,3 +1,10 @@
.overview {
overflow: hidden!important;
padding-top: 80px!important;
width: 20%;
min-width: 280px;
}
h3 {
margin-left: -20px;
}
@ -10,17 +17,6 @@ label {
border-color: red;
}
.overview {
position: fixed;
width: 25%;
min-width: 500px;
border-left: thin solid lightgrey;
padding-left: 50px;
padding-top: 20px;
margin-left: 10px;
height: 100vh;
}
.preview-image {
margin: 10px;
}

View File

@ -1,9 +1,7 @@
.load-indicator {
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
width: 50%;
left: 48.5%;
z-index: 1;
}

View File

@ -0,0 +1,17 @@
.overview {
position: fixed;
overflow-y: scroll;
overflow-x: hidden;
border-left: thin solid lightgrey;
padding: 20px 0 0 50px;
height: 100vh;
bottom: 10px;
}
.absolute-label {
display: block;
position: absolute;
font-size: 12px;
padding: 5px;
margin-left: 25%;
}

View File

@ -18,19 +18,6 @@
width: 50%;
}
/* enable scrolling for long list of awardings */
.overview {
position: fixed;
overflow-y: scroll;
overflow-x: hidden;
width: 100%;
border-left: thin solid lightgrey;
padding: 20px 0 0 50px;
margin-left: 10px;
height: 100vh;
bottom: 10px;
}
.form-group {
width: 25%;
}

View File

@ -8,7 +8,7 @@ import {DecorationService} from "../../services/decoration-service/decoration.se
@Component({
templateUrl: './award-user.component.html',
styleUrls: ['./award-user.component.css'],
styleUrls: ['./award-user.component.css', '../../style/overview.css', '../../style/hide-scrollbar.css'],
})
export class AwardUserComponent {

View File

@ -10,7 +10,7 @@ import {NgForm} from "@angular/forms";
@Component({
templateUrl: './edit-user.component.html',
styleUrls: ['./edit-user.component.css', '../../style/entry-form.css'],
styleUrls: ['./edit-user.component.css', '../../style/entry-form.css', '../../style/overview.css'],
})
export class EditUserComponent {