Package de.xima.fc.gui.model.appointment
Class AppointmentClientClosingTimeModel
java.lang.Object
de.xima.fc.gui.model.appointment.AAppointmentClosingTimeModel<AppointmentClientClosingTime>
de.xima.fc.gui.model.appointment.AppointmentClientClosingTimeModel
- All Implemented Interfaces:
Serializable
public final class AppointmentClientClosingTimeModel
extends AAppointmentClosingTimeModel<AppointmentClientClosingTime>
The view model for the
AppointmentClientClosingTime
.- Since:
- 8.0.0
- Author:
- XIMA MEDIA GmbH
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionAppointmentClientClosingTimeModel
(Mandant client, AppointmentTemplate template) Creates a new empty model without any closing times. -
Method Summary
Modifier and TypeMethodDescriptionprotected void
addSubtypePropertiesToItem
(AppointmentClientClosingTime item, com.alibaba.fastjson.JSONObject json) When deserializing the JSON data received from the client.protected void
addSubtypePropertiesToJson
(com.alibaba.fastjson.JSONObject json, AppointmentClientClosingTime item) When serializing an entity as JSON for the client.protected boolean
Compares two closing times for whether they are equal.protected AppointmentClientClosingTime
protected AppointmentClientClosingTime
Creates a new, non-persisted entity and sets all fields required by the sub type (such as a reference to aclient
etc.).protected de.xima.cmn.criteria.QueryCriteriaManager
Creates the query criteria manager with the filter and sorting criteria for reading all applicable closing time entities from the database.Methods inherited from class de.xima.fc.gui.model.appointment.AAppointmentClosingTimeModel
add, addNew, getAllJsonString, loadAll, removeRows, save, setAllJsonString
-
Constructor Details
-
AppointmentClientClosingTimeModel
Creates a new empty model without any closing times.- Parameters:
client
- The currentclient
scope.template
- The appointment template to which the closing times belong.
-
-
Method Details
-
addSubtypePropertiesToItem
protected void addSubtypePropertiesToItem(AppointmentClientClosingTime item, com.alibaba.fastjson.JSONObject json) Description copied from class:AAppointmentClosingTimeModel
When deserializing the JSON data received from the client. This method should read all properties from the JSON object that are not contained inAAppointmentClosingTime
, and add those to the entity.- Specified by:
addSubtypePropertiesToItem
in classAAppointmentClosingTimeModel<AppointmentClientClosingTime>
- Parameters:
item
- The entity to which the data should be added.json
- JSON data for the item as received from the client.
-
addSubtypePropertiesToJson
protected void addSubtypePropertiesToJson(com.alibaba.fastjson.JSONObject json, AppointmentClientClosingTime item) Description copied from class:AAppointmentClosingTimeModel
When serializing an entity as JSON for the client. This method should add all properties from the sub type not contained inAAppointmentClosingTime
to the JSON object.- Specified by:
addSubtypePropertiesToJson
in classAAppointmentClosingTimeModel<AppointmentClientClosingTime>
- Parameters:
json
- JSON object which will be passed to the client.item
- Entity with the data to add to the JSON object.
-
areSubtypePropertiesEqual
protected boolean areSubtypePropertiesEqual(AppointmentClientClosingTime x, AppointmentClientClosingTime y) Description copied from class:AAppointmentClosingTimeModel
Compares two closing times for whether they are equal. Implementation only need to check for properties not present in theAAppointmentClosingTime
.- Specified by:
areSubtypePropertiesEqual
in classAAppointmentClosingTimeModel<AppointmentClientClosingTime>
- Parameters:
x
- One item to check.y
- Another item to check.- Returns:
- Whether the properties of two items are equal.
-
cloneItem
- Specified by:
cloneItem
in classAAppointmentClosingTimeModel<AppointmentClientClosingTime>
- Parameters:
item
- An item to clone.- Returns:
- A clone of the basic properties of the closing time, without the ID / UUID / locking version etc.
-
createNew
Description copied from class:AAppointmentClosingTimeModel
Creates a new, non-persisted entity and sets all fields required by the sub type (such as a reference to aclient
etc.).- Specified by:
createNew
in classAAppointmentClosingTimeModel<AppointmentClientClosingTime>
- Returns:
- A new closing time entity.
-
getFetchAllCriteria
protected de.xima.cmn.criteria.QueryCriteriaManager getFetchAllCriteria()Description copied from class:AAppointmentClosingTimeModel
Creates the query criteria manager with the filter and sorting criteria for reading all applicable closing time entities from the database.- Specified by:
getFetchAllCriteria
in classAAppointmentClosingTimeModel<AppointmentClientClosingTime>
- Returns:
- A criteria manager for fetching all applicable entities.
-