opc-cpvp / OPC.PowerApps.PCFControls

MIT License
6 stars 0 forks source link

Fields not storing data #279

Closed r4bbiz closed 2 years ago

r4bbiz commented 3 years ago

Hey there,

first of all - great tool, exactly what I was looking for.

The problem is though, that the field on the form, where I want to add the tags from my tags entity, is not storing the tags, it's empty after saving and refreshing the dataset. Let me explain:

Entity 1: Product Entity 2: new_testtagtable (Custom) Relationship Name: new_ProductTestTagTable_Relationship (N:N) Relationship Entity Name: new_producttesttagtablerelationship

image

On the Product from, I got the custom Product field new_testtags3, where I want to add the tags, which are stored in the entity new_testtagtable. Attached my configuration. What am I doing wrong?

image

Thanks a lot in advance and best regards!

joshcampbell191 commented 3 years ago

@r4bbiz The configuration for the PCF appears to be correct.

Can you please ensure that the plugin is also registered and that the steps are enabled as per the following: image

r4bbiz commented 3 years ago

Turns out, although the step was displayed as "enabled", activating it again helped - the tags get now correctly saved. Thanks for the help!

r4bbiz commented 3 years ago

Hey Josh,

false alarm - it's still not working properly. I figured out the following: On the form for e. g. Product "ArmBand 100_", it displays the tag "Handschuhe". Altough when using Advanced Find, the field still stores another value "test" (I guess it was the first tag I created? I don't rememeber tbh.):

image image

For other Products, the tags get displayed on the form properly like for "ArmBand 100_" with "Handschuhe" but no value gets stored at all in the field when checking again via Advanced Find.

Also, the plugin seems to be okay:

image

Do you have any idea what's wrong here?

joshcampbell191 commented 3 years ago

Please note that the backing field (test tag 3) is only used to create the initial relationships (between the 2 entities) on CREATE. The field is no longer used to store data moving forward. If you do not like this behaviour, I recommend that you use the grid PCF component instead. Let me know if you have any additional questions.

r4bbiz commented 3 years ago

Ah, I see, thanks for the clarification. Sorry to bother you once more but as I see it, there is no option for me to choose the grid component. I imported the whole solution unmanaged but for test tag 3 I can only choose the tag picker in the control dialog - how to choose the grid component?

joshcampbell191 commented 3 years ago

The grid PCF component can only be applied to grids. Simply add a grid for the N:N relationship to your form and select the grid PCF. Note that it can't be used on CREATE (as opposed to the text field version of that the PCF) as it requires the entity to exist.

r4bbiz commented 3 years ago

Thanks for the clarification, Josh. As my Tags entity already exists by the time an user adds tags to a product e. g., I guess that works for me. Thanks a lot for your help!