Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/data #90

Merged
merged 14 commits into from
Apr 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion backend/db/migrations/4.label.sql
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ VALUES
(1, 'Household', 'purple'),
(5, 'Financial', 'orange'),
(5, 'Appointments', 'green'),
(5, 'Old People <3', 'red')
(5, 'Medication', 'red')
;

INSERT INTO task_labels (task_id, group_id, label_name)
Expand Down
30 changes: 30 additions & 0 deletions backend/db/simulation/1.user.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
DROP TABLE IF EXISTS users;

CREATE TABLE IF NOT EXISTS users (
user_id varchar NOT NULL UNIQUE,
first_name varchar NOT NULL,
last_name varchar NOT NULL,
email varchar NOT NULL,
phone varchar, --potentially make phone/address required (NOT NULL)
address varchar,
profile_picture varchar,
device_id varchar, --expoPushToken for push notifications
push_notification_enabled BOOLEAN DEFAULT FALSE,
PRIMARY KEY (user_id)
);

INSERT INTO users (user_id, first_name, last_name, email, phone, address, profile_picture)
VALUES
-- Care-Wallet Team
('fIoFY26mJnYWH8sNdfuVoxpnVnr1', 'Matt', 'McCoy', '[email protected]', '', '', 'fIoFY26mJnYWH8sNdfuVoxpnVnr1-IMG_1384.jpeg'),
('JamnX6TZf0dt6juozMRzNG5LMQd2', 'Andy', 'Cap', '[email protected]', '', '', 'JamnX6TZf0dt6juozMRzNG5LMQd2-IMG_0916.HEIC'),
('BLq3MXk4rVg4RKuYiMd7aEmMhsz1', 'Ansh', 'Patel', '[email protected]', '', '', 'BLq3MXk4rVg4RKuYiMd7aEmMhsz1-IMG_0585.jpg'),
('mPeo3d3MiXfnpPJADWgFD9ZcB2M2', 'Olivia', 'Sedarski', '[email protected]', '', '', 'mPeo3d3MiXfnpPJADWgFD9ZcB2M2-IMG_5068.jpeg'),
('pTBhZsE9BaOxltkGUfoBAUDote43', 'Louis', 'Rollo', '[email protected]', '', '', 'pTBhZsE9BaOxltkGUfoBAUDote43-IMG_3341.jpg'),
('8Sy7xBkGiGQv4ZKphcQfY8PxAqw1', 'Narayan', 'Sharma', '[email protected]', '', '', '8Sy7xBkGiGQv4ZKphcQfY8PxAqw1-IMG_1777.JPG'),
('iL7PnjS4axQffmlPceobjUUZ9DF2', 'Caitlin', 'Flynn', '[email protected]', '', '', 'iL7PnjS4axQffmlPceobjUUZ9DF2-IMG_2428.jpg'),
('5JgN2PQxCRM9VoCiiFPlQPNqkL32', 'Linwood', 'Blaisdell', '[email protected]', '', '', '5JgN2PQxCRM9VoCiiFPlQPNqkL32-IMG_6884.jpg'),
('P03ggWcw63N0RSY7ltbkeBoR6bd2', 'Chris', 'Wyatt', '[email protected]', '', '', 'P03ggWcw63N0RSY7ltbkeBoR6bd2-IMG_1597.jpeg'),
('9rIMSUo6qNf8ToTABkCfNqnByRv1', 'Haley', 'Martin', '[email protected]', '', '', '9rIMSUo6qNf8ToTABkCfNqnByRv1-IMG_8603.jpg')
-- End Care-Wallet Team
;
48 changes: 48 additions & 0 deletions backend/db/simulation/2.group.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
DROP TABLE IF EXISTS care_group;
DROP TABLE IF EXISTS group_roles;

CREATE TYPE role AS ENUM ('PATIENT', 'PRIMARY', 'SECONDARY');

CREATE TABLE IF NOT EXISTS care_group (
group_id serial NOT NULL UNIQUE,
group_name varchar NOT NULL,
date_created timestamp NOT NULL, --do we default current time?
PRIMARY KEY (group_id)
);

CREATE TABLE IF NOT EXISTS group_roles (
group_id integer NOT NULL,
user_id varchar NOT NULL,
role role NOT NULL,
PRIMARY KEY (group_id, user_id),
FOREIGN KEY (group_id) REFERENCES care_group (group_id),
FOREIGN KEY (user_id) REFERENCES users (user_id)
);

