@josephyan/qingflow-app-user-mcp 0.2.0-beta.87 → 0.2.0-beta.88
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-app-user-mcp@0.2.0-beta.
|
|
6
|
+
npm install @josephyan/qingflow-app-user-mcp@0.2.0-beta.88
|
|
7
7
|
```
|
|
8
8
|
|
|
9
9
|
Run:
|
|
10
10
|
|
|
11
11
|
```bash
|
|
12
|
-
npx -y -p @josephyan/qingflow-app-user-mcp@0.2.0-beta.
|
|
12
|
+
npx -y -p @josephyan/qingflow-app-user-mcp@0.2.0-beta.88 qingflow-app-user-mcp
|
|
13
13
|
```
|
|
14
14
|
|
|
15
15
|
Environment:
|
package/package.json
CHANGED
|
@@ -9893,6 +9893,7 @@ def _parse_field(question: dict[str, Any], *, field_id_hint: str | None = None)
|
|
|
9893
9893
|
field["visible_fields"] = visible_fields
|
|
9894
9894
|
field["field_name_show"] = bool(reference.get("fieldNameShow", True))
|
|
9895
9895
|
field["_reference_config_template"] = deepcopy(reference)
|
|
9896
|
+
field["_question_template"] = deepcopy(question)
|
|
9896
9897
|
field["_relation_config_explicit"] = False
|
|
9897
9898
|
if field_type == FieldType.department:
|
|
9898
9899
|
department_scope = _normalize_department_scope_from_question(question)
|
|
@@ -12691,7 +12692,7 @@ def _verify_package_attachment(packages: PackageTools, *, profile: str, tag_id:
|
|
|
12691
12692
|
|
|
12692
12693
|
|
|
12693
12694
|
def _field_to_question(field: dict[str, Any], *, temp_id: int) -> dict[str, Any]:
|
|
12694
|
-
|
|
12695
|
+
built_question, _next_temp_id = build_question(
|
|
12695
12696
|
{
|
|
12696
12697
|
"label": field["name"],
|
|
12697
12698
|
"type": field["type"],
|
|
@@ -12716,11 +12717,23 @@ def _field_to_question(field: dict[str, Any], *, temp_id: int) -> dict[str, Any]
|
|
|
12716
12717
|
},
|
|
12717
12718
|
temp_id,
|
|
12718
12719
|
)
|
|
12720
|
+
relation_question_template = (
|
|
12721
|
+
deepcopy(field.get("_question_template"))
|
|
12722
|
+
if field.get("type") == FieldType.relation.value and isinstance(field.get("_question_template"), dict)
|
|
12723
|
+
else None
|
|
12724
|
+
)
|
|
12725
|
+
question = relation_question_template if relation_question_template is not None else built_question
|
|
12719
12726
|
if _coerce_nonnegative_int(field.get("que_id")) is not None:
|
|
12720
12727
|
question["queId"] = field["que_id"]
|
|
12728
|
+
question.pop("queTempId", None)
|
|
12721
12729
|
else:
|
|
12730
|
+
question["queId"] = 0
|
|
12722
12731
|
question["queTempId"] = temp_id
|
|
12723
12732
|
field["que_temp_id"] = temp_id
|
|
12733
|
+
question["queType"] = built_question.get("queType", question.get("queType"))
|
|
12734
|
+
question["queTitle"] = built_question.get("queTitle", field["name"])
|
|
12735
|
+
question["required"] = built_question.get("required", bool(field.get("required", False)))
|
|
12736
|
+
question["queHint"] = built_question.get("queHint", field.get("description") or "")
|
|
12724
12737
|
if field.get("default_type") is not None:
|
|
12725
12738
|
question["queDefaultType"] = _coerce_positive_int(field.get("default_type")) or 1
|
|
12726
12739
|
if "default_value" in field:
|
|
@@ -12736,12 +12749,26 @@ def _field_to_question(field: dict[str, Any], *, temp_id: int) -> dict[str, Any]
|
|
|
12736
12749
|
preserved_reference["_targetEntityId"] = field.get("target_app_key")
|
|
12737
12750
|
question["referenceConfig"] = preserved_reference
|
|
12738
12751
|
else:
|
|
12739
|
-
reference = question.get("referenceConfig") if isinstance(question.get("referenceConfig"), dict) else {}
|
|
12752
|
+
reference = deepcopy(question.get("referenceConfig")) if isinstance(question.get("referenceConfig"), dict) else {}
|
|
12753
|
+
built_reference = (
|
|
12754
|
+
deepcopy(built_question.get("referenceConfig"))
|
|
12755
|
+
if isinstance(built_question.get("referenceConfig"), dict)
|
|
12756
|
+
else {}
|
|
12757
|
+
)
|
|
12758
|
+
for key in (
|
|
12759
|
+
"referQueId",
|
|
12760
|
+
"referQuestions",
|
|
12761
|
+
"referAuthQues",
|
|
12762
|
+
"optionalDataNum",
|
|
12763
|
+
"fieldNameShow",
|
|
12764
|
+
"_targetFieldId",
|
|
12765
|
+
):
|
|
12766
|
+
if key in built_reference:
|
|
12767
|
+
reference[key] = deepcopy(built_reference[key])
|
|
12740
12768
|
reference["referAppKey"] = field.get("target_app_key")
|
|
12741
12769
|
reference["_targetEntityId"] = field.get("target_app_key")
|
|
12742
12770
|
if field.get("target_field_que_id") is not None:
|
|
12743
12771
|
reference["referQueId"] = field.get("target_field_que_id")
|
|
12744
|
-
reference["optionalDataNum"] = _relation_mode_to_optional_data_num(field.get("relation_mode"))
|
|
12745
12772
|
question["referenceConfig"] = reference
|
|
12746
12773
|
if field.get("type") == FieldType.department.value:
|
|
12747
12774
|
scope_type, scope_payload = _serialize_department_scope_for_question(field.get("department_scope"))
|