- Permissions table (probably I'll change for others uses)
- Added CDateTime component (to save in the db)... in the component CGridTableRec and for CEventsCalendar
This commit is contained in:
@@ -105,10 +105,20 @@ MyEventSchema.statics.findAllIdApp = function (idapp) {
|
||||
};
|
||||
|
||||
|
||||
MyEventSchema.statics.getFieldsForSearch = function () {
|
||||
return ['short_tit', 'title', 'teacher', 'details']
|
||||
};
|
||||
|
||||
MyEventSchema.statics.executeQueryTable = function (idapp, params) {
|
||||
params.fieldsearch = this.getFieldsForSearch();
|
||||
return tools.executeQueryTable(this, idapp, params);
|
||||
};
|
||||
|
||||
if (tools.INITDB_FIRSTIME) {
|
||||
// console.log(' createIndex MyEvent Index...');
|
||||
// MyEventSchema.index({ short_tit: 'text', title: 'text', teacher: 'text', details: 'text' });
|
||||
}
|
||||
|
||||
|
||||
const MyEvent = mongoose.model('MyEvent', MyEventSchema);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user