INSERT INTO care_group (group_name, date_created)
VALUES
('Smith Family', NOW()),
('Johnson Support Network', NOW()),
('Williams Care Team', NOW()),
('Brown Medical Group', NOW()),

-- Care-Wallet Team
('We <3 Old People', NOW())
-- End Care-Wallet Team
;

INSERT INTO group_roles (group_id, user_id, role)
VALUES
-- Care-Wallet Team
(5, 'fIoFY26mJnYWH8sNdfuVoxpnVnr1', 'PRIMARY'),
(5, 'JamnX6TZf0dt6juozMRzNG5LMQd2', 'PRIMARY'),
(5, '5JgN2PQxCRM9VoCiiFPlQPNqkL32', 'PATIENT'),
(5, 'BLq3MXk4rVg4RKuYiMd7aEmMhsz1', 'SECONDARY'),
(5, 'mPeo3d3MiXfnpPJADWgFD9ZcB2M2', 'SECONDARY'),
(5, 'pTBhZsE9BaOxltkGUfoBAUDote43', 'SECONDARY'),
(5, '8Sy7xBkGiGQv4ZKphcQfY8PxAqw1', 'SECONDARY'),
(5, 'iL7PnjS4axQffmlPceobjUUZ9DF2', 'SECONDARY'),
(5, 'P03ggWcw63N0RSY7ltbkeBoR6bd2', 'SECONDARY'),
(5, '9rIMSUo6qNf8ToTABkCfNqnByRv1', 'SECONDARY')
-- End Care-Wallet Team
;
154 changes: 154 additions & 0 deletions backend/db/simulation/3.task.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,154 @@
DROP TABLE IF EXISTS task;
DROP TABLE IF EXISTS task_assignees;
DROP TABLE IF EXISTS task_labels;

CREATE TYPE task_assignment_status AS ENUM ('ACCEPTED', 'DECLINED', 'NOTIFIED');
CREATE TYPE task_status AS ENUM ('INCOMPLETE', 'COMPLETE', 'INPROGRESS',
'OVERDUE', 'TODO');
CREATE TYPE task_type AS ENUM ('med_mgmt', 'dr_appt', 'diet', 'grmg', 'fml_convos', 'shpping', 'activities', 'hlth_ins', 'financial', 'other');

CREATE TABLE IF NOT EXISTS task (
task_id serial NOT NULL,
task_title varchar NOT NULL,
group_id integer NOT NULL,
created_by varchar NOT NULL,
created_date timestamp NOT NULL, -- add default val with current timestamp?
start_date timestamp NOT NULL,
end_date timestamp NOT NULL,
quick_task BOOLEAN DEFAULT FALSE,
notes varchar,
repeating BOOLEAN DEFAULT FALSE,
repeating_interval varchar,
repeating_end_date timestamp,
task_status task_status NOT NULL,
task_type task_type NOT NULL, -- (eg. medication management, dr appointment, etc.)
task_info json,
PRIMARY KEY (task_id),
FOREIGN KEY (group_id) REFERENCES care_group (group_id),
FOREIGN KEY (created_by) REFERENCES users (user_id)
);

CREATE TABLE IF NOT EXISTS task_assignees (
task_id integer NOT NULL,
user_id varchar NOT NULL,
assignment_status task_assignment_status NOT NULL,
assigned_by varchar NOT NULL,
assigned_date timestamp NOT NULL, -- add default val with current timestamp?
last_notified timestamp,
PRIMARY KEY (task_id, user_id),
FOREIGN KEY (task_id) REFERENCES task (task_id),
FOREIGN KEY (user_id) REFERENCES users (user_id),
FOREIGN KEY (assigned_by) REFERENCES users (user_id)
);

-- Insert tasks for Matt McCoy
INSERT INTO task (task_title, group_id, created_by, created_date, start_date, end_date, notes, task_status, task_type, quick_task)
VALUES
('Take Care of Grandpa', 5, 'fIoFY26mJnYWH8sNdfuVoxpnVnr1', '2020-02-05 11:00:00', '2024-04-19 23:00:00', '2024-04-19 24:00:00', 'Grandpa Needs His Medicine', 'INPROGRESS', 'financial', FALSE),
('Grocery Shopping', 5, 'fIoFY26mJnYWH8sNdfuVoxpnVnr1', '2020-02-06 09:00:00', '2024-04-20 14:00:00', '2024-04-20 15:00:00', 'Buy groceries for the week', 'TODO', 'other', FALSE),
('Prepare Presentation', 5, 'fIoFY26mJnYWH8sNdfuVoxpnVnr1', '2020-02-07 13:00:00', '2024-04-21 10:00:00', '2024-04-21 12:00:00', 'Prepare slides for the team meeting', 'TODO', 'med_mgmt', FALSE)
;

