Replace strings with i18n keys in request module
							parent
							
								
									b2fa02d4eb
								
							
						
					
					
						commit
						36e213bbbf
					
				| 
						 | 
					@ -1,8 +1,8 @@
 | 
				
			||||||
<form #form="ngForm" class="overview">
 | 
					<form #form="ngForm" class="overview">
 | 
				
			||||||
  <h3>Auszeichnung beantragen</h3>
 | 
					  <h3>{{'request.award.headline' | translate}}</h3>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <div class="form-group">
 | 
					  <div class="form-group">
 | 
				
			||||||
    <label for="user">Teilnehmer</label>
 | 
					    <label for="user">{{'request.award.field.user' | translate}}</label>
 | 
				
			||||||
    <select class="form-control"
 | 
					    <select class="form-control"
 | 
				
			||||||
            name="user"
 | 
					            name="user"
 | 
				
			||||||
            id="user"
 | 
					            id="user"
 | 
				
			||||||
| 
						 | 
					@ -10,7 +10,7 @@
 | 
				
			||||||
            [compareWith]="equals"
 | 
					            [compareWith]="equals"
 | 
				
			||||||
            (change)="toggleUser()"
 | 
					            (change)="toggleUser()"
 | 
				
			||||||
            required>
 | 
					            required>
 | 
				
			||||||
      <option [ngValue]="{_id: '0'}">Auswählen...</option>
 | 
					      <option [ngValue]="{_id: '0'}">{{'request.award.field.user.placeholder' | translate}}</option>
 | 
				
			||||||
      <option *ngFor="let user of users" [ngValue]="user">
 | 
					      <option *ngFor="let user of users" [ngValue]="user">
 | 
				
			||||||
        {{user.username}}
 | 
					        {{user.username}}
 | 
				
			||||||
      </option>
 | 
					      </option>
 | 
				
			||||||
| 
						 | 
					@ -18,7 +18,7 @@
 | 
				
			||||||
  </div>
 | 
					  </div>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <div class="form-group">
 | 
					  <div class="form-group">
 | 
				
			||||||
    <label for="decoration">Auszeichnung</label>
 | 
					    <label for="decoration">{{'request.award.field.award' | translate}}</label>
 | 
				
			||||||
    <select class="form-control"
 | 
					    <select class="form-control"
 | 
				
			||||||
            name="decoration"
 | 
					            name="decoration"
 | 
				
			||||||
            id="decoration"
 | 
					            id="decoration"
 | 
				
			||||||
| 
						 | 
					@ -26,7 +26,7 @@
 | 
				
			||||||
            [compareWith]="equals"
 | 
					            [compareWith]="equals"
 | 
				
			||||||
            (change)="toggleDecoPreview(decoDescription, decoPreview)"
 | 
					            (change)="toggleDecoPreview(decoDescription, decoPreview)"
 | 
				
			||||||
            required>
 | 
					            required>
 | 
				
			||||||
      <option [ngValue]="{_id: '0'}">Auswählen...</option>
 | 
					      <option [ngValue]="{_id: '0'}">{{'request.award.field.award.placeholder' | translate}}</option>
 | 
				
			||||||
      <option *ngFor="let deco of decorations" [ngValue]="deco">
 | 
					      <option *ngFor="let deco of decorations" [ngValue]="deco">
 | 
				
			||||||
        {{deco.name}}
 | 
					        {{deco.name}}
 | 
				
			||||||
      </option>
 | 
					      </option>
 | 
				
			||||||
