"add admin user seed script and refactor common seed utilities"

This commit is contained in:
louiscklaw
2025-05-11 10:34:48 +08:00
parent c29ab4b920
commit 60eed00cb2
26 changed files with 1426 additions and 506 deletions

View File

@@ -1,6 +1,27 @@
module.exports = {
ASSETS_DIR: '/pb_hooks/assets',
id_v: '1'.padStart(15, 0), //id_vocabulary
id_c: '2'.padStart(15, 0), //id_connectives
cat_id_tech: '3'.padStart(15, 0), // category id of technology
ASSETS_DIR: "/pb_hooks/assets",
id_v: "1".padStart(15, 0), //id_vocabulary
id_c: "2".padStart(15, 0), //id_connectives
//
cat_id_news: "1".padStart(15, 0), // category id of news
cat_id_sport: "2".padStart(15, 0), // category id of sports
cat_id_tech: "3".padStart(15, 0), // category id of technology
cat_id_art: "4".padStart(15, 0), // category id of art
cat_id_basic: "5".padStart(15, 0), // category id of basic
cat_id_nature: "6".padStart(15, 0), // category id of nature
cat_id_workplace: "7".padStart(15, 0), // category id of workplace
//
cat_id_connectives_1: "11".padStart(15, 0), // category id of workplace
//
LP_cat_id_news: "1".padStart(15, 0),
LP_cat_id_sports: "2".padStart(15, 0),
LP_cat_id_technology: "3".padStart(15, 0),
//
MF_cat_id_news: "1".padStart(15, 0),
MF_cat_id_sports: "2".padStart(15, 0),
MF_cat_id_technology: "3".padStart(15, 0),
//
CR_cat_id_news: "1".padStart(15, 0),
CR_cat_id_sports: "2".padStart(15, 0),
CR_cat_id_technology: "3".padStart(15, 0),
};