Skip to content

Commit

Permalink
Merge pull request #7 from jadson179/develop
Browse files Browse the repository at this point in the history
Develop
  • Loading branch information
gtjadsonsantos authored Feb 17, 2020
2 parents c18108d + 12ee041 commit 07f3b48
Show file tree
Hide file tree
Showing 36 changed files with 5,682 additions and 63 deletions.
57 changes: 51 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
# PAINEL DE SALAS


![](frontend/public/view.png)

<h1 align="center"> PAINEL DE SALAS</h1>

<p align="center">
<img width="360" height="300" src="mobile/assets/icon.png">
</p>

A PROPOSTA DESSA APLICAÇÃO É TORNAR SIMPLES A IDENTIFICAÇÃO DAS EMPRESAS PRESENTES EM EMPREENDIMENTOS QUE SÃO COMERCIAIS

Expand Down Expand Up @@ -43,11 +42,57 @@ Acesse a interface do seu banco mysql http://`seuendereçoip`/phpmyadmin/

Copie o conteúdo do arquivo `PAINEL/provisioning.sql`, cole e execute

# AUTENTICAÇÃO INICIAL
### AUTENTICAÇÃO INICIAL

`Username`: admin

`Password`: admin


### SKETCHES

#### WEB

<table>
<tr>
<td><img style="width=100%; height=300px" src="frontend/public/login.png"></td>
</tr>
<tr>
<td><img style="width=100%; height=300px" src="frontend/public/admin-web.png"></td>
</tr>
<tr>
<td><img style="width=100%; height=300px" src="frontend/public/view-1.png"></td>
</tr>
<tr>
<td><img style="width=100%; height=300px" src="frontend/public/view-2.png"></td>
</tr>
</table>

### MOBILE

<table>
<tr>
<td><img style="width:200px; height:400px" src="mobile/assets/icon.png"></td>
</tr>
<tr>
<td><img style="width:300px; height:500px" src="mobile/assets/splash.png"></td>
<td><img style="width:300px; height:500px" src="frontend/public/login-mobile.png"></td>
</tr>
<tr>
<td><img style="width:300px; height:500px" src="frontend/public/admin-mobile.png"></td>
<td><img style="width:300px; height:500px" src="frontend/public/view-mobile.png"></td>
</tr>
</table>


