diff --git a/backend/src/main/resources/application.properties b/backend/src/main/resources/application.properties
index 04e45e5..b7290b3 100644
--- a/backend/src/main/resources/application.properties
+++ b/backend/src/main/resources/application.properties
@@ -6,7 +6,7 @@ spring.h2.console.enabled=true
spring.datasource.url = jdbc:mysql://localhost/brems?verifyServerCertificate=false&useSSL=true
spring.datasource.username = root
-spring.datasource.password = 1234
+spring.datasource.password = root
spring.datasource.driverClassName = com.mysql.jdbc.Driver
spring.jpa.hibernate.ddl-auto = create-drop
diff --git a/backend/target/classes/META-INF/MANIFEST.MF b/backend/target/classes/META-INF/MANIFEST.MF
index 7e36d92..0043377 100644
--- a/backend/target/classes/META-INF/MANIFEST.MF
+++ b/backend/target/classes/META-INF/MANIFEST.MF
@@ -1,7 +1,7 @@
Manifest-Version: 1.0
Implementation-Title: appSpring
Implementation-Version: 0.0.1
-Built-By: c.vazquezlos
+Built-By: jherel
Implementation-Vendor-Id: es.urjc.daw
Build-Jdk: 1.8.0_121
Implementation-URL: http://projects.spring.io/spring-boot/appSpring/
diff --git a/backend/target/classes/application.properties b/backend/target/classes/application.properties
index 04e45e5..b7290b3 100644
--- a/backend/target/classes/application.properties
+++ b/backend/target/classes/application.properties
@@ -6,7 +6,7 @@ spring.h2.console.enabled=true
spring.datasource.url = jdbc:mysql://localhost/brems?verifyServerCertificate=false&useSSL=true
spring.datasource.username = root
-spring.datasource.password = 1234
+spring.datasource.password = root
spring.datasource.driverClassName = com.mysql.jdbc.Driver
spring.jpa.hibernate.ddl-auto = create-drop
diff --git a/frontend/src/app/component/admin/admin.module.ts b/frontend/src/app/component/admin/admin.module.ts
index 1b20954..2fa4ace 100644
--- a/frontend/src/app/component/admin/admin.module.ts
+++ b/frontend/src/app/component/admin/admin.module.ts
@@ -1,4 +1,5 @@
import { NgModule } from '@angular/core';
+import { FormsModule, ReactiveFormsModule } from '@angular/forms';
import { CommonModule } from '@angular/common';
import { AdminComponent } from './admin.component';
@@ -16,7 +17,9 @@ import { DashboardComponent } from './dashboard/dashboard.component';
@NgModule({
imports: [
CommonModule,
- AdminRoutingModule
+ AdminRoutingModule,
+ FormsModule,
+ ReactiveFormsModule
],
declarations: [
AdminComponent,
diff --git a/frontend/src/app/component/admin/manage-loans/manage-loans.component.html b/frontend/src/app/component/admin/manage-loans/manage-loans.component.html
index 46deacc..0064c1c 100644
--- a/frontend/src/app/component/admin/manage-loans/manage-loans.component.html
+++ b/frontend/src/app/component/admin/manage-loans/manage-loans.component.html
@@ -1,3 +1,45 @@
-
- manage-loans works!
-
+
+
+
+
+
+
+ Identificador |
+ Usuario |
+ Recurso |
+ Petición |
+ Préstamo |
+ Devolución |
+ Administrar |
+
+
+
+
+ |
+ |
+ |
+ |
+
+
+
+
+ |
+
+
+
+
+ |
+
+
+
+
+ |
+
+
+
+
+
+
+
diff --git a/frontend/src/app/component/admin/manage-loans/manage-loans.component.ts b/frontend/src/app/component/admin/manage-loans/manage-loans.component.ts
index 48a3c36..3a79347 100644
--- a/frontend/src/app/component/admin/manage-loans/manage-loans.component.ts
+++ b/frontend/src/app/component/admin/manage-loans/manage-loans.component.ts
@@ -1,15 +1,25 @@
import { Component, OnInit } from '@angular/core';
+import { ActionService } from 'app/service/action.service'
+
@Component({
- selector: 'app-manage-loans',
templateUrl: './manage-loans.component.html',
styleUrls: ['./manage-loans.component.css']
})
export class ManageLoansComponent implements OnInit {
- constructor() { }
+ private loans: Object[] = [];
- ngOnInit() {
+ constructor(private service: ActionService) {
}
+ ngOnInit() {
+ this.service.getAllActions().subscribe(
+ loans => {
+ this.loans = loans;
+ console.log(this.loans);
+ },
+ error => console.log(error)
+ );
+ }
}
diff --git a/frontend/src/app/component/admin/manage-resources/edit/edit.component.1.html b/frontend/src/app/component/admin/manage-resources/edit/edit.component.1.html
deleted file mode 100644
index 984e0f7..0000000
--- a/frontend/src/app/component/admin/manage-resources/edit/edit.component.1.html
+++ /dev/null
@@ -1,57 +0,0 @@
-
-
-
diff --git a/frontend/src/app/component/admin/manage-resources/edit/edit.component.html b/frontend/src/app/component/admin/manage-resources/edit/edit.component.html
index 14b689f..5f7038a 100644
--- a/frontend/src/app/component/admin/manage-resources/edit/edit.component.html
+++ b/frontend/src/app/component/admin/manage-resources/edit/edit.component.html
@@ -1,3 +1,59 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/frontend/src/app/component/admin/manage-resources/edit/edit.component.ts b/frontend/src/app/component/admin/manage-resources/edit/edit.component.ts
index e277af3..e4103c4 100644
--- a/frontend/src/app/component/admin/manage-resources/edit/edit.component.ts
+++ b/frontend/src/app/component/admin/manage-resources/edit/edit.component.ts
@@ -2,7 +2,6 @@ import { Component, OnInit } from '@angular/core';
import { Router, ActivatedRoute } from '@angular/router';
import { Resource } from 'app/model/resource.model';
-
import { ResourceService } from 'app/service/resource.service';
@Component({
@@ -14,21 +13,22 @@ export class EditResourceComponent implements OnInit {
private resource: Resource;
constructor(private router: Router,
- activatedRoute: ActivatedRoute, service: ResourceService) {
- let id = activatedRoute.snapshot.params['id'];
+ private activatedRoute: ActivatedRoute,
+ private service: ResourceService) {
+ }
- service.getResource(id).subscribe(
- resource => this.resource = resource,
- error => console.error(error)
+ ngOnInit() {
+ let id = this.activatedRoute.snapshot.params['id'];
+ this.service.getResource(id).subscribe(
+ resource => {
+ this.resource = resource;
+ },
+ error => console.log(error)
);
- console.log(this.resource);
}
- ngOnInit() { }
-
gotoResources() { this.router.navigate(['/resources']); }
saveResource() { }
-
}
diff --git a/frontend/src/app/component/admin/manage-resources/manage-resources.component.html b/frontend/src/app/component/admin/manage-resources/manage-resources.component.html
index a4c0c34..5d04ab7 100644
--- a/frontend/src/app/component/admin/manage-resources/manage-resources.component.html
+++ b/frontend/src/app/component/admin/manage-resources/manage-resources.component.html
@@ -26,7 +26,7 @@