Hajk icon indicating copy to clipboard operation
Hajk copied to clipboard

Can't save text field in Edit

Open jacobwod opened this issue 4 years ago • 7 comments

This needs more investigation, but to reproduce, try:

  1. Setup a new WFS-T layer. Mine looks like this: Skärmavbild 2022-01-26 kl  10 37 04

  2. Add it to a map.

  3. Try adding a point. First without supplying any data in the text field.

  4. This saves the geometry correctly in the database. Skärmavbild 2022-01-26 kl  10 38 10

  5. No try adding another geometry with a text value this time. It will fail, something like this: Skärmavbild 2022-01-26 kl  10 35 18

  6. You can also get the same error if you try to edit the previously added geometry. In addition, you will get Object [object] as the text field's value: Skärmavbild 2022-01-26 kl  10 39 30

jacobwod avatar Jan 26 '22 09:01 jacobwod

Hi, can you send the config you used for the layer and the plugin? I've still not been able to reproduce this so difficult for me to debug/fix. Am I correct that you use QGIS Server?

hitomin21 avatar Feb 01 '22 09:02 hitomin21

@hitomin21 we now have a public test instance of Hajk at https://hajk.orebro.se/ so that you can try and recreate the issue Jacob described. The edit tool is enabled and configured to a test table in our oracle database. If something doesn´t work or if you would like to see some other setup to test against feel free to contact me.

WCarlsson avatar Feb 16 '22 15:02 WCarlsson

I can confirm that the test instance works well and can easily be used as a remote backend even when working locally. Just change you appConfig.json to include this:

  "mapserviceBase": " https://hajk.orebro.se/api/v1/",
  "defaultMap": "map_1",

Well done @WCarlsson!

jacobwod avatar Feb 17 '22 06:02 jacobwod

I can confirm that the errors remain in the latest develop. Skärmavbild 2022-02-17 kl  07 32 34

jacobwod avatar Feb 17 '22 06:02 jacobwod

Thanks, I will take a look

hitomin21 avatar Feb 17 '22 13:02 hitomin21

Hi, We are trying to solve this bug #987 but we are wondering If It has something to do with resetView(new-client, plugins, edit.js)? image Any tips or recommendations? Thank you :)

Anyou22 avatar Sep 30 '22 12:09 Anyou22

I'm not sure about it, but you can test it easily by e.g. commenting out the part of code (line 12?) that you suspect affects this and see if it really does. 😄

jacobwod avatar Oct 03 '22 11:10 jacobwod