|
@@ -78,11 +78,11 @@ public class MockController {
|
|
|
* 构建响应体
|
|
|
*
|
|
|
* @author WANGWEI
|
|
|
- * @param id
|
|
|
+ * @param templateId
|
|
|
* @param request
|
|
|
* @return
|
|
|
*/
|
|
|
- private String buildRespBody(String id, HttpServletRequest request) {
|
|
|
+ private String buildRespBody(String templateId, HttpServletRequest request) {
|
|
|
String requestURI = request.getRequestURI();
|
|
|
String uri = requestURI.substring("mock".length() + 2);
|
|
|
String[] pathValues = uri.split("/");
|
|
@@ -90,7 +90,7 @@ public class MockController {
|
|
|
data.put("pathValues", pathValues);
|
|
|
String template = null;
|
|
|
try {
|
|
|
- template = ResourceLoader.getResource("mock/" + id);
|
|
|
+ template = ResourceLoader.getResource("mock/" + templateId);
|
|
|
} catch (Exception e) {
|
|
|
throw new StatusException("XXX", "未定义模板");
|
|
|
}
|