Lista Doni Navi
This commit is contained in:
7
src/server/models/myevent.js
Normal file → Executable file
7
src/server/models/myevent.js
Normal file → Executable file
@@ -121,7 +121,7 @@ MyEventSchema.statics.getLastEvents = async function (idapp) {
|
||||
const lastn = await Settings.getValDbSettings(idapp, 'SHOW_LAST_N_EV', 1);
|
||||
|
||||
const query = [
|
||||
{ $match: { idapp, dateTimeStart: { $gte: tools.IncDateNow(- 1000 * 60 * 60 * 24) } } },
|
||||
{ $match: { idapp, dateTimeStart: { $gte: tools.IncDateNow(-1000 * 60 * 60 * 24) } } },
|
||||
{
|
||||
$lookup: {
|
||||
from: 'operators',
|
||||
@@ -165,7 +165,10 @@ MyEventSchema.statics.getLastEvents = async function (idapp) {
|
||||
|
||||
|
||||
MyEventSchema.statics.getFieldsForSearch = function () {
|
||||
return ['short_tit', 'title', 'teacher', 'details']
|
||||
return [{ field: 'short_tit', type: tools.FieldType.string },
|
||||
{ field: 'title', type: tools.FieldType.string },
|
||||
{ field: 'teacher', type: tools.FieldType.string },
|
||||
{ field: 'details', type: tools.FieldType.string }]
|
||||
};
|
||||
|
||||
MyEventSchema.statics.executeQueryTable = function (idapp, params) {
|
||||
|
||||
Reference in New Issue
Block a user