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

[14.0][IMP] edi_oca: Prevent duplication of type code in exchange filenames #1032

Open
wants to merge 1 commit into
base: 14.0
Choose a base branch
from

Conversation

QuocDuong1306
Copy link

Context:

  • When a related record exists, {record_name} uses the display name of the related record to differentiate the filename appropriately.

  • When there is no related record (e.g., when creating an exchange record from storage or an endpoint), {record_name} uses the exchange record's display name.

    • In this case, if {record_name} and {type.code} are both used in the filename pattern (e.g., "{record_name}-{type.code}-{dt}"), then the filename will end up with some redundant information when the exchange type name and code have similar slugs (e.g., "Test CSV Output" and "test_csv_output").
    • To avoid that, we remove the type name from the exc record's display name when these conditions are met

Changes:

  • Remove the type name from the exc record's display name when a duplication of the type code occurs, utilizing the context to handle this adjustment.

@OCA-git-bot
Copy link
Contributor

Hi @etobella, @simahawk,
some modules you are maintaining are being modified, check this out!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants