- attivita
- gestione degli script sul server - creato websocket per interagire con gli script del server.
This commit is contained in:
@@ -125,6 +125,12 @@ const MyGroupSchema = new Schema({
|
||||
lastdate_reqRisGroup: {
|
||||
type: Date,
|
||||
},
|
||||
|
||||
idMyGroup: {
|
||||
type: String,
|
||||
},
|
||||
// **ADDFIELD_MYGROUPS
|
||||
|
||||
});
|
||||
|
||||
MyGroupSchema.statics.getFieldsForSearch = function () {
|
||||
@@ -236,7 +242,7 @@ MyGroupSchema.statics.getListAdminsByGroupName = async function (idapp, groupnam
|
||||
|
||||
MyGroupSchema.statics.getWhatToShow = function (idapp, username) {
|
||||
// FOR ME, PERMIT ALL
|
||||
return {
|
||||
let whatToShow = {
|
||||
groupname: 1,
|
||||
title: 1,
|
||||
descr: 1,
|
||||
@@ -260,10 +266,14 @@ MyGroupSchema.statics.getWhatToShow = function (idapp, username) {
|
||||
lastdate_reqRisGroup: 1,
|
||||
};
|
||||
|
||||
whatToShow = { ...whatToShow, ...shared_consts.ANNUNCI_FIELDS };
|
||||
|
||||
return whatToShow;
|
||||
|
||||
};
|
||||
|
||||
MyGroupSchema.statics.getWhatToShow_Unknown = function (idapp, username) {
|
||||
return {
|
||||
let whatToShow = {
|
||||
groupname: 1,
|
||||
title: 1,
|
||||
descr: 1,
|
||||
@@ -277,6 +287,11 @@ MyGroupSchema.statics.getWhatToShow_Unknown = function (idapp, username) {
|
||||
mycircuits: 1,
|
||||
lastdate_reqRisGroup: 1,
|
||||
};
|
||||
|
||||
whatToShow = { ...whatToShow, ...shared_consts.ANNUNCI_FIELDS };
|
||||
|
||||
return whatToShow;
|
||||
|
||||
};
|
||||
|
||||
MyGroupSchema.statics.getArrUsernameFromFieldByGroupname = async function (
|
||||
@@ -648,7 +663,16 @@ MyGroupSchema.statics.setReceiveRisGroup = async function (idapp, groupname) {
|
||||
|
||||
};
|
||||
|
||||
MyGroupSchema.statics.getFieldsForAnnunci = function () {
|
||||
let annunciFields = {
|
||||
idMyGroup: {
|
||||
type: String,
|
||||
},
|
||||
// **ADDFIELD_MYGROUPS
|
||||
};
|
||||
|
||||
return annunciFields;
|
||||
};
|
||||
|
||||
const MyGroup = mongoose.model('MyGroup', MyGroupSchema);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user