diff --git a/front/src/app/app-routing.module.ts b/front/src/app/app-routing.module.ts index e1d468f..cb7fbe4 100644 --- a/front/src/app/app-routing.module.ts +++ b/front/src/app/app-routing.module.ts @@ -8,14 +8,15 @@ import { NgModule } from '@angular/core'; import { RouterModule, Routes } from '@angular/router'; import { ModuleWithProviders } from '@angular/core'; -import { HomeComponent } from './home/home.component'; -import { TypeDetailComponent } from './type-detail/type-detail.component'; -import { GroupDetailComponent } from './group-detail/group-detail.component'; -import { SaisonDetailComponent } from './saison-detail/saison-detail.component'; -import { VideoDetailComponent } from './video-detail/video-detail.component'; -import { LoginComponent } from './login/login.component'; -import { SignUpComponent } from './sign-up/sign-up.component'; -import { SettingsComponent } from './settings/settings.component'; +import { HomeComponent } from './scene/home/home.component'; +import { TypeComponent } from './scene/type/type.component'; +import { UniversComponent } from './scene/univers/univers'; +import { GroupComponent } from './scene/group/group.component'; +import { SaisonComponent } from './scene/saison/saison.component'; +import { VideoComponent } from './scene/video/video.component'; +import { LoginComponent } from './scene/login/login.component'; +import { SignUpComponent } from './scene/sign-up/sign-up.component'; +import { SettingsComponent } from './scene/settings/settings.component'; import { VideoEditComponent } from './scene/video-edit/video-edit'; //import { HelpComponent } from './help/help.component'; @@ -23,11 +24,19 @@ import { VideoEditComponent } from './scene/video-edit/video-edit'; const routes: Routes = [ { path: '', redirectTo: '/home', pathMatch: 'full'}, { path: 'home', component: HomeComponent }, - { path: 'type/:id', component: TypeDetailComponent }, - { path: 'group/:id', component: GroupDetailComponent }, - { path: 'saison/:id', component: SaisonDetailComponent }, - { path: 'video/:id', component: VideoDetailComponent }, - { path: 'video-edit/:id', component: VideoEditComponent }, + { path: 'type/:type_id', component: TypeComponent }, + { path: 'univers/:univers_id', component: UniversComponent }, + //{ path: 'type/:type_id/univers/:univers_id', component: UniversComponent }, + { path: 'group/:group_id', component: GroupComponent }, + //{ path: 'type/:type_id/group/:group_id', component: GroupComponent }, + //{ path: 'type/:type_id/univers/:univers_id/group/:group_id', component: GroupComponent }, + //{ path: 'univers/:univers_id/group/:group_id', component: GroupComponent }, + { path: 'saison/:saison_id', component: SaisonComponent }, + //{ path: 'type/:type_id/univers/:univers_id/group/:group_id/saison/:saison_id', component: SaisonComponent }, + { path: 'video/:video_id', component: VideoComponent }, + //{ path: 'type/:type_id/univers/:univers_id/group/:group_id/saison/:saison_id/video/:video_id', component: VideoComponent }, + //{ path: 'type/:type_id/univers/:univers_id/group/:group_id/saison/:saison_id/video/:video_id/edit', component: VideoEditComponent }, + { path: 'video-edit/:video_id', component: VideoEditComponent }, { path: 'login', component: LoginComponent }, { path: 'signup', component: SignUpComponent }, { path: 'settings', component: SettingsComponent }, diff --git a/front/src/app/app.component.spec.ts b/front/src/app/app.component.spec.ts deleted file mode 100644 index bcbdf36..0000000 --- a/front/src/app/app.component.spec.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { TestBed, async } from '@angular/core/testing'; -import { AppComponent } from './app.component'; -describe('AppComponent', () => { - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ - AppComponent - ], - }).compileComponents(); - })); - it('should create the app', async(() => { - const fixture = TestBed.createComponent(AppComponent); - const app = fixture.debugElement.componentInstance; - expect(app).toBeTruthy(); - })); - it(`should have as title 'app'`, async(() => { - const fixture = TestBed.createComponent(AppComponent); - const app = fixture.debugElement.componentInstance; - expect(app.title).toEqual('app'); - })); - it('should render title in a h1 tag', async(() => { - const fixture = TestBed.createComponent(AppComponent); - fixture.detectChanges(); - const compiled = fixture.debugElement.nativeElement; - expect(compiled.querySelector('h1').textContent).toContain('Welcome to app!'); - })); -}); diff --git a/front/src/app/app.component.ts b/front/src/app/app.component.ts index d64e2dc..44f4126 100644 --- a/front/src/app/app.component.ts +++ b/front/src/app/app.component.ts @@ -5,9 +5,9 @@ */ import { Component, OnInit} from '@angular/core'; -import { UserService } from './user.service'; -import { SessionService } from './session.service'; -import { CookiesService } from './cookies.service'; +import { UserService } from './service/user.service'; +import { SessionService } from './service/session.service'; +import { CookiesService } from './service/cookies.service'; @Component({ selector: 'app-root', diff --git a/front/src/app/app.module.ts b/front/src/app/app.module.ts index e88c8d7..b96e76a 100644 --- a/front/src/app/app.module.ts +++ b/front/src/app/app.module.ts @@ -14,37 +14,39 @@ import { FormsModule, ReactiveFormsModule } from '@angular/forms'; import { routing } from './app-routing.module'; -import { HelpComponent } from './help/help.component'; -import { AuthService } from './auth.service'; -import { UploadFileComponent } from './upload-file/upload-file.component'; -import { TopMenuComponent } from './top-menu/top-menu.component'; -import { ElementTypeComponent } from './element-type/element-type.component'; -import { ElementGroupComponent } from './element-group/element-group.component'; -import { ElementSaisonComponent } from './element-saison/element-saison.component'; -import { ElementVideoComponent } from './element-video/element-video.component'; -import { LoginComponent } from './login/login.component'; -import { SignUpComponent } from './sign-up/sign-up.component'; -import { ValidateEmailComponent } from './validate-email/validate-email.component'; -import { HomeComponent } from './home/home.component'; -import { TypeDetailComponent } from './type-detail/type-detail.component'; -import { GroupDetailComponent } from './group-detail/group-detail.component'; -import { SaisonDetailComponent } from './saison-detail/saison-detail.component'; -import { VideoDetailComponent } from './video-detail/video-detail.component'; -import { SettingsComponent } from './settings/settings.component'; -import { ErrorViewerComponent } from './error-viewer/error-viewer.component'; +import { UploadFileComponent } from './component/upload-file/upload-file.component'; +import { TopMenuComponent } from './component/top-menu/top-menu.component'; +import { ElementTypeComponent } from './component/element-type/element-type.component'; +import { ElementGroupComponent } from './component/element-group/element-group.component'; +import { ElementSaisonComponent } from './component/element-saison/element-saison.component'; +import { ElementVideoComponent } from './component/element-video/element-video.component'; + +import { HelpComponent } from './scene/help/help.component'; +import { LoginComponent } from './scene/login/login.component'; +import { SignUpComponent } from './scene/sign-up/sign-up.component'; +import { ValidateEmailComponent } from './scene/validate-email/validate-email.component'; +import { HomeComponent } from './scene/home/home.component'; +import { TypeComponent } from './scene/type/type.component'; +import { UniversComponent } from './scene/univers/univers'; +import { GroupComponent } from './scene/group/group.component'; +import { SaisonComponent } from './scene/saison/saison.component'; +import { VideoComponent } from './scene/video/video.component'; +import { SettingsComponent } from './scene/settings/settings.component'; +import { ErrorViewerComponent } from './scene/error-viewer/error-viewer.component'; import { ErrorComponent } from './error/error.component'; import { VideoEditComponent } from './scene/video-edit/video-edit'; -import { ArianeService } from './ariane.service'; -import { CookiesService } from './cookies.service'; -import { HttpWrapperService } from './http-wrapper.service'; -import { UserService } from './user.service'; -import { UniversService } from './univers.service'; -import { GroupService } from './group.service'; -import { TypeService } from './type.service'; -import { SaisonService } from './saison.service'; -import { VideoService } from './video.service'; -import { SessionService } from './session.service'; +import { AuthService } from './service/auth.service'; +import { ArianeService } from './service/ariane.service'; +import { CookiesService } from './service/cookies.service'; +import { HttpWrapperService } from './service/http-wrapper.service'; +import { UserService } from './service/user.service'; +import { UniversService } from './service/univers.service'; +import { GroupService } from './service/group.service'; +import { TypeService } from './service/type.service'; +import { SaisonService } from './service/saison.service'; +import { VideoService } from './service/video.service'; +import { SessionService } from './service/session.service'; import { AppComponent } from './app.component'; @@ -64,10 +66,11 @@ import { AppComponent } from './app.component'; SignUpComponent, ValidateEmailComponent, HomeComponent, - TypeDetailComponent, - GroupDetailComponent, - SaisonDetailComponent, - VideoDetailComponent, + TypeComponent, + UniversComponent, + GroupComponent, + SaisonComponent, + VideoComponent, SettingsComponent, ErrorViewerComponent, ErrorComponent, diff --git a/front/src/app/auth.service.spec.ts b/front/src/app/auth.service.spec.ts deleted file mode 100644 index bd98634..0000000 --- a/front/src/app/auth.service.spec.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { TestBed, inject } from '@angular/core/testing'; - -import { AuthService } from './auth.service'; - -describe('AuthService', () => { - beforeEach(() => { - TestBed.configureTestingModule({ - providers: [AuthService] - }); - }); - - it('should be created', inject([AuthService], (service: AuthService) => { - expect(service).toBeTruthy(); - })); -}); diff --git a/front/src/app/element-group/element-group.component.html b/front/src/app/component/element-group/element-group.component.html similarity index 100% rename from front/src/app/element-group/element-group.component.html rename to front/src/app/component/element-group/element-group.component.html diff --git a/front/src/app/element-group/element-group.component.less b/front/src/app/component/element-group/element-group.component.less similarity index 100% rename from front/src/app/element-group/element-group.component.less rename to front/src/app/component/element-group/element-group.component.less diff --git a/front/src/app/element-group/element-group.component.ts b/front/src/app/component/element-group/element-group.component.ts similarity index 95% rename from front/src/app/element-group/element-group.component.ts rename to front/src/app/component/element-group/element-group.component.ts index 9ddbaf5..9b06edc 100644 --- a/front/src/app/element-group/element-group.component.ts +++ b/front/src/app/component/element-group/element-group.component.ts @@ -9,7 +9,7 @@ import { Injectable, Component, OnInit, Input } from '@angular/core'; import { Router } from "@angular/router"; import { ActivatedRoute, Params } from '@angular/router'; -import { GroupService } from '../group.service'; +import { GroupService } from '../../service/group.service'; @Component({ selector: 'app-element-group', diff --git a/front/src/app/element-saison/element-saison.component.html b/front/src/app/component/element-saison/element-saison.component.html similarity index 100% rename from front/src/app/element-saison/element-saison.component.html rename to front/src/app/component/element-saison/element-saison.component.html diff --git a/front/src/app/element-saison/element-saison.component.less b/front/src/app/component/element-saison/element-saison.component.less similarity index 100% rename from front/src/app/element-saison/element-saison.component.less rename to front/src/app/component/element-saison/element-saison.component.less diff --git a/front/src/app/element-saison/element-saison.component.ts b/front/src/app/component/element-saison/element-saison.component.ts similarity index 94% rename from front/src/app/element-saison/element-saison.component.ts rename to front/src/app/component/element-saison/element-saison.component.ts index b5a3341..ae308e0 100644 --- a/front/src/app/element-saison/element-saison.component.ts +++ b/front/src/app/component/element-saison/element-saison.component.ts @@ -9,7 +9,7 @@ import { Injectable, Component, OnInit, Input } from '@angular/core'; import { Router } from "@angular/router"; import { ActivatedRoute, Params } from '@angular/router'; -import { SaisonService } from '../saison.service'; +import { SaisonService } from '../../service/saison.service'; @Component({ selector: 'app-element-saison', diff --git a/front/src/app/element-type/element-type.component.html b/front/src/app/component/element-type/element-type.component.html similarity index 100% rename from front/src/app/element-type/element-type.component.html rename to front/src/app/component/element-type/element-type.component.html diff --git a/front/src/app/element-type/element-type.component.less b/front/src/app/component/element-type/element-type.component.less similarity index 100% rename from front/src/app/element-type/element-type.component.less rename to front/src/app/component/element-type/element-type.component.less diff --git a/front/src/app/element-type/element-type.component.ts b/front/src/app/component/element-type/element-type.component.ts similarity index 97% rename from front/src/app/element-type/element-type.component.ts rename to front/src/app/component/element-type/element-type.component.ts index 38f369d..5735bc8 100644 --- a/front/src/app/element-type/element-type.component.ts +++ b/front/src/app/component/element-type/element-type.component.ts @@ -9,7 +9,7 @@ import { Injectable, Component, OnInit, Input } from '@angular/core'; import { Router } from "@angular/router"; import { ActivatedRoute, Params } from '@angular/router'; -import { TypeService } from '../type.service'; +import { TypeService } from '../../service/type.service'; @Component({ selector: 'app-element-type', diff --git a/front/src/app/element-video/element-video.component.html b/front/src/app/component/element-video/element-video.component.html similarity index 100% rename from front/src/app/element-video/element-video.component.html rename to front/src/app/component/element-video/element-video.component.html diff --git a/front/src/app/element-video/element-video.component.less b/front/src/app/component/element-video/element-video.component.less similarity index 100% rename from front/src/app/element-video/element-video.component.less rename to front/src/app/component/element-video/element-video.component.less diff --git a/front/src/app/element-video/element-video.component.ts b/front/src/app/component/element-video/element-video.component.ts similarity index 94% rename from front/src/app/element-video/element-video.component.ts rename to front/src/app/component/element-video/element-video.component.ts index 3e3c78b..812ab65 100644 --- a/front/src/app/element-video/element-video.component.ts +++ b/front/src/app/component/element-video/element-video.component.ts @@ -9,8 +9,8 @@ import { Injectable, Component, OnInit, Input } from '@angular/core'; import { Router } from "@angular/router"; import { ActivatedRoute, Params } from '@angular/router'; -import { VideoService } from '../video.service'; -import { HttpWrapperService } from '../http-wrapper.service'; +import { VideoService } from '../../service/video.service'; +import { HttpWrapperService } from '../../service/http-wrapper.service'; @Component({ selector: 'app-element-video', diff --git a/front/src/app/top-menu/top-menu.component.html b/front/src/app/component/top-menu/top-menu.component.html similarity index 62% rename from front/src/app/top-menu/top-menu.component.html rename to front/src/app/component/top-menu/top-menu.component.html index 3909a9f..cb726fa 100644 --- a/front/src/app/top-menu/top-menu.component.html +++ b/front/src/app/component/top-menu/top-menu.component.html @@ -2,28 +2,71 @@
diff --git a/front/src/app/top-menu/top-menu.component.less b/front/src/app/component/top-menu/top-menu.component.less similarity index 94% rename from front/src/app/top-menu/top-menu.component.less rename to front/src/app/component/top-menu/top-menu.component.less index fc4577b..ac7d6ce 100644 --- a/front/src/app/top-menu/top-menu.component.less +++ b/front/src/app/component/top-menu/top-menu.component.less @@ -107,6 +107,14 @@ text-transform: uppercase; font-weight: bold; font-size: 17px; + .comment { + visibility: "hidden"; + } + @media all and (min-width: 700px) { + .comment { + visibility: "visible"; + } + } } .ariane { diff --git a/front/src/app/top-menu/top-menu.component.ts b/front/src/app/component/top-menu/top-menu.component.ts similarity index 98% rename from front/src/app/top-menu/top-menu.component.ts rename to front/src/app/component/top-menu/top-menu.component.ts index cf4bb6a..e973738 100644 --- a/front/src/app/top-menu/top-menu.component.ts +++ b/front/src/app/component/top-menu/top-menu.component.ts @@ -9,8 +9,8 @@ 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'; +import { SessionService } from '../../service/session.service'; +import { ArianeService } from '../../service/ariane.service'; @Component({ selector: 'app-top-menu', diff --git a/front/src/app/upload-file/upload-file.component.html b/front/src/app/component/upload-file/upload-file.component.html similarity index 100% rename from front/src/app/upload-file/upload-file.component.html rename to front/src/app/component/upload-file/upload-file.component.html diff --git a/front/src/app/upload-file/upload-file.component.less b/front/src/app/component/upload-file/upload-file.component.less similarity index 90% rename from front/src/app/upload-file/upload-file.component.less rename to front/src/app/component/upload-file/upload-file.component.less index 4cf6eb4..359915e 100644 --- a/front/src/app/upload-file/upload-file.component.less +++ b/front/src/app/component/upload-file/upload-file.component.less @@ -1,5 +1,5 @@ .uploadfilecontainer { - //background-image: url("../../assets/cloud-2044823_960_720.png"); + //background-image: url("../../../assets/cloud-2044823_960_720.png"); background-repeat: no-repeat; background-size: 100px; background-position: center; diff --git a/front/src/app/upload-file/upload-file.component.ts b/front/src/app/component/upload-file/upload-file.component.ts similarity index 100% rename from front/src/app/upload-file/upload-file.component.ts rename to front/src/app/component/upload-file/upload-file.component.ts diff --git a/front/src/app/cookies.service.spec.ts b/front/src/app/cookies.service.spec.ts deleted file mode 100644 index 4cbc882..0000000 --- a/front/src/app/cookies.service.spec.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { TestBed, inject } from '@angular/core/testing'; - -import { CookiesService } from './cookies.service'; - -describe('CookiesService', () => { - beforeEach(() => { - TestBed.configureTestingModule({ - providers: [CookiesService] - }); - }); - - it('should be created', inject([CookiesService], (service: CookiesService) => { - expect(service).toBeTruthy(); - })); -}); diff --git a/front/src/app/element-group/element-group.component.spec.ts b/front/src/app/element-group/element-group.component.spec.ts deleted file mode 100644 index 5bffb5f..0000000 --- a/front/src/app/element-group/element-group.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { ElementGroupComponent } from './top-menu.component'; - -describe('ElementGroupComponent', () => { - let component: ElementGroupComponent; - let fixture: ComponentFixture; - - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ ElementGroupComponent ] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(ElementGroupComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/front/src/app/element-saison/element-saison.component.spec.ts b/front/src/app/element-saison/element-saison.component.spec.ts deleted file mode 100644 index ab4ae8c..0000000 --- a/front/src/app/element-saison/element-saison.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { ElementSaisonComponent } from './top-menu.component'; - -describe('ElementSaisonComponent', () => { - let component: ElementSaisonComponent; - let fixture: ComponentFixture; - - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ ElementSaisonComponent ] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(ElementSaisonComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/front/src/app/element-type/element-type.component.spec.ts b/front/src/app/element-type/element-type.component.spec.ts deleted file mode 100644 index fda1bae..0000000 --- a/front/src/app/element-type/element-type.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { ElementTypeComponent } from './top-menu.component'; - -describe('ElementTypeComponent', () => { - let component: ElementTypeComponent; - let fixture: ComponentFixture; - - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ ElementTypeComponent ] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(ElementTypeComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/front/src/app/element-video/element-video.component.spec.ts b/front/src/app/element-video/element-video.component.spec.ts deleted file mode 100644 index 009ebba..0000000 --- a/front/src/app/element-video/element-video.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { ElementVideoComponent } from './top-menu.component'; - -describe('ElementVideoComponent', () => { - let component: ElementVideoComponent; - let fixture: ComponentFixture; - - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ ElementVideoComponent ] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(ElementVideoComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/front/src/app/error-viewer/error-viewer.component.spec.ts b/front/src/app/error-viewer/error-viewer.component.spec.ts deleted file mode 100644 index 2937a3f..0000000 --- a/front/src/app/error-viewer/error-viewer.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { ErrorViewerComponent } from './error-viewer.component'; - -describe('ErrorViewerComponent', () => { - let component: ErrorViewerComponent; - let fixture: ComponentFixture; - - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ ErrorViewerComponent ] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(ErrorViewerComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/front/src/app/error/error.component.spec.ts b/front/src/app/error/error.component.spec.ts deleted file mode 100644 index ceefd5b..0000000 --- a/front/src/app/error/error.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { ErrorComponent } from './error.component'; - -describe('ErrorComponent', () => { - let component: ErrorComponent; - let fixture: ComponentFixture; - - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ ErrorComponent ] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(ErrorComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/front/src/app/group-detail/group-detail.component.spec.ts b/front/src/app/group-detail/group-detail.component.spec.ts deleted file mode 100644 index e35edd7..0000000 --- a/front/src/app/group-detail/group-detail.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { GroupDetailComponent } from './group-detail.component'; - -describe('GroupDetailComponent', () => { - let component: GroupDetailComponent; - let fixture: ComponentFixture; - - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ GroupDetailComponent ] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(GroupDetailComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/front/src/app/group.service.spec.ts b/front/src/app/group.service.spec.ts deleted file mode 100644 index 2123683..0000000 --- a/front/src/app/group.service.spec.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { TestBed, inject } from '@angular/core/testing'; - -import { GroupService } from './group.service'; - -describe('GroupService', () => { - beforeEach(() => { - TestBed.configureTestingModule({ - providers: [GroupService] - }); - }); - - it('should be created', inject([GroupService], (service: GroupService) => { - expect(service).toBeTruthy(); - })); -}); diff --git a/front/src/app/help/help.component.spec.ts b/front/src/app/help/help.component.spec.ts deleted file mode 100644 index 191ecee..0000000 --- a/front/src/app/help/help.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { HelpComponent } from './help.component'; - -describe('HelpComponent', () => { - let component: HelpComponent; - let fixture: ComponentFixture; - - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ HelpComponent ] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(HelpComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/front/src/app/home/home.component.spec.ts b/front/src/app/home/home.component.spec.ts deleted file mode 100644 index 490e81b..0000000 --- a/front/src/app/home/home.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { HomeComponent } from './home.component'; - -describe('HomeComponent', () => { - let component: HomeComponent; - let fixture: ComponentFixture; - - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ HomeComponent ] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(HomeComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/front/src/app/http-wrapper.service.spec.ts b/front/src/app/http-wrapper.service.spec.ts deleted file mode 100644 index a64bac5..0000000 --- a/front/src/app/http-wrapper.service.spec.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { TestBed, inject } from '@angular/core/testing'; - -import { HttpWrapperService } from './http-wrapper.service'; - -describe('HttpWrapperService', () => { - beforeEach(() => { - TestBed.configureTestingModule({ - providers: [HttpWrapperService] - }); - }); - - it('should be created', inject([HttpWrapperService], (service: HttpWrapperService) => { - expect(service).toBeTruthy(); - })); -}); diff --git a/front/src/app/login/login.component.spec.ts b/front/src/app/login/login.component.spec.ts deleted file mode 100644 index d6d85a8..0000000 --- a/front/src/app/login/login.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { LoginComponent } from './login.component'; - -describe('LoginComponent', () => { - let component: LoginComponent; - let fixture: ComponentFixture; - - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ LoginComponent ] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(LoginComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/front/src/app/saison-detail/saison-detail.component.spec.ts b/front/src/app/saison-detail/saison-detail.component.spec.ts deleted file mode 100644 index e475174..0000000 --- a/front/src/app/saison-detail/saison-detail.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { SaisonDetailComponent } from './saison-detail.component'; - -describe('SaisonDetailComponent', () => { - let component: SaisonDetailComponent; - let fixture: ComponentFixture; - - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ SaisonDetailComponent ] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(SaisonDetailComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/front/src/app/saison.service.spec.ts b/front/src/app/saison.service.spec.ts deleted file mode 100644 index 0856789..0000000 --- a/front/src/app/saison.service.spec.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { TestBed, inject } from '@angular/core/testing'; - -import { SaisonService } from './saison.service'; - -describe('SaisonService', () => { - beforeEach(() => { - TestBed.configureTestingModule({ - providers: [SaisonService] - }); - }); - - it('should be created', inject([SaisonService], (service: SaisonService) => { - expect(service).toBeTruthy(); - })); -}); diff --git a/front/src/app/error-viewer/error-viewer.component.html b/front/src/app/scene/error-viewer/error-viewer.component.html similarity index 100% rename from front/src/app/error-viewer/error-viewer.component.html rename to front/src/app/scene/error-viewer/error-viewer.component.html diff --git a/front/src/app/error-viewer/error-viewer.component.less b/front/src/app/scene/error-viewer/error-viewer.component.less similarity index 100% rename from front/src/app/error-viewer/error-viewer.component.less rename to front/src/app/scene/error-viewer/error-viewer.component.less diff --git a/front/src/app/error-viewer/error-viewer.component.ts b/front/src/app/scene/error-viewer/error-viewer.component.ts similarity index 100% rename from front/src/app/error-viewer/error-viewer.component.ts rename to front/src/app/scene/error-viewer/error-viewer.component.ts diff --git a/front/src/app/group-detail/group-detail.component.html b/front/src/app/scene/group/group.component.html similarity index 100% rename from front/src/app/group-detail/group-detail.component.html rename to front/src/app/scene/group/group.component.html diff --git a/front/src/app/group-detail/group-detail.component.less b/front/src/app/scene/group/group.component.less similarity index 100% rename from front/src/app/group-detail/group-detail.component.less rename to front/src/app/scene/group/group.component.less diff --git a/front/src/app/group-detail/group-detail.component.ts b/front/src/app/scene/group/group.component.ts similarity index 61% rename from front/src/app/group-detail/group-detail.component.ts rename to front/src/app/scene/group/group.component.ts index 7060725..03e2595 100644 --- a/front/src/app/group-detail/group-detail.component.ts +++ b/front/src/app/scene/group/group.component.ts @@ -7,20 +7,22 @@ import { Component, OnInit } from '@angular/core'; import { Router, ActivatedRoute, ParamMap } from '@angular/router'; import { Location } from '@angular/common'; -import { fadeInAnimation } from '../_animations/index'; +import { fadeInAnimation } from '../../_animations/index'; -import { GroupService } from '../group.service'; -import { ArianeService } from '../ariane.service'; +import { GroupService } from '../../service/group.service'; +import { ArianeService } from '../../service/ariane.service'; @Component({ - selector: 'app-group-detail', - templateUrl: './group-detail.component.html', - styleUrls: ['./group-detail.component.less'], + selector: 'app-group', + templateUrl: './group.component.html', + styleUrls: ['./group.component.less'], animations: [fadeInAnimation], host: { '[@fadeInAnimation]': '' } }) -export class GroupDetailComponent implements OnInit { +export class GroupComponent implements OnInit { + //id_type = -1; + //id_univers = -1; id_group = -1; saisons_error = ""; saisons = []; @@ -35,7 +37,10 @@ export class GroupDetailComponent implements OnInit { } ngOnInit() { - this.id_group = parseInt(this.route.snapshot.paramMap.get('id')); + //this.id_univers = parseInt(this.route.snapshot.paramMap.get('univers_id')); + //this.id_type = parseInt(this.route.snapshot.paramMap.get('type_id')); + this.id_group = parseInt(this.route.snapshot.paramMap.get('group_id')); + console.log let self = this; console.log("get parameter id: " + this.id_group); this.groupService.getSaison(this.id_group) @@ -56,12 +61,14 @@ export class GroupDetailComponent implements OnInit { }); } onSelectSaison(_idSelected: number):void { - this.router.navigate(['saison/' + _idSelected ]); + //this.router.navigate(['/type/' + this.type_id + '/group/' + this.id_group + '/saison/' + _idSelected ]); + this.router.navigate(['/saison/' + _idSelected ]); this.arianeService.setSaison(_idSelected); } onSelectVideo(_idSelected: number):void { - this.router.navigate(['video/' + _idSelected ]); + //this.router.navigate(['/type/' + this.type_id + '/group/' + this.id_group + '/video/' + _idSelected ]); + this.router.navigate(['/video/' + _idSelected ]); this.arianeService.setVideo(_idSelected); } diff --git a/front/src/app/help/help.component.html b/front/src/app/scene/help/help.component.html similarity index 100% rename from front/src/app/help/help.component.html rename to front/src/app/scene/help/help.component.html diff --git a/front/src/app/help/help.component.less b/front/src/app/scene/help/help.component.less similarity index 100% rename from front/src/app/help/help.component.less rename to front/src/app/scene/help/help.component.less diff --git a/front/src/app/help/help.component.ts b/front/src/app/scene/help/help.component.ts similarity index 100% rename from front/src/app/help/help.component.ts rename to front/src/app/scene/help/help.component.ts diff --git a/front/src/app/home/home.component.html b/front/src/app/scene/home/home.component.html similarity index 100% rename from front/src/app/home/home.component.html rename to front/src/app/scene/home/home.component.html diff --git a/front/src/app/home/home.component.less b/front/src/app/scene/home/home.component.less similarity index 100% rename from front/src/app/home/home.component.less rename to front/src/app/scene/home/home.component.less diff --git a/front/src/app/home/home.component.ts b/front/src/app/scene/home/home.component.ts similarity index 87% rename from front/src/app/home/home.component.ts rename to front/src/app/scene/home/home.component.ts index 55abc19..e052bbf 100644 --- a/front/src/app/home/home.component.ts +++ b/front/src/app/scene/home/home.component.ts @@ -7,10 +7,10 @@ import { Component, OnInit } from '@angular/core'; import { Router } from "@angular/router"; import { Location } from '@angular/common'; -import { fadeInAnimation } from '../_animations/index'; +import { fadeInAnimation } from '../../_animations/index'; -import { TypeService } from '../type.service'; -import { ArianeService } from '../ariane.service'; +import { TypeService } from '../../service/type.service'; +import { ArianeService } from '../../service/ariane.service'; @Component({ selector: 'app-home', diff --git a/front/src/app/login/login.component.html b/front/src/app/scene/login/login.component.html similarity index 100% rename from front/src/app/login/login.component.html rename to front/src/app/scene/login/login.component.html diff --git a/front/src/app/login/login.component.less b/front/src/app/scene/login/login.component.less similarity index 100% rename from front/src/app/login/login.component.less rename to front/src/app/scene/login/login.component.less diff --git a/front/src/app/login/login.component.ts b/front/src/app/scene/login/login.component.ts similarity index 93% rename from front/src/app/login/login.component.ts rename to front/src/app/scene/login/login.component.ts index 41e8a9b..456d90d 100644 --- a/front/src/app/login/login.component.ts +++ b/front/src/app/scene/login/login.component.ts @@ -7,11 +7,11 @@ import { Component, OnInit } from '@angular/core'; import { Router } from "@angular/router"; import { Location } from '@angular/common'; -import { fadeInAnimation } from '../_animations/index'; -import { slideInOutAnimation } from '../_animations/index'; -import { UserService } from '../user.service'; -import { SessionService } from '../session.service'; -import { CookiesService } from '../cookies.service'; +import { fadeInAnimation } from '../../_animations/index'; +import { slideInOutAnimation } from '../../_animations/index'; +import { UserService } from '../../service/user.service'; +import { SessionService } from '../../service/session.service'; +import { CookiesService } from '../../service/cookies.service'; export let checkLoginValidity = function(_value:string):boolean { diff --git a/front/src/app/saison-detail/saison-detail.component.html b/front/src/app/scene/saison/saison.component.html similarity index 100% rename from front/src/app/saison-detail/saison-detail.component.html rename to front/src/app/scene/saison/saison.component.html diff --git a/front/src/app/saison-detail/saison-detail.component.less b/front/src/app/scene/saison/saison.component.less similarity index 100% rename from front/src/app/saison-detail/saison-detail.component.less rename to front/src/app/scene/saison/saison.component.less diff --git a/front/src/app/saison-detail/saison-detail.component.ts b/front/src/app/scene/saison/saison.component.ts similarity index 73% rename from front/src/app/saison-detail/saison-detail.component.ts rename to front/src/app/scene/saison/saison.component.ts index f305b10..1fd5f75 100644 --- a/front/src/app/saison-detail/saison-detail.component.ts +++ b/front/src/app/scene/saison/saison.component.ts @@ -7,20 +7,20 @@ import { Component, OnInit } from '@angular/core'; import { Router, ActivatedRoute, ParamMap } from '@angular/router'; import { Location } from '@angular/common'; -import { fadeInAnimation } from '../_animations/index'; +import { fadeInAnimation } from '../../_animations/index'; -import { SaisonService } from '../saison.service'; -import { ArianeService } from '../ariane.service'; +import { SaisonService } from '../../service/saison.service'; +import { ArianeService } from '../../service/ariane.service'; @Component({ - selector: 'app-saison-detail', - templateUrl: './saison-detail.component.html', - styleUrls: ['./saison-detail.component.less'], + selector: 'app-saison', + templateUrl: './saison.component.html', + styleUrls: ['./saison.component.less'], animations: [fadeInAnimation], host: { '[@fadeInAnimation]': '' } }) -export class SaisonDetailComponent implements OnInit { +export class SaisonComponent implements OnInit { id_saison = -1; videos_error = ""; videos = []; @@ -33,7 +33,7 @@ export class SaisonDetailComponent implements OnInit { } ngOnInit() { - this.id_saison = parseInt(this.route.snapshot.paramMap.get('id')); + this.id_saison = parseInt(this.route.snapshot.paramMap.get('saison_id')); let self = this; console.log("get parameter id: " + this.id_saison); this.saisonService.getVideo(this.id_saison) diff --git a/front/src/app/settings/settings.component.html b/front/src/app/scene/settings/settings.component.html similarity index 100% rename from front/src/app/settings/settings.component.html rename to front/src/app/scene/settings/settings.component.html diff --git a/front/src/app/settings/settings.component.less b/front/src/app/scene/settings/settings.component.less similarity index 100% rename from front/src/app/settings/settings.component.less rename to front/src/app/scene/settings/settings.component.less diff --git a/front/src/app/settings/settings.component.ts b/front/src/app/scene/settings/settings.component.ts similarity index 100% rename from front/src/app/settings/settings.component.ts rename to front/src/app/scene/settings/settings.component.ts diff --git a/front/src/app/sign-up/sign-up.component.html b/front/src/app/scene/sign-up/sign-up.component.html similarity index 100% rename from front/src/app/sign-up/sign-up.component.html rename to front/src/app/scene/sign-up/sign-up.component.html diff --git a/front/src/app/sign-up/sign-up.component.less b/front/src/app/scene/sign-up/sign-up.component.less similarity index 85% rename from front/src/app/sign-up/sign-up.component.less rename to front/src/app/scene/sign-up/sign-up.component.less index 330e490..ae64e9d 100644 --- a/front/src/app/sign-up/sign-up.component.less +++ b/front/src/app/scene/sign-up/sign-up.component.less @@ -22,7 +22,7 @@ color: white; .comment { - background-image: url("../../assets/images/comments.svg"); + background-image: url("../../../assets/images/comments.svg"); background-repeat: no-repeat; background-size: 45px; /*background-attachment: fixed;*/ @@ -32,7 +32,7 @@ text-shadow:0px 0px 4px #2b3137; } .share { - background-image: url("../../assets/images/share.svg"); + background-image: url("../../../assets/images/share.svg"); background-repeat: no-repeat; background-size: 45px; /*background-attachment: fixed;*/ @@ -42,7 +42,7 @@ text-shadow:0px 0px 4px #2b3137; } .time { - background-image: url("../../assets/images/time.svg"); + background-image: url("../../../assets/images/time.svg"); background-repeat: no-repeat; background-size: 45px; /*background-attachment: fixed;*/ @@ -115,17 +115,17 @@ span.psw { text-align: center; } .icon-right-load { - background: white url("../../assets/images/load.svg") right no-repeat; + background: white url("../../../assets/images/load.svg") right no-repeat; background-size: 35px; padding-right: 17px; } .icon-right-validate { - background: white url("../../assets/images/validate.svg") right no-repeat; + background: white url("../../../assets/images/validate.svg") right no-repeat; background-size: 35px; padding-right: 17px; } .icon-right-not-validate { - background: white url("../../assets/images/validate-not.svg") right no-repeat; + background: white url("../../../assets/images/validate-not.svg") right no-repeat; background-size: 35px; padding-right: 17px; } diff --git a/front/src/app/sign-up/sign-up.component.ts b/front/src/app/scene/sign-up/sign-up.component.ts similarity index 98% rename from front/src/app/sign-up/sign-up.component.ts rename to front/src/app/scene/sign-up/sign-up.component.ts index 619643a..ba41c76 100644 --- a/front/src/app/sign-up/sign-up.component.ts +++ b/front/src/app/scene/sign-up/sign-up.component.ts @@ -7,8 +7,8 @@ import { Component, OnInit } from '@angular/core'; import { Router } from "@angular/router"; import { checkLoginValidity, checkEmailValidity, checkPasswordValidity } from '../login/login.component'; -import { fadeInAnimation } from '../_animations/index'; -import { UserService } from '../user.service'; +import { fadeInAnimation } from '../../_animations/index'; +import { UserService } from '../../service/user.service'; @Component({ diff --git a/front/src/app/type-detail/type-detail.component.html b/front/src/app/scene/type/type.component.html similarity index 100% rename from front/src/app/type-detail/type-detail.component.html rename to front/src/app/scene/type/type.component.html diff --git a/front/src/app/type-detail/type-detail.component.less b/front/src/app/scene/type/type.component.less similarity index 100% rename from front/src/app/type-detail/type-detail.component.less rename to front/src/app/scene/type/type.component.less diff --git a/front/src/app/type-detail/type-detail.component.ts b/front/src/app/scene/type/type.component.ts similarity index 70% rename from front/src/app/type-detail/type-detail.component.ts rename to front/src/app/scene/type/type.component.ts index cc26a45..3a87052 100644 --- a/front/src/app/type-detail/type-detail.component.ts +++ b/front/src/app/scene/type/type.component.ts @@ -7,20 +7,20 @@ import { Component, OnInit } from '@angular/core'; import { Router, ActivatedRoute, ParamMap } from '@angular/router'; import { Location } from '@angular/common'; -import { fadeInAnimation } from '../_animations/index'; +import { fadeInAnimation } from '../../_animations/index'; -import { TypeService } from '../type.service'; -import { ArianeService } from '../ariane.service'; +import { TypeService } from '../../service/type.service'; +import { ArianeService } from '../../service/ariane.service'; @Component({ - selector: 'app-type-detail', - templateUrl: './type-detail.component.html', - styleUrls: ['./type-detail.component.less'], + selector: 'app-type', + templateUrl: './type.component.html', + styleUrls: ['./type.component.less'], animations: [fadeInAnimation], host: { '[@fadeInAnimation]': '' } }) -export class TypeDetailComponent implements OnInit { +export class TypeComponent implements OnInit { type_id = -1; groups_error = ""; groups = []; @@ -42,7 +42,7 @@ export class TypeDetailComponent implements OnInit { } ngOnInit() { - this.type_id = parseInt(this.route.snapshot.paramMap.get('id')); + this.type_id = parseInt(this.route.snapshot.paramMap.get('type_id')); let self = this; console.log("get parameter id: " + this.type_id); this.typeService.getSubGroup(this.type_id) @@ -63,12 +63,14 @@ export class TypeDetailComponent implements OnInit { }); } onSelectGroup(_idSelected: number):void { - this.router.navigate(['group/' + _idSelected ]); + //this.router.navigate(['/type/' + this.type_id + '/group/' + _idSelected ]); + this.router.navigate(['/group/' + _idSelected ]); this.arianeService.setGroup(_idSelected); } onSelectVideo(_idSelected: number):void { - this.router.navigate(['video/' + _idSelected ]); + //this.router.navigate(['/type/' + this.type_id + '/video/' + _idSelected ]); + this.router.navigate(['/video/' + _idSelected ]); this.arianeService.setVideo(_idSelected); } diff --git a/front/src/app/scene/univers/univers.html b/front/src/app/scene/univers/univers.html new file mode 100644 index 0000000..a125f51 --- /dev/null +++ b/front/src/app/scene/univers/univers.html @@ -0,0 +1,7 @@ +
+
+
+ +
+
+
\ No newline at end of file diff --git a/front/src/app/scene/univers/univers.less b/front/src/app/scene/univers/univers.less new file mode 100644 index 0000000..09160ef --- /dev/null +++ b/front/src/app/scene/univers/univers.less @@ -0,0 +1,62 @@ +.fill-all{ + width:100%; + height:100%; + margin:0; + padding:0; + border:0; + background-color:#0F0; +} + +.item { + font-size: 20px; + height: 21%; + width: 23%; + margin: 1%; + padding: 0; + overflow: hidden; + //box-shadow: 0 1px 1.5px 0 rgba(0,0,0,.12),0 1px 1px 0 rgba(0,0,0,.24); + box-shadow: 0px 2px 4px 0 rgba(0, 0, 0, 0.6); + line-height: normal; + border: none; + font-family: "Roboto","Helvetica","Arial",sans-serif; + font-weight: 500; + text-transform: uppercase; + letter-spacing: 0; + will-change: box-shadow; + outline: none; + cursor: pointer; + text-decoration: none; + text-align: center; + vertical-align: middle; + transition-duration: 0.4s; + float:left; + display:block; + + h1 { + font-size: 24px; + } + + &:hover { + background-color: #F00; + } + + .material-icons { + vertical-align: middle; + } + + .material-icons { + position: absolute; + top: 50%; + left: 50%; + transform: ~"translate(-12px,-12px)"; + line-height: 24px; + width: 24px; + } +} + +.item-video { + &:hover { + background-color: #0F0; + } +} + diff --git a/front/src/app/scene/univers/univers.ts b/front/src/app/scene/univers/univers.ts new file mode 100644 index 0000000..cce3c57 --- /dev/null +++ b/front/src/app/scene/univers/univers.ts @@ -0,0 +1,56 @@ +/** @file + * @author Edouard DUPIN + * @copyright 2018, Edouard DUPIN, all right reserved + * @license PROPRIETARY (see license file) + */ + +import { Component, OnInit } from '@angular/core'; +import { Router, ActivatedRoute, ParamMap } from '@angular/router'; +import { Location } from '@angular/common'; +import { fadeInAnimation } from '../../_animations/index'; + +import { UniversService } from '../../service/univers.service'; +import { ArianeService } from '../../service/ariane.service'; + +@Component({ + selector: 'app-univers', + templateUrl: './univers.html', + styleUrls: ['./univers.less'], + animations: [fadeInAnimation], + host: { '[@fadeInAnimation]': '' } +}) + +export class UniversComponent implements OnInit { + univers_id = -1; + videos_error = ""; + videos = []; + constructor(private route: ActivatedRoute, + private router: Router, + private locate: Location, + private universService: UniversService, + private arianeService: ArianeService) { + + } + + ngOnInit() { + this.univers_id = parseInt(this.route.snapshot.paramMap.get('univers_id')); + let self = this; + console.log("get parameter id: " + this.univers_id); + /* + this.universService.getVideo(this.univers_id) + .then(function(response) { + self.videos_error = ""; + self.videos = response + }).catch(function(response) { + self.videos_error = "Can not get the List of video without saison"; + self.videos = [] + }); + */ + } + + onSelectVideo(_idSelected: number):void { + this.router.navigate(['video/' + _idSelected ]); + this.arianeService.setVideo(_idSelected); + } + +} diff --git a/front/src/app/validate-email/validate-email.component.html b/front/src/app/scene/validate-email/validate-email.component.html similarity index 100% rename from front/src/app/validate-email/validate-email.component.html rename to front/src/app/scene/validate-email/validate-email.component.html diff --git a/front/src/app/validate-email/validate-email.component.less b/front/src/app/scene/validate-email/validate-email.component.less similarity index 87% rename from front/src/app/validate-email/validate-email.component.less rename to front/src/app/scene/validate-email/validate-email.component.less index 2349c74..0c64ce2 100644 --- a/front/src/app/validate-email/validate-email.component.less +++ b/front/src/app/scene/validate-email/validate-email.component.less @@ -6,7 +6,7 @@ sign { right:100; background-color:#2b3137; - background-image: url("../../assets/images/ikon_gray.svg"); + background-image: url("../../../assets/images/ikon_gray.svg"); background-repeat: no-repeat; /* background-size: contain; @@ -31,7 +31,7 @@ sign { color: white; .comment { - background-image: url("../../assets/images/comments.svg"); + background-image: url("../../../assets/images/comments.svg"); background-repeat: no-repeat; background-size: 45px; background-attachment: fixed; @@ -41,7 +41,7 @@ sign { text-shadow:0px 0px 4px #2b3137; } .share { - background-image: url("../../assets/images/share.svg"); + background-image: url("../../../assets/images/share.svg"); background-repeat: no-repeat; background-size: 45px; background-attachment: fixed; @@ -51,7 +51,7 @@ sign { text-shadow:0px 0px 4px #2b3137; } .forget { - background-image: url("../../assets/images/erase.svg"); + background-image: url("../../../assets/images/erase.svg"); background-repeat: no-repeat; background-size: 45px; background-attachment: fixed; @@ -61,7 +61,7 @@ sign { text-shadow:0px 0px 4px #2b3137; } .time { - background-image: url("../../assets/images/time.svg"); + background-image: url("../../../assets/images/time.svg"); background-repeat: no-repeat; background-size: 45px; background-attachment: fixed; diff --git a/front/src/app/validate-email/validate-email.component.ts b/front/src/app/scene/validate-email/validate-email.component.ts similarity index 100% rename from front/src/app/validate-email/validate-email.component.ts rename to front/src/app/scene/validate-email/validate-email.component.ts diff --git a/front/src/app/scene/video-edit/video-edit.ts b/front/src/app/scene/video-edit/video-edit.ts index d0d1c82..8f022ea 100644 --- a/front/src/app/scene/video-edit/video-edit.ts +++ b/front/src/app/scene/video-edit/video-edit.ts @@ -10,9 +10,9 @@ import { Location } from '@angular/common'; import { NgForm } from '@angular/forms'; import { FormGroup, FormControl } from "@angular/forms"; import { fadeInAnimation } from '../../_animations/index'; -import { HttpWrapperService } from '../../http-wrapper.service'; +import { HttpWrapperService } from '../../service/http-wrapper.service'; -import { VideoService } from '../../video.service'; +import { VideoService } from '../../service/video.service'; @Component({ selector: 'app-video-edit', @@ -63,7 +63,7 @@ export class VideoEditComponent implements OnInit { } ngOnInit() { - this.id_video = parseInt(this.route.snapshot.paramMap.get('id')); + this.id_video = parseInt(this.route.snapshot.paramMap.get('video_id')); let self = this; this.videoService.get(this.id_video) .then(function(response) { diff --git a/front/src/app/video-detail/video-detail.component.html b/front/src/app/scene/video/video.component.html similarity index 100% rename from front/src/app/video-detail/video-detail.component.html rename to front/src/app/scene/video/video.component.html diff --git a/front/src/app/video-detail/video-detail.component.less b/front/src/app/scene/video/video.component.less similarity index 100% rename from front/src/app/video-detail/video-detail.component.less rename to front/src/app/scene/video/video.component.less diff --git a/front/src/app/video-detail/video-detail.component.ts b/front/src/app/scene/video/video.component.ts similarity index 83% rename from front/src/app/video-detail/video-detail.component.ts rename to front/src/app/scene/video/video.component.ts index 0d8275a..af5baf7 100644 --- a/front/src/app/video-detail/video-detail.component.ts +++ b/front/src/app/scene/video/video.component.ts @@ -7,20 +7,19 @@ import { Component, OnInit } from '@angular/core'; import { Router, ActivatedRoute, ParamMap } from '@angular/router'; import { Location } from '@angular/common'; -import { fadeInAnimation } from '../_animations/index'; -import { HttpWrapperService } from '../http-wrapper.service'; - -import { VideoService } from '../video.service'; +import { fadeInAnimation } from '../../_animations/index'; +import { HttpWrapperService } from '../../service/http-wrapper.service'; +import { VideoService } from '../../service/video.service'; @Component({ - selector: 'app-video-detail', - templateUrl: './video-detail.component.html', - styleUrls: ['./video-detail.component.less'], + selector: 'app-video', + templateUrl: './video.component.html', + styleUrls: ['./video.component.less'], animations: [fadeInAnimation], host: { '[@fadeInAnimation]': '' } }) -export class VideoDetailComponent implements OnInit { +export class VideoComponent implements OnInit { id_video:number = -1; error:string = "" @@ -45,7 +44,7 @@ export class VideoDetailComponent implements OnInit { } ngOnInit() { - this.id_video = parseInt(this.route.snapshot.paramMap.get('id')); + this.id_video = parseInt(this.route.snapshot.paramMap.get('video_id')); let self = this; this.videoService.get(this.id_video) .then(function(response) { diff --git a/front/src/app/ariane.service.ts b/front/src/app/service/ariane.service.ts similarity index 69% rename from front/src/app/ariane.service.ts rename to front/src/app/service/ariane.service.ts index 09739c9..baefca5 100644 --- a/front/src/app/ariane.service.ts +++ b/front/src/app/service/ariane.service.ts @@ -6,13 +6,25 @@ import { Injectable, Output, EventEmitter } from '@angular/core' -import { TypeService } from 'app/type.service'; -import { UniversService } from 'app/univers.service'; -import { GroupService } from 'app/group.service'; -import { SaisonService } from 'app/saison.service'; +import { Router, ActivatedRoute, ParamMap } from '@angular/router'; + +import { TypeService } from 'app/service/type.service'; +import { UniversService } from 'app/service/univers.service'; +import { GroupService } from 'app/service/group.service'; +import { SaisonService } from 'app/service/saison.service'; + +export class InputOrders { + public type_id: number = null; + public univers_id: number = null; + public group_id: number = null; + public saison_id: number = null; + public video_id: number = null; +} @Injectable() export class ArianeService { + + public type_id: number = null; public type_name: string = null; @Output() type_change: EventEmitter = new EventEmitter(); @@ -32,7 +44,7 @@ export class ArianeService { public video_id: number = null; @Output() video_change: EventEmitter = new EventEmitter(); - constructor( + constructor(private route: ActivatedRoute, private typeService: TypeService, private universService: UniversService, private groupService: GroupService, @@ -56,6 +68,38 @@ export class ArianeService { this.video_id = null; this.video_change.emit(this.video_id); } + /* + getCurrentRoute():InputOrders { + let out = new InputOrders() + out.type_id = parseInt(this.route.snapshot.paramMap.get('type_id')); + if (out.type_id == 0){ + out.type_id = undefined; + } + out.univers_id = parseInt(this.route.snapshot.paramMap.get('univers_id')); + if (out.univers_id == 0){ + out.univers_id = undefined; + } + out.group_id = parseInt(this.route.snapshot.paramMap.get('group_id')); + if (out.group_id == 0){ + out.group_id = undefined; + } + out.saison_id = parseInt(this.route.snapshot.paramMap.get('saison_id')); + if (out.saison_id == 0){ + out.saison_id = undefined; + } + out.video_id = parseInt(this.route.snapshot.paramMap.get('video_id')); + if (out.video_id == 0){ + out.video_id = undefined; + } + return out; + } + + routeTo(_data:InputOrders, _destination:string = null) { + routeTo = "" + //if ( + this.router.navigate(['/type/' + this.type_id + '/group/' + this.id_group + '/saison/' + _idSelected ]); + } + */ setType(id:number):void { this.type_id = id; diff --git a/front/src/app/auth.service.ts b/front/src/app/service/auth.service.ts similarity index 100% rename from front/src/app/auth.service.ts rename to front/src/app/service/auth.service.ts diff --git a/front/src/app/cookies.service.ts b/front/src/app/service/cookies.service.ts similarity index 100% rename from front/src/app/cookies.service.ts rename to front/src/app/service/cookies.service.ts diff --git a/front/src/app/group.service.ts b/front/src/app/service/group.service.ts similarity index 90% rename from front/src/app/group.service.ts rename to front/src/app/service/group.service.ts index 90e5060..55ed82f 100644 --- a/front/src/app/group.service.ts +++ b/front/src/app/service/group.service.ts @@ -1,5 +1,5 @@ import { Injectable } from '@angular/core'; -import { HttpWrapperService } from 'app/http-wrapper.service'; +import { HttpWrapperService } from 'app/service/http-wrapper.service'; @Injectable() export class GroupService { @@ -24,7 +24,7 @@ export class GroupService { .then(function(response: any) { if (response.status == 200) { resolve(response.data); - console.log("get data from type : " + response.data); + //console.log("get data from type : " + response.data); return; } reject("An error occured"); diff --git a/front/src/app/http-wrapper.service.ts b/front/src/app/service/http-wrapper.service.ts similarity index 98% rename from front/src/app/http-wrapper.service.ts rename to front/src/app/service/http-wrapper.service.ts index 0040a4e..8c85cd6 100644 --- a/front/src/app/http-wrapper.service.ts +++ b/front/src/app/service/http-wrapper.service.ts @@ -7,7 +7,7 @@ import { environment } from 'environments/environment'; @Injectable() export class HttpWrapperService { - private displayReturn:boolean = true; + private displayReturn:boolean = false; constructor(private http: HttpClient) { } diff --git a/front/src/app/saison.service.ts b/front/src/app/service/saison.service.ts similarity index 89% rename from front/src/app/saison.service.ts rename to front/src/app/service/saison.service.ts index 16c3b78..f848515 100644 --- a/front/src/app/saison.service.ts +++ b/front/src/app/service/saison.service.ts @@ -1,5 +1,5 @@ import { Injectable } from '@angular/core'; -import { HttpWrapperService } from 'app/http-wrapper.service'; +import { HttpWrapperService } from 'app/service/http-wrapper.service'; @Injectable() export class SaisonService { @@ -24,7 +24,7 @@ export class SaisonService { .then(function(response: any) { if (response.status == 200) { resolve(response.data); - console.log("get data from type : " + response.data); + //console.log("get data from type : " + response.data); return; } reject("An error occured"); diff --git a/front/src/app/session.service.ts b/front/src/app/service/session.service.ts similarity index 100% rename from front/src/app/session.service.ts rename to front/src/app/service/session.service.ts diff --git a/front/src/app/type.service.ts b/front/src/app/service/type.service.ts similarity index 97% rename from front/src/app/type.service.ts rename to front/src/app/service/type.service.ts index 66a27c3..0e1651f 100644 --- a/front/src/app/type.service.ts +++ b/front/src/app/service/type.service.ts @@ -1,5 +1,5 @@ import { Injectable } from '@angular/core'; -import { HttpWrapperService } from 'app/http-wrapper.service'; +import { HttpWrapperService } from 'app/service/http-wrapper.service'; //import { SHA512 } from 'assets/js_3rd_party/sha512'; export interface MessageLogIn { @@ -32,7 +32,7 @@ export class TypeService { .then(function(response: any) { if (response.status == 200) { resolve(response.data); - console.log("get data from type : " + response.data); + //console.log("get data from type : " + response.data); return; } reject("An error occured"); diff --git a/front/src/app/univers.service.ts b/front/src/app/service/univers.service.ts similarity index 95% rename from front/src/app/univers.service.ts rename to front/src/app/service/univers.service.ts index 5a1bef7..7b645c0 100644 --- a/front/src/app/univers.service.ts +++ b/front/src/app/service/univers.service.ts @@ -1,5 +1,5 @@ import { Injectable } from '@angular/core'; -import { HttpWrapperService } from 'app/http-wrapper.service'; +import { HttpWrapperService } from 'app/service/http-wrapper.service'; @Injectable() export class UniversService { @@ -21,7 +21,7 @@ export class UniversService { .then(function(response: any) { if (response.status == 200) { resolve(response.data); - console.log("get data from univers : " + response.data); + //console.log("get data from univers : " + response.data); return; } reject("An error occured"); diff --git a/front/src/app/user.service.ts b/front/src/app/service/user.service.ts similarity index 98% rename from front/src/app/user.service.ts rename to front/src/app/service/user.service.ts index c34d9a0..4504136 100644 --- a/front/src/app/user.service.ts +++ b/front/src/app/service/user.service.ts @@ -1,5 +1,5 @@ import { Injectable } from '@angular/core'; -import { HttpWrapperService } from 'app/http-wrapper.service'; +import { HttpWrapperService } from 'app/service/http-wrapper.service'; //import { SHA512 } from 'assets/js_3rd_party/sha512'; interface MessageLogIn { diff --git a/front/src/app/video.service.ts b/front/src/app/service/video.service.ts similarity index 87% rename from front/src/app/video.service.ts rename to front/src/app/service/video.service.ts index 9a805c9..3e61d16 100644 --- a/front/src/app/video.service.ts +++ b/front/src/app/service/video.service.ts @@ -1,5 +1,5 @@ import { Injectable } from '@angular/core'; -import { HttpWrapperService } from 'app/http-wrapper.service'; +import { HttpWrapperService } from 'app/service/http-wrapper.service'; @Injectable() export class VideoService { @@ -24,7 +24,7 @@ export class VideoService { .then(function(response: any) { if (response.status == 200) { resolve(response.data); - console.log("get data from response : " + JSON.stringify(response.data, null, 2)); + //console.log("get data from response : " + JSON.stringify(response.data, null, 2)); return; } reject("An error occured"); diff --git a/front/src/app/session.service.spec.ts b/front/src/app/session.service.spec.ts deleted file mode 100644 index 115f5d5..0000000 --- a/front/src/app/session.service.spec.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { TestBed, inject } from '@angular/core/testing'; - -import { SessionService } from './session.service'; - -describe('SessionService', () => { - beforeEach(() => { - TestBed.configureTestingModule({ - providers: [SessionService] - }); - }); - - it('should be created', inject([SessionService], (service: SessionService) => { - expect(service).toBeTruthy(); - })); -}); diff --git a/front/src/app/settings/settings.component.spec.ts b/front/src/app/settings/settings.component.spec.ts deleted file mode 100644 index 91588f3..0000000 --- a/front/src/app/settings/settings.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { SettingsComponent } from './settings.component'; - -describe('SettingsComponent', () => { - let component: SettingsComponent; - let fixture: ComponentFixture; - - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ SettingsComponent ] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(SettingsComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/front/src/app/sign-up/sign-up.component.spec.ts b/front/src/app/sign-up/sign-up.component.spec.ts deleted file mode 100644 index 24c0a1c..0000000 --- a/front/src/app/sign-up/sign-up.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { SignUpComponent } from './sign-up.component'; - -describe('SignUpComponent', () => { - let component: SignUpComponent; - let fixture: ComponentFixture; - - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ SignUpComponent ] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(SignUpComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/front/src/app/top-menu/top-menu.component.spec.ts b/front/src/app/top-menu/top-menu.component.spec.ts deleted file mode 100644 index 999b909..0000000 --- a/front/src/app/top-menu/top-menu.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { TopMenuComponent } from './top-menu.component'; - -describe('TopMenuComponent', () => { - let component: TopMenuComponent; - let fixture: ComponentFixture; - - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ TopMenuComponent ] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(TopMenuComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/front/src/app/type-detail/type-detail.component.spec.ts b/front/src/app/type-detail/type-detail.component.spec.ts deleted file mode 100644 index 909469b..0000000 --- a/front/src/app/type-detail/type-detail.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { TypeDetailComponent } from './type-detail.component'; - -describe('TypeDetailComponent', () => { - let component: TypeDetailComponent; - let fixture: ComponentFixture; - - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ TypeDetailComponent ] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(TypeDetailComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/front/src/app/type.service.spec.ts b/front/src/app/type.service.spec.ts deleted file mode 100644 index 203f5d4..0000000 --- a/front/src/app/type.service.spec.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { TestBed, inject } from '@angular/core/testing'; - -import { UserService } from './user.service'; - -describe('TypeService', () => { - beforeEach(() => { - TestBed.configureTestingModule({ - providers: [testService] - }); - }); - - it('should be created', inject([TypeService], (service: TypeService) => { - expect(service).toBeTruthy(); - })); -}); diff --git a/front/src/app/user.service.spec.ts b/front/src/app/user.service.spec.ts deleted file mode 100644 index b26195c..0000000 --- a/front/src/app/user.service.spec.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { TestBed, inject } from '@angular/core/testing'; - -import { UserService } from './user.service'; - -describe('UserService', () => { - beforeEach(() => { - TestBed.configureTestingModule({ - providers: [UserService] - }); - }); - - it('should be created', inject([UserService], (service: UserService) => { - expect(service).toBeTruthy(); - })); -}); diff --git a/front/src/app/validate-email/validate-email.component.spec.ts b/front/src/app/validate-email/validate-email.component.spec.ts deleted file mode 100644 index 73a0f41..0000000 --- a/front/src/app/validate-email/validate-email.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { ValidateEmailComponent } from './validate-email.component'; - -describe('ValidateEmailComponent', () => { - let component: ValidateEmailComponent; - let fixture: ComponentFixture; - - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ ValidateEmailComponent ] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(ValidateEmailComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/front/src/app/video-detail/video-detail.component.spec.ts b/front/src/app/video-detail/video-detail.component.spec.ts deleted file mode 100644 index 2ff474f..0000000 --- a/front/src/app/video-detail/video-detail.component.spec.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; - -import { VideoDetailComponent } from './video-detail.component'; - -describe('VideoDetailComponent', () => { - let component: VideoDetailComponent; - let fixture: ComponentFixture; - - beforeEach(async(() => { - TestBed.configureTestingModule({ - declarations: [ VideoDetailComponent ] - }) - .compileComponents(); - })); - - beforeEach(() => { - fixture = TestBed.createComponent(VideoDetailComponent); - component = fixture.componentInstance; - fixture.detectChanges(); - }); - - it('should create', () => { - expect(component).toBeTruthy(); - }); -}); diff --git a/front/src/app/video.service.spec.ts b/front/src/app/video.service.spec.ts deleted file mode 100644 index d142e51..0000000 --- a/front/src/app/video.service.spec.ts +++ /dev/null @@ -1,15 +0,0 @@ -import { TestBed, inject } from '@angular/core/testing'; - -import { VideoService } from './video.service'; - -describe('VideoService', () => { - beforeEach(() => { - TestBed.configureTestingModule({ - providers: [VideoService] - }); - }); - - it('should be created', inject([VideoService], (service: VideoService) => { - expect(service).toBeTruthy(); - })); -}); diff --git a/front/src/styles.less b/front/src/styles.less index d812348..48a9be2 100644 --- a/front/src/styles.less +++ b/front/src/styles.less @@ -1,3 +1,24 @@ +@media all and (min-width: 800px) { + .xdesktop{display:block;} + .xtablette{display:none;} + .xphone{display:none;} + .xmobile{display:none;} +} + +@media all and (min-width: 600px) and (max-width: 800px) { + .xdesktop{display:none;} + .xtablette{display:block;} + .xphone{display:none;} + .xmobile{display:block;} +} + +@media all and (max-width: 600px) { + .xdesktop{display:none;} + .xtablette{display:none;} + .xphone{display:block;} + .xmobile{display:block;} +} + html { font-size: 24px;