Merge branch 'clear-forms' into 'develop_v4'

Clearing unused form

See merge request !250
parents 60dab793 a9d670cf
import { Component, OnDestroy, OnInit } from "@angular/core"; import { Component, OnDestroy, OnInit } from "@angular/core";
import { Injectable } from "@angular/core"; import { Injectable } from "@angular/core";
import { FormBuilder, FormGroup } from "@angular/forms";
import { ActivatedRoute, Router } from "@angular/router"; import { ActivatedRoute, Router } from "@angular/router";
import { BehaviorSubject, Subscription } from "rxjs/Rx"; import { BehaviorSubject, Subscription } from "rxjs/Rx";
...@@ -11,7 +10,7 @@ import { HelperDataService } from "../../services/helper-data-service"; ...@@ -11,7 +10,7 @@ import { HelperDataService } from "../../services/helper-data-service";
template: ` template: `
<div class = "loading" *ngIf="(showLoader | async) === true"></div> <div class = "loading" *ngIf="(showLoader | async) === true"></div>
<div style="min-height: 500px;"> <div style="min-height: 500px;">
<form [formGroup]="formGroup"> <form>
<p style="margin-top: 20px; line-height: 2em;"> Στην παρακάτω λίστα βλέπετε τα τμήματα του σχολείου σας με την αντίστοιχη δυναμίκη τους σε αίθουσες. Παρακαλώ για να τροποποποιήσετε τη δυναμικήαυτή κάντε κλικ στον αντίστοιχο σύμβολο, <p style="margin-top: 20px; line-height: 2em;"> Στην παρακάτω λίστα βλέπετε τα τμήματα του σχολείου σας με την αντίστοιχη δυναμίκη τους σε αίθουσες. Παρακαλώ για να τροποποποιήσετε τη δυναμικήαυτή κάντε κλικ στον αντίστοιχο σύμβολο,
...@@ -76,8 +75,6 @@ import { HelperDataService } from "../../services/helper-data-service"; ...@@ -76,8 +75,6 @@ import { HelperDataService } from "../../services/helper-data-service";
@Injectable() export default class DirectorClassCapacity implements OnInit, OnDestroy { @Injectable() export default class DirectorClassCapacity implements OnInit, OnDestroy {
private formGroup: FormGroup;
private CapacityPerCourse$: BehaviorSubject<any>; private CapacityPerCourse$: BehaviorSubject<any>;
private CapacityPerCourseSub: Subscription; private CapacityPerCourseSub: Subscription;
private saveCapacitySub: Subscription; private saveCapacitySub: Subscription;
...@@ -86,19 +83,14 @@ import { HelperDataService } from "../../services/helper-data-service"; ...@@ -86,19 +83,14 @@ import { HelperDataService } from "../../services/helper-data-service";
private courseActive = <number>-1; private courseActive = <number>-1;
private showLoader: BehaviorSubject<boolean>; private showLoader: BehaviorSubject<boolean>;
constructor(private fb: FormBuilder, constructor(
private _hds: HelperDataService, private _hds: HelperDataService,
private activatedRoute: ActivatedRoute, private activatedRoute: ActivatedRoute,
private router: Router) { private router: Router
) {
this.CapacityPerCourse$ = new BehaviorSubject([{}]); this.CapacityPerCourse$ = new BehaviorSubject([{}]);
this.showLoader = new BehaviorSubject(false); this.showLoader = new BehaviorSubject(false);
this.isEdit = false; this.isEdit = false;
this.formGroup = this.fb.group({
});
} }
public showModal(popupMsgId): void { public showModal(popupMsgId): void {
......
import { Component, OnDestroy, OnInit } from "@angular/core"; import { Component, OnDestroy, OnInit } from "@angular/core";
import { Injectable } from "@angular/core"; import { Injectable } from "@angular/core";
import { FormBuilder, FormGroup } from "@angular/forms";
import { ActivatedRoute, Router } from "@angular/router"; import { ActivatedRoute, Router } from "@angular/router";
import { BehaviorSubject, Subscription } from "rxjs/Rx"; import { BehaviorSubject, Subscription } from "rxjs/Rx";
...@@ -51,8 +50,7 @@ import { HelperDataService } from "../../services/helper-data-service"; ...@@ -51,8 +50,7 @@ import { HelperDataService } from "../../services/helper-data-service";
</div> </div>
<div class = "loading" *ngIf="(showLoader | async) === true"></div> <div class = "loading" *ngIf="(showLoader | async) === true"></div>
<div style="min-height: 500px;"> <div style="min-height: 500px;">
<form [formGroup]="formGroup"> <form>
<p style="margin-top: 20px; line-height: 2em;"> H παρακάτω λίστα διαμορφώνει τη δυναμική του σχολείου σας σε τμήματα με κριτήριο τον αριθμό των διαθεσίμων αιθουσών. </p> <p style="margin-top: 20px; line-height: 2em;"> H παρακάτω λίστα διαμορφώνει τη δυναμική του σχολείου σας σε τμήματα με κριτήριο τον αριθμό των διαθεσίμων αιθουσών. </p>
<p style="margin-top: 20px; line-height: 2em;"> Παρακαλείστε να καταγράψετε τον αριθμό των τμημάτων ανά τάξη, τομέα και ειδικότητα. </p> <p style="margin-top: 20px; line-height: 2em;"> Παρακαλείστε να καταγράψετε τον αριθμό των τμημάτων ανά τάξη, τομέα και ειδικότητα. </p>
...@@ -262,8 +260,6 @@ import { HelperDataService } from "../../services/helper-data-service"; ...@@ -262,8 +260,6 @@ import { HelperDataService } from "../../services/helper-data-service";
@Injectable() export default class DirectorClassCapacity implements OnInit, OnDestroy { @Injectable() export default class DirectorClassCapacity implements OnInit, OnDestroy {
private formGroup: FormGroup;
private CoursesPerSchool$: BehaviorSubject<any>; private CoursesPerSchool$: BehaviorSubject<any>;
private CoursesPerSchoolSub: Subscription; private CoursesPerSchoolSub: Subscription;
private StudentInfo$: BehaviorSubject<any>; private StudentInfo$: BehaviorSubject<any>;
...@@ -280,21 +276,17 @@ import { HelperDataService } from "../../services/helper-data-service"; ...@@ -280,21 +276,17 @@ import { HelperDataService } from "../../services/helper-data-service";
private sector = <number>0; private sector = <number>0;
private special = <number>0; private special = <number>0;
constructor(private fb: FormBuilder, constructor(
private _hds: HelperDataService, private _hds: HelperDataService,
private activatedRoute: ActivatedRoute, private activatedRoute: ActivatedRoute,
private router: Router) { private router: Router
) {
this.CoursesPerSchool$ = new BehaviorSubject([{}]); this.CoursesPerSchool$ = new BehaviorSubject([{}]);
this.showLoader = new BehaviorSubject(false); this.showLoader = new BehaviorSubject(false);
this.StudentInfo$ = new BehaviorSubject([{}]); this.StudentInfo$ = new BehaviorSubject([{}]);
this.retrievedStudent = new BehaviorSubject(false); this.retrievedStudent = new BehaviorSubject(false);
this.SavedStudents$ = new BehaviorSubject({}); this.SavedStudents$ = new BehaviorSubject({});
this.opened = false; this.opened = false;
this.formGroup = this.fb.group({
});
} }
public showConfirmModal(): void { public showConfirmModal(): void {
......
import { Component, Injectable, OnDestroy, OnInit } from "@angular/core"; import { Component, Injectable, OnDestroy, OnInit } from "@angular/core";
import { FormBuilder, FormGroup } from "@angular/forms";
import { Router } from "@angular/router"; import { Router } from "@angular/router";
import { BehaviorSubject, Subscription } from "rxjs/Rx"; import { BehaviorSubject, Subscription } from "rxjs/Rx";
...@@ -26,7 +25,7 @@ import { HelperDataService } from "../../services/helper-data-service"; ...@@ -26,7 +25,7 @@ import { HelperDataService } from "../../services/helper-data-service";
</div> </div>
</div> </div>
<div style="min-height: 500px;"> <div style="min-height: 500px;">
<form [formGroup]="formGroup"> <form>
<p style="margin-top: 20px; line-height: 2em;">Στην παρακάτω λίστα βλέπετε τα σχολεία ευθύνης σας. <p style="margin-top: 20px; line-height: 2em;">Στην παρακάτω λίστα βλέπετε τα σχολεία ευθύνης σας.
<br/>Επιλέξτε σχολείο για να εμφανιστούν τα τμήματα του σχολείου.</p> <br/>Επιλέξτε σχολείο για να εμφανιστούν τα τμήματα του σχολείου.</p>
<div class="row" style="margin-top: 20px; line-height: 2em;"><p><strong>Τα τμήματα</strong></p></div> <div class="row" style="margin-top: 20px; line-height: 2em;"><p><strong>Τα τμήματα</strong></p></div>
...@@ -59,7 +58,6 @@ import { HelperDataService } from "../../services/helper-data-service"; ...@@ -59,7 +58,6 @@ import { HelperDataService } from "../../services/helper-data-service";
@Injectable() export default class EduadminView implements OnInit, OnDestroy { @Injectable() export default class EduadminView implements OnInit, OnDestroy {
private formGroup: FormGroup;
private SchoolsPerPerf$: BehaviorSubject<any>; private SchoolsPerPerf$: BehaviorSubject<any>;
private SchoolPerPerfSub: Subscription; private SchoolPerPerfSub: Subscription;
private LimitPerCateg$: BehaviorSubject<any>; private LimitPerCateg$: BehaviorSubject<any>;
...@@ -76,7 +74,7 @@ import { HelperDataService } from "../../services/helper-data-service"; ...@@ -76,7 +74,7 @@ import { HelperDataService } from "../../services/helper-data-service";
private modalText: BehaviorSubject<string>; private modalText: BehaviorSubject<string>;
private modalHeader: BehaviorSubject<string>; private modalHeader: BehaviorSubject<string>;
constructor(private fb: FormBuilder, constructor(
private router: Router, private router: Router,
private _hds: HelperDataService, private _hds: HelperDataService,
) { ) {
...@@ -86,8 +84,6 @@ import { HelperDataService } from "../../services/helper-data-service"; ...@@ -86,8 +84,6 @@ import { HelperDataService } from "../../services/helper-data-service";
this.StudentsSize$ = new BehaviorSubject({}); this.StudentsSize$ = new BehaviorSubject({});
this.School$ = new BehaviorSubject([{}]); this.School$ = new BehaviorSubject([{}]);
this.showLoader = new BehaviorSubject(false); this.showLoader = new BehaviorSubject(false);
this.formGroup = this.fb.group({
});
this.modalTitle = new BehaviorSubject(""); this.modalTitle = new BehaviorSubject("");
this.modalText = new BehaviorSubject(""); this.modalText = new BehaviorSubject("");
this.modalHeader = new BehaviorSubject(""); this.modalHeader = new BehaviorSubject("");
......
import { Component, Injectable, OnDestroy, OnInit } from "@angular/core"; import { Component, Injectable, OnDestroy, OnInit } from "@angular/core";
import { FormBuilder, FormGroup } from "@angular/forms";
import { Router } from "@angular/router"; import { Router } from "@angular/router";
import { BehaviorSubject, Subscription } from "rxjs/Rx"; import { BehaviorSubject, Subscription } from "rxjs/Rx";
...@@ -26,7 +25,7 @@ import { HelperDataService } from "../../services/helper-data-service"; ...@@ -26,7 +25,7 @@ import { HelperDataService } from "../../services/helper-data-service";
</div> </div>
</div> </div>
<div style="min-height: 500px;"> <div style="min-height: 500px;">
<form [formGroup]="formGroup"> <form>
<p style="margin-top: 20px; line-height: 2em;">Στην παρακάτω λίστα βλέπετε τα σχολεία ευθύνης σας. <p style="margin-top: 20px; line-height: 2em;">Στην παρακάτω λίστα βλέπετε τα σχολεία ευθύνης σας.
<br/>Επιλέξτε σχολείο για να εμφανιστούν τα τμήματα του σχολείου.</p> <br/>Επιλέξτε σχολείο για να εμφανιστούν τα τμήματα του σχολείου.</p>
<div class="row" style="margin-top: 20px; line-height: 2em;"><p><strong>Τα τμήματα</strong></p></div> <div class="row" style="margin-top: 20px; line-height: 2em;"><p><strong>Τα τμήματα</strong></p></div>
...@@ -58,7 +57,6 @@ import { HelperDataService } from "../../services/helper-data-service"; ...@@ -58,7 +57,6 @@ import { HelperDataService } from "../../services/helper-data-service";
@Injectable() export default class EduadminView implements OnInit, OnDestroy { @Injectable() export default class EduadminView implements OnInit, OnDestroy {
private formGroup: FormGroup;
private SchoolsPerPerf$: BehaviorSubject<any>; private SchoolsPerPerf$: BehaviorSubject<any>;
private SchoolPerPerfSub: Subscription; private SchoolPerPerfSub: Subscription;
private LimitPerCateg$: BehaviorSubject<any>; private LimitPerCateg$: BehaviorSubject<any>;
...@@ -75,7 +73,7 @@ import { HelperDataService } from "../../services/helper-data-service"; ...@@ -75,7 +73,7 @@ import { HelperDataService } from "../../services/helper-data-service";
private modalText: BehaviorSubject<string>; private modalText: BehaviorSubject<string>;
private modalHeader: BehaviorSubject<string>; private modalHeader: BehaviorSubject<string>;
constructor(private fb: FormBuilder, constructor(
private router: Router, private router: Router,
private _hds: HelperDataService, private _hds: HelperDataService,
) { ) {
...@@ -85,8 +83,6 @@ import { HelperDataService } from "../../services/helper-data-service"; ...@@ -85,8 +83,6 @@ import { HelperDataService } from "../../services/helper-data-service";
this.StudentsSize$ = new BehaviorSubject({}); this.StudentsSize$ = new BehaviorSubject({});
this.School$ = new BehaviorSubject([{}]); this.School$ = new BehaviorSubject([{}]);
this.showLoader = new BehaviorSubject(false); this.showLoader = new BehaviorSubject(false);
this.formGroup = this.fb.group({
});
this.modalTitle = new BehaviorSubject(""); this.modalTitle = new BehaviorSubject("");
this.modalText = new BehaviorSubject(""); this.modalText = new BehaviorSubject("");
this.modalHeader = new BehaviorSubject(""); this.modalHeader = new BehaviorSubject("");
......
...@@ -19,11 +19,6 @@ export class CsvCreator { ...@@ -19,11 +19,6 @@ export class CsvCreator {
search: query search: query
} }
], false); ], false);
// second parameter specifying whether to perform "AND" or "OR" search
// (meaning all columns should contain search query or at least one)
// "AND" by default, so changing to "OR" by setting false here
} }
......
import { NgRedux } from "@angular-redux/store"; import { NgRedux } from "@angular-redux/store";
import { Component, OnDestroy, OnInit } from "@angular/core"; import { Component, OnDestroy, OnInit } from "@angular/core";
import { Injectable } from "@angular/core"; import { Injectable } from "@angular/core";
import { FormBuilder, FormGroup } from "@angular/forms";
import { ActivatedRoute, Router } from "@angular/router"; import { ActivatedRoute, Router } from "@angular/router";
import { BehaviorSubject, Subscription } from "rxjs/Rx"; import { BehaviorSubject, Subscription } from "rxjs/Rx";
...@@ -73,7 +72,6 @@ import { IAppState } from "../../store/store"; ...@@ -73,7 +72,6 @@ import { IAppState } from "../../store/store";
@Injectable() export default class MinisterReports implements OnInit, OnDestroy { @Injectable() export default class MinisterReports implements OnInit, OnDestroy {
private formGroup: FormGroup;
private loginInfo$: BehaviorSubject<ILoginInfoRecords>; private loginInfo$: BehaviorSubject<ILoginInfoRecords>;
private loginInfoSub: Subscription; private loginInfoSub: Subscription;
private apiEndPoint = API_ENDPOINT; private apiEndPoint = API_ENDPOINT;
...@@ -82,22 +80,15 @@ import { IAppState } from "../../store/store"; ...@@ -82,22 +80,15 @@ import { IAppState } from "../../store/store";
private distStatus = "READY"; private distStatus = "READY";
private userRole: string; private userRole: string;
constructor(private fb: FormBuilder, constructor(
private _ngRedux: NgRedux<IAppState>, private _ngRedux: NgRedux<IAppState>,
private _hds: HelperDataService, private _hds: HelperDataService,
private activatedRoute: ActivatedRoute, private activatedRoute: ActivatedRoute,
private router: Router) { private router: Router
) {
this.formGroup = this.fb.group({
region: ["", []],
adminarea: ["", []],
schoollist: ["", []],
});
this.loginInfo$ = new BehaviorSubject(LOGININFO_INITIAL_STATE); this.loginInfo$ = new BehaviorSubject(LOGININFO_INITIAL_STATE);
this.minedu_userName = ""; this.minedu_userName = "";
this.userRole = MINISTRY_ROLE; this.userRole = MINISTRY_ROLE;
} }
ngOnInit() { ngOnInit() {
......
import { NgRedux } from "@angular-redux/store"; import { NgRedux } from "@angular-redux/store";
import { Injectable } from "@angular/core"; import { Injectable } from "@angular/core";
import { Component, ElementRef, Input, OnDestroy, OnInit, ViewChild } from "@angular/core"; import { Component, ElementRef, Input, OnDestroy, OnInit, ViewChild } from "@angular/core";
import { FormBuilder, FormGroup } from "@angular/forms";
import { ActivatedRoute, Router } from "@angular/router"; import { ActivatedRoute, Router } from "@angular/router";
import { LocalDataSource } from "ng2-smart-table"; import { LocalDataSource } from "ng2-smart-table";
import { BehaviorSubject, Subscription } from "rxjs/Rx"; import { BehaviorSubject, Subscription } from "rxjs/Rx";
...@@ -24,7 +23,7 @@ import { ReportsSchema, TableColumn } from "./reports-schema"; ...@@ -24,7 +23,7 @@ import { ReportsSchema, TableColumn } from "./reports-schema";
class = "loading" *ngIf="validCreator == 0" > class = "loading" *ngIf="validCreator == 0" >
</div> </div>
<form [formGroup]="formGroup" #form> <form #form>
<h5> >Επιλογή Φίλτρων <br><br></h5> <h5> >Επιλογή Φίλτρων <br><br></h5>
<h6> Δεν υπάρχουν διαθέσιμα φίλτρα <br><br><br></h6> <h6> Δεν υπάρχουν διαθέσιμα φίλτρα <br><br><br></h6>
...@@ -66,7 +65,6 @@ import { ReportsSchema, TableColumn } from "./reports-schema"; ...@@ -66,7 +65,6 @@ import { ReportsSchema, TableColumn } from "./reports-schema";
@Injectable() export default class ReportGeneral implements OnInit, OnDestroy { @Injectable() export default class ReportGeneral implements OnInit, OnDestroy {
private formGroup: FormGroup;
private loginInfo$: BehaviorSubject<ILoginInfoRecords>; private loginInfo$: BehaviorSubject<ILoginInfoRecords>;
private loginInfoSub: Subscription; private loginInfoSub: Subscription;
private generalReport$: BehaviorSubject<any>; private generalReport$: BehaviorSubject<any>;
...@@ -89,18 +87,12 @@ import { ReportsSchema, TableColumn } from "./reports-schema"; ...@@ -89,18 +87,12 @@ import { ReportsSchema, TableColumn } from "./reports-schema";
@ViewChild("chart") public chartContainer: ElementRef; @ViewChild("chart") public chartContainer: ElementRef;
private d3data: Array<any>; private d3data: Array<any>;
constructor(private fb: FormBuilder, constructor(
private _ngRedux: NgRedux<IAppState>, private _ngRedux: NgRedux<IAppState>,
private _hds: HelperDataService, private _hds: HelperDataService,
private activatedRoute: ActivatedRoute, private activatedRoute: ActivatedRoute,
private router: Router) { private router: Router
) {
this.formGroup = this.fb.group({
region: ["", []],
adminarea: ["", []],
schoollist: ["", []],
});
this.loginInfo$ = new BehaviorSubject(LOGININFO_INITIAL_STATE); this.loginInfo$ = new BehaviorSubject(LOGININFO_INITIAL_STATE);
this.generalReport$ = new BehaviorSubject([{}]); this.generalReport$ = new BehaviorSubject([{}]);
this.minedu_userName = ""; this.minedu_userName = "";
......
import { NgRedux } from "@angular-redux/store"; import { NgRedux } from "@angular-redux/store";
import { Component, OnDestroy, OnInit } from "@angular/core"; import { Component, OnDestroy, OnInit } from "@angular/core";
import { FormBuilder, FormGroup } from "@angular/forms";
import { ActivatedRoute, Params, Router } from "@angular/router"; import { ActivatedRoute, Params, Router } from "@angular/router";
import { CookieService } from "ngx-cookie"; import { CookieService } from "ngx-cookie";
import { BehaviorSubject, Subscription } from "rxjs/Rx"; import { BehaviorSubject, Subscription } from "rxjs/Rx";
...@@ -35,7 +34,7 @@ import { IAppState } from "../store/store"; ...@@ -35,7 +34,7 @@ import { IAppState } from "../store/store";
</div> </div>
</div> </div>
<div *ngIf="(errorCode$ | async) == ''"> <div *ngIf="(errorCode$ | async) == ''">
<form [formGroup]="formGroup" method = "POST" action="{{apiEndPoint}}/cas/login{{apiEndPointParams}}" #form> <form method = "POST" action="{{apiEndPoint}}/cas/login{{apiEndPointParams}}" #form>
<!-- <input type="hidden" name="X-oauth-enabled" value="true"> --> <!-- <input type="hidden" name="X-oauth-enabled" value="true"> -->
<div *ngFor="let loginInfoToken$ of loginInfo$ | async; let i=index"></div> <div *ngFor="let loginInfoToken$ of loginInfo$ | async; let i=index"></div>
<div class="row"> <div class="row">
...@@ -52,7 +51,6 @@ import { IAppState } from "../store/store"; ...@@ -52,7 +51,6 @@ import { IAppState } from "../store/store";
}) })
export default class SchoolHome implements OnInit, OnDestroy { export default class SchoolHome implements OnInit, OnDestroy {
private formGroup: FormGroup;
private authToken: string; private authToken: string;
private errorCode$: BehaviorSubject<string>; private errorCode$: BehaviorSubject<string>;
private authRole: string; private authRole: string;
...@@ -64,7 +62,7 @@ export default class SchoolHome implements OnInit, OnDestroy { ...@@ -64,7 +62,7 @@ export default class SchoolHome implements OnInit, OnDestroy {
private apiEndPoint = API_ENDPOINT; private apiEndPoint = API_ENDPOINT;
private apiEndPointParams = API_ENDPOINT_PARAMS; private apiEndPointParams = API_ENDPOINT_PARAMS;
constructor(private fb: FormBuilder, constructor(
private _ata: LoginInfoActions, private _ata: LoginInfoActions,
private _ngRedux: NgRedux<IAppState>, private _ngRedux: NgRedux<IAppState>,
private activatedRoute: ActivatedRoute, private activatedRoute: ActivatedRoute,
...@@ -77,8 +75,6 @@ export default class SchoolHome implements OnInit, OnDestroy { ...@@ -77,8 +75,6 @@ export default class SchoolHome implements OnInit, OnDestroy {
this.name = ""; this.name = "";
this.loginInfo$ = new BehaviorSubject(LOGININFO_INITIAL_STATE); this.loginInfo$ = new BehaviorSubject(LOGININFO_INITIAL_STATE);
this.errorCode$ = new BehaviorSubject(""); this.errorCode$ = new BehaviorSubject("");
this.formGroup = this.fb.group({
});
}; };
ngOnDestroy() { ngOnDestroy() {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment