Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
'Job title', 'Industries worked in', and 'Companies worked for' needs to be migrated to core fields.
This should put the fields in a group on the main edit screen, removing
else if ($form['#user_category'] == 'Work') {
// TODO: Remove this custom code in favour of field groups.
// Get the current company or organization(s) field
...
from drupalorg_form_alter()
and
// Hide revision fields on node add form.
// @TODO Should be removed in D8 #308820.
if (!isset($form['#node']->nid)) {
$form['revision_information']['#access'] = FALSE;
}
from drupalorg_form_node_form_alter()
Other fields in the Work category are covered by #968994: Multiple Values for listings of current companies and organizations and #2322257: Remove 'Company or organization size' profile field?.
Deployment
- Deploy code.
- At /admin/config/people/profile, hide profile_job, profile_industries, profile_companies. (clears all caches)
- At /admin/config/people/accounts/fields/field_current_company_org/widget-type, set to hidden.
- At /admin/config/people/accounts/display, set Current company or organization(s) to hidden.
- At /admin/structure/features, confirm things are at default.
- Run updatedb.
Comment | File | Size | Author |
---|---|---|---|
#4 | Screen Shot 2014-08-19 at 5.24.16 PM.png | 101.28 KB | drumm |
Comments
Comment #1
tvn CreditAttribution: tvn commentedI think Current companies and Job title fields need to be included in Bakery sync. While we won't sync all the fields, we should sync a minimal amount to give an idea about the person and make user profiles on sub sites not as empty.
Comment #2
drummI added #2323615: Ensure newly-migrated profile fields get migrated all the way to CiviCRM to get these synced over.
Comment #3
drummComment #4
drummI'm implementing this as a field collection for all organizations, since titles are per-organization. Here is what the edit form will look like:
Comment #5
tvn CreditAttribution: tvn commentedField collection is a great idea. I think that labels are a bit vague on the edit form.
I'd suggest "Organization" instead of "Name" and "Job Title" instead of "Title".
"Current organization" or "Current job" instead of "I am currently here".
And a help text above:
"List companies or institutions you have worked for or are working for now."
Comment #6
drummI've gotten all those changes ready, except the help text wants to go between the organization fields and the "Add another item" button.
Comment #7
tvn CreditAttribution: tvn commentedI guess that's fine for now.
Comment #9
drummComment #10
drummComment #11
drummNow deployed.
Comment #14
LewisNymanI have created a bug report which I think is related to the changed in this issue: #2380561: Organisation logo display on user profile should have alt text