`apk:` [address](https://exp-shell-app-assets.s3.us-west-1.amazonaws.com/android/%40jadson179/Painel-5aad65f531a9401dbcda37fd677efc24-signed.apk)

# CONTRIBUIDORES

<table>
<tr>
<td><a href="https://github.com/jadson179"><img width="100" src="https://avatars2.githubusercontent.com/u/42282908?s=460&v=4" /></a></td>
</tr>
</table>

![](frontend/public/logo.png)
7 changes: 6 additions & 1 deletion RELEASES.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,9 @@ a ação irá duplicar o usuário administrador e assim o servidor irá para de
* Estilizado as informação de horário, cotação do dolar
* `BUG`: Problema de servidor crachando.
* Adicionado campo para acesso a segunda view do painel, na página admnistração.
* Ajustado a interface para ser responsiva
* Ajustado a interface para ser responsiva


## VERSÃO 1.0.4

* Criado aplicativo mobile
16 changes: 10 additions & 6 deletions backend/migrate/Schemas.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
const connection = require('../database/connection')
const mysql = require('mysql2')
const database = require('../database/connection')

async function SchemaUsers () {
const sql = `
Expand All @@ -8,9 +9,10 @@ async function SchemaUsers () {
UserPassword VARCHAR(255) NOT NULL,
UserType VARCHAR(255) NOT NULL);`

await connection.promise().query(sql);
await connection.promise().query("INSERT INTO Users (UserName, UserPassword, UserType ) VALUES ('admin','admin','administrator');");

const connection = await mysql.createConnection(database)
await connection.promise().execute(sql)
await connection.promise().execute("INSERT INTO Users (UserName, UserPassword, UserType ) VALUES ('admin','admin','administrator');")
connection.end();

}
async function SchemaRooms() {
Expand All @@ -21,8 +23,9 @@ async function SchemaRooms() {
NameImage VARCHAR(100)
);
`

const connection = await mysql.createConnection(database)
await connection.promise().query(sql);
connection.end();

}
async function SchemaFloors() {
Expand All @@ -34,8 +37,9 @@ async function SchemaFloors() {
FOREIGN KEY(RoomsID) REFERENCES Rooms(RoomsID)ON DELETE CASCADE ON UPDATE CASCADE
);
`

const connection = await mysql.createConnection(database)
await connection.promise().query(sql);
connection.end();

}

Expand Down
Binary file added frontend/public/admin-mobile.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added frontend/public/admin-web.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed frontend/public/admin.png
Binary file not shown.
Binary file modified frontend/public/favicon.ico
Binary file not shown.
24 changes: 1 addition & 23 deletions frontend/public/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,34 +10,12 @@
content="Web site created using create-react-app"
/>
<link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" />
<!--
manifest.json provides metadata used when your web app is installed on a
user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
-->
<link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
<!--
Notice the use of %PUBLIC_URL% in the tags above.
It will be replaced with the URL of the `public` folder during the build.
Only files inside the `public` folder can be referenced from the HTML.

Unlike "/favicon.ico" or "favicon.ico", "%PUBLIC_URL%/favicon.ico" will
work correctly both with client-side routing and a non-root public URL.
Learn how to configure a non-root public URL by running `npm run build`.
-->
<title>React App</title>
<title>Painel de Salas</title>
</head>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
<!--
This HTML file is a template.
If you open it directly in the browser, you will see an empty page.
You can add webfonts, meta tags, or analytics to this file.
The build step will place the bundled scripts into the <body> tag.
To begin the development, run `npm start` or `yarn start`.
To create a production bundle, use `npm run build` or `yarn build`.
-->
</body>
</html>
Binary file added frontend/public/login-mobile.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified frontend/public/login.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified frontend/public/logo192.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified frontend/public/logo512.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion frontend/public/manifest.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"short_name": "React App",
"short_name": "Painel de Salas",
"name": "Create React App Sample",
"icons": [
{
Expand Down
Binary file added frontend/public/view-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added frontend/public/view-2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added frontend/public/view-mobile.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed frontend/public/view.png
Binary file not shown.
26 changes: 16 additions & 10 deletions frontend/src/components/Administration/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@

#containerNavigation ul {
width: 100%;
background: #fff;
border-radius: 0.2em;
}
#containerNavigation ul li p {
font-weight: bold;
Expand All @@ -24,19 +26,18 @@
}
#containerNavigation ul li:hover {
cursor: pointer;
border-left: 2px solid #fff;
background: rgb(219, 219, 219);
}

#containerNavigation ul li {
padding-left: 10px;
margin-top: 10px;
border-radius: 0.5em;
height: 50px;
text-align: start;
font-family: 'Roboto',sans-serif;
background: rgb(19, 18, 23);
font-size: small;
color: #fff;
font-weight: bold;
border-bottom: 1px solid rgb(182, 182, 182);
color: #000;
display: flex;
align-items: center;
}
Expand All @@ -55,7 +56,7 @@
#continerTopToMobile {
display: flex;
width: 100%;
height: 60px;
height: 65px;
background: #fff;
position: absolute;
flex-direction: row;
Expand All @@ -67,9 +68,10 @@
}
#buttonTopMenu {
color: #fff;
width: 30px;
height: 20px;
margin-left: 5px;
width: 40px;
height: 30px;
margin-top: 10px;
margin-left: 10px;
cursor: pointer;
}
#containerFunctional {
Expand Down Expand Up @@ -99,7 +101,11 @@
font-family: 'Roboto',sans-serif;
margin-top: 8px;
line-height: 40px;
margin-left: 10px;
padding-left: 10px;
height: 40px;
cursor: pointer;
}
#list-menu li:hover {
background: rgb(151, 151, 151);
}
}
2 changes: 1 addition & 1 deletion frontend/src/components/CreateUser/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ function CreateUser() {
{
((password === verifyPassword) &&
(password !== '') &&
(verifyPassword !== '') &&
(verifyPassword !== '') &&
(usertype !== '')
)
? <p id="verify">Senha correta</p>:<p id="incorret">Senha Incorreta</p>
Expand Down
4 changes: 2 additions & 2 deletions frontend/src/components/ListUsers/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ h2 {

}
#list {
width: 200px;
width: 300px;
}
.item-list {
color: #000;
color: #fff;
display: block;
text-align: center;
height: 30px;
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/components/Login/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ function Auth() {
<div id="containerLogin">
<div id="box-login">
<header>
<h1>Login</h1>
<h2>Login</h2>
</header>
<main>
<input type="text" placeholder="Usuario" onChange={username => setUsername(username.target.value)} autoFocus required />
Expand Down
9 changes: 4 additions & 5 deletions frontend/src/components/Login/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,7 @@ html, body, #root, #containerLogin {
height: 100%;
width: 100%;
display: flex;
background: rgb(2,0,36);
background: #fff;
background: rgb(4, 1, 44);
flex: 1;
}
#containerLogin {
Expand All @@ -40,7 +39,7 @@ header {
color: rgb(6, 2, 66);
}
h2 {
color: #000;
color: #fff;
font-size: 25px;
text-align: center;
border-bottom: 1px solid #000;
Expand All @@ -58,7 +57,7 @@ input {
width: 90%;
margin-top: 20px;
border-radius: 0.3em;
border: 0.6px solid rgb(70, 70, 70);
border: 0.5px solid rgb(128, 128, 128);
}

#area-buttons {
Expand All @@ -73,7 +72,7 @@ button {
height: 40px;
border-radius: 5px;
font-size: 15px;
background-color: rgb(0, 4, 42);
background-color: rgb(109, 109, 109);
color: #fff;
cursor: pointer;
margin-left: 24px;
Expand Down
8 changes: 4 additions & 4 deletions frontend/src/components/Section/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -37,18 +37,18 @@ html, body, #root {
}

.title {
margin-bottom: 13px;
padding-bottom: 13px;
width: 100%;
font-size: 20px;
color: #fff;
font-weight: 900;
height: 35px;
height: 45px;
text-align: center;
line-height: 35px;
line-height: 45px;
}

.imageCostumer {
width: 80%;
width: 70%;
height: 5%;
}

Expand Down
3 changes: 0 additions & 3 deletions frontend/src/components/Weather/index.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import React, { useState, useEffect } from 'react'
import OAuth from 'oauth'
import config from '../../config'
import Price from '../Price'
import './style.css'

Expand All @@ -21,7 +20,6 @@ function Time() {

function Weather(){
const [forecast, setForecast ] = useState([])
const [ firstForecast, setFirstForecast ] = useState({})

const [ date, setDate ] = useState('')
useEffect(()=>{
Expand Down Expand Up @@ -56,7 +54,6 @@ function Weather(){
const repo_yahoo = JSON.parse(data)
//document.getElementById('condicion').innerHTML = `${repo_yahoo.forecasts[0].text}`
setForecast(repo_yahoo.forecasts)
setFirstForecast(repo_yahoo.forecasts[0].code)
}
}
);
Expand Down
4 changes: 4 additions & 0 deletions mobile/.expo-shared/assets.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"f9155ac790fd02fadcdeca367b02581c04a353aa6d5aa84409a59f6804c87acd": true,
"89ed26367cdb9b771858e026f2eb95bfdb90e5ae943e716575327ec325f39c44": true
}
14 changes: 14 additions & 0 deletions mobile/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
node_modules/**/*
.expo/*
npm-debug.*
*.jks
*.p8
*.p12
*.key
*.mobileprovision
*.orig.*
web-build/
web-report/

# macOS
.DS_Store
7 changes: 7 additions & 0 deletions mobile/App.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import React from 'react';
import Routes from './routes'

export default function App() {
return <Routes />

}
Loading

0 comments on commit 07f3b48

Please sign in to comment.