| | |
| | | import org.springframework.stereotype.Controller;
|
| | | import org.springframework.web.bind.annotation.RequestMapping;
|
| | | import org.springframework.web.bind.annotation.RequestMethod;
|
| | | import org.springframework.web.multipart.commons.CommonsMultipartFile;
|
| | | import org.yeshi.utils.JsonUtil;
|
| | |
|
| | | import com.google.gson.Gson;
|
| | | import com.yeshi.fanli.entity.AppInfo;
|
| | |
| | | import com.yeshi.fanli.service.inter.customerservice.CustomerServiceCommonQuestionService;
|
| | | import com.yeshi.fanli.service.inter.customerservice.CustomerServiceHistoryService;
|
| | | import com.yeshi.fanli.util.StringUtil;
|
| | | import org.yeshi.utils.JsonUtil;
|
| | |
|
| | | import net.sf.json.JSONObject;
|
| | |
|
| | |
| | | out.print(JsonUtil.loadTrueResult(JsonUtil.getApiCommonGson().toJson(answer)));
|
| | | }
|
| | |
|
| | | |
| | | /**
|
| | | * 用户吐槽
|
| | | * @param fileList
|
| | | * @param uid
|
| | | * @param content
|
| | | * @param out
|
| | | */
|
| | | @RequestMapping(value = "complaint")
|
| | | public void complaint(List<CommonsMultipartFile> fileList, Long uid, String content, PrintWriter out) {
|
| | | |
| | | // 图片最多五张、可以为空
|
| | | if (fileList != null && fileList.size() > 5 ) {
|
| | | out.print(JsonUtil.loadFalseResult("图片最多可上传五张"));
|
| | | return;
|
| | | }
|
| | | |
| | | if (content == null || content.trim().length() == 0) {
|
| | | out.print(JsonUtil.loadFalseResult("吐槽内容为空"));
|
| | | return;
|
| | | }
|
| | | |
| | | try {
|
| | | |
| | | |
| | | out.print(JsonUtil.loadTrueResult("吐槽"));
|
| | | } catch (Exception e) {
|
| | | out.print(JsonUtil.loadFalseResult("操作失败"));
|
| | | e.printStackTrace();
|
| | | }
|
| | | }
|
| | | }
|