implemented a new structure for regions and schools using TypedRecord

parent f3f705c5
......@@ -12,7 +12,7 @@ export class RegionSchoolsActions {
getRegionSchools = (classActive,courseActive, reload) => {
const { regions } = this._ngRedux.getState();
if (reload === true || (reload === false && regions.size === 0)) {
if (reload === true || (reload === false && (regions.length === 0 || regions[0].get("region_id") === null))) {
return this._hds.getRegionsWithSchools(classActive,courseActive).then(regions => {
return this._ngRedux.dispatch({
type: REGIONSCHOOLS_RECEIVED,
......
......@@ -10,7 +10,7 @@ import { RegionSchoolsActions } from '../../actions/regionschools.actions';
import { EpalClassesActions } from '../../actions/epalclass.actions';
import { ISectorFields } from '../../store/sectorfields/sectorfields.types';
import { ISectors } from '../../store/sectorcourses/sectorcourses.types';
import { IRegions, IRegionSchool } from '../../store/regionschools/regionschools.types';
import { IRegionRecord, IRegionSchoolRecord } from '../../store/regionschools/regionschools.types';
import { IEpalClasses } from '../../store/epalclasses/epalclasses.types';
import {AppSettings} from '../../app.settings';
import { REGION_SCHOOLS_INITIAL_STATE } from '../../store/regionschools/regionschools.initial-state';
......@@ -80,8 +80,8 @@ import { SECTOR_FIELDS_INITIAL_STATE } from '../../store/sectorfields/sectorfiel
@Injectable() export default class ApplicationPreview implements OnInit {
private sectors$: BehaviorSubject<ISectors>;
private regions$: BehaviorSubject<IRegions>;
private selectedSchools$: BehaviorSubject<Array<IRegionSchool>> = new BehaviorSubject(Array());
private regions$: BehaviorSubject<Array<IRegionRecord>>;
private selectedSchools$: BehaviorSubject<Array<IRegionSchoolRecord>> = new BehaviorSubject(Array());
private sectorFields$: BehaviorSubject<ISectorFields>;
private epalclasses$: BehaviorSubject<IEpalClasses>;
private sectorsSub: Subscription;
......@@ -123,12 +123,10 @@ import { SECTOR_FIELDS_INITIAL_STATE } from '../../store/sectorfields/sectorfiel
this.regionsSub = this._ngRedux.select(state => {
let numsel = 0, numsel2 = 0;
let selectedSchools = Array<IRegionSchool>();
if (state.regions.size === 0)
let selectedSchools = Array<IRegionSchoolRecord>();
if (state.regions.length === 0 || state.regions[0].get("region_id") === null)
return;
console.log(state.regions);
state.regions.reduce((prevRegion, region) => {
console.log(region);
region.get("epals").reduce((prevEpal, epal) => {
if (epal.get("selected") === true) {
numsel++;
......@@ -172,7 +170,7 @@ import { SECTOR_FIELDS_INITIAL_STATE } from '../../store/sectorfields/sectorfiel
}
compareSchools(a: IRegionSchool,b: IRegionSchool) {
compareSchools(a: IRegionSchoolRecord,b: IRegionSchoolRecord) {
if (a.order_id < b.order_id)
return -1;
if (a.order_id > b.order_id)
......
......@@ -6,7 +6,7 @@ import { Injectable } from "@angular/core";
import { NgRedux, select } from "ng2-redux";
import { IAppState } from "../../store/store";
import { IStudentDataFields } from "../../store/studentdatafields/studentdatafields.types";
import { IRegions } from "../../store/regionschools/regionschools.types";
import { IRegionRecord, IRegionSchoolRecord } from "../../store/regionschools/regionschools.types";
import { ISectors } from "../../store/sectorcourses/sectorcourses.types";
import { ISectorFields } from "../../store/sectorfields/sectorfields.types";
import { IEpalClasses } from "../../store/epalclasses/epalclasses.types";
......@@ -106,7 +106,7 @@ import { HelperDataService } from "../../services/helper-data-service";
</button>
</div>
<div class="col-md-6">
<button type="button" *ngIf="(studentDataFields$ | async).size > 0 && (regions$ | async).size > 0 && (epalclasses$ | async).size > 0 && (loginInfo$ | async).size > 0" class="btn-primary btn-lg pull-right isclickable" style="width: 9em;" (click)="submitNow()">
<button type="button" *ngIf="(studentDataFields$ | async).size > 0 && (regions$ | async) && (regions$ | async).length > 0 && (regions$ | async)[0].region_id !== null && (epalclasses$ | async).size > 0 && (loginInfo$ | async).size > 0" class="btn-primary btn-lg pull-right isclickable" style="width: 9em;" (click)="submitNow()">
<span style="font-size: 0.9em; font-weight: bold;">Υποβολή&nbsp;&nbsp;&nbsp;</span><i class="fa fa-forward"></i>
</button>
</div>
......@@ -124,7 +124,7 @@ import { HelperDataService } from "../../services/helper-data-service";
private classSelected;
private totalPoints = <number>0;
private studentDataFields$: BehaviorSubject<IStudentDataFields>;
private regions$: BehaviorSubject<IRegions>;
private regions$: BehaviorSubject<Array<IRegionRecord>>;
private sectors$: BehaviorSubject<ISectors>;
private sectorFields$: BehaviorSubject<ISectorFields>;
private epalclasses$: BehaviorSubject<IEpalClasses>;
......
......@@ -4,7 +4,7 @@ import { BehaviorSubject, Subscription } from 'rxjs/Rx';
import { Injectable } from "@angular/core";
import { RegionSchoolsActions } from '../../actions/regionschools.actions';
import { NgRedux, select } from 'ng2-redux';
import { IRegions } from '../../store/regionschools/regionschools.types';
import { IRegionRecord } from '../../store/regionschools/regionschools.types';
import { REGION_SCHOOLS_INITIAL_STATE } from '../../store/regionschools/regionschools.initial-state';
import { EPALCLASSES_INITIAL_STATE } from '../../store/epalclasses/epalclasses.initial-state';
import { SECTOR_COURSES_INITIAL_STATE } from '../../store/sectorcourses/sectorcourses.initial-state';
......@@ -32,7 +32,7 @@ import {AppSettings} from '../../app.settings';
<breadcrumbs></breadcrumbs>
</div>
<div class = "loading" *ngIf="!(regions$ | async)">
<div class = "loading" *ngIf="!(regions$ | async) || (regions$ | async)[0].region_id===null">
</div>
<!-- <div class="row equal">
<div class="col-md-12"> -->
......@@ -115,7 +115,7 @@ import {AppSettings} from '../../app.settings';
})
@Injectable() export default class RegionSchoolsSelect implements OnInit, OnDestroy {
private epalclasses$: BehaviorSubject<IEpalClasses>;
private regions$: BehaviorSubject<IRegions>;
private regions$: BehaviorSubject<IRegionRecord[]>;
private sectors$: BehaviorSubject<ISectors>;
private sectorFields$: BehaviorSubject<ISectorFields>;
private epalclassesSub: Subscription;
......@@ -234,11 +234,7 @@ import {AppSettings} from '../../app.settings';
let numreg = 0; //count reduced regions in order to set activeRegion when user comes back to his choices
this.selectionLimitOptional.next(false);
console.log("numsel="+numsel);
console.log(state.regions);
console.log(state.regions.size);
console.log(this.regions$.getValue());
if (state.regions.size === 0)
if (state.regions.length === 0 || state.regions[0].get("region_id") === null)
return;
state.regions.reduce((prevRegion, region) =>{
......@@ -247,7 +243,6 @@ import {AppSettings} from '../../app.settings';
this.rss.push( new FormControl(epal.get("selected"), []));
if (epal.get("selected") === true) {
numsel++;
console.log("numsel2="+numsel);
if ( epal.get("epal_special_case") === "1") {
this.selectionLimitOptional.next(true);
}
......@@ -264,7 +259,6 @@ import {AppSettings} from '../../app.settings';
return region;
}, {});
console.log("numsel3="+numsel);
this.numSelected.next(numsel);
return state.regions;
}).subscribe(this.regions$);
......
......@@ -4,7 +4,7 @@ import { BehaviorSubject, Subscription } from 'rxjs/Rx';
import { Injectable } from "@angular/core";
import { NgRedux, select } from 'ng2-redux';
import { RegionSchoolsActions } from '../../actions/regionschools.actions';
import { IRegions, IRegionSchool } from '../../store/regionschools/regionschools.types';
import { IRegionRecord, IRegionSchoolRecord } from '../../store/regionschools/regionschools.types';
import { REGION_SCHOOLS_INITIAL_STATE } from '../../store/regionschools/regionschools.initial-state';
import { IAppState } from '../../store/store';
import {AppSettings} from '../../app.settings';
......@@ -15,8 +15,9 @@ import {AppSettings} from '../../app.settings';
<div class="row">
<breadcrumbs></breadcrumbs>
</div>
<div class = "loading" *ngIf="(selectedSchools$ | async).length === 0 || (regions$ | async).size === 0">
<div class = "loading" *ngIf="(selectedSchools$ | async).length === 0 || !(regions$ | async) || ((regions$ | async).length === 1 && (regions$ | async)[0].region_id === null)">
</div>
<h4> Σειρά προτίμησης</h4>
<p style="margin-top: 20px; line-height: 2em;" *ngIf = "(selectedSchools$ | async).length === 1" >Έχετε επιλέξει το παρακάτω σχολείο. Εάν συμφωνείτε με την επιλογή σας
πατήστε Συνέχεια, διαφορετικά μπορείτε να τροποποιήστε τις επιλογές σας επιστρέφοντας στην προηγούμενη οθόνη από το αριστερό βέλος κάτω αριστερά.</p>
......@@ -50,9 +51,9 @@ import {AppSettings} from '../../app.settings';
})
@Injectable() export default class SchoolsOrderSelect implements OnInit, OnDestroy {
// public formGroup: FormGroup;
private regions$: BehaviorSubject<IRegions>;
private regions$: BehaviorSubject<Array<IRegionRecord>>;
private regionsSub: Subscription;
private selectedSchools$: BehaviorSubject<Array<IRegionSchool>> = new BehaviorSubject(Array());
private selectedSchools$: BehaviorSubject<Array<IRegionSchoolRecord>> = new BehaviorSubject(Array());
constructor(private _cfa: RegionSchoolsActions,
private _ngRedux: NgRedux<IAppState>,
......@@ -62,12 +63,12 @@ import {AppSettings} from '../../app.settings';
ngOnInit() {
this.regionsSub = this._ngRedux.select(state => {
let selectedSchools = Array<IRegionSchool>();
let selectedSchools = Array<IRegionSchoolRecord>();
state.regions.reduce((prevRegion, region) => {
region.epals.reduce((prevEpal, epal) => {
if (epal.selected === true) {
selectedSchools.push(epal);
region.get("epals").reduce((prevEpal, epal) => {
if (epal.get("selected") === true) {
selectedSchools.push(epal.toJS());
}
return epal;
......@@ -97,7 +98,7 @@ import {AppSettings} from '../../app.settings';
if (this.regions$) this.regions$.unsubscribe();
}
compareSchools(a: IRegionSchool, b: IRegionSchool) {
compareSchools(a: IRegionSchoolRecord, b: IRegionSchoolRecord) {
if (a.order_id < b.order_id)
return -1;
if (a.order_id > b.order_id)
......@@ -106,7 +107,7 @@ import {AppSettings} from '../../app.settings';
}
changeOrder(i) {
let selectedSchools = Array<IRegionSchool>();
let selectedSchools = Array<IRegionSchoolRecord>();
selectedSchools = this.selectedSchools$.getValue();
if (i === 1) {
......
......@@ -4,7 +4,7 @@ import { BehaviorSubject } from "rxjs/Rx";
import "rxjs/add/operator/map";
import { ICourseField } from "../store/coursefields/coursefields.types";
import { ISectorField } from "../store/sectorfields/sectorfields.types";
import { IRegion, IRegions, IRegionSchool } from "../store/regionschools/regionschools.types";
import { IRegionRecord, IRegionSchoolRecord, IRRegion, IRRegionSchool } from "../store/regionschools/regionschools.types";
import { ISector, ISectors, ISectorCourse } from "../store/sectorcourses/sectorcourses.types";
import { AppSettings } from "../app.settings";
import { NgRedux, select } from "ng2-redux";
......@@ -278,7 +278,7 @@ export class HelperDataService implements OnInit, OnDestroy {
};
transformRegionSchoolsSchema(regionSchools: any) {
let rsa = Array<IRegion>();
let rsa = Array<IRRegion>();
let trackRegionId: string;
let trackIndex: number;
......@@ -289,10 +289,10 @@ export class HelperDataService implements OnInit, OnDestroy {
regionSchools.forEach(regionSchool => {
if (trackRegionId !== regionSchool.region_id) {
trackIndex++;
rsa.push(<IRegion>{ "region_id": regionSchool.region_id, "region_name": regionSchool.region_name, "epals": Array<IRegionSchool>() });
rsa.push(<IRRegion>{ "region_id": regionSchool.region_id, "region_name": regionSchool.region_name, "epals": Array<IRRegionSchool>() });
trackRegionId = regionSchool.region_id;
}
rsa[trackIndex].epals.push(<IRegionSchool>{ "epal_id": regionSchool.epal_id, "epal_name": regionSchool.epal_name, "epal_special_case": regionSchool.epal_special_case, "globalIndex": j, "selected": false, "order_id": 0 });
rsa[trackIndex].epals.push(<IRRegionSchool>{ "epal_id": regionSchool.epal_id, "epal_name": regionSchool.epal_name, "epal_special_case": regionSchool.epal_special_case, "globalIndex": j, "selected": false, "order_id": 0 });
j++;
});
return rsa;
......@@ -1057,5 +1057,3 @@ deleteApplicationforDirector(appId) {
}
......@@ -3,7 +3,7 @@ import * as createLogger from 'redux-logger';
import { IAppState, rootReducer, deimmutify } from './store';
import { ICourseField, ICourseFields } from './coursefields/coursefields.types';
import { ISectorField, ISectorFields } from './sectorfields/sectorfields.types';
import { IRegions, IRegion, RegionSchool } from './regionschools/regionschools.types';
import { IRRegion, IRRegionSchool, IRegionRecord, IRegionSchoolRecord } from './regionschools/regionschools.types';
import { ISectors, ISector, ISectorCourse } from './sectorcourses/sectorcourses.types';
import { IStudentDataField, IStudentDataFields } from './studentdatafields/studentdatafields.types';
import { IEpalClass, IEpalClasses } from './epalclasses/epalclasses.types';
......@@ -17,9 +17,10 @@ export {
ICourseFields,
ISectorField,
ISectorFields,
IRegions,
IRegion,
RegionSchool,
IRRegion,
IRegionRecord,
IRegionSchoolRecord,
IRRegionSchool,
ISectors,
ISector,
ISectorCourse,
......
import { IRegions, IRegion, IRegionM, RegionSchool } from './regionschools.types';
import { IRegionRecord, IRRegion, IRRegionSchool, IRegionSchoolRecord } from './regionschools.types';
import { regionSchoolsReducer } from './regionschools.reducer';
import { deimmutifyRegionSchools } from './regionschools.transformers';
export {
IRegion,
IRegionM,
IRegions,
RegionSchool,
IRRegion,
IRegionRecord,
IRegionSchoolRecord,
IRRegionSchool,
regionSchoolsReducer,
deimmutifyRegionSchools,
};
import { List } from 'immutable';
import { IRegion, IRegionM } from './regionschools.types';
import { IRegion, IRegionM, IRegionRecord, IRRegion, IRRegionSchool, IRegionSchoolRecord } from './regionschools.types';
import {recordify} from 'typed-immutable-record';
// export const INITIAL_STATE = List<ICourseField>([new CourseFieldRecord({})]);
export const REGION_SCHOOLS_INITIAL_STATE = List<IRegionM>();
// export const REGION_SCHOOLS_INITIAL_STATE = List<IRegionM>();
export const REGION_SCHOOLS_INITIAL_STATE = new Array(recordify<IRRegion, IRegionRecord>({region_id: null, region_name: null, epals: new Array(recordify<IRRegionSchool, IRegionSchoolRecord>({epal_id: null, epal_name: null, epal_special_case: null, globalIndex: -1, selected: false, order_id: -1 })) }));
import { IRegions, Region, IRegion, IRegionM, RegionSchool, IRegionSchools } from './regionschools.types';
import { IRegions, Region, IRegion, IRRegion, IRegionM, RegionSchool, IRRegionSchool, IRegionSchools, IRegionSchoolRecord, IRegionSchoolRecords, IRegionRecord } from './regionschools.types';
import { REGION_SCHOOLS_INITIAL_STATE } from './regionschools.initial-state';
import { Seq, Map, fromJS } from 'immutable';
import {recordify} from 'typed-immutable-record';
import {
REGIONSCHOOLS_RECEIVED,
......@@ -9,33 +10,58 @@ import {
REGIONSCHOOLS_INIT
} from '../../constants';
export function regionSchoolsReducer(state: IRegions = REGION_SCHOOLS_INITIAL_STATE, action): IRegions {
export function regionSchoolsReducer(state: IRegionRecord[] = REGION_SCHOOLS_INITIAL_STATE, action): IRegionRecord[] {
switch (action.type) {
case REGIONSCHOOLS_RECEIVED:
let newRegions = Array<Region>();
let i=0;
let newRegions = Array<IRegionRecord>();
let i=0, j=0;
let ii=0;
action.payload.regions.forEach(region => {
newRegions.push(<any>{region_id: region.region_id, region_name: region.region_name, epals: <any>[] });
region.epals.forEach(epal => {
newRegions[i].epals.push(<any>{epal_id: epal.epal_id, epal_name: epal.epal_name, epal_special_case: epal.epal_special_case, globalIndex: epal.globalIndex, selected: epal.selected, order_id: epal.order_id });
if (j !== i || (i === 0 && ii===0)) {
newRegions.push(recordify<IRRegion, IRegionRecord>({region_id: region.region_id, region_name: region.region_name, epals: new Array(recordify<IRRegionSchool, IRegionSchoolRecord>({epal_id: epal.epal_id, epal_name: epal.epal_name, epal_special_case: epal.epal_special_case, globalIndex: epal.globalIndex, selected: epal.selected, order_id: epal.order_id })) }));
j = i;
} else
newRegions[i].epals.push(recordify<IRRegionSchool, IRegionSchoolRecord>({epal_id: epal.epal_id, epal_name: epal.epal_name, epal_special_case: epal.epal_special_case, globalIndex: epal.globalIndex, selected: epal.selected, order_id: epal.order_id }));
ii++;
})
i++;
});
return fromJS(newRegions);
return newRegions;
case REGIONSCHOOLS_SELECTED_SAVE:
// let ind=0;
let region: IRegionM;
let epals: IRegionSchools;
region = state.get(action.payload.rIndex);
console.log(region);
let region: IRegionRecord;
region = state[action.payload.rIndex];
let newState = Array<IRegionRecord>();
i=0, j=0;
ii=0;
state.forEach(region => {
let epals: IRegionSchoolRecords;
epals = region.get("epals");
ii=0;
epals.forEach(epal => {
if (j !== i || (i === 0 && ii===0)) {
if (i===action.payload.rIndex && ii===action.payload.sIndex)
newState.push(recordify<IRRegion, IRegionRecord>({region_id: region.region_id, region_name: region.region_name, epals: new Array(recordify<IRRegionSchool, IRegionSchoolRecord>({epal_id: epal.epal_id, epal_name: epal.epal_name, epal_special_case: epal.epal_special_case, globalIndex: epal.globalIndex, selected: action.payload.checked, order_id: epal.order_id })) }));
else
newState.push(recordify<IRRegion, IRegionRecord>({region_id: region.region_id, region_name: region.region_name, epals: new Array(recordify<IRRegionSchool, IRegionSchoolRecord>({epal_id: epal.epal_id, epal_name: epal.epal_name, epal_special_case: epal.epal_special_case, globalIndex: epal.globalIndex, selected: epal.selected, order_id: epal.order_id })) }));
j = i;
} else {
if (i===action.payload.rIndex && ii===action.payload.sIndex)
newState[i].epals.push(recordify<IRRegionSchool, IRegionSchoolRecord>({epal_id: epal.epal_id, epal_name: epal.epal_name, epal_special_case: epal.epal_special_case, globalIndex: epal.globalIndex, selected: action.payload.checked, order_id: epal.order_id }));
else
newState[i].epals.push(recordify<IRRegionSchool, IRegionSchoolRecord>({epal_id: epal.epal_id, epal_name: epal.epal_name, epal_special_case: epal.epal_special_case, globalIndex: epal.globalIndex, selected: epal.selected, order_id: epal.order_id }));
}
ii++;
})
i++;
})
epals = region.get("epals").epals;
let epal = epals.get(action.payload.sIndex);
epal.set("selected", action.payload.checked);
region = region.set("epals", epals.set(action.payload.sIndex,
epal.set("selected", action.payload.checked)));
return state
.set(action.payload.rIndex, region);
return newState;
/* state.forEach(region => {
if (ind === action.payload.rIndex) {
......@@ -50,39 +76,37 @@ export function regionSchoolsReducer(state: IRegions = REGION_SCHOOLS_INITIAL_ST
// return state;
case REGIONSCHOOLS_ORDER_SAVE:
region = state[action.payload.rIndex];
let newState2 = Array<IRegionRecord>();
i=0, j=0;
let ind2=0;
state.forEach(region => {
for(let i=0; i<region.epals.length; i++){
if (region.epals[i].globalIndex === action.payload.selectedSchools[0].globalIndex) {
region.epals[i].order_id = action.payload.selectedSchools[0].order_id
return state.withMutations(function (list) {
list.set(ind2++, region);
});
let epals: IRegionSchoolRecords;
epals = region.get("epals");
epals.forEach(epal => {
let newOrderId = epal.order_id;
for (let jjj=0; jjj<3; jjj++) {
if (typeof action.payload.selectedSchools[jjj] !== 'undefined' &&
epal.globalIndex === action.payload.selectedSchools[jjj].globalIndex) {
newOrderId = action.payload.selectedSchools[jjj].order_id;
break;
}
}
if (typeof action.payload.selectedSchools[1] !== 'undefined' &&
region.epals[i].globalIndex === action.payload.selectedSchools[1].globalIndex) {
region.epals[i].order_id = action.payload.selectedSchools[1].order_id
return state.withMutations(function (list) {
list.set(ind2++, region);
});
if (j !== i || i === 0) {
newState2.push(recordify<IRRegion, IRegionRecord>({region_id: region.region_id, region_name: region.region_name, epals: new Array(recordify<IRRegionSchool, IRegionSchoolRecord>({epal_id: epal.epal_id, epal_name: epal.epal_name, epal_special_case: epal.epal_special_case, globalIndex: epal.globalIndex, selected: epal.selected, order_id: newOrderId })) }));
j = i;
} else {
newState2[i].epals.push(recordify<IRRegionSchool, IRegionSchoolRecord>({epal_id: epal.epal_id, epal_name: epal.epal_name, epal_special_case: epal.epal_special_case, globalIndex: epal.globalIndex, selected: epal.selected, order_id: newOrderId }));
}
if (typeof action.payload.selectedSchools[2] !== 'undefined' &&
region.epals[i].globalIndex === action.payload.selectedSchools[2].globalIndex) {
region.epals[i].order_id = action.payload.selectedSchools[2].order_id
return state.withMutations(function (list) {
list.set(ind2++, region);
});
}
//}
});
i++;
}
ind2++;
});
return state;
case REGIONSCHOOLS_INIT:
return REGION_SCHOOLS_INITIAL_STATE;
return newState2;
case REGIONSCHOOLS_INIT:
return REGION_SCHOOLS_INITIAL_STATE;
default: return state;
}
};
import { IRegions, IRegion } from './regionschools.types';
import { IRegionRecord } from './regionschools.types';
export function deimmutifyRegionSchools(state: IRegions): IRegions {
export function deimmutifyRegionSchools(state: IRegionRecord[]): IRegionRecord[] {
// let fetchedRegions = new Array<IRegion>();
// let i = 0;
......
import { List, Map } from 'immutable';
import {TypedRecord} from 'typed-immutable-record';
export interface IRRegion {
region_id: string;
region_name: string;
epals: IRRegionSchool[];
}
export interface IRRegionSchool {
epal_id: string;
epal_name: string;
epal_special_case: string;
globalIndex: number;
selected: boolean;
order_id: number;
}
export interface IRegionRecord extends TypedRecord<IRegionRecord>, IRRegion {};
export interface IRegionSchoolRecord extends TypedRecord<IRegionSchoolRecord>, IRRegionSchool {};
export type IRegionSchoolRecords = IRegionSchoolRecord[];
export interface Region {
......@@ -26,4 +46,4 @@ export type IRegions = List<IRegionM>;
// export type IRegionM = Map<IRegion>;
export type IRegionM = Map<string, IRegion>;
export type IRegionSchoolM = Map<string, RegionSchool>;
export type IRegionSchools = Map<string, List<IRegionSchoolM>>;
export type IRegionSchools = List<RegionSchool>;
......@@ -15,7 +15,7 @@ import * as criter from './criteria';
export interface IAppState {
courseFields?: courseFields.ICourseFields;
sectorFields?: sectorFields.ISectorFields;
regions?: regions.IRegions;
regions?: regions.IRegionRecord[];
sectors?: sectors.ISectors;
studentDataFields?: studentDataFields.IStudentDataFields;
epalclasses?: epalclasses.IEpalClasses;
......
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