Hi,
I have a custom object. I have a startTime and an endTime field that are used to calculate a duration field. I display all 3 fields on the list view. If startTime is populated but endTime is null, The endTime field is displaying the startTime value. In the form view the value starts out populated and then updates to be None.
The JSON data does not have a value in the endTime field.
Does anyone have any suggestions on how I can fix this or is it a bug? I am using version 6.1.7
I have a custom object. I have a startTime and an endTime field that are used to calculate a duration field. I display all 3 fields on the list view. If startTime is populated but endTime is null, The endTime field is displaying the startTime value. In the form view the value starts out populated and then updates to be None.
The JSON data does not have a value in the endTime field.
Does anyone have any suggestions on how I can fix this or is it a bug? I am using version 6.1.7
PHP Code:
Response Data:
{"total":1,"list":[{"id":"61223059a567a3e69","name":"A","createdAt":" 2021-08-22 11:09:13","startTime":"2021-08-22 11:09:00","endTime":null,"duration":null,"createdB yId":"2","createdByName":"Mythradon Admin","assignedUserId":"2","parentId":"6044a4000c 590d9ba","parentType":"Account","parentName":"Fine Defective"}]}
Entity Def:
"startTime": {
"notNull": false,
"type": "datetime",
"required": true,
"default": "javascript: return this.dateTime.getNow(1);",
"readOnly": true,
"customizationDisabled": true
},
"endTime": {
"type": "datetimeOptional",
"view": "crm:views/task/fields/date-end",
"readOnly": true,
"customizationDisabled": true
},
"duration": {
"type": "duration",
"start": "startTime",
"end": "endTime",
"options": [
300,
600,
900,
1800,
2700,
3600,
7200
],
"notStorable": true,
"select": {
"select": "TIMESTAMPDIFF_SECOND:(startTime, endTime)"
},
"order": {
"order": [
[
"TIMESTAMPDIFF_SECOND:(startTime, endTime)",
"{direction}"
]
]
}
},
Comment