// ------------------------------------------------------------------------- // Action implementation // ------------------------------------------------------------------------- public String execute() throws Exception { catalogTypes = new ArrayList<CatalogType>(catalogTypeService.getAllCatalogTypes()); inventoryTypeAttributes = new ArrayList<InventoryTypeAttribute>( inventoryTypeAttributeService.getAllInventoryTypeAttributes()); return SUCCESS; }
public String execute() throws Exception { System.out.println("Inside validateInvenotryTypeAttribute "); name = name.trim(); InventoryTypeAttribute match = inventoryTypeAttributeService.getInventoryTypeAttributeByName(name); if (match != null && (id == null || match.getId() != id.intValue())) { message = i18n.getString("name_in_use"); return INPUT; } message = i18n.getString("everything_is_ok"); return SUCCESS; }