From e31686cb6ba43597ee19cbd2f71be4ccfc79754a Mon Sep 17 00:00:00 2001 From: Your Name <arthur.mant@gmail.com> Date: Mon, 17 Feb 2020 14:00:43 -0300 Subject: [PATCH] cleaned up some useless comments --- pinsisApp/src/app/about/about.component.ts | 32 +++++++++--------- pinsisApp/src/app/app-routing.module.ts | 32 +++++++++--------- pinsisApp/src/app/app.component.ts | 26 +++++++-------- pinsisApp/src/app/app.module.ts | 26 +++++++-------- pinsisApp/src/app/data-api.service.ts | 33 ++++++++----------- .../edit-machine/edit-machine.component.scss | 7 ---- .../edit-machine/edit-machine.component.ts | 18 +--------- .../src/app/events/events.component.scss | 5 --- pinsisApp/src/app/footer/footer-element.ts | 26 +++++++-------- .../src/app/footer/footer.component.scss | 15 ++------- pinsisApp/src/app/footer/footer.component.ts | 32 +++++++++--------- .../src/app/footer/mock-footer-elements.ts | 26 +++++++-------- .../graph-element/graph-element.component.ts | 28 ++++++++-------- .../src/app/header/header.component.scss | 11 ------- pinsisApp/src/app/header/header.component.ts | 32 +++++++++--------- .../hospital-selector.component.ts | 27 ++++++++------- pinsisApp/src/app/hospital.service.ts | 11 +------ pinsisApp/src/app/hospital.ts | 6 ---- pinsisApp/src/app/login/login.component.scss | 7 ---- pinsisApp/src/app/login/login.js | 33 ------------------- pinsisApp/src/app/machine.ts | 1 - .../app/main-page/main-page.component.spec.ts | 32 +++++++++--------- .../src/app/main-page/main-page.component.ts | 26 +++++++-------- .../app/maps-page/maps-page.component.scss | 11 ------- .../src/app/maps-page/maps-page.component.ts | 1 - .../register-equipment.component.scss | 8 ----- .../register-equipment.component.ts | 10 ------ .../register-hospital.component.scss | 6 ---- .../register-hospital.component.ts | 27 --------------- .../src/app/register/register.component.scss | 1 - .../src/app/register/register.component.ts | 4 --- 31 files changed, 189 insertions(+), 371 deletions(-) delete mode 100644 pinsisApp/src/app/login/login.js diff --git a/pinsisApp/src/app/about/about.component.ts b/pinsisApp/src/app/about/about.component.ts index 42317582..e8cd8106 100644 --- a/pinsisApp/src/app/about/about.component.ts +++ b/pinsisApp/src/app/about/about.component.ts @@ -1,19 +1,19 @@ - // This file is part of the project Pinsis-Portal. - // Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e - // Software Live) - - // This program is free software: you can redistribute it and/or modify - // it under the terms of the GNU General Public License as published by - // the Free Software Foundation, either version 3 of the License, or - // (at your option) any later version. - - // This program is distributed in the hope that it will be useful, - // but WITHOUT ANY WARRANTY; without even the implied warranty of - // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - // GNU General Public License for more details. - - // You should have received a copy of the GNU General Public License - // along with this program. If not, see <https://www.gnu.org/licenses/>. + /* This file is part of the project Pinsis-Portal. + Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e + Software Live) + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>.*/ import { Component, OnInit } from '@angular/core'; diff --git a/pinsisApp/src/app/app-routing.module.ts b/pinsisApp/src/app/app-routing.module.ts index e1f09572..e788edf4 100644 --- a/pinsisApp/src/app/app-routing.module.ts +++ b/pinsisApp/src/app/app-routing.module.ts @@ -1,19 +1,19 @@ -// This file is part of the project Pinsis-Portal. -// Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e -// Software Live) - -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. - -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. - -// You should have received a copy of the GNU General Public License -// along with this program. If not, see <https://www.gnu.org/licenses/>. +/*This file is part of the project Pinsis-Portal. + Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e + Software Live) + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>.*/ import { NgModule } from '@angular/core'; diff --git a/pinsisApp/src/app/app.component.ts b/pinsisApp/src/app/app.component.ts index 63ae6981..f2a2a8b5 100644 --- a/pinsisApp/src/app/app.component.ts +++ b/pinsisApp/src/app/app.component.ts @@ -1,19 +1,19 @@ -// This file is part of the project Pinsis-Portal. -// Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e -// Software Live) +/*This file is part of the project Pinsis-Portal. + Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e + Software Live) -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. -// You should have received a copy of the GNU General Public License -// along with this program. If not, see <https://www.gnu.org/licenses/>. + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>.*/ import { Component } from '@angular/core'; import {AuthService} from './auth.service'; diff --git a/pinsisApp/src/app/app.module.ts b/pinsisApp/src/app/app.module.ts index 4729ba25..0f335113 100644 --- a/pinsisApp/src/app/app.module.ts +++ b/pinsisApp/src/app/app.module.ts @@ -1,19 +1,19 @@ -// This file is part of the project Pinsis-Portal. -// Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e -// Software Live) +/*This file is part of the project Pinsis-Portal. + Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e + Software Live) -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. -// You should have received a copy of the GNU General Public License -// along with this program. If not, see <https://www.gnu.org/licenses/>. + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>.*/ import { BrowserModule } from '@angular/platform-browser'; import { BrowserAnimationsModule } from '@angular/platform-browser/animations'; diff --git a/pinsisApp/src/app/data-api.service.ts b/pinsisApp/src/app/data-api.service.ts index 3610292a..49ec15bf 100644 --- a/pinsisApp/src/app/data-api.service.ts +++ b/pinsisApp/src/app/data-api.service.ts @@ -1,19 +1,19 @@ -// This file is part of the project Pinsis-Portal. -// Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e -// Software Live) +/*This file is part of the project Pinsis-Portal. + Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e + Software Live) -// This program is free software: you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation, either version 3 of the License, or -// (at your option) any later version. + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. -// This program is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. -// You should have received a copy of the GNU General Public License -// along with this program. If not, see <https://www.gnu.org/licenses/>. + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>.*/ import { Injectable } from '@angular/core'; import * as $ from 'jquery'; @@ -46,13 +46,9 @@ export class DataApiService { callback(result); }); } - // - - //Uses - /* config format: { @@ -79,9 +75,6 @@ export class DataApiService { callback(result); }); } - // - - //Geolocation private cacheStates = null; diff --git a/pinsisApp/src/app/edit-machine/edit-machine.component.scss b/pinsisApp/src/app/edit-machine/edit-machine.component.scss index 33e560f0..9b93b264 100644 --- a/pinsisApp/src/app/edit-machine/edit-machine.component.scss +++ b/pinsisApp/src/app/edit-machine/edit-machine.component.scss @@ -3,8 +3,6 @@ // Letras .btn-list-el { - //position: relative; - //left:220px; margin-top: 2px; border-radius: 4px; padding: 4px 5px; @@ -109,7 +107,6 @@ border-radius: 8px; cursor: pointer; color: $text-dark; - //color: #ff0000; display: inline-block; font-size: 18px; font-family: $font-default; @@ -162,7 +159,6 @@ line-height: 1.1em; border-radius: 4px; max-width: 950px; - //background-color: #b0cfed; padding-top: 1.5rem !important; border-top-right-radius: 8px; border-top-left-radius: 8px; @@ -170,7 +166,6 @@ //Card que encapsula a imagem para o resultado de procurar .photosS-btn { - //align-items: center; background-color: #b0cfed; float: left; margin-left: 10px; @@ -189,7 +184,6 @@ .search{ background-color: #b0cfed; - //border:solid 1px; border-radius:8px; width:300px; height: 32px !important; @@ -210,7 +204,6 @@ .search-btn { margin-right: 5px; height: 32px; - //float: right; border-radius:5px; float:right; border: 4px solid transparent; diff --git a/pinsisApp/src/app/edit-machine/edit-machine.component.ts b/pinsisApp/src/app/edit-machine/edit-machine.component.ts index c4ae3fcb..b0b10b39 100644 --- a/pinsisApp/src/app/edit-machine/edit-machine.component.ts +++ b/pinsisApp/src/app/edit-machine/edit-machine.component.ts @@ -15,7 +15,6 @@ declare var Android: any; export class EditMachineComponent implements OnInit { changeButton (i) { var text = document.getElementsByClassName("more_text") as HTMLCollectionOf<HTMLElement>; - // console.log("texte[i]" ,text[i].style.display) if (text[i].style.display === "") { text[i].style.display = "inline"; @@ -68,14 +67,11 @@ export class EditMachineComponent implements OnInit { ); } - private validateDate(date - //, callback - ) { + private validateDate(date) { var r = true; var ListofDays = [31,28,31,30,31,30,31,31,30,31,30,31]; if ((date.month == '') || (date.day == '') || (date.year == '')) { - //console.log (date + " is empty") r = false } if (date.month > 12) { @@ -99,7 +95,6 @@ export class EditMachineComponent implements OnInit { r = false; } } - //return callback (r) return r; } @@ -109,21 +104,17 @@ export class EditMachineComponent implements OnInit { for (let i in this.machines[index]) { let x = document.getElementById(i+"_"+this.machines[index].id) - //console.log(i + " -> " + this.machines[index][i]) if (this.machines[index][i] === '') { console.log(i + " is empty") if (x != null) {x.style.borderBottomColor = "#ff0000"} - //else { console.log(i + " input not found") } v = false } else { if (x != null) {x.style.borderColor = "#4f425b"} - //else { console.log(i + " input not found") } } } if (await this.validateDate(this.machines[index].date_last_maintenance)) { - //console.log("Data da última manutenção válida") for (let i in this.machines[index].date_last_maintenance) { let x = document.getElementById("date_last_maintenance_"+i+"_"+this.machines[index].id) if (x != null) {x.style.borderColor = "#4f425b"} @@ -134,7 +125,6 @@ export class EditMachineComponent implements OnInit { else { console.log("date_last_maintenance_error_msg"+this.machines[index].id+" not found") } } else { - //console.log("Data da última manutenção inválida") for (let i in this.machines[index].date_last_maintenance) { let x = document.getElementById("date_last_maintenance_"+i+"_"+this.machines[index].id) if (x != null) {x.style.borderColor = "#ff0000"} @@ -147,7 +137,6 @@ export class EditMachineComponent implements OnInit { } if (await this.validateDate(this.machines[index].date_next_maintenance)) { - //console.log("Data da próxima manutenção válida") for (let i in this.machines[index].date_next_maintenance) { let x = document.getElementById("date_next_maintenance_"+i+"_"+this.machines[index].id) if (x != null) {x.style.borderColor = "#4f425b"} @@ -158,7 +147,6 @@ export class EditMachineComponent implements OnInit { else { console.log("date_next_maintenance_error_msg_"+this.machines[index].id+" not found") } } else { - //console.log("Data da próxima manutenção inválida") for (let i in this.machines[index].date_next_maintenance) { let x = document.getElementById("date_next_maintenance_"+i+"_"+this.machines[index].id) if (x != null) {x.style.borderColor = "#ff0000"} @@ -199,11 +187,7 @@ export class EditMachineComponent implements OnInit { id: this.machines[i].id, } - //var v = await this.valid(i) - //console.log(v) - if (await this.valid(i)) { - this.machineService.updateMachine(send) .subscribe(_ => { window.alert("Máquina "+send.serial_number+" atualizada com sucesso"); diff --git a/pinsisApp/src/app/events/events.component.scss b/pinsisApp/src/app/events/events.component.scss index 280c0a0e..abc839ba 100644 --- a/pinsisApp/src/app/events/events.component.scss +++ b/pinsisApp/src/app/events/events.component.scss @@ -110,7 +110,6 @@ width: 100%; margin-right: auto; margin-left: auto; - //color: #ff0000; } } @@ -149,7 +148,6 @@ line-height: 1.1em; border-radius: 4px; max-width: 950px; - //background-color: #b0cfed; padding-top: 1.5rem !important; border-top-right-radius: 8px; border-top-left-radius: 8px; @@ -157,7 +155,6 @@ //Card que encapsula a imagem para o resultado de procurar .photosS-btn { - //align-items: center; background-color: #b0cfed; float: left; margin-left: 10px; @@ -176,7 +173,6 @@ .search{ background-color: #b0cfed; - //border:solid 1px; border-radius:8px; width:300px; height: 32px !important; @@ -197,7 +193,6 @@ .search-btn { margin-right: 5px; height: 32px; - //float: right; border-radius:5px; float:right; border: 4px solid transparent; diff --git a/pinsisApp/src/app/footer/footer-element.ts b/pinsisApp/src/app/footer/footer-element.ts index b3c89782..8f44c93d 100644 --- a/pinsisApp/src/app/footer/footer-element.ts +++ b/pinsisApp/src/app/footer/footer-element.ts @@ -1,19 +1,19 @@ - // This file is part of the project Pinsis-Portal. - // Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e - // Software Live) +/*This file is part of the project Pinsis-Portal. + Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e + Software Live) - // This program is free software: you can redistribute it and/or modify - // it under the terms of the GNU General Public License as published by - // the Free Software Foundation, either version 3 of the License, or - // (at your option) any later version. + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. - // This program is distributed in the hope that it will be useful, - // but WITHOUT ANY WARRANTY; without even the implied warranty of - // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - // GNU General Public License for more details. + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. - // You should have received a copy of the GNU General Public License - // along with this program. If not, see <https://www.gnu.org/licenses/>. + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>.*/ diff --git a/pinsisApp/src/app/footer/footer.component.scss b/pinsisApp/src/app/footer/footer.component.scss index 10ad7faa..992ea420 100644 --- a/pinsisApp/src/app/footer/footer.component.scss +++ b/pinsisApp/src/app/footer/footer.component.scss @@ -37,18 +37,7 @@ .partner-logo { margin-bottom: 7px; max-width: 100%; - max-height: 50px; - - // @media screen and (min-width: $break-large) { - // filter: grayscale(75%); - // transition: 0.3s; - - // &:hover { - // filter: none; - // } - // } - - + max-height: 50px; } .license { @@ -79,4 +68,4 @@ font-size: 11px; } -} \ No newline at end of file +} diff --git a/pinsisApp/src/app/footer/footer.component.ts b/pinsisApp/src/app/footer/footer.component.ts index 703b0516..62ce55d1 100644 --- a/pinsisApp/src/app/footer/footer.component.ts +++ b/pinsisApp/src/app/footer/footer.component.ts @@ -1,19 +1,19 @@ - // This file is part of the project Pinsis-Portal. - // Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e - // Software Live) - - // This program is free software: you can redistribute it and/or modify - // it under the terms of the GNU General Public License as published by - // the Free Software Foundation, either version 3 of the License, or - // (at your option) any later version. - - // This program is distributed in the hope that it will be useful, - // but WITHOUT ANY WARRANTY; without even the implied warranty of - // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - // GNU General Public License for more details. - - // You should have received a copy of the GNU General Public License - // along with this program. If not, see <https://www.gnu.org/licenses/>. +/*This file is part of the project Pinsis-Portal. + Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e + Software Live) + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>.*/ import { Component, OnInit } from '@angular/core'; diff --git a/pinsisApp/src/app/footer/mock-footer-elements.ts b/pinsisApp/src/app/footer/mock-footer-elements.ts index d60e8ca9..5830c556 100644 --- a/pinsisApp/src/app/footer/mock-footer-elements.ts +++ b/pinsisApp/src/app/footer/mock-footer-elements.ts @@ -1,19 +1,19 @@ - // This file is part of the project Pinsis-Portal. - // Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e - // Software Live) +/*This file is part of the project Pinsis-Portal. + Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e + Software Live) - // This program is free software: you can redistribute it and/or modify - // it under the terms of the GNU General Public License as published by - // the Free Software Foundation, either version 3 of the License, or - // (at your option) any later version. + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. - // This program is distributed in the hope that it will be useful, - // but WITHOUT ANY WARRANTY; without even the implied warranty of - // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - // GNU General Public License for more details. + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. - // You should have received a copy of the GNU General Public License - // along with this program. If not, see <https://www.gnu.org/licenses/>. + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>.*/ import { FooterElement } from './footer-element'; diff --git a/pinsisApp/src/app/graphs-page/graph-element/graph-element.component.ts b/pinsisApp/src/app/graphs-page/graph-element/graph-element.component.ts index 71072955..bc8dbf74 100644 --- a/pinsisApp/src/app/graphs-page/graph-element/graph-element.component.ts +++ b/pinsisApp/src/app/graphs-page/graph-element/graph-element.component.ts @@ -1,19 +1,19 @@ - // This file is part of the project Pinsis-Portal. - // Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e - // Software Live) +/*This file is part of the project Pinsis-Portal. + Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e + Software Live) - // This program is free software: you can redistribute it and/or modify - // it under the terms of the GNU General Public License as published by - // the Free Software Foundation, either version 3 of the License, or - // (at your option) any later version. + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. - // This program is distributed in the hope that it will be useful, - // but WITHOUT ANY WARRANTY; without even the implied warranty of - // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - // GNU General Public License for more details. + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. - // You should have received a copy of the GNU General Public License - // along with this program. If not, see <https://www.gnu.org/licenses/>. + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>.*/ import { Component, ViewChild, ElementRef, AfterViewInit, Input} from '@angular/core'; @@ -49,4 +49,4 @@ export class GraphElementComponent implements AfterViewInit { this.chart.destroy(); this.chart = chart(this.graphTarget.nativeElement, this.options); } -} \ No newline at end of file +} diff --git a/pinsisApp/src/app/header/header.component.scss b/pinsisApp/src/app/header/header.component.scss index 313d7ef5..5c69feb9 100644 --- a/pinsisApp/src/app/header/header.component.scss +++ b/pinsisApp/src/app/header/header.component.scss @@ -82,11 +82,6 @@ @media screen and (min-width: $break-small + 1) and (max-width: $break-large) { font-size: 13px; } - - // @media screen and (min-width: $break-large) { - // float: right; - // } - } .vertical-center { @@ -210,9 +205,3 @@ } } - .pull-left { - // float: left; - - border-right: 3px solid $bg-default; - -} diff --git a/pinsisApp/src/app/header/header.component.ts b/pinsisApp/src/app/header/header.component.ts index 462a603c..f7552503 100644 --- a/pinsisApp/src/app/header/header.component.ts +++ b/pinsisApp/src/app/header/header.component.ts @@ -1,19 +1,19 @@ - // This file is part of the project Pinsis-Portal. - // Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e - // Software Live) - - // This program is free software: you can redistribute it and/or modify - // it under the terms of the GNU General Public License as published by - // the Free Software Foundation, either version 3 of the License, or - // (at your option) any later version. - - // This program is distributed in the hope that it will be useful, - // but WITHOUT ANY WARRANTY; without even the implied warranty of - // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - // GNU General Public License for more details. - - // You should have received a copy of the GNU General Public License - // along with this program. If not, see <https://www.gnu.org/licenses/>. + /* This file is part of the project Pinsis-Portal. + Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e + Software Live) + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>.*/ import { Component, OnInit } from '@angular/core'; diff --git a/pinsisApp/src/app/hospital-selector/hospital-selector.component.ts b/pinsisApp/src/app/hospital-selector/hospital-selector.component.ts index ae5bc638..2fb34421 100644 --- a/pinsisApp/src/app/hospital-selector/hospital-selector.component.ts +++ b/pinsisApp/src/app/hospital-selector/hospital-selector.component.ts @@ -1,19 +1,19 @@ - // This file is part of the project Pinsis-Portal. - // Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e - // Software Live) +/*This file is part of the project Pinsis-Portal. + Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e + Software Live) - // This program is free software: you can redistribute it and/or modify - // it under the terms of the GNU General Public License as published by - // the Free Software Foundation, either version 3 of the License, or - // (at your option) any later version. + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. - // This program is distributed in the hope that it will be useful, - // but WITHOUT ANY WARRANTY; without even the implied warranty of - // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - // GNU General Public License for more details. + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. - // You should have received a copy of the GNU General Public License - // along with this program. If not, see <https://www.gnu.org/licenses/>. + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>.*/ import { Component, OnInit } from '@angular/core'; @@ -38,7 +38,6 @@ export class HospitalSelectorComponent implements OnInit { _itenTriggerClick = function(x){ this.mapsPage.showInfo(x) - //this.itemTriggerClick(x,this.father); }; itemTriggerClick = function(x,y){} diff --git a/pinsisApp/src/app/hospital.service.ts b/pinsisApp/src/app/hospital.service.ts index febcbee7..0e66682a 100644 --- a/pinsisApp/src/app/hospital.service.ts +++ b/pinsisApp/src/app/hospital.service.ts @@ -31,16 +31,7 @@ export class HospitalService { formData.append('longitude', hospital.longitude) formData.append('city', hospital.city) formData.append('file', hospital.image, hospital.image.name) - /* - var send = { - name: hospital.name, - longitude: hospital.longitude, - latitude: hospital.latitude, - //countie: hospital.city, - //state: hospital.state, - //region: hospital.region, - } - */ + return formData; } diff --git a/pinsisApp/src/app/hospital.ts b/pinsisApp/src/app/hospital.ts index 69123a2e..794cf17e 100644 --- a/pinsisApp/src/app/hospital.ts +++ b/pinsisApp/src/app/hospital.ts @@ -1,14 +1,8 @@ -//template para as maquinas (falta a imagem) export class Hospital { name: string; - //address: string; - //building_number: string; - //district: string; city: string; - //state: string; latitude: string; longitude: string; - //region: string; image: File; imagePath: 'none'; } diff --git a/pinsisApp/src/app/login/login.component.scss b/pinsisApp/src/app/login/login.component.scss index 8992c739..726fae78 100644 --- a/pinsisApp/src/app/login/login.component.scss +++ b/pinsisApp/src/app/login/login.component.scss @@ -5,12 +5,6 @@ } - // .form-group{ - // color:#98FB98 ; - // - // - // } - .card { border: 2px solid $text-dark; border-radius: 10px; @@ -59,7 +53,6 @@ input { font-size: 20px; - //padding: 5px 10px 5px 10px; color:$text-dark; border-color: #9d9d9d; border-radius: 4px; diff --git a/pinsisApp/src/app/login/login.js b/pinsisApp/src/app/login/login.js deleted file mode 100644 index f9d65076..00000000 --- a/pinsisApp/src/app/login/login.js +++ /dev/null @@ -1,33 +0,0 @@ -// $(function() { -// var createAllErrors = function() { -// var form = $(this); -// var errorList = $('ul.errorMessages', form); -// -// var showAllErrorMessages = function() { -// errorList.empty(); -// -// //Find all invalid fields within the form. -// form.find(':invalid').each(function(index, node) { -// -// //Find the field's corresponding label -// var label = $('label[for=' + node.id + ']'); -// -// //Opera incorrectly does not fill the validationMessage property. -// var message = node.validationMessage || 'Invalid value.'; -// errorList -// .show() -// .append('<li><span>' + label.html() + '</span> ' + message + '</li>'); -// }); -// }; -// -// $('input[type=submit], button', form).on('click', showAllErrorMessages); -// $('input[type=text]', form).on('keypress', function(event) { -// //keyCode 13 is Enter -// if (event.keyCode == 13) { -// showAllErrorMessages(); -// } -// }); -// }; -// -// $('form').each(createAllErrors); -// }); diff --git a/pinsisApp/src/app/machine.ts b/pinsisApp/src/app/machine.ts index 99c53e07..a915e3be 100644 --- a/pinsisApp/src/app/machine.ts +++ b/pinsisApp/src/app/machine.ts @@ -1,4 +1,3 @@ -//template para as maquinas (falta a imagem) export class Machine { serial_number: string; room: string; diff --git a/pinsisApp/src/app/main-page/main-page.component.spec.ts b/pinsisApp/src/app/main-page/main-page.component.spec.ts index 91ded734..039930fd 100644 --- a/pinsisApp/src/app/main-page/main-page.component.spec.ts +++ b/pinsisApp/src/app/main-page/main-page.component.spec.ts @@ -1,19 +1,19 @@ - // This file is part of the project Pinsis-Portal. - // Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e - // Software Live) - - // This program is free software: you can redistribute it and/or modify - // it under the terms of the GNU General Public License as published by - // the Free Software Foundation, either version 3 of the License, or - // (at your option) any later version. - - // This program is distributed in the hope that it will be useful, - // but WITHOUT ANY WARRANTY; without even the implied warranty of - // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - // GNU General Public License for more details. - - // You should have received a copy of the GNU General Public License - // along with this program. If not, see <https://www.gnu.org/licenses/>. +/* This file is part of the project Pinsis-Portal. + Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e + Software Live) + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>.*/ import { async, ComponentFixture, TestBed } from '@angular/core/testing'; diff --git a/pinsisApp/src/app/main-page/main-page.component.ts b/pinsisApp/src/app/main-page/main-page.component.ts index dd5f59a1..177076d5 100644 --- a/pinsisApp/src/app/main-page/main-page.component.ts +++ b/pinsisApp/src/app/main-page/main-page.component.ts @@ -1,19 +1,19 @@ - // This file is part of the project Pinsis-Portal. - // Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e - // Software Live) +/*This file is part of the project Pinsis-Portal. + Copyright (C),2018, by C3SL(Centro de Computação CientÃfica e + Software Live) - // This program is free software: you can redistribute it and/or modify - // it under the terms of the GNU General Public License as published by - // the Free Software Foundation, either version 3 of the License, or - // (at your option) any later version. + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. - // This program is distributed in the hope that it will be useful, - // but WITHOUT ANY WARRANTY; without even the implied warranty of - // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - // GNU General Public License for more details. + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. - // You should have received a copy of the GNU General Public License - // along with this program. If not, see <https://www.gnu.org/licenses/>. + You should have received a copy of the GNU General Public License + along with this program. If not, see <https://www.gnu.org/licenses/>.*/ import { Component, OnInit } from '@angular/core'; import { AppModule } from '../app.module'; diff --git a/pinsisApp/src/app/maps-page/maps-page.component.scss b/pinsisApp/src/app/maps-page/maps-page.component.scss index c60967d0..645abae3 100644 --- a/pinsisApp/src/app/maps-page/maps-page.component.scss +++ b/pinsisApp/src/app/maps-page/maps-page.component.scss @@ -77,16 +77,6 @@ } } - - -// [class*="col-"] { -// float: none; -// display: table-cell; -// vertical-align: top; -// padding:5px; -// min-width:100px; -// } - .arrow_box { position: relative; background: #fff; @@ -126,7 +116,6 @@ padding: 10px 16px; list-style: none; background-color: $white; - //width: 60%; li { display: inline; diff --git a/pinsisApp/src/app/maps-page/maps-page.component.ts b/pinsisApp/src/app/maps-page/maps-page.component.ts index f494dabc..6b504cea 100644 --- a/pinsisApp/src/app/maps-page/maps-page.component.ts +++ b/pinsisApp/src/app/maps-page/maps-page.component.ts @@ -1,5 +1,4 @@ import {Component, OnInit, ViewChild,AfterViewInit } from '@angular/core'; -//import { HospitalSelectorComponent } from '../hospital-selector/hospital-selector.component'; import { DataApiService } from '../data-api.service'; import * as L from 'leaflet'; import { Icon, Marker } from 'leaflet'; diff --git a/pinsisApp/src/app/register-equipment/register-equipment.component.scss b/pinsisApp/src/app/register-equipment/register-equipment.component.scss index d7d1c90c..32dd8422 100644 --- a/pinsisApp/src/app/register-equipment/register-equipment.component.scss +++ b/pinsisApp/src/app/register-equipment/register-equipment.component.scss @@ -32,7 +32,6 @@ } } -// Texto de input input { color:$text-dark; font-size: 20px; @@ -83,7 +82,6 @@ input { } } -// Card branco de fundo .blank-square { padding: 20px 15px; background-color: $white; @@ -101,8 +99,6 @@ input { width:27%; margin-top:20px; - //margin-left:auto; - //margin-right: 50px; display:inline-block; border-style: none; @@ -114,9 +110,7 @@ input { background:$dark-purple; } @media only screen and (max-width: $break-small+80px) { - //background: solid red; width: 80%; - //margin-top: 20px; margin-left: 5%; margin-right: 5%; } @@ -151,9 +145,7 @@ input { background:$dark-purple; } @media only screen and (max-width: $break-small+80px) { - //background: solid red; width: 80%; - //margin-top: 20px; margin-left: 5%; margin-right: 5%; } diff --git a/pinsisApp/src/app/register-equipment/register-equipment.component.ts b/pinsisApp/src/app/register-equipment/register-equipment.component.ts index a431322a..17a49173 100644 --- a/pinsisApp/src/app/register-equipment/register-equipment.component.ts +++ b/pinsisApp/src/app/register-equipment/register-equipment.component.ts @@ -57,7 +57,6 @@ export class RegisterEquipmentComponent implements OnInit { var ListofDays = [31,28,31,30,31,30,31,31,30,31,30,31]; if ((date.month == '') || (date.day == '') || (date.year == '')) { - //console.log (date + " is empty") r = false } if (date.month > 12) { @@ -91,19 +90,16 @@ export class RegisterEquipmentComponent implements OnInit { for (let i in this.machineData) { var x = document.getElementById(i) if (this.machineData[i] === '') { - //console.log(i + " is empty") if (x != null) {x.style.borderColor = "#ff0000"} else { console.log(i + " input not found") } v = false } else { if (x != null) {x.style.borderColor = "#9d9d9d"} - //else { console.log(i + " input not found") } } } if (this.machineData.image.size == 0) { - //console.log("image is empty") x = document.getElementById("image_upload_button") if (x != null) { x.style.borderColor = "#ff0000" @@ -128,7 +124,6 @@ export class RegisterEquipmentComponent implements OnInit { } if (await this.validateDate(this.machineData.date_last_maintenance)) { - //console.log("Data da última manutenção válida") for (let i in this.machineData.date_last_maintenance) { let x = document.getElementById("date_last_maintenance_"+i) if (x != null) {x.style.borderColor = "#9d9d9d"} @@ -139,7 +134,6 @@ export class RegisterEquipmentComponent implements OnInit { else { console.log("date_last_maintenance_error_msg not found") } } else { - //console.log("Data da última manutenção inválida") for (let i in this.machineData.date_last_maintenance) { let x = document.getElementById("date_last_maintenance_"+i) if (x != null) {x.style.borderColor = "#ff0000"} @@ -152,7 +146,6 @@ export class RegisterEquipmentComponent implements OnInit { } if (await this.validateDate(this.machineData.date_next_maintenance)) { - //console.log("Data da próxima manutenção válida") for (let i in this.machineData.date_next_maintenance) { let x = document.getElementById("date_next_maintenance_"+i) if (x != null) {x.style.borderColor = "#9d9d9d"} @@ -163,7 +156,6 @@ export class RegisterEquipmentComponent implements OnInit { else { console.log("date_next_maintenance_error_msg not found") } } else { - //console.log("Data da próxima manutenção inválida") for (let i in this.machineData.date_next_maintenance) { let x = document.getElementById("date_next_maintenance_"+i) if (x != null) {x.style.borderColor = "#ff0000"} @@ -235,8 +227,6 @@ export class RegisterEquipmentComponent implements OnInit { scanQRCode () { - //window.alert("scanning QR code"); - Android.scanBarcode(); alert(Android.result()); this.machineData.serial_number = Android.result(); diff --git a/pinsisApp/src/app/register-hospital/register-hospital.component.scss b/pinsisApp/src/app/register-hospital/register-hospital.component.scss index 7ec0ea15..99ba0ef9 100644 --- a/pinsisApp/src/app/register-hospital/register-hospital.component.scss +++ b/pinsisApp/src/app/register-hospital/register-hospital.component.scss @@ -19,7 +19,6 @@ input { border-color: #9d9d9d; border-radius: 4px; border-style: solid; - //padding: 5px 10px; } .register-card { @@ -33,7 +32,6 @@ input { .input-text { font-size: 20px; - //padding: 5px 10px; display: block; margin-top:10px; } @@ -51,8 +49,6 @@ input { font-size: 20px; padding: 5px 20px; - //margin-right: 9%; - //margin-left: auto; margin-top: 20px; display: inline-block; @@ -76,7 +72,6 @@ input { margin-left: 20px; margin-right: 36%; - //margin-top: 30px; display: inline-block; border-style: none; @@ -93,7 +88,6 @@ input { .selected-image { font-size: 20px; - //width: 40%; display: inline-block; margin-top: 20px; margin-left: 20px; diff --git a/pinsisApp/src/app/register-hospital/register-hospital.component.ts b/pinsisApp/src/app/register-hospital/register-hospital.component.ts index 3dbc3469..23a7deb8 100644 --- a/pinsisApp/src/app/register-hospital/register-hospital.component.ts +++ b/pinsisApp/src/app/register-hospital/register-hospital.component.ts @@ -12,14 +12,9 @@ export class RegisterHospitalComponent implements OnInit { hospitalData: Hospital = { name: '', - //address: '', - //building_number: '', - //district: '', city: '', - //state: '', latitude: '', longitude: '', - //region: '', image: new File([''], "nenhuma"), imagePath: 'none', } @@ -80,42 +75,20 @@ export class RegisterHospitalComponent implements OnInit { async onSubmit() { this.hospitalData.name = this.hospitalData.name.trim(); - //this.hospitalData.address = this.hospitalData.address.trim(); - //this.hospitalData.building_number = this.hospitalData.building_number.trim(); - //this.hospitalData.district = this.hospitalData.district.trim(); this.hospitalData.city = this.hospitalData.city.trim(); - //this.hospitalData.state = this.hospitalData.state.trim(); this.hospitalData.latitude = this.hospitalData.latitude.trim(); this.hospitalData.longitude = this.hospitalData.longitude.trim(); - //this.hospitalData.region = this.hospitalData.region.trim(); if (await this.valid()) { console.log("sending") -/* - window.alert("Nome: "+this.hospitalData.name - //+"\nRua: "+this.hospitalData.address - //+"\nNumero: "+this.hospitalData.building_number - //+"\nBairro: "+this.hospitalData.district - +"\nCidade: "+this.hospitalData.city - +"\nEstado: "+this.hospitalData.state - +"\nRegião: "+this.hospitalData.region - +"\nLatitude: "+this.hospitalData.latitude - +"\nLongitude: "+this.hospitalData.longitude) -*/ this.hospitalService.addHospital(this.hospitalData) .subscribe(res => { window.alert("Hospital "+res.agent.hospital_name+" registrado com sucesso"); this.hospitalData.name = ''; - //this.hospitalData.address = ''; - //this.hospitalData.building_number = ''; - //this.hospitalData.district = ''; this.hospitalData.city = ''; - //this.hospitalData.state = ''; this.hospitalData.latitude = ''; this.hospitalData.longitude = ''; - //this.hospitalData.region = 'indefinida'; - //console.log(res) this.hospitalData.image = new File([''], "nenhuma"); }, err => { diff --git a/pinsisApp/src/app/register/register.component.scss b/pinsisApp/src/app/register/register.component.scss index dc3838ef..e003c71c 100644 --- a/pinsisApp/src/app/register/register.component.scss +++ b/pinsisApp/src/app/register/register.component.scss @@ -59,7 +59,6 @@ input { font-size: 20px; - //padding: 5px 10px 5px 10px; color:$text-dark; border-color: #9d9d9d; border-radius: 4px; diff --git a/pinsisApp/src/app/register/register.component.ts b/pinsisApp/src/app/register/register.component.ts index a28575da..b8ffc6b4 100644 --- a/pinsisApp/src/app/register/register.component.ts +++ b/pinsisApp/src/app/register/register.component.ts @@ -27,7 +27,6 @@ export class RegisterComponent implements OnInit { x.style.display = "none" var v = true; if (this.registerUserData.email.length < 5) { - //window.alert("Email inválido") let x = document.getElementById("email_error_msg") x.style.display = "block" v = false; @@ -37,7 +36,6 @@ export class RegisterComponent implements OnInit { } if (this.registerUserData.password.length < 5) { - //window.alert("A senha deve possuir 5 ou mais caracteres") let x = document.getElementById("password_error_msg") x.style.display = "block" v = false; @@ -47,7 +45,6 @@ export class RegisterComponent implements OnInit { } if (this.registerUserData.password !== this.registerUserData.passwordConfirmation) { - //window.alert("Ambas as senhas tem que ser iguais") let x = document.getElementById("passwordConfirmation_error_msg") x.style.display = "block" v = false; @@ -66,7 +63,6 @@ export class RegisterComponent implements OnInit { res =>{ console.log(res) if(res.status == "User with this email found") { - //window.alert("Esse usuário já está em uso") let x = document.getElementById("email_error_msg_2") x.style.display = "block" return; -- GitLab