-- Insert tasks for Andy Cap
INSERT INTO task (task_title, group_id, created_by, created_date, start_date, end_date, notes, task_status, task_type, quick_task)
VALUES
('Call Client', 5, 'JamnX6TZf0dt6juozMRzNG5LMQd2', '2020-02-08 10:00:00', '2024-04-19 09:30:00', '2024-04-19 10:00:00', 'Discuss project updates with the client', 'INPROGRESS', 'med_mgmt', FALSE),
('Review Report', 5, 'JamnX6TZf0dt6juozMRzNG5LMQd2', '2020-02-09 14:00:00', '2024-04-20 09:00:00', '2024-04-20 11:00:00', 'Review quarterly financial report', 'TODO', 'financial', FALSE),
('Send Email', 5, 'JamnX6TZf0dt6juozMRzNG5LMQd2', '2020-02-10 16:00:00', '2024-04-19 12:00:00', '2024-04-19 13:00:00', 'Send follow-up email to the team', 'TODO', 'dr_appt', FALSE)
;

-- Insert tasks for Ansh Patel
INSERT INTO task (task_title, group_id, created_by, created_date, start_date, end_date, notes, task_status, task_type, quick_task)
VALUES
('Attend Meeting', 5, 'BLq3MXk4rVg4RKuYiMd7aEmMhsz1', '2020-02-11 09:00:00', '2024-04-19 09:30:00', '2024-04-19 10:30:00', 'Attend weekly team meeting', 'TODO', 'dr_appt', FALSE),
('Exercise', 5, 'BLq3MXk4rVg4RKuYiMd7aEmMhsz1', '2020-02-12 07:00:00', '2024-04-20 07:30:00', '2024-04-20 08:30:00', 'Morning jog', 'TODO', 'financial', FALSE),
('Submit Expense Report', 5, 'BLq3MXk4rVg4RKuYiMd7aEmMhsz1', '2020-02-13 15:00:00', '2024-04-21 13:00:00', '2024-04-21 14:00:00', 'Submit expenses for reimbursement', 'TODO', 'financial', FALSE)
;

-- Insert tasks for Olivia Sedarski
INSERT INTO task (task_title, group_id, created_by, created_date, start_date, end_date, notes, task_status, task_type, quick_task)
VALUES
('Read Book', 5, 'mPeo3d3MiXfnpPJADWgFD9ZcB2M2', '2020-02-14 10:00:00', '2024-04-20 12:00:00', '2024-04-20 12:00:00', 'Read new novel', 'TODO', 'med_mgmt', FALSE),
('Attend Webinar', 5, 'mPeo3d3MiXfnpPJADWgFD9ZcB2M2', '2020-02-15 13:00:00', '2024-04-19 15:30:00', '2024-04-19 17:00:00', 'Attend webinar on project management', 'TODO', 'other', FALSE),
('Call Family', 5, 'mPeo3d3MiXfnpPJADWgFD9ZcB2M2', '2020-02-16 18:00:00', '2024-04-20 18:30:00', '2024-04-20 19:00:00', 'Catch up with family', 'TODO', 'financial', FALSE)
;

-- Insert tasks for Danny Rollo
INSERT INTO task (task_title, group_id, created_by, created_date, start_date, end_date, notes, task_status, task_type, quick_task)
VALUES
('Workout', 5, 'pTBhZsE9BaOxltkGUfoBAUDote43', '2020-02-17 08:00:00', '2024-04-19 08:30:00', '2024-04-19 09:30:00', 'Gym session', 'TODO', 'financial', FALSE),
('Update Resume', 5, 'pTBhZsE9BaOxltkGUfoBAUDote43', '2020-02-18 11:00:00', '2024-04-20 08:30:00', '2024-04-20 09:30:00', 'Add recent achievements', 'TODO', 'other', TRUE),
('Grocery Shopping', 5, 'pTBhZsE9BaOxltkGUfoBAUDote43', '2020-02-19 14:00:00', '2024-04-19 14:30:00', '2024-04-19 15:30:00', 'Buy groceries for the week', 'TODO', 'other', FALSE)
;

