Skip to content

Commit

Permalink
init databse:
Browse files Browse the repository at this point in the history
  • Loading branch information
xxxfzxxx committed Nov 4, 2022
1 parent 93206d4 commit 812eb1e
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 18 deletions.
Binary file modified src/backend/database/database.db
Binary file not shown.
36 changes: 18 additions & 18 deletions src/backend/database/schema.sql
Original file line number Diff line number Diff line change
Expand Up @@ -36,31 +36,31 @@ CREATE TABLE Reviews (
);

-- TEST
INSERT INTO Users (username, password, email, phone, apt_id)
VALUES ('Zongxian', '12345abcde', '[email protected]', '1234567890', 1);
-- INSERT INTO Users (username, password, email, phone, apt_id)
-- VALUES ('Zongxian', '12345abcde', '[email protected]', '1234567890', 1);

INSERT INTO Users (username, password, email, phone, apt_id)
VALUES ('MonteCarlo', 'qwert#6767', '[email protected]', '9876543210', 2);
-- INSERT INTO Users (username, password, email, phone, apt_id)
-- VALUES ('MonteCarlo', 'qwert#6767', '[email protected]', '9876543210', 2);

INSERT INTO Users (username, password, email, phone, apt_id)
VALUES ('Minh', 'hello123', 'Minh.com', '9876543210', 2);
-- INSERT INTO Users (username, password, email, phone, apt_id)
-- VALUES ('Minh', 'hello123', 'Minh.com', '9876543210', 2);

INSERT INTO Apartments (apt_name, apt_address, price_min, price_max, link)
VALUES ('The Dean Campustown', '708 S 6th St, Champaign, IL 61820', 860, 1900, 'https://www.apartmentfinder.com/Illinois/Champaign-Apartments/The-Dean-Campustown-Apartments-ttrtct8');
-- INSERT INTO Apartments (apt_name, apt_address, price_min, price_max, link)
-- VALUES ('The Dean Campustown', '708 S 6th St, Champaign, IL 61820', 860, 1900, 'https://www.apartmentfinder.com/Illinois/Champaign-Apartments/The-Dean-Campustown-Apartments-ttrtct8');

INSERT INTO Apartments (apt_name, apt_address, price_min, price_max, link)
VALUES ('Seven07 Apartments', '707 S 4th St, Champaign, IL 61820', 856, 1750, 'https://www.apartmentfinder.com/Illinois/Champaign-Apartments/Seven07-Apartments-75ckgzx');
-- INSERT INTO Apartments (apt_name, apt_address, price_min, price_max, link)
-- VALUES ('Seven07 Apartments', '707 S 4th St, Champaign, IL 61820', 856, 1750, 'https://www.apartmentfinder.com/Illinois/Champaign-Apartments/Seven07-Apartments-75ckgzx');

INSERT INTO AptPics (apt_id, link)
VALUES (2, 'https://image1.apartmentfinder.com/i2/yI_vOGHFLSjSR7fuXTtN6vEcPux3OoeLbY-pKtkIda8/116/seven07-champaign-il-4-br-4-ba---living-room.jpg');
-- INSERT INTO AptPics (apt_id, link)
-- VALUES (2, 'https://image1.apartmentfinder.com/i2/yI_vOGHFLSjSR7fuXTtN6vEcPux3OoeLbY-pKtkIda8/116/seven07-champaign-il-4-br-4-ba---living-room.jpg');

INSERT INTO AptPics (apt_id, link)
VALUES (2, 'https://image1.apartmentfinder.com/i2/fU58gLkELEv-9Yoe6T4cecz5HcARTNYp-eA3RtF1wY0/116/seven07-champaign-il-building-photo.jpg');
-- INSERT INTO AptPics (apt_id, link)
-- VALUES (2, 'https://image1.apartmentfinder.com/i2/fU58gLkELEv-9Yoe6T4cecz5HcARTNYp-eA3RtF1wY0/116/seven07-champaign-il-building-photo.jpg');

INSERT INTO Reviews (apt_id, user_id, date_of_rating, comment, vote)
VALUES (1, 1, '2021-09-23', 'Great Apartment, I love it!', 1);
-- INSERT INTO Reviews (apt_id, user_id, date_of_rating, comment, vote)
-- VALUES (1, 1, '2021-09-23', 'Great Apartment, I love it!', 1);

INSERT INTO Reviews (apt_id, user_id, date_of_rating, comment, vote)
VALUES (2, 2, '2021-09-23', 'Shit Apartment, I hate it!', -1);
-- INSERT INTO Reviews (apt_id, user_id, date_of_rating, comment, vote)
-- VALUES (2, 2, '2021-09-23', 'Shit Apartment, I hate it!', -1);


3 comments on commit 812eb1e

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Coverage

Coverage Report
FileStmtsMissCoverMissing
app.py847412%18–152
dataholders
   apt.py90100% 
   review.py70100% 
pages
   login.py311745%27–55, 60–65
   mainpage.py866129%20–36, 41–53, 61–79, 85–100, 106–121, 128–148, 153–159, 166–188, 193–201, 205–212
TOTAL21715230% 

Tests Skipped Failures Errors Time
1 0 💤 0 ❌ 1 🔥 0.461s ⏱️

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Coverage

Coverage Report
FileStmtsMissCover
app.py840100%
dataholders
   apt.py90100%
   review.py70100%
pages
   login.py310100%
   mainpage.py860100%
TOTAL2170100%

Tests Skipped Failures Errors Time
44 0 💤 0 ❌ 0 🔥 0.838s ⏱️

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Coverage

Coverage Report
FileStmtsMissCover
app.py840100%
dataholders
   apt.py90100%
   review.py70100%
pages
   login.py310100%
   mainpage.py860100%
TOTAL2170100%

Tests Skipped Failures Errors Time
44 0 💤 0 ❌ 0 🔥 0.952s ⏱️

Please sign in to comment.