Data Entity Refresh (Including Composite Entity) After Customizations - arp6333/xplusplus GitHub Wiki

Updating Entities

  1. Both the entity extension and an extension of the staging table must be added to the project

image

  1. Any fields added to the entity must be manually added to the staging table, it cannot be auto generated like with a custom new entity

  2. Perform a DB sync and build once both entity and staging table are updated

  3. You can select in SQL to verify if the fields have been added to the staging table successfully (not to verify data yet, just that the fields were added correctly)

image
  1. Navigate to 'System Administration -> Data management'
image
  1. Open 'Framework parameters'
image
  1. Click 'Entity settings -> Refresh entity list'
image

Note: if you make any code changes to an entity's code (not just the design), you MUST refresh the entity list to see the changes every time.

  1. This will run in batch, you can see the progress in the Batch jobs list ('System administration -> Inquiries -> Batch jobs')
image
image
  1. Once that completes execution, return back to 'System Administration -> Data management' and click 'Data entities'
image
  1. Search for your target entity

image


If this is a composite entity, search for the parent entity, NOT the child entity that was modified

ex. CustomerPaymentJournalLineEntity has parent CustomerPaymentJournalEntity, so we want to use CustomerPaymentJournalEntity and not CustomerPaymentJournalLineEntity

image

i. Then select 'Child entities' from the top bar

image

ii. It can be a little buggy and not populate on first click, if so go back and click 'Child entities' again until it populates

image

iii. Select the first child entity, even if it was not the one that was modified and continue with the rest of the steps

  1. Click 'Modify target mapping' from the top bar
image
  1. Click the 'Generate mapping' button, and if it prompts 'Do you want to generate the mapping from scratch?' click 'Yes'
image
  1. Switch to the 'Mapping visualization' tab and verify any new fields are both there, and have a line connecting them from Staging to Target
image
  1. Click the 'x' to close that form and return to the 'Target entities' form. Click 'Validate' to verify the entity is valid with an inline message
image

You can also click 'Target fields' to verify any new fields have successfully been added, as they will show up on this grid if successful

image
image

If composite entity, repeat steps 11-14 for all child entities


  1. For any jobs that use this entity, the entity can be removed and readded to the job to refresh the field list
image
image

You can use '/data' or '/data/' in the URL to view the data in the entity quickly from the front-end. The entity name IS case sensitive!

After the Data Entity name in the url address place a ? then you can start adding the parameters the & will let you add multiple parameters.

Example: (don't worry about spacing and non-URL characters as they will be fixed once you hit enter) /data/SalesInvoiceLines?cross-company=true&$filter=InvoiceId eq 'INV000000001'

Some query options:

  • $filter
  • $count
  • $orderby
  • $skip
  • $top
  • $select

Filter options: $filter:

  • Equals (eq)
  • Not equals (ne)
  • Greater than (gt)
  • Greater than or equal (ge)
  • Less than (lt)
  • Less than or equal (le)
  • And
  • Or
  • Not

https://docs.microsoft.com/en-us/dynamics365/fin-ops-core/dev-itpro/data-entities/odata

⚠️ **GitHub.com Fallback** ⚠️