Commit c1780ef
Issue #1028: UI creates attribute+association in one call; add axios timeout
Frontend (mdr-frontend):
- ModelExplorer.handleCreateAttribute now passes EntityId to createAttribute when
adding under an Entity, and no longer makes the separate createEntityAttributeAssociation
request — the API creates both atomically (see attribute_service). Removes the two-request
orphan window. (The separate-association dialog flow for EXISTING attributes is unchanged.)
- api.ts: add a 30s request timeout so a stalled request fails fast/clearly instead of
hanging into the ambiguous 'Network error' that triggered the orphan bug.
- AttributeParams gains optional EntityId.
Backend:
- create_attribute sets the association's ExtendedByDataModelId for extension models
(OrgLIF/PartnerLIF), mirroring the frontend template, so the single atomic call is correct
for extension data models too.
Type-checks clean (tsc). Refs #1028.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>1 parent 53b788e commit c1780ef
4 files changed
Lines changed: 20 additions & 10 deletions
File tree
- components/lif/mdr_services
- frontends/mdr-frontend/src
- components/ModelExplorer
- services
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
110 | 110 | | |
111 | 111 | | |
112 | 112 | | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
113 | 116 | | |
114 | 117 | | |
115 | 118 | | |
116 | 119 | | |
117 | 120 | | |
118 | 121 | | |
| 122 | + | |
119 | 123 | | |
120 | 124 | | |
121 | 125 | | |
| |||
Lines changed: 9 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
407 | 407 | | |
408 | 408 | | |
409 | 409 | | |
410 | | - | |
411 | 410 | | |
412 | 411 | | |
413 | 412 | | |
414 | | - | |
| 413 | + | |
| 414 | + | |
| 415 | + | |
| 416 | + | |
| 417 | + | |
| 418 | + | |
| 419 | + | |
| 420 | + | |
| 421 | + | |
415 | 422 | | |
416 | 423 | | |
417 | | - | |
418 | | - | |
419 | | - | |
420 | | - | |
421 | | - | |
422 | | - | |
423 | | - | |
424 | | - | |
425 | 424 | | |
426 | 425 | | |
427 | 426 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
12 | 12 | | |
13 | 13 | | |
14 | 14 | | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
15 | 19 | | |
16 | 20 | | |
17 | 21 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
28 | 31 | | |
29 | 32 | | |
30 | 33 | | |
| |||
0 commit comments