@josephyan/qingflow-cli 1.1.10 → 1.1.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md
CHANGED
|
@@ -3,13 +3,13 @@
|
|
|
3
3
|
Install:
|
|
4
4
|
|
|
5
5
|
```bash
|
|
6
|
-
npm install @josephyan/qingflow-cli@1.1.
|
|
6
|
+
npm install @josephyan/qingflow-cli@1.1.12
|
|
7
7
|
```
|
|
8
8
|
|
|
9
9
|
Run:
|
|
10
10
|
|
|
11
11
|
```bash
|
|
12
|
-
npx -y -p @josephyan/qingflow-cli@1.1.
|
|
12
|
+
npx -y -p @josephyan/qingflow-cli@1.1.12 qingflow
|
|
13
13
|
```
|
|
14
14
|
|
|
15
15
|
Environment:
|
package/package.json
CHANGED
package/pyproject.toml
CHANGED
|
@@ -2137,7 +2137,7 @@ class PortalComponentPositionPatch(StrictModel):
|
|
|
2137
2137
|
|
|
2138
2138
|
|
|
2139
2139
|
class PortalChartRefPatch(StrictModel):
|
|
2140
|
-
app_key: str
|
|
2140
|
+
app_key: str | None = None
|
|
2141
2141
|
chart_id: str | None = None
|
|
2142
2142
|
chart_name: str | None = None
|
|
2143
2143
|
|
|
@@ -2145,6 +2145,8 @@ class PortalChartRefPatch(StrictModel):
|
|
|
2145
2145
|
def validate_target(self) -> "PortalChartRefPatch":
|
|
2146
2146
|
if not (self.chart_id or self.chart_name):
|
|
2147
2147
|
raise ValueError("chart_ref requires chart_id or chart_name")
|
|
2148
|
+
if self.chart_name and not self.chart_id and not self.app_key:
|
|
2149
|
+
raise ValueError("chart_ref.app_key is required when resolving by chart_name")
|
|
2148
2150
|
return self
|
|
2149
2151
|
|
|
2150
2152
|
|
|
@@ -17345,6 +17345,8 @@ def _resolve_chart_reference(*, charts: QingbiReportTools, profile: str, ref: An
|
|
|
17345
17345
|
app_key = str(getattr(ref, "app_key", "") or "").strip()
|
|
17346
17346
|
chart_id = str(getattr(ref, "chart_id", "") or "").strip()
|
|
17347
17347
|
chart_name = str(getattr(ref, "chart_name", "") or "").strip()
|
|
17348
|
+
if chart_id and not app_key:
|
|
17349
|
+
return {"chart_id": chart_id, "chart_name": chart_name, "app_key": None, "chart_type": ""}
|
|
17348
17350
|
items = charts.qingbi_report_list(profile=profile, app_key=app_key).get("items") or []
|
|
17349
17351
|
if chart_id:
|
|
17350
17352
|
for item in items:
|
|
@@ -898,7 +898,11 @@ def _handle_portal_apply(args: argparse.Namespace, context: CliContext) -> dict:
|
|
|
898
898
|
fix_hint="Use `--dash-key` for an existing portal. For create mode, pass `--package-id --dash-name`.",
|
|
899
899
|
)
|
|
900
900
|
sections = [] if not args.sections_file else require_list_arg(args.sections_file, option_name="--sections-file")
|
|
901
|
-
patch_sections =
|
|
901
|
+
patch_sections = (
|
|
902
|
+
load_list_arg(args.patch_sections_file, option_name="--patch-sections-file")
|
|
903
|
+
if args.patch_sections_file
|
|
904
|
+
else None
|
|
905
|
+
)
|
|
902
906
|
return context.builder.portal_apply(
|
|
903
907
|
profile=args.profile,
|
|
904
908
|
dash_key=args.dash_key,
|