|
|
@@ -0,0 +1,34 @@
|
|
|
+package org.dromara.server.consume.controller.v1;
|
|
|
+
|
|
|
+import lombok.RequiredArgsConstructor;
|
|
|
+import lombok.extern.slf4j.Slf4j;
|
|
|
+import org.dromara.common.core.api.ReturnResult;
|
|
|
+import org.dromara.server.consume.domain.XfTermEvents;
|
|
|
+import org.springframework.http.HttpStatus;
|
|
|
+import org.springframework.http.ResponseEntity;
|
|
|
+import org.springframework.util.MultiValueMap;
|
|
|
+import org.springframework.web.bind.annotation.PostMapping;
|
|
|
+import org.springframework.web.bind.annotation.RequestBody;
|
|
|
+import org.springframework.web.bind.annotation.RequestMapping;
|
|
|
+import org.springframework.web.bind.annotation.RestController;
|
|
|
+
|
|
|
+/**
|
|
|
+ * 消费机事件控制器
|
|
|
+ * <p>
|
|
|
+ *
|
|
|
+ * @author luoyibo
|
|
|
+ * @date 2025-06-27
|
|
|
+ * @since JDK17
|
|
|
+ */
|
|
|
+@Slf4j
|
|
|
+@RestController
|
|
|
+@RequiredArgsConstructor
|
|
|
+@RequestMapping(path = {"/v1/xfTermEvent"})
|
|
|
+public class TermEventsController {
|
|
|
+ @PostMapping({"/uploadRecord"})
|
|
|
+ public Object uploadRecord(@RequestBody XfTermEvents termEvents) {
|
|
|
+ // TO DO 这里面实际应该入库,暂时默认成功返回给前端
|
|
|
+ ReturnResult result = ReturnResult.success(true, "入库成功!", termEvents.getEventId());
|
|
|
+ return new ResponseEntity<>(result, (MultiValueMap) null, HttpStatus.OK);
|
|
|
+ }
|
|
|
+}
|