Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix enotice when using Civi-import #25979

Merged
merged 1 commit into from
Apr 3, 2023

Conversation

eileenmcnaughton
Copy link
Contributor

Overview

Fix enotice when using Civi-import

Before

When Civi-import is enabled and the there is an attempt to save an import configuration which includes Soft Credit fields e-notices appear and the Soft credit fields are not saved to civicrm_mapping_field. This is actually a cosmetic rather than functional issue as the values in civicrm_mapping_field and not the primary information source for mappings when Civi-Import is enabled. They are synced to the primary source - which is the import_mappings key in the civicrm_user_job.metadata field. We don't necessary want to keep this sync forever - but while it exists it should work....

After

E-notices fixed, it saves

Technical Details

The underlying problem we are hacking around is that we use api syntax (with dots between entity & field names) with the import code but the QuickForm hierarchical Select element does not support the dots (which I think break it's js). On the QuickForm layer we swap them out for __ & then back again but on the angular layer we keep the dots & save the values to the more sophisticated data structure in the metadata

Comments

Not new to this PR but I do wonder if my js structure here and here is at risk of Quickform submit starting before the js has saved the job. Recommendations welcome on it

@civibot
Copy link

civibot bot commented Apr 2, 2023

(Standard links)

@civibot civibot bot added the master label Apr 2, 2023
@colemanw
Copy link
Member

colemanw commented Apr 3, 2023

Ok, looks good and is low-risk

@colemanw colemanw merged commit d9231a1 into civicrm:master Apr 3, 2023
@colemanw colemanw deleted the civi_import_notice_fix branch April 3, 2023 00:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants