Traccar as a Service User expirationTime

GrupoVR3 years ago

Hi there!

Is there a parameter that disables the manager's limitation not being able to set an expiration date greater than its own?

Or any way to update a user via API without passing the expiration date? Keeping the current date.

I have the scenario of traccar as a service where a manager pays monthly and his customer pays annually and the manager cannot update any customer information such as Name, Phone, etc... Because he must pass the expiration date.

Anton Tananaev3 years ago

If you don't change the expiration, I think it should work. Otherwise it sounds like a bug.

GrupoVR3 years ago

If I send the same date (not changing):

{"id":"21","name":"Enzo Henrique Araújo","email":"e***@***m.com.br","phone":"27685478565","administrator":false,"deviceLimit":"0","userLimit":"0","password":"","disabled":false,"expirationTime":"2023-06-06T03:00:00.000Z","attributes":""}

I receive that response:

Administrator access required - SecurityException (PermissionsService:77 < *:163 < BaseObjectResource:90 < ...)

If I don't send expiration time:

{"id":"21","name":"Enzo Henrique Araújo","email":"e***@***m.com.br","phone":"27685478565","administrator":false,"deviceLimit":"0","userLimit":"0","password":"","disabled":false,"attributes":""}

I receive the same response:

Administrator access required - SecurityException (PermissionsService:77 < *:163 < BaseObjectResource:90 < ...)

If I send empty like password:

{"id":"21","name":"Enzo Henrique Araújo","email":"e***@***m.com.br","phone":"27685478565","administrator":false,"deviceLimit":"0","userLimit":"0","password":"","disabled":false,"expirationTime":"","attributes":""}

I receive the same response:

Administrator access required - SecurityException (PermissionsService:77 < *:163 < BaseObjectResource:90 < ...)
Anton Tananaev3 years ago

Please create a bug ticket on GitHub.

GrupoVR3 years ago

Done, Thanks!