From 0457f0296cc8f34339059c35ccc90d99386acf2d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=A5=87=E5=81=A5=E9=99=80=E8=9E=BA=E7=8E=8B?= Date: Tue, 20 Jul 2021 05:47:40 +0000 Subject: [PATCH] =?UTF-8?q?param=E5=8F=82=E6=95=B0=E5=A2=9E=E5=8A=A0Boolea?= =?UTF-8?q?n=E7=B1=BB=E5=9E=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/org/ssssssss/magicapi/model/DataType.java | 2 +- .../src/console/src/components/layout/magic-request.vue | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/magic-api/src/main/java/org/ssssssss/magicapi/model/DataType.java b/magic-api/src/main/java/org/ssssssss/magicapi/model/DataType.java index c7b43b16..8182901f 100644 --- a/magic-api/src/main/java/org/ssssssss/magicapi/model/DataType.java +++ b/magic-api/src/main/java/org/ssssssss/magicapi/model/DataType.java @@ -11,7 +11,7 @@ import static org.ssssssss.script.reflection.JavaReflection.findInvoker; public enum DataType { Object("object"), Array("array"), - Boolean("boolean"), + Boolean(false, findInvoker(Boolean.class, "valueOf", new Class[]{String.class}), false, true, "boolean"), String("string"), Integer(true, findInvoker(BigDecimal.class, "intValue"), "number"), Double(true, findInvoker(BigDecimal.class, "doubleValue"), "number"), diff --git a/magic-editor/src/console/src/components/layout/magic-request.vue b/magic-editor/src/console/src/components/layout/magic-request.vue index 9ae51dfb..70c8ed45 100644 --- a/magic-editor/src/console/src/components/layout/magic-request.vue +++ b/magic-editor/src/console/src/components/layout/magic-request.vue @@ -211,6 +211,7 @@ ], headerTypes: [ {value: 'String', text: 'String'}, + {value: 'Boolean', text: 'Boolean'}, {value: 'Integer', text: 'Integer'}, {value: 'Double', text: 'Double'}, {value: 'Long', text: 'Long'}, @@ -220,6 +221,7 @@ ], types: [ {value: 'String', text: 'String'}, + {value: 'Boolean', text: 'Boolean'}, {value: 'Integer', text: 'Integer'}, {value: 'Double', text: 'Double'}, {value: 'Long', text: 'Long'}, -- Gitee