×
Please submit new Bug Reports on GitHub: github.com/Jensen-Technologies/component-creator-issues/issues
Possible Bug? 'Item Saved Successfully'
Gary Hurdman
New Member
Posts: 6
2 年 2 个月 前 #9994
由 Gary Hurdman
Possible Bug? 'Item Saved Successfully' was created by Gary Hurdman
Hi,
I think I have found a bug.
in the Model when a form is NOT saved because FALSE was passed back to the controller
public function save($data)
{...
.
.
if ($status !=6 && $status !=7)
{
$app->enqueueMessage(Text::_('WARNING! - This trader has is neither Casual or licensed - Status = '.$status), 'warning');
return false; //Don't save this data.
}
.
.
}
In the controller:
The 'Item Saved Successfully' message is always shown
I think it should be like this...
public function save($key = NULL, $urlVar = NULL)
{
.
.
.
.
// Check in the profile.
if ($return)
{
$model->checkin($return);
$this->setMessage(Text::_('COM_BCC_MACCS_MARKET_STALLS_ITEM_SAVED_SUCCESSFULLY'));
}
There doesn't appear to be any condition around the message otherwise???
Cheers - Paul
I think I have found a bug.
in the Model when a form is NOT saved because FALSE was passed back to the controller
public function save($data)
{...
.
.
if ($status !=6 && $status !=7)
{
$app->enqueueMessage(Text::_('WARNING! - This trader has is neither Casual or licensed - Status = '.$status), 'warning');
return false; //Don't save this data.
}
.
.
}
In the controller:
The 'Item Saved Successfully' message is always shown
I think it should be like this...
public function save($key = NULL, $urlVar = NULL)
{
.
.
.
.
// Check in the profile.
if ($return)
{
$model->checkin($return);
$this->setMessage(Text::_('COM_BCC_MACCS_MARKET_STALLS_ITEM_SAVED_SUCCESSFULLY'));
}
There doesn't appear to be any condition around the message otherwise???
Cheers - Paul
Please 登录 或 注册一个帐号 to join the conversation.
创建页面时间:0.090秒