|
|
@@ -16,10 +16,7 @@ import com.fdkankan.ucenter.service.*;
|
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
|
|
import com.fdkankan.ucenter.util.DateUserUtil;
|
|
|
import com.fdkankan.ucenter.vo.request.RegisterParam;
|
|
|
-import com.fdkankan.ucenter.vo.response.LoginVo;
|
|
|
-import com.fdkankan.ucenter.vo.response.SceneInfoVo;
|
|
|
-import com.fdkankan.ucenter.vo.response.ScenePlusVo;
|
|
|
-import com.fdkankan.ucenter.vo.response.SceneVo;
|
|
|
+import com.fdkankan.ucenter.vo.response.*;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
@@ -57,7 +54,7 @@ public class ContactUsServiceImpl extends ServiceImpl<IContactUsMapper, ContactU
|
|
|
UcenterConfig ucenterConfig;
|
|
|
|
|
|
@Override
|
|
|
- public void submit(ContactUs contactUs) {
|
|
|
+ public ContactUsSubmitVo submit(ContactUs contactUs) {
|
|
|
if(StringUtils.isBlank(contactUs.getName()) || StringUtils.isBlank(contactUs.getTel())
|
|
|
|| StringUtils.isBlank(contactUs.getEmail()) || StringUtils.isBlank(contactUs.getCompany())){
|
|
|
throw new BusinessException(ResultCode.PARAM_MISS);
|
|
|
@@ -75,7 +72,7 @@ public class ContactUsServiceImpl extends ServiceImpl<IContactUsMapper, ContactU
|
|
|
if(user !=null){
|
|
|
mailTemplateService.sendContactUs2(contactUs.getEmail(),13);
|
|
|
this.save(contactUs);
|
|
|
- return;
|
|
|
+ return new ContactUsSubmitVo(1);
|
|
|
}
|
|
|
|
|
|
String callBackUrl = ucenterConfig.getContactUsCallBackUrl() + uuid;
|
|
|
@@ -84,6 +81,7 @@ public class ContactUsServiceImpl extends ServiceImpl<IContactUsMapper, ContactU
|
|
|
redisUtil.set(redisKey2, JSONObject.toJSONString(contactUs),ucenterConfig.getEmailExTime());
|
|
|
}
|
|
|
this.save(contactUs);
|
|
|
+ return new ContactUsSubmitVo(0);
|
|
|
}
|
|
|
|
|
|
@Override
|