Commit 0bb5c7e3 authored by Open Source Developer's avatar Open Source Developer

tranfer

parent 88ffd174
......@@ -15,7 +15,7 @@ current_user:
requirements:
_user_is_logged_in: 'TRUE'
submitedapplications:
path: '/epal/subapplic/{$studentid}'
path: '/epal/subapplic'
options:
_auth: [ 'basic_auth' ]
defaults:
......
......@@ -34,44 +34,38 @@ class SubmitedApplications extends ControllerBase
$epalUsers = $this->entityTypeManager->getStorage('epal_users')->loadByProperties(array('authtoken' => $authToken));
$epalUser = reset($epalUsers);
if ($epalUser) {
$userid = $epalUser -> user_id -> entity ->id();
$userid = $epalUser -> id();
$epalStudents = $this->entityTypeManager->getStorage('epal_student')->loadByProperties(array('user_id' => $userid));
$epalStudent = reset($epalStudents);
if ($epalStudent) {
return $this->respondWithStatus([
'name' => $epalStudent ->name->value,
'studentsurname' => $epalStudent ->studentsurname->value,
], Response::HTTP_OK);
}
else {
return $this->respondWithStatus([
'message' => t("EPAL user not found"),
], Response::HTTP_FORBIDDEN);
}
if ($studentid){
$epalStudents = $this->entityTypeManager->getStorage('epal_student')->loadByProperties(array('epaluser_id' => $userid));
//$epalStudent = reset($epalStudents);
$i = 0;
if ($epalStudents) {
$list = array();
foreach ($epalStudents as $object) {
$list[] = array('name' => $object -> name ->value,
$StudentSelection = $this->entityTypeManager->getStorage('epal_student_epal_chosen')->loadByProperties(array('student_id' => $studentid, 'user_id' => $userid ));
$StudentSel = reset($StudentSelection);
if ($StudentSel) {
return $this->respondWithStatus([
'epal_id' => $epalStudent ->epal_id->entity->getEpal_id(),
], Response::HTTP_OK);
'studentsurname' => $object -> studentsurname ->value);
$i++;
}
return $this->respondWithStatus(
$list
, Response::HTTP_OK);
}
else {
return $this->respondWithStatus([
'message' => t("SpecificStudent not found"),
'message' => t("EPAL user not found"),
], Response::HTTP_FORBIDDEN);
}
}
} else {
return $this->respondWithStatus([
'message' => t("EPAL user not found"),
'message' => t(" user not found"),
], Response::HTTP_FORBIDDEN);
}
}
......
......@@ -8,7 +8,7 @@
<img src="../myschool/assets/images/myschool_logo.png" alt="Αρχική" />
</a>
<div class="collapse navbar-collapse flex-row-reverse" id="navbarNav">
<div *ngFor="let loginInfoToken$ of loginInfo$ | async; let i=index"></div>
<div *ngFor="let loginInfoToken$ of loginInfo$ | async; let i=index "></div>
<ul class="navbar-nav">
<div *ngFor="let username$ of loginInfo$ | async;">
......@@ -21,42 +21,17 @@
<i class="fa fa-sign-out"></i>
</button>
</div>
<div class="pull-right" class="nav-item" [ngClass]="{active: path=='submited-preview'}">
<a class="nav-link" [routerLink]="['/submited-preview']" [routerLinkActive]="['active']"><b>Υποβληθείσες αιτήσεις</b></a>
</div>
</div>
<!--
<li class="nav-item" [ngClass]="{active: path=='application-preview'}">
<a class="nav-link" [routerLink]="['/application-preview']" [routerLinkActive]="['active']">Προεπισκόπηση</a>
</li>
<li class="nav-item" [ngClass]="{active: path=='amka-fill'}">
<a class="nav-link" [routerLink]="['/amka-fill']" [routerLinkActive]="['active']">ΑΜΚΑ ΜΑΘΗΤΗ</a>
</li>
<li class="nav-item" [ngClass]="{active: path=='epal-class-select'}">
<a class="nav-link" [routerLink]="['/epal-class-select']" [routerLinkActive]="['active']">Τάξη</a>
</li>
<li class="nav-item" [ngClass]="{active: path=='sector-fields-select'}">
<a class="nav-link" [routerLink]="['/sector-fields-select']" [routerLinkActive]="['active']">Τομεας</a>
</li>
<li class="nav-item" [ngClass]="{active: path=='sectorcourses-fields-select'}">
<a class="nav-link" [routerLink]="['/sectorcourses-fields-select']" [routerLinkActive]="['active']">Ειδικοτητα</a>
</li>
<li class="nav-item" [ngClass]="{active: path=='region-schools-select'}">
<a class="nav-link" [routerLink]="['/region-schools-select']" [routerLinkActive]="['active']">Σχολειο</a>
</li>
<li class="nav-item" [ngClass]="{active: path=='student-application-form-main'}">
<a class="nav-link" [routerLink]="['/student-application-form-main']" [routerLinkActive]="['active']">Αιτηση</a>
</li>
-->
<!--
<li class="nav-item" [ngClass]="{active: path=='schools-order-select'}">
<a class="nav-link" [routerLink]="['/schools-order-select']" [routerLinkActive]="['active']">Σειρά επιλογής</a>
</li>
-->
</div>
</ul>
</div>
<div class="pull-right" class="nav-item" [ngClass]="{active: path=='submited-preview'}">
<a class="nav-link" [routerLink]="['/submited-preview']" [routerLinkActive]="['active']"><b>Υποβληθείσες αιτήσεις</b></a>
</div>
</nav>
</div>
</div>
import { Component, OnInit, ElementRef, ViewChild} from "@angular/core";
import { Component, OnInit, OnDestroy,ElementRef, ViewChild} from "@angular/core";
let jsPDF = require('jspdf');
import { Injectable } from "@angular/core";
import { AppSettings } from '../../app.settings';
......@@ -6,7 +6,6 @@ import { HelperDataService } from '../../services/helper-data-service';
import {Observable} from "rxjs/Observable";
import {IStudentDataFields, IStudentDataField} from '../../store/studentdatafields';
import {Http, Headers, RequestOptions} from '@angular/http';
import * as html2canvas from "html2canvas"
import {Removetags} from '../../pipes/removehtmltags';
import { NgRedux, select } from 'ng2-redux';
import { IAppState } from '../../store/store';
......@@ -18,66 +17,49 @@ import { BehaviorSubject, Subscription } from 'rxjs/Rx';
@Component({
selector: 'submited-preview',
template: `
<h5 style="margin-top: 20px; line-height: 2em; ">Έχετε ολοκληρώσει την αίτηση για εγγραφή στην επαγγελπατική εκπαίδευση των παρακάτω ατόμων:</h5>
<div *ngFor="let userdata$ of submitedapplic$ | async; ">
<ul class="list-group left-side-view" style="margin-bottom: 20px;">
<li class="list-group-item active">
Μαθητής: {{userdata$.name}}
</li>
</ul>
</div>
<button type="submit" (click)="studentpreview()"> Λεπτομέρειες
</button>
<div *ngFor="let userdata$ of submitedapplic$ | async">
{{userdata$.name}}
</div>
`
})
@Injectable() export default class SubmitedPreview implements OnInit {
@Injectable() export default class SubmitedPreview implements OnInit , OnDestroy{
public html2canvas: any;
private submitedapplic$: BehaviorSubject<any>;
private submitedusers$: Subscription;
private submitedusersSub: Subscription;
public studentid = 1 ;
constructor(private _hds: HelperDataService,
public http: Http,
private _ngRedux: NgRedux<IAppState>,
private activatedRoute: ActivatedRoute,
private router: Router )
{
this.submitedapplic$ = new BehaviorSubject({});
this.submitedapplic$ = new BehaviorSubject([{}]);
}
ngOnDestroy()
{
if (this.submitedusersSub)
this.submitedusersSub.unsubscribe();
}
ngOnInit() {
this.submitedusers$ = this._hds.getSubmittedPreviw(0).subscribe(this.submitedapplic$);
console.log("subscription", this.submitedusers$, "behavior", this.submitedapplic$);
this.submitedusersSub = this._hds.getSubmittedPreviw().subscribe(this.submitedapplic$);
this.submitedapplic$.subscribe( function (x) { console.log("I am in next"); console.log(x); }, function (err) { console.log('Error: ' + err); }, function () { console.log('Completed='); } );
}
createPdf()
{
html2canvas(document.getElementById("target")).then(function(canvas)
{
var img = canvas.toDataURL();
var doc = new jsPDF('p', 'mm');
doc.addImage(img, 'PNG', 10, 10);
doc.save('applications.pdf');
}
);
}
studentpreview()
{
......
......@@ -6,7 +6,6 @@ import { HelperDataService } from '../../services/helper-data-service';
import {Observable} from "rxjs/Observable";
import {IStudentDataFields, IStudentDataField} from '../../store/studentdatafields';
import {Http, Headers, RequestOptions} from '@angular/http';
import * as html2canvas from "html2canvas"
import {Removetags} from '../../pipes/removehtmltags';
import { NgRedux, select } from 'ng2-redux';
import { IAppState } from '../../store/store';
......@@ -66,26 +65,11 @@ import { BehaviorSubject, Subscription } from 'rxjs/Rx';
}
});
this.submitedusers$ = this._hds.getSubmittedPreviw(this.userid).subscribe(this.submitedapplic$);
console.log("subscription", this.submitedusers$, "behavior", this.submitedapplic$);
}
createPdf()
{
html2canvas(document.getElementById("target")).then(function(canvas)
{
var img = canvas.toDataURL();
var doc = new jsPDF('p', 'mm');
doc.addImage(img, 'PNG', 10, 10);
doc.save('applications.pdf');
}
);
}
}
\ No newline at end of file
......@@ -333,7 +333,7 @@ transformUserSchema(userlogin:any,oauthtoken:string, oauthrole:string){
getSubmittedPreviw(stud_id) {
getSubmittedPreviw() {
this.loginInfo$.forEach(loginInfoToken => {
this.authToken = loginInfoToken.get(0).auth_token;
......@@ -343,9 +343,13 @@ transformUserSchema(userlogin:any,oauthtoken:string, oauthrole:string){
});
this.createAuthorizationHeader(headers);
let options = new RequestOptions({ headers: headers });
return this.http.get(`${AppSettings.API_ENDPOINT}/epal/subapplic`, options , {params:{"param1": stud_id}})
return this.http.get(`${AppSettings.API_ENDPOINT}/epal/subapplic`, options )
.map(response => response.json());
}
}
"use strict";
const immutable_1 = require("immutable");
// export const INITIAL_STATE = List<ICourseField>([new CourseFieldRecord({})]);
exports.INITIAL_STATE = immutable_1.List();
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY291cnNlZmllbGRzLmluaXRpYWwtc3RhdGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJjb3Vyc2VmaWVsZHMuaW5pdGlhbC1zdGF0ZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBQUEseUNBQWlDO0FBR2pDLGdGQUFnRjtBQUNuRSxRQUFBLGFBQWEsR0FBRyxnQkFBSSxFQUFnQixDQUFDIn0=
\ No newline at end of file
"use strict";
const coursefields_initial_state_1 = require("./coursefields.initial-state");
const immutable_1 = require("immutable");
const constants_1 = require("../../constants");
function courseFieldsReducer(state = coursefields_initial_state_1.INITIAL_STATE, action) {
switch (action.type) {
case constants_1.COURSEFIELDS_RECEIVED:
let newCourseFields = Array();
let i = 0;
action.payload.courseFields.forEach(courseField => {
newCourseFields.push({ id: courseField.id, name: courseField.name, selected: false });
i++;
});
return immutable_1.Seq(newCourseFields).map(n => n).toList();
case constants_1.COURSEFIELDS_SELECTED_SAVE:
let selectedCourseFields = Array();
let ind = 0;
state.forEach(courseField => {
selectedCourseFields.push({ id: courseField.id, name: courseField.name, selected: action.payload.courseFieldsSelected[ind] });
ind++;
});
return immutable_1.Seq(selectedCourseFields).map(n => n).toList();
default: return state;
}
}
exports.courseFieldsReducer = courseFieldsReducer;
;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY291cnNlZmllbGRzLn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ksRUFBRSxXQUFXLENBQUMsSUFBSSxFQUFFLFFBQVEsRUFBRSxNQUFNLENBQUMsT0FBTyxDQUFDLG9CQUFvQixDQUFDLEdBQUcsQ0FBQyxFQUFDLENBQUMsQ0FBQztnQkFDMUksR0FBRyxFQUFFLENBQUM7WUFDVixDQUFDLENBQUMsQ0FBQztZQUNILE1BQU0sQ0FBQyxlQUFHLENBQUMsb0JBQW9CLENBQUMsQ0FBQyxHQUFHLENBQUMsQ0FBQyxJQUFJLENBQUMsQ0FBQyxDQUFDLE1BQU0sRUFBRSxDQUFDO1FBQzFELFNBQVMsTUFBTSxDQUFDLEtBQUssQ0FBQztJQUN4QixDQUFDO0FBQ0gsQ0FBQztBQXBCRCxrREFvQkM7QUFBQSxDQUFDIn0=
\ No newline at end of file
"use strict";
function deimmutifyCourseFields(state) {
let fetchedCourseFields = new Array();
state.forEach(courseField => {
fetchedCourseFields.push({ id: courseField.id, name: courseField.name, selected: courseField.selected });
});
return fetchedCourseFields;
}
exports.deimmutifyCourseFields = deimmutifyCourseFields;
;
/* export function reimmutifyCourseFields(plain): ICourseFields {
return List<ICourseField>(plain ? plain.map(CourseFieldRecord) : []);
} */
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY291cnNlZmllbGRzLnRyYW5zZm9ybWVycy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbImNvdXJzZWZpZWxkcy50cmFuc2Zvcm1lcnMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IjtBQUVBLGdDQUF1QyxLQUFvQjtJQUN2RCxJQUFJLG1CQUFtQixHQUFHLElBQUksS0FBSyxFQUFFLENBQUM7SUFDdEMsS0FBSyxDQUFDLE9BQU8sQ0FBQyxXQUFXO1FBQ3JCLG1CQUFtQixDQUFDLElBQUksQ0FBZSxFQUFDLEVBQUUsRUFBRSxXQUFXLENBQUMsRUFBRSxFQUFFLElBQUksRUFBRSxXQUFXLENBQUMsSUFBSSxFQUFFLFFBQVEsRUFBRSxXQUFXLENBQUMsUUFBUSxFQUFDLENBQUMsQ0FBQztJQUN6SCxDQUFDLENBQUMsQ0FBQztJQUNILE1BQU0sQ0FBQyxtQkFBbUIsQ0FBQztBQUMvQixDQUFDO0FBTkQsd0RBTUM7QUFBQSxDQUFDO0FBRUY7O0lBRUkifQ==
\ No newline at end of file
"use strict";
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY291cnNlZmllbGRzLnR5cGVzLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiY291cnNlZmllbGRzLnR5cGVzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiIifQ==
\ No newline at end of file
"use strict";
const coursefields_reducer_1 = require("./coursefields.reducer");
exports.courseFieldsReducer = coursefields_reducer_1.courseFieldsReducer;
const coursefields_transformers_1 = require("./coursefields.transformers");
exports.deimmutifyCourseFields = coursefields_transformers_1.deimmutifyCourseFields;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJpbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBQ0EsaUVBQTZEO0FBTTNELHlFQUFtQjtBQUxyQiwyRUFBcUU7QUFNbkUsb0ZBQXNCIn0=
\ No newline at end of file
"use strict";
const immutable_1 = require("immutable");
exports.CRITERIA_INITIAL_STATE = immutable_1.List();
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY3JpdGVyaWEuaW5pdGlhbC1zdGF0ZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbImNyaXRlcmlhLmluaXRpYWwtc3RhdGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IjtBQUFBLHlDQUFpQztBQUlwQixRQUFBLHNCQUFzQixHQUFHLGdCQUFJLEVBQWEsQ0FBQyJ9
\ No newline at end of file
"use strict";
const criteria_initial_state_1 = require("./criteria.initial-state");
const immutable_1 = require("immutable");
const constants_1 = require("../../constants");
function criteriaReducer(state = criteria_initial_state_1.CRITERIA_INITIAL_STATE, action) {
switch (action.type) {
case constants_1.CRITERIA_RECEIVED:
let newCriter = Array();
let i = 0;
action.payload.criteria.forEach(criteria => {
newCriter.push({ id: criteria.id, name: criteria.name, mutual_disabled_id: criteria.mutual_disabled_id, selected: false });
i++;
});
return immutable_1.Seq(newCriter).map(n => n).toList();
case constants_1.CRITERIA_SAVE:
let criter = Array();
let ind = 0;
state.forEach(criteria => {
criter.push({ id: criteria.id, name: criteria.name, mutual_disabled_id: criteria.mutual_disabled_id, selected: action.payload.criter[0][ind] });
ind++;
});
return immutable_1.Seq(criter).map(n => n).toList();
default: return state;
}
}
exports.criteriaReducer = criteriaReducer;
;
/*
case COURSEFIELDS_SELECTED_SAVE:
let selectedCourseFields = Array<ICourseField>();
let ind=0;
state.forEach(courseField => {
selectedCourseFields.push(<ICourseField>{id: courseField.id, name: courseField.name, selected: action.payload.courseFieldsSelected[ind]});
ind++;
});
return Seq(selectedCourseFields).map(n => n).toList();
default: return state;
*/
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY3JpdGVyaWEucmVkdWNlci5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbImNyaXRlcmlhLnJlZHVjZXIudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IjtBQUNBLHFFQUFrRTtBQUNsRSx5Q0FBZ0M7QUFFaEMsK0NBR3lCO0FBRXpCLHlCQUFnQyxRQUFpQiwrQ0FBc0IsRUFBRSxNQUFNO0lBQzdFLE1BQU0sQ0FBQyxDQUFDLE1BQU0sQ0FBQyxJQUFJLENBQUMsQ0FBQyxDQUFDO1FBQ3BCLEtBQUssNkJBQWlCO1lBQ2xCLElBQUksU0FBUyxHQUFHLEtBQUssRUFB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R0FBRyxDQUFDLENBQUMsSUFBSSxDQUFDLENBQUMsQ0FBQyxNQUFNLEVBQUUsQ0FBQztRQUM1QyxTQUFTLE1BQU0sQ0FBQyxLQUFLLENBQUM7SUFDeEIsQ0FBQztBQUNILENBQUM7QUF0QkQsMENBc0JDO0FBQUEsQ0FBQztBQUNGOzs7Ozs7Ozs7O0VBVUUifQ==
\ No newline at end of file
"use strict";
function deimmutifyCriteria(state) {
let fetchedCriteria = new Array();
state.forEach(criteria => {
fetchedCriteria.push({ id: criteria.id, name: criteria.name, mutual_disabled_id: criteria.mutual_disabled_id, selected: criteria.selected,
});
});
return fetchedCriteria;
}
exports.deimmutifyCriteria = deimmutifyCriteria;
;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY3JpdGVyaWEudHJhbnNmb3JtZXJzLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiY3JpdGVyaWEudHJhbnNmb3JtZXJzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7QUFFQSw0QkFBbUMsS0FBYztJQUM3QyxJQUFJLGVBQWUsR0FBRyxJQUFJLEtBQUssRUFBRSxDQUFDO0lBRWxDLEtBQUssQ0FBQyxPQUFPLENBQUMsUUFBUTtRQUNsQixlQUFlLENBQUMsSUFBSSxDQUFZLEVBQUMsRUFBRSxFQUFFLFFBQVEsQ0FBQyxFQUFFLEVBQUUsSUFBSSxFQUFFLFFBQVEsQ0FBQyxJQUFJLEVBQUcsa0JBQWtCLEVBQUUsUUFBUSxDQUFDLGtCQUFrQixFQUFFLFFBQVEsRUFBRSxRQUFRLENBQUMsUUFBUTtTQUNuSixDQUFDLENBQUM7SUFDUCxDQUFDLENBQUMsQ0FBQztJQUNILE1BQU0sQ0FBQyxlQUFlLENBQUM7QUFDM0IsQ0FBQztBQVJELGdEQVFDO0FBQUEsQ0FBQyJ9
\ No newline at end of file
"use strict";
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY3JpdGVyaWEudHlwZXMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJjcml0ZXJpYS50eXBlcy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiIn0=
\ No newline at end of file
"use strict";
const criteria_reducer_1 = require("./criteria.reducer");
exports.criteriaReducer = criteria_reducer_1.criteriaReducer;
const criteria_transformers_1 = require("./criteria.transformers");
exports.deimmutifyCriteria = criteria_transformers_1.deimmutifyCriteria;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJpbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBQ0EseURBQXFEO0FBTW5ELDZEQUFlO0FBTGpCLG1FQUE2RDtBQU0zRCx3RUFBa0IifQ==
\ No newline at end of file
"use strict";
const immutable_1 = require("immutable");
exports.EPALCLASSES_INITIAL_STATE = immutable_1.List();
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZXBhbGNsYXNzZXMuaW5pdGlhbC1zdGF0ZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbImVwYWxjbGFzc2VzLmluaXRpYWwtc3RhdGUudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IjtBQUFBLHlDQUFpQztBQUlwQixRQUFBLHlCQUF5QixHQUFHLGdCQUFJLEVBQWMsQ0FBQyJ9
\ No newline at end of file
"use strict";
const epalclasses_initial_state_1 = require("./epalclasses.initial-state");
const immutable_1 = require("immutable");
const constants_1 = require("../../constants");
function epalclassesReducer(state = epalclasses_initial_state_1.EPALCLASSES_INITIAL_STATE, action) {
switch (action.type) {
case constants_1.EPALCLASSES_SAVE:
let selectedEpalClasses = Array();
selectedEpalClasses.push({ name: action.payload.epalClasses.name });
return immutable_1.Seq(selectedEpalClasses).map(n => n).toList();
default: return state;
}
}
exports.epalclassesReducer = epalclassesReducer;
;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZXBhbGNsYXNzZXMucmVkdWNlci5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbImVwYWxjbGFzc2VzLnJlZHVjZXIudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IjtBQUNBLDJFQUF3RTtBQUN4RSx5Q0FBZ0M7QUFFaEMsK0NBQW1EO0FBRW5ELDRCQUFtQyxRQUFzQixxREFBeUIsRUFBRSxNQUFNO0lBR3hGLE1BQU0sQ0FBQyxDQUFDLE1BQU0sQ0FBQyxJQUFJLENBQUMsQ0FBQyxDQUFDO1FBR3BCLEtBQUssNEJBQWdCO1lBQ2pCLElBQUksbUJBQW1CLEdBQUcsS0FBSyxFQUFjLENBQUM7WUFFOUMsbUJBQW1CLENBQUMsSUFBSSxDQUFhLEVBQUUsSUFBSSxFQUFFLE1BQU0sQ0FBQyxPQUFPLENBQUMsV0FBVyxDQUFDLElBQUksRUFBQyxDQUFDLENBQUM7WUFHL0UsTUFBTSxDQUFDLGVBQUcsQ0FBQyxtQkFBbUIsQ0FBQyxDQUFDLEdBQUcsQ0FBQyxDQUFDLElBQUksQ0FBQyxDQUFDLENBQUMsTUFBTSxFQUFFLENBQUM7UUFDekQsU0FBUyxNQUFNLENBQUMsS0FBSyxDQUFDO0lBQ3hCLENBQUM7QUFDSCxDQUFDO0FBZkQsZ0RBZUM7QUFBQSxDQUFDIn0=
\ No newline at end of file
"use strict";
function deimmutifyEpalClasses(state) {
let fetchedEpalClasses = new Array();
state.forEach(epalclass => {
fetchedEpalClasses.push({ name: epalclass.name });
});
return fetchedEpalClasses;
}
exports.deimmutifyEpalClasses = deimmutifyEpalClasses;
;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZXBhbGNsYXNzZXMudHJhbnNmb3JtZXJzLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiZXBhbGNsYXNzZXMudHJhbnNmb3JtZXJzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7QUFFQSwrQkFBc0MsS0FBbUI7SUFDckQsSUFBSSxrQkFBa0IsR0FBRyxJQUFJLEtBQUssRUFBRSxDQUFDO0lBQ3JDLEtBQUssQ0FBQyxPQUFPLENBQUMsU0FBUztRQUNuQixrQkFBa0IsQ0FBQyxJQUFJLENBQWEsRUFBQyxJQUFJLEVBQUUsU0FBUyxDQUFDLElBQUksRUFBQyxDQUFDLENBQUM7SUFDaEUsQ0FBQyxDQUFDLENBQUM7SUFDSCxNQUFNLENBQUMsa0JBQWtCLENBQUM7QUFDOUIsQ0FBQztBQU5ELHNEQU1DO0FBQUEsQ0FBQyJ9
\ No newline at end of file
"use strict";
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZXBhbGNsYXNzZXMudHlwZXMuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJlcGFsY2xhc3Nlcy50eXBlcy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiIn0=
\ No newline at end of file
"use strict";
const epalclasses_reducer_1 = require("./epalclasses.reducer");
exports.epalclassesReducer = epalclasses_reducer_1.epalclassesReducer;
const epalclasses_transformers_1 = require("./epalclasses.transformers");
exports.deimmutifyEpalClasses = epalclasses_transformers_1.deimmutifyEpalClasses;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJpbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBQ0EsK0RBQTJEO0FBTXpELHNFQUFrQjtBQUxwQix5RUFBbUU7QUFNakUsaUZBQXFCIn0=
\ No newline at end of file
"use strict";
// import * as persistState from 'redux-localstorage';
const createLogger = require("redux-logger");
const store_1 = require("./store");
exports.rootReducer = store_1.rootReducer;
exports.middleware = [
createLogger({
level: 'info',
collapsed: true,
stateTransformer: store_1.deimmutify
})
];
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJpbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBQUEsc0RBQXNEO0FBQ3RELDZDQUE2QztBQUM3QyxtQ0FBNkQ7QUFZM0QsMENBQVc7QUFvQkEsUUFBQSxVQUFVLEdBQUc7SUFDeEIsWUFBWSxDQUFDO1FBQ1gsS0FBSyxFQUFFLE1BQU07UUFDYixTQUFTLEVBQUUsSUFBSTtRQUNmLGdCQUFnQixFQUFFLGtCQUFVO0tBQzdCLENBQUM7Q0FDSCxDQUFDIn0=
\ No newline at end of file
"use strict";
const logininfo_reducer_1 = require("./logininfo.reducer");
exports.loginInfoReducer = logininfo_reducer_1.loginInfoReducer;
const logininfo_transformers_1 = require("./logininfo.transformers");
exports.deimmutifyLoginInfo = logininfo_transformers_1.deimmutifyLoginInfo;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJpbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBQ0EsMkRBQXVEO0FBTXJELGdFQUFnQjtBQUxsQixxRUFBK0Q7QUFNN0QsMkVBQW1CIn0=
\ No newline at end of file
"use strict";
const immutable_1 = require("immutable");
// export const INITIAL_STATE = List<ICourseField>([new CourseFieldRecord({})]);
exports.LOGININFO_INITIAL_STATE = immutable_1.List();
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibG9naW5pbmZvLmluaXRpYWwtc3RhdGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJsb2dpbmluZm8uaW5pdGlhbC1zdGF0ZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBQUEseUNBQWlDO0FBR2pDLGdGQUFnRjtBQUNuRSxRQUFBLHVCQUF1QixHQUFHLGdCQUFJLEVBQW1CLENBQUMifQ==
\ No newline at end of file
"use strict";
const logininfo_initial_state_1 = require("./logininfo.initial-state");
const immutable_1 = require("immutable");
const constants_1 = require("../../constants");
function loginInfoReducer(state = logininfo_initial_state_1.LOGININFO_INITIAL_STATE, action) {
switch (action.type) {
case constants_1.LOGININFO_SAVE:
let loginInfoTokens = Array();
let i = 0;
action.payload.loginInfos.forEach(loginInfo => {
loginInfoTokens.push({ auth_token: loginInfo.auth_token, auth_role: loginInfo.auth_role, cu_name: loginInfo.cu_name });
i++;
});
return immutable_1.Seq(loginInfoTokens).map(n => n).toList();
case constants_1.LOGININFO_INIT:
return logininfo_initial_state_1.LOGININFO_INITIAL_STATE;
default:
return state;
}
}
exports.loginInfoReducer = loginInfoReducer;
;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibG9naW5pbmZvLnJlZHVjZXIuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJsb2dpbmluZm8ucmVkdWNlci50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBQ0EsdUVBQW9FO0FBQ3BFLHlDQUFnQztBQUVoQywrQ0FHeUI7QUFFekIsMEJBQWlDLFFBQW9CLGlEQUF1QixFQUFFLE1BQU07SUFDbEYsTUFBTSxDQUFDLENBQUMsTUFBTSxDQUFDLElBQUksQ0FBQyxDQUFDLENBQUM7UUFDcEIsS0FBSywwQkFBYztZQUNyQixJQUFJLGVBQWUsR0FBRyxLQUFLLEVBQW1CLENBQUM7WUFDekMsSUFBSSxDQUFDLEdBQUMsQ0FBQyxDQUFDO1lBQ1IsTUFBTSxDQUFDLE9BQU8sQ0FBQyxVQUFVLENBQUMsT0FBTyxDQUFDLFNBQVM7Z0JBQ3ZDLGVBQWUsQ0FBQyxJQUFJLENBQWtCLEVBQUMsVUFBVSxFQUFFLFNBQVMsQ0FBQyxVQUFVLEVBQUUsU0FBUyxFQUFFLFNBQVMsQ0FBQyxTQUFTLEVBQUUsT0FBTyxFQUFFLFNBQVMsQ0FBQyxPQUFPLEVBQUMsQ0FBQyxDQUFDO2dCQUN0SSxDQUFDLEVBQUUsQ0FBQztZQUNSLENBQUMsQ0FBQyxDQUFDO1lBQ0gsTUFBTSxDQUFDLGVBQUcsQ0FBQyxlQUFlLENBQUMsQ0FBQyxHQUFHLENBQUMsQ0FBQyxJQUFJLENBQUMsQ0FBQyxDQUFDLE1BQU0sRUFBRSxDQUFDO1FBRXJELEtBQUssMEJBQWM7WUFDZixNQUFNLENBQUMsaURBQXVCLENBQUM7UUFDbkM7WUFDSSxNQUFNLENBQUMsS0FBSyxDQUFDO0lBQ25CLENBQUM7QUFDSCxDQUFDO0FBaEJELDRDQWdCQztBQUFBLENBQUMifQ==
\ No newline at end of file
"use strict";
function deimmutifyLoginInfo(state) {
let fetchedLoginInfoTokens = new Array();
state.forEach(loginInfoToken => {
fetchedLoginInfoTokens.push({ auth_token: loginInfoToken.auth_token, auth_role: loginInfoToken.auth_role, cu_name: loginInfoToken.cu_name });
});
return fetchedLoginInfoTokens;
}
exports.deimmutifyLoginInfo = deimmutifyLoginInfo;
;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibG9naW5pbmZvLnRyYW5zZm9ybWVycy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbImxvZ2luaW5mby50cmFuc2Zvcm1lcnMudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IjtBQUVBLDZCQUFvQyxLQUFpQjtJQUNqRCxJQUFJLHNCQUFzQixHQUFHLElBQUksS0FBSyxFQUFFLENBQUM7SUFDekMsS0FBSyxDQUFDLE9BQU8sQ0FBQyxjQUFjO1FBQ3hCLHNCQUFzQixDQUFDLElBQUksQ0FBa0IsRUFBQyxVQUFVLEVBQUUsY0FBYyxDQUFDLFVBQVUsRUFBRSxTQUFTLEVBQUUsY0FBYyxDQUFDLFNBQVMsRUFBRSxPQUFPLEVBQUUsY0FBYyxDQUFDLE9BQU8sRUFBQyxDQUFDLENBQUM7SUFDaEssQ0FBQyxDQUFDLENBQUM7SUFDSCxNQUFNLENBQUMsc0JBQXNCLENBQUM7QUFDbEMsQ0FBQztBQU5ELGtEQU1DO0FBQUEsQ0FBQyJ9
\ No newline at end of file
"use strict";
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibG9naW5pbmZvLnR5cGVzLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsibG9naW5pbmZvLnR5cGVzLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiIifQ==
\ No newline at end of file
"use strict";
const regionschools_reducer_1 = require("./regionschools.reducer");
exports.regionSchoolsReducer = regionschools_reducer_1.regionSchoolsReducer;
const regionschools_transformers_1 = require("./regionschools.transformers");
exports.deimmutifyRegionSchools = regionschools_transformers_1.deimmutifyRegionSchools;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyJpbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBQ0EsbUVBQStEO0FBTzdELDRFQUFvQjtBQU50Qiw2RUFBdUU7QUFPckUsdUZBQXVCIn0=
\ No newline at end of file
"use strict";
const immutable_1 = require("immutable");
// export const INITIAL_STATE = List<ICourseField>([new CourseFieldRecord({})]);
exports.REGION_SCHOOLS_INITIAL_STATE = immutable_1.List();
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmVnaW9uc2Nob29scy5pbml0aWFsLXN0YXRlLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsicmVnaW9uc2Nob29scy5pbml0aWFsLXN0YXRlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7QUFBQSx5Q0FBaUM7QUFHakMsZ0ZBQWdGO0FBQ25FLFFBQUEsNEJBQTRCLEdBQUcsZ0JBQUksRUFBVyxDQUFDIn0=
\ No newline at end of file