[DEV] add ariane flow (fix mode)
This commit is contained in:
parent
c6bae2cae1
commit
7ea7446335
@ -10,6 +10,7 @@ import { Location } from '@angular/common';
|
||||
import { fadeInAnimation } from '../_animations/index';
|
||||
|
||||
import { GroupService } from '../group.service';
|
||||
import { ArianeService } from '../ariane.service';
|
||||
|
||||
@Component({
|
||||
selector: 'app-group-detail',
|
||||
@ -28,7 +29,8 @@ export class GroupDetailComponent implements OnInit {
|
||||
constructor(private route: ActivatedRoute,
|
||||
private router: Router,
|
||||
private locate: Location,
|
||||
private groupService: GroupService) {
|
||||
private groupService: GroupService,
|
||||
private arianeService: ArianeService) {
|
||||
|
||||
}
|
||||
|
||||
@ -55,6 +57,7 @@ export class GroupDetailComponent implements OnInit {
|
||||
}
|
||||
onSelectSaison(_idSelected: number):void {
|
||||
this.router.navigate(['saison/' + _idSelected ]);
|
||||
this.arianeService.setSaison(_idSelected);
|
||||
}
|
||||
|
||||
onSelectVideo(_idSelected: number):void {
|
||||
|
@ -10,6 +10,7 @@ import { Location } from '@angular/common';
|
||||
import { fadeInAnimation } from '../_animations/index';
|
||||
|
||||
import { TypeService } from '../type.service';
|
||||
import { ArianeService } from '../ariane.service';
|
||||
|
||||
@Component({
|
||||
selector: 'app-home',
|
||||
@ -23,7 +24,8 @@ export class HomeComponent implements OnInit {
|
||||
error = "";
|
||||
constructor(private router: Router,
|
||||
private locate: Location,
|
||||
private typeService: TypeService) {
|
||||
private typeService: TypeService,
|
||||
private arianeService: ArianeService) {
|
||||
|
||||
}
|
||||
|
||||
@ -37,8 +39,10 @@ export class HomeComponent implements OnInit {
|
||||
self.error = "Wrong e-mail/login or password";
|
||||
self.data_list = []
|
||||
});
|
||||
this.arianeService.reset();
|
||||
}
|
||||
onSelectType(_idSelected: number):void {
|
||||
this.arianeService.setType(_idSelected);
|
||||
//this.router.navigate(['type/', { id: _idSelected} ]);
|
||||
this.router.navigate(['type/' + _idSelected ]);
|
||||
}
|
||||
|
@ -10,6 +10,7 @@ import { Location } from '@angular/common';
|
||||
import { fadeInAnimation } from '../_animations/index';
|
||||
|
||||
import { SaisonService } from '../saison.service';
|
||||
import { ArianeService } from '../ariane.service';
|
||||
|
||||
@Component({
|
||||
selector: 'app-saison-detail',
|
||||
@ -26,7 +27,8 @@ export class SaisonDetailComponent implements OnInit {
|
||||
constructor(private route: ActivatedRoute,
|
||||
private router: Router,
|
||||
private locate: Location,
|
||||
private saisonService: SaisonService) {
|
||||
private saisonService: SaisonService,
|
||||
private arianeService: ArianeService) {
|
||||
|
||||
}
|
||||
|
||||
|
@ -4,6 +4,15 @@
|
||||
(click)="onHome()">
|
||||
<i class="material-icons">home</i> Home
|
||||
</button>
|
||||
<div class="ariane">
|
||||
<button class="item" *ngIf="ariane_type_id != null" title="type" (click)="onArianeType()">{{ariane_type_name}}</button>
|
||||
<div class="item_ariane_separator" *ngIf="ariane_univers_id != null && ariane_type_id != null" >/</div>
|
||||
<button class="item" *ngIf="ariane_univers_id != null" title="univers" (click)="onArianeUnivers()">{{ariane_univers_name}}</button>
|
||||
<div class="item_ariane_separator" *ngIf="ariane_group_id != null && (ariane_univers_id != null || ariane_type_id != null)" >/</div>
|
||||
<button class="item" *ngIf="ariane_group_id != null" title="group" (click)="onArianeGroup()">{{ariane_group_name}}</button>
|
||||
<div class="item_ariane_separator" *ngIf="ariane_saison_id != null && (ariane_group_id != null || ariane_univers_id != null || ariane_type_id != null)" >/</div>
|
||||
<button class="item" *ngIf="ariane_saison_id != null" title="saison" (click)="onArianeSaison()">{{ariane_saison_name}}</button>
|
||||
</div>
|
||||
<button class="item"
|
||||
*ngIf="login == null"
|
||||
style="float:right;"
|
||||
|
@ -109,6 +109,30 @@
|
||||
font-size: 17px;
|
||||
}
|
||||
|
||||
.ariane {
|
||||
display:block;
|
||||
float: left;
|
||||
line-height: 56px;
|
||||
z-index: 4;
|
||||
padding: 0 0 0 15px;
|
||||
margin: 0 3px 0 3px;
|
||||
border: 0;
|
||||
text-transform: uppercase;
|
||||
font-weight: bold;
|
||||
font-size: 15px;
|
||||
.item_ariane_separator {
|
||||
display:block;
|
||||
float: left;
|
||||
line-height: 56px;
|
||||
z-index: 4;
|
||||
margin: 0 3px 0 3px;
|
||||
border: 0;
|
||||
text-transform: uppercase;
|
||||
font-weight: bold;
|
||||
font-size: 30px;
|
||||
}
|
||||
}
|
||||
|
||||
.material-icons {
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
@ -10,6 +10,7 @@ import { Injectable, Component, OnInit } from '@angular/core';
|
||||
import { Router } from "@angular/router";
|
||||
import { ActivatedRoute, Params } from '@angular/router';
|
||||
import { SessionService } from '../session.service';
|
||||
import { ArianeService } from '../ariane.service';
|
||||
|
||||
@Component({
|
||||
selector: 'app-top-menu',
|
||||
@ -22,8 +23,21 @@ export class TopMenuComponent implements OnInit {
|
||||
public avatar: string = null;//Session.getAvatar();
|
||||
public displayUserMenu: boolean = false;
|
||||
|
||||
public ariane_type_id: number = null;
|
||||
public ariane_type_name: string = null;
|
||||
|
||||
public ariane_univers_id: number = 5;
|
||||
public ariane_univers_name: string = "sdfsdf";
|
||||
|
||||
public ariane_group_id: number = null;
|
||||
public ariane_group_name: string = null;
|
||||
|
||||
public ariane_saison_id: number = 6;
|
||||
public ariane_saison_name: string = "lkjlkjlkjlkjlkjlkj";
|
||||
|
||||
constructor(private router: Router,
|
||||
private sessionService: SessionService) {
|
||||
private sessionService: SessionService,
|
||||
private arianeService: ArianeService) {
|
||||
|
||||
}
|
||||
|
||||
@ -42,6 +56,23 @@ export class TopMenuComponent implements OnInit {
|
||||
console.log(" avatar:" + this.avatar);
|
||||
}
|
||||
});
|
||||
this.arianeService.type_change.subscribe(id => {
|
||||
console.log("zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz");
|
||||
this.ariane_type_id = id;
|
||||
this.ariane_type_name = this.arianeService.getTypeName();
|
||||
});
|
||||
this.arianeService.univers_change.subscribe(id => {
|
||||
this.ariane_univers_id = id;
|
||||
this.ariane_univers_name = this.arianeService.getUniversName();
|
||||
});
|
||||
this.arianeService.group_change.subscribe(id => {
|
||||
this.ariane_group_id = id;
|
||||
this.ariane_group_name = this.arianeService.getGroupName();
|
||||
});
|
||||
this.arianeService.saison_change.subscribe(id => {
|
||||
this.ariane_saison_id = id;
|
||||
this.ariane_saison_name = this.arianeService.getSaisonName();
|
||||
});
|
||||
}
|
||||
onAvatar(): void {
|
||||
console.log("onAvatar() " + this.displayUserMenu);
|
||||
@ -89,6 +120,22 @@ export class TopMenuComponent implements OnInit {
|
||||
console.log("onOutUserProperty ==> event...");
|
||||
this.displayUserMenu = false;
|
||||
}
|
||||
|
||||
onArianeType(): void {
|
||||
console.log("onArianeType()");
|
||||
}
|
||||
|
||||
onArianeUnivers(): void {
|
||||
console.log("onArianeUnivers()");
|
||||
}
|
||||
|
||||
onArianeGroup(): void {
|
||||
console.log("onArianeGroup()");
|
||||
}
|
||||
|
||||
onArianeSaison(): void {
|
||||
console.log("onArianeSaison()");
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
@ -10,6 +10,7 @@ import { Location } from '@angular/common';
|
||||
import { fadeInAnimation } from '../_animations/index';
|
||||
|
||||
import { TypeService } from '../type.service';
|
||||
import { ArianeService } from '../ariane.service';
|
||||
|
||||
@Component({
|
||||
selector: 'app-type-detail',
|
||||
@ -28,7 +29,8 @@ export class TypeDetailComponent implements OnInit {
|
||||
constructor(private route: ActivatedRoute,
|
||||
private router: Router,
|
||||
private locate: Location,
|
||||
private typeService: TypeService) {
|
||||
private typeService: TypeService,
|
||||
private arianeService: ArianeService) {
|
||||
/*
|
||||
this.route.params.subscribe(params => {
|
||||
console.log(params);
|
||||
@ -62,6 +64,7 @@ export class TypeDetailComponent implements OnInit {
|
||||
}
|
||||
onSelectGroup(_idSelected: number):void {
|
||||
this.router.navigate(['group/' + _idSelected ]);
|
||||
this.arianeService.setGroup(_idSelected);
|
||||
}
|
||||
|
||||
onSelectVideo(_idSelected: number):void {
|
||||
|
Loading…
Reference in New Issue
Block a user