feat: Adding privacy to loads and companies endpoint

This commit is contained in:
Josepablo Cruz
2026-03-30 19:08:36 -06:00
parent e2582f7464
commit 30cd506862
8 changed files with 270 additions and 40 deletions

View File

@@ -59,6 +59,7 @@ const schema = new Schema({
lng: { type: String },
is_hidden: { type: Boolean, default: false },
privacy: { type: Boolean, default: false }, /// Disables visibility on the directory, only enabled for private groups.
createdAt: { type : Date, required : true, default : () => { return Date.now(); } }
});

View File

@@ -90,7 +90,9 @@ const schema = new Schema({
payment_term: { type: String },
terms_and_conditions: { type: String },
createdAt: { type : Date, required : true, default : () => { return Date.now(); } }
createdAt: { type : Date, required : true, default : () => { return Date.now(); } },
privacy: { type: Boolean, default: false }, /// Disables visibility on the directory, only enabled for private groups.
});
module.exports = mongoose.model( "loads", schema );