Skip to content

Commit

Permalink
Fix issue in migration script
Browse files Browse the repository at this point in the history
  • Loading branch information
koredefashokun committed Jun 22, 2020
1 parent 9078747 commit 4a42fc8
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
11 changes: 10 additions & 1 deletion app/src/components/RecentOrders.tsx
Expand Up @@ -24,7 +24,16 @@ const RecentOrders = () => {

return (
<View>
<Text>RecentOrders</Text>
<Text
style={{
fontSize: 18,
fontWeight: '500',
color: '#505050',
marginLeft: 20
}}
>
Recent Orders
</Text>
<FlatList
data={data?.userOrders}
keyExtractor={({ id }) => id}
Expand Down
2 changes: 1 addition & 1 deletion server/migrations.sql
Expand Up @@ -50,7 +50,7 @@ CREATE TABLE IF NOT EXISTS orders (
status order_status DEFAULT 'Pending',
created_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
updated_at TIMESTAMPTZ NOT NULL DEFAULT NOW(),
FOREIGN KEY (user_id) REFERENCES users (id) ON DELETE CASCADE
FOREIGN KEY (user_id) REFERENCES users (id) ON DELETE CASCADE,
FOREIGN KEY (store_id) REFERENCES stores (id) ON DELETE CASCADE
);

Expand Down

0 comments on commit 4a42fc8

Please sign in to comment.