if (!isset($_POST[$col])) continue;
$row[$col] = $_POST[$col] ?: NULL;
}
+ if (isset($_POST['status'])) {
+ $reset = !empty($_POST['status']);
+ if (isset($Issue->closed) !== $reset) {
+ $row['closed'] = $reset ? ['now()'] : NULL;
+ }
+ }
$Db->set('issues', $row, ['id = ?', $Issue->id]);
}
$_POST['reply'] = NULL;
'Toegewezen aan',
htmlspecialchars($Issue->assign ?? '')
);
+ printf(
+ '<input type="hidden" name="%s" value="" />' .
+ '<input type="checkbox" id="%1$s" name="%1$s" value="%s"%s />'
+ . '<label for="%1$s"> %s</label>'."\n",
+ 'status',
+ 'resolved',
+ isset($Issue->closed) ? ' checked' : '',
+ 'Gesloten'
+ );
print "</p>\n";
}
printf('<textarea id="%s" name="%1$s" cols=60 rows=3 placeholder="%s">%s</textarea>'."\n",