Update Versi 1.5.27 #32
15
.eslintrc.mjs
Normal file
15
.eslintrc.mjs
Normal file
@@ -0,0 +1,15 @@
|
||||
import { FlatCompat } from "@eslint/eslintrc";
|
||||
import path from "node:path";
|
||||
import { fileURLToPath } from "node:url";
|
||||
|
||||
const __filename = fileURLToPath(import.meta.url);
|
||||
const __dirname = path.dirname(__filename);
|
||||
|
||||
const compat = new FlatCompat({
|
||||
baseDirectory: __dirname,
|
||||
});
|
||||
|
||||
const config = compat.extends("next/core-web-vitals", "next/typescript");
|
||||
console.log(config); // Cek output di terminal
|
||||
|
||||
export default Array.isArray(config) ? config : [config];
|
||||
33
.gitignore
vendored
33
.gitignore
vendored
@@ -21,21 +21,48 @@
|
||||
|
||||
# debug
|
||||
npm-debug.log*
|
||||
|
||||
rn-debug.log*
|
||||
yarn-debug.log*
|
||||
yarn-error.log*
|
||||
|
||||
# local env files
|
||||
.env*.local
|
||||
|
||||
# build env files
|
||||
.env*.build
|
||||
|
||||
# env here
|
||||
.env
|
||||
|
||||
# vercel
|
||||
.vercel
|
||||
|
||||
# logs - mengabaikan isi logs tetapi menyimpan struktur folder
|
||||
logs/*
|
||||
!logs/.gitkeep
|
||||
!logs/backend/
|
||||
!logs/frontend/
|
||||
logs/backend/*
|
||||
!logs/backend/.gitkeep
|
||||
logs/frontend/*
|
||||
!logs/frontend/.gitkeep
|
||||
|
||||
# typescript
|
||||
*.tsbuildinfo
|
||||
next-env.d.ts
|
||||
|
||||
certificates
|
||||
# certificates
|
||||
certificates/
|
||||
**/certificates/
|
||||
*.cert
|
||||
*.key
|
||||
*.pem
|
||||
|
||||
# IDE and editor files
|
||||
.idea/
|
||||
.vscode/
|
||||
*.swp
|
||||
*.swo
|
||||
*.swn
|
||||
.DS_Store
|
||||
Thumbs.db
|
||||
.qodo
|
||||
|
||||
4
.vscode/settings.json
vendored
4
.vscode/settings.json
vendored
@@ -1,4 +0,0 @@
|
||||
{
|
||||
"WillLuke.nextjs.addTypesOnSave": true,
|
||||
"WillLuke.nextjs.hasPrompted": true
|
||||
}
|
||||
637
CHANGELOG.md
637
CHANGELOG.md
@@ -2,6 +2,643 @@
|
||||
|
||||
All notable changes to this project will be documented in this file. See [commit-and-tag-version](https://github.com/absolute-version/commit-and-tag-version) for commit guidelines.
|
||||
|
||||
## [1.5.27](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.26...v1.5.27) (2025-12-17)
|
||||
|
||||
## [1.5.26](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.25...v1.5.26) (2025-12-10)
|
||||
|
||||
## [1.5.25](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.24...v1.5.25) (2025-12-09)
|
||||
|
||||
## [1.5.24](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.22...v1.5.24) (2025-12-08)
|
||||
|
||||
## [1.5.22](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.21...v1.5.22) (2025-12-03)
|
||||
|
||||
## [1.5.21](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.20...v1.5.21) (2025-12-03)
|
||||
|
||||
## [1.5.20](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.19...v1.5.20) (2025-12-02)
|
||||
|
||||
## [1.5.19](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.18...v1.5.19) (2025-12-01)
|
||||
|
||||
## [1.5.18](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.17...v1.5.18) (2025-11-28)
|
||||
|
||||
## [1.5.17](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.16...v1.5.17) (2025-11-24)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* delete all data user ([fb9515d](https://wibugit.wibudev.com/wibu/hipmi/commit/fb9515dfe465ef07d43460ca4e9bb31705ec48b8))
|
||||
|
||||
## [1.5.16](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.15...v1.5.16) (2025-11-20)
|
||||
|
||||
## [1.5.15](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.14...v1.5.15) (2025-11-18)
|
||||
|
||||
## [1.5.14](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.13...v1.5.14) (2025-11-17)
|
||||
|
||||
## [1.5.13](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.12...v1.5.13) (2025-11-17)
|
||||
|
||||
## [1.5.12](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.10...v1.5.12) (2025-11-13)
|
||||
|
||||
## [1.5.11](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.4.45...v1.5.11) (2025-11-07)
|
||||
|
||||
## [1.5.10](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.9...v1.5.10) (2025-11-03)
|
||||
|
||||
## [1.5.9](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.8...v1.5.9) (2025-10-30)
|
||||
|
||||
## [1.5.8](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.7...v1.5.8) (2025-10-29)
|
||||
|
||||
## [1.5.7](https://wibugit.wibudev.com/wibu/hipmi/compare/v1.5.6...v1.5.7) (2025-10-28)
|
||||
|
||||
## [1.5.6](https://wibugit.wibudev.com/bip/hipmi/compare/v1.5.5...v1.5.6) (2025-10-21)
|
||||
|
||||
## [1.5.5](https://wibugit.wibudev.com/bip/hipmi/compare/v1.5.4...v1.5.5) (2025-10-20)
|
||||
|
||||
## [1.5.4](https://wibugit.wibudev.com/bip/hipmi/compare/v1.5.3...v1.5.4) (2025-10-17)
|
||||
|
||||
## [1.5.3](https://wibugit.wibudev.com/bip/hipmi/compare/v1.5.2...v1.5.3) (2025-10-16)
|
||||
|
||||
## [1.5.2](https://wibugit.wibudev.com/bip/hipmi/compare/v1.5.1...v1.5.2) (2025-10-15)
|
||||
|
||||
## [1.5.1](https://wibugit.wibudev.com/bip/hipmi/compare/v1.5.0...v1.5.1) (2025-10-14)
|
||||
|
||||
## 1.5.0 (2025-10-09)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* admin app information ([bc10b80](https://wibugit.wibudev.com/bip/hipmi/commit/bc10b80139833966d3e39b52cabf577930552052))
|
||||
* admin sticker ([2a8c79f](https://wibugit.wibudev.com/bip/hipmi/commit/2a8c79fd09c3f7fd7ee58ac6896b17802dfe0147))
|
||||
* admin stiker ([e7858a2](https://wibugit.wibudev.com/bip/hipmi/commit/e7858a281223a81037219afec58e5f6b9e04be15))
|
||||
* **app / dev / login:** membuat page login ([91333b5](https://wibugit.wibudev.com/bip/hipmi/commit/91333b5c00b87da35a0d965f0678ff971484825b))
|
||||
* **app / dev / page:** modified file ([90c32b3](https://wibugit.wibudev.com/bip/hipmi/commit/90c32b345c1099c943a9b8f67b8aa257941484d9))
|
||||
* **app / dev / register:** membuat page register ([1e06aeb](https://wibugit.wibudev.com/bip/hipmi/commit/1e06aeb6998f00d77fa74849de11be182a0be676))
|
||||
* **dashboard admin:** membuat dashboard admin ([46da772](https://wibugit.wibudev.com/bip/hipmi/commit/46da772f3895bde770942c3d9044e6da0620ef1c))
|
||||
* **dashboard super admin:** membuat dashboard super admin ([c363736](https://wibugit.wibudev.com/bip/hipmi/commit/c3637366f9ebf24507c470714952ad2e572a0b0d))
|
||||
* **image:** menambahkan gambar logo ([c74bb6e](https://wibugit.wibudev.com/bip/hipmi/commit/c74bb6eceb401c55c3c297889fe43181406f3a22))
|
||||
* **landing page:** buat komponen landing page ([38cb10d](https://wibugit.wibudev.com/bip/hipmi/commit/38cb10da4ac8d68f1abd0163a0671036c15e1743))
|
||||
* **login:** - Membuat login page - Membuat register page ([b6cc83c](https://wibugit.wibudev.com/bip/hipmi/commit/b6cc83c004cacb2289c51491fce7ebc2b29e126f))
|
||||
* **src/app/page:** mengedit page ([ca66fde](https://wibugit.wibudev.com/bip/hipmi/commit/ca66fde1dc6751f3749cb1d582f7bbd299241318))
|
||||
* tambah dependensi 'jose' versi 5.9.2 pada package.json ([6ee43ed](https://wibugit.wibudev.com/bip/hipmi/commit/6ee43ed20faa273cbca0be948295e95d36bbd760))
|
||||
* tampilan upload stiker di admin ([fbea35e](https://wibugit.wibudev.com/bip/hipmi/commit/fbea35eef96a656e1b474959aa3fb8198c7d2b0e))
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* admin ([604077c](https://wibugit.wibudev.com/bip/hipmi/commit/604077cc8dda568951fa1cd1b8ddfe862e1d321d))
|
||||
* Admin ([74108c3](https://wibugit.wibudev.com/bip/hipmi/commit/74108c30969bd2c607b51f302209de91430e7792))
|
||||
* admin app info ([117dbe6](https://wibugit.wibudev.com/bip/hipmi/commit/117dbe6157fbb74d359db1c8baffe3c4985fab4a))
|
||||
* admin app info ([0cbcee8](https://wibugit.wibudev.com/bip/hipmi/commit/0cbcee87bd52f6a7b596e260841deef9d4615016))
|
||||
* admin collaboration ([039ffc5](https://wibugit.wibudev.com/bip/hipmi/commit/039ffc57b18d24968d854d06cd62fff13b769a6f))
|
||||
* admin donasi ([6ccdbf9](https://wibugit.wibudev.com/bip/hipmi/commit/6ccdbf9763c1ce8443a6a691b24817d6b80265c6))
|
||||
* admin donasi ([d624d61](https://wibugit.wibudev.com/bip/hipmi/commit/d624d61a33069a9c578a1af780bc2229dd3bad96))
|
||||
* admin forum ([aba2585](https://wibugit.wibudev.com/bip/hipmi/commit/aba258517db277fd85d043c3aa4df279a5ec232d))
|
||||
* admin investasi ([9b4a6fd](https://wibugit.wibudev.com/bip/hipmi/commit/9b4a6fdc1c49ea982bb5e166aa8b3f4f40b3a392))
|
||||
* admin job ([3aea046](https://wibugit.wibudev.com/bip/hipmi/commit/3aea0460462e87c30b0e7a939a24aaf5d9ce6978))
|
||||
* admin map ([8cedf7d](https://wibugit.wibudev.com/bip/hipmi/commit/8cedf7db61702dc67300fdd11570022d84b1d857))
|
||||
* Bug ([7e9dfce](https://wibugit.wibudev.com/bip/hipmi/commit/7e9dfce293bda5a4577ea16a4867e340b9883b3f))
|
||||
* button sticker ([3743008](https://wibugit.wibudev.com/bip/hipmi/commit/37430081d8718b4b2b06f5c3c09f13935bf413c4))
|
||||
* collaboration ([5030253](https://wibugit.wibudev.com/bip/hipmi/commit/5030253b07c1264229d066d18732d81e2636c5a6))
|
||||
* collaboration ([740ae44](https://wibugit.wibudev.com/bip/hipmi/commit/740ae447340ce48d168e0e8e7c14079b3cf61817))
|
||||
* collaboration ([bdff760](https://wibugit.wibudev.com/bip/hipmi/commit/bdff760f7021c624f8338da3af2d46c911b1dcff))
|
||||
* collaboration ([5007827](https://wibugit.wibudev.com/bip/hipmi/commit/5007827d51117105b879bf18f06da60db8c48ff4))
|
||||
* Cookies ([038c40a](https://wibugit.wibudev.com/bip/hipmi/commit/038c40a6fbc4062e1c3f1659ec0d1a4ab92205ae))
|
||||
* Cookies ([abaec2c](https://wibugit.wibudev.com/bip/hipmi/commit/abaec2c1c3be2a54975246e89cfe7047c962f2a8))
|
||||
* dashboard admin ([ac432d1](https://wibugit.wibudev.com/bip/hipmi/commit/ac432d1eb7b975d621889b0d2e13e366e806cf56))
|
||||
* Db Profile ([cf9355e](https://wibugit.wibudev.com/bip/hipmi/commit/cf9355e91f623171e7708d37a9ce8590ff473a44))
|
||||
* donasi ([f2c6940](https://wibugit.wibudev.com/bip/hipmi/commit/f2c694022e510ea99726cfffaf06b6cfffb808c1))
|
||||
* donasi ([1f1cca3](https://wibugit.wibudev.com/bip/hipmi/commit/1f1cca3520ff22b878e945383a580b32a3054a3d))
|
||||
* donasi ([e94090e](https://wibugit.wibudev.com/bip/hipmi/commit/e94090eb30c2f34af08816b3c4ad8ac4cbd360e8))
|
||||
* donasi ([bb65042](https://wibugit.wibudev.com/bip/hipmi/commit/bb650429b323670c85adc582eda8ff522bd4dd60))
|
||||
* donasi ([886d9f3](https://wibugit.wibudev.com/bip/hipmi/commit/886d9f37f4636576b8a89020537e13708f582431))
|
||||
* donasi ([709de95](https://wibugit.wibudev.com/bip/hipmi/commit/709de95b10650ae1472b75d73bdd0bf20306633e))
|
||||
* donasi ([9c5f005](https://wibugit.wibudev.com/bip/hipmi/commit/9c5f0053b6b834c67f170767e28dd9e04c5614a4))
|
||||
* donasi ([4fdfb6f](https://wibugit.wibudev.com/bip/hipmi/commit/4fdfb6f4b0548d78a712443ac24e37e933665d41))
|
||||
* donasi ([1b23c50](https://wibugit.wibudev.com/bip/hipmi/commit/1b23c50ff08f2bbb46ecfeec9d0c02c03f9230c1))
|
||||
* donasi ([0e4dda5](https://wibugit.wibudev.com/bip/hipmi/commit/0e4dda5356df96f4dc749c5a7d5613e378eb6096))
|
||||
* donasi ([72b6d23](https://wibugit.wibudev.com/bip/hipmi/commit/72b6d239fee3e90e812ab24192154e5e8910fccb))
|
||||
* Donasi ([517b2bb](https://wibugit.wibudev.com/bip/hipmi/commit/517b2bb9b0e256d31d7a10332a6e7880c58ad48f))
|
||||
* Donasi ([2335807](https://wibugit.wibudev.com/bip/hipmi/commit/2335807b427ee24e7a28ae78a3ca9dae981a79e2))
|
||||
* Donasi ([a798f9a](https://wibugit.wibudev.com/bip/hipmi/commit/a798f9a3bc9996811ca55e70ea407297e1f939d8))
|
||||
* drawer katalog ([eab293d](https://wibugit.wibudev.com/bip/hipmi/commit/eab293dd35a6f061cfa4675679de1ce68f506c3c))
|
||||
* dynamic error ([86bfbcb](https://wibugit.wibudev.com/bip/hipmi/commit/86bfbcb60e225adcba6504869cf8548370fc6750))
|
||||
* event ([6f686b6](https://wibugit.wibudev.com/bip/hipmi/commit/6f686b6abf4ba6201df632938e4024004fe749b3))
|
||||
* event ([02bbdfd](https://wibugit.wibudev.com/bip/hipmi/commit/02bbdfd5f6a2d299b8d527b9211f7b6ff598602f))
|
||||
* event ([fc38813](https://wibugit.wibudev.com/bip/hipmi/commit/fc388133a638d4288314dd3faeddfcce61fe7292))
|
||||
* Event ([45279cd](https://wibugit.wibudev.com/bip/hipmi/commit/45279cd37fb4b2a293012c9cb1a8d6e977d0edb3))
|
||||
* Event ([1f8bfcb](https://wibugit.wibudev.com/bip/hipmi/commit/1f8bfcbed924ec1b53cdcc42393884f554299c5b))
|
||||
* Event ([8f76067](https://wibugit.wibudev.com/bip/hipmi/commit/8f760673804d114c3f04ce65a648fa0ff5962822))
|
||||
* Event ([81543d6](https://wibugit.wibudev.com/bip/hipmi/commit/81543d678cb515b36f8393ee257b8a6a6c4a0834))
|
||||
* File view ([84b7b38](https://wibugit.wibudev.com/bip/hipmi/commit/84b7b381f62d2f69d8b1e9d7c2411175e5d48e38))
|
||||
* forum ([0de70b0](https://wibugit.wibudev.com/bip/hipmi/commit/0de70b038429a63be25b669ef6d8732e2312fd9d))
|
||||
* forum ([42cfe65](https://wibugit.wibudev.com/bip/hipmi/commit/42cfe650b565c02eb7ebf639ecef41c188ad4449))
|
||||
* forum ([512d170](https://wibugit.wibudev.com/bip/hipmi/commit/512d170c3e047848c9b26144533e50720e04950b))
|
||||
* forum admin ([4b8316c](https://wibugit.wibudev.com/bip/hipmi/commit/4b8316cc1311eb88840c029f1dfdb6a43e3a7f4f))
|
||||
* Image donasi ([0371ca5](https://wibugit.wibudev.com/bip/hipmi/commit/0371ca5e0137354bb0d7a89300aa112112cf194d))
|
||||
* investasi ([69c0abe](https://wibugit.wibudev.com/bip/hipmi/commit/69c0abed75cb7b777c7072969e8826663dd32fdc))
|
||||
* investasi ([7a95395](https://wibugit.wibudev.com/bip/hipmi/commit/7a95395fe9861997527d76f08073db8de4ba48aa))
|
||||
* Investasi ([5ff74b0](https://wibugit.wibudev.com/bip/hipmi/commit/5ff74b00f55751cc951b959f2d9bccda403158dc))
|
||||
* investasi: ([5c3fe55](https://wibugit.wibudev.com/bip/hipmi/commit/5c3fe551aeb57bdd24ad616f9cbe37c2d417efca))
|
||||
* Job ([1b58ba7](https://wibugit.wibudev.com/bip/hipmi/commit/1b58ba7d905f490fdba9e1d90e722faf251b2ae3))
|
||||
* Job ([aa612d2](https://wibugit.wibudev.com/bip/hipmi/commit/aa612d24bc7cb729db66841bd3a48379cf875f70))
|
||||
* Job ([30743b0](https://wibugit.wibudev.com/bip/hipmi/commit/30743b02ae0c2d0a83310af05711ed255000c7ce))
|
||||
* loading button tambah portofolio ([8823a01](https://wibugit.wibudev.com/bip/hipmi/commit/8823a01b067928cbeea195402f2bb454df8e8bea))
|
||||
* Map ([f23defd](https://wibugit.wibudev.com/bip/hipmi/commit/f23defd972fbd276fee546677dc5e9565651b4f4))
|
||||
* Map ([56548b4](https://wibugit.wibudev.com/bip/hipmi/commit/56548b425876a7fa9be49f2a290de6a1916609a1))
|
||||
* Middlerawe/1 ([cc690ee](https://wibugit.wibudev.com/bip/hipmi/commit/cc690eec0686e4306a440a8b38fffacb2c2b78c6))
|
||||
* Middlerawe/2 ([ac749f3](https://wibugit.wibudev.com/bip/hipmi/commit/ac749f3d9d348162a2b8e8c88091dce97f9cca27))
|
||||
* Middlerawe/3 ([10dee19](https://wibugit.wibudev.com/bip/hipmi/commit/10dee19f98b011de19a21e9ef4a5282e37ffdf38))
|
||||
* Middlerawe/4 ([0a03b05](https://wibugit.wibudev.com/bip/hipmi/commit/0a03b05d4e0d9c369844859cac8879ba5505efa7))
|
||||
* Middlerawe/5 ([6e5a9f7](https://wibugit.wibudev.com/bip/hipmi/commit/6e5a9f785a06f6b31b6010f8b89dfd146112a44a))
|
||||
* Middlerawe/6 ([b9e4b97](https://wibugit.wibudev.com/bip/hipmi/commit/b9e4b97b31f1f86cd3ee64c1a51827d3d724b1e7))
|
||||
* Middlerawe/7 ([13c855f](https://wibugit.wibudev.com/bip/hipmi/commit/13c855f2f64212857cb6c143f135d2fe160d9ee9))
|
||||
* middleware ([31124c5](https://wibugit.wibudev.com/bip/hipmi/commit/31124c5500d10a4d831c45c0da1a46a1dee995db))
|
||||
* Navbar admin ([6b8ace7](https://wibugit.wibudev.com/bip/hipmi/commit/6b8ace772c54aa00eebf9228da0d1543ed593d2d))
|
||||
* Navbar admin ([5fcb09b](https://wibugit.wibudev.com/bip/hipmi/commit/5fcb09b88906e74c2f2be76f5fd325daa48f5ae5))
|
||||
* nested layout ([c202cc8](https://wibugit.wibudev.com/bip/hipmi/commit/c202cc8ea08ce8cdb351136a47c2afe10afb14c9))
|
||||
* Notifikasi ([82f5b23](https://wibugit.wibudev.com/bip/hipmi/commit/82f5b237ae52dc087711452f4bd6baa7acce8a1f))
|
||||
* pencegahan error ([afe8014](https://wibugit.wibudev.com/bip/hipmi/commit/afe8014cc8b4ab7266f3c52918a6bc82bb62bc58))
|
||||
* Profile ([b13110b](https://wibugit.wibudev.com/bip/hipmi/commit/b13110be6f475df7d5b36909cdc8f92f80a62d57))
|
||||
* super admin ([5bc70ba](https://wibugit.wibudev.com/bip/hipmi/commit/5bc70baf96e792e1e1492027747f8352f2f80313))
|
||||
* test new github ([555b6e7](https://wibugit.wibudev.com/bip/hipmi/commit/555b6e76332d867fc72b51cc1163fd6911a63288))
|
||||
* update version ([3d6ec14](https://wibugit.wibudev.com/bip/hipmi/commit/3d6ec1410d0a54bad35dea2740101aaad589fdd7))
|
||||
* update version in package.json ([ca99de7](https://wibugit.wibudev.com/bip/hipmi/commit/ca99de7dd5a48dca66f33b3d63b6c278e0367c9d))
|
||||
* Upload image ([360ba26](https://wibugit.wibudev.com/bip/hipmi/commit/360ba267ec69404dd45bb7d6510fe6113d9087ab))
|
||||
* Upload image ([370e3ec](https://wibugit.wibudev.com/bip/hipmi/commit/370e3ec4e4c6e1f342c966feb7a65b62a09d2945))
|
||||
* user ([215accb](https://wibugit.wibudev.com/bip/hipmi/commit/215accbcaa989e43f43dfc5f400d5411013f4ef3))
|
||||
* User search & Event ([ca5c304](https://wibugit.wibudev.com/bip/hipmi/commit/ca5c30499a2630e5d8a8c87f569f2b50fa88ad6e))
|
||||
* validasi ([a6548f7](https://wibugit.wibudev.com/bip/hipmi/commit/a6548f7b364e403d5265a0015003021b5c11f004))
|
||||
* version 1.2.10 ([08eed15](https://wibugit.wibudev.com/bip/hipmi/commit/08eed15b798d549146b035ffd9a44cea5e55b283))
|
||||
* version 1.2.11 ([7afcc9c](https://wibugit.wibudev.com/bip/hipmi/commit/7afcc9ced02eafab1df669fd71fdbcd4556bb322))
|
||||
* version 1.2.12 ([932735f](https://wibugit.wibudev.com/bip/hipmi/commit/932735f9238db07b331b1b26328624247371c3d6))
|
||||
* version 1.2.6 ([13142f2](https://wibugit.wibudev.com/bip/hipmi/commit/13142f283d804fead233cf6bff6a41e4732a3ec0))
|
||||
* version 1.2.7 ([1b83de0](https://wibugit.wibudev.com/bip/hipmi/commit/1b83de0189b4581a8511cc58af2de0d5c613646b))
|
||||
* version 1.2.8 ([378b2c1](https://wibugit.wibudev.com/bip/hipmi/commit/378b2c19ff7a7fb07647c6a093d803d299c091f7))
|
||||
* version 1.2.8 ([23edb2d](https://wibugit.wibudev.com/bip/hipmi/commit/23edb2d6317f2a8344ac3190f492f718c05b65c9))
|
||||
* voting ([c057f20](https://wibugit.wibudev.com/bip/hipmi/commit/c057f20963df70f4ce2ac071007541678c6ff854))
|
||||
* Voting ([e65a8d3](https://wibugit.wibudev.com/bip/hipmi/commit/e65a8d30a2a70593f3e4268518ae4c0c542a02dd))
|
||||
* voting status ([9bb68b2](https://wibugit.wibudev.com/bip/hipmi/commit/9bb68b216fc444e390fccf7131af886bc6d12d60))
|
||||
* voting status ([e5e36a3](https://wibugit.wibudev.com/bip/hipmi/commit/e5e36a38893f21037688cd3153a57dc29ce1347e))
|
||||
|
||||
## [1.4.45](https://wibugit.wibudev.com/bip/hipmi/compare/v1.4.44...v1.4.45) (2025-10-06)
|
||||
|
||||
## [1.4.44](https://wibugit.wibudev.com/bip/hipmi/compare/v1.4.43...v1.4.44) (2025-10-02)
|
||||
|
||||
## [1.4.43](https://wibugit.wibudev.com/bip/hipmi/compare/v1.4.42...v1.4.43) (2025-09-29)
|
||||
|
||||
## [1.4.42](https://wibugit.wibudev.com/bip/hipmi/compare/v1.4.41...v1.4.42) (2025-09-24)
|
||||
|
||||
## [1.4.41](https://wibugit.wibudev.com/bip/hipmi/compare/v1.4.40...v1.4.41) (2025-09-23)
|
||||
|
||||
## [1.4.40](https://wibugit.wibudev.com/bip/hipmi/compare/v1.4.39...v1.4.40) (2025-09-22)
|
||||
|
||||
## [1.4.39](https://wibugit.wibudev.com/bip/hipmi/compare/v1.4.38...v1.4.39) (2025-09-19)
|
||||
|
||||
## [1.4.38](https://wibugit.wibudev.com/bip/hipmi/compare/v1.4.37...v1.4.38) (2025-09-18)
|
||||
|
||||
## [1.4.37](https://wibugit.wibudev.com/bip/hipmi/compare/v1.4.36...v1.4.37) (2025-09-16)
|
||||
|
||||
## [1.4.36](https://wibugit.wibudev.com/bip/hipmi/compare/v1.4.35...v1.4.36) (2025-09-15)
|
||||
|
||||
## [1.4.35](https://wibugit.wibudev.com/bip/hipmi/compare/v1.4.34...v1.4.35) (2025-09-12)
|
||||
|
||||
## [1.4.34](https://wibugit.wibudev.com/bip/hipmi/compare/v1.4.33...v1.4.34) (2025-09-01)
|
||||
|
||||
## [1.4.33](https://wibugit.wibudev.com/bip/hipmi/compare/v1.4.32...v1.4.33) (2025-08-29)
|
||||
|
||||
## [1.4.32](https://wibugit.wibudev.com/bip/hipmi/compare/v1.4.31...v1.4.32) (2025-08-29)
|
||||
|
||||
## [1.4.31](https://wibugit.wibudev.com/bip/hipmi/compare/v1.4.30...v1.4.31) (2025-08-27)
|
||||
|
||||
## [1.4.30](https://wibugit.wibudev.com/bip/hipmi/compare/v1.4.29...v1.4.30) (2025-08-26)
|
||||
|
||||
## [1.4.29](https://wibugit.wibudev.com/bip/hipmi/compare/v1.4.28...v1.4.29) (2025-08-25)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* test new github ([555b6e7](https://wibugit.wibudev.com/bip/hipmi/commit/555b6e76332d867fc72b51cc1163fd6911a63288))
|
||||
|
||||
## [1.4.28](https://github.com/bipproduction/hipmi/compare/v1.4.27...v1.4.28) (2025-06-16)
|
||||
|
||||
## [1.4.27](https://github.com/bipproduction/hipmi/compare/v1.4.26...v1.4.27) (2025-06-16)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* dynamic error ([86bfbcb](https://github.com/bipproduction/hipmi/commit/86bfbcb60e225adcba6504869cf8548370fc6750))
|
||||
|
||||
## [1.4.26](https://github.com/bipproduction/hipmi/compare/v1.4.25...v1.4.26) (2025-06-13)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* admin donasi ([6ccdbf9](https://github.com/bipproduction/hipmi/commit/6ccdbf9763c1ce8443a6a691b24817d6b80265c6))
|
||||
* super admin ([5bc70ba](https://github.com/bipproduction/hipmi/commit/5bc70baf96e792e1e1492027747f8352f2f80313))
|
||||
|
||||
## [1.4.25](https://github.com/bipproduction/hipmi/compare/v1.4.24...v1.4.25) (2025-06-12)
|
||||
|
||||
## [1.4.24](https://github.com/bipproduction/hipmi/compare/v1.4.23...v1.4.24) (2025-06-12)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* admin collaboration ([039ffc5](https://github.com/bipproduction/hipmi/commit/039ffc57b18d24968d854d06cd62fff13b769a6f))
|
||||
* admin forum ([aba2585](https://github.com/bipproduction/hipmi/commit/aba258517db277fd85d043c3aa4df279a5ec232d))
|
||||
* forum admin ([4b8316c](https://github.com/bipproduction/hipmi/commit/4b8316cc1311eb88840c029f1dfdb6a43e3a7f4f))
|
||||
|
||||
## [1.4.23](https://github.com/bipproduction/hipmi/compare/v1.4.22...v1.4.23) (2025-06-11)
|
||||
|
||||
## [1.4.22](https://github.com/bipproduction/hipmi/compare/v1.4.21...v1.4.22) (2025-06-11)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* donasi ([f2c6940](https://github.com/bipproduction/hipmi/commit/f2c694022e510ea99726cfffaf06b6cfffb808c1))
|
||||
* donasi ([1f1cca3](https://github.com/bipproduction/hipmi/commit/1f1cca3520ff22b878e945383a580b32a3054a3d))
|
||||
* donasi ([e94090e](https://github.com/bipproduction/hipmi/commit/e94090eb30c2f34af08816b3c4ad8ac4cbd360e8))
|
||||
* donasi ([bb65042](https://github.com/bipproduction/hipmi/commit/bb650429b323670c85adc582eda8ff522bd4dd60))
|
||||
* donasi ([886d9f3](https://github.com/bipproduction/hipmi/commit/886d9f37f4636576b8a89020537e13708f582431))
|
||||
|
||||
## [1.4.21](https://github.com/bipproduction/hipmi/compare/v1.4.20...v1.4.21) (2025-06-10)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* donasi ([709de95](https://github.com/bipproduction/hipmi/commit/709de95b10650ae1472b75d73bdd0bf20306633e))
|
||||
* donasi ([9c5f005](https://github.com/bipproduction/hipmi/commit/9c5f0053b6b834c67f170767e28dd9e04c5614a4))
|
||||
* donasi ([4fdfb6f](https://github.com/bipproduction/hipmi/commit/4fdfb6f4b0548d78a712443ac24e37e933665d41))
|
||||
* donasi ([1b23c50](https://github.com/bipproduction/hipmi/commit/1b23c50ff08f2bbb46ecfeec9d0c02c03f9230c1))
|
||||
* donasi ([0e4dda5](https://github.com/bipproduction/hipmi/commit/0e4dda5356df96f4dc749c5a7d5613e378eb6096))
|
||||
|
||||
## [1.4.20](https://github.com/bipproduction/hipmi/compare/v1.4.19...v1.4.20) (2025-06-05)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* investasi ([69c0abe](https://github.com/bipproduction/hipmi/commit/69c0abed75cb7b777c7072969e8826663dd32fdc))
|
||||
|
||||
## [1.4.19](https://github.com/bipproduction/hipmi/compare/v1.4.18...v1.4.19) (2025-06-04)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* forum ([0de70b0](https://github.com/bipproduction/hipmi/commit/0de70b038429a63be25b669ef6d8732e2312fd9d))
|
||||
* forum ([42cfe65](https://github.com/bipproduction/hipmi/commit/42cfe650b565c02eb7ebf639ecef41c188ad4449))
|
||||
* investasi ([7a95395](https://github.com/bipproduction/hipmi/commit/7a95395fe9861997527d76f08073db8de4ba48aa))
|
||||
* investasi: ([5c3fe55](https://github.com/bipproduction/hipmi/commit/5c3fe551aeb57bdd24ad616f9cbe37c2d417efca))
|
||||
|
||||
## [1.4.18](https://github.com/bipproduction/hipmi/compare/v1.4.17...v1.4.18) (2025-06-03)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* forum ([512d170](https://github.com/bipproduction/hipmi/commit/512d170c3e047848c9b26144533e50720e04950b))
|
||||
|
||||
## [1.4.17](https://github.com/bipproduction/hipmi/compare/v1.4.16...v1.4.17) (2025-06-02)
|
||||
|
||||
## [1.4.16](https://github.com/bipproduction/hipmi/compare/v1.4.15...v1.4.16) (2025-06-02)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* event ([6f686b6](https://github.com/bipproduction/hipmi/commit/6f686b6abf4ba6201df632938e4024004fe749b3))
|
||||
* voting ([c057f20](https://github.com/bipproduction/hipmi/commit/c057f20963df70f4ce2ac071007541678c6ff854))
|
||||
|
||||
## [1.4.15](https://github.com/bipproduction/hipmi/compare/v1.4.14...v1.4.15) (2025-05-30)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* collaboration ([5030253](https://github.com/bipproduction/hipmi/commit/5030253b07c1264229d066d18732d81e2636c5a6))
|
||||
* collaboration ([740ae44](https://github.com/bipproduction/hipmi/commit/740ae447340ce48d168e0e8e7c14079b3cf61817))
|
||||
|
||||
## [1.4.14](https://github.com/bipproduction/hipmi/compare/v1.4.13...v1.4.14) (2025-05-27)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* collaboration ([bdff760](https://github.com/bipproduction/hipmi/commit/bdff760f7021c624f8338da3af2d46c911b1dcff))
|
||||
|
||||
## [1.4.13](https://github.com/bipproduction/hipmi/compare/v1.4.12...v1.4.13) (2025-05-26)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* collaboration ([5007827](https://github.com/bipproduction/hipmi/commit/5007827d51117105b879bf18f06da60db8c48ff4))
|
||||
|
||||
## [1.4.12](https://github.com/bipproduction/hipmi/compare/v1.4.11...v1.4.12) (2025-05-26)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* Map ([f23defd](https://github.com/bipproduction/hipmi/commit/f23defd972fbd276fee546677dc5e9565651b4f4))
|
||||
|
||||
## [1.4.11](https://github.com/bipproduction/hipmi/compare/v1.4.10...v1.4.11) (2025-05-26)
|
||||
|
||||
## [1.4.10](https://github.com/bipproduction/hipmi/compare/v1.4.9...v1.4.10) (2025-05-23)
|
||||
|
||||
## [1.4.9](https://github.com/bipproduction/hipmi/compare/v1.4.8...v1.4.9) (2025-05-23)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* nested layout ([c202cc8](https://github.com/bipproduction/hipmi/commit/c202cc8ea08ce8cdb351136a47c2afe10afb14c9))
|
||||
|
||||
## [1.4.8](https://github.com/bipproduction/hipmi/compare/v1.4.7...v1.4.8) (2025-05-22)
|
||||
|
||||
## [1.4.7](https://github.com/bipproduction/hipmi/compare/v1.4.6...v1.4.7) (2025-05-22)
|
||||
|
||||
## [1.4.6](https://github.com/bipproduction/hipmi/compare/v1.4.5...v1.4.6) (2025-05-21)
|
||||
|
||||
## [1.4.5](https://github.com/bipproduction/hipmi/compare/v1.4.4...v1.4.5) (2025-05-21)
|
||||
|
||||
## [1.4.4](https://github.com/bipproduction/hipmi/compare/v1.4.3...v1.4.4) (2025-05-20)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* button sticker ([3743008](https://github.com/bipproduction/hipmi/commit/37430081d8718b4b2b06f5c3c09f13935bf413c4))
|
||||
* event ([02bbdfd](https://github.com/bipproduction/hipmi/commit/02bbdfd5f6a2d299b8d527b9211f7b6ff598602f))
|
||||
|
||||
## [1.4.3](https://github.com/bipproduction/hipmi/compare/v1.4.2...v1.4.3) (2025-05-20)
|
||||
|
||||
## [1.4.2](https://github.com/bipproduction/hipmi/compare/v1.4.1...v1.4.2) (2025-05-19)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* admin app info ([117dbe6](https://github.com/bipproduction/hipmi/commit/117dbe6157fbb74d359db1c8baffe3c4985fab4a))
|
||||
* admin app info ([0cbcee8](https://github.com/bipproduction/hipmi/commit/0cbcee87bd52f6a7b596e260841deef9d4615016))
|
||||
|
||||
## [1.4.1](https://github.com/bipproduction/hipmi/compare/v1.4.0...v1.4.1) (2025-05-19)
|
||||
|
||||
## [1.4.0](https://github.com/bipproduction/hipmi/compare/v1.3.1...v1.4.0) (2025-05-16)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* admin sticker ([2a8c79f](https://github.com/bipproduction/hipmi/commit/2a8c79fd09c3f7fd7ee58ac6896b17802dfe0147))
|
||||
* admin stiker ([e7858a2](https://github.com/bipproduction/hipmi/commit/e7858a281223a81037219afec58e5f6b9e04be15))
|
||||
|
||||
## [1.3.1](https://github.com/bipproduction/hipmi/compare/v1.3.0...v1.3.1) (2025-05-16)
|
||||
|
||||
## [1.3.0](https://github.com/bipproduction/hipmi/compare/v1.2.126...v1.3.0) (2025-05-15)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* admin app information ([bc10b80](https://github.com/bipproduction/hipmi/commit/bc10b80139833966d3e39b52cabf577930552052))
|
||||
* tampilan upload stiker di admin ([fbea35e](https://github.com/bipproduction/hipmi/commit/fbea35eef96a656e1b474959aa3fb8198c7d2b0e))
|
||||
|
||||
## [1.2.126](https://github.com/bipproduction/hipmi/compare/v1.2.125...v1.2.126) (2025-05-13)
|
||||
|
||||
## [1.2.125](https://github.com/bipproduction/hipmi/compare/v1.2.124...v1.2.125) (2025-05-09)
|
||||
|
||||
## [1.2.124](https://github.com/bipproduction/hipmi/compare/v1.2.123...v1.2.124) (2025-05-08)
|
||||
|
||||
## [1.2.123](https://github.com/bipproduction/hipmi/compare/v1.2.122...v1.2.123) (2025-05-06)
|
||||
|
||||
## [1.2.122](https://github.com/bipproduction/hipmi/compare/v1.2.121...v1.2.122) (2025-05-06)
|
||||
|
||||
## [1.2.121](https://github.com/bipproduction/hipmi/compare/v1.2.120...v1.2.121) (2025-05-05)
|
||||
|
||||
## [1.2.120](https://github.com/bipproduction/hipmi/compare/v1.2.119...v1.2.120) (2025-05-05)
|
||||
|
||||
## [1.2.119](https://github.com/bipproduction/hipmi/compare/v1.2.118...v1.2.119) (2025-05-02)
|
||||
|
||||
## [1.2.118](https://github.com/bipproduction/hipmi/compare/v1.2.117...v1.2.118) (2025-04-30)
|
||||
|
||||
## [1.2.117](https://github.com/bipproduction/hipmi/compare/v1.2.116...v1.2.117) (2025-04-29)
|
||||
|
||||
## [1.2.116](https://github.com/bipproduction/hipmi/compare/v1.2.115...v1.2.116) (2025-04-28)
|
||||
|
||||
## [1.2.115](https://github.com/bipproduction/hipmi/compare/v1.2.114...v1.2.115) (2025-04-28)
|
||||
|
||||
## [1.2.114](https://github.com/bipproduction/hipmi/compare/v1.2.113...v1.2.114) (2025-04-23)
|
||||
|
||||
## [1.2.113](https://github.com/bipproduction/hipmi/compare/v1.2.112...v1.2.113) (2025-04-21)
|
||||
|
||||
## [1.2.112](https://github.com/bipproduction/hipmi/compare/v1.2.111...v1.2.112) (2025-04-17)
|
||||
|
||||
## [1.2.111](https://github.com/bipproduction/hipmi/compare/v1.2.110...v1.2.111) (2025-04-17)
|
||||
|
||||
## [1.2.110](https://github.com/bipproduction/hipmi/compare/v1.2.109...v1.2.110) (2025-04-16)
|
||||
|
||||
## [1.2.109](https://github.com/bipproduction/hipmi/compare/v1.2.108...v1.2.109) (2025-04-16)
|
||||
|
||||
## [1.2.108](https://github.com/bipproduction/hipmi/compare/v1.2.107...v1.2.108) (2025-04-14)
|
||||
|
||||
## [1.2.107](https://github.com/bipproduction/hipmi/compare/v1.2.106...v1.2.107) (2025-04-10)
|
||||
|
||||
## [1.2.106](https://github.com/bipproduction/hipmi/compare/v1.2.105...v1.2.106) (2025-04-09)
|
||||
|
||||
## [1.2.105](https://github.com/bipproduction/hipmi/compare/v1.2.104...v1.2.105) (2025-04-09)
|
||||
|
||||
## [1.2.104](https://github.com/bipproduction/hipmi/compare/v1.2.103...v1.2.104) (2025-04-09)
|
||||
|
||||
## [1.2.103](https://github.com/bipproduction/hipmi/compare/v1.2.102...v1.2.103) (2025-04-09)
|
||||
|
||||
## [1.2.102](https://github.com/bipproduction/hipmi/compare/v1.2.101...v1.2.102) (2025-04-08)
|
||||
|
||||
## [1.2.101](https://github.com/bipproduction/hipmi/compare/v1.2.100...v1.2.101) (2025-04-08)
|
||||
|
||||
## [1.2.100](https://github.com/bipproduction/hipmi/compare/v1.2.99...v1.2.100) (2025-04-08)
|
||||
|
||||
## [1.2.99](https://github.com/bipproduction/hipmi/compare/v1.2.98...v1.2.99) (2025-04-08)
|
||||
|
||||
## [1.2.98](https://github.com/bipproduction/hipmi/compare/v1.2.97...v1.2.98) (2025-04-08)
|
||||
|
||||
## [1.2.97](https://github.com/bipproduction/hipmi/compare/v1.2.96...v1.2.97) (2025-04-08)
|
||||
|
||||
## [1.2.96](https://github.com/bipproduction/hipmi/compare/v1.2.95...v1.2.96) (2025-04-08)
|
||||
|
||||
## [1.2.95](https://github.com/bipproduction/hipmi/compare/v1.2.94...v1.2.95) (2025-04-08)
|
||||
|
||||
## [1.2.94](https://github.com/bipproduction/hipmi/compare/v1.2.93...v1.2.94) (2025-04-08)
|
||||
|
||||
## [1.2.93](https://github.com/bipproduction/hipmi/compare/v1.2.92...v1.2.93) (2025-04-08)
|
||||
|
||||
## [1.2.92](https://github.com/bipproduction/hipmi/compare/v1.2.91...v1.2.92) (2025-04-08)
|
||||
|
||||
## [1.2.91](https://github.com/bipproduction/hipmi/compare/v1.2.90...v1.2.91) (2025-04-08)
|
||||
|
||||
## [1.2.90](https://github.com/bipproduction/hipmi/compare/v1.2.89...v1.2.90) (2025-04-07)
|
||||
|
||||
## [1.2.89](https://github.com/bipproduction/hipmi/compare/v1.2.88...v1.2.89) (2025-04-07)
|
||||
|
||||
## [1.2.88](https://github.com/bipproduction/hipmi/compare/v1.2.87...v1.2.88) (2025-04-07)
|
||||
|
||||
## [1.2.87](https://github.com/bipproduction/hipmi/compare/v1.2.86...v1.2.87) (2025-03-26)
|
||||
|
||||
## [1.2.86](https://github.com/bipproduction/hipmi/compare/v1.2.85...v1.2.86) (2025-03-25)
|
||||
|
||||
## [1.2.85](https://github.com/bipproduction/hipmi/compare/v1.2.84...v1.2.85) (2025-03-24)
|
||||
|
||||
## [1.2.84](https://github.com/bipproduction/hipmi/compare/v1.2.83...v1.2.84) (2025-03-21)
|
||||
|
||||
## [1.2.83](https://github.com/bipproduction/hipmi/compare/v1.2.82...v1.2.83) (2025-03-20)
|
||||
|
||||
## [1.2.82](https://github.com/bipproduction/hipmi/compare/v1.2.81...v1.2.82) (2025-03-19)
|
||||
|
||||
## [1.2.81](https://github.com/bipproduction/hipmi/compare/v1.2.80...v1.2.81) (2025-03-17)
|
||||
|
||||
## [1.2.80](https://github.com/bipproduction/hipmi/compare/v1.2.79...v1.2.80) (2025-03-14)
|
||||
|
||||
## [1.2.79](https://github.com/bipproduction/hipmi/compare/v1.2.78...v1.2.79) (2025-03-14)
|
||||
|
||||
## [1.2.78](https://github.com/bipproduction/hipmi/compare/v1.2.77...v1.2.78) (2025-03-12)
|
||||
|
||||
## [1.2.77](https://github.com/bipproduction/hipmi/compare/v1.2.76...v1.2.77) (2025-03-12)
|
||||
|
||||
## [1.2.76](https://github.com/bipproduction/hipmi/compare/v1.2.75...v1.2.76) (2025-03-12)
|
||||
|
||||
## [1.2.75](https://github.com/bipproduction/hipmi/compare/v1.2.74...v1.2.75) (2025-03-07)
|
||||
|
||||
## [1.2.74](https://github.com/bipproduction/hipmi/compare/v1.2.73...v1.2.74) (2025-03-07)
|
||||
|
||||
## [1.2.73](https://github.com/bipproduction/hipmi/compare/v1.2.72...v1.2.73) (2025-03-06)
|
||||
|
||||
## [1.2.72](https://github.com/bipproduction/hipmi/compare/v1.2.71...v1.2.72) (2025-03-05)
|
||||
|
||||
## [1.2.71](https://github.com/bipproduction/hipmi/compare/v1.2.70...v1.2.71) (2025-03-04)
|
||||
|
||||
## [1.2.70](https://github.com/bipproduction/hipmi/compare/v1.2.69...v1.2.70) (2025-03-04)
|
||||
|
||||
## [1.2.69](https://github.com/bipproduction/hipmi/compare/v1.2.68...v1.2.69) (2025-02-28)
|
||||
|
||||
## [1.2.68](https://github.com/bipproduction/hipmi/compare/v1.2.67...v1.2.68) (2025-02-28)
|
||||
|
||||
## [1.2.67](https://github.com/bipproduction/hipmi/compare/v1.2.66...v1.2.67) (2025-02-27)
|
||||
|
||||
## [1.2.66](https://github.com/bipproduction/hipmi/compare/v1.2.65...v1.2.66) (2025-02-27)
|
||||
|
||||
## [1.2.65](https://github.com/bipproduction/hipmi/compare/v1.2.64...v1.2.65) (2025-02-27)
|
||||
|
||||
## [1.2.64](https://github.com/bipproduction/hipmi/compare/v1.2.63...v1.2.64) (2025-02-26)
|
||||
|
||||
## [1.2.63](https://github.com/bipproduction/hipmi/compare/v1.2.62...v1.2.63) (2025-02-26)
|
||||
|
||||
## [1.2.62](https://github.com/bipproduction/hipmi/compare/v1.2.61...v1.2.62) (2025-02-25)
|
||||
|
||||
## [1.2.61](https://github.com/bipproduction/hipmi/compare/v1.2.60...v1.2.61) (2025-02-25)
|
||||
|
||||
## [1.2.60](https://github.com/bipproduction/hipmi/compare/v1.2.59...v1.2.60) (2025-02-25)
|
||||
|
||||
## [1.2.59](https://github.com/bipproduction/hipmi/compare/v1.2.58...v1.2.59) (2025-02-25)
|
||||
|
||||
## [1.2.58](https://github.com/bipproduction/hipmi/compare/v1.2.57...v1.2.58) (2025-02-25)
|
||||
|
||||
## [1.2.57](https://github.com/bipproduction/hipmi/compare/v1.2.56...v1.2.57) (2025-02-20)
|
||||
|
||||
## [1.2.56](https://github.com/bipproduction/hipmi/compare/v1.2.55...v1.2.56) (2025-02-19)
|
||||
|
||||
## [1.2.55](https://github.com/bipproduction/hipmi/compare/v1.2.54...v1.2.55) (2025-02-12)
|
||||
|
||||
## [1.2.54](https://github.com/bipproduction/hipmi/compare/v1.2.53...v1.2.54) (2025-02-12)
|
||||
|
||||
## [1.2.53](https://github.com/bipproduction/hipmi/compare/v1.2.52...v1.2.53) (2025-02-11)
|
||||
|
||||
## [1.2.52](https://github.com/bipproduction/hipmi/compare/v1.2.51...v1.2.52) (2025-02-10)
|
||||
|
||||
## [1.2.51](https://github.com/bipproduction/hipmi/compare/v1.2.50...v1.2.51) (2025-02-10)
|
||||
|
||||
## [1.2.50](https://github.com/bipproduction/hipmi/compare/v1.2.49...v1.2.50) (2025-02-10)
|
||||
|
||||
## [1.2.49](https://github.com/bipproduction/hipmi/compare/v1.2.48...v1.2.49) (2025-02-07)
|
||||
|
||||
## [1.2.48](https://github.com/bipproduction/hipmi/compare/v1.2.47...v1.2.48) (2025-02-07)
|
||||
|
||||
## [1.2.47](https://github.com/bipproduction/hipmi/compare/v1.2.46...v1.2.47) (2025-02-03)
|
||||
|
||||
## [1.2.46](https://github.com/bipproduction/hipmi/compare/v1.2.45...v1.2.46) (2025-02-03)
|
||||
|
||||
## [1.2.45](https://github.com/bipproduction/hipmi/compare/v1.2.44...v1.2.45) (2025-02-03)
|
||||
|
||||
## [1.2.44](https://github.com/bipproduction/hipmi/compare/v1.2.43...v1.2.44) (2025-02-03)
|
||||
|
||||
## [1.2.43](https://github.com/bipproduction/hipmi/compare/v1.2.42...v1.2.43) (2025-02-03)
|
||||
|
||||
## [1.2.42](https://github.com/bipproduction/hipmi/compare/v1.2.41...v1.2.42) (2025-01-30)
|
||||
|
||||
## [1.2.41](https://github.com/bipproduction/hipmi/compare/v1.2.40...v1.2.41) (2025-01-21)
|
||||
|
||||
## [1.2.40](https://github.com/bipproduction/hipmi/compare/v1.2.39...v1.2.40) (2025-01-16)
|
||||
|
||||
## [1.2.39](https://github.com/bipproduction/hipmi/compare/v1.2.38...v1.2.39) (2025-01-12)
|
||||
|
||||
## [1.2.38](https://github.com/bipproduction/hipmi/compare/v1.2.37...v1.2.38) (2025-01-03)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* user ([215accb](https://github.com/bipproduction/hipmi/commit/215accbcaa989e43f43dfc5f400d5411013f4ef3))
|
||||
|
||||
## [1.2.37](https://github.com/bipproduction/hipmi/compare/v1.2.36...v1.2.37) (2025-01-02)
|
||||
|
||||
## [1.2.36](https://github.com/bipproduction/hipmi/compare/v1.2.35...v1.2.36) (2024-12-30)
|
||||
|
||||
## [1.2.35](https://github.com/bipproduction/hipmi/compare/v1.2.34...v1.2.35) (2024-12-27)
|
||||
|
||||
## [1.2.34](https://github.com/bipproduction/hipmi/compare/v1.2.33...v1.2.34) (2024-12-24)
|
||||
|
||||
## [1.2.33](https://github.com/bipproduction/hipmi/compare/v1.2.32...v1.2.33) (2024-12-22)
|
||||
|
||||
## [1.2.32](https://github.com/bipproduction/hipmi/compare/v1.2.31...v1.2.32) (2024-12-19)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* donasi ([72b6d23](https://github.com/bipproduction/hipmi/commit/72b6d239fee3e90e812ab24192154e5e8910fccb))
|
||||
|
||||
## [1.2.31](https://github.com/bipproduction/hipmi/compare/v1.2.30...v1.2.31) (2024-12-17)
|
||||
|
||||
## [1.2.30](https://github.com/bipproduction/hipmi/compare/v1.2.29...v1.2.30) (2024-12-16)
|
||||
|
||||
## [1.2.29](https://github.com/bipproduction/hipmi/compare/v1.2.28...v1.2.29) (2024-12-13)
|
||||
|
||||
## [1.2.28](https://github.com/bipproduction/hipmi/compare/v1.2.27...v1.2.28) (2024-12-12)
|
||||
|
||||
## [1.2.27](https://github.com/bipproduction/hipmi/compare/v1.2.26...v1.2.27) (2024-12-12)
|
||||
|
||||
## [1.2.26](https://github.com/bipproduction/hipmi/compare/v1.2.25...v1.2.26) (2024-12-12)
|
||||
|
||||
## [1.2.25](https://github.com/bipproduction/hipmi/compare/v1.2.24...v1.2.25) (2024-12-12)
|
||||
|
||||
## [1.2.24](https://github.com/bipproduction/hipmi/compare/v1.2.23...v1.2.24) (2024-12-11)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* drawer katalog ([eab293d](https://github.com/bipproduction/hipmi/commit/eab293dd35a6f061cfa4675679de1ce68f506c3c))
|
||||
* loading button tambah portofolio ([8823a01](https://github.com/bipproduction/hipmi/commit/8823a01b067928cbeea195402f2bb454df8e8bea))
|
||||
* pencegahan error ([afe8014](https://github.com/bipproduction/hipmi/commit/afe8014cc8b4ab7266f3c52918a6bc82bb62bc58))
|
||||
|
||||
## [1.2.23](https://github.com/bipproduction/hipmi/compare/v1.2.22...v1.2.23) (2024-12-11)
|
||||
|
||||
## [1.2.22](https://github.com/bipproduction/hipmi/compare/v1.2.21...v1.2.22) (2024-12-10)
|
||||
|
||||
## [1.2.21](https://github.com/bipproduction/hipmi/compare/v1.2.20...v1.2.21) (2024-12-09)
|
||||
|
||||
## [1.2.20](https://github.com/bipproduction/hipmi/compare/v1.2.19...v1.2.20) (2024-12-09)
|
||||
|
||||
## [1.2.19](https://github.com/bipproduction/hipmi/compare/v1.2.18...v1.2.19) (2024-12-06)
|
||||
|
||||
## [1.2.18](https://github.com/bipproduction/hipmi/compare/v1.2.17...v1.2.18) (2024-12-04)
|
||||
|
||||
## [1.2.17](https://github.com/bipproduction/hipmi/compare/v1.2.16...v1.2.17) (2024-12-04)
|
||||
|
||||
## [1.2.16](https://github.com/bipproduction/hipmi/compare/v1.2.15...v1.2.16) (2024-12-03)
|
||||
|
||||
## [1.2.15](https://github.com/bipproduction/hipmi/compare/v1.2.14...v1.2.15) (2024-12-03)
|
||||
|
||||
## [1.2.14](https://github.com/bipproduction/hipmi/compare/v1.2.13...v1.2.14) (2024-12-03)
|
||||
|
||||
## [1.2.13](https://github.com/bipproduction/hipmi/compare/v1.2.12...v1.2.13) (2024-12-03)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* event ([fc38813](https://github.com/bipproduction/hipmi/commit/fc388133a638d4288314dd3faeddfcce61fe7292))
|
||||
* version 1.2.12 ([932735f](https://github.com/bipproduction/hipmi/commit/932735f9238db07b331b1b26328624247371c3d6))
|
||||
|
||||
## [1.2.12](https://github.com/bipproduction/hipmi/compare/v1.2.11...v1.2.12) (2024-12-02)
|
||||
|
||||
|
||||
|
||||
3399
backup.sql
Normal file
3399
backup.sql
Normal file
File diff suppressed because it is too large
Load Diff
3
build.wibu
Normal file
3
build.wibu
Normal file
@@ -0,0 +1,3 @@
|
||||
bun --env-file=.env.build prisma db push
|
||||
bun --env-file=.env.build prisma db seed
|
||||
bun --env-file=.env.build run build
|
||||
16
eslint.config.mjs.back.txt
Normal file
16
eslint.config.mjs.back.txt
Normal file
@@ -0,0 +1,16 @@
|
||||
import { fileURLToPath } from "url";
|
||||
import { dirname } from "path"; // Pastikan `dirname` diimpor
|
||||
import { FlatCompat } from "@eslint/eslintrc";
|
||||
|
||||
const __filename = fileURLToPath(import.meta.url);
|
||||
const __dirname = dirname(__filename);
|
||||
|
||||
const compat = new FlatCompat({
|
||||
baseDirectory: __dirname,
|
||||
});
|
||||
|
||||
const eslintConfig = [
|
||||
...compat.extends("next/core-web-vitals", "next/typescript"),
|
||||
];
|
||||
|
||||
export default eslintConfig;
|
||||
0
logs/.gitkeep
Normal file
0
logs/.gitkeep
Normal file
0
logs/backend/.gitkeep
Normal file
0
logs/backend/.gitkeep
Normal file
0
logs/frontend/.gitkeep
Normal file
0
logs/frontend/.gitkeep
Normal file
@@ -1,10 +1,27 @@
|
||||
/** @type {import('next').NextConfig} */
|
||||
const nextConfig = {
|
||||
reactStrictMode: false,
|
||||
experimental: {
|
||||
serverActions: true
|
||||
},
|
||||
|
||||
}
|
||||
reactStrictMode: false,
|
||||
experimental: {
|
||||
serverActions: true,
|
||||
},
|
||||
output: "standalone",
|
||||
staticPageGenerationTimeout: 180, // tingkatkan menjadi 3 menit
|
||||
eslint: {
|
||||
ignoreDuringBuilds: true,
|
||||
},
|
||||
// async headers() {
|
||||
// return [
|
||||
// {
|
||||
// source: "/(.*)",
|
||||
// headers: [
|
||||
// {
|
||||
// key: "Cache-Control",
|
||||
// value: "no-store, max-age=0",
|
||||
// },
|
||||
// ],
|
||||
// },
|
||||
// ];
|
||||
// },
|
||||
};
|
||||
|
||||
module.exports = nextConfig
|
||||
module.exports = nextConfig;
|
||||
|
||||
48
package.json
48
package.json
@@ -1,15 +1,16 @@
|
||||
{
|
||||
"name": "hipmi",
|
||||
"version": "1.2.12",
|
||||
"version": "1.5.27",
|
||||
"private": true,
|
||||
"prisma": {
|
||||
"seed": "npx tsx prisma/seed.ts --yes"
|
||||
"seed": "bun prisma/seed.ts"
|
||||
},
|
||||
"scripts": {
|
||||
"dev": "bun --bun run next dev --experimental-https",
|
||||
"build": "bun --bun run next build",
|
||||
"start": "bun --bun run next start",
|
||||
"lint": "bun --bun run next lint",
|
||||
"dev": "next dev --experimental-https",
|
||||
"build": "next build",
|
||||
"build:dev": "next build",
|
||||
"start": "next start",
|
||||
"lint": "next lint",
|
||||
"ver": "bunx commit-and-tag-version -- --prerelease"
|
||||
},
|
||||
"dependencies": {
|
||||
@@ -27,18 +28,21 @@
|
||||
"@mantine/next": "^6.0.17",
|
||||
"@mantine/notifications": "^6.0.17",
|
||||
"@mantine/tiptap": "^7.5.3",
|
||||
"@prisma/client": "^5.0.0",
|
||||
"@prisma/client": "^6.3.0",
|
||||
"@react-email/render": "^2.0.0",
|
||||
"@react-pdf/renderer": "^3.4.4",
|
||||
"@tabler/icons-react": "^2.38.0",
|
||||
"@tabler/icons-react": "^3.31.0",
|
||||
"@tiptap/extension-highlight": "^2.2.3",
|
||||
"@tiptap/extension-image": "^2.11.7",
|
||||
"@tiptap/extension-link": "^2.2.3",
|
||||
"@tiptap/extension-subscript": "^2.2.3",
|
||||
"@tiptap/extension-superscript": "^2.2.3",
|
||||
"@tiptap/extension-text-align": "^2.2.3",
|
||||
"@tiptap/extension-underline": "^2.2.3",
|
||||
"@tiptap/extension-underline": "^2.11.7",
|
||||
"@tiptap/pm": "^2.2.3",
|
||||
"@tiptap/react": "^2.2.3",
|
||||
"@tiptap/starter-kit": "^2.2.3",
|
||||
"@types/bun": "^1.1.14",
|
||||
"@types/lodash": "^4.17.4",
|
||||
"@types/mapbox-gl": "^3.4.0",
|
||||
"@types/node": "20.4.5",
|
||||
@@ -47,13 +51,17 @@
|
||||
"@types/uuid": "^9.0.4",
|
||||
"autoprefixer": "10.4.14",
|
||||
"bufferutil": "^4.0.8",
|
||||
"bun": "^1.1.38",
|
||||
"caniuse-lite": "^1.0.30001757",
|
||||
"colors": "^1.4.0",
|
||||
"date-fns": "^4.1.0",
|
||||
"dayjs": "^1.11.10",
|
||||
"dotenv": "^16.4.5",
|
||||
"echarts": "^5.4.3",
|
||||
"echarts-for-react": "^3.0.2",
|
||||
"embla-carousel-react": "^8.0.0-rc14",
|
||||
"eslint": "8.45.0",
|
||||
"eslint-config-next": "13.4.12",
|
||||
"eslint-config-next": "^13.5.4",
|
||||
"firebase-admin": "^13.6.0",
|
||||
"iron-session": "^6.3.1",
|
||||
"jose": "^5.9.2",
|
||||
"jotai": "^2.4.3",
|
||||
@@ -62,18 +70,20 @@
|
||||
"midtrans-client": "^1.3.1",
|
||||
"moment": "^2.29.4",
|
||||
"mqtt": "^5.5.0",
|
||||
"next": "^13.5.4-canary.8",
|
||||
"next": "^13.5.4",
|
||||
"next-dev": "^1.1.9",
|
||||
"next-scroll-loader": "^1.0.9",
|
||||
"p-limit": "^6.2.0",
|
||||
"pdf-lib": "^1.17.1",
|
||||
"pdf2pic": "^3.1.3",
|
||||
"pdfjs-dist": "^4.6.82",
|
||||
"postcss": "8.4.27",
|
||||
"prisma": "^5.19.1",
|
||||
"prisma": "^6.3.0",
|
||||
"react": "18.2.0",
|
||||
"react-countdown": "^2.3.5",
|
||||
"react-dom": "18.2.0",
|
||||
"react-easy-infinite-scroll-hook": "^2.1.4",
|
||||
"react-fast-marquee": "^1.6.4",
|
||||
"react-icons": "^5.0.1",
|
||||
"react-iframe": "^1.8.5",
|
||||
"react-infinite-scroll-component": "^6.1.0",
|
||||
"react-international-phone": "^4.2.6",
|
||||
@@ -83,7 +93,10 @@
|
||||
"react-quill": "^2.0.0",
|
||||
"react-responsive-carousel": "^3.2.23",
|
||||
"react-toastify": "^9.1.3",
|
||||
"resend": "^6.4.2",
|
||||
"sharp": "^0.33.5",
|
||||
"socket.io-client": "^4.7.2",
|
||||
"swr": "^2.3.0",
|
||||
"tailwindcss": "3.3.3",
|
||||
"ts-node": "^10.9.2",
|
||||
"typescript": "5.1.6",
|
||||
@@ -92,6 +105,13 @@
|
||||
"wibu": "bipproduction/wibu",
|
||||
"wibu-cli": "^1.0.91",
|
||||
"wibu-pkg": "^1.0.3",
|
||||
"winston": "^3.17.0",
|
||||
"winston-daily-rotate-file": "^5.0.0",
|
||||
"yaml": "^2.3.2"
|
||||
},
|
||||
"devDependencies": {
|
||||
"eslint": "^8.56.0",
|
||||
"@typescript-eslint/eslint-plugin": "^7.0.0",
|
||||
"@typescript-eslint/parser": "^7.0.0"
|
||||
}
|
||||
}
|
||||
|
||||
198
prisma/migrations/20250108154615_new_database/migration.sql
Normal file
198
prisma/migrations/20250108154615_new_database/migration.sql
Normal file
@@ -0,0 +1,198 @@
|
||||
/*
|
||||
Warnings:
|
||||
|
||||
- You are about to drop the column `imagesId` on the `Job` table. All the data in the column will be lost.
|
||||
- You are about to drop the column `active` on the `MasterBank` table. All the data in the column will be lost.
|
||||
- You are about to drop the column `name` on the `MasterBank` table. All the data in the column will be lost.
|
||||
- You are about to drop the column `imagesBackgroundId` on the `Profile` table. All the data in the column will be lost.
|
||||
- You are about to drop the column `imagesId` on the `Profile` table. All the data in the column will be lost.
|
||||
- You are about to drop the `ImagesBackground` table. If the table is not empty, all the data it contains will be lost.
|
||||
- Added the required column `namaAkun` to the `MasterBank` table without a default value. This is not possible if the table is not empty.
|
||||
- Added the required column `namaBank` to the `MasterBank` table without a default value. This is not possible if the table is not empty.
|
||||
|
||||
*/
|
||||
-- DropForeignKey
|
||||
ALTER TABLE "Job" DROP CONSTRAINT "Job_imagesId_fkey";
|
||||
|
||||
-- DropForeignKey
|
||||
ALTER TABLE "Notifikasi" DROP CONSTRAINT "NotifikasiAdmin";
|
||||
|
||||
-- DropForeignKey
|
||||
ALTER TABLE "Notifikasi" DROP CONSTRAINT "NotifikasiUser";
|
||||
|
||||
-- DropForeignKey
|
||||
ALTER TABLE "Portofolio" DROP CONSTRAINT "Portofolio_logoId_fkey";
|
||||
|
||||
-- DropForeignKey
|
||||
ALTER TABLE "Profile" DROP CONSTRAINT "Profile_imagesBackgroundId_fkey";
|
||||
|
||||
-- DropForeignKey
|
||||
ALTER TABLE "Profile" DROP CONSTRAINT "Profile_imagesId_fkey";
|
||||
|
||||
-- DropIndex
|
||||
DROP INDEX "Profile_imagesBackgroundId_key";
|
||||
|
||||
-- DropIndex
|
||||
DROP INDEX "Profile_imagesId_key";
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "BeritaInvestasi" ADD COLUMN "imageId" TEXT;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "DokumenInvestasi" ADD COLUMN "fileId" TEXT,
|
||||
ALTER COLUMN "url" DROP NOT NULL;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "Donasi" ADD COLUMN "imageId" TEXT;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "Donasi_Cerita" ADD COLUMN "imageId" TEXT;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "Donasi_Invoice" ADD COLUMN "imageId" TEXT;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "Donasi_Kabar" ADD COLUMN "imageId" TEXT;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "Donasi_PencairanDana" ADD COLUMN "imageId" TEXT;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "Donasi_TemporaryCreate" ADD COLUMN "imageId" TEXT;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "Event" ADD COLUMN "isArsip" BOOLEAN DEFAULT false,
|
||||
ADD COLUMN "tanggalSelesai" TIMESTAMP(3),
|
||||
ALTER COLUMN "tanggal" DROP NOT NULL;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "Event_Peserta" ADD COLUMN "isPresent" BOOLEAN NOT NULL DEFAULT false;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "Investasi" ADD COLUMN "imageId" TEXT,
|
||||
ADD COLUMN "prospektusFileId" TEXT;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "Job" DROP COLUMN "imagesId",
|
||||
ADD COLUMN "imageId" TEXT;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "MasterBank" DROP COLUMN "active",
|
||||
DROP COLUMN "name",
|
||||
ADD COLUMN "isActive" BOOLEAN NOT NULL DEFAULT true,
|
||||
ADD COLUMN "namaAkun" TEXT NOT NULL,
|
||||
ADD COLUMN "namaBank" TEXT NOT NULL;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "Notifikasi" ALTER COLUMN "userId" DROP NOT NULL,
|
||||
ALTER COLUMN "adminId" DROP NOT NULL;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "Profile" DROP COLUMN "imagesBackgroundId",
|
||||
DROP COLUMN "imagesId",
|
||||
ADD COLUMN "imageBackgroundId" TEXT,
|
||||
ADD COLUMN "imageId" TEXT;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "ProspektusInvestasi" ADD COLUMN "fileId" TEXT,
|
||||
ADD COLUMN "title" TEXT;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "User" ALTER COLUMN "active" SET DEFAULT false;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "UserSession" ALTER COLUMN "expires" DROP NOT NULL;
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "Voting" ADD COLUMN "isArsip" BOOLEAN NOT NULL DEFAULT false;
|
||||
|
||||
-- DropTable
|
||||
DROP TABLE "ImagesBackground";
|
||||
|
||||
-- CreateTable
|
||||
CREATE TABLE "Investasi_Invoice" (
|
||||
"id" TEXT NOT NULL,
|
||||
"isActive" BOOLEAN NOT NULL DEFAULT true,
|
||||
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"updatedAt" TIMESTAMP(3) NOT NULL,
|
||||
"nominal" TEXT NOT NULL,
|
||||
"lembarTerbeli" TEXT NOT NULL,
|
||||
"investasiId" TEXT,
|
||||
"masterBankId" TEXT,
|
||||
"statusInvoiceId" TEXT,
|
||||
"authorId" TEXT,
|
||||
"imagesId" TEXT,
|
||||
"imageId" TEXT,
|
||||
|
||||
CONSTRAINT "Investasi_Invoice_pkey" PRIMARY KEY ("id")
|
||||
);
|
||||
|
||||
-- CreateTable
|
||||
CREATE TABLE "InvestasiMaster_StatusInvoice" (
|
||||
"id" TEXT NOT NULL,
|
||||
"name" TEXT NOT NULL,
|
||||
"isActive" BOOLEAN NOT NULL DEFAULT true,
|
||||
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"updatedAt" TIMESTAMP(3) NOT NULL,
|
||||
|
||||
CONSTRAINT "InvestasiMaster_StatusInvoice_pkey" PRIMARY KEY ("id")
|
||||
);
|
||||
|
||||
-- CreateTable
|
||||
CREATE TABLE "BusinessMaps" (
|
||||
"id" TEXT NOT NULL,
|
||||
"isActive" BOOLEAN NOT NULL DEFAULT true,
|
||||
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"updatedAt" TIMESTAMP(3) NOT NULL,
|
||||
"namePin" TEXT NOT NULL,
|
||||
"latitude" DOUBLE PRECISION NOT NULL,
|
||||
"longitude" DOUBLE PRECISION NOT NULL,
|
||||
"authorId" TEXT,
|
||||
"portofolioId" TEXT,
|
||||
"imageId" TEXT,
|
||||
"pinId" TEXT,
|
||||
|
||||
CONSTRAINT "BusinessMaps_pkey" PRIMARY KEY ("id")
|
||||
);
|
||||
|
||||
-- CreateTable
|
||||
CREATE TABLE "MasterKategoriApp" (
|
||||
"id" TEXT NOT NULL,
|
||||
"isActive" BOOLEAN NOT NULL DEFAULT true,
|
||||
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"updatedAt" TIMESTAMP(3) NOT NULL,
|
||||
"name" TEXT NOT NULL,
|
||||
"value" TEXT,
|
||||
|
||||
CONSTRAINT "MasterKategoriApp_pkey" PRIMARY KEY ("id")
|
||||
);
|
||||
|
||||
-- CreateIndex
|
||||
CREATE UNIQUE INDEX "BusinessMaps_portofolioId_key" ON "BusinessMaps"("portofolioId");
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "Investasi_Invoice" ADD CONSTRAINT "Investasi_Invoice_investasiId_fkey" FOREIGN KEY ("investasiId") REFERENCES "Investasi"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "Investasi_Invoice" ADD CONSTRAINT "Investasi_Invoice_masterBankId_fkey" FOREIGN KEY ("masterBankId") REFERENCES "MasterBank"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "Investasi_Invoice" ADD CONSTRAINT "Investasi_Invoice_statusInvoiceId_fkey" FOREIGN KEY ("statusInvoiceId") REFERENCES "InvestasiMaster_StatusInvoice"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "Investasi_Invoice" ADD CONSTRAINT "Investasi_Invoice_authorId_fkey" FOREIGN KEY ("authorId") REFERENCES "User"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "Investasi_Invoice" ADD CONSTRAINT "Investasi_Invoice_imagesId_fkey" FOREIGN KEY ("imagesId") REFERENCES "Images"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "Notifikasi" ADD CONSTRAINT "NotifikasiUser" FOREIGN KEY ("userId") REFERENCES "User"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "Notifikasi" ADD CONSTRAINT "NotifikasiAdmin" FOREIGN KEY ("adminId") REFERENCES "User"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "BusinessMaps" ADD CONSTRAINT "BusinessMaps_authorId_fkey" FOREIGN KEY ("authorId") REFERENCES "User"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "BusinessMaps" ADD CONSTRAINT "BusinessMaps_portofolioId_fkey" FOREIGN KEY ("portofolioId") REFERENCES "Portofolio"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
@@ -0,0 +1,125 @@
|
||||
-- AlterTable
|
||||
ALTER TABLE "MasterBidangBisnis" ADD COLUMN "slug" TEXT NOT NULL DEFAULT 'NULL';
|
||||
|
||||
-- CreateTable
|
||||
CREATE TABLE "Portofolio_BidangDanSubBidangBisnis" (
|
||||
"id" TEXT NOT NULL,
|
||||
"isActive" BOOLEAN NOT NULL DEFAULT true,
|
||||
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"updatedAt" TIMESTAMP(3) NOT NULL,
|
||||
"portofolioId" TEXT,
|
||||
"masterBidangBisnisId" TEXT,
|
||||
"masterSubBidangBisnisId" TEXT,
|
||||
|
||||
CONSTRAINT "Portofolio_BidangDanSubBidangBisnis_pkey" PRIMARY KEY ("id")
|
||||
);
|
||||
|
||||
-- CreateTable
|
||||
CREATE TABLE "MasterSubBidangBisnis" (
|
||||
"id" TEXT NOT NULL,
|
||||
"name" TEXT NOT NULL,
|
||||
"slug" TEXT NOT NULL DEFAULT 'NULL',
|
||||
"isActive" BOOLEAN NOT NULL DEFAULT true,
|
||||
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"updatedAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"masterBidangBisnisId" TEXT,
|
||||
|
||||
CONSTRAINT "MasterSubBidangBisnis_pkey" PRIMARY KEY ("id")
|
||||
);
|
||||
|
||||
-- CreateTable
|
||||
CREATE TABLE "MasterStatusTransaksi" (
|
||||
"id" TEXT NOT NULL,
|
||||
"name" TEXT NOT NULL,
|
||||
"isActive" BOOLEAN NOT NULL DEFAULT true,
|
||||
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"updatedAt" TIMESTAMP(3) NOT NULL,
|
||||
|
||||
CONSTRAINT "MasterStatusTransaksi_pkey" PRIMARY KEY ("id")
|
||||
);
|
||||
|
||||
-- CreateTable
|
||||
CREATE TABLE "MasterEmotions" (
|
||||
"id" SERIAL NOT NULL,
|
||||
"label" TEXT NOT NULL,
|
||||
"value" TEXT NOT NULL,
|
||||
"isActive" BOOLEAN NOT NULL DEFAULT true,
|
||||
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"updatedAt" TIMESTAMP(3) NOT NULL,
|
||||
|
||||
CONSTRAINT "MasterEmotions_pkey" PRIMARY KEY ("id")
|
||||
);
|
||||
|
||||
-- CreateTable
|
||||
CREATE TABLE "EventSponsor" (
|
||||
"id" TEXT NOT NULL,
|
||||
"isActive" BOOLEAN NOT NULL DEFAULT true,
|
||||
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"updatedAt" TIMESTAMP(3) NOT NULL,
|
||||
"name" TEXT NOT NULL,
|
||||
"isTransfer" BOOLEAN DEFAULT false,
|
||||
"fileName" TEXT NOT NULL,
|
||||
"fileExt" TEXT,
|
||||
"fileId" TEXT NOT NULL,
|
||||
"authorId" TEXT,
|
||||
"eventId" TEXT,
|
||||
|
||||
CONSTRAINT "EventSponsor_pkey" PRIMARY KEY ("id")
|
||||
);
|
||||
|
||||
-- CreateTable
|
||||
CREATE TABLE "EventTransaksi" (
|
||||
"id" TEXT NOT NULL,
|
||||
"isActive" BOOLEAN NOT NULL DEFAULT true,
|
||||
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"updatedAt" TIMESTAMP(3) NOT NULL,
|
||||
"nominal" INTEGER NOT NULL,
|
||||
"status" TEXT NOT NULL,
|
||||
"transferImageId" TEXT,
|
||||
"masterBankId" TEXT,
|
||||
"authorId" TEXT,
|
||||
"eventId" TEXT,
|
||||
"eventSponsorId" TEXT,
|
||||
"masterStatusTransaksiId" TEXT,
|
||||
|
||||
CONSTRAINT "EventTransaksi_pkey" PRIMARY KEY ("id")
|
||||
);
|
||||
|
||||
-- CreateIndex
|
||||
CREATE UNIQUE INDEX "MasterEmotions_value_key" ON "MasterEmotions"("value");
|
||||
|
||||
-- CreateIndex
|
||||
CREATE UNIQUE INDEX "EventTransaksi_eventSponsorId_key" ON "EventTransaksi"("eventSponsorId");
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "Portofolio_BidangDanSubBidangBisnis" ADD CONSTRAINT "Portofolio_BidangDanSubBidangBisnis_portofolioId_fkey" FOREIGN KEY ("portofolioId") REFERENCES "Portofolio"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "Portofolio_BidangDanSubBidangBisnis" ADD CONSTRAINT "Portofolio_BidangDanSubBidangBisnis_masterBidangBisnisId_fkey" FOREIGN KEY ("masterBidangBisnisId") REFERENCES "MasterBidangBisnis"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "Portofolio_BidangDanSubBidangBisnis" ADD CONSTRAINT "Portofolio_BidangDanSubBidangBisnis_masterSubBidangBisnisI_fkey" FOREIGN KEY ("masterSubBidangBisnisId") REFERENCES "MasterSubBidangBisnis"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "MasterSubBidangBisnis" ADD CONSTRAINT "MasterSubBidangBisnis_masterBidangBisnisId_fkey" FOREIGN KEY ("masterBidangBisnisId") REFERENCES "MasterBidangBisnis"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "EventSponsor" ADD CONSTRAINT "EventSponsor_authorId_fkey" FOREIGN KEY ("authorId") REFERENCES "User"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "EventSponsor" ADD CONSTRAINT "EventSponsor_eventId_fkey" FOREIGN KEY ("eventId") REFERENCES "Event"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "EventTransaksi" ADD CONSTRAINT "EventTransaksi_masterBankId_fkey" FOREIGN KEY ("masterBankId") REFERENCES "MasterBank"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "EventTransaksi" ADD CONSTRAINT "EventTransaksi_authorId_fkey" FOREIGN KEY ("authorId") REFERENCES "User"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "EventTransaksi" ADD CONSTRAINT "EventTransaksi_eventId_fkey" FOREIGN KEY ("eventId") REFERENCES "Event"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "EventTransaksi" ADD CONSTRAINT "EventTransaksi_eventSponsorId_fkey" FOREIGN KEY ("eventSponsorId") REFERENCES "EventSponsor"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "EventTransaksi" ADD CONSTRAINT "EventTransaksi_masterStatusTransaksiId_fkey" FOREIGN KEY ("masterStatusTransaksiId") REFERENCES "MasterStatusTransaksi"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
30
prisma/migrations/20250515060811_relasi/migration.sql
Normal file
30
prisma/migrations/20250515060811_relasi/migration.sql
Normal file
@@ -0,0 +1,30 @@
|
||||
-- CreateTable
|
||||
CREATE TABLE "Stiker" (
|
||||
"id" TEXT NOT NULL,
|
||||
"isActive" BOOLEAN NOT NULL DEFAULT true,
|
||||
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"updatedAt" TIMESTAMP(3) NOT NULL,
|
||||
"name" TEXT,
|
||||
"fileName" TEXT,
|
||||
"fileExt" TEXT,
|
||||
"fileId" TEXT NOT NULL,
|
||||
|
||||
CONSTRAINT "Stiker_pkey" PRIMARY KEY ("id")
|
||||
);
|
||||
|
||||
-- CreateTable
|
||||
CREATE TABLE "_StikerEmotions" (
|
||||
"A" INTEGER NOT NULL,
|
||||
"B" TEXT NOT NULL,
|
||||
|
||||
CONSTRAINT "_StikerEmotions_AB_pkey" PRIMARY KEY ("A","B")
|
||||
);
|
||||
|
||||
-- CreateIndex
|
||||
CREATE INDEX "_StikerEmotions_B_index" ON "_StikerEmotions"("B");
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "_StikerEmotions" ADD CONSTRAINT "_StikerEmotions_A_fkey" FOREIGN KEY ("A") REFERENCES "MasterEmotions"("id") ON DELETE CASCADE ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "_StikerEmotions" ADD CONSTRAINT "_StikerEmotions_B_fkey" FOREIGN KEY ("B") REFERENCES "Stiker"("id") ON DELETE CASCADE ON UPDATE CASCADE;
|
||||
28
prisma/migrations/20250515062136_ganti/migration.sql
Normal file
28
prisma/migrations/20250515062136_ganti/migration.sql
Normal file
@@ -0,0 +1,28 @@
|
||||
/*
|
||||
Warnings:
|
||||
|
||||
- You are about to drop the `Stiker` table. If the table is not empty, all the data it contains will be lost.
|
||||
|
||||
*/
|
||||
-- DropForeignKey
|
||||
ALTER TABLE "_StikerEmotions" DROP CONSTRAINT "_StikerEmotions_B_fkey";
|
||||
|
||||
-- DropTable
|
||||
DROP TABLE "Stiker";
|
||||
|
||||
-- CreateTable
|
||||
CREATE TABLE "Sticker" (
|
||||
"id" TEXT NOT NULL,
|
||||
"isActive" BOOLEAN NOT NULL DEFAULT true,
|
||||
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"updatedAt" TIMESTAMP(3) NOT NULL,
|
||||
"name" TEXT,
|
||||
"fileName" TEXT,
|
||||
"fileExt" TEXT,
|
||||
"fileId" TEXT NOT NULL,
|
||||
|
||||
CONSTRAINT "Sticker_pkey" PRIMARY KEY ("id")
|
||||
);
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "_StikerEmotions" ADD CONSTRAINT "_StikerEmotions_B_fkey" FOREIGN KEY ("B") REFERENCES "Sticker"("id") ON DELETE CASCADE ON UPDATE CASCADE;
|
||||
@@ -0,0 +1,2 @@
|
||||
-- AlterTable
|
||||
ALTER TABLE "Sticker" ADD COLUMN "jenisKelamin" TEXT;
|
||||
@@ -0,0 +1,5 @@
|
||||
-- AlterTable
|
||||
ALTER TABLE "Donasi_Invoice" ADD COLUMN "masterBankId" TEXT;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "Donasi_Invoice" ADD CONSTRAINT "Donasi_Invoice_masterBankId_fkey" FOREIGN KEY ("masterBankId") REFERENCES "MasterBank"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
@@ -0,0 +1,5 @@
|
||||
-- AlterTable
|
||||
ALTER TABLE "Donasi_Invoice" ALTER COLUMN "masterBankId" SET DEFAULT 'null';
|
||||
|
||||
-- AlterTable
|
||||
ALTER TABLE "User" ADD COLUMN "termsOfServiceAccepted" BOOLEAN NOT NULL DEFAULT false;
|
||||
@@ -0,0 +1,35 @@
|
||||
-- CreateTable
|
||||
CREATE TABLE "BlockedUser" (
|
||||
"id" TEXT NOT NULL,
|
||||
"isActive" BOOLEAN NOT NULL DEFAULT true,
|
||||
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"updatedAt" TIMESTAMP(3) NOT NULL,
|
||||
"blockerId" TEXT NOT NULL,
|
||||
"blockedId" TEXT NOT NULL,
|
||||
"menuFeatureId" TEXT NOT NULL,
|
||||
|
||||
CONSTRAINT "BlockedUser_pkey" PRIMARY KEY ("id")
|
||||
);
|
||||
|
||||
-- CreateTable
|
||||
CREATE TABLE "MenuFeature" (
|
||||
"id" TEXT NOT NULL,
|
||||
"isActive" BOOLEAN NOT NULL DEFAULT true,
|
||||
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"updatedAt" TIMESTAMP(3) NOT NULL,
|
||||
"name" TEXT NOT NULL,
|
||||
|
||||
CONSTRAINT "MenuFeature_pkey" PRIMARY KEY ("id")
|
||||
);
|
||||
|
||||
-- CreateIndex
|
||||
CREATE UNIQUE INDEX "BlockedUser_blockerId_blockedId_key" ON "BlockedUser"("blockerId", "blockedId");
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "BlockedUser" ADD CONSTRAINT "BlockedUser_menuFeatureId_fkey" FOREIGN KEY ("menuFeatureId") REFERENCES "MenuFeature"("id") ON DELETE RESTRICT ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "BlockedUser" ADD CONSTRAINT "BlockedUser_blockerId_fkey" FOREIGN KEY ("blockerId") REFERENCES "User"("id") ON DELETE RESTRICT ON UPDATE CASCADE;
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "BlockedUser" ADD CONSTRAINT "BlockedUser_blockedId_fkey" FOREIGN KEY ("blockedId") REFERENCES "User"("id") ON DELETE RESTRICT ON UPDATE CASCADE;
|
||||
@@ -0,0 +1,14 @@
|
||||
/*
|
||||
Warnings:
|
||||
|
||||
- You are about to drop the `MenuFeature` table. If the table is not empty, all the data it contains will be lost.
|
||||
|
||||
*/
|
||||
-- DropForeignKey
|
||||
ALTER TABLE "BlockedUser" DROP CONSTRAINT "BlockedUser_menuFeatureId_fkey";
|
||||
|
||||
-- DropTable
|
||||
DROP TABLE "MenuFeature";
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "BlockedUser" ADD CONSTRAINT "BlockedUser_menuFeatureId_fkey" FOREIGN KEY ("menuFeatureId") REFERENCES "MasterKategoriApp"("id") ON DELETE RESTRICT ON UPDATE CASCADE;
|
||||
@@ -0,0 +1,3 @@
|
||||
-- AlterTable
|
||||
ALTER TABLE "User" ADD COLUMN "acceptedForumTermsAt" TIMESTAMP(3),
|
||||
ADD COLUMN "acceptedTermsAt" TIMESTAMP(3);
|
||||
@@ -0,0 +1,28 @@
|
||||
-- AlterTable
|
||||
ALTER TABLE "Notifikasi" ADD COLUMN "deepLink" TEXT,
|
||||
ADD COLUMN "readAt" TIMESTAMP(3);
|
||||
|
||||
-- CreateTable
|
||||
CREATE TABLE "TokenUserDevice" (
|
||||
"id" TEXT NOT NULL,
|
||||
"isActive" BOOLEAN NOT NULL DEFAULT true,
|
||||
"createdAt" TIMESTAMP(3) NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
"updatedAt" TIMESTAMP(3) NOT NULL,
|
||||
"platform" TEXT,
|
||||
"deviceId" TEXT,
|
||||
"model" TEXT,
|
||||
"appVersion" TEXT,
|
||||
"token" TEXT NOT NULL,
|
||||
"userId" TEXT,
|
||||
|
||||
CONSTRAINT "TokenUserDevice_pkey" PRIMARY KEY ("id")
|
||||
);
|
||||
|
||||
-- CreateIndex
|
||||
CREATE INDEX "TokenUserDevice_userId_idx" ON "TokenUserDevice"("userId");
|
||||
|
||||
-- CreateIndex
|
||||
CREATE INDEX "TokenUserDevice_token_idx" ON "TokenUserDevice"("token");
|
||||
|
||||
-- AddForeignKey
|
||||
ALTER TABLE "TokenUserDevice" ADD CONSTRAINT "TokenUserDevice_userId_fkey" FOREIGN KEY ("userId") REFERENCES "User"("id") ON DELETE SET NULL ON UPDATE CASCADE;
|
||||
@@ -1,3 +1,3 @@
|
||||
# Please do not edit this file manually
|
||||
# It should be added in your version-control system (i.e. Git)
|
||||
# It should be added in your version-control system (e.g., Git)
|
||||
provider = "postgresql"
|
||||
@@ -2,8 +2,9 @@
|
||||
// learn more about it in the docs: https://pris.ly/d/prisma-schema
|
||||
|
||||
generator client {
|
||||
provider = "prisma-client-js"
|
||||
engineType = "binary"
|
||||
provider = "prisma-client-js"
|
||||
engineType = "binary"
|
||||
binaryTargets = ["native"]
|
||||
}
|
||||
|
||||
datasource db {
|
||||
@@ -47,6 +48,17 @@ model User {
|
||||
User_Notifikasi Notifikasi[] @relation("UserNotifikasi")
|
||||
BusinessMaps BusinessMaps[]
|
||||
Investasi_Invoice Investasi_Invoice[]
|
||||
|
||||
EventSponsor EventSponsor[]
|
||||
EventTransaksi EventTransaksi[]
|
||||
termsOfServiceAccepted Boolean @default(false)
|
||||
|
||||
blockedUsers BlockedUser[] @relation("Blocking")
|
||||
blockedBy BlockedUser[] @relation("BlockedBy")
|
||||
|
||||
acceptedTermsAt DateTime?
|
||||
acceptedForumTermsAt DateTime?
|
||||
tokenUserDevices TokenUserDevice[]
|
||||
}
|
||||
|
||||
model MasterUserRole {
|
||||
@@ -125,11 +137,13 @@ model Portofolio {
|
||||
updatedAt DateTime @default(now()) @updatedAt
|
||||
Profile Profile? @relation(fields: [profileId], references: [id])
|
||||
profileId String?
|
||||
MasterBidangBisnis MasterBidangBisnis @relation(fields: [masterBidangBisnisId], references: [id])
|
||||
masterBidangBisnisId String
|
||||
Portofolio_MediaSosial Portofolio_MediaSosial?
|
||||
BusinessMaps BusinessMaps?
|
||||
logoId String?
|
||||
|
||||
MasterBidangBisnis MasterBidangBisnis @relation(fields: [masterBidangBisnisId], references: [id])
|
||||
masterBidangBisnisId String
|
||||
Portofolio_BidangDanSubBidangBisnis Portofolio_BidangDanSubBidangBisnis[]
|
||||
}
|
||||
|
||||
model Portofolio_MediaSosial {
|
||||
@@ -146,17 +160,46 @@ model Portofolio_MediaSosial {
|
||||
portofolioId String? @unique
|
||||
}
|
||||
|
||||
model MasterBidangBisnis {
|
||||
id String @id
|
||||
name String
|
||||
active Boolean @default(true)
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @default(now()) @updatedAt
|
||||
Portofolio Portofolio[]
|
||||
model Portofolio_BidangDanSubBidangBisnis {
|
||||
id String @id @default(cuid())
|
||||
isActive Boolean @default(true)
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
|
||||
Portofolio Portofolio? @relation(fields: [portofolioId], references: [id])
|
||||
portofolioId String?
|
||||
MasterBidangBisnis MasterBidangBisnis? @relation(fields: [masterBidangBisnisId], references: [id])
|
||||
masterBidangBisnisId String?
|
||||
MasterSubBidangBisnis MasterSubBidangBisnis? @relation(fields: [masterSubBidangBisnisId], references: [id])
|
||||
masterSubBidangBisnisId String?
|
||||
}
|
||||
|
||||
// ------------------- MASTER -------------------------- //
|
||||
|
||||
model MasterBidangBisnis {
|
||||
id String @id @default(uuid())
|
||||
name String
|
||||
slug String @default("NULL")
|
||||
active Boolean @default(true)
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @default(now()) @updatedAt
|
||||
Portofolio Portofolio[]
|
||||
MasterSubBidangBisnis MasterSubBidangBisnis[]
|
||||
Portofolio_BidangDanSubBidangBisnis Portofolio_BidangDanSubBidangBisnis[]
|
||||
}
|
||||
|
||||
model MasterSubBidangBisnis {
|
||||
id String @id @default(cuid())
|
||||
name String
|
||||
slug String @default("NULL")
|
||||
isActive Boolean @default(true)
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @default(now()) @updatedAt
|
||||
MasterBidangBisnis MasterBidangBisnis? @relation(fields: [masterBidangBisnisId], references: [id])
|
||||
masterBidangBisnisId String?
|
||||
Portofolio_BidangDanSubBidangBisnis Portofolio_BidangDanSubBidangBisnis[]
|
||||
}
|
||||
|
||||
model MasterBank {
|
||||
id String @id @default(cuid())
|
||||
namaBank String
|
||||
@@ -166,6 +209,8 @@ model MasterBank {
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
Investasi_Invoice Investasi_Invoice[]
|
||||
EventTransaksi EventTransaksi[]
|
||||
Donasi_Invoice Donasi_Invoice[]
|
||||
}
|
||||
|
||||
model MasterStatus {
|
||||
@@ -177,6 +222,25 @@ model MasterStatus {
|
||||
Job Job[]
|
||||
}
|
||||
|
||||
model MasterStatusTransaksi {
|
||||
id String @id @default(cuid())
|
||||
name String
|
||||
isActive Boolean @default(true)
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
EventTransaksi EventTransaksi[]
|
||||
}
|
||||
|
||||
model MasterEmotions {
|
||||
id Int @id @default(autoincrement())
|
||||
label String
|
||||
value String @unique
|
||||
isActive Boolean @default(true)
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
Sticker Sticker[] @relation("StikerEmotions")
|
||||
}
|
||||
|
||||
// -------------------- INVESTASI --------------------- //
|
||||
// Table investasi / saham
|
||||
model Investasi {
|
||||
@@ -521,7 +585,9 @@ model Donasi_Invoice {
|
||||
Images Images? @relation(fields: [imagesId], references: [id])
|
||||
imagesId String?
|
||||
|
||||
imageId String?
|
||||
imageId String?
|
||||
MasterBank MasterBank? @relation(fields: [masterBankId], references: [id])
|
||||
masterBankId String? @default("null")
|
||||
}
|
||||
|
||||
model Donasi_Kabar {
|
||||
@@ -593,6 +659,8 @@ model Event {
|
||||
Event_Peserta Event_Peserta[]
|
||||
EventMaster_TipeAcara EventMaster_TipeAcara? @relation(fields: [eventMaster_TipeAcaraId], references: [id])
|
||||
eventMaster_TipeAcaraId Int?
|
||||
EventSponsor EventSponsor[]
|
||||
EventTransaksi EventTransaksi[]
|
||||
}
|
||||
|
||||
model EventMaster_TipeAcara {
|
||||
@@ -618,6 +686,7 @@ model Event_Peserta {
|
||||
active Boolean @default(true)
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
isPresent Boolean @default(false)
|
||||
|
||||
Event Event? @relation(fields: [eventId], references: [id])
|
||||
eventId String?
|
||||
@@ -905,16 +974,19 @@ model NomorAdmin {
|
||||
}
|
||||
|
||||
model Notifikasi {
|
||||
id String @id @default(cuid())
|
||||
isActive Boolean @default(true)
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
isRead Boolean @default(false)
|
||||
id String @id @default(cuid())
|
||||
isActive Boolean @default(true)
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
appId String
|
||||
kategoriApp String
|
||||
pesan String
|
||||
title String?
|
||||
status String?
|
||||
|
||||
isRead Boolean @default(false)
|
||||
readAt DateTime? // kapan user membaca notifikasi ini
|
||||
deepLink String? // misal: "announcement/123", "user/profile/cmha6wb9w0001cfndwl9fcse6"
|
||||
|
||||
Role MasterUserRole? @relation(fields: [userRoleId], references: [id])
|
||||
userRoleId String
|
||||
@@ -950,4 +1022,103 @@ model MasterKategoriApp {
|
||||
updatedAt DateTime @updatedAt
|
||||
name String
|
||||
value String?
|
||||
|
||||
blockedUsers BlockedUser[]
|
||||
}
|
||||
|
||||
// ======================= EVENT ======================= //
|
||||
|
||||
model EventSponsor {
|
||||
id String @id @default(cuid())
|
||||
isActive Boolean @default(true)
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
name String
|
||||
isTransfer Boolean? @default(false)
|
||||
fileName String
|
||||
fileExt String?
|
||||
fileId String
|
||||
|
||||
Author User? @relation(fields: [authorId], references: [id])
|
||||
authorId String?
|
||||
|
||||
Event Event? @relation(fields: [eventId], references: [id])
|
||||
eventId String?
|
||||
|
||||
EventTransaksi EventTransaksi?
|
||||
}
|
||||
|
||||
model EventTransaksi {
|
||||
id String @id @default(cuid())
|
||||
isActive Boolean @default(true)
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
nominal Int
|
||||
status String
|
||||
transferImageId String?
|
||||
|
||||
MasterBank MasterBank? @relation(fields: [masterBankId], references: [id])
|
||||
masterBankId String?
|
||||
|
||||
AuthorId User? @relation(fields: [authorId], references: [id])
|
||||
authorId String?
|
||||
|
||||
Event Event? @relation(fields: [eventId], references: [id])
|
||||
eventId String?
|
||||
|
||||
EventSponsor EventSponsor? @relation(fields: [eventSponsorId], references: [id])
|
||||
eventSponsorId String? @unique
|
||||
|
||||
MasterStatusTransaksi MasterStatusTransaksi? @relation(fields: [masterStatusTransaksiId], references: [id])
|
||||
masterStatusTransaksiId String?
|
||||
}
|
||||
|
||||
model Sticker {
|
||||
id String @id @default(cuid())
|
||||
isActive Boolean @default(true)
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
name String?
|
||||
fileName String?
|
||||
fileExt String?
|
||||
fileId String
|
||||
jenisKelamin String?
|
||||
|
||||
MasterEmotions MasterEmotions[] @relation("StikerEmotions")
|
||||
}
|
||||
|
||||
model BlockedUser {
|
||||
id String @id @default(uuid())
|
||||
isActive Boolean @default(true)
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
blockerId String // ID user yang memblokir
|
||||
blockedId String // ID user yang diblokir
|
||||
|
||||
menuFeatureId String
|
||||
menuFeature MasterKategoriApp @relation(fields: [menuFeatureId], references: [id])
|
||||
|
||||
blocker User @relation("BlockedBy", fields: [blockerId], references: [id])
|
||||
blocked User @relation("Blocking", fields: [blockedId], references: [id])
|
||||
|
||||
@@unique([blockerId, blockedId])
|
||||
}
|
||||
|
||||
model TokenUserDevice {
|
||||
id String @id @default(uuid())
|
||||
isActive Boolean @default(true)
|
||||
createdAt DateTime @default(now())
|
||||
updatedAt DateTime @updatedAt
|
||||
|
||||
platform String? // "ios" | "android"
|
||||
deviceId String? // UUID unik dari device (misal: dari expo-device)
|
||||
model String? // "iPhone15,4", "Pixel 7", dll
|
||||
appVersion String? // "1.5.15" — sangat berguna saat debug
|
||||
|
||||
token String @db.Text
|
||||
user User? @relation(fields: [userId], references: [id])
|
||||
userId String?
|
||||
|
||||
@@index([userId])
|
||||
@@index([token]) // untuk pencarian cepat & deduplikasi
|
||||
}
|
||||
|
||||
1098
prisma/schema.prisma.backup
Normal file
1098
prisma/schema.prisma.backup
Normal file
File diff suppressed because it is too large
Load Diff
@@ -1,16 +1,16 @@
|
||||
import prisma from "./../src/app/lib/prisma";
|
||||
import prisma from "../src/lib/prisma";
|
||||
import { generate_seeder } from "./../src/app_modules/_global/fun/generate_seeder";
|
||||
|
||||
(async () => {
|
||||
console.log("start");
|
||||
console.log("start seeder >>");
|
||||
await generate_seeder();
|
||||
})()
|
||||
.then(() => {
|
||||
console.log("success");
|
||||
console.log("<< success seeder");
|
||||
process.exit(0);
|
||||
})
|
||||
.catch((e) => {
|
||||
console.error(e);
|
||||
console.error("<< error seeder", e);
|
||||
process.exit(1);
|
||||
})
|
||||
.finally(async () => {
|
||||
|
||||
11
public/.well-known/apple-app-site-association
Normal file
11
public/.well-known/apple-app-site-association
Normal file
@@ -0,0 +1,11 @@
|
||||
{
|
||||
"applinks": {
|
||||
"apps": [],
|
||||
"details": [
|
||||
{
|
||||
"appID": "BMY6GT6W3D.com.anonymous.hipmi-mobile",
|
||||
"paths": ["*"]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
8
public/.well-known/assetlinks.json
Normal file
8
public/.well-known/assetlinks.json
Normal file
@@ -0,0 +1,8 @@
|
||||
[{
|
||||
"relation": ["delegate_permission/common.handle_all_urls"],
|
||||
"target": {
|
||||
"namespace": "android_app",
|
||||
"package_name": "com.bip.hipmimobileapp",
|
||||
"sha256_cert_fingerprints": ["CFF8431520BFAE665025B68138774A4E64AA6338D2DF6C7D900A71F0551FFD2D"]
|
||||
}
|
||||
}]
|
||||
BIN
public/aset/global/dummy-image.jpg
Normal file
BIN
public/aset/global/dummy-image.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 20 KiB |
BIN
public/aset/home/home-hipmi-new.png
Normal file
BIN
public/aset/home/home-hipmi-new.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 128 KiB |
BIN
public/aset/investasi/logo-crowd-panjang-new.png
Normal file
BIN
public/aset/investasi/logo-crowd-panjang-new.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 331 KiB |
BIN
public/aset/logo/hiconnect.png
Normal file
BIN
public/aset/logo/hiconnect.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 509 KiB |
301
public/privacy-policy.html
Normal file
301
public/privacy-policy.html
Normal file
@@ -0,0 +1,301 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Privacy Policy</title>
|
||||
<style>
|
||||
body {
|
||||
font-family: Arial, sans-serif;
|
||||
line-height: 1.6;
|
||||
color: #333;
|
||||
max-width: 900px;
|
||||
margin: 40px auto;
|
||||
padding: 20px;
|
||||
}
|
||||
h1 {
|
||||
font-size: 2em;
|
||||
font-weight: bold;
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
.last-updated {
|
||||
color: #777;
|
||||
font-style: italic;
|
||||
margin-bottom: 25px;
|
||||
}
|
||||
p {
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
ul {
|
||||
margin: 15px 0;
|
||||
padding-left: 20px;
|
||||
}
|
||||
li {
|
||||
margin-bottom: 8px;
|
||||
}
|
||||
strong {
|
||||
font-weight: bold;
|
||||
}
|
||||
a {
|
||||
color: #0066cc;
|
||||
text-decoration: none;
|
||||
}
|
||||
a:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
.summary-box {
|
||||
background-color: #faf8e8;
|
||||
padding: 20px;
|
||||
border-radius: 8px;
|
||||
margin: 25px 0;
|
||||
}
|
||||
.summary-box h3 {
|
||||
margin-top: 0;
|
||||
font-size: 1.2em;
|
||||
}
|
||||
.section-title {
|
||||
font-size: 1.5em;
|
||||
font-weight: bold;
|
||||
margin-top: 30px;
|
||||
margin-bottom: 15px;
|
||||
}
|
||||
address {
|
||||
margin-top: 15px;
|
||||
font-style: normal;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h1>Privacy Policy</h1>
|
||||
<div class="last-updated">Last updated November 06, 2025</div>
|
||||
|
||||
<p>This Privacy Notice for Bali Interaktif Perkasa ("<strong>we</strong>", "<strong>us</strong>", or "<strong>our</strong>"), describes how and why we might access, collect, store, use, and/or share ("<strong>process</strong>") your personal information when you use our services ("<strong>Services</strong>"), including when you:</p>
|
||||
|
||||
<ul>
|
||||
<li>Download and use our mobile application (HIPMI Badung Connect), or any other application of ours that links to this Privacy Notice</li>
|
||||
|
||||
<li>Use HIPMI Badung Connect. HIPMI Badung Connect is an official digital platform developed to support the network of members of HIPMI (Himpunan Pengusaha Muda Indonesia – Indonesian Young Entrepreneurs Association) in Badung Regency. The app aims to strengthen collaboration, partnerships, and the business ecosystem among young entrepreneurs through a range of interactive and informative features. Key features of the app include:
|
||||
<ul style="list-style-type: none; padding-left: 0;">
|
||||
<li><strong>Profile:</strong> Displays users’ personal and professional background as HIPMI Badung members.</li>
|
||||
<li><strong>Business Portfolio:</strong> Allows users to showcase their business name, business information, and associated social media links.</li>
|
||||
<li><strong>User Search:</strong> Enables members to discover and connect with other users based on specific criteria.</li>
|
||||
<li><strong>Events:</strong> Provides information and registration for business events, seminars, workshops, and HIPMI Badung community activities.</li>
|
||||
<li><strong>Voting:</strong> Supports internal organizational decision-making through a digital voting system.</li>
|
||||
<li><strong>Collaboration Projects:</strong> Serves as a hub for initiating, managing, and participating in joint business initiatives.</li>
|
||||
<li><strong>Job Search:</strong> Offers job postings and career opportunities within the members’ business ecosystem.</li>
|
||||
<li><strong>Forum:</strong> An interactive space for members to exchange ideas, ask questions, and share solutions related to entrepreneurship.</li>
|
||||
<li><strong>Business Map (Maps):</strong> Displays the physical locations of members’ businesses to facilitate networking and in-person visits.</li>
|
||||
<li><strong>Crowdfunding:</strong> Includes two funding mechanisms—Investment (for business opportunities offering returns) and Donation (for social support with no expectation of return).</li>
|
||||
</ul>
|
||||
This app is designed to uphold user data integrity while promoting transparency, collaboration, and sustainable economic growth among young entrepreneurs in Badung. All personal and business information collected through the app is used solely to enable core functionalities and is managed in accordance with applicable privacy policies.
|
||||
</li>
|
||||
|
||||
<li>Engage with us in other related ways, including any sales, marketing, or events</li>
|
||||
</ul>
|
||||
|
||||
<p><strong>Questions or concerns?</strong> Reading this Privacy Notice will help you understand your privacy rights and choices. We are responsible for making decisions about how your personal information is processed. If you do not agree with our policies and practices, please do not use our Services. If you still have any questions or concerns, please contact us at <a href="mailto:bip.baliinteraktifperkasa@gmail.com">bip.baliinteraktifperkasa@gmail.com</a>.</p>
|
||||
|
||||
<!-- SUMMARY OF KEY POINTS -->
|
||||
<div class="summary-box">
|
||||
<h3>Summary of Key Points</h3>
|
||||
<p>This summary provides key points from our Privacy Notice, but you can find out more details about any of these topics by using the table of contents below.</p>
|
||||
|
||||
<ul>
|
||||
<li><strong>What personal information do we process?</strong> We may process personal information depending on how you interact with us and the Services, the choices you make, and the products and features you use.</li>
|
||||
<li><strong>Do we process any sensitive personal information?</strong> We do not process sensitive personal information.</li>
|
||||
<li><strong>Do we collect any information from third parties?</strong> We do not collect any information from third parties.</li>
|
||||
<li><strong>How do we process your information?</strong> To provide, improve, and administer our Services; communicate with you; for security and fraud prevention; and to comply with law.</li>
|
||||
<li><strong>In what situations and with which parties do we share personal information?</strong> We may share information in specific situations and with specific third parties.</li>
|
||||
<li><strong>How do we keep your information safe?</strong> We have adequate organizational and technical processes in place to protect your personal information.</li>
|
||||
<li><strong>What are your rights?</strong> Depending on where you are located geographically, you may have certain rights regarding your personal information.</li>
|
||||
<li><strong>How do you exercise your rights?</strong> By submitting a data subject access request, or by contacting us.</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<!-- TABLE OF CONTENTS -->
|
||||
<h3>Table of Contents</h3>
|
||||
<ol>
|
||||
<li><a href="#section1">WHAT INFORMATION DO WE COLLECT?</a></li>
|
||||
<li><a href="#section2">HOW DO WE PROCESS YOUR INFORMATION?</a></li>
|
||||
<li><a href="#section3">WHEN AND WITH WHOM DO WE SHARE YOUR PERSONAL INFORMATION?</a></li>
|
||||
<li><a href="#section4">DO WE USE COOKIES AND OTHER TRACKING TECHNOLOGIES?</a></li>
|
||||
<li><a href="#section5">HOW LONG DO WE KEEP YOUR INFORMATION?</a></li>
|
||||
<li><a href="#section6">HOW DO WE KEEP YOUR INFORMATION SAFE?</a></li>
|
||||
<li><a href="#section7">DO WE COLLECT INFORMATION FROM MINORS?</a></li>
|
||||
<li><a href="#section8">WHAT ARE YOUR PRIVACY RIGHTS?</a></li>
|
||||
<li><a href="#section9">CONTROLS FOR DO-NOT-TRACK FEATURES</a></li>
|
||||
<li><a href="#section10">DO WE MAKE UPDATES TO THIS NOTICE?</a></li>
|
||||
<li><a href="#section11">HOW CAN YOU CONTACT US ABOUT THIS NOTICE?</a></li>
|
||||
<li><a href="#section12">HOW CAN YOU REVIEW, UPDATE, OR DELETE THE DATA WE COLLECT FROM YOU?</a></li>
|
||||
</ol>
|
||||
|
||||
<!-- SECTION 1 -->
|
||||
<div id="section1" class="section-title">1. WHAT INFORMATION DO WE COLLECT?</div>
|
||||
<h4>Personal information you disclose to us</h4>
|
||||
<p><em>In Short:</em> We collect personal information that you provide to us.</p>
|
||||
<p>We collect personal information that you voluntarily provide to us when you register on the Services, express an interest in obtaining information about us or our products and Services, when you participate in activities on the Services, or otherwise when you contact us.</p>
|
||||
<h4>Personal Information Provided by You.</h4>
|
||||
<p>The personal information that we collect depends on the context of your interactions with us and the Services, the choices you make, and the products and features you use. The personal information we collect may include the following:</p>
|
||||
<ul>
|
||||
<li>names</li>
|
||||
<li>phone numbers</li>
|
||||
<li>email addresses</li>
|
||||
<li>usernames</li>
|
||||
</ul>
|
||||
<h4>Sensitive Information.</h4>
|
||||
<p>We do not process sensitive information.</p>
|
||||
<h4>Application Data.</h4>
|
||||
<p>If you use our application(s), we also may collect the following information if you choose to provide us with access or permission:</p>
|
||||
<ul>
|
||||
<li><strong>Geolocation Information.</strong> We may request access or permission to track location-based information from your mobile device, either continuously or while you are using our mobile application(s), to provide certain location-based services. If you wish to change our access or permissions, you may do so in your device's settings.</li>
|
||||
<li><strong>Mobile Device Data.</strong> We automatically collect device information (such as your mobile device ID, model, and manufacturer), operating system, version information and system configuration information, device and application identification numbers, browser type and version, hardware model Internet service provider and/or mobile carrier, and Internet Protocol (IP) address (or proxy server). If you are using our application(s), we may also collect information about the phone network associated with your mobile device, your mobile device’s operating system or platform, the type of mobile device you use, your mobile device’s unique device ID, and information about the features of our application(s) you accessed.</li>
|
||||
<li><strong>Push Notifications.</strong> We may request to send you push notifications regarding your account or certain features of the application(s). If you wish to opt out from receiving these types of communications, you may turn them off in your device's settings.</li>
|
||||
</ul>
|
||||
<p>This information is primarily needed to maintain the security and operation of our application(s), for troubleshooting, and for our internal analytics and reporting purposes.</p>
|
||||
<p>All personal information that you provide to us must be true, complete, and accurate, and you must notify us of any changes to such personal information.</p>
|
||||
<h4>Information automatically collected</h4>
|
||||
<p><em>In Short:</em> Some information — such as your Internet Protocol (IP) address and/or browser and device characteristics — is collected automatically when you visit our Services.</p>
|
||||
<p>We automatically collect certain information when you visit, use, or navigate the Services. This information does not reveal your specific identity (like your name or contact information) but may include device and usage information, such as your IP address, browser and device characteristics, operating system, language preferences, referring URLs, device name, country, location, information about how and when you use our Services, and other technical information. This information is primarily needed to maintain the security and operation of our Services, and for our internal analytics and reporting purposes.</p>
|
||||
<p>Like many businesses, we also collect information through cookies and similar technologies.</p>
|
||||
<h4>The information we collect includes:</h4>
|
||||
<ul>
|
||||
<li><strong>Log and Usage Data.</strong> Log and usage data is service-related, diagnostic, usage, and performance information our servers automatically collect when you access or use our Services and which we record in log files. Depending on how you interact with us, this log data may include your IP address, device information, browser type, and settings and information about your activity in the Services (such as the date/time stamps associated with your usage, pages and files viewed, searches, and other actions you take such as which features you use), device event information (such as system activity, error reports (sometimes called "crash dumps"), and hardware settings).</li>
|
||||
<li><strong>Device Data.</strong> We collect device data such as information about your computer, phone, tablet, or other device you use to access the Services. Depending on the device used, this device data may include information such as your IP address (or proxy server), device and application identification numbers, location, browser type, hardware model, Internet service provider and/or mobile carrier, operating system, and system configuration information.</li>
|
||||
<li><strong>Location Data.</strong> We collect location data such as information about your device's location, which can be either precise or imprecise. How much information we collect depends on the type and settings of the device you use to access the Services. For example, we may use GPS and other technologies to collect geolocation data that tells us your current location (based on your IP address). You can opt out of allowing us to collect this information either by refusing access to the information or by disabling your Location setting on your device. However, if you choose to opt out, you may not be able to use certain aspects of the Services.</li>
|
||||
</ul>
|
||||
<h4>Google API</h4>
|
||||
<p>Our use of information received from Google APIs will adhere to <a href="https://developers.google.com/terms/api-services-user-data-policy" target="_blank">Google API Services User Data Policy</a>, including the <a href="https://developers.google.com/terms/api-services-user-data-policy#limited-use" target="_blank">Limited Use requirements</a>.</p>
|
||||
|
||||
<!-- SECTION 2 -->
|
||||
<div id="section2" class="section-title">2. HOW DO WE PROCESS YOUR INFORMATION?</div>
|
||||
<p><em>In Short:</em> We process your information to provide, improve, and administer our Services, communicate with you, for security and fraud prevention, and to comply with law. We may also process your information for other purposes with your consent.</p>
|
||||
<p>We process your personal information for a variety of reasons, depending on how you interact with our Services, including:</p>
|
||||
<ul>
|
||||
<li><strong>To facilitate account creation and authentication and otherwise manage user accounts.</strong> We may process your information so you can create and log in to your account, as well as keep your account in working order.</li>
|
||||
<li><strong>To deliver and facilitate delivery of services to the user.</strong> We may process your information to provide you with the requested service.</li>
|
||||
<li><strong>To respond to user inquiries/offer support to users.</strong> We may process your information to respond to your inquiries and solve any potential issues you might have with the requested service.</li>
|
||||
<li><strong>To send administrative information to you.</strong> We may process your information to send you details about our products and services, changes to our terms and policies, and other similar information.</li>
|
||||
<li><strong>To enable user-to-user communications.</strong> We may process your information if you choose to use any of our offerings that allow for communication with another user.</li>
|
||||
<li><strong>To request feedback.</strong> We may process your information when necessary to request feedback and to contact you about your use of our Services.</li>
|
||||
<li><strong>To send you marketing and promotional communications.</strong> We may process the personal information you send to us for our marketing purposes, if this is in accordance with your marketing preferences. You can opt out of our marketing emails at any time. For more information, see "<a href="#section8">WHAT ARE YOUR PRIVACY RIGHTS?</a>" below.</li>
|
||||
<li><strong>To protect our Services.</strong> We may process your information as part of our efforts to keep our Services safe and secure, including fraud monitoring and prevention.</li>
|
||||
<li><strong>To evaluate and improve our Services, products, marketing, and your experience.</strong> We may process your information when we believe it is necessary to identify usage trends, determine the effectiveness of our promotional campaigns, and to evaluate and improve our Services, products, marketing, and your experience.</li>
|
||||
<li><strong>To identify usage trends.</strong> We may process information about how you use our Services to better understand how they are being used so we can improve them.</li>
|
||||
</ul>
|
||||
|
||||
<!-- SECTION 3 -->
|
||||
<div id="section3" class="section-title">3. WHEN AND WITH WHOM DO WE SHARE YOUR PERSONAL INFORMATION?</div>
|
||||
<p><em>In Short:</em> We may share information in specific situations described in this section and/or with the following third parties.</p>
|
||||
<h4>Vendors, Consultants, and Other Third-Party Service Providers.</h4>
|
||||
<p>We may share your data with third-party vendors, service providers, contractors, or agents (“<strong>third parties</strong>”) who perform services for us or on our behalf and require access to such information to do that work. We have contracts in place with our third parties, which are designed to help safeguard your personal information. This means that they cannot do anything with your personal information unless we have instructed them to do it. They will also not share your personal information with any organization apart from us. They also commit to protect the data they hold on our behalf and to retain it for the period we instruct.</p>
|
||||
<p>The third parties we may share personal information with are as follows:</p>
|
||||
<ul>
|
||||
<li><strong>Cloud Computing Services</strong>
|
||||
<ul style="list-style-type: none; padding-left: 15px;">
|
||||
<li>Google Cloud Platform</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><strong>Functionality and Infrastructure Optimization</strong>
|
||||
<ul style="list-style-type: none; padding-left: 15px;">
|
||||
<li>Firebase Realtime Database</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><strong>Web and Mobile Analytics</strong>
|
||||
<ul style="list-style-type: none; padding-left: 15px;">
|
||||
<li>Google Analytics for Firebase</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><strong>Website Performance Monitoring</strong>
|
||||
<ul style="list-style-type: none; padding-left: 15px;">
|
||||
<li>Firebase Crash Reporting</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><strong>Website Testing</strong>
|
||||
<ul style="list-style-type: none; padding-left: 15px;">
|
||||
<li>Google Play Console and TestFlight</li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
<p>We also may need to share your personal information in the following situations:</p>
|
||||
<ul>
|
||||
<li><strong>Business Transfers.</strong> We may share or transfer your information in connection with, or during negotiations of, any merger, sale of company assets, financing, or acquisition of all or a portion of our business to another company.</li>
|
||||
<li><strong>When we use Google Maps Platform APIs.</strong> We may share your information with certain Google Maps Platform APIs (e.g., Google Maps API, Places API). Google Maps uses GPS, Wi-Fi, and cell towers to estimate your location. GPS is accurate to about 20 meters, while Wi-Fi and cell towers help improve accuracy when GPS signals are weak, like indoors. This data helps Google Maps provide directions, but it is not always perfectly precise. We obtain and store on your device (“cache”) your location. You may revoke your consent anytime by contacting us at the contact details provided at the end of this document.</li>
|
||||
<li><strong>Business Partners.</strong> We may share your information with our business partners to offer you certain products, services, or promotions.</li>
|
||||
<li><strong>Other Users.</strong> When you share personal information (for example, by posting comments, contributions, or other content to the Services) or otherwise interact with public areas of the Services, such personal information may be viewed by all users and may be publicly made available outside the Services in perpetuity. Similarly, other users will be able to view descriptions of your activity, communicate with you within our Services, and view your profile.</li>
|
||||
</ul>
|
||||
|
||||
<!-- SECTION 4 -->
|
||||
<div id="section4" class="section-title">4. DO WE USE COOKIES AND OTHER TRACKING TECHNOLOGIES?</div>
|
||||
<p><em>In Short:</em> We may use cookies and other tracking technologies to collect and store your information.</p>
|
||||
<p>We may use cookies and similar tracking technologies (like web beacons and pixels) to gather information when you interact with our Services. Some online tracking technologies help us maintain the security of our Services and your account, prevent crashes, fix bugs, save your preferences, and assist with basic site functions.</p>
|
||||
<p>We also permit third parties and service providers to use online tracking technologies on our Services for analytics and advertising, including to help manage and display advertisements, to tailor advertisements to your interests, or to send abandoned shopping cart reminders (depending on your communication preferences). The third parties and service providers use their technology to provide advertising about products and services tailored to your interests which may appear either on our Services or on other websites.</p>
|
||||
<p>Specific information about how we use such technologies and how you can refuse certain cookies is set out in our Cookie Notice.</p>
|
||||
<h4>Google Analytics</h4>
|
||||
<p>We may share your information with Google Analytics to track and analyze the use of the Services. To opt out of being tracked by Google Analytics across the Services, visit <a href="https://tools.google.com/dlpage/gaoptout" target="_blank">https://tools.google.com/dlpage/gaoptout</a>. For more information on the privacy practices of Google, please visit the <a href="https://policies.google.com/privacy" target="_blank">Google Privacy & Terms page</a>.</p>
|
||||
|
||||
<!-- SECTION 5 -->
|
||||
<div id="section5" class="section-title">5. HOW LONG DO WE KEEP YOUR INFORMATION?</div>
|
||||
<p><em>In Short:</em> We keep your information for as long as necessary to fulfill the purposes outlined in this Privacy Notice unless otherwise required by law.</p>
|
||||
<p>We will only keep your personal information for as long as it is necessary for the purposes set out in this Privacy Notice, unless a longer retention period is required or permitted by law (such as tax, accounting, or other legal requirements). No purpose in this notice will require us keeping your personal information for longer than the period of time in which users have an account with us.</p>
|
||||
<p>When we have no ongoing legitimate business need to process your personal information, we will either delete or anonymize such information, or, if this is not possible (for example, because your personal information has been stored in backup archives), then we will securely store your personal information and isolate it from any further processing until deletion is possible.</p>
|
||||
|
||||
<!-- SECTION 6 -->
|
||||
<div id="section6" class="section-title">6. HOW DO WE KEEP YOUR INFORMATION SAFE?</div>
|
||||
<p><em>In Short:</em> We aim to protect your personal information through a system of organizational and technical security measures.</p>
|
||||
<p>We have implemented appropriate and reasonable technical and organizational security measures designed to protect the security of any personal information we process. However, despite our safeguards and efforts to secure your information, no electronic transmission over the Internet or information storage technology can be guaranteed to be 100% secure, so we cannot promise or guarantee that hackers, cybercriminals, or other unauthorized third parties will not be able to defeat our security and improperly collect, access, steal, or modify your information. Although we will do our best to protect your personal information, transmission of personal information to and from our Services is at your own risk. You should only access the Services within a secure environment.</p>
|
||||
|
||||
<!-- SECTION 7 -->
|
||||
<div id="section7" class="section-title">7. DO WE COLLECT INFORMATION FROM MINORS?</div>
|
||||
<p><em>In Short:</em> We do not knowingly collect data from or market to minors.</p>
|
||||
<p>HIPMI Badung Connect is not intended for use by individuals under the age of 18. We do not knowingly collect personal information from children under 18. If we become aware that we have inadvertently collected such information, we will take steps to delete it as soon as possible.</p>
|
||||
|
||||
<!-- SECTION 8 -->
|
||||
<div id="section8" class="section-title">8. WHAT ARE YOUR PRIVACY RIGHTS?</div>
|
||||
<p><em>In Short:</em> You may review, change, or terminate your account at any time, depending on your country, province, or state of residence.</p>
|
||||
<h4>Withdrawing your consent:</h4>
|
||||
<p>If we are relying on your consent to process your personal information, which may be express and/or implied consent depending on the applicable law, you have the right to withdraw your consent at any time. You can withdraw your consent at any time by contacting us by using the contact details provided in the section "<a href="#section11">HOW CAN YOU CONTACT US ABOUT THIS NOTICE?</a>" below.</p>
|
||||
<p>However, please note that this will not affect the lawfulness of the processing before its withdrawal nor, when applicable law allows, will it affect the processing of your personal information conducted in reliance on lawful processing grounds other than consent.</p>
|
||||
<h4>Opting out of marketing and promotional communications:</h4>
|
||||
<p>You can unsubscribe from our marketing and promotional communications at any time by clicking on the unsubscribe link in the emails that we send, or by contacting us using the details provided in the section "<a href="#section11">HOW CAN YOU CONTACT US ABOUT THIS NOTICE?</a>" below. You will then be removed from the marketing lists. However, we may still communicate with you — for example, to send you service-related messages that are necessary for the administration and use of your account, to respond to service requests, or for other non-marketing purposes.</p>
|
||||
<h4>Account Information</h4>
|
||||
<p>If you would at any time like to review or change the information in your account or terminate your account, you can:</p>
|
||||
<ul>
|
||||
<li>Log in to your account settings and update your user account.</li>
|
||||
<li>Contact us using the contact information provided.</li>
|
||||
<li><a href="mailto:bip.baliinteraktifperkasa@gmail.com">bip.baliinteraktifperkasa@gmail.com</a></li>
|
||||
</ul>
|
||||
<p>Upon your request to terminate your account, we will deactivate or delete your account and information from our active databases. However, we may retain some information in our files to prevent fraud, troubleshoot problems, assist with any investigations, enforce our legal terms and/or comply with applicable legal requirements.</p>
|
||||
<h4>Cookies and similar technologies:</h4>
|
||||
<p>Most Web browsers are set to accept cookies by default. If you prefer, you can usually choose to set your browser to remove cookies and to reject cookies. If you choose to remove cookies or reject cookies, this could affect certain features or services of our Services.</p>
|
||||
<p>If you have questions or comments about your privacy rights, you may email us at <a href="mailto:bip.baliinteraktifperkasa@gmail.com">bip.baliinteraktifperkasa@gmail.com</a>.</p>
|
||||
|
||||
<!-- SECTION 9 -->
|
||||
<div id="section9" class="section-title">9. CONTROLS FOR DO-NOT-TRACK FEATURES</div>
|
||||
<p>Most web browsers and some mobile operating systems and mobile applications include a Do-Not-Track ("DNT") feature or setting you can activate to signal your privacy preference not to have data about your online browsing activities monitored and collected. At this stage, no uniform technology standard for recognizing and implementing DNT signals has been finalized. As such, we do not currently respond to DNT browser signals or any other mechanism that automatically communicates your choice not to be tracked online. If a standard for online tracking is adopted that we must follow in the future, we will inform you about that practice in a revised version of this Privacy Notice.</p>
|
||||
|
||||
<!-- SECTION 10 -->
|
||||
<div id="section10" class="section-title">10. DO WE MAKE UPDATES TO THIS NOTICE?</div>
|
||||
<p><em>In Short:</em> Yes, we will update this notice as necessary to stay compliant with relevant laws.</p>
|
||||
<p>We may update this Privacy Notice from time to time. The updated version will be indicated by an updated "Revised" date at the top of this Privacy Notice. If we make material changes to this Privacy Notice, we may notify you either by prominently posting a notice of such changes or by directly sending you a notification. We encourage you to review this Privacy Notice frequently to be informed of how we are protecting your information.</p>
|
||||
|
||||
<!-- SECTION 11 -->
|
||||
<div id="section11" class="section-title">11. HOW CAN YOU CONTACT US ABOUT THIS NOTICE?</div>
|
||||
<p>If you have questions or comments about this notice, you may email us at <a href="mailto:bip.baliinteraktifperkasa@gmail.com">bip.baliinteraktifperkasa@gmail.com</a> or contact us by post at:</p>
|
||||
<address>
|
||||
Bali Interaktif Perkasa<br>
|
||||
Park23 Creative Hub, Bali Interaktif Perkasa - Private Office<br>
|
||||
Jl. Kediri 3rd Floor, Number 01 - 02, Tuban<br>
|
||||
Badung, Bali, Indonesia 80361<br>
|
||||
Indonesia
|
||||
</address>
|
||||
|
||||
<!-- SECTION 12 -->
|
||||
<div id="section12" class="section-title">12. HOW CAN YOU REVIEW, UPDATE, OR DELETE THE DATA WE COLLECT FROM YOU?</div>
|
||||
<p>You have the right to request access to the personal information we collect from you, details about how we have processed it, correct inaccuracies, or delete your personal information. You may also have the right to withdraw your consent to our processing of your personal information. These rights may be limited in some circumstances by applicable law.</p>
|
||||
<p>To make a request, please contact us at <a href="mailto:bip.baliinteraktifperkasa@gmail.com">bip.baliinteraktifperkasa@gmail.com</a>.</p>
|
||||
<hr style="margin: 30px 0; border: 0; border-top: 1px solid #eee;">
|
||||
<p>© 2025 Bali Interaktif Perkasa. All rights reserved.</p>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
110
public/terms-of-service.html
Normal file
110
public/terms-of-service.html
Normal file
@@ -0,0 +1,110 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="id">
|
||||
<head>
|
||||
<meta charset="UTF-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0"/>
|
||||
<title>Syarat & Ketentuan - HIPMI Badung Connect</title>
|
||||
<style>
|
||||
body {
|
||||
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
|
||||
line-height: 1.6;
|
||||
color: #333;
|
||||
max-width: 800px;
|
||||
margin: 40px auto;
|
||||
padding: 0 20px;
|
||||
}
|
||||
h1, h2, h3 {
|
||||
color: #1a365d;
|
||||
}
|
||||
ul {
|
||||
padding-left: 20px;
|
||||
}
|
||||
footer {
|
||||
margin-top: 40px;
|
||||
font-size: 0.9em;
|
||||
color: #666;
|
||||
border-top: 1px solid #eee;
|
||||
padding-top: 20px;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<h1>Syarat & Ketentuan Penggunaan HIPMI Badung Connect</h1>
|
||||
|
||||
<p>
|
||||
Dengan menggunakan aplikasi <strong>HIPMI Badung Connect</strong> (“Aplikasi”), Anda setuju untuk mematuhi dan terikat oleh syarat dan ketentuan berikut. Jika Anda tidak setuju dengan ketentuan ini, harap jangan gunakan Aplikasi.
|
||||
</p>
|
||||
|
||||
<h2>1. Definisi</h2>
|
||||
<p>
|
||||
<strong>HIPMI Badung Connect</strong> adalah platform digital resmi untuk anggota Himpunan Pengusaha Muda Indonesia (HIPMI) Kabupaten Badung, yang bertujuan memfasilitasi jaringan, kolaborasi, dan pertumbuhan bisnis para pengusaha muda.
|
||||
</p>
|
||||
|
||||
<h2>2. Larangan Konten Tidak Pantas</h2>
|
||||
<p>
|
||||
Anda <strong>dilarang keras</strong> memposting, mengirim, membagikan, atau mengunggah konten apa pun yang mengandung:
|
||||
</p>
|
||||
<ul>
|
||||
<li>Ujaran kebencian, diskriminasi, atau konten SARA (Suku, Agama, Ras, Antar-golongan)</li>
|
||||
<li>Pornografi, konten seksual eksplisit, atau gambar tidak senonoh</li>
|
||||
<li>Ancaman, pelecehan, bullying, atau perilaku melecehkan</li>
|
||||
<li>Informasi palsu, hoaks, spam, atau konten menyesatkan</li>
|
||||
<li>Konten ilegal, melanggar hukum, atau melanggar hak kekayaan intelektual pihak lain</li>
|
||||
<li>Promosi narkoba, perjudian, atau aktivitas ilegal lainnya</li>
|
||||
</ul>
|
||||
|
||||
<h2>3. Tanggung Jawab Pengguna</h2>
|
||||
<p>
|
||||
Anda bertanggung jawab penuh atas setiap konten yang Anda unggah atau bagikan melalui fitur-fitur berikut:
|
||||
</p>
|
||||
<ul>
|
||||
<li>Profil (bio, foto, portofolio)</li>
|
||||
<li>Forum diskusi</li>
|
||||
<li>Chat pribadi atau grup</li>
|
||||
<li>Lowongan kerja, investasi, dan donasi</li>
|
||||
</ul>
|
||||
<p>
|
||||
Konten yang melanggar ketentuan ini dapat dihapus kapan saja tanpa pemberitahuan.
|
||||
</p>
|
||||
|
||||
<h2>4. Tindakan terhadap Pelanggaran</h2>
|
||||
<p>
|
||||
Jika kami menerima laporan atau menemukan konten yang melanggar ketentuan ini, kami akan:
|
||||
</p>
|
||||
<ul>
|
||||
<li>Segera menghapus konten tersebut</li>
|
||||
<li>Memberikan peringatan atau memblokir akun pengguna</li>
|
||||
<li>Dalam kasus berat, melaporkan ke pihak berwajib sesuai hukum yang berlaku</li>
|
||||
</ul>
|
||||
<p>
|
||||
Tim kami berkomitmen untuk menanggapi laporan konten tidak pantas <strong>dalam waktu 24 jam</strong>.
|
||||
</p>
|
||||
|
||||
<h2>5. Mekanisme Pelaporan</h2>
|
||||
<p>
|
||||
Anda dapat melaporkan konten atau pengguna yang mencurigakan melalui:
|
||||
</p>
|
||||
<ul>
|
||||
<li>Tombol <strong>“Laporkan”</strong> di setiap posting forum atau pesan chat</li>
|
||||
<li>Tombol <strong>“Blokir Pengguna”</strong> di profil pengguna</li>
|
||||
</ul>
|
||||
<p>
|
||||
Setiap laporan akan ditangani secara rahasia dan segera.
|
||||
</p>
|
||||
|
||||
<h2>6. Perubahan Ketentuan</h2>
|
||||
<p>
|
||||
Kami berhak memperbarui Syarat & Ketentuan ini sewaktu-waktu. Versi terbaru akan dipublikasikan di halaman ini dengan tanggal revisi yang diperbarui.
|
||||
</p>
|
||||
|
||||
<h2>7. Kontak</h2>
|
||||
<p>
|
||||
Jika Anda memiliki pertanyaan tentang ketentuan ini, silakan hubungi kami di:
|
||||
<strong>bip.baliinteraktifperkasa@gmail.com</strong>
|
||||
</p>
|
||||
|
||||
<footer>
|
||||
<p>© 2025 Bali Interaktif Perkasa. All rights reserved.</p>
|
||||
</footer>
|
||||
</body>
|
||||
</html>
|
||||
1
run.env.build.dev
Normal file
1
run.env.build.dev
Normal file
@@ -0,0 +1 @@
|
||||
nice -n 19 bun --env-file=.env run --bun build
|
||||
1
run.env.build.local
Normal file
1
run.env.build.local
Normal file
@@ -0,0 +1 @@
|
||||
bun --env-file=.env.local run --bun build
|
||||
1
run.env.dev
Normal file
1
run.env.dev
Normal file
@@ -0,0 +1 @@
|
||||
bun --env-file=.env run --bun dev -p 3000
|
||||
1
run.env.local.dev
Normal file
1
run.env.local.dev
Normal file
@@ -0,0 +1 @@
|
||||
bun --env-file=.env.local run --bun dev -p 3005
|
||||
1
run.env.start.dev
Normal file
1
run.env.start.dev
Normal file
@@ -0,0 +1 @@
|
||||
bun --env-file=.env run --bun start -p 3000
|
||||
1
run.env.start.local
Normal file
1
run.env.start.local
Normal file
@@ -0,0 +1 @@
|
||||
bun --env-file=.env-local run --bun start -p 3000
|
||||
3
run.prisma.env.local
Normal file
3
run.prisma.env.local
Normal file
@@ -0,0 +1,3 @@
|
||||
bun --env-file=.env.local prisma db push
|
||||
bun --env-file=.env.local prisma db seed
|
||||
bun --env-file=.env.local run --bun build
|
||||
30
sendWhatsapp.js
Normal file
30
sendWhatsapp.js
Normal file
@@ -0,0 +1,30 @@
|
||||
// sendWhatsapp.js
|
||||
|
||||
// --- INPUT MANUAL ---
|
||||
let phoneNumber = "6282340374412";
|
||||
const codeOtp = "3546";
|
||||
// ---------------------
|
||||
|
||||
phoneNumber = phoneNumber.replace(/\D/g, "");
|
||||
|
||||
// Format pesan
|
||||
const message =
|
||||
`HIPMI - Kode ini bersifat RAHASIA dan JANGAN DI BAGIKAN KEPADA SIAPAPUN, termasuk anggota ataupun pengurus HIPMI lainnya.\n\n` +
|
||||
`>> Kode OTP anda: ${codeOtp}.`;
|
||||
|
||||
const encodedMessage = encodeURIComponent(message);
|
||||
|
||||
const waLink = `https://wa.wibudev.com/code?nom=${phoneNumber}&text=${encodedMessage}`;
|
||||
|
||||
console.log("Mengirim request ke server...\n");
|
||||
|
||||
// Jalankan HTTP GET
|
||||
fetch(waLink)
|
||||
.then(res => res.text())
|
||||
.then(data => {
|
||||
console.log("Response dari server:");
|
||||
console.log(data);
|
||||
})
|
||||
.catch(err => {
|
||||
console.error("Terjadi error:", err);
|
||||
});
|
||||
138
src/app/(admin)/logs/logs.module.css
Normal file
138
src/app/(admin)/logs/logs.module.css
Normal file
@@ -0,0 +1,138 @@
|
||||
/* app/admin/logs/logs.module.css */
|
||||
.container {
|
||||
padding: 24px;
|
||||
max-width: 1200px;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 24px;
|
||||
font-weight: bold;
|
||||
margin-bottom: 16px;
|
||||
}
|
||||
|
||||
.filterContainer {
|
||||
margin-bottom: 16px;
|
||||
}
|
||||
|
||||
.select {
|
||||
padding: 8px;
|
||||
border: 1px solid #ddd;
|
||||
border-radius: 4px;
|
||||
min-width: 200px;
|
||||
}
|
||||
|
||||
.logsContainer {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
.logItem {
|
||||
padding: 16px;
|
||||
border-radius: 4px;
|
||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
|
||||
.errorLog {
|
||||
background-color: #fef2f2;
|
||||
}
|
||||
|
||||
.warnLog {
|
||||
background-color: #fefce8;
|
||||
}
|
||||
|
||||
.infoLog {
|
||||
background-color: #ffffff;
|
||||
}
|
||||
|
||||
.logHeader {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
.timestamp {
|
||||
font-size: 14px;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.level {
|
||||
padding: 4px 8px;
|
||||
border-radius: 4px;
|
||||
font-size: 12px;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.errorLevel {
|
||||
background-color: #fee2e2;
|
||||
color: #991b1b;
|
||||
}
|
||||
|
||||
.warnLevel {
|
||||
background-color: #fef3c7;
|
||||
color: #92400e;
|
||||
}
|
||||
|
||||
.infoLevel {
|
||||
background-color: #dbeafe;
|
||||
color: #1e40af;
|
||||
}
|
||||
|
||||
.message {
|
||||
margin-top: 8px;
|
||||
}
|
||||
|
||||
.metadata {
|
||||
margin-top: 8px;
|
||||
padding: 8px;
|
||||
background-color: #f9fafb;
|
||||
border-radius: 4px;
|
||||
font-size: 14px;
|
||||
overflow-x: auto;
|
||||
white-space: pre-wrap;
|
||||
}
|
||||
|
||||
.loading {
|
||||
text-align: center;
|
||||
padding: 24px;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.error {
|
||||
color: #dc2626;
|
||||
text-align: center;
|
||||
padding: 24px;
|
||||
}
|
||||
|
||||
/* Hover effects */
|
||||
.logItem:hover {
|
||||
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
|
||||
.select:hover {
|
||||
border-color: #999;
|
||||
}
|
||||
|
||||
/* Focus states */
|
||||
.select:focus {
|
||||
outline: none;
|
||||
border-color: #2563eb;
|
||||
box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.2);
|
||||
}
|
||||
|
||||
/* Responsive adjustments */
|
||||
@media (max-width: 768px) {
|
||||
.container {
|
||||
padding: 16px;
|
||||
}
|
||||
|
||||
.logHeader {
|
||||
flex-direction: column;
|
||||
align-items: flex-start;
|
||||
}
|
||||
|
||||
.metadata {
|
||||
font-size: 12px;
|
||||
}
|
||||
}
|
||||
106
src/app/(admin)/logs/page.tsx
Normal file
106
src/app/(admin)/logs/page.tsx
Normal file
@@ -0,0 +1,106 @@
|
||||
// app/admin/logs/page.tsx
|
||||
"use client";
|
||||
|
||||
import { useEffect, useState } from "react";
|
||||
import { format } from "date-fns";
|
||||
import styles from "./logs.module.css";
|
||||
|
||||
interface LogEntry {
|
||||
timestamp: string;
|
||||
level: string;
|
||||
message: string;
|
||||
metadata?: any;
|
||||
}
|
||||
|
||||
export default function LogsPage() {
|
||||
const [logs, setLogs] = useState<LogEntry[]>([]);
|
||||
const [loading, setLoading] = useState(true);
|
||||
const [error, setError] = useState<string | null>(null);
|
||||
const [filter, setFilter] = useState<"all" | "error" | "info" | "warn">(
|
||||
"all"
|
||||
);
|
||||
|
||||
useEffect(() => {
|
||||
fetchLogs();
|
||||
}, []);
|
||||
|
||||
async function fetchLogs() {
|
||||
try {
|
||||
const response = await fetch("/api/logs/view");
|
||||
if (!response.ok) throw new Error("Failed to fetch logs");
|
||||
|
||||
const data = await response.json();
|
||||
setLogs(data.logs);
|
||||
} catch (err) {
|
||||
setError(err instanceof Error ? err.message : "Error fetching logs");
|
||||
} finally {
|
||||
setLoading(false);
|
||||
}
|
||||
}
|
||||
|
||||
const filteredLogs = logs.filter((log) =>
|
||||
filter === "all" ? true : log.level === filter
|
||||
);
|
||||
|
||||
if (loading) return <div className={styles.loading}>Loading logs...</div>;
|
||||
if (error) return <div className={styles.error}>Error: {error}</div>;
|
||||
|
||||
return (
|
||||
<div className={styles.container}>
|
||||
<h1 className={styles.title}>System Logs</h1>
|
||||
|
||||
<div className={styles.filterContainer}>
|
||||
<select
|
||||
value={filter}
|
||||
onChange={(e) => setFilter(e.target.value as any)}
|
||||
className={styles.select}
|
||||
>
|
||||
<option value="all">All Logs</option>
|
||||
<option value="error">Errors</option>
|
||||
<option value="warn">Warnings</option>
|
||||
<option value="info">Info</option>
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<div className={styles.logsContainer}>
|
||||
{filteredLogs.map((log, index) => (
|
||||
<div
|
||||
key={index}
|
||||
className={`${styles.logItem} ${
|
||||
log.level === "error"
|
||||
? styles.errorLog
|
||||
: log.level === "warn"
|
||||
? styles.warnLog
|
||||
: styles.infoLog
|
||||
}`}
|
||||
>
|
||||
<div className={styles.logHeader}>
|
||||
<span className={styles.timestamp}>
|
||||
{format(new Date(log.timestamp), "yyyy-MM-dd HH:mm:ss")}
|
||||
</span>
|
||||
<span
|
||||
className={`${styles.level} ${
|
||||
log.level === "error"
|
||||
? styles.errorLevel
|
||||
: log.level === "warn"
|
||||
? styles.warnLevel
|
||||
: styles.infoLevel
|
||||
}`}
|
||||
>
|
||||
{log.level.toUpperCase()}
|
||||
</span>
|
||||
</div>
|
||||
|
||||
<div className={styles.message}>{log.message}</div>
|
||||
|
||||
{log.metadata && (
|
||||
<pre className={styles.metadata}>
|
||||
{JSON.stringify(log.metadata, null, 2)}
|
||||
</pre>
|
||||
)}
|
||||
</div>
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
49
src/app/(auth)/_lib/decrypt.ts
Normal file
49
src/app/(auth)/_lib/decrypt.ts
Normal file
@@ -0,0 +1,49 @@
|
||||
import { jwtVerify } from "jose";
|
||||
|
||||
export async function decrypt({
|
||||
token,
|
||||
encodedKey,
|
||||
}: {
|
||||
token: string;
|
||||
encodedKey: string;
|
||||
}): Promise<Record<string, any> | null> {
|
||||
if (!token || !encodedKey) {
|
||||
console.error("Missing required parameters:", {
|
||||
hasToken: !!token,
|
||||
hasEncodedKey: !!encodedKey,
|
||||
});
|
||||
return null;
|
||||
}
|
||||
|
||||
try {
|
||||
const enc = new TextEncoder().encode(encodedKey);
|
||||
const { payload } = await jwtVerify(token, enc, {
|
||||
algorithms: ["HS256"],
|
||||
});
|
||||
|
||||
if (!payload || !payload.user) {
|
||||
console.error("Invalid payload structure:", {
|
||||
hasPayload: !!payload,
|
||||
hasUser: payload ? !!payload.user : false,
|
||||
});
|
||||
return null;
|
||||
}
|
||||
|
||||
// Logging untuk debug
|
||||
// console.log("Decrypt successful:", {
|
||||
// payloadExists: !!payload,
|
||||
// userExists: !!payload.user,
|
||||
// tokenPreview: token.substring(0, 10) + "...",
|
||||
// });
|
||||
|
||||
return payload.user as Record<string, any>;
|
||||
} catch (error) {
|
||||
console.error("Token verification failed:", {
|
||||
error,
|
||||
tokenLength: token?.length,
|
||||
errorName: error instanceof Error ? error.name : "Unknown error",
|
||||
errorMessage: error instanceof Error ? error.message : String(error),
|
||||
});
|
||||
return null;
|
||||
}
|
||||
}
|
||||
9
src/app/(auth)/invalid-user/page.tsx
Normal file
9
src/app/(auth)/invalid-user/page.tsx
Normal file
@@ -0,0 +1,9 @@
|
||||
import { InvalidUser } from "@/app_modules/auth";
|
||||
|
||||
export default function Page() {
|
||||
return (
|
||||
<>
|
||||
<InvalidUser />
|
||||
</>
|
||||
);
|
||||
}
|
||||
14
src/app/(auth)/waiting-room/page.tsx
Normal file
14
src/app/(auth)/waiting-room/page.tsx
Normal file
@@ -0,0 +1,14 @@
|
||||
import { funGetUserIdByToken } from "@/app_modules/_global/fun/get";
|
||||
import WaitingRoom_View from "@/app_modules/waiting_room/view";
|
||||
|
||||
export const dynamic = "force-dynamic";
|
||||
|
||||
export default async function Page() {
|
||||
const userLoginId = await funGetUserIdByToken();
|
||||
|
||||
return (
|
||||
<>
|
||||
<WaitingRoom_View userLoginId={userLoginId as string} />
|
||||
</>
|
||||
);
|
||||
}
|
||||
@@ -1,13 +1,10 @@
|
||||
import { Job_UiNotUserView } from "@/app_modules/job/_ui";
|
||||
import { job_getOneById } from "@/app_modules/job/fun/get/get_one_by_id";
|
||||
|
||||
export default async function Page({ params }: { params: { id: string } }) {
|
||||
const jobId = params.id;
|
||||
const dataJob = await job_getOneById(jobId);
|
||||
export default async function Page() {
|
||||
|
||||
return (
|
||||
<>
|
||||
<Job_UiNotUserView data={dataJob} />
|
||||
<Job_UiNotUserView />
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
153
src/app/(support)/delete-account/page.tsx
Normal file
153
src/app/(support)/delete-account/page.tsx
Normal file
@@ -0,0 +1,153 @@
|
||||
"use client";
|
||||
|
||||
import {
|
||||
Box,
|
||||
Button,
|
||||
Grid,
|
||||
Paper,
|
||||
Stack,
|
||||
Text,
|
||||
TextInput,
|
||||
Title,
|
||||
} from "@mantine/core";
|
||||
import { notifications } from "@mantine/notifications";
|
||||
import Image from "next/image";
|
||||
import { useParams } from "next/navigation";
|
||||
import { useEffect, useState } from "react";
|
||||
|
||||
export default function DeleteAccount() {
|
||||
const [phoneNumber, setPhoneNumber] = useState<string>("");
|
||||
const [data, setData] = useState({
|
||||
description: "",
|
||||
});
|
||||
const [isLoading, setIsLoading] = useState(false);
|
||||
|
||||
useEffect(() => {
|
||||
// Hanya di client, setelah mount
|
||||
const urlParams = new URLSearchParams(window.location.search);
|
||||
const phone = urlParams.get("phone");
|
||||
if (phone) {
|
||||
setPhoneNumber(phone);
|
||||
}
|
||||
}, []);
|
||||
|
||||
const handlerSubmit = async () => {
|
||||
if (!phoneNumber) {
|
||||
return notifications.show({
|
||||
title: "Error",
|
||||
message: "Please check your phone number",
|
||||
color: "red",
|
||||
});
|
||||
}
|
||||
|
||||
if (!data.description) {
|
||||
return notifications.show({
|
||||
title: "Error",
|
||||
message: "Please fill in description with 'Delete Account'",
|
||||
color: "red",
|
||||
});
|
||||
}
|
||||
|
||||
if (data.description !== "Delete Account") {
|
||||
return notifications.show({
|
||||
title: "Error",
|
||||
message: "Please fill in description with 'Delete Account'",
|
||||
color: "red",
|
||||
});
|
||||
}
|
||||
|
||||
try {
|
||||
setIsLoading(true);
|
||||
const response = await fetch("/api/helper/delete-account", {
|
||||
method: "POST",
|
||||
headers: {
|
||||
"Content-Type": "application/json",
|
||||
},
|
||||
body: JSON.stringify({
|
||||
number: phoneNumber,
|
||||
description: data.description,
|
||||
}),
|
||||
});
|
||||
|
||||
const result = await response.json();
|
||||
if (result.success) {
|
||||
notifications.show({
|
||||
title: "Success",
|
||||
message: "Account will process to delete",
|
||||
color: "green",
|
||||
});
|
||||
|
||||
setData({
|
||||
description: "",
|
||||
});
|
||||
}
|
||||
|
||||
if (!result.success) {
|
||||
notifications.show({
|
||||
title: "Error",
|
||||
message: result.error || "Failed to delete account.",
|
||||
color: "red",
|
||||
});
|
||||
}
|
||||
} catch (error) {
|
||||
console.log(error);
|
||||
} finally {
|
||||
setIsLoading(false);
|
||||
}
|
||||
};
|
||||
|
||||
return (
|
||||
<Box
|
||||
style={{
|
||||
display: "flex",
|
||||
justifyContent: "center",
|
||||
alignItems: "center",
|
||||
height: "100vh",
|
||||
backgroundColor: "#f5f5f5",
|
||||
padding: "20px",
|
||||
}}
|
||||
>
|
||||
<Paper withBorder shadow="md" p={"lg"}>
|
||||
<Stack align="center">
|
||||
<Image
|
||||
src="/aset/logo/hiconnect.png"
|
||||
alt="logo"
|
||||
width={100}
|
||||
height={100}
|
||||
/>
|
||||
<Title>Delete Account</Title>
|
||||
<Stack spacing={0} align="center">
|
||||
<Text align="center" fw={"lighter"}>
|
||||
To delete your account with phone number{" "}
|
||||
{phoneNumber ? `+${phoneNumber}` : ""}.
|
||||
</Text>
|
||||
<Text align="center" fw={"lighter"}>
|
||||
Type your message with subject ‘Delete Account’
|
||||
</Text>
|
||||
</Stack>
|
||||
|
||||
<Grid w={"100%"}>
|
||||
<Grid.Col span={8}>
|
||||
<TextInput
|
||||
value={data.description}
|
||||
w={"100%"}
|
||||
placeholder="Type your subject here"
|
||||
onChange={(e) => {
|
||||
setData({
|
||||
...data,
|
||||
description: e.target.value,
|
||||
});
|
||||
}}
|
||||
/>
|
||||
</Grid.Col>
|
||||
<Grid.Col span={4}>
|
||||
<Button onClick={handlerSubmit} w={"100%"} loading={isLoading}>
|
||||
Submit
|
||||
</Button>
|
||||
</Grid.Col>
|
||||
</Grid>
|
||||
</Stack>
|
||||
</Paper>
|
||||
</Box>
|
||||
);
|
||||
}
|
||||
202
src/app/(support)/support-center/page.tsx
Normal file
202
src/app/(support)/support-center/page.tsx
Normal file
@@ -0,0 +1,202 @@
|
||||
"use client";
|
||||
import {
|
||||
Box,
|
||||
Button,
|
||||
Group,
|
||||
Paper,
|
||||
SimpleGrid,
|
||||
Stack,
|
||||
Text,
|
||||
Textarea,
|
||||
TextInput,
|
||||
Title,
|
||||
} from "@mantine/core";
|
||||
import { notifications } from "@mantine/notifications";
|
||||
import { IconBrandGmail, IconLocation } from "@tabler/icons-react";
|
||||
import Image from "next/image";
|
||||
import { useState } from "react";
|
||||
|
||||
export default function SupportCenter() {
|
||||
const [data, setData] = useState({
|
||||
email: "",
|
||||
title: "",
|
||||
description: "",
|
||||
});
|
||||
const [isLoading, setLoading] = useState(false);
|
||||
|
||||
const handleSubmit = async () => {
|
||||
if (!data.email || !data.title || !data.description) {
|
||||
return notifications.show({
|
||||
title: "Error",
|
||||
color: "red",
|
||||
message: "Please fill in all fields.",
|
||||
});
|
||||
}
|
||||
|
||||
try {
|
||||
setLoading(true);
|
||||
|
||||
const response = await fetch("/api/helper/support-center", {
|
||||
method: "POST",
|
||||
headers: {
|
||||
"Content-Type": "application/json",
|
||||
},
|
||||
body: JSON.stringify(data),
|
||||
});
|
||||
const result = await response.json();
|
||||
|
||||
if (result.success) {
|
||||
notifications.show({
|
||||
title: "Success",
|
||||
color: "green",
|
||||
message: "Message sent successfully.",
|
||||
});
|
||||
|
||||
setData({
|
||||
email: "",
|
||||
title: "",
|
||||
description: "",
|
||||
});
|
||||
}
|
||||
|
||||
if (!result.success) {
|
||||
notifications.show({
|
||||
title: "Error",
|
||||
color: "red",
|
||||
message: result.error || "Failed to send message.",
|
||||
});
|
||||
}
|
||||
} catch (error) {
|
||||
console.log(error);
|
||||
} finally {
|
||||
setLoading(false);
|
||||
}
|
||||
};
|
||||
|
||||
return (
|
||||
<Box
|
||||
style={{
|
||||
display: "flex",
|
||||
justifyContent: "center",
|
||||
alignItems: "center",
|
||||
height: "100vh",
|
||||
backgroundColor: "#f5f5f5",
|
||||
padding: "20px",
|
||||
}}
|
||||
>
|
||||
<Stack spacing={"lg"}>
|
||||
<Stack align="center">
|
||||
<Stack spacing={"xs"} align="center">
|
||||
<Group>
|
||||
<Image
|
||||
src="/aset/logo/hiconnect.png"
|
||||
alt="logo"
|
||||
width={50}
|
||||
height={50}
|
||||
/>
|
||||
|
||||
<Title>Support Center</Title>
|
||||
</Group>
|
||||
<Text align="center">
|
||||
Send us a message and we'll get back to you as soon as possible.
|
||||
</Text>
|
||||
</Stack>
|
||||
</Stack>
|
||||
|
||||
<Paper style={{ padding: "20px" }} withBorder shadow="md">
|
||||
<SimpleGrid
|
||||
cols={2}
|
||||
// verticalSpacing={50}
|
||||
spacing={50}
|
||||
breakpoints={[
|
||||
{ maxWidth: "md", cols: 2, spacing: "md" },
|
||||
{ maxWidth: "sm", cols: 2, spacing: "sm" },
|
||||
{ maxWidth: "xs", cols: 1, spacing: "sm" },
|
||||
]}
|
||||
>
|
||||
<Stack>
|
||||
<Stack spacing={0}>
|
||||
<Title order={2}>Contact Information</Title>
|
||||
<Text>For general inquiries, please contact us !</Text>
|
||||
</Stack>
|
||||
<Group>
|
||||
<IconBrandGmail
|
||||
size={40}
|
||||
style={{
|
||||
backgroundColor: "gray",
|
||||
borderRadius: "10%",
|
||||
padding: "5px",
|
||||
}}
|
||||
/>
|
||||
<Stack spacing={0}>
|
||||
<Text fw={"bold"}>Email</Text>
|
||||
<Text>bip.baliinteraktifperkasa@gmail.com</Text>
|
||||
</Stack>
|
||||
</Group>
|
||||
|
||||
<Group>
|
||||
<IconLocation
|
||||
size={40}
|
||||
style={{
|
||||
backgroundColor: "gray",
|
||||
borderRadius: "10%",
|
||||
padding: "5px",
|
||||
}}
|
||||
/>
|
||||
<Stack spacing={0}>
|
||||
<Text fw={"bold"}>Location</Text>
|
||||
<Text>Bali, Indonesia</Text>
|
||||
</Stack>
|
||||
</Group>
|
||||
</Stack>
|
||||
|
||||
<Stack>
|
||||
<Title order={2}>Send a Message</Title>
|
||||
|
||||
<TextInput
|
||||
label="Email"
|
||||
placeholder="Email"
|
||||
onChange={(e) => {
|
||||
setData({
|
||||
...data,
|
||||
email: e.target.value,
|
||||
});
|
||||
}}
|
||||
/>
|
||||
|
||||
<TextInput
|
||||
label="Title"
|
||||
placeholder="Title"
|
||||
onChange={(e) => {
|
||||
setData({
|
||||
...data,
|
||||
title: e.target.value,
|
||||
});
|
||||
}}
|
||||
/>
|
||||
|
||||
<Textarea
|
||||
label="Description"
|
||||
placeholder="Description"
|
||||
onChange={(e) => {
|
||||
setData({
|
||||
...data,
|
||||
description: e.target.value,
|
||||
});
|
||||
}}
|
||||
/>
|
||||
|
||||
<Button
|
||||
loading={isLoading}
|
||||
color="yellow"
|
||||
onClick={() => handleSubmit()}
|
||||
>
|
||||
Submit
|
||||
</Button>
|
||||
</Stack>
|
||||
</SimpleGrid>
|
||||
</Paper>
|
||||
</Stack>
|
||||
</Box>
|
||||
);
|
||||
}
|
||||
@@ -1,19 +0,0 @@
|
||||
import { funGetUserIdByToken } from "@/app_modules/_global/fun/get";
|
||||
import { funGlobal_checkActivationUseById } from "@/app_modules/_global/fun/get/fun_check_activation_use_by_id";
|
||||
import WaitingRoom_View from "@/app_modules/waiting_room/view";
|
||||
|
||||
export default async function Page() {
|
||||
const userLoginId = await funGetUserIdByToken();
|
||||
const activationUser = await funGlobal_checkActivationUseById({
|
||||
userId: userLoginId as string,
|
||||
});
|
||||
|
||||
return (
|
||||
<>
|
||||
<WaitingRoom_View
|
||||
activationUser={activationUser as boolean}
|
||||
userLoginId={userLoginId as string}
|
||||
/>
|
||||
</>
|
||||
);
|
||||
}
|
||||
72
src/app/api/admin/collaboration/[id]/route.ts
Normal file
72
src/app/api/admin/collaboration/[id]/route.ts
Normal file
@@ -0,0 +1,72 @@
|
||||
import prisma from "@/lib/prisma";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(
|
||||
req: Request,
|
||||
{ params }: { params: { id: string } }
|
||||
) {
|
||||
try {
|
||||
const { id } = params;
|
||||
const data = await prisma.projectCollaboration.findUnique({
|
||||
where: {
|
||||
id: id,
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
isActive: true,
|
||||
title: true,
|
||||
lokasi: true,
|
||||
purpose: true,
|
||||
benefit: true,
|
||||
createdAt: true,
|
||||
report: true,
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
},
|
||||
},
|
||||
ProjectCollaborationMaster_Industri: true,
|
||||
ProjectCollaboration_Partisipasi: {
|
||||
where: {
|
||||
User: {
|
||||
active: true,
|
||||
},
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
User: {
|
||||
select: {
|
||||
id: true,
|
||||
Profile: {
|
||||
select: {
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get collaboration",
|
||||
data: data,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get collaboration >>", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Error get collaboration",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
58
src/app/api/admin/collaboration/dashboard/[name]/route.ts
Normal file
58
src/app/api/admin/collaboration/dashboard/[name]/route.ts
Normal file
@@ -0,0 +1,58 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(request: Request, { params }: {
|
||||
params: { name: string }
|
||||
}) {
|
||||
const { name } = params;
|
||||
try {
|
||||
let fixData;
|
||||
const fixStatus = _.startCase(name);
|
||||
|
||||
if (fixStatus === "Publish") {
|
||||
fixData = await prisma.projectCollaboration.count({
|
||||
where: {
|
||||
isActive: true,
|
||||
isReject: false,
|
||||
Author: {
|
||||
active: true,
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
} else if (fixStatus === "Reject") {
|
||||
fixData = await prisma.projectCollaboration.count({
|
||||
where: {
|
||||
isReject: true,
|
||||
},
|
||||
});
|
||||
|
||||
} else if (fixStatus === "Room") {
|
||||
fixData = await prisma.projectCollaboration_RoomChat.count({
|
||||
where: {
|
||||
isActive: true,
|
||||
},
|
||||
});
|
||||
|
||||
}
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: `Success Get Data ${fixStatus}`,
|
||||
data: fixData,
|
||||
|
||||
},
|
||||
{ status: 200 }
|
||||
)
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get count group chat", error);
|
||||
return NextResponse.json({
|
||||
success: false,
|
||||
message: "Error get data count group chat ",
|
||||
reason: (error as Error).message
|
||||
},
|
||||
{ status: 500 }
|
||||
)
|
||||
}
|
||||
}
|
||||
74
src/app/api/admin/collaboration/group/[id]/route.ts
Normal file
74
src/app/api/admin/collaboration/group/[id]/route.ts
Normal file
@@ -0,0 +1,74 @@
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import { NextResponse } from "next/server";
|
||||
import { prisma } from "@/lib";
|
||||
|
||||
export async function GET(
|
||||
request: Request,
|
||||
{ params }: { params: { id: string } }
|
||||
) {
|
||||
try {
|
||||
const { id } = params;
|
||||
|
||||
const data = await prisma.projectCollaboration_RoomChat.findUnique({
|
||||
where: {
|
||||
id: id,
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
name: true,
|
||||
ProjectCollaboration: {
|
||||
select: {
|
||||
id: true,
|
||||
isActive: true,
|
||||
title: true,
|
||||
lokasi: true,
|
||||
purpose: true,
|
||||
benefit: true,
|
||||
createdAt: true,
|
||||
ProjectCollaborationMaster_Industri: true,
|
||||
Author: true
|
||||
},
|
||||
},
|
||||
ProjectCollaboration_AnggotaRoomChat: {
|
||||
select: {
|
||||
User: {
|
||||
select: {
|
||||
username: true,
|
||||
id: true,
|
||||
Profile: {
|
||||
select: {
|
||||
id: true,
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get data collaboration group",
|
||||
data: data,
|
||||
},
|
||||
{
|
||||
status: 200,
|
||||
}
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data collaboration group", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Error get data collaboration group",
|
||||
error: (error as Error).message,
|
||||
},
|
||||
{
|
||||
status: 500,
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
146
src/app/api/admin/collaboration/group/route.ts
Normal file
146
src/app/api/admin/collaboration/group/route.ts
Normal file
@@ -0,0 +1,146 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(request: Request) {
|
||||
const { searchParams } = new URL(request.url);
|
||||
const search = searchParams.get("search");
|
||||
const page = searchParams.get("page");
|
||||
const takeData = 10;
|
||||
const skipData = Number(page) * takeData - takeData;
|
||||
|
||||
try {
|
||||
let fixData;
|
||||
|
||||
if (!page) {
|
||||
fixData = await prisma.projectCollaboration_RoomChat.findMany({
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
isActive: true,
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
createdAt: true,
|
||||
isActive: true,
|
||||
name: true,
|
||||
ProjectCollaboration_AnggotaRoomChat: {
|
||||
select: {
|
||||
User: {
|
||||
select: {
|
||||
id: true,
|
||||
Profile: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
ProjectCollaboration: {
|
||||
select: {
|
||||
id: true,
|
||||
isActive: true,
|
||||
title: true,
|
||||
lokasi: true,
|
||||
purpose: true,
|
||||
benefit: true,
|
||||
createdAt: true,
|
||||
report: true,
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
Profile: {
|
||||
select: {
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
ProjectCollaborationMaster_Industri: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
} else {
|
||||
const data = await prisma.projectCollaboration_RoomChat.findMany({
|
||||
take: takeData,
|
||||
skip: skipData,
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
isActive: true,
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
createdAt: true,
|
||||
isActive: true,
|
||||
name: true,
|
||||
ProjectCollaboration_AnggotaRoomChat: {
|
||||
select: {
|
||||
User: {
|
||||
select: {
|
||||
id: true,
|
||||
Profile: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
ProjectCollaboration: {
|
||||
select: {
|
||||
id: true,
|
||||
isActive: true,
|
||||
title: true,
|
||||
lokasi: true,
|
||||
purpose: true,
|
||||
benefit: true,
|
||||
createdAt: true,
|
||||
report: true,
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
Profile: {
|
||||
select: {
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
ProjectCollaborationMaster_Industri: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
const nCount = await prisma.projectCollaboration_RoomChat.count({
|
||||
where: {
|
||||
isActive: true,
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nPage: _.ceil(nCount / takeData),
|
||||
};
|
||||
}
|
||||
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get data collaboration group",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data collaboration group >>", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Error get data collaboration group",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
141
src/app/api/admin/collaboration/status/publish/route.ts
Normal file
141
src/app/api/admin/collaboration/status/publish/route.ts
Normal file
@@ -0,0 +1,141 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(request: Request) {
|
||||
const { searchParams } = new URL(request.url);
|
||||
const page = searchParams.get("page");
|
||||
const takeData = 10;
|
||||
const skipData = Number(page) * takeData - takeData;
|
||||
|
||||
try {
|
||||
let fixData;
|
||||
|
||||
if (!page) {
|
||||
fixData = await prisma.projectCollaboration.findMany({
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
isActive: true,
|
||||
isReject: false,
|
||||
Author: {
|
||||
active: true,
|
||||
},
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
createdAt: true,
|
||||
isActive: true,
|
||||
title: true,
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
Profile: true,
|
||||
},
|
||||
},
|
||||
projectCollaborationMaster_IndustriId: true,
|
||||
ProjectCollaborationMaster_Industri: true,
|
||||
ProjectCollaboration_Partisipasi: {
|
||||
where: {
|
||||
User: {
|
||||
active: true,
|
||||
},
|
||||
},
|
||||
// select: {
|
||||
// User: {
|
||||
// select: {
|
||||
// id: true,
|
||||
// username: true,
|
||||
// Profile: true,
|
||||
// },
|
||||
// },
|
||||
// },
|
||||
},
|
||||
},
|
||||
});
|
||||
} else {
|
||||
const data = await prisma.projectCollaboration.findMany({
|
||||
skip: skipData,
|
||||
take: takeData,
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
isActive: true,
|
||||
isReject: false,
|
||||
Author: {
|
||||
active: true,
|
||||
},
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
createdAt: true,
|
||||
isActive: true,
|
||||
title: true,
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
Profile: true,
|
||||
},
|
||||
},
|
||||
projectCollaborationMaster_IndustriId: true,
|
||||
ProjectCollaborationMaster_Industri: true,
|
||||
ProjectCollaboration_Partisipasi: {
|
||||
where: {
|
||||
User: {
|
||||
active: true,
|
||||
},
|
||||
},
|
||||
// select: {
|
||||
// User: {
|
||||
// select: {
|
||||
// id: true,
|
||||
// username: true,
|
||||
// Profile: true,
|
||||
// },
|
||||
// },
|
||||
// },
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
const nCount = await prisma.projectCollaboration.count({
|
||||
where: {
|
||||
isActive: true,
|
||||
isReject: false,
|
||||
Author: {
|
||||
active: true,
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nPage: _.ceil(nCount / takeData),
|
||||
};
|
||||
}
|
||||
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get data collaboration dashboard",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data collaboration dashboard >>", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Error get data collaboration dashboard",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
143
src/app/api/admin/collaboration/status/reject/route.ts
Normal file
143
src/app/api/admin/collaboration/status/reject/route.ts
Normal file
@@ -0,0 +1,143 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(request: Request) {
|
||||
|
||||
const { searchParams } = new URL(request.url);
|
||||
const page = searchParams.get("page");
|
||||
const takeData = 10;
|
||||
const skipData = Number(page) * takeData - takeData;
|
||||
|
||||
try {
|
||||
let fixData;
|
||||
|
||||
|
||||
if (!page) {
|
||||
fixData = await prisma.projectCollaboration.findMany({
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
isActive: false,
|
||||
isReject: true,
|
||||
Author: {
|
||||
active: true,
|
||||
},
|
||||
|
||||
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
createdAt: true,
|
||||
isActive: true,
|
||||
title: true,
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
Profile: true,
|
||||
},
|
||||
},
|
||||
projectCollaborationMaster_IndustriId: true,
|
||||
ProjectCollaborationMaster_Industri: true,
|
||||
ProjectCollaboration_Partisipasi: {
|
||||
where: {
|
||||
User: {
|
||||
active: true,
|
||||
},
|
||||
},
|
||||
// select: {
|
||||
// User: {
|
||||
// select: {
|
||||
// id: true,
|
||||
// username: true,
|
||||
// Profile: true,
|
||||
// },
|
||||
// },
|
||||
// },
|
||||
},
|
||||
},
|
||||
});
|
||||
} else {
|
||||
const data = await prisma.projectCollaboration.findMany({
|
||||
skip: skipData,
|
||||
take: takeData,
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
isActive: false,
|
||||
isReject: true,
|
||||
Author: {
|
||||
active: true,
|
||||
},
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
createdAt: true,
|
||||
isActive: true,
|
||||
title: true,
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
Profile: true,
|
||||
},
|
||||
},
|
||||
projectCollaborationMaster_IndustriId: true,
|
||||
ProjectCollaborationMaster_Industri: true,
|
||||
ProjectCollaboration_Partisipasi: {
|
||||
where: {
|
||||
User: {
|
||||
active: true,
|
||||
},
|
||||
},
|
||||
// select: {
|
||||
// User: {
|
||||
// select: {
|
||||
// id: true,
|
||||
// username: true,
|
||||
// Profile: true,
|
||||
// },
|
||||
// },
|
||||
// },
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
const nCount = await prisma.projectCollaboration.count({
|
||||
where: {
|
||||
isActive: false,
|
||||
isReject: true,
|
||||
Author: {
|
||||
active: true,
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nPage: _.ceil(nCount / takeData),
|
||||
}
|
||||
}
|
||||
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: "Success get data collaboration dashboard",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data collaboration dashboard >>", error);
|
||||
return NextResponse.json({
|
||||
success: false,
|
||||
message: "Error get data collaboration dashboard",
|
||||
reason: (error as Error).message
|
||||
},
|
||||
{ status: 500 }
|
||||
)
|
||||
}
|
||||
}
|
||||
84
src/app/api/admin/developer/route.ts
Normal file
84
src/app/api/admin/developer/route.ts
Normal file
@@ -0,0 +1,84 @@
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
import prisma from "@/lib/prisma";
|
||||
|
||||
export const dynamic = "force-dynamic";
|
||||
|
||||
export async function GET(request: Request) {
|
||||
try {
|
||||
let fixData;
|
||||
const { searchParams } = new URL(request.url);
|
||||
const search = searchParams.get("search");
|
||||
const page = searchParams.get("page");
|
||||
const dataTake = 10;
|
||||
const dataSkip = Number(page) * dataTake - dataTake;
|
||||
|
||||
if (!page) {
|
||||
fixData = await prisma.user.findMany({
|
||||
orderBy: {
|
||||
updatedAt: "desc",
|
||||
},
|
||||
where: {
|
||||
masterUserRoleId: "2",
|
||||
username: {
|
||||
contains: search || "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
});
|
||||
} else {
|
||||
const data = await prisma.user.findMany({
|
||||
skip: dataSkip,
|
||||
take: dataTake,
|
||||
orderBy: {
|
||||
updatedAt: "desc",
|
||||
},
|
||||
where: {
|
||||
masterUserRoleId: "2",
|
||||
username: {
|
||||
contains: search || "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
const nCount = await prisma.user.count({
|
||||
where: {
|
||||
masterUserRoleId: "2",
|
||||
username: {
|
||||
contains: search || "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nPage: _.ceil(nCount / dataTake),
|
||||
};
|
||||
}
|
||||
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get data",
|
||||
data: fixData,
|
||||
},
|
||||
{
|
||||
status: 200,
|
||||
}
|
||||
);
|
||||
} catch (error) {
|
||||
console.error("Error get data admin", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Internal Server Error",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{
|
||||
status: 500,
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
29
src/app/api/admin/donasi/[id]/count/route.ts
Normal file
29
src/app/api/admin/donasi/[id]/count/route.ts
Normal file
@@ -0,0 +1,29 @@
|
||||
import { NextResponse } from "next/server";
|
||||
import prisma from "@/lib/prisma";
|
||||
export async function GET(
|
||||
req: Request,
|
||||
{ params }: { params: { id: string } }
|
||||
) {
|
||||
const { id } = params;
|
||||
try {
|
||||
const data = await prisma.donasi_Invoice.count({
|
||||
where: {
|
||||
donasiId: id,
|
||||
donasiMaster_StatusInvoiceId: "1",
|
||||
},
|
||||
});
|
||||
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: "Data berhasil diambil",
|
||||
data: data,
|
||||
});
|
||||
} catch (error) {
|
||||
console.error("Error get count donasi ", error);
|
||||
return NextResponse.json({
|
||||
success: false,
|
||||
message: "Error get count donasi",
|
||||
reason: (error as Error).message,
|
||||
});
|
||||
}
|
||||
}
|
||||
109
src/app/api/admin/donasi/[id]/donatur/route.ts
Normal file
109
src/app/api/admin/donasi/[id]/donatur/route.ts
Normal file
@@ -0,0 +1,109 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(
|
||||
req: Request,
|
||||
{ params }: { params: { id: string } }
|
||||
) {
|
||||
try {
|
||||
let fixData;
|
||||
const { id } = params;
|
||||
const { searchParams } = new URL(req.url);
|
||||
const page = searchParams.get("page");
|
||||
const status = searchParams.get("status");
|
||||
const takeData = 10;
|
||||
const skipData = Number(page) * takeData - takeData;
|
||||
|
||||
if (!page) {
|
||||
fixData = await prisma.donasi_Invoice.findMany({
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
donasiId: id,
|
||||
active: true,
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
nominal: true,
|
||||
createdAt: true,
|
||||
Author: true,
|
||||
DonasiMaster_Bank: true,
|
||||
DonasiMaster_StatusInvoice: true,
|
||||
donasiMaster_StatusInvoiceId: true,
|
||||
imagesId: true,
|
||||
imageId: true,
|
||||
},
|
||||
});
|
||||
} else {
|
||||
const fixStatus = _.startCase(status ? status : "");
|
||||
const data = await prisma.donasi_Invoice.findMany({
|
||||
take: takeData,
|
||||
skip: skipData,
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
donasiId: id,
|
||||
active: true,
|
||||
DonasiMaster_StatusInvoice: {
|
||||
name: {
|
||||
contains: fixStatus,
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
nominal: true,
|
||||
createdAt: true,
|
||||
Author: true,
|
||||
DonasiMaster_Bank: true,
|
||||
DonasiMaster_StatusInvoice: true,
|
||||
donasiMaster_StatusInvoiceId: true,
|
||||
imagesId: true,
|
||||
imageId: true,
|
||||
},
|
||||
});
|
||||
|
||||
const nCount = await prisma.donasi_Invoice.count({
|
||||
where: {
|
||||
donasiId: id,
|
||||
active: true,
|
||||
DonasiMaster_StatusInvoice: {
|
||||
name: {
|
||||
contains: fixStatus,
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nPage: _.ceil(nCount / takeData),
|
||||
};
|
||||
}
|
||||
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data donatur >>", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Error get data donatur",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
64
src/app/api/admin/donasi/[id]/pencairan/route.ts
Normal file
64
src/app/api/admin/donasi/[id]/pencairan/route.ts
Normal file
@@ -0,0 +1,64 @@
|
||||
import prisma from "@/lib/prisma";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
export async function GET(
|
||||
req: Request,
|
||||
{ params }: { params: { id: string } }
|
||||
) {
|
||||
|
||||
let fixData;
|
||||
const donasiId = params.id;
|
||||
const { searchParams } = new URL(req.url);
|
||||
const page = searchParams.get("page");
|
||||
const takeData = 10
|
||||
const skipData = Number(page) * takeData - takeData;
|
||||
|
||||
try {
|
||||
if (!page) {
|
||||
fixData = await prisma.donasi_PencairanDana.findMany({
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
donasiId: donasiId,
|
||||
},
|
||||
});
|
||||
} else {
|
||||
const data = await prisma.donasi_PencairanDana.findMany({
|
||||
take: takeData,
|
||||
skip: skipData,
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
donasiId: donasiId,
|
||||
},
|
||||
});
|
||||
|
||||
const nCount = await prisma.donasi_PencairanDana.count({
|
||||
where: {
|
||||
donasiId: donasiId,
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nPage: _.ceil(nCount / takeData),
|
||||
};
|
||||
}
|
||||
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: "Data berhasil diambil",
|
||||
data: fixData,
|
||||
});
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get pencairan donasi >>", error);
|
||||
return NextResponse.json({
|
||||
success: false,
|
||||
message: "Error get pencairan donasi",
|
||||
reason: (error as Error).message,
|
||||
});
|
||||
}
|
||||
}
|
||||
57
src/app/api/admin/donasi/[id]/route.ts
Normal file
57
src/app/api/admin/donasi/[id]/route.ts
Normal file
@@ -0,0 +1,57 @@
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import { NextResponse } from "next/server";
|
||||
import prisma from "@/lib/prisma";
|
||||
|
||||
export async function GET(req: Request, { params }: { params: { id: string } }) {
|
||||
|
||||
try {
|
||||
const { id } = params;
|
||||
const donasiId = id;
|
||||
const data = await prisma.donasi.findUnique({
|
||||
where: {
|
||||
id: donasiId,
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
title: true,
|
||||
target: true,
|
||||
active: true,
|
||||
createdAt: true,
|
||||
updatedAt: true,
|
||||
publishTime: true,
|
||||
catatan: true,
|
||||
progres: true,
|
||||
terkumpul: true,
|
||||
authorId: true,
|
||||
namaBank: true,
|
||||
rekening: true,
|
||||
totalPencairan: true,
|
||||
akumulasiPencairan: true,
|
||||
imagesId: true,
|
||||
donasiMaster_KategoriId: true,
|
||||
donasiMaster_DurasiId: true,
|
||||
donasiMaster_StatusDonasiId: true,
|
||||
Author: true,
|
||||
imageDonasi: true,
|
||||
CeritaDonasi: true,
|
||||
DonasiMaster_Ketegori: true,
|
||||
DonasiMaster_Durasi: true,
|
||||
DonasiMaster_Status: true,
|
||||
imageId: true,
|
||||
}
|
||||
})
|
||||
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: "Data Donasi Berhasil Diambil",
|
||||
data: data,
|
||||
}, { status: 200 });
|
||||
} catch (error) {
|
||||
backendLogger.error("Error Get Data Donasi >>", error);
|
||||
return NextResponse.json({
|
||||
success: false,
|
||||
message: "Error get detail Investasi",
|
||||
reason: (error as Error).message,
|
||||
}, { status: 500 });
|
||||
}
|
||||
}
|
||||
38
src/app/api/admin/donasi/dashboard/[name]/route.ts
Normal file
38
src/app/api/admin/donasi/dashboard/[name]/route.ts
Normal file
@@ -0,0 +1,38 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(request: Request, { params }: {
|
||||
params: { name: string }
|
||||
}) {
|
||||
|
||||
const { name } = params;
|
||||
try {
|
||||
let fixData;
|
||||
const fixStatus = _.startCase(name);
|
||||
fixData = await prisma.donasi.count({
|
||||
where: {
|
||||
DonasiMaster_Status: {
|
||||
name: fixStatus
|
||||
},
|
||||
}
|
||||
});
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: "Success get data donasi dashboard",
|
||||
data: fixData
|
||||
},
|
||||
{ status: 200 }
|
||||
)
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data donasi dashboard >>", error);
|
||||
return NextResponse.json({
|
||||
success: false,
|
||||
message: "Failed to get data donasi dashboard",
|
||||
reason: (error as Error).message
|
||||
},
|
||||
{ status: 500 }
|
||||
)
|
||||
}
|
||||
}
|
||||
25
src/app/api/admin/donasi/dashboard/kategori/route.ts
Normal file
25
src/app/api/admin/donasi/dashboard/kategori/route.ts
Normal file
@@ -0,0 +1,25 @@
|
||||
import { prisma } from "@/lib";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET() {
|
||||
try {
|
||||
const fixData = await prisma.donasiMaster_Kategori.count({});
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get data donasi dashboard",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "gagal mendapatkan data donasi dashboard",
|
||||
error: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
34
src/app/api/admin/donasi/kategori/route.ts
Normal file
34
src/app/api/admin/donasi/kategori/route.ts
Normal file
@@ -0,0 +1,34 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(request: Request) {
|
||||
const method = request.method;
|
||||
try {
|
||||
const data = await prisma.donasiMaster_Kategori.findMany({
|
||||
orderBy: {
|
||||
createdAt: 'asc'
|
||||
},
|
||||
where: {
|
||||
|
||||
active: true
|
||||
|
||||
}
|
||||
|
||||
})
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: "Success get kategori",
|
||||
data: data
|
||||
})
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get kategori", error);
|
||||
return NextResponse.json({
|
||||
success: false,
|
||||
message: "Failed get kategori",
|
||||
reason: (error as Error).message
|
||||
},
|
||||
{ status: 500 }
|
||||
)
|
||||
}
|
||||
}
|
||||
122
src/app/api/admin/donasi/status/[name]/route.ts
Normal file
122
src/app/api/admin/donasi/status/[name]/route.ts
Normal file
@@ -0,0 +1,122 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(request: Request,
|
||||
{ params }: { params: { name: string } }) {
|
||||
|
||||
const { name } = params;
|
||||
const { searchParams } = new URL(request.url);
|
||||
const search = searchParams.get("search");
|
||||
const page = searchParams.get("page");
|
||||
const takeData = 10;
|
||||
const skipData = Number(page) * takeData - takeData;
|
||||
|
||||
try {
|
||||
let fixData;
|
||||
const fixStatus = _.startCase(name);
|
||||
|
||||
|
||||
if (!page) {
|
||||
fixData = await prisma.donasi.findMany({
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
DonasiMaster_Status: {
|
||||
name: fixStatus,
|
||||
},
|
||||
active: true,
|
||||
title: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
title: true,
|
||||
target: true,
|
||||
authorId: true,
|
||||
terkumpul: true,
|
||||
imageDonasi: true,
|
||||
DonasiMaster_Ketegori: true,
|
||||
DonasiMaster_Durasi: true,
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
} else {
|
||||
const data = await prisma.donasi.findMany({
|
||||
take: takeData,
|
||||
skip: skipData,
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
DonasiMaster_Status: {
|
||||
name: fixStatus,
|
||||
},
|
||||
active: true,
|
||||
title: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
title: true,
|
||||
target: true,
|
||||
authorId: true,
|
||||
terkumpul: true,
|
||||
imageDonasi: true,
|
||||
DonasiMaster_Ketegori: true,
|
||||
DonasiMaster_Durasi: true,
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
const nCount = await prisma.donasi.count({
|
||||
where: {
|
||||
active: true,
|
||||
DonasiMaster_Status: {
|
||||
name: fixStatus
|
||||
},
|
||||
}
|
||||
})
|
||||
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nCount: _.ceil(nCount / takeData)
|
||||
}
|
||||
}
|
||||
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: "Success",
|
||||
data: fixData
|
||||
},
|
||||
{ status: 200 }
|
||||
)
|
||||
|
||||
} catch (error) {
|
||||
backendLogger.error("Error geta data table donasi event dashboard>>", error)
|
||||
return NextResponse.json({
|
||||
success: false,
|
||||
message: "Failed get data table donasi dashboard",
|
||||
reason: (error as Error).message
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
100
src/app/api/admin/event/[id]/peserta/route.ts
Normal file
100
src/app/api/admin/event/[id]/peserta/route.ts
Normal file
@@ -0,0 +1,100 @@
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
import prisma from "@/lib/prisma";
|
||||
|
||||
export async function GET(request: Request,
|
||||
{ params }: { params: { id: string } }) {
|
||||
|
||||
const { searchParams } = new URL(request.url);
|
||||
const search = searchParams.get('search');
|
||||
const page = searchParams.get('page');
|
||||
const takeData = 10;
|
||||
const skipData = Number(page) * takeData - takeData;
|
||||
|
||||
|
||||
try {
|
||||
let fixData;
|
||||
const { id } = params;
|
||||
const eventId = id
|
||||
|
||||
if (!page) {
|
||||
fixData = await prisma.event_Peserta.findMany({
|
||||
|
||||
where: {
|
||||
eventId: eventId,
|
||||
User: {
|
||||
username: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
}
|
||||
}
|
||||
|
||||
},
|
||||
select: {
|
||||
isPresent: true,
|
||||
User: {
|
||||
include: {
|
||||
Profile: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
} else {
|
||||
const data = await prisma.event_Peserta.findMany({
|
||||
skip: skipData,
|
||||
take: takeData,
|
||||
where: {
|
||||
eventId: eventId,
|
||||
User: {
|
||||
username: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
}
|
||||
}
|
||||
},
|
||||
select: {
|
||||
isPresent: true,
|
||||
User: {
|
||||
include: {
|
||||
Profile: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
const nCount = await prisma.event_Peserta.count({
|
||||
where: {
|
||||
eventId: eventId,
|
||||
User: {
|
||||
username: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
}
|
||||
}
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nPage: _.ceil(nCount / takeData),
|
||||
};
|
||||
}
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: "Success get data event detail",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
)
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data event detail >>", error);
|
||||
return NextResponse.json({
|
||||
success: false,
|
||||
message: "Error get data event detail",
|
||||
reason: (error as Error).message
|
||||
},
|
||||
{ status: 500 }
|
||||
)
|
||||
}
|
||||
}
|
||||
55
src/app/api/admin/event/[id]/route.ts
Normal file
55
src/app/api/admin/event/[id]/route.ts
Normal file
@@ -0,0 +1,55 @@
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import { NextResponse } from "next/server";
|
||||
import prisma from "@/lib/prisma";
|
||||
|
||||
export async function GET(
|
||||
req: Request,
|
||||
{ params }: { params: { id: string } }
|
||||
) {
|
||||
try {
|
||||
const { id } = params;
|
||||
const data = await prisma.event.findUnique({
|
||||
where: {
|
||||
id: id,
|
||||
},
|
||||
include: {
|
||||
Author: {
|
||||
select: {
|
||||
username: true,
|
||||
nomor: true,
|
||||
Profile: {
|
||||
select: {
|
||||
name: true,
|
||||
alamat: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
EventMaster_TipeAcara: {
|
||||
select: {
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
EventMaster_Status: true,
|
||||
},
|
||||
});
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get data event detail",
|
||||
data: data,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data event detail >>", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Error get data event detail",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
44
src/app/api/admin/event/dashboard/[name]/route.ts
Normal file
44
src/app/api/admin/event/dashboard/[name]/route.ts
Normal file
@@ -0,0 +1,44 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(
|
||||
request: Request,
|
||||
{ params }: { params: { name: string } }
|
||||
) {
|
||||
|
||||
const { name } = params;
|
||||
|
||||
try {
|
||||
let fixData;
|
||||
const fixStatus = _.startCase(name);
|
||||
fixData = await prisma.event.count({
|
||||
where: {
|
||||
EventMaster_Status: {
|
||||
name: fixStatus,
|
||||
},
|
||||
isArsip: false,
|
||||
},
|
||||
});
|
||||
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get data event dashboard",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data event dashboard >>", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Failed to get data",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
37
src/app/api/admin/event/dashboard/riwayat/route.ts
Normal file
37
src/app/api/admin/event/dashboard/riwayat/route.ts
Normal file
@@ -0,0 +1,37 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(request: Request) {
|
||||
try {
|
||||
let fixData;
|
||||
fixData = await prisma.event.count({
|
||||
where: {
|
||||
EventMaster_Status: {
|
||||
name: "Publish",
|
||||
},
|
||||
isArsip: true,
|
||||
},
|
||||
});
|
||||
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get data riwayat event dashboard",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data riwayat event dashboard >>", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Failed to get data",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
33
src/app/api/admin/event/dashboard/tipe-acara/route.ts
Normal file
33
src/app/api/admin/event/dashboard/tipe-acara/route.ts
Normal file
@@ -0,0 +1,33 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET() {
|
||||
try {
|
||||
const fixData = await prisma.eventMaster_TipeAcara.count({
|
||||
where: {
|
||||
active: true,
|
||||
},
|
||||
});
|
||||
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get data riwayat event dashboard",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data riwayat event dashboard >>", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Failed to get data",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
192
src/app/api/admin/event/riwayat/route.ts
Normal file
192
src/app/api/admin/event/riwayat/route.ts
Normal file
@@ -0,0 +1,192 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(request: Request) {
|
||||
|
||||
const { searchParams } = new URL(request.url);
|
||||
const search = searchParams.get("search");
|
||||
const page = searchParams.get("page");
|
||||
const takeData = 10;
|
||||
const skipData = Number(page) * takeData - takeData;
|
||||
|
||||
try {
|
||||
let fixData;
|
||||
|
||||
if (!page && !search) {
|
||||
fixData = await prisma.event.findMany({
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
EventMaster_Status: {
|
||||
name: "Publish",
|
||||
},
|
||||
isArsip: true,
|
||||
},
|
||||
include: {
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
Profile: {
|
||||
select: {
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
EventMaster_Status: true,
|
||||
EventMaster_TipeAcara: true,
|
||||
},
|
||||
});
|
||||
} else if (!page && search) {
|
||||
fixData = await prisma.event.findMany({
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
EventMaster_Status: {
|
||||
name: "Publish",
|
||||
},
|
||||
isArsip: true,
|
||||
title: {
|
||||
contains: search,
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
include: {
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
Profile: {
|
||||
select: {
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
EventMaster_Status: true,
|
||||
EventMaster_TipeAcara: true,
|
||||
},
|
||||
});
|
||||
} else if (page && !search) {
|
||||
const data = await prisma.event.findMany({
|
||||
take: takeData,
|
||||
skip: skipData,
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
EventMaster_Status: {
|
||||
name: "Publish",
|
||||
},
|
||||
isArsip: true,
|
||||
},
|
||||
include: {
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
Profile: {
|
||||
select: {
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
EventMaster_Status: true,
|
||||
EventMaster_TipeAcara: true,
|
||||
},
|
||||
});
|
||||
|
||||
const nCount = await prisma.event.count({
|
||||
where: {
|
||||
active: true,
|
||||
isArsip: true,
|
||||
EventMaster_Status: {
|
||||
name: "Publish",
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nPage: _.ceil(nCount / takeData),
|
||||
};
|
||||
} else if (page && search) {
|
||||
const data = await prisma.event.findMany({
|
||||
take: takeData,
|
||||
skip: skipData,
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
EventMaster_Status: {
|
||||
name: "Publish",
|
||||
},
|
||||
isArsip: true,
|
||||
title: {
|
||||
contains: search,
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
include: {
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
Profile: {
|
||||
select: {
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
EventMaster_Status: true,
|
||||
EventMaster_TipeAcara: true,
|
||||
},
|
||||
});
|
||||
|
||||
const nCount = await prisma.event.count({
|
||||
where: {
|
||||
active: true,
|
||||
isArsip: true,
|
||||
EventMaster_Status: {
|
||||
name: "Publish",
|
||||
},
|
||||
title: {
|
||||
contains: search,
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data,
|
||||
nPage: _.ceil(nCount / takeData),
|
||||
};
|
||||
}
|
||||
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get data riwayat event",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data riwayat event >>", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Error get data riwayat event",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
153
src/app/api/admin/event/status/[name]/route.ts
Normal file
153
src/app/api/admin/event/status/[name]/route.ts
Normal file
@@ -0,0 +1,153 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import moment from "moment";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(
|
||||
request: Request,
|
||||
{ params }: { params: { name: string } }
|
||||
) {
|
||||
const { name } = params;
|
||||
const { searchParams } = new URL(request.url);
|
||||
const search = searchParams.get("search");
|
||||
const page = searchParams.get("page");
|
||||
const takeData = 10;
|
||||
const skipData = Number(page) * takeData - takeData;
|
||||
|
||||
try {
|
||||
let fixData;
|
||||
const fixStatus = _.startCase(name);
|
||||
|
||||
if (!page) {
|
||||
fixData = await prisma.event.findMany({
|
||||
orderBy: {
|
||||
updatedAt: "desc",
|
||||
},
|
||||
where: {
|
||||
active: true,
|
||||
isArsip: false,
|
||||
EventMaster_Status: {
|
||||
name: fixStatus,
|
||||
},
|
||||
title: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
include: {
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
Profile: {
|
||||
select: {
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
EventMaster_Status: true,
|
||||
EventMaster_TipeAcara: true,
|
||||
},
|
||||
});
|
||||
} else {
|
||||
if (fixStatus === "Publish") {
|
||||
const getAllData = await prisma.event.findMany({
|
||||
where: {
|
||||
active: true,
|
||||
EventMaster_Status: {
|
||||
name: fixStatus,
|
||||
},
|
||||
isArsip: false,
|
||||
},
|
||||
});
|
||||
|
||||
for (let i of getAllData) {
|
||||
if (moment(i.tanggalSelesai).diff(moment(), "minutes") < 0) {
|
||||
await prisma.event.update({
|
||||
where: {
|
||||
id: i.id,
|
||||
},
|
||||
data: {
|
||||
isArsip: true,
|
||||
},
|
||||
});
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
const data = await prisma.event.findMany({
|
||||
take: takeData,
|
||||
skip: skipData,
|
||||
orderBy: {
|
||||
tanggal: "asc",
|
||||
},
|
||||
where: {
|
||||
active: true,
|
||||
isArsip: false,
|
||||
EventMaster_Status: {
|
||||
name: fixStatus,
|
||||
},
|
||||
title: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
include: {
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
Profile: {
|
||||
select: {
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
EventMaster_Status: true,
|
||||
EventMaster_TipeAcara: true,
|
||||
},
|
||||
});
|
||||
|
||||
const nCount = await prisma.event.count({
|
||||
where: {
|
||||
active: true,
|
||||
isArsip: false,
|
||||
EventMaster_Status: {
|
||||
name: fixStatus,
|
||||
},
|
||||
title: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nPage: _.ceil(nCount / takeData),
|
||||
};
|
||||
}
|
||||
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: `Success get data table event ${name}`,
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data table event dashboard >>", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Failed get data table event dashboard",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
102
src/app/api/admin/forum/[id]/komentar/route.ts
Normal file
102
src/app/api/admin/forum/[id]/komentar/route.ts
Normal file
@@ -0,0 +1,102 @@
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
import prisma from "@/lib/prisma";
|
||||
|
||||
export async function GET(
|
||||
request: Request,
|
||||
{ params }: { params: { id: string } }
|
||||
) {
|
||||
const { searchParams } = new URL(request.url);
|
||||
const search = searchParams.get("search");
|
||||
const page = searchParams.get("page");
|
||||
const takeData = 10;
|
||||
const skipData = Number(page) * takeData - takeData;
|
||||
|
||||
try {
|
||||
let fixData;
|
||||
const { id } = params;
|
||||
const postingId = id;
|
||||
|
||||
if (!page) {
|
||||
fixData = await prisma.forum_Komentar.findMany({
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
forum_PostingId: postingId,
|
||||
isActive: true,
|
||||
komentar: {
|
||||
contains: search ?? "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
include: {
|
||||
Forum_ReportKomentar: true,
|
||||
Author: {
|
||||
select: {
|
||||
username: true
|
||||
}
|
||||
}
|
||||
|
||||
},
|
||||
});
|
||||
} else {
|
||||
const data = await prisma.forum_Komentar.findMany({
|
||||
take: takeData,
|
||||
skip: skipData,
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
forum_PostingId: postingId,
|
||||
isActive: true,
|
||||
komentar: {
|
||||
contains: search ?? "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
include: {
|
||||
Forum_ReportKomentar: true,
|
||||
Author: {
|
||||
select: {
|
||||
username: true
|
||||
}
|
||||
}
|
||||
|
||||
},
|
||||
});
|
||||
|
||||
const nCount = await prisma.forum_Komentar.count({
|
||||
where: {
|
||||
forum_PostingId: postingId,
|
||||
isActive: true,
|
||||
komentar: {
|
||||
contains: search ?? "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nPage: _.ceil(nCount / takeData),
|
||||
};
|
||||
}
|
||||
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: "Berhasil mendapatkan data komentar",
|
||||
data: fixData,
|
||||
});
|
||||
} catch (error) {
|
||||
console.log("Error get data komentar", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
status: false,
|
||||
message: "Gagal mendapatkan data komentar",
|
||||
error: error || (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
109
src/app/api/admin/forum/[id]/report-komentar/route.ts
Normal file
109
src/app/api/admin/forum/[id]/report-komentar/route.ts
Normal file
@@ -0,0 +1,109 @@
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
import prisma from "@/lib/prisma";
|
||||
|
||||
export async function GET(
|
||||
request: Request,
|
||||
{ params }: { params: { id: string } }
|
||||
) {
|
||||
const { searchParams } = new URL(request.url);
|
||||
const search = searchParams.get("search");
|
||||
const page = searchParams.get("page");
|
||||
const takeData = 10;
|
||||
const skipData = Number(page) * takeData - takeData;
|
||||
|
||||
try {
|
||||
let fixData;
|
||||
const { id } = params;
|
||||
const komentarId = id;
|
||||
|
||||
if (!page) {
|
||||
fixData = await prisma.forum_ReportKomentar.findMany({
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
forum_KomentarId: komentarId,
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
isActive: true,
|
||||
createdAt: true,
|
||||
deskripsi: true,
|
||||
ForumMaster_KategoriReport: true,
|
||||
User: {
|
||||
select: {
|
||||
username: true,
|
||||
Profile: {
|
||||
select: {
|
||||
id: true,
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
} else {
|
||||
const data = await prisma.forum_ReportKomentar.findMany({
|
||||
take: takeData,
|
||||
skip: skipData,
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
forum_KomentarId: komentarId,
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
isActive: true,
|
||||
createdAt: true,
|
||||
deskripsi: true,
|
||||
ForumMaster_KategoriReport: true,
|
||||
User: {
|
||||
select: {
|
||||
username: true,
|
||||
Profile: {
|
||||
select: {
|
||||
id: true,
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
const nCount = await prisma.forum_ReportKomentar.count({
|
||||
where: {
|
||||
forum_KomentarId: komentarId,
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nPage: _.ceil(nCount / takeData),
|
||||
};
|
||||
}
|
||||
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get detail data report komentar",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get detail data report komentar >>", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Error get detail data report komentar",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
113
src/app/api/admin/forum/[id]/report-posting/route.ts
Normal file
113
src/app/api/admin/forum/[id]/report-posting/route.ts
Normal file
@@ -0,0 +1,113 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(request: Request,
|
||||
{ params }: { params: { id: string } }) {
|
||||
|
||||
const { searchParams } = new URL(request.url);
|
||||
const search = searchParams.get('search');
|
||||
const page = searchParams.get('page');
|
||||
const takeData = 10;
|
||||
const skipData = Number(page) * takeData - takeData;
|
||||
|
||||
try {
|
||||
let fixData;
|
||||
const { id } = params;
|
||||
const postingId = id
|
||||
|
||||
if (!page) {
|
||||
fixData = await prisma.forum_ReportPosting.findMany({
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
forum_PostingId: postingId,
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
deskripsi: true,
|
||||
createdAt: true,
|
||||
User: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
Profile: {
|
||||
select: {
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
ForumMaster_KategoriReport: {
|
||||
select: {
|
||||
id: true,
|
||||
title: true,
|
||||
deskripsi: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
} else {
|
||||
const data = await prisma.forum_ReportPosting.findMany({
|
||||
take: takeData,
|
||||
skip: skipData,
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
forum_PostingId: postingId,
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
deskripsi: true,
|
||||
createdAt: true,
|
||||
User: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
Profile: {
|
||||
select: {
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
ForumMaster_KategoriReport: {
|
||||
select: {
|
||||
id: true,
|
||||
title: true,
|
||||
deskripsi: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
const nCount = await prisma.forum_ReportPosting.count({
|
||||
where: {
|
||||
forum_PostingId: postingId,
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nPage: _.ceil(nCount / takeData),
|
||||
};
|
||||
}
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: "Success get data forum report posting",
|
||||
data: fixData
|
||||
},
|
||||
{ status: 200 }
|
||||
)
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data forum report posting >>", error);
|
||||
return NextResponse.json({
|
||||
success: false,
|
||||
message: "Error get data forum report posting",
|
||||
},
|
||||
{ status: 500 }
|
||||
)
|
||||
}
|
||||
}
|
||||
65
src/app/api/admin/forum/[id]/route.ts
Normal file
65
src/app/api/admin/forum/[id]/route.ts
Normal file
@@ -0,0 +1,65 @@
|
||||
import { NextResponse } from "next/server";
|
||||
import prisma from "@/lib/prisma";
|
||||
import _ from "lodash";
|
||||
|
||||
export async function GET(
|
||||
request: Request,
|
||||
{ params }: { params: { id: string } }
|
||||
) {
|
||||
try {
|
||||
const { id } = params;
|
||||
const data = await prisma.forum_Posting.findFirst({
|
||||
where: {
|
||||
id: id,
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
diskusi: true,
|
||||
ForumMaster_StatusPosting: {
|
||||
select: {
|
||||
id: true,
|
||||
status: true,
|
||||
},
|
||||
},
|
||||
authorId: true,
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
Profile: {
|
||||
select: {
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
Forum_Komentar: {
|
||||
where: {
|
||||
isActive: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
const result = {
|
||||
..._.omit(data, "Forum_Komentar"),
|
||||
Forum_Komentar: data?.Forum_Komentar.length,
|
||||
};
|
||||
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: "Success get data",
|
||||
data: result,
|
||||
});
|
||||
} catch (error) {
|
||||
console.error("Error get data forum", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Error get data forum",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
32
src/app/api/admin/forum/dashboard/publish/route.ts
Normal file
32
src/app/api/admin/forum/dashboard/publish/route.ts
Normal file
@@ -0,0 +1,32 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET() {
|
||||
try {
|
||||
const fixData = await prisma.forum_Posting.count({
|
||||
where: {
|
||||
isActive: true,
|
||||
},
|
||||
});
|
||||
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get data forum dashboard",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data forum dashboard", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Error get data forum dashboard",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
31
src/app/api/admin/forum/dashboard/report_komentar/route.ts
Normal file
31
src/app/api/admin/forum/dashboard/report_komentar/route.ts
Normal file
@@ -0,0 +1,31 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(request: Request) {
|
||||
|
||||
try {
|
||||
let fixData;
|
||||
fixData = await prisma.forum_ReportKomentar.count({
|
||||
where: {
|
||||
isActive: true,
|
||||
}
|
||||
})
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: "Success get data forum dashboard",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data forum dashboard", error);
|
||||
return NextResponse.json({
|
||||
success: false,
|
||||
message: "Error get data forum dashboard",
|
||||
reason: (error as Error).message
|
||||
},
|
||||
{ status: 500 }
|
||||
)
|
||||
}
|
||||
}
|
||||
30
src/app/api/admin/forum/dashboard/report_posting/route.ts
Normal file
30
src/app/api/admin/forum/dashboard/report_posting/route.ts
Normal file
@@ -0,0 +1,30 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(request: Request) {
|
||||
try {
|
||||
let fixData;
|
||||
fixData = await prisma.forum_ReportPosting.count({
|
||||
where: {
|
||||
isActive: true,
|
||||
}
|
||||
})
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: "Success get data forum dashboard",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data forum dashboard", error);
|
||||
return NextResponse.json({
|
||||
success: false,
|
||||
message: "Error get data forum dashboard",
|
||||
reason: (error as Error).message
|
||||
},
|
||||
{ status: 500 }
|
||||
)
|
||||
}
|
||||
}
|
||||
45
src/app/api/admin/forum/komentar/[id]/route.ts
Normal file
45
src/app/api/admin/forum/komentar/[id]/route.ts
Normal file
@@ -0,0 +1,45 @@
|
||||
import { NextResponse } from "next/server";
|
||||
import prisma from "@/lib/prisma";
|
||||
|
||||
export async function GET(
|
||||
request: Request,
|
||||
{ params }: { params: { id: string } }
|
||||
) {
|
||||
try {
|
||||
const { id } = params;
|
||||
const data = await prisma.forum_Komentar.findFirst({
|
||||
where: {
|
||||
id: id,
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
isActive: true,
|
||||
authorId: true,
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
},
|
||||
},
|
||||
komentar: true,
|
||||
forum_PostingId: true,
|
||||
},
|
||||
});
|
||||
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: "Success get data komentar",
|
||||
data: data,
|
||||
});
|
||||
} catch (error) {
|
||||
console.error("Error get data komentar", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Error get data komentar",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
122
src/app/api/admin/forum/komentar/route.ts
Normal file
122
src/app/api/admin/forum/komentar/route.ts
Normal file
@@ -0,0 +1,122 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(request: Request) {
|
||||
const { searchParams } = new URL(request.url);
|
||||
const search = searchParams.get("search");
|
||||
const page = searchParams.get("page");
|
||||
const takeData = 10;
|
||||
const skipData = Number(page) * takeData - takeData;
|
||||
|
||||
try {
|
||||
let fixData;
|
||||
|
||||
if (!page) {
|
||||
fixData = await prisma.forum_ReportKomentar.findMany({
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
Forum_Komentar: {
|
||||
isActive: true,
|
||||
komentar: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
},
|
||||
include: {
|
||||
ForumMaster_KategoriReport: true,
|
||||
User: {
|
||||
select: {
|
||||
username: true,
|
||||
Profile: {
|
||||
select: {
|
||||
id: true,
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
Forum_Komentar: {
|
||||
select: {
|
||||
id: true,
|
||||
komentar: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
} else {
|
||||
const data = await prisma.forum_ReportKomentar.findMany({
|
||||
take: takeData,
|
||||
skip: skipData,
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
Forum_Komentar: {
|
||||
isActive: true,
|
||||
komentar: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
},
|
||||
include: {
|
||||
ForumMaster_KategoriReport: true,
|
||||
User: {
|
||||
select: {
|
||||
username: true,
|
||||
Profile: {
|
||||
select: {
|
||||
id: true,
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
Forum_Komentar: {
|
||||
select: {
|
||||
id: true,
|
||||
komentar: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
const nCount = await prisma.forum_ReportKomentar.count({
|
||||
where: {
|
||||
Forum_Komentar: {
|
||||
isActive: true,
|
||||
komentar: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nCount: _.ceil(nCount / takeData),
|
||||
};
|
||||
}
|
||||
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get data forum komentar",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data forum komentar", error);
|
||||
return NextResponse.json({
|
||||
success: false,
|
||||
message: "Error get data forum komentar",
|
||||
reason: (error as Error).message,
|
||||
});
|
||||
}
|
||||
}
|
||||
153
src/app/api/admin/forum/posting/route.ts
Normal file
153
src/app/api/admin/forum/posting/route.ts
Normal file
@@ -0,0 +1,153 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(request: Request) {
|
||||
const { searchParams } = new URL(request.url);
|
||||
const search = searchParams.get("search");
|
||||
const page = searchParams.get("page");
|
||||
const takeData = 10;
|
||||
const skipData = Number(page) * takeData - takeData;
|
||||
|
||||
try {
|
||||
let fixData;
|
||||
|
||||
if (!page) {
|
||||
fixData = await prisma.forum_ReportPosting.findMany({
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
Forum_Posting: {
|
||||
isActive: true,
|
||||
diskusi: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
deskripsi: true,
|
||||
createdAt: true,
|
||||
User: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
Profile: {
|
||||
select: {
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
ForumMaster_KategoriReport: {
|
||||
select: {
|
||||
id: true,
|
||||
title: true,
|
||||
deskripsi: true,
|
||||
},
|
||||
},
|
||||
Forum_Posting: {
|
||||
select: {
|
||||
diskusi: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
} else {
|
||||
const data = await prisma.forum_ReportPosting.findMany({
|
||||
take: takeData,
|
||||
skip: skipData,
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
Forum_Posting: {
|
||||
isActive: true,
|
||||
diskusi: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
isActive: true,
|
||||
createdAt: true,
|
||||
deskripsi: true,
|
||||
forumMaster_KategoriReportId: true,
|
||||
ForumMaster_KategoriReport: {
|
||||
select: {
|
||||
id: true,
|
||||
title: true,
|
||||
deskripsi: true,
|
||||
},
|
||||
},
|
||||
|
||||
forum_PostingId: true,
|
||||
Forum_Posting: {
|
||||
select: {
|
||||
id: true,
|
||||
diskusi: true,
|
||||
ForumMaster_StatusPosting: {
|
||||
select: {
|
||||
id: true,
|
||||
status: true,
|
||||
},
|
||||
},
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
userId: true,
|
||||
User: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
const nCount = await prisma.forum_ReportPosting.count({
|
||||
where: {
|
||||
Forum_Posting: {
|
||||
isActive: true,
|
||||
diskusi: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nCount: _.ceil(nCount / takeData),
|
||||
};
|
||||
}
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get data forum posting",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data forum posting >>", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Error get data forum posting",
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
119
src/app/api/admin/forum/publish/route.ts
Normal file
119
src/app/api/admin/forum/publish/route.ts
Normal file
@@ -0,0 +1,119 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(request: Request) {
|
||||
const { searchParams } = new URL(request.url);
|
||||
const search = searchParams.get("search");
|
||||
const page = searchParams.get("page");
|
||||
const takeData = 10;
|
||||
const skipData = Number(page) * takeData - takeData;
|
||||
|
||||
try {
|
||||
let fixData;
|
||||
|
||||
if (!page) {
|
||||
fixData = await prisma.forum_Posting.findMany({
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
isActive: true,
|
||||
diskusi: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
diskusi: true,
|
||||
isActive: true,
|
||||
createdAt: true,
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
Profile: true,
|
||||
},
|
||||
},
|
||||
Forum_ReportPosting: true,
|
||||
Forum_Komentar: {
|
||||
where: {
|
||||
isActive: true,
|
||||
},
|
||||
},
|
||||
ForumMaster_StatusPosting: true,
|
||||
},
|
||||
});
|
||||
} else {
|
||||
const data = await prisma.forum_Posting.findMany({
|
||||
take: takeData,
|
||||
skip: skipData,
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
isActive: true,
|
||||
diskusi: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
select: {
|
||||
id: true,
|
||||
diskusi: true,
|
||||
isActive: true,
|
||||
createdAt: true,
|
||||
Author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
Profile: true,
|
||||
},
|
||||
},
|
||||
Forum_ReportPosting: true,
|
||||
Forum_Komentar: {
|
||||
where: {
|
||||
isActive: true,
|
||||
},
|
||||
},
|
||||
ForumMaster_StatusPosting: true,
|
||||
},
|
||||
});
|
||||
|
||||
const nCount = await prisma.forum_Posting.count({
|
||||
where: {
|
||||
isActive: true,
|
||||
diskusi: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nCount: _.ceil(nCount / takeData),
|
||||
};
|
||||
}
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get data table forum",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data table forum", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Error get data table forum",
|
||||
reason: error as Error,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
80
src/app/api/admin/investasi/[id]/detail/route.ts
Normal file
80
src/app/api/admin/investasi/[id]/detail/route.ts
Normal file
@@ -0,0 +1,80 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(req: Request,
|
||||
{ params }: { params: { id: string } }) {
|
||||
|
||||
|
||||
|
||||
try {
|
||||
const { id } = params;
|
||||
const investasiId = id;
|
||||
const data = await prisma.investasi.findUnique({
|
||||
where: {
|
||||
id: investasiId,
|
||||
},
|
||||
select: {
|
||||
imageId: true,
|
||||
prospektusFileId: true,
|
||||
id: true,
|
||||
author: {
|
||||
select: {
|
||||
id: true,
|
||||
username: true,
|
||||
nomor: true,
|
||||
Profile: true,
|
||||
},
|
||||
},
|
||||
title: true,
|
||||
authorId: true,
|
||||
hargaLembar: true,
|
||||
targetDana: true,
|
||||
totalLembar: true,
|
||||
sisaLembar: true,
|
||||
lembarTerbeli: true,
|
||||
progress: true,
|
||||
roi: true,
|
||||
active: true,
|
||||
createdAt: true,
|
||||
updatedAt: true,
|
||||
catatan: true,
|
||||
imagesId: true,
|
||||
MasterStatusInvestasi: true,
|
||||
BeritaInvestasi: true,
|
||||
DokumenInvestasi: true,
|
||||
ProspektusInvestasi: true,
|
||||
MasterPembagianDeviden: true,
|
||||
MasterPencarianInvestor: true,
|
||||
MasterPeriodeDeviden: true,
|
||||
MasterProgresInvestasi: true,
|
||||
masterStatusInvestasiId: true,
|
||||
Investasi_Invoice: {
|
||||
where: {
|
||||
statusInvoiceId: "1",
|
||||
},
|
||||
},
|
||||
countDown: true,
|
||||
|
||||
},
|
||||
});
|
||||
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: "Success get detail investasi",
|
||||
data: data,
|
||||
},
|
||||
{ status: 200 }
|
||||
)
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get detail investasi", error);
|
||||
return NextResponse.json({
|
||||
success: false,
|
||||
message: "Error get detail investasi",
|
||||
reason: (error as Error).message
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
|
||||
}
|
||||
}
|
||||
41
src/app/api/admin/investasi/[id]/detail_transaksi/route.ts
Normal file
41
src/app/api/admin/investasi/[id]/detail_transaksi/route.ts
Normal file
@@ -0,0 +1,41 @@
|
||||
import prisma from "@/lib/prisma";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import { NextResponse } from "next/server";
|
||||
export async function GET(req: Request,
|
||||
{ params }: { params: { id: string } }) {
|
||||
try {
|
||||
let fixData;
|
||||
const { id } = params
|
||||
const data = await prisma.investasi_Invoice.findUnique({
|
||||
where: {
|
||||
id: id
|
||||
},
|
||||
include: {
|
||||
Author: true,
|
||||
Images: true,
|
||||
StatusInvoice: true,
|
||||
MasterBank: true,
|
||||
}
|
||||
})
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
}
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: "Success get data detail transaksi",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
)
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data detail transaksi", error);
|
||||
return NextResponse.json({
|
||||
success: false,
|
||||
message: "Error get data detail transaksi",
|
||||
reason: (error as Error).message
|
||||
},
|
||||
{ status: 500 }
|
||||
)
|
||||
}
|
||||
}
|
||||
99
src/app/api/admin/investasi/[id]/transaksi/route.ts
Normal file
99
src/app/api/admin/investasi/[id]/transaksi/route.ts
Normal file
@@ -0,0 +1,99 @@
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
import prisma from "@/lib/prisma";
|
||||
|
||||
export async function GET(
|
||||
request: Request,
|
||||
{ params }: { params: { id: string } }
|
||||
) {
|
||||
try {
|
||||
let fixData;
|
||||
const { id } = params;
|
||||
const { searchParams } = new URL(request.url);
|
||||
const page = searchParams.get("page");
|
||||
const status = searchParams.get("status");
|
||||
const takeData = 10
|
||||
const skipData = Number(page) * takeData - takeData;
|
||||
|
||||
if (!page) {
|
||||
fixData = await prisma.investasi_Invoice.findMany({
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
investasiId: id,
|
||||
isActive: true,
|
||||
},
|
||||
include: {
|
||||
Author: true,
|
||||
Images: true,
|
||||
StatusInvoice: true,
|
||||
MasterBank: true,
|
||||
},
|
||||
});
|
||||
} else {
|
||||
const fixStatus = _.startCase(status ? status : "");
|
||||
|
||||
const data = await prisma.investasi_Invoice.findMany({
|
||||
take: takeData,
|
||||
skip: skipData,
|
||||
orderBy: {
|
||||
createdAt: "desc",
|
||||
},
|
||||
where: {
|
||||
investasiId: id,
|
||||
isActive: true,
|
||||
StatusInvoice: {
|
||||
name: {
|
||||
contains: fixStatus,
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
},
|
||||
include: {
|
||||
Author: true,
|
||||
Images: true,
|
||||
StatusInvoice: true,
|
||||
MasterBank: true,
|
||||
},
|
||||
});
|
||||
const nCount = await prisma.investasi_Invoice.count({
|
||||
where: {
|
||||
investasiId: id,
|
||||
isActive: true,
|
||||
StatusInvoice: {
|
||||
name: {
|
||||
contains: fixStatus,
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nPage: _.ceil(nCount / takeData),
|
||||
};
|
||||
}
|
||||
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get status transaksi",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Eror get status transaksi", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Error get status transaksi",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
36
src/app/api/admin/investasi/dashboard/[name]/route.ts
Normal file
36
src/app/api/admin/investasi/dashboard/[name]/route.ts
Normal file
@@ -0,0 +1,36 @@
|
||||
import { prisma } from "@/lib";
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(request: Request, { params }: { params: { name: string } }) {
|
||||
|
||||
const { name } = params;
|
||||
try {
|
||||
let fixData;
|
||||
const fixStatus = _.startCase(name);
|
||||
fixData = await prisma.investasi.count({
|
||||
where: {
|
||||
MasterStatusInvestasi: {
|
||||
name: fixStatus
|
||||
},
|
||||
}
|
||||
})
|
||||
return NextResponse.json({
|
||||
success: true,
|
||||
message: "Success get data investasi dashboard",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
)
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data investasi dashboard >>", error);
|
||||
return NextResponse.json({
|
||||
success: false,
|
||||
message: "Error get data investasi dashboard",
|
||||
reason: (error as Error).message
|
||||
},
|
||||
{ status: 500 }
|
||||
)
|
||||
}
|
||||
}
|
||||
138
src/app/api/admin/investasi/status/[name]/route.ts
Normal file
138
src/app/api/admin/investasi/status/[name]/route.ts
Normal file
@@ -0,0 +1,138 @@
|
||||
import { prisma } from "@/lib";
|
||||
import _ from "lodash";
|
||||
import { NextResponse } from "next/server";
|
||||
|
||||
export async function GET(
|
||||
request: Request,
|
||||
{
|
||||
params,
|
||||
}: {
|
||||
params: { name: string };
|
||||
}
|
||||
) {
|
||||
const method = request.method;
|
||||
if (method !== "GET") {
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Method not allowed",
|
||||
},
|
||||
{ status: 405 }
|
||||
);
|
||||
}
|
||||
|
||||
const { name } = params;
|
||||
const { searchParams } = new URL(request.url);
|
||||
const search = searchParams.get("search");
|
||||
const page = searchParams.get("page");
|
||||
const takeData = 10;
|
||||
const skipData = Number(page) * takeData - takeData;
|
||||
|
||||
try {
|
||||
let fixData;
|
||||
const fixStatus = _.startCase(name);
|
||||
|
||||
if (!page) {
|
||||
fixData = await prisma.investasi.findMany({
|
||||
orderBy: {
|
||||
updatedAt: "desc",
|
||||
},
|
||||
where: {
|
||||
active: true,
|
||||
MasterStatusInvestasi: {
|
||||
name: fixStatus,
|
||||
},
|
||||
title: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
include: {
|
||||
MasterStatusInvestasi: true,
|
||||
BeritaInvestasi: true,
|
||||
DokumenInvestasi: true,
|
||||
ProspektusInvestasi: true,
|
||||
MasterPembagianDeviden: true,
|
||||
MasterPencarianInvestor: true,
|
||||
MasterPeriodeDeviden: true,
|
||||
author: true,
|
||||
Investasi_Invoice: {
|
||||
where: {
|
||||
statusInvoiceId: "2",
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
} else {
|
||||
const data = await prisma.investasi.findMany({
|
||||
take: takeData,
|
||||
skip: skipData,
|
||||
orderBy: {
|
||||
updatedAt: "desc",
|
||||
},
|
||||
where: {
|
||||
active: true,
|
||||
MasterStatusInvestasi: {
|
||||
name: fixStatus,
|
||||
},
|
||||
title: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
include: {
|
||||
MasterStatusInvestasi: true,
|
||||
BeritaInvestasi: true,
|
||||
DokumenInvestasi: true,
|
||||
ProspektusInvestasi: true,
|
||||
MasterPembagianDeviden: true,
|
||||
MasterPencarianInvestor: true,
|
||||
MasterPeriodeDeviden: true,
|
||||
author: true,
|
||||
Investasi_Invoice: {
|
||||
where: {
|
||||
statusInvoiceId: "2",
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
const nCount = await prisma.investasi.count({
|
||||
where: {
|
||||
active: true,
|
||||
MasterStatusInvestasi: {
|
||||
name: fixStatus,
|
||||
},
|
||||
title: {
|
||||
contains: search ? search : "",
|
||||
mode: "insensitive",
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
fixData = {
|
||||
data: data,
|
||||
nPage: _.ceil(nCount / takeData),
|
||||
};
|
||||
}
|
||||
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success",
|
||||
data: fixData,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
console.log(error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Failed",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
53
src/app/api/admin/job/[id]/route.ts
Normal file
53
src/app/api/admin/job/[id]/route.ts
Normal file
@@ -0,0 +1,53 @@
|
||||
import backendLogger from "@/util/backendLogger";
|
||||
import { NextResponse } from "next/server";
|
||||
import prisma from "@/lib/prisma";
|
||||
|
||||
export { GET };
|
||||
|
||||
async function GET(request: Request, { params }: { params: { id: string } }) {
|
||||
try {
|
||||
const { id } = params;
|
||||
const data = await prisma.job.findUnique({
|
||||
where: {
|
||||
id: id,
|
||||
},
|
||||
include: {
|
||||
Author: {
|
||||
select: {
|
||||
username: true,
|
||||
nomor: true,
|
||||
Profile: {
|
||||
select: {
|
||||
name: true,
|
||||
alamat: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
MasterStatus: {
|
||||
select: {
|
||||
name: true,
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: true,
|
||||
message: "Success get data job-vacancy",
|
||||
data: data,
|
||||
},
|
||||
{ status: 200 }
|
||||
);
|
||||
} catch (error) {
|
||||
backendLogger.error("Error get data job-vacancy", error);
|
||||
return NextResponse.json(
|
||||
{
|
||||
success: false,
|
||||
message: "Error get data job-vacancy",
|
||||
reason: (error as Error).message,
|
||||
},
|
||||
{ status: 500 }
|
||||
);
|
||||
}
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user