-- Insert tasks for Narayan Sharma
INSERT INTO task (task_title, group_id, created_by, created_date, start_date, end_date, notes, task_status, task_type, quick_task)
VALUES
('Sit with Grandpa', 5, '8Sy7xBkGiGQv4ZKphcQfY8PxAqw1', '2020-02-17 08:00:00', '2024-04-19 22:30:00', '2024-04-19 23:30:00', 'Gym session', 'TODO', 'financial', FALSE),
('Grandpas Sheets', 5, '8Sy7xBkGiGQv4ZKphcQfY8PxAqw1', '2020-02-18 11:00:00', '2024-04-20 10:00:00', '2024-04-20 12:00:00', 'Add recent achievements', 'TODO', 'med_mgmt', TRUE),
('Grandpa Laundry', 5, '8Sy7xBkGiGQv4ZKphcQfY8PxAqw1', '2020-02-19 14:00:00', '2024-04-20 14:30:00', '2024-04-20 15:30:00', 'Buy groceries for the week', 'TODO', 'other', FALSE)
;

-- Insert tasks for Caitlin Flynn
INSERT INTO task (task_title, group_id, created_by, created_date, start_date, end_date, notes, task_status, task_type, quick_task)
VALUES
('Eat with Grandpa', 5, 'iL7PnjS4axQffmlPceobjUUZ9DF2', '2020-02-17 08:00:00', '2024-04-19 10:30:00', '2024-04-19 11:30:00', 'Gym session', 'TODO', 'financial', FALSE),
('Take a walk with grandpa', 5, 'iL7PnjS4axQffmlPceobjUUZ9DF2', '2020-02-18 11:00:00', '2024-04-20 10:00:00', '2024-04-20 12:00:00', 'Add recent achievements', 'TODO', 'med_mgmt', FALSE),
('Grocery Shopping', 5, 'iL7PnjS4axQffmlPceobjUUZ9DF2', '2020-02-19 14:00:00', '2024-04-19 14:30:00', '2024-04-19 15:30:00', 'Buy groceries for the week', 'TODO', 'other', FALSE)
;

-- Insert tasks for Chris Wyatt
INSERT INTO task (task_title, group_id, created_by, created_date, start_date, end_date, notes, task_status, task_type, quick_task)
VALUES
('Take a walk', 5, 'P03ggWcw63N0RSY7ltbkeBoR6bd2', '2020-02-17 08:00:00', '2024-04-19 20:30:00', '2024-04-19 21:30:00', 'Gym session', 'TODO', 'financial', FALSE),
('Get medicine', 5, 'P03ggWcw63N0RSY7ltbkeBoR6bd2', '2020-02-18 11:00:00', '2024-04-19 10:00:00', '2024-04-19 12:00:00', 'Add recent achievements', 'TODO', 'med_mgmt', FALSE),
('Grocery Shopping', 5, 'P03ggWcw63N0RSY7ltbkeBoR6bd2', '2020-02-19 14:00:00', '2024-04-19 14:30:00', '2024-04-18 15:30:00', 'Buy groceries for the week', 'TODO', 'other', FALSE)
;

-- Insert tasks for Hayley Martin
INSERT INTO task (task_title, group_id, created_by, created_date, start_date, end_date, notes, task_status, task_type, quick_task)
VALUES
('Get a snack', 5, '9rIMSUo6qNf8ToTABkCfNqnByRv1', '2020-02-17 08:00:00', '2024-04-19 08:30:00', '2024-04-19 09:30:00', 'Gym session', 'TODO', 'financial', FALSE),
('listen to music with grandpa', 5, '9rIMSUo6qNf8ToTABkCfNqnByRv1', '2020-02-18 11:00:00', '2024-04-22 10:00:00', '2024-04-22 12:00:00', 'Add recent achievements', 'TODO', 'med_mgmt', FALSE),
('Grocery Shopping', 5, '9rIMSUo6qNf8ToTABkCfNqnByRv1', '2020-02-19 14:00:00', '2024-04-22 14:30:00', '2024-04-22 15:30:00', 'Buy groceries for the week', 'TODO', 'other', FALSE)
;


