- Modified privacywrite query with graphLookup:

$graphLookup: {
        from: "projects",
        startWith: "$id_main_project",
        connectFromField: "id_main_project",
        connectToField: "_id",
        as: "ris",
        restrictSearchWithMatch: { $or: [{ privacyread: server_constants.Privacy.all }, { userId: userId }] }
      }
    },
    { $match: { "ris.privacyread": { $exists: true } } },
This commit is contained in:
Paolo Arena
2019-04-13 03:04:40 +02:00
parent 7b1e24c407
commit 3c05d2d9c7
10 changed files with 94 additions and 95 deletions

View File

@@ -174,20 +174,6 @@ export default class SingleTodo extends Vue {
this.clButtPopover += ' pos-item-popover_cursor'
}
// if (this.inEdit) {
// this.classDescr += ' hide'
// this.classDescrEdit += ' show'
// } else {
// this.classDescrEdit += ' hide'
// this.classDescr += ' show'
// }
// this.getinputdescr = 'inputdescr' + this.itemtodo._id
// console.log('classDescrEdit = ', this.classDescrEdit)
// console.log('classDescr', this.classDescr)
// console.log('UserStore.state.lang', UserStore.state.lang)
if (this.isTodo()) {
this.menuPopupTodo = tools.menuPopupTodo[UserStore.state.lang]
}
@@ -295,10 +281,11 @@ export default class SingleTodo extends Vue {
}
if (!!theField) {
console.log('FOCUS TODO', theField)
theField.focus()
}
// console.log('focus()')
}, 100)
}, 300)
}
public exitEdit(singola: boolean = false) {
@@ -408,6 +395,8 @@ export default class SingleTodo extends Vue {
} else {
this.itemtodo.statustodo = tools.Status.COMPLETED
}
this.itemtodo.progress = 100
this.watchupdate('statustodo')
this.deselectAndExitEdit()