mirror of
https://github.com/FH-Complete/FHC-Core.git
synced 2026-07-22 01:12:17 +00:00
fixes little bug where status timestamp was converted from null to the current date, with create_date in php
This commit is contained in:
@@ -72,8 +72,7 @@ class Profil extends Auth_Controller
|
||||
$_GET = json_decode($this->input->raw_input_stream, true);
|
||||
$uid = $this->input->get('uid');
|
||||
$id = $this->input->get('id');
|
||||
echo $uid;
|
||||
echo $id;
|
||||
|
||||
|
||||
if($uid && $id){
|
||||
$res= $this->ProfilChangeModel->getProfilUpdate($uid, $id);
|
||||
|
||||
@@ -46,10 +46,11 @@ class Profil_change_model extends DB_Model
|
||||
// catch error
|
||||
}else{
|
||||
if(hasData($res)){
|
||||
|
||||
foreach($res->retval as $update){
|
||||
$update->requested_change = json_decode($update->requested_change);
|
||||
$update->change_timestamp = date_create($update->change_timestamp)->format('d.m.Y');
|
||||
$update->status_timestamp = date_create($update->status_timestamp)->format('d.m.Y');
|
||||
$update->change_timestamp = !is_null($update->change_timestamp)?date_create($update->change_timestamp)->format('d.m.Y'):null;
|
||||
$update->status_timestamp = !is_null($update->status_timestamp)?date_create($update->status_timestamp)->format('d.m.Y'):null;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user