From daa6dbe5516a1b94c4c6f397f54d9ab3bcb759a3 Mon Sep 17 00:00:00 2001
From: aotaduy
Date: Wed, 13 May 2020 15:57:37 -0300
Subject: [PATCH 1/3] Enunciado ejercicio
---
README.md | 45 +-
angular.json | 9 +-
package-lock.json | 10 +
package.json | 2 +
src/app/app.component.html | 535 +-------------------
src/app/app.module.ts | 8 +-
src/app/model/todo-item.ts | 9 +
src/app/todo-app/todo-app.component.html | 8 +
src/app/todo-app/todo-app.component.scss | 0
src/app/todo-app/todo-app.component.spec.ts | 25 +
src/app/todo-app/todo-app.component.ts | 20 +
11 files changed, 116 insertions(+), 555 deletions(-)
create mode 100644 src/app/model/todo-item.ts
create mode 100644 src/app/todo-app/todo-app.component.html
create mode 100644 src/app/todo-app/todo-app.component.scss
create mode 100644 src/app/todo-app/todo-app.component.spec.ts
create mode 100644 src/app/todo-app/todo-app.component.ts
diff --git a/README.md b/README.md
index e5c5427..9a4b344 100644
--- a/README.md
+++ b/README.md
@@ -1,27 +1,38 @@
-# NgPeti
+## Ejercicio
-This project was generated with [Angular CLI](https://github.com/angular/angular-cli) version 9.1.1.
+La idea es con los conceptos que ya tenemos de Angular, @Input, @Output y componentes
+Completar el presente repositorio para que la aplicacion funcione.
-## Development server
+## TodoList
-Run `ng serve` for a dev server. Navigate to `http://localhost:4200/`. The app will automatically reload if you change any of the source files.
+Tengo una lista de tareas.
-## Code scaffolding
++ Como usuario quiero poder agregar una tarea. Una tera consiste en un texto y en un estado que puede ser pendiente o completada.
++ Al agregarse la tarea esta siempre pendiente.
++ A medida que se van agregando elementos se le asigna un id unico secuencial a cada tarea.
++ Como usuario quiero poder eliminar una tarea, haciendo click en un comando junto a ella.
++ como usuario quiero cambiar el estado de una tarea de completada a pendiente y viceversa.
++ Como usuario quiero que las tareas completadas se muestren con una diferenciacion visual de las pendientes, puede ser un tachado, un color de fondo o algo.
++ como usuario quiero ver la cantidad total de tareas pendientes y completadas que tengo en mi lista en un footer.
++ En la lista de tareas se puede ver el id descripcion y el estado de cada tarea, ademas de un boton para elimnarla y otro para cambiar el estado.
-Run `ng generate component component-name` to generate a new component. You can also use `ng generate directive|pipe|service|class|guard|interface|enum|module`.
+Se deben usar los componentes que estan planteados y completar la funcionalidad faltante para que compile y se pueda hacer el
-## Build
+```ng build```
+```ng build --prod```
+```ng serve```
-Run `ng build` to build the project. The build artifacts will be stored in the `dist/` directory. Use the `--prod` flag for a production build.
+## Nivel 2 (opcional)
+Si te resulto muy facil la primera parte. o si ya tenes experiencia con Angular, React, Vue u otros frameworks.
++ Persistir la lista en localStorage
++ Permitir la edicion de una tarea.
++ Medir el tiempo que se tarda en completar una tarea y mostrar en el footer el tiempo promedio.
++ Permitir seleccionar un icono de fontawesome, bootstrap icons o cualquier libreria publica de iconos, para la tarea.
-## Running unit tests
+## Para entregar el trabajo
++ Hacer un fork de este repositorio tomar la rama todo-list-exercise y hacer un pull request a dicha rama.
+[Aqui](https://blog.desdelinux.net/tutorial-simple-primer-pr-pull-request/)
+y [Aqui](https://github.com/omegaup/omegaup/wiki/C%C3%B3mo-Hacer-un-Pull-Request) les deoj una guia de como usar git para un Pull request.
-Run `ng test` to execute the unit tests via [Karma](https://karma-runner.github.io).
+Me mandan el link al pull request asi les puedo mandar comentarios mediante github.
-## Running end-to-end tests
-
-Run `ng e2e` to execute the end-to-end tests via [Protractor](http://www.protractortest.org/).
-
-## Further help
-
-To get more help on the Angular CLI use `ng help` or go check out the [Angular CLI README](https://github.com/angular/angular-cli/blob/master/README.md).
diff --git a/angular.json b/angular.json
index 4deb648..1c7e6d6 100644
--- a/angular.json
+++ b/angular.json
@@ -28,6 +28,8 @@
"src/assets"
],
"styles": [
+ "./node_modules/bootstrap/dist/css/bootstrap.min.css",
+ "./node_modules/ngx-bootstrap/datepicker/bs-datepicker.css",
"src/styles.scss"
],
"scripts": []
@@ -92,6 +94,8 @@
"src/assets"
],
"styles": [
+ "./node_modules/bootstrap/dist/css/bootstrap.min.css",
+ "./node_modules/ngx-bootstrap/datepicker/bs-datepicker.css",
"src/styles.scss"
],
"scripts": []
@@ -123,6 +127,7 @@
}
}
}
- }},
+ }
+ },
"defaultProject": "ng-peti"
-}
+}
\ No newline at end of file
diff --git a/package-lock.json b/package-lock.json
index 512f702..90e9696 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -2492,6 +2492,11 @@
"integrity": "sha1-aN/1++YMUes3cl6p4+0xDcwed24=",
"dev": true
},
+ "bootstrap": {
+ "version": "4.1.1",
+ "resolved": "https://registry.npmjs.org/bootstrap/-/bootstrap-4.1.1.tgz",
+ "integrity": "sha512-SpiDSOcbg4J/PjVSt4ny5eY6j74VbVSjROY4Fb/WIUXBV9cnb5luyR4KnPvNoXuGnBK1T+nJIWqRsvU3yP8Mcg=="
+ },
"brace-expansion": {
"version": "1.1.11",
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz",
@@ -7423,6 +7428,11 @@
"integrity": "sha512-iyam8fBuCUpWeKPGpaNMetEocMt364qkCsfL9JuhjXX6dRnguRVOfk2GZaDpPjcOKiiXCPINZC1GczQ7iTq3Zw==",
"dev": true
},
+ "ngx-bootstrap": {
+ "version": "4.3.0",
+ "resolved": "https://registry.npmjs.org/ngx-bootstrap/-/ngx-bootstrap-4.3.0.tgz",
+ "integrity": "sha512-ZPS6V2yLEeqB/7KIlVohS8qUdtFa1bgUB/sSPWRcXqOWU3EKhORetZoXG6m2F5ILYDe5hwQvBEjdHPlEz2piOg=="
+ },
"nice-try": {
"version": "1.0.5",
"resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz",
diff --git a/package.json b/package.json
index 72b4bd7..c512cf5 100644
--- a/package.json
+++ b/package.json
@@ -19,6 +19,8 @@
"@angular/platform-browser": "~9.1.1",
"@angular/platform-browser-dynamic": "~9.1.1",
"@angular/router": "~9.1.1",
+ "bootstrap": "4.1.1",
+ "ngx-bootstrap": "^4.1.1",
"rxjs": "~6.5.4",
"tslib": "^1.10.0",
"zone.js": "~0.10.2"
diff --git a/src/app/app.component.html b/src/app/app.component.html
index e48d8c1..b530937 100644
--- a/src/app/app.component.html
+++ b/src/app/app.component.html
@@ -1,534 +1 @@
-
-
-
-
-
-
-
-
-
-
-
-
-