From e1f0867df9e12c1c27c707fb814df809493a8aaa Mon Sep 17 00:00:00 2001 From: yunjy Date: Mon, 14 Feb 2022 10:35:06 +0900 Subject: [PATCH] =?UTF-8?q?monaco=20=EA=B4=80=EB=A0=A8=20=EC=88=98?= =?UTF-8?q?=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/eactive/httpmockserver/ApiInfo.java | 43 ++++++++-- .../templates/page/add-edit-api.html | 82 +++++++++++++++++-- 2 files changed, 114 insertions(+), 11 deletions(-) diff --git a/src/main/java/com/eactive/httpmockserver/ApiInfo.java b/src/main/java/com/eactive/httpmockserver/ApiInfo.java index 46e5474..adc8cb3 100644 --- a/src/main/java/com/eactive/httpmockserver/ApiInfo.java +++ b/src/main/java/com/eactive/httpmockserver/ApiInfo.java @@ -54,9 +54,15 @@ public class ApiInfo implements Serializable { @Positive private Integer sleepSeconds; + @Column(length = 50) + private String syntaxResponseBody1; + @Column(length = 5000) private String responseBody1; + @Column(length = 50) + private String syntaxResponseBody2; + @Column(length = 5000) private String responseBody2; @@ -156,12 +162,39 @@ public class ApiInfo implements Serializable { this.responseBody2 = responseBody2; } + public String getSyntaxResponseBody1() { + return syntaxResponseBody1; + } + + public void setSyntaxResponseBody1(String syntaxResponseBody1) { + this.syntaxResponseBody1 = syntaxResponseBody1; + } + + public String getSyntaxResponseBody2() { + return syntaxResponseBody2; + } + + public void setSyntaxResponseBody2(String syntaxResponseBody2) { + this.syntaxResponseBody2 = syntaxResponseBody2; + } + @Override public String toString() { - return "ApiInfo [id=" + id + ", apiGroupName=" + apiGroupName + ", apiName=" + apiName + ", url=" + url - + ", serviceValue=" + serviceValue + ", method=" + method + ", responseContentType=" - + responseContentType + ", responseHeaders=" + responseHeaders + ", responseStatusCode=" - + responseStatusCode + ", sleepSeconds=" + sleepSeconds + ", responseBody1=" + responseBody1 - + ", responseBody2=" + responseBody2 + "]"; + return "ApiInfo{" + + "id=" + id + + ", apiGroupName='" + apiGroupName + '\'' + + ", apiName='" + apiName + '\'' + + ", url='" + url + '\'' + + ", serviceValue='" + serviceValue + '\'' + + ", method='" + method + '\'' + + ", responseContentType='" + responseContentType + '\'' + + ", responseHeaders='" + responseHeaders + '\'' + + ", responseStatusCode=" + responseStatusCode + + ", sleepSeconds=" + sleepSeconds + + ", syntaxResponseBody1='" + syntaxResponseBody1 + '\'' + + ", responseBody1='" + responseBody1 + '\'' + + ", syntaxResponseBody2='" + syntaxResponseBody2 + '\'' + + ", responseBody2='" + responseBody2 + '\'' + + '}'; } } diff --git a/src/main/resources/templates/page/add-edit-api.html b/src/main/resources/templates/page/add-edit-api.html index 9977941..b3c002d 100644 --- a/src/main/resources/templates/page/add-edit-api.html +++ b/src/main/resources/templates/page/add-edit-api.html @@ -27,7 +27,7 @@
-
@@ -153,13 +153,40 @@
+
+
+
+ +
+ +
+
+
+
+
+ +
+ +
+
+
+
- +
+ +
@@ -167,8 +194,9 @@
- + + +
@@ -186,8 +214,50 @@ + + + + + + + +