This commit is contained in:
Flatlogic Bot 2026-03-11 22:01:23 +00:00
parent b0b2dc530c
commit c15f7371d4
17 changed files with 75 additions and 23 deletions

View File

@ -461,12 +461,12 @@ module.exports = class Courier_profilesDBApi {
{
model: db.file,
model: db.files,
as: 'verification_files',
},
{
model: db.file,
model: db.files,
as: 'profile_images',
},

View File

@ -36,7 +36,7 @@ module.exports = class FileDBApi {
);
for (const file of inexistentFiles) {
await db.file.create(
await db.files.create(
{
belongsTo: relation.belongsTo,
belongsToColumn: relation.belongsToColumn,
@ -62,7 +62,7 @@ module.exports = class FileDBApi {
) {
const transaction = (options && options.transaction) || undefined;
const filesToDelete = await db.file.findAll({
const filesToDelete = await db.files.findAll({
where: {
belongsTo: relation.belongsTo,
belongsToId: relation.belongsToId,

View File

@ -456,12 +456,12 @@ module.exports = class Merchant_profilesDBApi {
{
model: db.file,
model: db.files,
as: 'logo_images',
},
{
model: db.file,
model: db.files,
as: 'banner_images',
},

View File

@ -367,7 +367,7 @@ module.exports = class Product_categoriesDBApi {
{
model: db.file,
model: db.files,
as: 'category_images',
},

View File

@ -460,7 +460,7 @@ module.exports = class ProductsDBApi {
{
model: db.file,
model: db.files,
as: 'product_images',
},

View File

@ -498,7 +498,7 @@ module.exports = class StoresDBApi {
{
model: db.file,
model: db.files,
as: 'store_images',
},

View File

@ -448,7 +448,7 @@ module.exports = class Support_ticketsDBApi {
{
model: db.file,
model: db.files,
as: 'attachment_files',
},

View File

@ -577,7 +577,7 @@ module.exports = class UsersDBApi {
{
model: db.file,
model: db.files,
as: 'avatar',
},

View File

@ -163,7 +163,7 @@ rating_count: {
db.courier_profiles.hasMany(db.file, {
db.courier_profiles.hasMany(db.files, {
as: 'verification_files',
foreignKey: 'belongsToId',
constraints: false,
@ -173,7 +173,7 @@ rating_count: {
},
});
db.courier_profiles.hasMany(db.file, {
db.courier_profiles.hasMany(db.files, {
as: 'profile_images',
foreignKey: 'belongsToId',
constraints: false,

View File

@ -1,6 +1,6 @@
module.exports = function(sequelize, DataTypes) {
const file = sequelize.define(
'file',
'files',
{
id: {
type: DataTypes.UUID,
@ -40,11 +40,11 @@ module.exports = function(sequelize, DataTypes) {
);
file.associate = (db) => {
db.file.belongsTo(db.users, {
db.files.belongsTo(db.users, {
as: 'createdBy',
});
db.file.belongsTo(db.users, {
db.files.belongsTo(db.users, {
as: 'updatedBy',
});
};

View File

@ -171,7 +171,7 @@ status: {
db.merchant_profiles.hasMany(db.file, {
db.merchant_profiles.hasMany(db.files, {
as: 'logo_images',
foreignKey: 'belongsToId',
constraints: false,
@ -181,7 +181,7 @@ status: {
},
});
db.merchant_profiles.hasMany(db.file, {
db.merchant_profiles.hasMany(db.files, {
as: 'banner_images',
foreignKey: 'belongsToId',
constraints: false,

View File

@ -119,7 +119,7 @@ is_active: {
db.product_categories.hasMany(db.file, {
db.product_categories.hasMany(db.files, {
as: 'category_images',
foreignKey: 'belongsToId',
constraints: false,

View File

@ -166,7 +166,7 @@ is_featured: {
db.products.hasMany(db.file, {
db.products.hasMany(db.files, {
as: 'product_images',
foreignKey: 'belongsToId',
constraints: false,

View File

@ -219,7 +219,7 @@ closed_at: {
db.stores.hasMany(db.file, {
db.stores.hasMany(db.files, {
as: 'store_images',
foreignKey: 'belongsToId',
constraints: false,

View File

@ -195,7 +195,7 @@ resolved_at: {
db.support_tickets.hasMany(db.file, {
db.support_tickets.hasMany(db.files, {
as: 'attachment_files',
foreignKey: 'belongsToId',
constraints: false,

View File

@ -276,7 +276,7 @@ provider: {
db.users.hasMany(db.file, {
db.users.hasMany(db.files, {
as: 'avatar',
foreignKey: 'belongsToId',
constraints: false,

View File

@ -0,0 +1,52 @@
{
"pages": {
"dashboard": {
"pageTitle": "Dashboard",
"overview": "Overview",
"loadingWidgets": "Loading widgets...",
"loading": "Loading..."
},
"login": {
"pageTitle": "Login",
"form": {
"loginLabel": "Login",
"loginHelp": "Please enter your login",
"passwordLabel": "Password",
"passwordHelp": "Please enter your password",
"remember": "Remember",
"forgotPassword": "Forgot password?",
"loginButton": "Login",
"loading": "Loading...",
"noAccountYet": "Dont have an account yet?",
"newAccount": "New Account"
},
"pexels": {
"photoCredit": "Photo by {{photographer}} on Pexels",
"videoCredit": "Video by {{name}} on Pexels",
"videoUnsupported": "Your browser does not support the video tag."
},
"footer": {
"copyright": "© {{year}} {{title}}. All rights reserved",
"privacy": "Privacy Policy"
}
}
},
"components": {
"widgetCreator": {
"title": "Create Chart or Widget",
"helpText": "Describe your new widget or chart in natural language. For example: \"Number of admin users\" OR \"red chart with number of closed contracts grouped by month\"",
"settingsTitle": "Widget Creator Settings",
"settingsDescription": "What role are we showing and creating widgets for?",
"doneButton": "Done",
"loading": "Loading..."
},
"search": {
"placeholder": "Search",
"required": "Required",
"minLength": "Minimum length: {{count}} characters"
}
}
}