From: Roland Häder Date: Sat, 7 Oct 2017 22:41:06 +0000 (+0200) Subject: Please cherry-pick: X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=15ff7433a527e2191fdbd926b1d85fb45015552a;p=jfinancials-war.git Please cherry-pick: - added backing bean for departments and opening times - added converter for DayOfTheWeek enumeration - added required getter for above enum in dataController - added administrative list views and "add-form" template for above new beans - added required navigation rules (not opening times so far) - added missing i18n strings - renamed some i18n strings which are now more clear - added custom JSF tags for above new beans (show/edit/delete) - removed no longer needed CSS classes/ids as this is now done by panel grids - removed divider-right CSS class - added more ui-noborder where required (no ugly over-bordering ... ;-) Signed-off-by: Roland Häder --- diff --git a/src/java/org/mxchange/jfinancials/beans/business/department/FinancialsAdminDepartmentWebRequestBean.java b/src/java/org/mxchange/jfinancials/beans/business/department/FinancialsAdminDepartmentWebRequestBean.java new file mode 100644 index 00000000..a71d89b5 --- /dev/null +++ b/src/java/org/mxchange/jfinancials/beans/business/department/FinancialsAdminDepartmentWebRequestBean.java @@ -0,0 +1,307 @@ +/* + * Copyright (C) 2017 Roland Häder + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Affero General Public License for more details. + * + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see . + */ +package org.mxchange.jfinancials.beans.business.department; + +import java.util.List; +import javax.ejb.EJB; +import javax.enterprise.context.RequestScoped; +import javax.enterprise.event.Event; +import javax.enterprise.inject.Any; +import javax.inject.Inject; +import javax.inject.Named; +import org.mxchange.jcontactsbusiness.events.department.added.DepartmentAddedEvent; +import org.mxchange.jcontactsbusiness.events.department.added.ObservableDepartmentAddedEvent; +import org.mxchange.jcontactsbusiness.exceptions.department.DepartmentAlreadyAddedException; +import org.mxchange.jcontactsbusiness.model.basicdata.BusinessBasicData; +import org.mxchange.jcontactsbusiness.model.branchoffice.BranchOffice; +import org.mxchange.jcontactsbusiness.model.department.AdminDepartmentSessionBeanRemote; +import org.mxchange.jcontactsbusiness.model.department.CompanyDepartment; +import org.mxchange.jcontactsbusiness.model.department.Department; +import org.mxchange.jcontactsbusiness.model.department.Departments; +import org.mxchange.jcontactsbusiness.model.employee.Employee; +import org.mxchange.jcontactsbusiness.model.headquarters.HeadquartersData; +import org.mxchange.jfinancials.beans.BaseFinancialsBean; +import org.mxchange.jusercore.model.user.User; + +/** + * An administrative bean for departments + *

+ * @author Roland Häder + */ +@Named ("adminDepartmentController") +@RequestScoped +public class FinancialsAdminDepartmentWebRequestBean extends BaseFinancialsBean implements FinancialsAdminDepartmentWebRequestController { + + /** + * Serial number + */ + private static final long serialVersionUID = 5_028_697_360_462L; + + /** + * EJB for administrative purposes + */ + @EJB (lookup = "java:global/jfinancials-ejb/adminDepartment!org.mxchange.jcontactsbusiness.model.department.AdminDepartmentSessionBeanRemote") + private AdminDepartmentSessionBeanRemote adminDepartmentBean; + + /** + * An event being fired when a department has been successfully added + */ + @Inject + @Any + private Event departmentAddedEvent; + + /** + * Assigned branch office (if apply-able) + */ + private BranchOffice departmentBranchOffice; + + /** + * Assigned company for this department + */ + private BusinessBasicData departmentCompany; + + /** + * A general department controller (backing bean) + */ + @Inject + private FinancialsDepartmentWebRequestController departmentController; + + /** + * Assigned headquarters (if apply-able) + */ + private HeadquartersData departmentHeadquarters; + + /** + * Lead person of this department + */ + private Employee departmentLead; + + /** + * Department name + */ + private String departmentName; + + /** + * Owning user instance (which this department is assigned to) + */ + private User departmentUserOwner; + + /** + * Default constructor + */ + public FinancialsAdminDepartmentWebRequestBean () { + // Call super constructor + super(); + } + + /** + * Adds department with all data from this backing bean. First this action + * method will validate if the department's address is already registered + * and if found, it will output a proper faces message. + *

+ * @return Redirect outcome + */ + public String addDepartment () { + // Get instance + final Department department = this.createDepartment(); + + // Is the department not created yet? + if (this.isDepartmentCreatedByRequiredData(department)) { + // Then show proper faces message + this.showFacesMessage("form-admin-add-department:branchStreet", "ADMIN_BRANCH_OFFICE_ALREADY_CREATED"); //NOI18N + return ""; //NOI18N + } + + // Delcare updated instance + final Department updatedDepartment; + + try { + // Try to call EJB + updatedDepartment = this.adminDepartmentBean.addDepartment(department); + } catch (final DepartmentAlreadyAddedException ex) { + // Output message + this.showFacesMessage("form-admin-add-department:departmentName", "ADMIN_DEPARTMENT_ALREADY_CREATED"); //NOI18N + return ""; //NOI18N + } + + // Fire event + this.departmentAddedEvent.fire(new DepartmentAddedEvent(updatedDepartment)); + + // Redirect to list + return "admin_list_department"; //NOI18N + } + + /** + * Getter for assigned branch office + *

+ * @return Branch office + */ + public BranchOffice getDepartmentBranchOffice () { + return this.departmentBranchOffice; + } + + /** + * Setter for assigned branch office + *

+ * @param departmentBranchOffice Branch office + */ + public void setDepartmentBranchOffice (final BranchOffice departmentBranchOffice) { + this.departmentBranchOffice = departmentBranchOffice; + } + + /** + * Getter for basic company data + *

+ * @return Basic company data + */ + public BusinessBasicData getDepartmentCompany () { + return this.departmentCompany; + } + + /** + * Setter for basic company data + *

+ * @param departmentCompany Basic company data + */ + public void setDepartmentCompany (final BusinessBasicData departmentCompany) { + this.departmentCompany = departmentCompany; + } + + /** + * Getter for assigned headquarters data + *

+ * @return Headquarters data + */ + public HeadquartersData getDepartmentHeadquarters () { + return this.departmentHeadquarters; + } + + /** + * Setter for assigned headquarters data + *

+ * @param departmentHeadquarters Headquarters data + */ + public void setDepartmentHeadquarters (final HeadquartersData departmentHeadquarters) { + this.departmentHeadquarters = departmentHeadquarters; + } + + /** + * Getter for department contact person + *

+ * @return Department contact person + */ + public Employee getDepartmentLead () { + return this.departmentLead; + } + + /** + * Setter for department contact person + *

+ * @param departmentLead Department contact person + */ + public void setDepartmentLead (final Employee departmentLead) { + this.departmentLead = departmentLead; + } + + /** + * Getter for department name + *

+ * @return Department name + */ + public String getDepartmentName () { + return this.departmentName; + } + + /** + * Setter for department name + *

+ * @param departmentName Department name + */ + public void setDepartmentName (final String departmentName) { + this.departmentName = departmentName; + } + + /** + * Getter for owning user instance + *

+ * @return Owning user instance + */ + public User getDepartmentUserOwner () { + return this.departmentUserOwner; + } + + /** + * Setter for owning user instance + *

+ * @param departmentUserOwner Owning user instance + */ + public void setDepartmentUserOwner (final User departmentUserOwner) { + this.departmentUserOwner = departmentUserOwner; + } + + /** + * Prepares an instance of a Department object (entity) with all data from + * this bean. If a complete fax number or land-line number was provided, it + * will be set in the instance as well. + *

+ * @return An instance of a Department class (entity) + */ + private Department createDepartment () { + // Create new department instance + final Department department = new CompanyDepartment(this.getDepartmentCompany(), this.getDepartmentName()); + + // Add all optional fields + department.setDepartmentHeadquarters(this.getDepartmentHeadquarters()); + department.setDepartmentBranchOffice(this.getDepartmentBranchOffice()); + department.setDepartmentLead(this.getDepartmentLead()); + department.setDepartmentUserOwner(this.getDepartmentUserOwner()); + + // Return fully prepared instance + return department; + } + + /** + * Checks whether the given department is already found in local cache. + * Please note that this method fully relies on the cache, so you must + * always fire proper events that add/update/delete entries in cache. + *

+ * @param department Department to check it's address + *

+ * @return Whether the address has been found + */ + private boolean isDepartmentCreatedByRequiredData (final Department department) { + // Get full list from other bean + final List departments = this.departmentController.allDepartments(); + + // Default is not found + boolean isFound = false; + + // Now check each entry + for (final Department dep : departments) { + // Is same address? + if (Departments.isSameDepartment(dep, department)) { + // Found one + isFound = true; + break; + } + } + + // Return flag + return isFound; + } + +} diff --git a/src/java/org/mxchange/jfinancials/beans/business/department/FinancialsAdminDepartmentWebRequestController.java b/src/java/org/mxchange/jfinancials/beans/business/department/FinancialsAdminDepartmentWebRequestController.java new file mode 100644 index 00000000..f960f39b --- /dev/null +++ b/src/java/org/mxchange/jfinancials/beans/business/department/FinancialsAdminDepartmentWebRequestController.java @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2017 Roland Häder + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Affero General Public License for more details. + * + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see . + */ +package org.mxchange.jfinancials.beans.business.department; + +import java.io.Serializable; + +/** + * An interface for administrative branch office controller + *

+ * @author Roland Häder + */ +public interface FinancialsAdminDepartmentWebRequestController extends Serializable { + +} diff --git a/src/java/org/mxchange/jfinancials/beans/business/department/FinancialsDepartmentWebRequestBean.java b/src/java/org/mxchange/jfinancials/beans/business/department/FinancialsDepartmentWebRequestBean.java new file mode 100644 index 00000000..61ca5a73 --- /dev/null +++ b/src/java/org/mxchange/jfinancials/beans/business/department/FinancialsDepartmentWebRequestBean.java @@ -0,0 +1,186 @@ +/* + * Copyright (C) 2017 Roland Häder + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Affero General Public License for more details. + * + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see . + */ +package org.mxchange.jfinancials.beans.business.department; + +import fish.payara.cdi.jsr107.impl.NamedCache; +import java.text.MessageFormat; +import java.util.Comparator; +import java.util.Iterator; +import java.util.LinkedList; +import java.util.List; +import javax.annotation.PostConstruct; +import javax.cache.Cache; +import javax.ejb.EJB; +import javax.enterprise.context.RequestScoped; +import javax.enterprise.event.Observes; +import javax.inject.Inject; +import javax.inject.Named; +import org.mxchange.jcontactsbusiness.events.department.added.ObservableDepartmentAddedEvent; +import org.mxchange.jcontactsbusiness.model.department.Department; +import org.mxchange.jcontactsbusiness.model.department.DepartmentSessionBeanRemote; +import org.mxchange.jfinancials.beans.BaseFinancialsBean; + +/** + * A general bean for departments + *

+ * @author Roland Häder + */ +@Named ("departmentController") +@RequestScoped +public class FinancialsDepartmentWebRequestBean extends BaseFinancialsBean implements FinancialsDepartmentWebRequestController { + + /** + * Serial number + */ + private static final long serialVersionUID = 5_028_697_360_461L; + + /** + * A list of all departments + */ + private final List allDepartments; + + /** + * EJB for administrative purposes + */ + @EJB (lookup = "java:global/jfinancials-ejb/department!org.mxchange.jcontactsbusiness.model.department.DepartmentSessionBeanRemote") + private DepartmentSessionBeanRemote departmentBean; + + /** + * A list of all departments (globally) + */ + @Inject + @NamedCache (cacheName = "departmentCache") + private Cache departmentCache; + + /** + * A list of filtered departments + */ + private List filteredDepartments; + + /** + * Default constructor + */ + public FinancialsDepartmentWebRequestBean () { + // Call super constructor + super(); + + // Init list + this.allDepartments = new LinkedList<>(); + } + + /** + * Observes events being fired when a department has been added. + *

+ * @param event Event being fired + *

+ * @throws NullPointerException If the parameter or it's carried instance is + * null + * @throws IllegalArgumentException If the branchId is zero or lower + */ + public void afterDepartmentAddedEvent (@Observes final ObservableDepartmentAddedEvent event) { + // Validate parameter + if (null == event) { + // Throw NPE + throw new NullPointerException("event is null"); //NOI18N + } else if (event.getDepartment() == null) { + // Throw NPE again + throw new NullPointerException("event.department is null"); //NOI18N + } else if (event.getDepartment().getDepartmentId() == null) { + // Throw it again + throw new NullPointerException("event.department.branchId is null"); //NOI18N + } else if (event.getDepartment().getDepartmentId() < 1) { + // Throw IAE + throw new IllegalArgumentException(MessageFormat.format("event.department.branchId={0} is not valid", event.getDepartment().getDepartmentId())); //NOI18N + } + + // Add instance to cache + this.departmentCache.put(event.getDepartment().getDepartmentId(), event.getDepartment()); + this.allDepartments.add(event.getDepartment()); + } + + @Override + @SuppressWarnings ("ReturnOfCollectionOrArrayField") + public List allDepartments () { + return this.allDepartments; + } + + /** + * Getter for a list of filtered departments + *

+ * @return Filtered departments + */ + @SuppressWarnings ("ReturnOfCollectionOrArrayField") + public List getFilteredDepartments () { + return this.filteredDepartments; + } + + /** + * Setter for a list of filtered departments + *

+ * @param filteredDepartments Filtered departments + */ + @SuppressWarnings ("AssignmentToCollectionOrArrayFieldFromParameter") + public void setFilteredDepartments (final List filteredDepartments) { + this.filteredDepartments = filteredDepartments; + } + + /** + * Initializer method + */ + @PostConstruct + public void initializeList () { + // Is cache there? + if (!this.departmentCache.iterator().hasNext()) { + // Get whole list + final List list = this.departmentBean.allDepartments(); + + // Add all + for (final Iterator iterator = list.iterator(); iterator.hasNext();) { + // Get next element + final Department next = iterator.next(); + + // Add it to cache + this.departmentCache.put(next.getDepartmentId(), next); + } + } + + // Is the list empty, but filled cache? + if (this.allDepartments.isEmpty() && this.departmentCache.iterator().hasNext()) { + // Get iterator + final Iterator> iterator = this.departmentCache.iterator(); + + // Build up list + while (iterator.hasNext()) { + // GEt next element + final Cache.Entry next = iterator.next(); + + // Add to list + this.allDepartments.add(next.getValue()); + } + + // Sort list + this.allDepartments.sort(new Comparator() { + @Override + public int compare (final Department o1, final Department o2) { + return o1.getDepartmentId() > o2.getDepartmentId() ? 1 : o1.getDepartmentId() < o2.getDepartmentId() ? -1 : 0; + } + } + ); + } + } + +} diff --git a/src/java/org/mxchange/jfinancials/beans/business/department/FinancialsDepartmentWebRequestController.java b/src/java/org/mxchange/jfinancials/beans/business/department/FinancialsDepartmentWebRequestController.java new file mode 100644 index 00000000..8ff2f6ab --- /dev/null +++ b/src/java/org/mxchange/jfinancials/beans/business/department/FinancialsDepartmentWebRequestController.java @@ -0,0 +1,37 @@ +/* + * Copyright (C) 2017 Roland Häder + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Affero General Public License for more details. + * + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see . + */ +package org.mxchange.jfinancials.beans.business.department; + +import java.io.Serializable; +import java.util.List; +import org.mxchange.jcontactsbusiness.model.department.Department; + +/** + * An interface for general department controller + *

+ * @author Roland Häder + */ +public interface FinancialsDepartmentWebRequestController extends Serializable { + + /** + * Returns a list of all departments + *

+ * @return A list of all departments + */ + List allDepartments (); + +} diff --git a/src/java/org/mxchange/jfinancials/beans/business/opening_time/FinancialsAdminOpeningTimeWebRequestBean.java b/src/java/org/mxchange/jfinancials/beans/business/opening_time/FinancialsAdminOpeningTimeWebRequestBean.java new file mode 100644 index 00000000..85103d18 --- /dev/null +++ b/src/java/org/mxchange/jfinancials/beans/business/opening_time/FinancialsAdminOpeningTimeWebRequestBean.java @@ -0,0 +1,201 @@ +/* + * Copyright (C) 2017 Roland Häder + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Affero General Public License for more details. + * + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see . + */ +package org.mxchange.jfinancials.beans.business.opening_time; + +import java.util.Date; +import javax.ejb.EJB; +import javax.enterprise.context.RequestScoped; +import javax.enterprise.event.Event; +import javax.enterprise.inject.Any; +import javax.inject.Inject; +import javax.inject.Named; +import org.mxchange.jcontactsbusiness.events.opening_time.added.ObservableOpeningTimeAddedEvent; +import org.mxchange.jcontactsbusiness.events.opening_time.added.OpeningTimeAddedEvent; +import org.mxchange.jcontactsbusiness.model.opening_time.AdminOpeningTimeSessionBeanRemote; +import org.mxchange.jcontactsbusiness.model.opening_time.BusinessOpeningTime; +import org.mxchange.jcontactsbusiness.model.opening_time.OpeningTime; +import org.mxchange.jcontactsbusiness.model.opening_time.dayofweek.DayOfTheWeek; +import org.mxchange.jfinancials.beans.BaseFinancialsBean; + +/** + * An administrative bean for openingTimes + *

+ * @author Roland Häder + */ +@Named ("adminOpeningTimeController") +@RequestScoped +public class FinancialsAdminOpeningTimeWebRequestBean extends BaseFinancialsBean implements FinancialsAdminOpeningTimeWebRequestController { + + /** + * Serial number + */ + private static final long serialVersionUID = 5_028_697_360_463L; + + /** + * EJB for administrative purposes + */ + @EJB (lookup = "java:global/jfinancials-ejb/adminOpeningTimes!org.mxchange.jcontactsbusiness.model.opening_time.AdminOpeningTimeSessionBeanRemote") + private AdminOpeningTimeSessionBeanRemote adminOpeningTimeBean; + + /** + * Ending week day + */ + private DayOfTheWeek openingEndDay; + + /** + * Ending time + */ + private Date openingEndTime; + + /** + * Starting week day + */ + private DayOfTheWeek openingStartDay; + + /** + * Starting time + */ + private Date openingStartTime; + + /** + * An event being fired when a openingTime has been successfully added + */ + @Inject + @Any + private Event openingTimeAddedEvent; + + /** + * Default constructor + */ + public FinancialsAdminOpeningTimeWebRequestBean () { + // Call super constructor + super(); + } + + /** + * Adds openingTime with all data from this backing bean. First this action + * method will validate if the openingTime's address is already registered + * and if found, it will output a proper faces message. + *

+ * @return Redirect outcome + */ + public String addOpeningTimes () { + // Get instance + final OpeningTime openingTime = this.createOpeningTimes(); + + // Call EJB and return updated instance + final OpeningTime updatedOpeningTimes = this.adminOpeningTimeBean.addOpeningTime(openingTime); + + // Fire event + this.openingTimeAddedEvent.fire(new OpeningTimeAddedEvent(updatedOpeningTimes)); + + // Redirect to list + return "admin_list_opening_time"; //NOI18N + } + + /** + * Getter for ending week day + *

+ * @return Ending week day + */ + public DayOfTheWeek getOpeningEndDay () { + return this.openingEndDay; + } + + /** + * Setter for ending week day + *

+ * @param openingEndDay Ending week day + */ + public void setOpeningEndDay (final DayOfTheWeek openingEndDay) { + this.openingEndDay = openingEndDay; + } + + /** + * Getter for ending time + *

+ * @return Ending time + */ + @SuppressWarnings ("ReturnOfDateField") + public Date getOpeningEndTime () { + return this.openingEndTime; + } + + /** + * Getter for ending time + *

+ * @param openingEndTime Ending time + */ + @SuppressWarnings ("AssignmentToDateFieldFromParameter") + public void setOpeningEndTime (final Date openingEndTime) { + this.openingEndTime = openingEndTime; + } + + /** + * Getter for starting week day + *

+ * @return Starting week day + */ + public DayOfTheWeek getOpeningStartDay () { + return this.openingStartDay; + } + + /** + * Getter for starting week day + *

+ * @param openingStartDay Starting week day + */ + public void setOpeningStartDay (final DayOfTheWeek openingStartDay) { + this.openingStartDay = openingStartDay; + } + + /** + * Getter for starting time + *

+ * @return Starting time + */ + @SuppressWarnings ("ReturnOfDateField") + public Date getOpeningStartTime () { + return this.openingStartTime; + } + + /** + * Getter for starting time + *

+ * @param openingStartTime Starting time + */ + @SuppressWarnings ("AssignmentToDateFieldFromParameter") + public void setOpeningStartTime (final Date openingStartTime) { + this.openingStartTime = openingStartTime; + } + + /** + * Prepares an instance of a OpeningTimes object (entity) with all data from + * this bean. If a complete fax number or land-line number was provided, it + * will be set in the instance as well. + *

+ * @return An instance of a OpeningTimes class (entity) + */ + private OpeningTime createOpeningTimes () { + // Create new openingTime instance + final OpeningTime openingTime = new BusinessOpeningTime(this.getOpeningEndDay(), this.getOpeningEndTime(), this.getOpeningStartDay(), this.getOpeningStartTime()); + + // Return fully prepared instance + return openingTime; + } + +} diff --git a/src/java/org/mxchange/jfinancials/beans/business/opening_time/FinancialsAdminOpeningTimeWebRequestController.java b/src/java/org/mxchange/jfinancials/beans/business/opening_time/FinancialsAdminOpeningTimeWebRequestController.java new file mode 100644 index 00000000..168e2022 --- /dev/null +++ b/src/java/org/mxchange/jfinancials/beans/business/opening_time/FinancialsAdminOpeningTimeWebRequestController.java @@ -0,0 +1,28 @@ +/* + * Copyright (C) 2017 Roland Häder + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Affero General Public License for more details. + * + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see . + */ +package org.mxchange.jfinancials.beans.business.opening_time; + +import java.io.Serializable; + +/** + * An interface for administrative opening time controller + *

+ * @author Roland Häder + */ +public interface FinancialsAdminOpeningTimeWebRequestController extends Serializable { + +} diff --git a/src/java/org/mxchange/jfinancials/beans/business/opening_time/FinancialsOpeningTimeWebRequestBean.java b/src/java/org/mxchange/jfinancials/beans/business/opening_time/FinancialsOpeningTimeWebRequestBean.java new file mode 100644 index 00000000..7ae1d1d6 --- /dev/null +++ b/src/java/org/mxchange/jfinancials/beans/business/opening_time/FinancialsOpeningTimeWebRequestBean.java @@ -0,0 +1,153 @@ +/* + * Copyright (C) 2017 Roland Häder + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Affero General Public License for more details. + * + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see . + */ +package org.mxchange.jfinancials.beans.business.opening_time; + +import fish.payara.cdi.jsr107.impl.NamedCache; +import java.util.Comparator; +import java.util.Iterator; +import java.util.LinkedList; +import java.util.List; +import javax.annotation.PostConstruct; +import javax.cache.Cache; +import javax.ejb.EJB; +import javax.enterprise.context.RequestScoped; +import javax.inject.Inject; +import javax.inject.Named; +import org.mxchange.jcontactsbusiness.model.opening_time.OpeningTime; +import org.mxchange.jcontactsbusiness.model.opening_time.OpeningTimeSessionBeanRemote; +import org.mxchange.jfinancials.beans.BaseFinancialsBean; + +/** + * A general bean for opening times + *

+ * @author Roland Häder + */ +@Named ("openingTimeController") +@RequestScoped +public class FinancialsOpeningTimeWebRequestBean extends BaseFinancialsBean implements FinancialsOpeningTimeWebRequestController { + + /** + * Serial number + */ + private static final long serialVersionUID = 5_028_697_360_462L; + + /** + * A list of all opening times + */ + private final List allOpeningTimes; + + /** + * A list of filtered opening times + */ + private List filteredOpeningTimes; + + /** + * EJB for administrative purposes + */ + @EJB (lookup = "java:global/jfinancials-ejb/openingTimes!org.mxchange.jcontactsbusiness.model.opening_time.OpeningTimeSessionBeanRemote") + private OpeningTimeSessionBeanRemote openingTimesBean; + + /** + * A list of all opening times (globally) + */ + @Inject + @NamedCache (cacheName = "openingTimesCache") + private Cache openingTimesCache; + + /** + * Default constructor + */ + public FinancialsOpeningTimeWebRequestBean () { + // Call super constructor + super(); + + // Init list + this.allOpeningTimes = new LinkedList<>(); + } + + @Override + @SuppressWarnings ("ReturnOfCollectionOrArrayField") + public List allOpeningTimes () { + return this.allOpeningTimes; + } + + /** + * Getter for a list of filtered opening times + *

+ * @return Filtered opening times + */ + @SuppressWarnings ("ReturnOfCollectionOrArrayField") + public List getFilteredOpeningTimes () { + return this.filteredOpeningTimes; + } + + /** + * Setter for a list of filtered opening times + *

+ * @param filteredOpeningTimes Filtered opening times + */ + @SuppressWarnings ("AssignmentToCollectionOrArrayFieldFromParameter") + public void setFilteredOpeningTimes (final List filteredOpeningTimes) { + this.filteredOpeningTimes = filteredOpeningTimes; + } + + /** + * Initializer method + */ + @PostConstruct + public void initializeList () { + // Is cache there? + if (!this.openingTimesCache.iterator().hasNext()) { + // Get whole list + final List list = this.openingTimesBean.allOpeningTimes(); + + // Add all + for (final Iterator iterator = list.iterator(); iterator.hasNext();) { + // Get next element + final OpeningTime next = iterator.next(); + + // Add it to cache + this.openingTimesCache.put(next.getOpeningId(), next); + } + } + + // Is the list empty, but filled cache? + if (this.allOpeningTimes.isEmpty() && this.openingTimesCache.iterator().hasNext()) { + // Get iterator + final Iterator> iterator = this.openingTimesCache.iterator(); + + // Build up list + while (iterator.hasNext()) { + // GEt next element + final Cache.Entry next = iterator.next(); + + // Add to list + this.allOpeningTimes.add(next.getValue()); + } + + // Sort list + this.allOpeningTimes.sort(new Comparator() { + @Override + public int compare (final OpeningTime o1, final OpeningTime o2) { + return o1.getOpeningId() > o2.getOpeningId() ? 1 : o1.getOpeningId() < o2.getOpeningId() ? -1 : 0; + } + } + ); + } + } + +} diff --git a/src/java/org/mxchange/jfinancials/beans/business/opening_time/FinancialsOpeningTimeWebRequestController.java b/src/java/org/mxchange/jfinancials/beans/business/opening_time/FinancialsOpeningTimeWebRequestController.java new file mode 100644 index 00000000..442b1532 --- /dev/null +++ b/src/java/org/mxchange/jfinancials/beans/business/opening_time/FinancialsOpeningTimeWebRequestController.java @@ -0,0 +1,37 @@ +/* + * Copyright (C) 2017 Roland Häder + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU Affero General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU Affero General Public License for more details. + * + * You should have received a copy of the GNU Affero General Public License + * along with this program. If not, see . + */ +package org.mxchange.jfinancials.beans.business.opening_time; + +import java.io.Serializable; +import java.util.List; +import org.mxchange.jcontactsbusiness.model.opening_time.OpeningTime; + +/** + * An interface for general opening times controller + *

+ * @author Roland Häder + */ +public interface FinancialsOpeningTimeWebRequestController extends Serializable { + + /** + * Returns a list of all opening times + *

+ * @return A list of all opening times + */ + List allOpeningTimes (); + +} diff --git a/src/java/org/mxchange/jfinancials/beans/data/FinancialsDataWebApplicationBean.java b/src/java/org/mxchange/jfinancials/beans/data/FinancialsDataWebApplicationBean.java index db014c53..9a88edc5 100644 --- a/src/java/org/mxchange/jfinancials/beans/data/FinancialsDataWebApplicationBean.java +++ b/src/java/org/mxchange/jfinancials/beans/data/FinancialsDataWebApplicationBean.java @@ -18,6 +18,7 @@ package org.mxchange.jfinancials.beans.data; import javax.enterprise.context.ApplicationScoped; import javax.inject.Named; +import org.mxchange.jcontactsbusiness.model.opening_time.dayofweek.DayOfTheWeek; import org.mxchange.jfinancials.beans.BaseFinancialsBean; import org.mxchange.jproduct.model.payment.PaymentType; @@ -43,6 +44,15 @@ public class FinancialsDataWebApplicationBean extends BaseFinancialsBean { super(); } + /** + * Returns a list of all days of the week + *

+ * @return A list of all days of the week + */ + public DayOfTheWeek[] getDayOfTheWeek () { + return DayOfTheWeek.values(); + } + /** * Returns a list of all payment types *

@@ -51,5 +61,4 @@ public class FinancialsDataWebApplicationBean extends BaseFinancialsBean { public PaymentType[] getPaymentTypes () { return PaymentType.values(); } - } diff --git a/src/java/org/mxchange/jfinancials/converter/business/department/FinancialsCompanyDepartmentConverter.java b/src/java/org/mxchange/jfinancials/converter/business/department/FinancialsCompanyDepartmentConverter.java index 8681cbc8..547f9616 100644 --- a/src/java/org/mxchange/jfinancials/converter/business/department/FinancialsCompanyDepartmentConverter.java +++ b/src/java/org/mxchange/jfinancials/converter/business/department/FinancialsCompanyDepartmentConverter.java @@ -26,9 +26,9 @@ import javax.faces.validator.ValidatorException; import javax.naming.Context; import javax.naming.InitialContext; import javax.naming.NamingException; -import org.mxchange.jcontactsbusiness.exceptions.department.CompanyDepartmentNotFoundException; -import org.mxchange.jcontactsbusiness.model.department.CompanyDepartmentSessionBeanRemote; +import org.mxchange.jcontactsbusiness.exceptions.department.DepartmentNotFoundException; import org.mxchange.jcontactsbusiness.model.department.Department; +import org.mxchange.jcontactsbusiness.model.department.DepartmentSessionBeanRemote; /** * Converter for company department id <-> instance @@ -41,7 +41,7 @@ public class FinancialsCompanyDepartmentConverter implements Converter. + */ +package org.mxchange.jfinancials.converter.dayofweek; + +import javax.faces.convert.EnumConverter; +import javax.faces.convert.FacesConverter; +import org.mxchange.jcontactsbusiness.model.opening_time.dayofweek.DayOfTheWeek; + +/** + * A converter for day of the week enumeration + *

+ * @author Roland Häder + */ +@FacesConverter("DayOfTheWeekConverter") +public class FinancialsDayOfTheWeekConverter extends EnumConverter { + + /** + * Default constructor which calls the super constructor with the proper + * enumeration as class type. + */ + public FinancialsDayOfTheWeekConverter () { + super(DayOfTheWeek.class); + } + +} diff --git a/src/java/org/mxchange/localization/bundle_de_DE.properties b/src/java/org/mxchange/localization/bundle_de_DE.properties index 3a8afccf..e5cae05f 100644 --- a/src/java/org/mxchange/localization/bundle_de_DE.properties +++ b/src/java/org/mxchange/localization/bundle_de_DE.properties @@ -88,12 +88,14 @@ CONTENT_TITLE_INDEX_PRIVACY=Datenschutzbestimmungen: ADMIN_MENU_MAIN_TITLE=Hauptauswahl ADMIN_MENU_LOGOUT_TITLE=Ausloggen ADMIN_LINK_INDEX_TITLE=Zur Willkommensseite -ADMIN_LINK_LOGOUT_TITLE=Ausloggen +ADMIN_LINK_LOGOUT_TITLE=Ausloggen vom Administrationsbereich ADMIN_LINK_TO_WEBPAGE_TITLE=Zur Webseite, aber eingeloggt bleiben ADMIN_LINK_INDEX=Home ADMIN_LINK_LOGOUT=Ausloggen ADMIN_LINK_TO_WEBPAGE=Webseite aufrufen ADMIN_LINK_FOOTER_TO_WEBPAGE=Zur Webseite +#@TODO Please fix German umlauts! +ADMIN_LINK_FOOTER_TO_WEBPAGE_TITLE=Dieser Link fuehrt zum Gastbereich. GUEST_LINK_IMPRINT=Impressum GUEST_LINK_TERMS=AGBs GUEST_LINK_PRIVACY=Datenschutz @@ -126,7 +128,8 @@ CONTENT_TITLE_USER_LOGIN_HOME=\u00dcbersicht Ihrer Bewerbungen: LOGIN_LINK_LOGOUT=Ausloggen COUNTRY_GERMANY=Deutschland COUNTRY_PHILIPPINES=Philippinen -NONE_SELECTED=k.A. +#@TODO Please fix German umlauts! +NONE_SELECTED=Nichts ausgewaehlt ENTERED_HOUSE_NUMBER_INVALID=Die eingegebene Hausnummer ist ung\u00fcltig. ENTERED_ZIP_CODE_INVALID=Die eingegebene Postleitzahl ist ung\u00fcltig. TABLE_HEADER_USER_LIST=Alle Benutzer auflisten @@ -236,6 +239,7 @@ CONTENT_TITLE_ADMIN_EDIT_USER=\u00c4ndern von Benutzeraccounts: PAGE_TITLE_ADMIN_UNLOCK_USER=Entsperren von Benutzeraccounts CONTENT_TITLE_ADMIN_UNLOCK_USER=Entsperren von Benutzeraccounts: ADMIN_MENU_USER_TITLE=Benutzerverwaltung +#@TODO Please fix German umlauts! PAGE_TITLE_ADMIN_ADD_USER=Neues Benutzeraccount hinzufuegen CONTENT_TITLE_ADMIN_ADD_USER=Neues Benutzeraccount hinzufuegen: TABLE_SUMMARY_ADMIN_LIST_USERS=Diese Tabelle listet Administration, alle Benutzer auf. @@ -265,7 +269,8 @@ BUTTON_ADMIN_ADD_USER=Neues Benutzeraccount hinzuf\u00fcgen ADMIN_MENU_COUNTRY_TITLE=L\u00e4nderdaten ADMIN_LINK_LIST_COUNTRIES=L\u00e4nder ADMIN_LINK_LIST_COUNTRIES_TITLE=Bestehende L\u00e4nderdaten auflisten, neue hinzuf\u00fcgen, \u00e4ndern und l\u00f6schen. -PAGE_TITLE_ADMIN_LIST_COUNTRY=L\u00e4nderdaten verwalten +PAGE_TITLE_ADMIN_LIST_COUNTRY=L\u00e4nderdaten auflisten +#@TODO Please fix German umlauts! CONTENT_TITLE_ADMIN_LIST_COUNTRY=Auflisten von Laenderdaten: ADMIN_ADD_COUNTRY_TITLE=Neues Land hinzuf\u00fcgen ADMIN_COUNTRY_DATA_MINIMUM_NOTICE=Bitte geben Sie alle Felder an. @@ -521,9 +526,9 @@ BUTTON_ADMIN_EXPORT_USERS_XLS=Benutzerdaten als Excel-Datei ADMIN_LINK_EXPORT_CONTACT=Daten exportieren ADMIN_LINK_EXPORT_CONTACT_TITLE=Kontaktdaten exportieren #@TODO Please fix German umlauts! -ADMIN_CONTACT_LIST_EMPTY=Keine Kontaktdaten in Datenbank gefunden. Oder Ihre Suche ergab keine Uebereinstimmungen. +ADMIN_EMPTY_LIST_CONTACT=Keine Kontaktdaten in Datenbank gefunden. Oder Ihre Suche ergab keine Uebereinstimmungen. #@TODO Please fix German umlauts! -ADMIN_USER_LIST_EMPTY=Keine Benutzerdaten in Datenbank gefunden. Oder Ihre Suche ergab keine Uebereinstimmungen. +ADMIN_EMPTY_LIST_USER=Keine Benutzerdaten in Datenbank gefunden. Oder Ihre Suche ergab keine Uebereinstimmungen. ADMIN_PERSONAL_DATA_COMMENT=Kommentar: (optional) PAGE_TITLE_USER_RESEND_DONE=Neuen Best\u00e4tigungslink verschickt CONTENT_TITLE_USER_RESEND_DONE=Neuen Best\u00e4tigungslink verschickt: @@ -783,7 +788,7 @@ PAGE_TITLE_ADMIN_LIST_BASIC_COMPANY_DATA=Stammdaten auflisten #@TODO Please fix German umlauts! CONTENT_TITLE_ADMIN_LIST_BASIC_COMPANY_DATA=Auflisten von Stammdaten #@TODO Please fix German umlauts! -ADMIN_BASIC_COMPANY_DATA_LIST_EMPTY=Es befinden sich keine Stammdaten in der Datenbank. Oder Ihre Suche ergab keine Uebereinstimmungen. +ADMIN_EMPTY_LIST_BASIC_COMPANY_DATA=Es befinden sich keine Stammdaten in der Datenbank. Oder Ihre Suche ergab keine Uebereinstimmungen. #@TODO Please fix German umlauts! TABLE_SUMMARY_ADMIN_LIST_BASIC_COMPANY_DATA=Diese Tabelle listet Stammdaten auf. ADMIN_BASIC_COMPANY_DATA_ID=Id-Nummer: @@ -847,21 +852,21 @@ ADMIN_LINK_SHOW_BASIC_COMPANY_DATA_COMPANY_FOUNDER_TITLE=Daten des Unternehmensg ADMIN_LINK_ASSIGN_BASIC_COMPANY_DATA_COMPANY_FOUNDER_TITLE=Weisst diesem Firmeneintrag einen Unternehmensgruender zu. ADMIN_BASIC_COMPANY_DATA_CREATED=Eintrag erstellt ADMIN_USER_NAME_IS_REQUIRED=Bitte vergeben Sie einen Benutzernamen. Dieser muss unique sein. -NO_WEBSITE_URL_ENTERED=Keine URL eingegeben +NO_WEBSITE_URL_ENTERED=Keine URL eingegeben. ADMIN_LINK_LIST_BRANCH_OFFICES=Filialen ADMIN_LINK_LIST_BRANCH_OFFICES_TITLE=Listet Filialen auf. ADMIN_ENTER_DATA_STORE=Etage eingeben: ADMIN_ENTER_DATA_SUITE_NUMBER=Appartmentnummer eingeben: -ADMIN_ASSIGN_BRANCH_OFFICE_USER_OWNER=Benutzer einer Filiale zuweisen: +ADMIN_ASSIGN_BRANCH_OFFICE_USER_OWNER=Benutzer der Filiale zuweisen: ADMIN_ASSIGN_BRANCH_OFFICE_CONTACT_EMPLOYEE=Kontaktperson der Filiale zuweisen: ADMIN_BRANCH_OFFICE_DATA_LEGEND=Grunddaten der Filiale: #@TODO Please fix German umlauts! ADMIN_BRANCH_OFFICE_DATA_LEGEND_TITLE=Geben Sie hier die Grunddaten der Filiale ein. -ADMIN_ASSIGN_BRANCH_OFFICE_COMPANY=Filiale einem Unternehmen zuweisen: +ADMIN_ASSIGN_BRANCH_OFFICE_COMPANY=Filiale dem Unternehmen zuweisen: PAGE_TITLE_ADMIN_LIST_BRANCH_OFFICES=Filialen auflisten CONTENT_TITLE_ADMIN_LIST_BRANCH_OFFICES=Auflisten von Filialen: #@TODO Please fix German umlauts! -ADMIN_BRANCH_OFFICES_LIST_EMPTY=Es wurden keine Filialen in der Datenbank gefunden. Oder Ihre Suche ergab keine Uebereinstimmungen. +ADMIN_EMPTY_LIST_BRANCH_OFFICES=Es wurden keine Filialen in der Datenbank gefunden. Oder Ihre Suche ergab keine Uebereinstimmungen. #@TODO Please fix German umlauts! ADMIN_ADD_BRANCH_OFFICE_TITLE=Filiale hinzufuegen #@TODO Please fix German umlauts! @@ -916,25 +921,26 @@ ADMIN_LINK_RESEND_CONFIRMATION_SHORT=Erneut ADMIN_LINK_UNLOCK_SHORT=Entsperren ADMIN_LINK_LOCK_SHORT=Sperren #@TODO Please fix German umlauts! -ADMIN_MOBILE_PROVIDER_LIST_EMPTY=Es befinden sich keine Mobilfunkanbieter in der Datenbank. Oder Ihre Suche ergab keine Uebereinstimmungen. +ADMIN_EMPTY_LIST_MOBILE_PROVIDER=Es befinden sich keine Mobilfunkanbieter in der Datenbank. Oder Ihre Suche ergab keine Uebereinstimmungen. ADMIN_LINK_SHOW_MOBILE_PROVIDER_TITLE=Details des Mobilfunkanbieters anzeigen. ADMIN_LINK_EDIT_MOBILE_PROVIDER_TITLE=Edieren des Mobilfunkanbieters. #@TODO Please fix German umlauts! ADMIN_LINK_DELETE_MOBILE_PROVIDER_TITLE=Loescht den Mobilfunkanbieter. -ADMIN_LINK_SHOW_COUNTRY_TITLE=Details des Landes anzeigen. -ADMIN_LINK_EDIT_COUNTRY_TITLE=Editieren des Landes. +ADMIN_LINK_SHOW_COUNTRY_TITLE=Zeigt Details des Landes an. +#@TODO Please fix German umlauts! +ADMIN_LINK_EDIT_COUNTRY_TITLE=Editieren der Laenderdaten. #@TODO Please fix German umlauts! -ADMIN_LINK_DELETE_COUNTRY_TITLE=Loeschen des Landes. +ADMIN_LINK_DELETE_COUNTRY_TITLE=Loescht die Laenderdaten. #@TODO Please fix German umlauts! -ADMIN_COUNTRY_LIST_EMPTY=Es befinden sich keine Laender in der Datenbank. Oder Ihre Suche ergab keine Uebereinstimmungen. +ADMIN_EMPTY_LIST_COUNTRY=Es befinden sich keine Laender in der Datenbank. Oder Ihre Suche ergab keine Uebereinstimmungen. #@TODO Please fix German umlauts! -ADMIN_FAX_NUMBER_LIST_EMPTY=Es befinden sich keine Faxnummern in der Datenbank oder Ihre Suche ergab keine Uebereinstimmungen. +ADMIN_EMPTY_LIST_FAX_NUMBER=Es befinden sich keine Faxnummern in der Datenbank oder Ihre Suche ergab keine Uebereinstimmungen. #@TODO Please fix German umlauts! -ADMIN_LANDLINE_NUMBER_LIST_EMPTY=Es befinden sich keine Festnetznummern in der Datenbank oder Ihre Suche ergab keine Uebereinstimmungen. +ADMIN_EMPTY_LIST_LANDLINE_NUMBER=Es befinden sich keine Festnetznummern in der Datenbank oder Ihre Suche ergab keine Uebereinstimmungen. #@TODO Please fix German umlauts! -ADMIN_MOBILE_NUMBER_LIST_EMPTY=Es befinden sich keine Mobilfunknummern in der Datenbank oder Ihre Suche ergab keine Uebereinstimmungen. +ADMIN_EMPTY_LIST_MOBILE_NUMBER=Es befinden sich keine Mobilfunknummern in der Datenbank oder Ihre Suche ergab keine Uebereinstimmungen. #@TODO Please fix German umlauts! -ADMIN_CONTACT_MOBILE_LIST_EMPTY=Es befinden sich keine Mobilfunknummern von Kontakten in der Datenbank oder Ihre Suche ergab keine Uebereinstimmungen. +ADMIN_EMPTY_LIST_CONTACT_MOBILE=Es befinden sich keine Mobilfunknummern von Kontakten in der Datenbank oder Ihre Suche ergab keine Uebereinstimmungen. #@TODO Please fix German umlauts! ADMIN_MOBILE_PROVIDER_COUNTRY_REQUIRED=Bitte waehlen Sie ein Land fuer den Mobilfunkanbieter aus. #@TODO Please fix German umlauts! @@ -966,10 +972,10 @@ PAYMENT_TYPE_INVOICE=Auf Rechnung ADMIN_SELECT_SELLER_EMPLOYEE=Verkaeufer auswaehlen: #@TODO Please fix German umlauts! LOGIN_SELECT_SELLER_EMPLOYEE=Bitte waehlen Sie einen Verkaeufer aus: -ADMIN_LINK_SHOW_EMPLOYEE_TITLE=Zeigt Daten eines Mitarbeiters an. +ADMIN_LINK_SHOW_EMPLOYEE_TITLE=Zeigt Details des Mitarbeiters an. TABLE_SUMMARY_ADMIN_LIST_EMPLOYEES=Diese Tabelle listet alle Mitarbeiter auf. #@TODO Please fix German umlauts! -ADMIN_EMPLOYEES_LIST_EMPTY=Es wurden keine Mitarbeiter in der Datenbank gefunden. Oder Ihre Suche ergab keine Uebereinstimmungen. +ADMIN_EMPTY_LIST_EMPLOYEES=Es befinden sich keine Mitarbeiter in der Datenbank gefunden. Oder Ihre Suche ergab keine Uebereinstimmungen. ADMIN_LIST_EMPLOYEES_HEADER=Alle Mitarbeiter auflisten ADMIN_LINK_LIST_EMPLOYEES=Mitarbeiter ADMIN_LINK_LIST_EMPLOYEES_TITLE=Listet Mitarbeiter auf @@ -1010,3 +1016,57 @@ ADMIN_LINK_LIST_DEPARTMENTS=Abteilungen ADMIN_LINK_LIST_DEPARTMENTS_TITLE=Listet Abteilungen von Unternehmen auf. #@TODO Please fix German umlauts! ADMIN_LINK_LIST_OPENING_TIMES=Oeffnungszeiten +PAGE_TITLE_ADMIN_LIST_DEPARTMENTS=Abteilungen auflisten +CONTENT_TITLE_ADMIN_LIST_DEPARTMENTS=Auflisten von Abteilungen: +#@TODO Please fix German umlauts! +ADMIN_EMPTY_LIST_DEPARTMENTS=Es befinden sich keine Abteilungen in der Datenbank. Oder Ihre Suche ergab keine Uebereinstimmungen. +ADMIN_LINK_SHOW_DEPARTMENT_TITLE=Zeigt Details zur Abteilung an. +ADMIN_LINK_EDIT_DEPARTMENT_TITLE=Editieren der Abteilung +ADMIN_LINK_DELETE_DEPARTMENT_TITLE=Loescht die Abteilung +#@TODO Please fix German umlauts! +ADMIN_DEPARTMENT_ALREADY_CREATED=Die Abteilung existiert bereits im ausgewaehlten Unternehmen. +ADMIN_LIST_DEPARTMENTS_HEADER=Alle Abteilungen auflisten +ADMIN_DEPARTMENT_NAME=Abteilung: +ADMIN_DEPARTMENT_LEAD_EMPLOYEE=Abteilungsleiter: +ADMIN_ADD_DEPARTMENT_TITLE=Neue Abteilung hinzuf\u00fcgen +ADMIN_DEPARTMENT_LEGEND=Daten der Abteilung eingeben: +ADMIN_DEPARTMENT_LEGEND_TITLE=Geben Sie hier die Daten der Abteilung ein. +#@TODO Please fix German umlauts! +ADMIN_ADD_DEPARTMENT_MINIMUM_DATA=Bitte geben Sie mindestens den Namen der Abteilung (z.B. Verkauf) ein und waehlen Sie mindestens das Unternehmen aus. Wenn bekannt, waehlen Sie entweder eine Filiale oder eine Hauptniederlassung aus. +ADMIN_ENTER_DEPARTMENT_NAME=Name der Abteilung eingeben: +ADMIN_ASSIGN_DEPARTMENT_BRANCH_OFFICE=Filiale der Abteilung zuweisen: +ADMIN_ASSIGN_DEPARTMENT_HEADQUARTERS=Hauptsitz der Abteilung zuweisen: +ADMIN_ASSIGN_DEPARTMENT_COMPANY=Unternehmen der Abteilung zuweisen: +ADMIN_ASSIGN_DEPARTMENT_LEAD_EMPLOYEE=Leitender Mitarbeiter der Abteilung zuweisen: +ADMIN_ASSIGN_DEPARTMENT_USER_OWNER=Benutzer als Besitzer der Abteilung zuweisen: +ADMIN_DEPARTMENT_COMPANY_REQUIRED=Bitte weisen Sie ein Unternehmen der Abteilung zu. +ADMIN_DEPARTMENT_NAME_REQUIRED=Bitte geben Sie der Abteilung einen Namen. Zum Beispiel: Verkauf, Personalwesen +BUTTON_ADMIN_ADD_DEPARTMENT_DATA=Abteilung hinzuf\u00fcgen +#@TODO Please fix German umlauts! +PAGE_TITLE_ADMIN_LIST_OPENING_TIMES=Oeffnungszeiten auflisten +#@TODO Please fix German umlauts! +CONTENT_TITLE_ADMIN_LIST_OPENING_TIMES=Auflisten von Oeffnungszeiten: +#@TODO Please fix German umlauts! +TABLE_SUMMARY_ADMIN_LIST_OPENING_TIMES=Diese Tabelle listet alle bereits angelegten Oeffnungszeiten auf. +#@TODO Please fix German umlauts! +ADMIN_EMPTY_LIST_OPENING_TIMES=Es befinden sich keine Oeffnungszeiten in der Datenbank. Oder Ihre Suche ergab keine Uebereinstimmungen. +LABEL_WEEK_DAYS=Wochentage +FILTER_BY_MULTIPLE_WEEK_DAYS_TITLE=Liste durch Auswahl von ein oder mehr Wochentagen durchsuchen. +#@TODO Please fix German umlauts! +ADMIN_LIST_OPENING_TIMES_HEADER=Liste aller Oeffnungszeiten +ADMIN_START_WEEK_DAY=Start-Wochentag: +ADMIN_END_WEEK_DAY=Endwochentag: +ADMIN_START_TIME=Startzeit: +ADMIN_END_TIME=Endezeit: +ADMIN_START_WEEK_DAY_REQUIRED=Bitte geben Sie den Startwochentag an. +ADMIN_END_WEEK_DAY_REQUIRED=Bitte geben Sie den Endwochentag an. +ADMIN_START_TIME_REQUIRED=Bitte geben Sie die Startzeit an. +ADMIN_END_TIME_REQUIRED=Bitte geben Sie die Endezeit an. +#@TODO Please fix German umlauts! +ADMIN_OPENING_TIME_LEGEND=Einzelne Oeffnungszeit: +ADMIN_OPENING_TIME_LEGEND_TITLE=Geben Sie die Daten einer einzelnen Oeffnungszeit an. +#@TODO Please fix German umlauts! +ADMIN_ADD_OPENING_TIME_TITLE=Oeffnungszeit hinzufuegen: +#@TODO Please fix German umlauts! +ADMIN_ADD_OPENING_TIME_MINIMUM_DATA=Bitte geben Sie zum Hinzufuegen einer Oeffnungszeit alle Angaben an. Diese sollten nicht konfliktieren. +BUTTON_ADMIN_ADD_OPENING_TIME=Oeffnungszeit hinzufuegen diff --git a/src/java/org/mxchange/localization/bundle_en_US.properties b/src/java/org/mxchange/localization/bundle_en_US.properties index 46cbe6ea..fd1c16c6 100644 --- a/src/java/org/mxchange/localization/bundle_en_US.properties +++ b/src/java/org/mxchange/localization/bundle_en_US.properties @@ -94,6 +94,7 @@ ADMIN_LINK_INDEX=Home ADMIN_LINK_LOGOUT=Logout ADMIN_LINK_TO_WEBPAGE=Call website ADMIN_LINK_FOOTER_TO_WEBPAGE=To website +ADMIN_LINK_FOOTER_TO_WEBPAGE_TITLE=This link goes to the guest area. GUEST_LINK_IMPRINT=Imprint GUEST_LINK_TERMS=T&C GUEST_LINK_PRIVACY=Privacy @@ -127,7 +128,7 @@ LOGIN_LINK_LOGOUT=Logout PAGE_TITLE_LOGIN_AREA=User area COUNTRY_GERMANY=Germany COUNTRY_PHILIPPINES=Philippines -NONE_SELECTED=Empty +NONE_SELECTED=None selected ENTERED_HOUSE_NUMBER_INVALID=The entered house number is invalid. ENTERED_ZIP_CODE_INVALID=The entered ZIP code is invalid. TABLE_HEADER_USER_LIST=List all users @@ -247,7 +248,7 @@ BUTTON_ADMIN_ADD_USER=Add new user account ADMIN_MENU_COUNTRY_TITLE=Country data ADMIN_LINK_LIST_COUNTRIES=Countries ADMIN_LINK_LIST_COUNTRIES_TITLE=List existing countries, add new country, edit and delete. -PAGE_TITLE_ADMIN_LIST_COUNTRY=Manage country data +PAGE_TITLE_ADMIN_LIST_COUNTRY=List country data CONTENT_TITLE_ADMIN_LIST_COUNTRY=List country data: ADMIN_ADD_COUNTRY_TITLE=Add new country ADMIN_COUNTRY_DATA_MINIMUM_NOTICE=Please fill out all fields. @@ -683,8 +684,8 @@ CONTENT_TITLE_ADMIN_DELETE_LAND_LINE_NUMBER=Delete land-line number: ADMIN_DELETE_LAND_LINE_NUMBER_TITLE=Dou you really want to delete following land-line number? ADMIN_DELETE_LAND_LINE_NUMBER_DATA_NOTICE=If you delete the land-line number, it won't be available anymore for anything. Please consider carefully if you really want this. BUTTON_ADMIN_DELETE_LAND_LINE_NUMBER=Delete land-line number -ADMIN_CONTACT_LIST_EMPTY=No contact data found in database. Or your search criteria doesn't match anything. -ADMIN_USER_LIST_EMPTY=No user data found in database. Or your search criteria doesn't match anything. +ADMIN_EMPTY_LIST_CONTACT=No contact data found in database. Or your search criteria doesn't match anything. +ADMIN_EMPTY_LIST_USER=No user data found in database. Or your search criteria doesn't match anything. ADMIN_PERSONAL_DATA_COMMENT=Comment: (optional) ADMIN_LINK_RESEND_USER_CONFIRMATION_LINK=Send new confirmation key ADMIN_LINK_RESEND_USER_CONFIRMATION_LINK_TITLE=Sends out a new confirmation link to the user's assigned email address. @@ -768,7 +769,7 @@ ADMIN_LINK_LIST_BASIC_COMPANY_DATA=Basic company data ADMIN_LINK_LIST_BASIC_COMPANY_DATA_TITLE=Lists basic company data. PAGE_TITLE_ADMIN_LIST_BASIC_COMPANY_DATA=List basic company data CONTENT_TITLE_ADMIN_LIST_BASIC_COMPANY_DATA=Lists basic company data -ADMIN_BASIC_COMPANY_DATA_LIST_EMPTY=There are currently no basic company data in database. Or your search criteria doesn't match anything. +ADMIN_EMPTY_LIST_BASIC_COMPANY_DATA=There are currently no basic company data in database. Or your search criteria doesn't match anything. TABLE_SUMMARY_ADMIN_LIST_BASIC_COMPANY_DATA=This table lists all basic company data. ADMIN_BASIC_COMPANY_DATA_ID=Id Number: ADMIN_LINK_SHOW_BASIC_COMAPNY_DATA_TITLE=Show details of this business contact. @@ -815,7 +816,7 @@ ADMIN_LINK_SHOW_BASIC_COMPANY_DATA_COMPANY_FOUNDER_TITLE=Show data of company fo ADMIN_LINK_ASSIGN_BASIC_COMPANY_DATA_COMPANY_FOUNDER_TITLE=Assigns a company founder to this company entry. ADMIN_BASIC_COMPANY_DATA_CREATED=Entry created ADMIN_USER_NAME_IS_REQUIRED=Please enter a user name. This must be unique. -NO_WEBSITE_URL_ENTERED=No URL entered +NO_WEBSITE_URL_ENTERED=No URL entered. ADMIN_LINK_LIST_BRANCH_OFFICES=Branch offices ADMIN_LINK_LIST_BRANCH_OFFICES_TITLE=Lists branch offices. ADMIN_ENTER_DATA_STORE=Enter store: @@ -827,7 +828,7 @@ ADMIN_BRANCH_OFFICE_DATA_LEGEND_TITLE=Enter branch office basic data here. ADMIN_ASSIGN_BRANCH_OFFICE_COMPANY=Assign branch office to company: PAGE_TITLE_ADMIN_LIST_BRANCH_OFFICES=List branch offices CONTENT_TITLE_ADMIN_LIST_BRANCH_OFFICES=List branch offices: -ADMIN_BRANCH_OFFICES_LIST_EMPTY=There are no branch offices found in database. Or your search criteria doesn't match anything. +ADMIN_EMPTY_LIST_BRANCH_OFFICES=There are no branch offices found in database. Or your search criteria doesn't match anything. ADMIN_ADD_BRANCH_OFFICE_TITLE=Add branch office #Bitte waehlen Sie mindestens das zugehoerige Unternehmen und das Land aus und geben Sie Strasse, Hausnummer, Postleitzahl und Stadt ein. ADMIN_ADD_BRANCH_OFFICE_MINIMUM_DATA=Please at least choose assigned company, country and enter at least street name, house number, ZIP code and city. @@ -853,36 +854,36 @@ NO_EMAIL_ADDRESS_ENTERED=No email address entered. DATA_ADDRESS=Address DATA_STORE=Store: DATA_SUITE_NUMBER=Suite number: -ADMIN_LINK_SHOW_LANDLINE_NUMBER_TITLE=Shows details to land-line number. -ADMIN_LINK_EDIT_LANDLINE_NUMBER_TITLE=Edit of land-line number. +ADMIN_LINK_SHOW_LANDLINE_NUMBER_TITLE=Shows details to a land-line number. +ADMIN_LINK_EDIT_LANDLINE_NUMBER_TITLE=Edit of a land-line number. ADMIN_LINK_UNLINK_LANDLINE_NUMBER_CONTACT_TITLE=Unlinks land-line number from contact. -ADMIN_LINK_DELETE_LANDLINE_NUMBER_TITLE=Deletes land-line number. +ADMIN_LINK_DELETE_LANDLINE_NUMBER_TITLE=Deletes a land-line number. ADMIN_LINK_UNLINK_MOBILE_NUMBER_CONTACT_TITLE=Unlinks mobile number from contact. -ADMIN_LINK_SHOW_MOBILE_NUMBER_TITLE=Shows details of mobile number. +ADMIN_LINK_SHOW_MOBILE_NUMBER_TITLE=Shows details of a mobile number. ADMIN_LINK_UNLINK_FAX_NUMBER_CONTACT_TITLE=Unlinks fax number from contact. -ADMIN_LINK_SHOW_FAX_NUMBER_TITLE=Shows details of fax number. -ADMIN_LINK_DELETE_MOBILE_NUMBER_TITLE=Deletes mobile mobile. -ADMIN_LINK_EDIT_MOBILE_NUMBER_TITLE=Edit of mobile number -ADMIN_LINK_DELETE_FAX_NUMBER_TITLE=Deletes fax number. -ADMIN_LINK_EDIT_FAX_NUMBER_TITLE=Edit of fax number. +ADMIN_LINK_SHOW_FAX_NUMBER_TITLE=Shows details of a fax number. +ADMIN_LINK_DELETE_MOBILE_NUMBER_TITLE=Deletes a mobile mobile. +ADMIN_LINK_EDIT_MOBILE_NUMBER_TITLE=Edit of a mobile number +ADMIN_LINK_DELETE_FAX_NUMBER_TITLE=Deletes a fax number. +ADMIN_LINK_EDIT_FAX_NUMBER_TITLE=Edit of a fax number. ADMIN_LINK_EDIT_BASIC_COMAPNY_DATA_TITLE=Edit of basic data of company. ADMIN_LINK_DELETE_BASIC_COMAPNY_DATA_TITLE=Deletes basic data of company. ADMIN_ACTION_LINKS=Actions: ADMIN_LINK_RESEND_CONFIRMATION_SHORT=Resend ADMIN_LINK_UNLOCK_SHORT=Unlock ADMIN_LINK_LOCK_SHORT=Lock -ADMIN_MOBILE_PROVIDER_LIST_EMPTY=There are no mobile providers in database. Or your search criteria doesn't match anything. -ADMIN_LINK_SHOW_MOBILE_PROVIDER_TITLE=Shows details of mobile provider. -ADMIN_LINK_EDIT_MOBILE_PROVIDER_TITLE=Edit of mobile provider. -ADMIN_LINK_DELETE_MOBILE_PROVIDER_TITLE=Deletes mobile provider. -ADMIN_LINK_SHOW_COUNTRY_TITLE=Show details of country. -ADMIN_LINK_EDIT_COUNTRY_TITLE=Edit of country. -ADMIN_LINK_DELETE_COUNTRY_TITLE=Deletes country. -ADMIN_COUNTRY_LIST_EMPTY=There are no countries in database. Or your search criteria doesn't match anything. -ADMIN_FAX_NUMBER_LIST_EMPTY=There are no fax numbers in database. Or your search criteria doesn't match anything. -ADMIN_LANDLINE_NUMBER_LIST_EMPTY=There are no land-line numbers in database. Or your search criteria doesn't match anything. -ADMIN_MOBILE_NUMBER_LIST_EMPTY=There are no mobile numbers in database. Or your search criteria doesn't match anything. -ADMIN_CONTACT_MOBILE_LIST_EMPTY=There are no mobile numbers of contacts in database. Or your search criteria doesn't match anything. +ADMIN_EMPTY_LIST_MOBILE_PROVIDER=There are no mobile providers in database. Or your search criteria doesn't match anything. +ADMIN_LINK_SHOW_MOBILE_PROVIDER_TITLE=Shows details of a mobile provider. +ADMIN_LINK_EDIT_MOBILE_PROVIDER_TITLE=Edit of a mobile provider. +ADMIN_LINK_DELETE_MOBILE_PROVIDER_TITLE=Deletes a mobile provider. +ADMIN_LINK_SHOW_COUNTRY_TITLE=Shows details of a country. +ADMIN_LINK_EDIT_COUNTRY_TITLE=Edit of a country. +ADMIN_LINK_DELETE_COUNTRY_TITLE=Deletes a country. +ADMIN_EMPTY_LIST_COUNTRY=There are no countries in database. Or your search criteria doesn't match anything. +ADMIN_EMPTY_LIST_FAX_NUMBER=There are no fax numbers in database. Or your search criteria doesn't match anything. +ADMIN_EMPTY_LIST_LANDLINE_NUMBER=There are no land-line numbers in database. Or your search criteria doesn't match anything. +ADMIN_EMPTY_LIST_MOBILE_NUMBER=There are no mobile numbers in database. Or your search criteria doesn't match anything. +ADMIN_EMPTY_LIST_CONTACT_MOBILE=There are no mobile numbers of contacts in database. Or your search criteria doesn't match anything. ADMIN_MOBILE_PROVIDER_COUNTRY_REQUIRED=Please select a country for mobile provider. LABEL_COUNTRIES=Countries #Filter list by selecting one or more users. @@ -907,9 +908,9 @@ PAYMENT_TYPE_PREPAYMENT=Prepayment PAYMENT_TYPE_INVOICE=Per invoice ADMIN_SELECT_SELLER_EMPLOYEE=Choose seller: LOGIN_SELECT_SELLER_EMPLOYEE=Please choose a seller: -ADMIN_LINK_SHOW_EMPLOYEE_TITLE=Shows data of an employee. +ADMIN_LINK_SHOW_EMPLOYEE_TITLE=Shows details of an employee. TABLE_SUMMARY_ADMIN_LIST_EMPLOYEES=This table lists all company employees. -ADMIN_EMPLOYEES_LIST_EMPTY=There are no company employees found in database. Or your search criteria doesn't match anything. +ADMIN_EMPTY_LIST_EMPLOYEES=There are no company employees found in database. Or your search criteria doesn't match anything. ADMIN_LIST_EMPLOYEES_HEADER=List all company employees ADMIN_LINK_LIST_EMPLOYEES=Employees ADMIN_LINK_LIST_EMPLOYEES_TITLE=Lists company employees @@ -945,3 +946,48 @@ ADMIN_LIST_BASIC_COMPANY_DATA_HEADER=List all company basic data ADMIN_LINK_LIST_DEPARTMENTS=Departments ADMIN_LINK_LIST_DEPARTMENTS_TITLE=Lists departments of companies. ADMIN_LINK_LIST_OPENING_TIMES=Opening times +PAGE_TITLE_ADMIN_LIST_DEPARTMENTS=List departments +CONTENT_TITLE_ADMIN_LIST_DEPARTMENTS=List departments: +ADMIN_EMPTY_LIST_DEPARTMENTS=There are no departments in database. Or your search criteria doesn't match anything. +ADMIN_LINK_SHOW_DEPARTMENT_TITLE=Shpws details of a department. +ADMIN_LINK_EDIT_DEPARTMENT_TITLE=Edit of a department +ADMIN_LINK_DELETE_DEPARTMENT_TITLE=Deletes a department. +ADMIN_DEPARTMENT_ALREADY_CREATED=The department already exists in selected company. +ADMIN_LIST_DEPARTMENTS_HEADER=List all departments +ADMIN_DEPARTMENT_NAME=Department: +ADMIN_DEPARTMENT_LEAD_EMPLOYEE=Department leader: +ADMIN_ADD_DEPARTMENT_TITLE=Add new department +ADMIN_DEPARTMENT_LEGEND=Enter data of department: +ADMIN_DEPARTMENT_LEGEND_TITLE=Here you can enter data of the new department. +#Bitte geben Sie mindestens den Namen der Abteilung (z.B. Verkauf) ein und waehlen Sie mindestens das Unternehmen aus. Wenn bekannt, waehlen Sie entweder eine Filiale oder eine Hauptniederlassung aus. +ADMIN_ADD_DEPARTMENT_MINIMUM_DATA=Please enter at least name of department (e.g. Sales) and choose assigned company. If known, choose a branch office or headquarters. +ADMIN_ENTER_DEPARTMENT_NAME=Enter name of department: +ADMIN_ASSIGN_DEPARTMENT_BRANCH_OFFICE=Assign branch office to department: +ADMIN_ASSIGN_DEPARTMENT_HEADQUARTERS=Assign headquarters to department: +ADMIN_ASSIGN_DEPARTMENT_COMPANY=Assign company to department: +ADMIN_ASSIGN_DEPARTMENT_LEAD_EMPLOYEE=Assign leading employee to department: +ADMIN_ASSIGN_DEPARTMENT_USER_OWNER=Assign owning user to department: +ADMIN_DEPARTMENT_COMPANY_REQUIRED=Please assign a company to this department. +ADMIN_DEPARTMENT_NAME_REQUIRED=Please enter a name for the department. Examples: Sales, Human Resources +BUTTON_ADMIN_ADD_DEPARTMENT_DATA=Add department +PAGE_TITLE_ADMIN_LIST_OPENING_TIMES=List opening times +CONTENT_TITLE_ADMIN_LIST_OPENING_TIMES=List opening times: +TABLE_SUMMARY_ADMIN_LIST_OPENING_TIMES=This table lists all opening times. +ADMIN_EMPTY_LIST_OPENING_TIMES=There are no opening times in database. Or your search criteria doesn't match anything. +LABEL_WEEK_DAYS=Week days +FILTER_BY_MULTIPLE_WEEK_DAYS_TITLE=Filter list by selecting one or more week days. +ADMIN_LIST_OPENING_TIMES_HEADER=List of all opening times +ADMIN_START_WEEK_DAY=Start week day: +ADMIN_END_WEEK_DAY=End week day: +ADMIN_START_TIME=Start time: +ADMIN_END_TIME=End time: +ADMIN_START_WEEK_DAY_REQUIRED=Please enter start week day. +ADMIN_END_WEEK_DAY_REQUIRED=Please enter end week day. +ADMIN_START_TIME_REQUIRED=Please enter start time. +ADMIN_END_TIME_REQUIRED=Please enter end time. +ADMIN_OPENING_TIME_LEGEND=Data of single opening time: +ADMIN_OPENING_TIME_LEGEND_TITLE=Enter data of single opening time. +ADMIN_ADD_OPENING_TIME_TITLE=Add new opening time: +#BItte geben Sie zum Hinzufuegen einer Oeffnungszeit alle Angaben an. Diese sollten nicht konfliktieren. +ADMIN_ADD_OPENING_TIME_MINIMUM_DATA=To add new opening time, you have to provide all data. They should not conflict. +BUTTON_ADMIN_ADD_OPENING_TIME=Add opening time diff --git a/web/WEB-INF/faces-config.xml b/web/WEB-INF/faces-config.xml index a41f05d9..c1f66e43 100644 --- a/web/WEB-INF/faces-config.xml +++ b/web/WEB-INF/faces-config.xml @@ -761,7 +761,7 @@ /admin/basic_company_data/admin_basic_company_data_assign_owner.xhtml - admin_show_business_employee + admin_show_employee /admin/company_employee/admin_company_employee_show.xhtml @@ -796,7 +796,7 @@ /admin/basic_company_data/admin_basic_company_data_show.xhtml - admin_show_business_employee + admin_show_employee /admin/company_employee/admin_company_employee_show.xhtml @@ -804,6 +804,41 @@ /admin/branch_office/admin_branch_office_assign_employee.xhtml + + /admin/department/admin_department_list.xhtml + + admin_show_department + /admin/department/admin_department_show.xhtml + + + admin_edit_department + /admin/department/admin_department_edit.xhtml + + + admin_delete_department + /admin/department/admin_department_delete.xhtml + + + admin_show_branch_office + /admin/branch_office/admin_branch_office_show.xhtml + + + admin_assign_department_branch_office + /admin/department/admin_assign_department_branch_office.xhtml + + + admin_show_employee + /admin/employee/admin_employee_show.xhtml + + + admin_assign_department_employee + /admin/department/admin_assign_department_employee.xhtml + + + admin_assign_department_user + /admin/department/admin_assign_department_user.xhtml + + /admin/employee/admin_employee_list.xhtml diff --git a/web/WEB-INF/links.jsf.taglib.xml b/web/WEB-INF/links.jsf.taglib.xml index 7a131f3d..a0841d5a 100644 --- a/web/WEB-INF/links.jsf.taglib.xml +++ b/web/WEB-INF/links.jsf.taglib.xml @@ -193,6 +193,29 @@ along with this program. If not, see . java.lang.Boolean + + outputDepartmentAdminMiniLinks + This tag renders administrative "mini-links" for given department instance. + resources/tags/admin/links/mini/department/admin_department_links.tpl + + department + The department instance that provides the data for this tag. + true + org.mxchange.jcontactsbusiness.model.department.Department + + + renderShowLink + Whether to render (default: true) "show department" link. + false + java.langBoolean + + + rendered + Whether this tag is being rendered by JSF engine (default: true). + false + java.lang.Boolean + + outputCompanyEmployeeAdminMiniLinks This tag renders administrative "mini-links" for given employee instance. @@ -216,6 +239,29 @@ along with this program. If not, see . java.lang.Boolean + + outputOpeningTimeAdminMiniLinks + This tag renders administrative "mini-links" for given opening time instance. + resources/tags/admin/links/mini/opening_time/admin_opening_time_links.tpl + + openingTime + The opening time instance that provides the data for this tag. + true + org.mxchange.jcontactsbusiness.model.opening_time.OpeningTimes + + + renderShowLink + Whether to render (default: true) "show opening time" link. + false + java.langBoolean + + + rendered + Whether this tag is being rendered by JSF engine (default: true). + false + java.lang.Boolean + + outputContactAdminMiniLinks This tag renders administrative "mini-links" for given contact instance. diff --git a/web/WEB-INF/resources/tags/admin/links/mini/department/admin_department_links.tpl b/web/WEB-INF/resources/tags/admin/links/mini/department/admin_department_links.tpl new file mode 100644 index 00000000..82e11453 --- /dev/null +++ b/web/WEB-INF/resources/tags/admin/links/mini/department/admin_department_links.tpl @@ -0,0 +1,33 @@ + + + + +

+ + diff --git a/web/WEB-INF/resources/tags/admin/links/mini/opening_time/admin_opening_time_links.tpl b/web/WEB-INF/resources/tags/admin/links/mini/opening_time/admin_opening_time_links.tpl new file mode 100644 index 00000000..18c56c79 --- /dev/null +++ b/web/WEB-INF/resources/tags/admin/links/mini/opening_time/admin_opening_time_links.tpl @@ -0,0 +1,33 @@ + + + + + + + diff --git a/web/WEB-INF/resources/tags/input/panel_grid/fax_input_panel_grid.tpl b/web/WEB-INF/resources/tags/input/panel_grid/fax_input_panel_grid.tpl index 27d2c3dd..f7306814 100644 --- a/web/WEB-INF/resources/tags/input/panel_grid/fax_input_panel_grid.tpl +++ b/web/WEB-INF/resources/tags/input/panel_grid/fax_input_panel_grid.tpl @@ -7,9 +7,9 @@ xmlns:p="http://primefaces.org/ui"> - + - + diff --git a/web/WEB-INF/resources/tags/input/panel_grid/landline_input_panel_grid.tpl b/web/WEB-INF/resources/tags/input/panel_grid/landline_input_panel_grid.tpl index 945493b4..517ebe42 100644 --- a/web/WEB-INF/resources/tags/input/panel_grid/landline_input_panel_grid.tpl +++ b/web/WEB-INF/resources/tags/input/panel_grid/landline_input_panel_grid.tpl @@ -7,9 +7,9 @@ xmlns:p="http://primefaces.org/ui"> - + - + diff --git a/web/WEB-INF/resources/tags/table_rows/fax_input_table_row.tpl b/web/WEB-INF/resources/tags/table_rows/fax_input_table_row.tpl index 0240d378..5d7bbcba 100644 --- a/web/WEB-INF/resources/tags/table_rows/fax_input_table_row.tpl +++ b/web/WEB-INF/resources/tags/table_rows/fax_input_table_row.tpl @@ -10,8 +10,8 @@ - - + + diff --git a/web/WEB-INF/resources/tags/table_rows/landline_input_table_row.tpl b/web/WEB-INF/resources/tags/table_rows/landline_input_table_row.tpl index 262ab7ba..c61aac21 100644 --- a/web/WEB-INF/resources/tags/table_rows/landline_input_table_row.tpl +++ b/web/WEB-INF/resources/tags/table_rows/landline_input_table_row.tpl @@ -10,8 +10,8 @@ - - + + diff --git a/web/WEB-INF/templates/admin/admin_footer.tpl b/web/WEB-INF/templates/admin/admin_footer.tpl index dfdfde4f..e5a3b6e9 100644 --- a/web/WEB-INF/templates/admin/admin_footer.tpl +++ b/web/WEB-INF/templates/admin/admin_footer.tpl @@ -9,7 +9,7 @@ diff --git a/web/WEB-INF/templates/admin/branch_office/admin_form_branch_office_data.tpl b/web/WEB-INF/templates/admin/branch_office/admin_form_branch_office_data.tpl index a356ca10..778e60a7 100644 --- a/web/WEB-INF/templates/admin/branch_office/admin_form_branch_office_data.tpl +++ b/web/WEB-INF/templates/admin/branch_office/admin_form_branch_office_data.tpl @@ -22,7 +22,7 @@ requiredMessage="#{msg.ADMIN_BRANCH_OFFICE_COMPANY_REQUIRED}" > - + diff --git a/web/WEB-INF/templates/admin/contact/admin_show_contact_data.tpl b/web/WEB-INF/templates/admin/contact/admin_show_contact_data.tpl index 70ba78a7..0fd48407 100644 --- a/web/WEB-INF/templates/admin/contact/admin_show_contact_data.tpl +++ b/web/WEB-INF/templates/admin/contact/admin_show_contact_data.tpl @@ -4,9 +4,14 @@ xmlns:widgets="http://mxchange.org/jsf/core/widgets" xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html" - xmlns:ui="http://xmlns.jcp.org/jsf/facelets"> + xmlns:ui="http://xmlns.jcp.org/jsf/facelets" + xmlns:p="http://primefaces.org/ui" + > - + + diff --git a/web/WEB-INF/templates/admin/department/admin_form_department_data.tpl b/web/WEB-INF/templates/admin/department/admin_form_department_data.tpl new file mode 100644 index 00000000..fb18bf89 --- /dev/null +++ b/web/WEB-INF/templates/admin/department/admin_form_department_data.tpl @@ -0,0 +1,81 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/web/WEB-INF/templates/admin/employee/admin_form_employee_data.tpl b/web/WEB-INF/templates/admin/employee/admin_form_employee_data.tpl index 01164486..2ebc4023 100644 --- a/web/WEB-INF/templates/admin/employee/admin_form_employee_data.tpl +++ b/web/WEB-INF/templates/admin/employee/admin_form_employee_data.tpl @@ -22,7 +22,7 @@ requiredMessage="#{msg.ADMIN_EMPLOYEE_COMPANY_REQUIRED}" > - + @@ -34,7 +34,7 @@ filterMatchMode="contains" > - + @@ -89,8 +89,8 @@ filterMatchMode="contains" > - - + + @@ -101,7 +101,7 @@ filterMatchMode="contains" > - + diff --git a/web/WEB-INF/templates/admin/fax/admin_form_add_contact_fax.tpl b/web/WEB-INF/templates/admin/fax/admin_form_add_contact_fax.tpl index c5f81e08..671722d5 100644 --- a/web/WEB-INF/templates/admin/fax/admin_form_add_contact_fax.tpl +++ b/web/WEB-INF/templates/admin/fax/admin_form_add_contact_fax.tpl @@ -25,7 +25,7 @@
- + @@ -40,7 +40,7 @@ diff --git a/web/WEB-INF/templates/admin/landline/admin_form_add_contact_landline.tpl b/web/WEB-INF/templates/admin/landline/admin_form_add_contact_landline.tpl index fbf14e51..f1010546 100644 --- a/web/WEB-INF/templates/admin/landline/admin_form_add_contact_landline.tpl +++ b/web/WEB-INF/templates/admin/landline/admin_form_add_contact_landline.tpl @@ -25,7 +25,7 @@
- + @@ -40,7 +40,7 @@
- + @@ -37,10 +37,11 @@
- + +
- +
@@ -163,9 +168,9 @@
- + - + @@ -189,9 +194,9 @@
- + - + @@ -209,7 +214,8 @@ - + + diff --git a/web/WEB-INF/templates/guest/user/guest_login_form.tpl b/web/WEB-INF/templates/guest/user/guest_login_form.tpl index 185c785a..01c94d24 100644 --- a/web/WEB-INF/templates/guest/user/guest_login_form.tpl +++ b/web/WEB-INF/templates/guest/user/guest_login_form.tpl @@ -48,7 +48,7 @@ diff --git a/web/WEB-INF/templates/guest/user/register/guest_form_register_page1.tpl b/web/WEB-INF/templates/guest/user/register/guest_form_register_page1.tpl index 392136e2..1f1bb430 100644 --- a/web/WEB-INF/templates/guest/user/register/guest_form_register_page1.tpl +++ b/web/WEB-INF/templates/guest/user/register/guest_form_register_page1.tpl @@ -85,7 +85,7 @@ diff --git a/web/WEB-INF/templates/guest/user/register/guest_form_register_page2.tpl b/web/WEB-INF/templates/guest/user/register/guest_form_register_page2.tpl index 0286393a..f1a04346 100644 --- a/web/WEB-INF/templates/guest/user/register/guest_form_register_page2.tpl +++ b/web/WEB-INF/templates/guest/user/register/guest_form_register_page2.tpl @@ -15,7 +15,7 @@ diff --git a/web/WEB-INF/templates/guest/user/register/guest_form_register_single.tpl b/web/WEB-INF/templates/guest/user/register/guest_form_register_single.tpl index 711fd8fa..924a5103 100644 --- a/web/WEB-INF/templates/guest/user/register/guest_form_register_single.tpl +++ b/web/WEB-INF/templates/guest/user/register/guest_form_register_single.tpl @@ -89,7 +89,7 @@ diff --git a/web/admin/basic_company_data/admin_basic_company_data_list.xhtml b/web/admin/basic_company_data/admin_basic_company_data_list.xhtml index 1bb9a2ac..e3059b2c 100644 --- a/web/admin/basic_company_data/admin_basic_company_data_list.xhtml +++ b/web/admin/basic_company_data/admin_basic_company_data_list.xhtml @@ -32,21 +32,19 @@ rowsPerPageTemplate="5,10,20,50,100" sortMode="multiple" summary="#{msg.TABLE_SUMMARY_ADMIN_LIST_BASIC_COMPANY_DATA}" - emptyMessage="#{msg.ADMIN_BASIC_COMPANY_DATA_LIST_EMPTY}" + emptyMessage="#{msg.ADMIN__EMPTY_LISTBASIC_COMPANY_DATA}" widgetVar="basicDataList" > - - - - + + - + - - + + @@ -104,7 +102,7 @@ - + @@ -129,7 +127,7 @@ - + @@ -150,7 +148,7 @@ - + @@ -165,7 +163,7 @@ diff --git a/web/admin/branch_office/admin_branch_office_list.xhtml b/web/admin/branch_office/admin_branch_office_list.xhtml index 8d474b63..1b0fca22 100644 --- a/web/admin/branch_office/admin_branch_office_list.xhtml +++ b/web/admin/branch_office/admin_branch_office_list.xhtml @@ -32,21 +32,19 @@ rowsPerPageTemplate="5,10,20,50,100" sortMode="multiple" summary="#{msg.TABLE_SUMMARY_ADMIN_LIST_BRANCH_OFFICES}" - emptyMessage="#{msg.ADMIN_BRANCH_OFFICES_LIST_EMPTY}" + emptyMessage="#{msg.ADMIN_EMPTY_LIST_BRANCH_OFFICES}" widgetVar="branchOfficeList" > - - - - + + - + - - + + @@ -82,7 +80,14 @@ - + @@ -105,16 +110,23 @@ - + - + - + - + @@ -135,7 +147,7 @@ - + @@ -150,7 +162,7 @@ diff --git a/web/admin/contact/admin_contact_delete.xhtml b/web/admin/contact/admin_contact_delete.xhtml index 2be5d7ff..ead8fde4 100644 --- a/web/admin/contact/admin_contact_delete.xhtml +++ b/web/admin/contact/admin_contact_delete.xhtml @@ -40,7 +40,7 @@ diff --git a/web/admin/contact/admin_contact_edit.xhtml b/web/admin/contact/admin_contact_edit.xhtml index 11692efc..ddae0a2f 100644 --- a/web/admin/contact/admin_contact_edit.xhtml +++ b/web/admin/contact/admin_contact_edit.xhtml @@ -40,7 +40,7 @@ diff --git a/web/admin/contact/admin_contact_export.xhtml b/web/admin/contact/admin_contact_export.xhtml index d4fac88e..3b506de8 100644 --- a/web/admin/contact/admin_contact_export.xhtml +++ b/web/admin/contact/admin_contact_export.xhtml @@ -17,7 +17,16 @@ - + diff --git a/web/admin/contact/admin_contact_list.xhtml b/web/admin/contact/admin_contact_list.xhtml index 6ca9c357..a4f8f277 100644 --- a/web/admin/contact/admin_contact_list.xhtml +++ b/web/admin/contact/admin_contact_list.xhtml @@ -26,7 +26,7 @@ paginator="true" rows="10" summary="#{msg.TABLE_SUMMARY_ADMIN_LIST_CONTACT}" - emptyMessage="#{msg.ADMIN_CONTACT_LIST_EMPTY}" + emptyMessage="#{msg.ADMIN_EMPTY_LIST_CONTACT}" widgetVar="contactList" > @@ -91,7 +91,7 @@ - + @@ -103,7 +103,7 @@ diff --git a/web/admin/country/admin_country_list.xhtml b/web/admin/country/admin_country_list.xhtml index cf21667f..f74bb080 100644 --- a/web/admin/country/admin_country_list.xhtml +++ b/web/admin/country/admin_country_list.xhtml @@ -25,7 +25,7 @@ paginator="true" rows="10" summary="#{msg.TABLE_SUMMARY_ADMIN_LIST_COUNTRIES}" - emptyMessage="#{msg.ADMIN_COUNTRY_LIST_EMPTY}" + emptyMessage="#{msg.ADMIN_EMPTY_LIST_COUNTRY}" widgetVar="countryList" > @@ -82,7 +82,7 @@