first commit

This commit is contained in:
Isuru Bimsara
2026-08-14 22:46:02 +05:30
commit 81d0e65686
132 changed files with 24398 additions and 0 deletions
+54
View File
@@ -0,0 +1,54 @@
/**
* © 2026 Niolla. All rights reserved.
*
* This file is part of the Niolla software project and is intended for internal use only.
* Unauthorized copying, modification, distribution, or disclosure of this file,
* via any medium, is strictly prohibited without written permission from Niolla.
*
* For inquiries, contact: support@niolla.lk
*/
// app/models/upload.model.js
module.exports = (sequelize, DataTypes) => {
const upload = sequelize.define(
"upload",
{
id: {
type: DataTypes.INTEGER,
autoIncrement: true,
primaryKey: true,
},
file_path: {
type: DataTypes.STRING,
allowNull: false,
},
file_type: {
type: DataTypes.STRING,
allowNull: false,
},
file_size: {
type: DataTypes.INTEGER,
allowNull: false,
},
original_name: {
type: DataTypes.STRING,
allowNull: false,
},
use_for: {
type: DataTypes.STRING,
allowNull: false,
},
uploaded_by: {
type: DataTypes.STRING,
allowNull: false,
},
},
{
tableName: "uploads",
timestamps: true,
},
);
return upload;
};