Default metadata value of the currently logged in user

Technical aspects, customization, code samples.
Post Reply
PeBe
Posts: 2
Joined: Fri Jan 08, 2021 12:07 pm

Default metadata value of the currently logged in user

Post by PeBe »

Is there any possibility to insert the default value with the name of the currently logged in user, into the text field of the document metadata? I mean some django template tag or native variable of Mayan, similar to e.g. the current date and time {% now "SHORT_DATETIME_FORMAT" %}
User avatar
rosarior
Developer
Developer
Posts: 649
Joined: Tue Aug 21, 2018 3:28 am
Location: Puerto Rico
Contact:

Re: Default metadata value of the currently logged in user

Post by rosarior »

Not at the moment.

We have seen this request in the past but are unsure how to proceed. The template system also works for non interactive purposes. There might also be performance and security concerns with making the entire request object available in the template context.

The technical aspect of making the request and/or user available are not difficult, it is more of a design decision as it is hard to determine the negative consequences of the change.
PeBe
Posts: 2
Joined: Fri Jan 08, 2021 12:07 pm

Re: Default metadata value of the currently logged in user

Post by PeBe »

Thank you for reply. I am sure that the implementation of this feature would be appreciated by many users, and I hope you will consider doing it in the near future.
Post Reply