fixed updating with password changes
This commit is contained in:
@@ -4,7 +4,6 @@ import UpdateEmployeeValidator from 'App/Validators/UpdateEmployeeValidator'
|
||||
import CreateEmployeeValidator from 'App/Validators/CreateEmployeeValidator'
|
||||
|
||||
import Database from '@ioc:Adonis/Lucid/Database'
|
||||
import Logger from '@ioc:Adonis/Core/Logger'
|
||||
|
||||
type ResultShow = {
|
||||
id: number,
|
||||
|
||||
@@ -85,6 +85,9 @@ export default class UpdateEmployeeValidator {
|
||||
table: 'employees',
|
||||
column: 'username',
|
||||
caseInsensitive: true,
|
||||
whereNot: {
|
||||
id: this.ctx.params.id
|
||||
}
|
||||
})
|
||||
]
|
||||
),
|
||||
|
||||
Reference in New Issue
Block a user