mirror of
https://github.com/NebulaServices/Nebula.git
synced 2025-05-13 03:50:02 -04:00
change db schema
This commit is contained in:
parent
a2b21a141a
commit
c8a88b837f
1 changed files with 12 additions and 6 deletions
18
server.js
18
server.js
|
@ -27,6 +27,9 @@ const catalog_assets = sequelize.define("catalog_assets", {
|
||||||
description: {
|
description: {
|
||||||
type: DataTypes.TEXT,
|
type: DataTypes.TEXT,
|
||||||
},
|
},
|
||||||
|
image: {
|
||||||
|
type: DataTypes.TEXT,
|
||||||
|
},
|
||||||
tags: {
|
tags: {
|
||||||
type: DataTypes.JSON,
|
type: DataTypes.JSON,
|
||||||
allowNull: true,
|
allowNull: true,
|
||||||
|
@ -34,11 +37,11 @@ const catalog_assets = sequelize.define("catalog_assets", {
|
||||||
version: {
|
version: {
|
||||||
type: DataTypes.TEXT,
|
type: DataTypes.TEXT,
|
||||||
},
|
},
|
||||||
image: {
|
background_image: {
|
||||||
type: DataTypes.TEXT,
|
type: DataTypes.TEXT,
|
||||||
allowNull: true,
|
allowNull: true,
|
||||||
},
|
},
|
||||||
video: {
|
background_video: {
|
||||||
type: DataTypes.TEXT,
|
type: DataTypes.TEXT,
|
||||||
allowNull: true,
|
allowNull: true,
|
||||||
},
|
},
|
||||||
|
@ -80,10 +83,11 @@ app.get("/api/catalog-assets", async (request, reply) => {
|
||||||
acc[asset.package_name] = {
|
acc[asset.package_name] = {
|
||||||
title: asset.title,
|
title: asset.title,
|
||||||
description: asset.description,
|
description: asset.description,
|
||||||
|
image: asset.image,
|
||||||
tags: asset.tags,
|
tags: asset.tags,
|
||||||
version: asset.version,
|
version: asset.version,
|
||||||
image: asset.image,
|
background_image: asset.background_image,
|
||||||
video: asset.video,
|
background_video: asset.background_video,
|
||||||
payload: asset.payload,
|
payload: asset.payload,
|
||||||
type: asset.type,
|
type: asset.type,
|
||||||
};
|
};
|
||||||
|
@ -123,10 +127,11 @@ app.get("/api/packages/:package", async (request, reply) => {
|
||||||
const details = {
|
const details = {
|
||||||
title: package_row.get("title"),
|
title: package_row.get("title"),
|
||||||
description: package_row.get("description"),
|
description: package_row.get("description"),
|
||||||
|
image: package_row.get("image"),
|
||||||
tags: package_row.get("tags"),
|
tags: package_row.get("tags"),
|
||||||
version: package_row.get("version"),
|
version: package_row.get("version"),
|
||||||
image: package_row.get("image"),
|
background_image: package_row.get("background_image"),
|
||||||
video: package_row.get("video"),
|
background_video: package_row.get("background_video"),
|
||||||
payload: package_row.get("payload"),
|
payload: package_row.get("payload"),
|
||||||
type: package_row.get("type"),
|
type: package_row.get("type"),
|
||||||
};
|
};
|
||||||
|
@ -139,6 +144,7 @@ app.get("/api/packages/:package", async (request, reply) => {
|
||||||
// await catalog_assets.create({
|
// await catalog_assets.create({
|
||||||
// package_name: "trolled.fortnite.jpeg",
|
// package_name: "trolled.fortnite.jpeg",
|
||||||
// title: "fortnite.jpeg",
|
// title: "fortnite.jpeg",
|
||||||
|
// image: "fortnite.jpg"
|
||||||
// version: "6.9.420",
|
// version: "6.9.420",
|
||||||
// description: "a man in a blessings shirt sticking his tounge out",
|
// description: "a man in a blessings shirt sticking his tounge out",
|
||||||
// tags: ["Fortnite", "Shit out my ass"],
|
// tags: ["Fortnite", "Shit out my ass"],
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue