/**
  * 更新公共连接
  *
  * @param jsonObj 公共连接参数json
  * @return 0:失败 1:成功
  * @throws UnsupportedEncodingException 异常
  */
 @POST
 @Path("/update/commonlink")
 @Produces({MediaType.APPLICATION_JSON})
 public JSONObject updateCommonlink(JSONObject jsonObj) throws UnsupportedEncodingException {
   HttpSession session = request.getSession();
   User user = (User) session.getAttribute("loginUser");
   JSONObject result = new JSONObject();
   result.put("result", 0);
   if (null != jsonObj && null != user) {
     Commonlink commonlink = new Commonlink();
     buildJSONObjectToCommonlink(commonlink, jsonObj);
     boolean success = commonlinkService.updateCommonlink(commonlink);
     if (success) {
       result.put("result", 1);
       return result;
     }
   }
   return result;
 }