INSERT INTO task_assignees (task_id, user_id, assignment_status, assigned_by, assigned_date)
VALUES
(1, 'fIoFY26mJnYWH8sNdfuVoxpnVnr1', 'ACCEPTED', 'fIoFY26mJnYWH8sNdfuVoxpnVnr1', NOW()),
(2, 'fIoFY26mJnYWH8sNdfuVoxpnVnr1', 'ACCEPTED', 'fIoFY26mJnYWH8sNdfuVoxpnVnr1', NOW()),
(3, 'fIoFY26mJnYWH8sNdfuVoxpnVnr1', 'ACCEPTED', 'fIoFY26mJnYWH8sNdfuVoxpnVnr1', NOW()),

(4, 'JamnX6TZf0dt6juozMRzNG5LMQd2', 'ACCEPTED', 'JamnX6TZf0dt6juozMRzNG5LMQd2', NOW()),
(5, 'JamnX6TZf0dt6juozMRzNG5LMQd2', 'ACCEPTED', 'JamnX6TZf0dt6juozMRzNG5LMQd2', NOW()),
(6, 'JamnX6TZf0dt6juozMRzNG5LMQd2', 'ACCEPTED', 'JamnX6TZf0dt6juozMRzNG5LMQd2', NOW()),

(7, 'BLq3MXk4rVg4RKuYiMd7aEmMhsz1', 'ACCEPTED', 'BLq3MXk4rVg4RKuYiMd7aEmMhsz1', NOW()),
(8, 'BLq3MXk4rVg4RKuYiMd7aEmMhsz1', 'ACCEPTED', 'BLq3MXk4rVg4RKuYiMd7aEmMhsz1', NOW()),
(9, 'BLq3MXk4rVg4RKuYiMd7aEmMhsz1', 'ACCEPTED', 'BLq3MXk4rVg4RKuYiMd7aEmMhsz1', NOW()),

(10, 'mPeo3d3MiXfnpPJADWgFD9ZcB2M2', 'ACCEPTED', 'mPeo3d3MiXfnpPJADWgFD9ZcB2M2', NOW()),
(11, 'mPeo3d3MiXfnpPJADWgFD9ZcB2M2', 'ACCEPTED', 'mPeo3d3MiXfnpPJADWgFD9ZcB2M2', NOW()),
(12, 'mPeo3d3MiXfnpPJADWgFD9ZcB2M2', 'ACCEPTED', 'mPeo3d3MiXfnpPJADWgFD9ZcB2M2', NOW()),

(13, 'pTBhZsE9BaOxltkGUfoBAUDote43', 'ACCEPTED', 'pTBhZsE9BaOxltkGUfoBAUDote43', NOW()),
(14, 'pTBhZsE9BaOxltkGUfoBAUDote43', 'ACCEPTED', 'pTBhZsE9BaOxltkGUfoBAUDote43', NOW()),
(15, 'pTBhZsE9BaOxltkGUfoBAUDote43', 'ACCEPTED', 'pTBhZsE9BaOxltkGUfoBAUDote43', NOW()),

(16, '8Sy7xBkGiGQv4ZKphcQfY8PxAqw1', 'ACCEPTED', '8Sy7xBkGiGQv4ZKphcQfY8PxAqw1', NOW()),
(17, '8Sy7xBkGiGQv4ZKphcQfY8PxAqw1', 'ACCEPTED', '8Sy7xBkGiGQv4ZKphcQfY8PxAqw1', NOW()),
(18, '8Sy7xBkGiGQv4ZKphcQfY8PxAqw1', 'ACCEPTED', '8Sy7xBkGiGQv4ZKphcQfY8PxAqw1', NOW()),

(19, 'iL7PnjS4axQffmlPceobjUUZ9DF2', 'ACCEPTED', 'iL7PnjS4axQffmlPceobjUUZ9DF2', NOW()),
(20, 'iL7PnjS4axQffmlPceobjUUZ9DF2', 'ACCEPTED', 'iL7PnjS4axQffmlPceobjUUZ9DF2', NOW()),
(21, 'iL7PnjS4axQffmlPceobjUUZ9DF2', 'ACCEPTED', 'iL7PnjS4axQffmlPceobjUUZ9DF2', NOW()),

