Beispiel #1
0
 /**
  * Get the toolbar to render.
  *
  * @return RToolbar
  */
 public function getToolbar()
 {
     $group = new RToolbarButtonGroup();
     if (empty($this->item->id)) {
         $cancel = RToolbarBuilder::createCancelButton('payment_log.cancel');
     } else {
         $cancel = RToolbarBuilder::createCloseButton('payment_log.cancel');
     }
     $group->addButton($cancel);
     $toolbar = new RToolbar();
     $toolbar->addGroup($group);
     return $toolbar;
 }
Beispiel #2
0
 /**
  * Get the toolbar to render.
  *
  * @return  RToolbar
  */
 public function getToolbar()
 {
     $group = new RToolbarButtonGroup();
     $secondGroup = new RToolbarButtonGroup();
     $user = JFactory::getUser();
     if ($user->authorise('core.admin', 'com_redcore')) {
         $save = RToolbarBuilder::createSaveButton('config.apply');
         $saveAndClose = RToolbarBuilder::createSaveAndCloseButton('config.save');
         $group->addButton($save)->addButton($saveAndClose);
     }
     $cancel = RToolbarBuilder::createCloseButton('config.cancel');
     $group->addButton($cancel);
     $toolbar = new RToolbar();
     $toolbar->addGroup($group)->addGroup($secondGroup);
     return $toolbar;
 }
Beispiel #3
0
 /**
  * Get the toolbar to render.
  *
  * @return  RToolbar
  */
 public function getToolbar()
 {
     $canDo = OpenHrmHelpersAcl::getActions($this->state->get('filter.country_id'));
     $user = JFactory::getUser();
     $firstGroup = new RToolbarButtonGroup();
     $secondGroup = new RToolbarButtonGroup();
     if ($user->authorise('core.admin', 'com_openhrm.panel')) {
         $save = RToolbarBuilder::createSaveButton('organizationinfo.apply');
         $saveClose = RToolbarBuilder::createSaveAndCloseButton('organizationinfo.save');
         $firstGroup->addButton($save)->addButton($saveClose);
         $cancel = RToolbarBuilder::createCloseButton('organizationinfo.close');
         $secondGroup->addButton($cancel);
     }
     $toolbar = new RToolbar();
     $toolbar->addGroup($firstGroup)->addGroup($secondGroup);
     return $toolbar;
 }
Beispiel #4
0
 /**
  * Get the toolbar to render.
  *
  * @return  RToolbar
  */
 public function getToolbar()
 {
     $group = new RToolbarButtonGroup();
     $save = RToolbarBuilder::createSaveButton('team.apply');
     $saveAndClose = RToolbarBuilder::createSaveAndCloseButton('team.save');
     $saveAndNew = RToolbarBuilder::createSaveAndNewButton('team.save2new');
     $save2Copy = RToolbarBuilder::createSaveAsCopyButton('team.save2copy');
     $group->addButton($save)->addButton($saveAndClose)->addButton($saveAndNew)->addButton($save2Copy);
     if (empty($this->item->id)) {
         $cancel = RToolbarBuilder::createCancelButton('team.cancel');
     } else {
         $cancel = RToolbarBuilder::createCloseButton('team.cancel');
     }
     $group->addButton($cancel);
     $toolbar = new RToolbar();
     $toolbar->addGroup($group);
     return $toolbar;
 }
Beispiel #5
0
 /**
  * Get the toolbar to render.
  *
  * @return  RToolbar
  */
 public function getToolbar()
 {
     $group = new RToolbarButtonGroup();
     $user = JFactory::getUser();
     if ($user->authorise('core.admin', 'com_jab.panel')) {
         $save = RToolbarBuilder::createSaveButton('state.apply');
         $saveAndClose = RToolbarBuilder::createSaveAndCloseButton('state.save');
         $saveAndNew = RToolbarBuilder::createSaveAndNewButton('state.save2new');
         $group->addButton($save)->addButton($saveAndClose)->addButton($saveAndNew);
     }
     if (empty($this->item->id)) {
         $cancel = RToolbarBuilder::createCancelButton('state.cancel');
     } else {
         $cancel = RToolbarBuilder::createCloseButton('state.cancel');
     }
     $group->addButton($cancel);
     $toolbar = new RToolbar();
     $toolbar->addGroup($group);
     return $toolbar;
 }
Beispiel #6
0
 /**
  * Get the toolbar to render.
  *
  * @todo	We have setup ACL requirements for Dummy
  *
  * @return  RToolbar
  */
 public function getToolbar()
 {
     $group1 = new RToolbarButtonGroup();
     $save = RToolbarBuilder::createSaveButton('object.apply');
     $saveAndClose = RToolbarBuilder::createSaveAndCloseButton('object.save');
     $saveAndNew = RToolbarBuilder::createSaveAndNewButton('object.save2new');
     $group1->addButton($save);
     $group2 = new RToolbarButtonGroup();
     $group2->addButton($saveAndClose);
     $group3 = new RToolbarButtonGroup();
     $group3->addButton($saveAndNew);
     if (empty($this->item->id)) {
         $cancel = RToolbarBuilder::createCancelButton('object.cancel');
     } else {
         $cancel = RToolbarBuilder::createCloseButton('object.cancel');
     }
     $group5 = new RToolbarButtonGroup();
     $group5->addButton($cancel);
     $toolbar = new RToolbar();
     $toolbar->addGroup($group1)->addGroup($group2)->addGroup($group3)->addGroup($group5);
     return $toolbar;
 }