Loading...
Loading...
Use when modifying EXISTING Datex Studio reports on a branch. Handles label/style changes, field rearrangement, adding/removing columns, datasource modifications, and adding new data sections. Trigger for: "edit a report", "modify a report", "change the label", "add a column", "update the report on branch X", "fix the report layout". For creating NEW reports from scratch, use `report-creator`.
npx skill4agent add datex/skills report-editordxssetmoveremovebatchtable add-columndataset add-fielddatasource-creatorschema-explorerreport-editor (this skill)
|
+-- Phase 1: Download & Inspect
| +-- Select branch + find report (branch-setup.md)
| +-- Download report folder (RDLX-JSON + datasources + manifest)
| +-- Inspect layout + DataSets + datasource fields
| +-- Output: report folder + structural understanding
|
+-- Phase 2: Triage -- Determine Change Depth
| +-- Classify user's request into category 1-5
| +-- Check DataSet fields vs datasource fields
| +-- Output: modification plan with category + steps
|
+-- Phase 3: Modify (conditional paths by category)
| +-- Cat 1-2: Layout-only --> set/move/remove/batch on folder/report.rdlx-json
| +-- Cat 3: Add from existing DataSet field --> table add-column
| +-- Cat 4: Datasource gap --> datasource-creator --> datasource add --> DataSet --> layout
| +-- Cat 5: New section --> schema-explorer --> datasource-creator --> datasource add --> DataSet --> layout
|
+-- Phase 4: Deploy & Verify (deploy-patterns.md)
| +-- assemble folder --> wrapper JSON
| +-- upload wrapper JSONdxs report list --branch <branch_id># Auto-names folder from reference name
dxs report download --branch <branch_id> --reference-name <reference_name>
# Or specify folder path explicitly
dxs report download <folder_path> --branch <branch_id> --reference-name <reference_name>report.rdlx-jsonmanifest.jsonds_*.jsondxs report datasource list <folder>/dxs report inspect <folder>/report.rdlx-json--bboxdxs report preview <file.rdlx-json> --bbox ElementName:red --bbox AnotherElement:blue -o /tmp/inspect.svgdxs report inspect <file.rdlx-json>dxs report datasource list <folder>/# For standalone datasources
dxs report datasource-fields <datasource_ref> --branch <branch_id>
# For owned datasources
dxs report datasource-fields <datasource_ref> --branch <branch_id> --report <report_ref>in_paramsdxs report listreport-creator| Category | Examples | What's Needed | Dependency Skills |
|---|---|---|---|
| 1. Label/Style | "Change 'SHIPPER' to 'FROM'", "Make header blue", "Increase font size" | | None |
| 2. Rearrangement | "Swap columns 2 and 3", "Move address block down", "Remove the footer" | | None |
| 3. Add column (field in DataSet) | "Add the Status column" where Status IS in the DataSet | | None |
| 4a. Add field (in datasource, missing from DataSet) | "Add Material Description" where the field IS in the datasource output but NOT in the DataSet | | None |
| 4b. Add field (datasource gap) | "Add Material Description" where the field is NOT in the datasource | Datasource regeneration + | |
| 5. New data section | "Add a line items table" where no suitable datasource exists | Full: | |
User request
|
+-- Does the change involve data fields?
| +-- NO --> Is it positional/structural (move, swap, remove)?
| | +-- YES --> Category 2 (rearrangement)
| | +-- NO --> Category 1 (label/style)
| | --> Proceed to Phase 3
| |
| +-- YES --> Does the needed field exist in a report DataSet?
| +-- YES --> Category 3 (add column/element from existing DataSet field)
| | --> Proceed to Phase 3
| |
| +-- NO --> Is the field in the datasource output? (from datasource-fields)
| +-- YES --> Category 4a (field in datasource, missing from DataSet)
| | --> Add to DataSet, then layout
| |
| +-- NO --> Is the field reachable from the datasource's entity?
| | (just missing from $select/$expand)
| |
| +-- YES --> Category 4b (datasource needs regeneration)
| | --> Modify datasource --> re-upsert --> DataSet --> layout
| |
| +-- NO --> Category 5 (entirely new data requirement)
| --> schema-explorer --> datasource-creator --> DataSet --> layout### Modification Plan
**Requested change:** [user's request]
**Category:** [1-5] -- [description]
**Steps:**
1. [what will happen]
2. [what will happen]
...
**Impact:** [layout-only / DataSet change / datasource modification / new datasource]
Proceed?# Change a label
dxs report set <file> ElementName --value "New Label Text"
# Change styling
dxs report set <file> ElementName --font-size 12pt --color Navy --font-weight Bold
# Move an element
dxs report move <file> ElementName --left 1in --top 2in
# Resize an element
dxs report set <file> ElementName --width 3in --height 1in
# Remove an element
dxs report remove <file> ElementName
# Batch operations (for multiple changes)
cat > /tmp/ops.json << 'OPEOF'
[
{"action": "set", "name": "Title", "value": "New Title", "font-size": "18pt"},
{"action": "set", "name": "SubTitle", "color": "DimGray"},
{"action": "move", "name": "AddressBlock", "left": "0in", "top": "1.5in"},
{"action": "remove", "name": "OldElement"}
]
OPEOF
dxs report batch <file> --ops-file /tmp/ops.jsonStartPointEndPointstart-xstart-yend-xend-ylefttopwidthheightmovesetdxs report table add-column <file> --table <TablixName> --shrink \
--header-cell "New Header" \
--detail-cell '=Fields!ExistingField.Value' \
--header-style 'font-family:Arial;font-size:10pt;font-weight:Bold;border-bottom-width:1.5pt;border-bottom-style:Solid;border-bottom-color:#5B08B2;padding:2pt;vertical-align:Bottom' \
--detail-style 'font-family:Arial;font-size:10pt;padding:2pt;vertical-align:Middle;border-bottom-width:0.25pt;border-bottom-style:Solid;border-bottom-color:LightGray'--shrinkdxs report batchadddxs report dataset add-field <file> --dataset <DataSetName> --field "New.Field.Path"[Date|YYYY-MM-DDTHH:mm:ss.fffffff].data.json$select$expanddxs datasource get <ref> --branch <id>Material/Description$expanddatasource-creatordxs datasource upsertdxs report dataset add-fieldds_*.jsondatasource-creatordxs report datasource remove <folder> <alias>dxs report datasource add <folder> --owned <new_ds.json>:<alias>dxs report dataset add-fielddxs datasource generate-flowdxs report datasource remove/addrequirements-gatheringschema-explorerdatasource-creatordxs report datasource add <folder> --owned <file>:<alias>dxs report batchdxs report dataset add <file> --name ds_new_section \
--field Id --field LookupCode --field Status \
--field "Account.Name" \
--field "OrderDate[Date|YYYY-MM-DDTHH:mm:ss.fffffff]"cat > /tmp/new-section-ops.json << 'OPEOF'
[
{"action": "add", "type": "rectangle", "name": "NewSectionBox",
"left": "0in", "top": "4in", "width": "7.5in", "height": "2in"},
{"action": "add", "type": "textbox", "name": "NewSectionTitle",
"parent": "NewSectionBox", "left": "0in", "top": "0in",
"width": "7.5in", "height": "0.3in",
"value": "Section Title", "font-size": "14pt", "color": "DimGray"}
]
OPEOF
dxs report batch <file> --ops-file /tmp/new-section-ops.jsondxs report add tablixsetmoveremove# Assemble folder into wrapper JSON
dxs report assemble <folder>/ -o <reference_name>.json
# Upload wrapper to branch
dxs report upload <reference_name>.json --branch <branch_id>dxs report datasource add/removedxs report get <reference_name> --branch <branch_id>in_params| Mistake | Fix |
|---|---|
| Modifying report without downloading first | Always |
| Adding a field to DataSet but not updating sample data | Studio preview shows blank for the new field -- update |
| Assuming the datasource has the field without checking | Always run |
| Changing a field expression but not the DataSet field | If you rename a DataField path, the DataSet field must also be updated to match |
| Removing a datasource field that is still referenced | Check all expressions in the report for |
| Adding collection-path fields as flat DataSet fields | Collection navigation properties silently resolve to blank in single-result DataSets -- use a flow datasource to flatten, or create child datasets with |