Exemplo n.º 1
0
  @RequestMapping(
      value = "/admin/shares",
      method = RequestMethod.GET,
      produces = "application/json;charset=UTF-8")
  public @ResponseBody List<ShareElement> checkShares() {
    Map<String, ShareElement> shares = shareService.getShares();
    List<ShareElement> l = new ArrayList<ShareElement>(shares.values());
    for (ShareElement s : l) {
      String p = BrowseUtils.decodePath(shareService.decryptPath(s.getPath(), s.getShareCode()));
      s.setDecodedPath(p);
    }

    return l;
  }