update code to comply with updated entities

parent 97ffa32e
{"version":3,"sources":["webpack:///./source/components/lazy-load/lazy-load.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;AAAA,qCAA0C;AAC1C,qCAAyC;AACzC,wCAAuD;AAMvD,KAAM,sBAAsB;KAA5B;KAA8B,CAAC;KAAD,6BAAC;AAAD,EAAC;AAAzB,uBAAsB;KAH3B,gBAAS,CAAC;SACT,QAAQ,EAAE,oCAAoC;MAC/C,CAAC;;IACI,sBAAsB,CAAG;AAE/B,KAAM,MAAM,GAAW;KACrB,EAAE,IAAI,EAAE,OAAO,EAAE,SAAS,EAAE,sBAAsB,EAAE;EACrD,CAAC;AAMF,KAAa,gBAAgB;KAA7B;KAAgC,CAAC;KAAD,uBAAC;AAAD,EAAC;AAApB,iBAAgB;KAJ5B,eAAQ,CAAC;SACR,OAAO,EAAE,CAAG,qBAAY,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAE;SAC3C,YAAY,EAAE,CAAE,sBAAsB,CAAE;MACzC,CAAC;;IACW,gBAAgB,CAAI;AAApB,6CAAgB","file":"1.chunk.js","sourcesContent":["import { Component } from '@angular/core';\nimport { NgModule } from '@angular/core';\nimport { Routes, RouterModule } from '@angular/router';\n\n\n@Component({\n template: `<H1>Lazy Loaded Component One</H1>`\n})\nclass LazyLoadedComponentOne {}\n\nconst routes: Routes = [\n { path: 'lazy1', component: LazyLoadedComponentOne },\n];\n\n@NgModule({\n imports: [ RouterModule.forChild(routes) ],\n declarations: [ LazyLoadedComponentOne ]\n})\nexport class LazyLoadedModule { }\n\n\n\n// WEBPACK FOOTER //\n// ./~/angular2-router-loader/src!./~/tslint-loader!./source/components/lazy-load/lazy-load.ts"],"sourceRoot":""}
\ No newline at end of file
webpackJsonp([1],{ webpackJsonp([1],{
/***/ 471: /***/ 477:
/***/ function(module, exports, __webpack_require__) { /***/ function(module, exports, __webpack_require__) {
"use strict"; "use strict";
...@@ -48,4 +48,4 @@ webpackJsonp([1],{ ...@@ -48,4 +48,4 @@ webpackJsonp([1],{
/***/ } /***/ }
}); });
//# sourceMappingURL=1.5d424ee89dc353107fad.bundle.js.map //# sourceMappingURL=1.d2de929a692b8772d022.bundle.js.map
\ No newline at end of file \ No newline at end of file
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
...@@ -11,5 +11,5 @@ ...@@ -11,5 +11,5 @@
<div class="container-fluid"> <div class="container-fluid">
<kitchen-sink></kitchen-sink> <kitchen-sink></kitchen-sink>
</div> </div>
<script type="text/javascript" src="vendor.5d424ee89dc353107fad.bundle.js"></script><script type="text/javascript" src="app.5d424ee89dc353107fad.bundle.js"></script></body> <script type="text/javascript" src="/vendor.d2de929a692b8772d022.bundle.js"></script><script type="text/javascript" src="/app.d2de929a692b8772d022.bundle.js"></script></body>
</html> </html>
This diff is collapsed.
This diff is collapsed.
...@@ -58,7 +58,8 @@ export default class Form3 { ...@@ -58,7 +58,8 @@ export default class Form3 {
let options = new RequestOptions({ headers: headers, withCredentials: true }); let options = new RequestOptions({ headers: headers, withCredentials: true });
console.log(this.student); console.log(this.student);
this.http.post('http://eepal.dev/drupal/entity/student', this.student, options) // this.http.post('http://eepal.dev/drupal/entity/epal_student', this.student, options)
this.http.post('http://eduslim2.minedu.gov.gr/drupal/entity/epal_student', this.student, options)
// Call map on the response observable to get the parsed people object // Call map on the response observable to get the parsed people object
.map((res: Response) => res.json()) .map((res: Response) => res.json())
.subscribe(success => {alert("Η εγγραφή έγινε με επιτυχία"); console.log("success post")}, // put the data returned from the server in our variable .subscribe(success => {alert("Η εγγραφή έγινε με επιτυχία"); console.log("success post")}, // put the data returned from the server in our variable
......
...@@ -52,7 +52,8 @@ import { CourseField } from './coursefield'; ...@@ -52,7 +52,8 @@ import { CourseField } from './coursefield';
getCourseFields(http: Http) { getCourseFields(http: Http) {
this.http.get('http://eepal.dev/drupal/coursefields/list') // this.http.get('http://eepal.dev/drupal/coursefields/list')
this.http.get('http://eduslim2.minedu.gov.gr/drupal/coursefields/list')
// Call map on the response observable to get the parsed people object // Call map on the response observable to get the parsed people object
.map(response => <CourseField[]>response.json()) .map(response => <CourseField[]>response.json())
.subscribe(data => { .subscribe(data => {
......
...@@ -5,6 +5,6 @@ export class Student { ...@@ -5,6 +5,6 @@ export class Student {
public surname: string, public surname: string,
public address: string, public address: string,
public birthdate: string, public birthdate: string,
public studentclass_id:number public epalstudentclass_id:number
){} ){}
} }
...@@ -33,7 +33,7 @@ import 'rxjs/add/operator/toPromise'; ...@@ -33,7 +33,7 @@ import 'rxjs/add/operator/toPromise';
address: { address: {
title: 'Διεύθυνση' title: 'Διεύθυνση'
}, },
studentclass_id: { epalstudentclass_id: {
title: 'Τμήμα' title: 'Τμήμα'
} }
} }
...@@ -49,8 +49,8 @@ import 'rxjs/add/operator/toPromise'; ...@@ -49,8 +49,8 @@ import 'rxjs/add/operator/toPromise';
} }
getStudents(http: Http) { getStudents(http: Http) {
// this.http.get('http://eduslim2.minedu.gov.gr/drupal/students/list') // this.http.get('http://eduslim2.minedu.gov.gr/drupal/students/list')
this.data = new ServerDataSource(http, { endPoint: 'http://eepal.dev/drupal/students/list' }); // this.data = new ServerDataSource(http, { endPoint: 'http://eepal.dev/drupal/students/list' });
// this.data = new ServerDataSource(http, {endPoint: 'http://eduslim2.minedu.gov.gr/drupal/students/list'}); this.data = new ServerDataSource(http, {endPoint: 'http://eduslim2.minedu.gov.gr/drupal/students/list'});
/* this.http.get('http://eepal.dev/drupal/students/list') /* this.http.get('http://eepal.dev/drupal/students/list')
// Call map on the response observable to get the parsed people object // Call map on the response observable to get the parsed people object
.map(response => <Student[]>response.json()) .map(response => <Student[]>response.json())
......
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