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

Add update to commit response #991

Merged
merged 21 commits into from
Dec 23, 2024
Merged

Conversation

wlorenzetti
Copy link
Member

@wlorenzetti wlorenzetti commented Dec 12, 2024

Add 'update' section to response of /vector/api/commit/:

Before:

{
    "result": true,
    "response": {
        "new": [],
        "new_lockids": [],
        "relations": {
            "maintenance_works_f8cbe34a_eebe_4cd1_9c78_5d420ab0af63": {
                "new": [],
                "new_lockids": [],
            }
        },
    }
}

After:

{
    "result": true,
    "response": {
        "new": [],
        "new_lockids": [],
        "relations": {
            "maintenance_works_f8cbe34a_eebe_4cd1_9c78_5d420ab0af63": {
                "new": [],
                "new_lockids": [],
                "update": [
                    {
                        "id": "65",
                        "properties": {
                            "cost": "1002",
                            "date": "2024-04-18",
                            "fid": 65,
                            "form": "http://localhost:8006/it/me/qdjango/1628/1707379097739.jpeg",
                            "id_building": 63,
                            "maintenance": "Plant replacement",
                            "outcome": null,
                            "responsible": null,
                            "test": null,
                            "validation": "0",
                            "value": null
                        }
                    }
                ]
            }
        },
        "update": [
            {
                "id": "63",
                "properties": {
                    "address": "A108",
                    "architectural_barriers": "Not checked",
                    "attachment": "0",
                    "date_barriers": "2024-12-12",
                    "date_exits": null,
                    "date_fire": null,
                    "description": "<p>2024-12-12T15:52:32.237-tesst definitivo</p>",
                    "fid": 63,
                    "fire_system": "Not checked",
                    "form": null,
                    "high": 12,
                    "link": null,
                    "name": "tesst definitivo",
                    "photo": null,
                    "safety_exits": "Not checked",
                    "subtype": "{1}",
                    "surface": 348.46,
                    "type": "Residential",
                    "user": "",
                    "volume": null,
                    "year": 2016,
                    "zone": "B"
                }
            }
        ]
    }
}

@wlorenzetti wlorenzetti added feature New feature or request refactoring Anything which could result in a API change labels Dec 12, 2024
@wlorenzetti wlorenzetti added this to the v3.9 milestone Dec 12, 2024
@wlorenzetti wlorenzetti self-assigned this Dec 12, 2024
volterra79 added a commit to g3w-suite/g3w-client-plugin-editing that referenced this pull request Dec 12, 2024
volterra79 added a commit to g3w-suite/g3w-client-plugin-editing that referenced this pull request Dec 16, 2024
* ✨ Start to develop edit multi relation feature from multi parent feature layer

* ✨ Start to develop edit multi relation feature from multi parent feature layer

* ✨ Add reset method step

* Clean code - spaces

* 🐛 Add user message to copy paste from other layer

* Clean code - spaces

* Use steps message to address user to follow right flow

* ♻️ Use class instead base or inherit

* Remove setModal false

* ✨ Show modal select window to choose whild features of select relation you want edit

* 🐛 get relation only editable, not also visible

* 🌐translation

* 💄 run Once

* Remove copy feature form external layer tool. Unused

* ♻️ Handle start toolbox session uniform

* Comment getEditingMediaFields to copy also attach (media, pdf,etcc.) of clone of feature

* 🐛 In case of no relations, show user message and stop

* ✨ Referred to  g3w-suite/g3w-admin#991

* 🐛 Unlock relations layers in case of editing relation by parent layer

* Remove return Promise.reject because cause a vue error

* Remove unusefull new
@wlorenzetti wlorenzetti marked this pull request as ready for review December 23, 2024 15:00
@wlorenzetti wlorenzetti merged commit 6647b74 into dev Dec 23, 2024
4 checks passed
@wlorenzetti wlorenzetti deleted the add_update_to_commit_response branch December 23, 2024 15:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request refactoring Anything which could result in a API change
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants