Skip to content

date_end of calls is not stored correctly in the database #9985

Open
@QuickCRM

Description

@QuickCRM

date_end of calls is stored as date_start if duration_hours is 0 or duration_minutes is 0

Issue

Expected Behavior

date_end should depend on duration

Actual Behavior

date_end = date_start in the database

Possible Fix

in Calls save function, replace
if (!empty($this->duration_hours) && !empty($this->duration_minutes)) {
by
if (!empty($this->duration_hours) || !empty($this->duration_minutes)) {

Steps to Reproduce

  1. Create a call with duration = 15mn
  2. Look at that call in the database
  3. date_end is equal to date_start

Context

Your Environment

  • SuiteCRM Version used: 7.12.10
  • Browser name and version (e.g. Chrome Version 51.0.2704.63 (64-bit)): any
  • Environment name and version (e.g. MySQL, PHP 7): PHP 7.4
  • Operating System and version (e.g Ubuntu 16.04):

Metadata

Metadata

Assignees

No one assigned

    Labels

    Area: ModuleIssues & PRs related to modules that do not have specific labelPriority:ImportantIssues & PRs that are important; broken functions, errors - there are workaroundsStatus:Fix ProposedA issue that has a PR related to it that provides a possible resolutionType: BugBugs within the core SuiteCRM codebase

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions