fixed email fetching utf8

This commit is contained in:
Luca Haid
2024-11-12 14:09:02 +01:00
parent acf7dc151e
commit 24676a67a0
2 changed files with 59 additions and 10 deletions

View File

@@ -70,7 +70,8 @@ class TTCrud extends mfBaseController {
"CREATE_URL" => $this::getUrl($this->mod . "/create"),
"TABLE_URL" => $this::getUrl($this->mod . "/get"),
"UPDATE_URL" => $this::getUrl($this->mod . "/update"),
"DELETE_URL" => $this::getUrl($this->mod . "/delete"),]);
"DELETE_URL" => $this::getUrl($this->mod . "/delete"),
"USER_ID" => $this->user->id]);
}
/**
@@ -189,6 +190,13 @@ class TTCrud extends mfBaseController {
}
protected function updateAction() {
if (property_exists($this->model, 'createBy') && !isset($this->postData['createBy'])) {
$this->postData['createBy'] = $this->user->id;
}
if (property_exists($this->model, 'create') && !isset($this->postData['create'])) {
$this->postData['create'] = time();
}
Helper::validateArray($this->postData, array_merge($this->checkArray, ['id' => ['required' => true]]));
if (method_exists($this, 'beforeUpdate') && !$this->beforeUpdate($this->postData)) {