Don't attach new emails to closed cases

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • VikinGDM
    Member
    • Feb 2019
    • 92

    Don't attach new emails to closed cases

    Hi everyone!
    I would like to suggest additional feature request

    When a client writes a email support, very often he don't change the title of the email from the previous case.
    When this email arrives, it is automatically linked by the old number to the old case.
    PHP Code:
    if (preg_match('/\[#([0-9]+)[^0-9]*\]/', $email->get('name'), $m)) {
    $caseNumber = $m[1];
    $case = $this->entityManager
    ->getRDBRepository('Case')
    ->where([
    'number' => $caseNumber,
    ])
    ->findOne(); 
    
    I propose to add a setting to group mailboxes - excluding cases statuses. Then will remove the old number from the email header.
    As example:
    Code:
    { "type": "notin", "attribute": "status", "value": ["Closed"] }
Working...