Ejemplo n.º 1
0
  public void deleteUncheckedRule(String uuid) {
    AssetItem asset = rulesRepository.loadAssetByUUID(uuid);

    ModuleItem packageItem = asset.getModule();
    packageItem.updateBinaryUpToDate(false);

    asset.remove();

    rulesRepository.save();
    push("packageChange", packageItem.getName());
  }
Ejemplo n.º 2
0
  @WebRemote
  @LoggedIn
  public void removeAsset(String uuid) {
    try {
      AssetItem item = rulesRepository.loadAssetByUUID(uuid);
      serviceSecurity.checkSecurityIsPackageDeveloperWithPackageUuid(item.getModule().getUUID());

      item.remove();
      rulesRepository.save();
    } catch (RulesRepositoryException e) {
      log.error("Unable to remove asset.", e);
      throw e;
    }
  }
Ejemplo n.º 3
0
  @WebRemote
  @Restrict("#{identity.loggedIn}")
  public void removeAsset(String uuid) {
    try {
      AssetItem item = getRulesRepository().loadAssetByUUID(uuid);
      serviceSecurity.checkSecurityIsPackageDeveloper(item);

      item.remove();
      getRulesRepository().save();
    } catch (RulesRepositoryException e) {
      log.error("Unable to remove asset.", e);
      throw e;
    }
  }