(22, 'P03ggWcw63N0RSY7ltbkeBoR6bd2', 'ACCEPTED', 'P03ggWcw63N0RSY7ltbkeBoR6bd2', NOW()),
(23, 'P03ggWcw63N0RSY7ltbkeBoR6bd2', 'ACCEPTED', 'P03ggWcw63N0RSY7ltbkeBoR6bd2', NOW()),
(24, 'P03ggWcw63N0RSY7ltbkeBoR6bd2', 'ACCEPTED', 'P03ggWcw63N0RSY7ltbkeBoR6bd2', NOW()),

(22, '9rIMSUo6qNf8ToTABkCfNqnByRv1', 'ACCEPTED', '9rIMSUo6qNf8ToTABkCfNqnByRv1', NOW()),
(23, '9rIMSUo6qNf8ToTABkCfNqnByRv1', 'ACCEPTED', '9rIMSUo6qNf8ToTABkCfNqnByRv1', NOW()),
(24, '9rIMSUo6qNf8ToTABkCfNqnByRv1', 'ACCEPTED', '9rIMSUo6qNf8ToTABkCfNqnByRv1', NOW())
;
54 changes: 54 additions & 0 deletions backend/db/simulation/4.label.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
DROP TABLE IF EXISTS label;

CREATE TABLE If NOT EXISTS label (
group_id integer NOT NULL,
label_name varchar NOT NULL,
label_color varchar NOT NULL,
PRIMARY KEY (group_id, label_name),
FOREIGN KEY (group_id) REFERENCES care_group (group_id)
);

CREATE TABLE If NOT EXISTS task_labels (
task_id integer NOT NULL,
group_id integer NOT NULL,
label_name varchar NOT NULL,
PRIMARY KEY (task_id, label_name),
FOREIGN KEY (task_id) REFERENCES task (task_id) ON UPDATE CASCADE,
FOREIGN KEY (group_id, label_name) REFERENCES label (group_id, label_name) ON UPDATE CASCADE
);

INSERT INTO label (group_id, label_name, label_color)
VALUES
(5, 'Financial', 'orange'),
(5, 'Appointments', 'green'),
(5, 'Medication', 'red'),
(5, 'Household', 'purple')
;

INSERT INTO task_labels (task_id, group_id, label_name)
VALUES
(1, 5, 'Financial'),
(2, 5, 'Appointments'),
(3, 5, 'Medication'),
(4, 5, 'Financial'),
(5, 5, 'Appointments'),
(6, 5, 'Financial'),
(7, 5, 'Appointments'),
(8, 5, 'Medication'),
(9, 5, 'Appointments'),
(10, 5, 'Financial'),
(11, 5, 'Household'),
(12, 5, 'Financial'),
(13, 5, 'Appointments'),
(14, 5, 'Medication'),
(15, 5, 'Appointments'),
(16, 5, 'Financial'),
(17, 5, 'Household'),
(18, 5, 'Financial'),
(19, 5, 'Appointments'),
(20, 5, 'Financial'),
(21, 5, 'Household'),
(22, 5, 'Financial'),
(23, 5, 'Appointments'),
(24, 5, 'Financial')
;
17 changes: 17 additions & 0 deletions backend/db/simulation/5.files.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
DROP TABLE IF EXISTS files;

CREATE TABLE IF NOT EXISTS files (
file_id serial NOT NULL UNIQUE,
file_name varchar NOT NULL,
group_id integer NOT NULL,
upload_by varchar NOT NULL,
upload_date timestamp,
file_size integer NOT NULL,
task_id integer,
notes varchar,
label_name varchar,
PRIMARY KEY (file_id),
FOREIGN KEY (group_id) REFERENCES care_group (group_id),
FOREIGN KEY (upload_by) REFERENCES users (user_id),
FOREIGN KEY (task_id) REFERENCES task (task_id)
);
2 changes: 1 addition & 1 deletion client/components/Dropdown.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export function CWDropdown({
<View className="mb-3 bg-carewallet-white">
{isOpen && (
<View className="absolute bottom-14 z-50 flex flex-row flex-wrap rounded-lg border border-carewallet-blue/20 bg-carewallet-white">
{selected !== 'Select Label' && (
{selected !== 'Select' && (
<View
className="h-14 w-full justify-center rounded-lg border-t border-carewallet-blue/20"
onTouchEnd={() => {
Expand Down
Loading
Loading