Initiate action should/could be specified in URL
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Anfängerfreundlichkeit
- 35/100
Rechercherichtung
Beginne damit, den Client-Ablauf von GET /api/travel-request/ bis zur POST-URL nachzuverfolgen, und untersuche anschließend, wie die initiate-Aktion beim Erstellen dieser URL behandelt wird. Bestätige das gewünschte Verhalten anhand der Issue-Diskussion, bevor du etwas änderst. Erledigt bedeutet, dass POST-Anfragen konsistent den action slug enthalten, einschließlich der Initiierung, und dass das resultierende action-Formular erfolgreich übermittelt wird.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
The way the client is designed, it gets the workflow definition from GET /api/travel-request/. If there's an id property, it renders the data and the events. If there's multiple state.actions, it renders action buttons. If there's only 1 state.actions, it renders the form for it. If there's more than 1 state.actions, it waits until you select one of the action buttons, and renders that form. On submission, the form posts to POST /api/travel-request/<case-id?>/<action-slug>?token=xx.
At the moment, this fails on the initiate action, I think because by design we expected clients to not include the action on the initiate POST. But it's actually pretty simple to do that since (a) we're providing the name of the action in the response to their GET request, and (b) they're already using part of that response for their POST request (the template).
My guess is you probably added extra logic to identify what the default action was. Perhaps this isn't necessary, and we can just expect clients to include the action name in every POST request.
Thoughts @mjumbewu ?
- Vorherrschende Sprache
- Python
- Sterne
- 22
- Forks
- 5
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Beitragsleitfaden
Für dieses Repository ist kein Beitragsleitfaden indexiert
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus CodeForPhilly/stately
-
Related app: Docassemble Offen
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 15/100
CodeForPhilly/stately#60 ·
-
Investigate using BPML Offen
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 20/100
CodeForPhilly/stately#59 · 1 Kommentar ·
-
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 28/100
CodeForPhilly/stately#58 · 1 Kommentar ·
-
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 25/100
CodeForPhilly/stately#57 ·
-
Search case list Offenapi ui
Schwierigkeit 3/5 1-2 Tage Anfängerfreundlichkeit 35/100
CodeForPhilly/stately#55 ·
Alle Issues in CodeForPhilly/stately
Ähnliche Issues
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 86/100
browser-use/browser-use#5905 ·
-
type: enhancement
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 68/100
ynput/ayon-python-api#363 ·
-
bug needs triage
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 88/100
modelscope/FunASR#3728 ·
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 88/100
open-compass/opencompass#2655 ·