Set user Last name in defaults

Hello everybody!

In custom doctype I’ve created a field to show the owner of the record. In default I put “user” and it shows only name of user. Is there an easy way to get user “last_name” there (without custom script)? How to script in default field? Tried “user.last_name” but didn’t work. Compiles this as text.

Hi OlegKuryshev,

use user_fullname


Hi saurabh! Thank You! It works. And can You tell me where to find those namefields? I mean, for date I know it works “today” and thanks to You i now know “user_fullname”. What else can I use and where to find it?

After logging in to frappe, from console you can have access of frappe functions

And where is console? I use self hosted frappe.

Browser console. For chrome : tools > developer tool or javascript console

Thank you a lot! I got it.

Very Cool Tip.