Hi Try this according to document https://docs.erpnext.com/docs/user/manual/en/customize-erpnext/articles/fetching-data-from-a-document