Initial commit: Angular frontend and Expressjs backend

This commit is contained in:
chamikaJ
2024-05-17 09:32:30 +05:30
parent eb0a0d77d6
commit 298ca6beeb
3548 changed files with 193558 additions and 3 deletions

View File

@@ -0,0 +1,13 @@
export default {
type: "object",
properties: {
to: {
type: "array",
items: {type: "string"},
minItems: 1 // Optional field, at least 1 item required
},
subject: {type: "string"},
html: {type: "string"}
},
required: ["to", "subject", "html"] // subject and html fields are required
};

View File

@@ -0,0 +1,14 @@
export default {
type: "object",
properties: {
name: {type: "string", message: "Invalid Name"},
sku: {type: "string", message: "Invalid SKU"},
stock_amount: {type: "number", message: "Invalid Stock Amount"},
image: {type: "string", message: "Invalid Image"},
price: {type: "number", message: "Invalid Price"},
value: {type: "number", message: "Invalid Value"},
active: {type: "boolean", message: "Invalid type of Active"},
category_id: {type: "string", message: "Invalid Category"}
},
required: ["name", "sku", "stock_amount", "image", "price", "value", "active", "category_id"],
};

View File

@@ -0,0 +1,13 @@
export default {
type: "object",
properties: {
name: {
type: "string",
minLength: 2,
maxLength: 20,
message: "Invalid category name"
},
color_code: {type: ["string", "null"]}
},
required: ["name"]
};

View File

@@ -0,0 +1,13 @@
export default {
type: "object",
properties: {
name: {
type: "string",
minLength: 2,
maxLength: 20,
message: "Invalid folder name"
},
color_code: {type: ["string", "null"]}
},
required: ["name"]
};

View File

@@ -0,0 +1,12 @@
export default {
type: "object",
properties: {
name: {
type: "string",
message: "Invalid name",
minLength: 2,
maxLength: 30
}
},
required: ["name"]
};