-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #18 from Duzz-Clean/duzzsys-patch-1
Novas funcionalidades de autenticação.
- Loading branch information
Showing
7 changed files
with
413 additions
and
129 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
create database dcleanapi; | ||
use dcleanapi; | ||
|
||
create table connections( | ||
`id` INT(12) PRIMARY KEY AUTO_INCREMENT, | ||
`token` INT(12) NOT NULL, -- Chave estrangeira de tokens.id | ||
`active` BOOLEAN DEFAULT TRUE | ||
)ENGINE = InnoDB; | ||
|
||
create table tokens( | ||
`id` INT(12) PRIMARY KEY AUTO_INCREMENT, | ||
`user` INT(12) NOT NULL, -- Usuário que utiliza | ||
`token` TEXT NOT NULL, -- Token de autenticação | ||
`datetime` TIMESTAMP DEFAULT NOW() -- Data e hora de gerado | ||
)ENGINE = InnoDB; | ||
|
||
ALTER TABLE connections | ||
ADD CONSTRAINT fk_tokens FOREIGN KEY (token) REFERENCES tokens(id); | ||
|
||
INSERT INTO `tokens` (`token`) VALUES ('953J359p267d761M'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,14 @@ | ||
[config_server] | ||
devs = "Jonas Duarte, Pablo Mariz" | ||
|
||
[config_bank] | ||
[config_bank_app] | ||
address_bank = localhost | ||
name_bank = dclean | ||
user_bank = root | ||
password_bank = '' | ||
|
||
[config_bank_api] | ||
address_bank = localhost | ||
name_bank = dcleanapi | ||
user_bank = root | ||
password_bank = '' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.