@Override public String getTermsAndConditionsContent() throws PackageException { return localPackage.getTermsAndConditionsContent(); }
@GET @Produces("text/html") @Path(value = "showTermsAndConditions/{pkgId}") public Object showTermsAndConditions(@PathParam("pkgId") String pkgId, @QueryParam("source") String source, @QueryParam("depCheck") Boolean depCheck) { if (depCheck == null) { depCheck = true; } try { PackageUpdateService pus = Framework.getService(PackageUpdateService.class); LocalPackage pkg = pus.getPackage(pkgId); String content = pkg.getTermsAndConditionsContent(); return getView("termsAndConditions").arg("pkg", pkg).arg("source", source).arg("content", content).arg( "depCheck", depCheck); } catch (PackageException e) { log.error("Error during terms and conditions phase ", e); return getView("installError").arg("e", e).arg("source", source); } }
@GET @Produces("text/html") @Path(value = "showTermsAndConditions/{pkgId}") public Object showTermsAndConditions(@PathParam("pkgId") String pkgId, @QueryParam("source") String source, @QueryParam("depCheck") Boolean depCheck) { if (depCheck == null) { depCheck = true; } try { PackageUpdateService pus = Framework.getLocalService(PackageUpdateService.class); LocalPackage pkg = pus.getPackage(pkgId); String content = pkg.getTermsAndConditionsContent(); return getView("termsAndConditions").arg("pkg", pkg).arg("source", source).arg("content", content).arg( "depCheck", depCheck); } catch (PackageException e) { log.error("Error during terms and conditions phase ", e); return getView("installError").arg("e", e).arg("source", source); } }