BiologicalRecordsCentre / PoMS

repository for Pollinator Monitoring Scheme website
0 stars 0 forks source link

Exiting data not loading in Welsh #89

Closed andrewvanbreda closed 3 years ago

andrewvanbreda commented 3 years ago

Using the Welsh variant of the Public Fit Count page, the app data is not loading in edit mode.

andrewvanbreda commented 3 years ago

@kitenetter @DavidRoy Am realising we have a serious problem here (not to do with app). Whereby my other multi-lingual projects have multi-language support, having spoke to John it, it looks like Indicia is not going to load this existing attribute data in this particular situation. I hadn't expected this, it may have also been deceptive in tests as I think data entered in Welsh would load in Welsh. If I can't resolve this today, I will see if I can make it to John's house tomorrow so I can get input from him.

andrewvanbreda commented 3 years ago

@BirenRathod @kitenetter @DavidRoy Ok spoke to John, I think (probably) there is an elegant way to correct this situation without changing Indicia.

There is an option that can be enabled public static $delegate_translation_to_hostsite = TRUE;

Once this is on, we can switch the Welsh page to use English terms, but then those are auto translated by Drupal's language system (we still leave synonyms in Warehouse for reporting)

This would also result in more of the sites language changes being picked up by Indicia.

Biren: I think the line needs adding to helper_config, but I don't seem to be able to edit this file in Git (nor is it present on FTP). Are you able add this line please? (although it may already be present and set to FALSE, in which case obviously needs changing to TRUE)

BirenRathod commented 3 years ago

@andrewvanbreda you need to remove helper_config.php file from .gitignore. only then git will accept the commit.

andrewvanbreda commented 3 years ago

@BirenRathod Thanks Biren, I will try to take that approach then

andrewvanbreda commented 3 years ago

@kitenetter @DavidRoy @BirenRathod Just to let you know, this technique looks like it will resolve this problem. I only imported one term, but can now see this being selected correctly on Welsh version of the page. Biren: Just to note I didn't need to change $delegate_translation_to_hostsite in the end, already set, so just needed to configure individual form

BirenRathod commented 3 years ago

Thanks for this info @andrewvanbreda.

andrewvanbreda commented 3 years ago

@kitenetter @DavidRoy @BirenRathod This is fixed and seen working. Problem is this means that welsh bleeds through to the 1km and Pan Trap forms. However if I switch those forms to show both English/Welsh terms and then tell Javascript to only show the terms we want then this should work. I need to do this anyway for a change for Karolis because the app has extra terms we don't want on the website, so these two problem should be solvable together. Will close this issue now as there is another issue available for that app problem.