Needs review
Project:
CRM Core
Version:
8.x-3.x-dev
Component:
CRM Core Contact
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
22 Apr 2016 at 21:45 UTC
Updated:
25 Jan 2020 at 10:14 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
dpiPatch is required for https://github.com/dpi/courier_crm_core_contact
Comment #3
berdirSure about this? These are the only possible primary fields?
The documentation doesn't seem to indicate this, a sequence for any list of field seems more likely?
Also, given that we plan to add multi-value fields with a type for email and phone, I'm not sure if this API will still be required then?
If null is a valid return value, shouldn't we check that? this will throw a veird exception otherwise.
inheritdoc can only be used if it's the only thing, if you extend it, you have to copy the parent implementation.
Looks like there are supposed to be more of those primary fields, it's just commented out at the moment.
Comment #4
dpiI discussed the future of contacts and contact types with miro_dietiker over IRC this morning and I understand this patch is likely obsolete since the model is changing.
email, address, primary they are the primary fields listed in the UI, and there's an array on the form which has those fields. Again I understand the existing implementation was probably placeholder. If the model allowed more primary fields then the schema will be very different.
I dont think what I have written will stick, but it gets the existing code running.
Comment #5
grahlProbably irrelevant, need to check.
Comment #6
grahl- Primary fields schema potentially still relevant but leaving out to leave the option of adding additional fields in custom code.
- ConfigEntityBundleBase already provides ConfigEntityInterface, not needed
- Primary Fields functions already present, however the function does two things: get the field name and field value, let's take that apart.
And let's add those functions to the interface.