Notifications
Announcements
No record found.
Hi there,
I have a field called legal entity in my table, in this field I want my legal entity name for every record created.
ThankYou.
Hi Ganesh,,
You can set the legal entity name in the insert method of your table.
public void insert() { this.LegalEntityName = CompanyInfo::find().Name; super(); }
Don't duplicate the information. Join your table with CompanyInfo to get the name.
Hi Martin
could you please tell me how to do it and where? at table level?
Hi Gunjan Bhattachayya
This is working but it's reflecting name but I want legal entity like ex: USMF
I got it by using this
this.LegalEntity = CompanyInfo::find().DataArea; super();
Thank you.
What is the point of this code? If the table isn't shared, the value is already stored by the system in DataAreaId, therefore you don't need to waste storage for another field, you don't need any code and you don't have to prevent set-based operations by overriding insert().
If the table is shared, isn't it a design flaw?
Hi goshoom
They want to show legal entity in form but, not in the grid, they want it in the table as a field if they want to show it in the form they can add it from listed fields while clicking on insert columns in the form..
Don't let end-users be technical architects; they're usually not trained in things like the design of relation databases. It's our role to do this work.
Let users define business requirements and then design a technical solution that meets both business requirements and non-functional requirements (e.g. regarding maintainablity, performance, data consistency and so on).
It seem that they believe that a field must be added to the particular table to be addable via personalization, which isn't true. It's also not true that all fields of a table can automatically be added that way. Therefore their technical design seems to be based on wrong assumptions.
Also, could you please respond to my previous reply? What the point ot adding DataAreaId by custom code instead of using rhe standard field? It seems like spending money to make the system slower and achieving nothing. But maybe there is a reason - that's why I asked.
Under review
Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.
As AI tools become more common, we’re introducing a Responsible AI Use…
We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…
These are the community rock stars!
Stay up to date on forum activity by subscribing.
Martin Dráb 551 Most Valuable Professional
André Arnaud de Cal... 450 Super User 2025 Season 2
BillurSamdancioglu 278 Most Valuable Professional