|
@@ -0,0 +1,59 @@
|
|
|
+package com.gree.mall.manager.controller.policy;
|
|
|
+
|
|
|
+import cn.hutool.core.lang.TypeReference;
|
|
|
+import com.baomidou.mybatisplus.core.metadata.IPage;
|
|
|
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
|
+import com.gree.mall.manager.annotation.ZfireList;
|
|
|
+import com.gree.mall.manager.bean.policy.AgreementAddUp;
|
|
|
+import com.gree.mall.manager.bean.policy.AgreementDetail;
|
|
|
+import com.gree.mall.manager.bean.policy.AgreementVo;
|
|
|
+import com.gree.mall.manager.bean.policy.PolicyVo;
|
|
|
+import com.gree.mall.manager.exception.RemoteServiceException;
|
|
|
+import com.gree.mall.manager.helper.ResponseHelper;
|
|
|
+import com.gree.mall.manager.logic.policy.AgreementLogic;
|
|
|
+import com.gree.mall.manager.plus.entity.Mailbox;
|
|
|
+import com.gree.mall.manager.zfire.bean.ZfireParamBean;
|
|
|
+import com.gree.mall.manager.zfire.util.FieldUtils;
|
|
|
+import io.swagger.annotations.Api;
|
|
|
+import io.swagger.annotations.ApiOperation;
|
|
|
+import io.swagger.annotations.ApiParam;
|
|
|
+import lombok.extern.slf4j.Slf4j;
|
|
|
+import org.springframework.beans.factory.annotation.Autowired;
|
|
|
+import org.springframework.web.bind.annotation.*;
|
|
|
+
|
|
|
+import javax.servlet.http.HttpServletRequest;
|
|
|
+import javax.servlet.http.HttpServletResponse;
|
|
|
+import java.text.ParseException;
|
|
|
+
|
|
|
+@Slf4j
|
|
|
+@RestController
|
|
|
+@Api(value = "邮箱配置", tags = {"邮箱配置"})
|
|
|
+@RequestMapping(value = "/mailbox", produces = "application/json; charset=utf-8")
|
|
|
+public class MailboxController {
|
|
|
+
|
|
|
+ @Autowired
|
|
|
+ private AgreementLogic agreementLogic;
|
|
|
+
|
|
|
+
|
|
|
+ @PostMapping("/detail")
|
|
|
+ @ApiOperation("邮箱配置详情")
|
|
|
+ public ResponseHelper<Mailbox> detail(
|
|
|
+ HttpServletRequest request
|
|
|
+ ) throws ParseException {
|
|
|
+ Mailbox mailbox = agreementLogic.detailMailbox();
|
|
|
+ return ResponseHelper.success(mailbox);
|
|
|
+ }
|
|
|
+
|
|
|
+ @PostMapping("/add")
|
|
|
+ @ApiOperation("邮箱配置修改")
|
|
|
+ public ResponseHelper add(
|
|
|
+ @RequestBody Mailbox mailbox,
|
|
|
+ HttpServletRequest request
|
|
|
+ ) throws ParseException {
|
|
|
+ agreementLogic.addDetail(mailbox);
|
|
|
+ return ResponseHelper.success();
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+}
|