Forum

Welcome to ProjeQtOr new Forum. We migrated old forum to the new website.
You will find all your posts here, with your usual account.
Just one point : you’ll have to reinitialize your password. Use “Lost password” feature.

Result Handling
 
Notifications
Clear all

Result Handling

2 Posts
2 Users
0 Reactions
3,542 Views
(@antonio-grr)
Posts: 84
Active Member
Topic starter
 
[#4412]

Hi.
In order to get a more flexible handling of save/update/delete result I introduced a component like ResultHdl in attachment and in SqlElement I added the functions listed in resultcall.txt in attachment.
Now getLastOperationStatus status is useless or can be reduced as

public function getLastOperationStatus($result)
{
return $result->status;
}

The function displayLastOperationStatus changes to

public function displayLastOperationStatus($result)
{
if ($result->status == "OK" or $result->status == "NO_CHANGE" or $result->status == "INCOMPLETE") {
Sql::commitTransaction();
} else {
Sql::rollbackTransaction();
}
echo $result->formatMessage();
return $result->status;
}


 
Posted : 14 Jun 2017 10H41
babynus
(@babynus)
Posts: 14966
Main Contributor Admin
 

Your proposale hase been integrated (not used yet)


 
Posted : 19 Jun 2017 21H20
Share:

Scroll to Top