Add recovery_hash field to users table.

master
sigonasr2, Sig, Sigo 3 years ago
parent f39f79013e
commit f95022dd8b
  1. 1
      ngsplanner_patch.sql
  2. 3
      ngsplanner_schema.sql
  3. 8
      ngsplanner_seed.sql
  4. 2
      server.js

@ -6,3 +6,4 @@ alter table weapon_existence_data add column special_name text;
alter table potential drop column description;
alter table potential_data add column description text;
alter table photon_art add column icon text;
alter table users add column recovery_hash text;

@ -214,7 +214,8 @@ CREATE TABLE "users" (
"created_on" timestamptz,
"roles_id" int,
"avatar" text,
"editors_choice" int
"editors_choice" int,
"recovery_hash" text
);
CREATE TABLE "roles" (

@ -158,10 +158,10 @@ insert into roles(name)
insert into roles(name)
values('Guest');
insert into users(username,email,password_hash,created_on,roles_id,avatar)
values('sigonasr2','sigonasr2@gmail.com','ABCDEFG','2021-07-13 04:30+00',(select id from roles where name='Administrator' limit 1),'');
insert into users(username,email,password_hash,created_on,roles_id,avatar)
values('sigonasr3','sigonasr3@gmail.com','ABCDEF','2021-07-14 05:30+00',(select id from roles where name='Editor' limit 1),'');
insert into users(username,email,password_hash,created_on,roles_id,avatar,recovery_hash)
values('sigonasr2','sigonasr2@gmail.com','ABCDEFG','2021-07-13 04:30+00',(select id from roles where name='Administrator' limit 1),'','');
insert into users(username,email,password_hash,created_on,roles_id,avatar,recovery_hash)
values('sigonasr3','sigonasr3@gmail.com','ABCDEF','2021-07-14 05:30+00',(select id from roles where name='Editor' limit 1),'','');
insert into builds(users_id,creator,build_name,class1,class2,created_on,last_modified,likes,data,editors_choice)
values((select id from users where username='sigonasr2' limit 1),'sigonasr2','Test Build',(select id from class where name='Ranger' limit 1),(select id from class where name='Force' limit 1),'2021-07-13 04:30+00','2021-07-13 04:30+00',5,'<DATA STRING>',0);

@ -210,7 +210,7 @@ const ENDPOINTDATA=[
{
endpoint:"users",
requiredfields:["username","email","created_on","roles_id"],
optionalfields:["avatar","editors_choice"],
optionalfields:["avatar","editors_choice","recovery_hash"],
excludedfields:["password_hash"] //Fields to not output in GET.
},
{

Loading…
Cancel
Save