generated from purwadhikafullstack/finpro-nextjs-express-prisma
-
Notifications
You must be signed in to change notification settings - Fork 2
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 #1 from AnakUtara/feat/admin-dashboard/riady
Feat/admin dashboard/riady
- Loading branch information
Showing
190 changed files
with
10,384 additions
and
601 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,10 @@ | ||
NODE_ENV=development | ||
PORT=8000 | ||
DATABASE_URL="mysql://root@localhost:3306/mydb" | ||
DATABASE_URL="mysql://root:D4nau$unter@localhost:3306/online_groceries" | ||
CORS=http://localhost:3000 | ||
ACC_SECRET_KEY=finpro-akses | ||
REFR_SECRET_KEY=finpro-refresh | ||
FP_SECRET_KEY=finpro-forgot | ||
VERIF_SECRET_KEY=finpro-verif | ||
|
||
RAJAONGKIR_API_KEY='84d2023f491aa0b631bbf096b319d4a7' |
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
Empty file.
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,16 @@ | ||
import { Prisma } from '@prisma/client'; | ||
|
||
export const categories: Prisma.CategoryCreateManyInput[] = [ | ||
{ id: 1, name: 'Sayur', created_at: new Date(), updated_at: new Date() }, | ||
{ id: 2, name: 'Buah', created_at: new Date(), updated_at: new Date() }, | ||
{ id: 3, name: 'Protein', created_at: new Date(), updated_at: new Date() }, | ||
{ id: 4, name: 'Sayur', created_at: new Date(), updated_at: new Date() }, | ||
{ id: 5, name: 'Sembako', created_at: new Date(), updated_at: new Date() }, | ||
{ id: 6, name: 'Siap Saji', created_at: new Date(), updated_at: new Date() }, | ||
{ | ||
id: 7, | ||
name: 'Susu & Olahan', | ||
created_at: new Date(), | ||
updated_at: new Date(), | ||
}, | ||
]; |
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,15 @@ | ||
import axios from 'axios'; | ||
|
||
export async function copyCities() { | ||
const res = await axios.get('https://api.rajaongkir.com/starter/city', { | ||
headers: { | ||
key: process.env.RAJAONGKIR_API_KEY, | ||
}, | ||
}); | ||
const { | ||
data: { | ||
rajaongkir: { results }, | ||
}, | ||
} = res; | ||
return results; | ||
} |
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 @@ | ||
export const images = []; |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+13.8 KB
apps/api/prisma/data/images/products/buah/ZepriKiwiGoldImpor-2pcs.webp
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+15.8 KB
apps/api/prisma/data/images/products/buah/ZepriKiwiGoldImpor-6pcs.webp
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+8.34 KB
apps/api/prisma/data/images/products/sayur/TalasBelitungPotong-250g.webp
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+13.6 KB
apps/api/prisma/data/images/products/snacks/oreo-doublestuf-133g.webp
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+5.22 KB
apps/api/prisma/data/images/products/snacks/slim-fit-dark-chocolate.webp
Binary file not shown.
Binary file added
BIN
+5.28 KB
apps/api/prisma/data/images/products/snacks/slim-fit-raisin-cinnamon.webp
Binary file not shown.
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 @@ | ||
export const products = []; |
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,28 @@ | ||
import { StoreSchedule } from '@prisma/client'; | ||
|
||
export const schedule: StoreSchedule[] = [ | ||
{ | ||
id: 'cly5uxlq100020cl5giq7e62r', | ||
name: 'Operational', | ||
start_time: new Date(2024, 3, 7, 9, 0, 0), | ||
end_time: new Date(2024, 3, 7, 18, 0, 0), | ||
created_at: new Date(), | ||
updated_at: new Date(), | ||
}, | ||
{ | ||
id: 'cly5uwfce00010cl59ze5fnh1', | ||
name: 'Setengah hari', | ||
start_time: new Date(2024, 3, 7, 9, 0, 0), | ||
end_time: new Date(2024, 3, 7, 15, 0, 0), | ||
created_at: new Date(), | ||
updated_at: new Date(), | ||
}, | ||
{ | ||
id: 'cly5uv68000000cl5ggdf1crx', | ||
name: 'Libur nasional', | ||
start_time: null, | ||
end_time: null, | ||
created_at: new Date(), | ||
updated_at: new Date(), | ||
}, | ||
]; |
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,81 @@ | ||
import { hashPassword } from '@/libs/bcrypt'; | ||
import { Gender, Role, User } from '@prisma/client'; | ||
|
||
export const users: User[] = [ | ||
{ | ||
id: 'cly5vk76k00000dmg78mgfo4y', | ||
email: '[email protected]', | ||
password: '$2a$12$ONRX/7qOG1nqV8XU7WrLQ.PO11Htfo5Y0aKaWfaEJh.xGmlPGpPwm', | ||
reset_token: null, | ||
is_verified: true, | ||
role: Role.super_admin, | ||
full_name: 'Rama Naufal Alim', | ||
gender: Gender.male, | ||
dob: null, | ||
phone_no: null, | ||
store_id: null, | ||
created_at: new Date(), | ||
updated_at: new Date(), | ||
avatar_id: null, | ||
voucher_id: null, | ||
referral_code: null, | ||
reference_code: null, | ||
}, | ||
{ | ||
id: 'cly5vx4zh00000cju1d1ig61c', | ||
email: '[email protected]', | ||
password: '$2a$12$I/3WZPa1bq3ETdiFOihsjeuZQlIzRYDUJrZHyJkq7nLUEhFHum1Bi', | ||
reset_token: null, | ||
is_verified: true, | ||
role: Role.store_admin, | ||
full_name: 'Be Liau', | ||
gender: Gender.male, | ||
dob: null, | ||
phone_no: null, | ||
store_id: null, | ||
created_at: new Date(), | ||
updated_at: new Date(), | ||
avatar_id: null, | ||
voucher_id: null, | ||
referral_code: null, | ||
reference_code: null, | ||
}, | ||
{ | ||
id: 'cly5vyacc00010cju7mdgd60n', | ||
email: '[email protected]', | ||
password: '$2a$12$kRSKn8F2mQ4K/x.DolwzTOZxYKzdBJYvw31C0FqNCLFg/KBLqKvay', | ||
reset_token: null, | ||
is_verified: false, | ||
role: Role.customer, | ||
full_name: 'An Drew', | ||
gender: Gender.male, | ||
dob: null, | ||
phone_no: null, | ||
store_id: null, | ||
created_at: new Date(), | ||
updated_at: new Date(), | ||
avatar_id: null, | ||
voucher_id: null, | ||
referral_code: null, | ||
reference_code: null, | ||
}, | ||
{ | ||
id: 'cly5w0lzg00020cjugmwqa7zf', | ||
email: '[email protected]', | ||
password: '$2a$12$J0/YV0ZnTXyvj3Ql5J3koeCErpJWKifyZHuYA2idDUm8m9kC5DU32', | ||
reset_token: null, | ||
is_verified: true, | ||
role: Role.customer, | ||
full_name: 'Frangky Sihombing', | ||
gender: Gender.male, | ||
dob: null, | ||
phone_no: null, | ||
store_id: null, | ||
created_at: new Date(), | ||
updated_at: new Date(), | ||
avatar_id: null, | ||
voucher_id: null, | ||
referral_code: 'AzaGE', | ||
reference_code: null, | ||
}, | ||
]; |
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 @@ | ||
export const variants = []; |
Oops, something went wrong.