| 
						 | 
					@ -44,35 +44,35 @@
 | 
				
			||||||
  </div>
 | 
					  </div>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <div class="form-group">
 | 
					  <div class="form-group">
 | 
				
			||||||
    <label for="reason">Begründung</label>
 | 
					    <label for="reason">{{'request.award.field.reason' | translate}}</label>
 | 
				
			||||||
    <textarea class="form-control center-block" name="reason" [(ngModel)]="reason" required
 | 
					    <textarea class="form-control center-block" name="reason" [(ngModel)]="reason" required
 | 
				
			||||||
              id="reason" placeholder="Begründung eingeben..." rows="3"></textarea>
 | 
					              id="reason" placeholder="{{'request.award.field.reason.placeholder' | translate}}" rows="3"></textarea>
 | 
				
			||||||
  </div>
 | 
					  </div>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <button id="cancel"
 | 
					  <button id="cancel"
 | 
				
			||||||
          (click)="cancel()"
 | 
					          (click)="cancel()"
 | 
				
			||||||
          class="btn btn-default">
 | 
					          class="btn btn-default">
 | 
				
			||||||
    Abbrechen
 | 
					    {{'request.award.button.cancel' | translate}}
 | 
				
			||||||
  </button>
 | 
					  </button>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <button id="save"
 | 
					  <button id="save"
 | 
				
			||||||
          (click)="addAwarding(decoPreview, decoDescription)"
 | 
					          (click)="addAwarding(decoPreview, decoDescription)"
 | 
				
			||||||
          class="btn btn-default"
 | 
					          class="btn btn-default"
 | 
				
			||||||
          [disabled]="!form.valid || user._id === '0' || decoration._id === '0'">
 | 
					          [disabled]="!form.valid || user._id === '0' || decoration._id === '0'">
 | 
				
			||||||
    Bestätigen
 | 
					    {{'request.award.button.submit' | translate}}
 | 
				
			||||||
  </button>
 | 
					  </button>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <div class="table-container" *ngIf="showForm">
 | 
					  <div class="table-container" *ngIf="showForm">
 | 
				
			||||||
    <table class="table table-hover">
 | 
					    <table class="table table-hover">
 | 
				
			||||||
      <thead>
 | 
					      <thead>
 | 
				
			||||||
      <tr>
 | 
					      <tr>
 | 
				
			||||||
        <th class="col-sm-1">Bild</th>
 | 
					        <th class="col-sm-1">{{'request.award.table.head.image' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-2">Bezeichnung</th>
 | 
					        <th class="col-sm-2">{{'request.award.table.head.name' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-2">Begründung</th>
 | 
					        <th class="col-sm-2">{{'request.award.table.head.reason' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1 ">Antragsteller</th>
 | 
					        <th class="col-sm-1 ">{{'request.award.table.head.requester' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1 text-right">Datum</th>
 | 
					        <th class="col-sm-1 text-right">{{'request.award.table.head.date' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1 text-center">Status</th>
 | 
					        <th class="col-sm-1 text-center">{{'request.award.table.head.status' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-2 text-right">Grund für Ablehnung</th>
 | 
					        <th class="col-sm-2 text-right">{{'request.award.table.head.reject.reason' | translate}}</th>
 | 
				
			||||||
      </tr>
 | 
					      </tr>
 | 
				
			||||||
      </thead>
 | 
					      </thead>
 | 
				
			||||||
      <tbody *ngFor="let award of awards">
 | 
					      <tbody *ngFor="let award of awards">
 | 
				
			||||||
| 
						 | 
					@ -96,7 +96,15 @@
 | 
				
			||||||
          {{award.date | date: 'dd.MM.yyyy'}}
 | 
					          {{award.date | date: 'dd.MM.yyyy'}}
 | 
				
			||||||
        </td>
 | 
					        </td>
 | 
				
			||||||
        <td class="text-center">
 | 
					        <td class="text-center">
 | 
				
			||||||
          {{award.confirmed === 0? 'In Bearbeitung' : (award.confirmed === 1? 'Genehmigt' : 'Abgelehnt')}}
 | 
					           <span *ngIf="award.confirmed === 0">
 | 
				
			||||||
 | 
					            {{'request.award.table.status.progressing' | translate}}
 | 
				
			||||||
 | 
					          </span>
 | 
				
			||||||
 | 
					          <span *ngIf="award.confirmed === 1">
 | 
				
			||||||
 | 
					            {{'request.award.table.status.accepted' | translate}}
 | 
				
			||||||
 | 
					          </span>
 | 
				
			||||||
 | 
					          <span *ngIf="award.confirmed !== 0 && award.confirmed !== 1">
 | 
				
			||||||
 | 
					            {{'request.award.table.status.rejected' | translate}}
 | 
				
			||||||
 | 
					          </span>
 | 
				
			||||||
        </td>
 | 
					        </td>
 | 
				
			||||||
        <td class="text-right">
 | 
					        <td class="text-right">
 | 
				
			||||||
          {{award.rejectReason ? award.rejectReason : ''}}
 | 
					          {{award.rejectReason ? award.rejectReason : ''}}
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -82,10 +82,10 @@ export class RequestAwardComponent implements OnInit {
 | 
				
			||||||
  addAwarding(previewImage, descriptionField) {
 | 
					  addAwarding(previewImage, descriptionField) {
 | 
				
			||||||
    if (this.decoration._id && this.reason.length > 0) {
 | 
					    if (this.decoration._id && this.reason.length > 0) {
 | 
				
			||||||
      const award: Award = {
 | 
					      const award: Award = {
 | 
				
			||||||
        'userId': this.user._id,
 | 
					        userId: this.user._id,
 | 
				
			||||||
        'decorationId': this.decoration._id,
 | 
					        decorationId: this.decoration._id,
 | 
				
			||||||
        'reason': this.reason,
 | 
					        reason: this.reason,
 | 
				
			||||||
        'date': Date.now()
 | 
					        date: Date.now()
 | 
				
			||||||
      };
 | 
					      };
 | 
				
			||||||
      this.awardingService.requestAwarding(award).subscribe(() => {
 | 
					      this.awardingService.requestAwarding(award).subscribe(() => {
 | 
				
			||||||
        this.awardingService.getUserAwardings(this.user._id)
 | 
					        this.awardingService.getUserAwardings(this.user._id)
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -1,18 +1,18 @@
 | 
				
			||||||
<form #form="ngForm" class="overview">
 | 
					<form #form="ngForm" class="overview">
 | 
				
			||||||
  <h3>Offene Anträge - Auszeichnungen</h3>
 | 
					  <h3>{{'request.confirm.award.headline' | translate}}</h3>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <div class="table-container">
 | 
					  <div class="table-container">
 | 
				
			||||||
    <table class="table table-hover">
 | 
					    <table class="table table-hover">
 | 
				
			||||||
      <thead>
 | 
					      <thead>
 | 
				
			||||||
      <tr>
 | 
					      <tr>
 | 
				
			||||||
        <th class="col-sm-1">Teilnehmer</th>
 | 
					        <th class="col-sm-1">{{'request.confirm.award.table.head.participant' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1"></th>
 | 
					        <th class="col-sm-1"></th>
 | 
				
			||||||
        <th class="col-sm-2">Auszeichnung</th>
 | 
					        <th class="col-sm-2">{{'request.confirm.award.table.head.award' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-2">Begründung</th>
 | 
					        <th class="col-sm-2">{{'request.confirm.award.table.head.reason' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1 ">Antragsteller</th>
 | 
					        <th class="col-sm-1 ">{{'request.confirm.award.table.head.requester' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1 text-right">Datum</th>
 | 
					        <th class="col-sm-1 text-right">{{'request.confirm.award.table.head.date' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-2 text-right"></th>
 | 
					        <th class="col-sm-2 text-right"></th>
 | 
				
			||||||
        <th class="col-sm-1 text-right">Aktion</th>
 | 
					        <th class="col-sm-1 text-right">{{'request.confirm.award.table.head.action' | translate}}</th>
 | 
				
			||||||
      </tr>
 | 
					      </tr>
 | 
				
			||||||
      </thead>
 | 
					      </thead>
 | 
				
			||||||
      <tbody *ngFor="let award of awards">
 | 
					      <tbody *ngFor="let award of awards">
 | 
				
			||||||
| 
						 | 
					@ -43,16 +43,19 @@
 | 
				
			||||||
        <td>
 | 
					        <td>
 | 
				
			||||||
          <textarea style="width: 100%;"
 | 
					          <textarea style="width: 100%;"
 | 
				
			||||||
                    rows="3"
 | 
					                    rows="3"
 | 
				
			||||||
                    placeholder="Begründung für Ablehnung (optional)"
 | 
					                    placeholder="{{'request.confirm.award.table.reject.reason.placeholder' | translate}}"
 | 
				
			||||||
                    #rejectReason></textarea>
 | 
					                    #rejectReason></textarea>
 | 
				
			||||||
        </td>
 | 
					        </td>
 | 
				
			||||||
        <td class="text-right">
 | 
					        <td class="text-right">
 | 
				
			||||||
          <a class="action" (click)="confirm(award, true, reason.value)">Bestätigen</a><br>
 | 
					          <a class="action" (click)="confirm(award, true, reason.value)">
 | 
				
			||||||
          <a class="action" (click)="confirm(award, false, reason.value, rejectReason.value)">Ablehnen</a>
 | 
					            {{'request.confirm.award.table.button.action.accept' | translate}}
 | 
				
			||||||
 | 
					          </a><br>
 | 
				
			||||||
 | 
					          <a class="action" (click)="confirm(award, false, reason.value, rejectReason.value)">
 | 
				
			||||||
 | 
					            {{'request.confirm.award.table.button.action.reject' | translate}}
 | 
				
			||||||
 | 
					          </a>
 | 
				
			||||||
        </td>
 | 
					        </td>
 | 
				
			||||||
      </tr>
 | 
					      </tr>
 | 
				
			||||||
      </tbody>
 | 
					      </tbody>
 | 
				
			||||||
    </table>
 | 
					    </table>
 | 
				
			||||||
  </div>
 | 
					  </div>
 | 
				
			||||||
 | 
					 | 
				
			||||||
</form>
 | 
					</form>
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -1,18 +1,18 @@
 | 
				
			||||||
<form #form="ngForm" class="overview">
 | 
					<form #form="ngForm" class="overview">
 | 
				
			||||||
  <h3>Offene Anträge - Beförderung</h3>
 | 
					  <h3>{{'request.confirm.promotion.headline' | translate}}</h3>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <div class="table-container">
 | 
					  <div class="table-container">
 | 
				
			||||||
    <table class="table table-hover">
 | 
					    <table class="table table-hover">
 | 
				
			||||||
      <thead>
 | 
					      <thead>
 | 
				
			||||||
      <tr>
 | 
					      <tr>
 | 
				
			||||||
        <th class="col-sm-1">Teilnehmer</th>
 | 
					        <th class="col-sm-1">{{'request.confirm.promotion.table.head.participant' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1">Alter Rang</th>
 | 
					        <th class="col-sm-1">{{'request.confirm.promotion.table.head.rank.before' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1">Neuer Rang</th>
 | 
					        <th class="col-sm-1">{{'request.confirm.promotion.table.head.rank.after' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1 ">Antragsteller</th>
 | 
					        <th class="col-sm-1 ">{{'"request.confirm.promotion.table.head.requester' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1 text-center">Datum</th>
 | 
					        <th class="col-sm-1 text-center">{{'request.confirm.promotion.table.head.date' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1 text-center">Status</th>
 | 
					        <th class="col-sm-1 text-center">{{'request.confirm.promotion.table.head.status' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-2 text-right"></th>
 | 
					        <th class="col-sm-2 text-right"></th>
 | 
				
			||||||
        <th class="col-sm-1 text-right">Aktion</th>
 | 
					        <th class="col-sm-1 text-right">{{'request.confirm.promotion.table.head.action' | translate}}</th>
 | 
				
			||||||
      </tr>
 | 
					      </tr>
 | 
				
			||||||
      </thead>
 | 
					      </thead>
 | 
				
			||||||
      <tbody *ngFor="let promotion of promotions">
 | 
					      <tbody *ngFor="let promotion of promotions">
 | 
				
			||||||
| 
						 | 
					@ -33,17 +33,29 @@
 | 
				
			||||||
          {{promotion.timestamp | date: 'dd.MM.yyyy'}}
 | 
					          {{promotion.timestamp | date: 'dd.MM.yyyy'}}
 | 
				
			||||||
        </td>
 | 
					        </td>
 | 
				
			||||||
        <td class="text-center">
 | 
					        <td class="text-center">
 | 
				
			||||||
          {{promotion.confirmed === 0? 'In Bearbeitung' : (promotion.confirmed === 1? 'Genehmigt' : 'Abgelehnt')}}
 | 
					          <span *ngIf="promotion.confirmed === 0">
 | 
				
			||||||
 | 
					            {{'request.confirm.promotion.table.status.progressing' | translate}}
 | 
				
			||||||
 | 
					          </span>
 | 
				
			||||||
 | 
					          <span *ngIf="promotion.confirmed === 1">
 | 
				
			||||||
 | 
					            {{'request.confirm.promotion.table.status.accepted' | translate}}
 | 
				
			||||||
 | 
					          </span>
 | 
				
			||||||
 | 
					          <span *ngIf="promotion.confirmed !== 0 && promotion.confirmed !== 1">
 | 
				
			||||||
 | 
					            {{'request.confirm.promotion.table.status.rejected' | translate}}
 | 
				
			||||||
 | 
					          </span>
 | 
				
			||||||
        </td>
 | 
					        </td>
 | 
				
			||||||
        <td>
 | 
					        <td>
 | 
				
			||||||
          <textarea style="width: 100%;"
 | 
					          <textarea style="width: 100%;"
 | 
				
			||||||
                    rows="3"
 | 
					                    rows="3"
 | 
				
			||||||
                    placeholder="Begründung für Ablehnung (optional)"
 | 
					                    placeholder="{{'request.confirm.promotion.table.reject.reason.placeholder' | translate}}"
 | 
				
			||||||
                    #rejectReason></textarea>
 | 
					                    #rejectReason></textarea>
 | 
				
			||||||
        </td>
 | 
					        </td>
 | 
				
			||||||
        <td class="text-right">
 | 
					        <td class="text-right">
 | 
				
			||||||
          <a class="action" (click)="confirm(promotion, true)">Bestätigen</a><br>
 | 
					          <a class="action" (click)="confirm(promotion, true)">
 | 
				
			||||||
          <a class="action" (click)="confirm(promotion, false, rejectReason.value)">Ablehnen</a>
 | 
					            {{'request.confirm.promotion.table.button.action.accept' | translate}}
 | 
				
			||||||
 | 
					          </a><br>
 | 
				
			||||||
 | 
					          <a class="action" (click)="confirm(promotion, false, rejectReason.value)">
 | 
				
			||||||
 | 
					            {{'request.confirm.promotion.table.button.action.reject' | translate}}
 | 
				
			||||||
 | 
					          </a>
 | 
				
			||||||
        </td>
 | 
					        </td>
 | 
				
			||||||
      </tr>
 | 
					      </tr>
 | 
				
			||||||
      </tbody>
 | 
					      </tbody>
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -1,8 +1,8 @@
 | 
				
			||||||
<form #form="ngForm" class="overview">
 | 
					<form #form="ngForm" class="overview">
 | 
				
			||||||
  <h3>Beförderung beantragen</h3>
 | 
					  <h3>{{'request.promotion.headline' | translate}}</h3>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <div class="form-group">
 | 
					  <div class="form-group">
 | 
				
			||||||
    <label for="user">Teilnehmer</label>
 | 
					    <label for="user">{{'request.promotion.field.participant' | translate}}</label>
 | 
				
			||||||
    <select class="form-control"
 | 
					    <select class="form-control"
 | 
				
			||||||
            name="user"
 | 
					            name="user"
 | 
				
			||||||
            id="user"
 | 
					            id="user"
 | 
				
			||||||
| 
						 | 
					@ -10,7 +10,7 @@
 | 
				
			||||||
            [compareWith]="equals"
 | 
					            [compareWith]="equals"
 | 
				
			||||||
            required
 | 
					            required
 | 
				
			||||||
            (change)="toggleUser()">
 | 
					            (change)="toggleUser()">
 | 
				
			||||||
      <option [ngValue]="{_id: '0'}">Auswählen...</option>
 | 
					      <option [ngValue]="{_id: '0'}">{{'request.promotion.field.participant.placeholder' | translate}}</option>
 | 
				
			||||||
      <option *ngFor="let user of users" [ngValue]="user">
 | 
					      <option *ngFor="let user of users" [ngValue]="user">
 | 
				
			||||||
        {{user.username}}
 | 
					        {{user.username}}
 | 
				
			||||||
      </option>
 | 
					      </option>
 | 
				
			||||||
| 
						 | 
					@ -20,7 +20,7 @@
 | 
				
			||||||
  <div *ngIf="showForm">
 | 
					  <div *ngIf="showForm">
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    <div class="form-group">
 | 
					    <div class="form-group">
 | 
				
			||||||
      <label for="user">Aktueller Rang</label>
 | 
					      <label for="user">{{'request.promotion.field.rank.before' | translate}}</label>
 | 
				
			||||||
      <input class="form-control"
 | 
					      <input class="form-control"
 | 
				
			||||||
             [(ngModel)]="selectedUserRank"
 | 
					             [(ngModel)]="selectedUserRank"
 | 
				
			||||||
             [ngModelOptions]="{standalone: true}"
 | 
					             [ngModelOptions]="{standalone: true}"
 | 
				
			||||||
| 
						 | 
					@ -28,7 +28,7 @@
 | 
				
			||||||
    </div>
 | 
					    </div>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    <div class="form-group">
 | 
					    <div class="form-group">
 | 
				
			||||||
      <label for="decoration">Neuer Rang</label>
 | 
					      <label for="decoration">{{'request.promotion.field.rank.after' | translate}}</label>
 | 
				
			||||||
      <select class="form-control"
 | 
					      <select class="form-control"
 | 
				
			||||||
              name="decoration"
 | 
					              name="decoration"
 | 
				
			||||||
              id="decoration"
 | 
					              id="decoration"
 | 
				
			||||||
| 
						 | 
					@ -46,7 +46,7 @@
 | 
				
			||||||
  <button id="cancel"
 | 
					  <button id="cancel"
 | 
				
			||||||
          (click)="cancel()"
 | 
					          (click)="cancel()"
 | 
				
			||||||
          class="btn btn-default">
 | 
					          class="btn btn-default">
 | 
				
			||||||
    Abbrechen
 | 
					    {{'request.promotion.button.cancel' | translate}}
 | 
				
			||||||
  </button>
 | 
					  </button>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <button id="save"
 | 
					  <button id="save"
 | 
				
			||||||
| 
						 | 
					@ -54,7 +54,7 @@
 | 
				
			||||||
          (click)="addPromotion()"
 | 
					          (click)="addPromotion()"
 | 
				
			||||||
          class="btn btn-default"
 | 
					          class="btn btn-default"
 | 
				
			||||||
          [disabled]="newLevel === user.rankLvl">
 | 
					          [disabled]="newLevel === user.rankLvl">
 | 
				
			||||||
    Bestätigen
 | 
					    {{'request.promotion.button.submit' | translate}}
 | 
				
			||||||
  </button>
 | 
					  </button>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <div class="table-container">
 | 
					  <div class="table-container">
 | 
				
			||||||
| 
						 | 
					@ -62,13 +62,13 @@
 | 
				
			||||||
    <table class="table table-hover">
 | 
					    <table class="table table-hover">
 | 
				
			||||||
      <thead>
 | 
					      <thead>
 | 
				
			||||||
      <tr>
 | 
					      <tr>
 | 
				
			||||||
        <th class="col-sm-1">Teilnehmer</th>
 | 
					        <th class="col-sm-1">{{'request.promotion.table.head.participant' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1">Alter Rang</th>
 | 
					        <th class="col-sm-1">{{'request.promotion.table.head.rank.before' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1">Neuer Rang</th>
 | 
					        <th class="col-sm-1">{{'request.promotion.table.head.rank.after' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1 ">Antragsteller</th>
 | 
					        <th class="col-sm-1 ">{{'request.promotion.table.head.requester' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1 text-center">Datum</th>
 | 
					        <th class="col-sm-1 text-center">{{'request.promotion.table.head.date' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1 text-center">Status</th>
 | 
					        <th class="col-sm-1 text-center">{{'request.promotion.table.head.status' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-2 text-right">Grund für Ablehnung</th>
 | 
					        <th class="col-sm-2 text-right">{{'request.promotion.table.head.reject.reason' | translate}}</th>
 | 
				
			||||||
      </tr>
 | 
					      </tr>
 | 
				
			||||||
      </thead>
 | 
					      </thead>
 | 
				
			||||||
      <tbody *ngFor="let promotion of uncheckedPromotions">
 | 
					      <tbody *ngFor="let promotion of uncheckedPromotions">
 | 
				
			||||||
| 
						 | 
					@ -89,10 +89,18 @@
 | 
				
			||||||
          {{promotion.timestamp | date: 'dd.MM.yyyy'}}
 | 
					          {{promotion.timestamp | date: 'dd.MM.yyyy'}}
 | 
				
			||||||
        </td>
 | 
					        </td>
 | 
				
			||||||
        <td class="text-center">
 | 
					        <td class="text-center">
 | 
				
			||||||
          {{promotion.confirmed === 0? 'In Bearbeitung' : (promotion.confirmed === 1? 'Genehmigt' : 'Abgelehnt')}}
 | 
					          <span *ngIf="promotion.confirmed === 0">
 | 
				
			||||||
 | 
					            {{'request.confirm.promotion.table.status.progressing' | translate}}
 | 
				
			||||||
 | 
					          </span>
 | 
				
			||||||
 | 
					          <span *ngIf="promotion.confirmed === 1">
 | 
				
			||||||
 | 
					            {{'request.confirm.promotion.table.status.accepted' | translate}}
 | 
				
			||||||
 | 
					          </span>
 | 
				
			||||||
 | 
					          <span *ngIf="promotion.confirmed !== 0 && promotion.confirmed !== 1">
 | 
				
			||||||
 | 
					            {{'request.confirm.promotion.table.status.rejected' | translate}}
 | 
				
			||||||
 | 
					          </span>
 | 
				
			||||||
        </td>
 | 
					        </td>
 | 
				
			||||||
        <td class="text-right">
 | 
					        <td class="text-right">
 | 
				
			||||||
          {{promotion.rejectReason ? promotion.rejectReason : ''}}
 | 
					          <span *ngIf="promotion.rejectReason">{{promotion.rejectReason}}</span>
 | 
				
			||||||
        </td>
 | 
					        </td>
 | 
				
			||||||
      </tr>
 | 
					      </tr>
 | 
				
			||||||
      </tbody>
 | 
					      </tbody>
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -98,5 +98,4 @@ export class RequestPromotionComponent implements OnInit {
 | 
				
			||||||
      return o1._id === o2._id;
 | 
					      return o1._id === o2._id;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -1,11 +1,13 @@
 | 
				
			||||||
import {Component} from '@angular/core';
 | 
					import {Component} from '@angular/core';
 | 
				
			||||||
 | 
					import {TranslateService} from '@ngx-translate/core';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@Component({
 | 
					@Component({
 | 
				
			||||||
  selector: 'cc-request',
 | 
					  selector: 'cc-request-root',
 | 
				
			||||||
  templateUrl: 'request.component.html',
 | 
					  templateUrl: 'request.component.html',
 | 
				
			||||||
  styleUrls: ['request.component.css']
 | 
					  styleUrls: ['request.component.css']
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
export class RequestComponent {
 | 
					export class RequestComponent {
 | 
				
			||||||
  constructor() {
 | 
					  constructor(private translate: TranslateService) {
 | 
				
			||||||
 | 
					    translate.setDefaultLang('de');
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -9,11 +9,38 @@ import {ConfirmPromotionComponent} from './confirm-promotion/confirm-promotion.c
 | 
				
			||||||
import {RequestAwardComponent} from './award/req-award.component';
 | 
					import {RequestAwardComponent} from './award/req-award.component';
 | 
				
			||||||
import {RequestPromotionComponent} from './promotion/req-promotion.component';
 | 
					import {RequestPromotionComponent} from './promotion/req-promotion.component';
 | 
				
			||||||
import {SqlDashboardComponent} from './sql-dashboard/sql-dashboard.component';
 | 
					import {SqlDashboardComponent} from './sql-dashboard/sql-dashboard.component';
 | 
				
			||||||
 | 
					import {HttpClient} from '@angular/common/http';
 | 
				
			||||||
 | 
					import {TranslateHttpLoader} from '@ngx-translate/http-loader';
 | 
				
			||||||
 | 
					import {TranslateLoader, TranslateModule} from '@ngx-translate/core';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					export function createTranslateLoader(http: HttpClient) {
 | 
				
			||||||
 | 
					  return new TranslateHttpLoader(http, './assets/i18n/request/', '.json');
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@NgModule({
 | 
					@NgModule({
 | 
				
			||||||
  declarations: [RequestComponent, RequestPromotionComponent, RequestAwardComponent, ConfirmPromotionComponent,
 | 
					  declarations: [
 | 
				
			||||||
    ConfirmAwardComponent, SqlDashboardComponent, FilterRankPipe],
 | 
					    RequestComponent,
 | 
				
			||||||
  imports: [CommonModule, SharedModule, requestRouterModule]
 | 
					    RequestPromotionComponent,
 | 
				
			||||||
 | 
					    RequestAwardComponent,
 | 
				
			||||||
 | 
					    ConfirmPromotionComponent,
 | 
				
			||||||
 | 
					    ConfirmAwardComponent,
 | 
				
			||||||
 | 
					    SqlDashboardComponent,
 | 
				
			||||||
 | 
					    FilterRankPipe
 | 
				
			||||||
 | 
					  ],
 | 
				
			||||||
 | 
					  imports: [
 | 
				
			||||||
 | 
					    CommonModule,
 | 
				
			||||||
 | 
					    SharedModule,
 | 
				
			||||||
 | 
					    requestRouterModule,
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    TranslateModule.forChild({
 | 
				
			||||||
 | 
					      loader: {
 | 
				
			||||||
 | 
					        provide: TranslateLoader,
 | 
				
			||||||
 | 
					        useFactory: (createTranslateLoader),
 | 
				
			||||||
 | 
					        deps: [HttpClient]
 | 
				
			||||||
 | 
					      },
 | 
				
			||||||
 | 
					      isolate: true
 | 
				
			||||||
 | 
					    })
 | 
				
			||||||
 | 
					  ]
 | 
				
			||||||
})
 | 
					})
 | 
				
			||||||
export class RequestModule {
 | 
					export class RequestModule {
 | 
				
			||||||
  static routes = requestRouterModule;
 | 
					  static routes = requestRouterModule;
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -11,9 +11,11 @@ import {LoginGuardHL, LoginGuardSQL} from '../login';
 | 
				
			||||||
import {SqlDashboardComponent} from './sql-dashboard/sql-dashboard.component';
 | 
					import {SqlDashboardComponent} from './sql-dashboard/sql-dashboard.component';
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					
 | 
				
			||||||
export const requestRoutes: Routes = [{
 | 
					export const requestRoutes: Routes = [
 | 
				
			||||||
  path: '', component: RequestComponent
 | 
					  {
 | 
				
			||||||
},
 | 
					    path: '',
 | 
				
			||||||
 | 
					    component: RequestComponent,
 | 
				
			||||||
 | 
					    children: [
 | 
				
			||||||
      {
 | 
					      {
 | 
				
			||||||
        path: RouteConfig.requestAwardPath,
 | 
					        path: RouteConfig.requestAwardPath,
 | 
				
			||||||
        component: RequestAwardComponent,
 | 
					        component: RequestAwardComponent,
 | 
				
			||||||
| 
						 | 
					@ -39,6 +41,8 @@ export const requestRoutes: Routes = [{
 | 
				
			||||||
        component: ConfirmPromotionComponent,
 | 
					        component: ConfirmPromotionComponent,
 | 
				
			||||||
        canActivate: [LoginGuardHL]
 | 
					        canActivate: [LoginGuardHL]
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
 | 
					    ]
 | 
				
			||||||
 | 
					  },
 | 
				
			||||||
];
 | 
					];
 | 
				
			||||||
 | 
					
 | 
				
			||||||
export const requestRouterModule: ModuleWithProviders = RouterModule.forChild(requestRoutes);
 | 
					export const requestRouterModule: ModuleWithProviders = RouterModule.forChild(requestRoutes);
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -1,16 +1,16 @@
 | 
				
			||||||
<div class="overview">
 | 
					<div class="overview">
 | 
				
			||||||
  <h3>SQL Dashboard</h3>
 | 
					  <h3>{{'request.sql.dashboard.headline' | translate}}</h3>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <div class="table-container">
 | 
					  <div class="table-container">
 | 
				
			||||||
    <label>Beförderungsanträge</label>
 | 
					    <label>{{'request.confirm.promotion.headline' | translate}}</label>
 | 
				
			||||||
    <table class="table table-hover">
 | 
					    <table class="table table-hover">
 | 
				
			||||||
      <thead>
 | 
					      <thead>
 | 
				
			||||||
      <tr>
 | 
					      <tr>
 | 
				
			||||||
        <th class="col-sm-1">Teilnehmer</th>
 | 
					        <th class="col-sm-1">{{'request.confirm.promotion.table.head.participant' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1">Alter Rang</th>
 | 
					        <th class="col-sm-1">{{'request.confirm.promotion.table.head.rank.before' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1">Neuer Rang</th>
 | 
					        <th class="col-sm-1">{{'request.confirm.promotion.table.head.rank.after' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1 ">Antragsteller</th>
 | 
					        <th class="col-sm-1 ">{{'request.confirm.promotion.table.head.requester' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1 text-center">Datum</th>
 | 
					        <th class="col-sm-1 text-center">{{'request.confirm.promotion.table.head.date' | translate}}</th>
 | 
				
			||||||
      </tr>
 | 
					      </tr>
 | 
				
			||||||
      </thead>
 | 
					      </thead>
 | 
				
			||||||
      <tbody *ngFor="let promotion of promotions">
 | 
					      <tbody *ngFor="let promotion of promotions">
 | 
				
			||||||
| 
						 | 
					@ -36,16 +36,16 @@
 | 
				
			||||||
  </div>
 | 
					  </div>
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  <div class="table-container">
 | 
					  <div class="table-container">
 | 
				
			||||||
    <label>Anträge für Orden/ Auszeichnungen</label>
 | 
					    <label>{{'request.confirm.award.headline' | translate}}</label>
 | 
				
			||||||
    <table class="table table-hover">
 | 
					    <table class="table table-hover">
 | 
				
			||||||
      <thead>
 | 
					      <thead>
 | 
				
			||||||
      <tr>
 | 
					      <tr>
 | 
				
			||||||
        <th class="col-sm-1">Teilnehmer</th>
 | 
					        <th class="col-sm-1">{{'request.confirm.award.table.head.participant' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1">Bild</th>
 | 
					        <th class="col-sm-1"></th>
 | 
				
			||||||
        <th class="col-sm-2">Bezeichnung</th>
 | 
					        <th class="col-sm-2">{{'request.confirm.award.table.head.award' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-2">Begründung</th>
 | 
					        <th class="col-sm-2">{{'request.confirm.award.table.head.reason' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1 ">Antragsteller</th>
 | 
					        <th class="col-sm-1 ">{{'request.confirm.award.table.head.requester' | translate}}</th>
 | 
				
			||||||
        <th class="col-sm-1 text-right">Datum</th>
 | 
					        <th class="col-sm-1 text-right">{{'request.confirm.award.table.head.date' | translate}}</th>
 | 
				
			||||||
      </tr>
 | 
					      </tr>
 | 
				
			||||||
      </thead>
 | 
					      </thead>
 | 
				
			||||||
      <tbody *ngFor="let award of awards">
 | 
					      <tbody *ngFor="let award of awards">
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -0,0 +1,72 @@
 | 
				
			||||||
 | 
					{
 | 
				
			||||||
 | 
					  "public.error.message.required": "{{fieldName}} ist ein Pflichtfeld",
 | 
				
			||||||
 | 
					  "public.error.message.min.length": "{{fieldName}} muss mindestens {{boundary}} Zeichen enthalten",
 | 
				
			||||||
 | 
					  "public.error.message.max.length": "{{fieldName}} darf maximal {{boundary}} Zeichen enthalten",
 | 
				
			||||||
 | 
					  "public.error.message.email": "Bitte geben Sie eine gültige E-Mail Adresse an",
 | 
				
			||||||
 | 
					  "public.error.message.no.user": "Der eingetragene Benutzer existiert nicht.",
 | 
				
			||||||
 | 
					  "public.error.message.default": "{{fieldName}} ist nicht valide",
 | 
				
			||||||
 | 
					  "public.common.search.button": "Suchen",
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  "request.confirm.award.headline": "Offene Anträge - Auszeichnungen",
 | 
				
			||||||
 | 
					  "request.confirm.award.table.head.participant": "Teilnehmer",
 | 
				
			||||||
 | 
					  "request.confirm.award.table.head.award": "Auszeichnung",
 | 
				
			||||||
 | 
					  "request.confirm.award.table.head.reason": "Begründung",
 | 
				
			||||||
 | 
					  "request.confirm.award.table.head.requester": "Antragsteller",
 | 
				
			||||||
 | 
					  "request.confirm.award.table.head.date": "Datum",
 | 
				
			||||||
 | 
					  "request.confirm.award.table.head.action": "Aktion",
 | 
				
			||||||
 | 
					  "request.confirm.award.table.reject.reason.placeholder": "Begründung für Ablehnung (optional)",
 | 
				
			||||||
 | 
					  "request.confirm.award.table.button.action.accept": "Bestätigen",
 | 
				
			||||||
 | 
					  "request.confirm.award.table.button.action.reject": "Ablehnen",
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  "request.confirm.promotion.headline": "Offene Anträge - Beförderungen",
 | 
				
			||||||
 | 
					  "request.confirm.promotion.table.head.participant": "Teilnehmer",
 | 
				
			||||||
 | 
					  "request.confirm.promotion.table.head.rank.before": "Alter Rang",
 | 
				
			||||||
 | 
					  "request.confirm.promotion.table.head.rank.after": "Neuer Rang",
 | 
				
			||||||
 | 
					  "request.confirm.promotion.table.head.requester": "Antragsteller",
 | 
				
			||||||
 | 
					  "request.confirm.promotion.table.head.date": "Datum",
 | 
				
			||||||
 | 
					  "request.confirm.promotion.table.head.status": "Status",
 | 
				
			||||||
 | 
					  "request.confirm.promotion.table.head.action": "Aktion",
 | 
				
			||||||
 | 
					  "request.confirm.promotion.table.reject.reason.placeholder": "Begründung für Ablehnung (optional)",
 | 
				
			||||||
 | 
					  "request.confirm.promotion.table.button.action.accept": "Bestätigen",
 | 
				
			||||||
 | 
					  "request.confirm.promotion.table.button.action.reject": "Ablehnen",
 | 
				
			||||||
 | 
					  "request.confirm.promotion.table.status.progressing": "In Bearbeitung",
 | 
				
			||||||
 | 
					  "request.confirm.promotion.table.status.accepted": "Genehmigt",
 | 
				
			||||||
 | 
					  "request.confirm.promotion.table.status.rejected": "Abgelehnt",
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  "request.award.headline": "Auszeichnung beantragen",
 | 
				
			||||||
 | 
					  "request.award.field.user": "Teilnehmer",
 | 
				
			||||||
 | 
					  "request.award.field.user.placeholder": "Auswählen...",
 | 
				
			||||||
 | 
					  "request.award.field.award": "Auszeichnung",
 | 
				
			||||||
 | 
					  "request.award.field.award.placeholder": "Auswählen...",
 | 
				
			||||||
 | 
					  "request.award.field.reason": "Begründung",
 | 
				
			||||||
 | 
					  "request.award.field.reason.placeholder": "Begründung eingeben...",
 | 
				
			||||||
 | 
					  "request.award.button.cancel": "Abbrechen",
 | 
				
			||||||
 | 
					  "request.award.button.submit": "Bestätigen",
 | 
				
			||||||
 | 
					  "request.award.table.head.image": "Bild",
 | 
				
			||||||
 | 
					  "request.award.table.head.name": "Bezeichnung",
 | 
				
			||||||
 | 
					  "request.award.table.head.reason": "Begründung",
 | 
				
			||||||
 | 
					  "request.award.table.head.requester": "Antragsteller",
 | 
				
			||||||
 | 
					  "request.award.table.head.date": "Datum",
 | 
				
			||||||
 | 
					  "request.award.table.head.status": "Status",
 | 
				
			||||||
 | 
					  "request.award.table.head.reject.reason": "Grund für Ablehnung",
 | 
				
			||||||
 | 
					  "request.award.table.status.progressing": "In Bearbeitung",
 | 
				
			||||||
 | 
					  "request.award.table.status.accepted": "Genehmigt",
 | 
				
			||||||
 | 
					  "request.award.table.status.rejected": "Abgelehnt",
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  "request.promotion.headline": "Beförderung beantragen",
 | 
				
			||||||
 | 
					  "request.promotion.field.participant": "Teilnehmer",
 | 
				
			||||||
 | 
					  "request.promotion.field.participant.placeholder": "Auswählen...",
 | 
				
			||||||
 | 
					  "request.promotion.field.rank.before": "Aktueller Rang",
 | 
				
			||||||
 | 
					  "request.promotion.field.rank.after": "Neuer Rang",
 | 
				
			||||||
 | 
					  "request.promotion.button.submit": "Bestätigen",
 | 
				
			||||||
 | 
					  "request.promotion.button.cancel": "Abbrechen",
 | 
				
			||||||
 | 
					  "request.promotion.table.head.participant": "Teilnehmer",
 | 
				
			||||||
 | 
					  "request.promotion.table.head.rank.before": "Alter Rang",
 | 
				
			||||||
 | 
					  "request.promotion.table.head.rank.after": "Neuer Rang",
 | 
				
			||||||
 | 
					  "request.promotion.table.head.requester": "Antragsteller",
 | 
				
			||||||
 | 
					  "request.promotion.table.head.date": "Datum",
 | 
				
			||||||
 | 
					  "request.promotion.table.head.status": "Status",
 | 
				
			||||||
 | 
					  "request.promotion.table.head.reject.reason": "Grund für Ablehnung",
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  "request.sql.dashboard.headline":"SQL Dashboard"
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
| 
						 | 
					@ -0,0 +1,2 @@
 | 
				
			||||||
 | 
					{
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
		Loading…
	
		Reference in New Issue