TRUE, 'edit'=>TRUE, ); /** * Add Export Maping items */ public function action_add() { $eo = ORM::factory('export'); $output = ''; if ($_POST AND $eo->values($_POST)->check()) { $eo->module_id = ORM::factory('module',array('name'=>'product'))->id; // @todo This probably should be in the form. $eo->plugin_name = 'quicken'; // @todo This should be in the form. // Entry updated if (! $eo->save()) throw new Kohana_Exception('Unable to save data :post',array(':post'=>serialize($_POST))); SystemMessage::add(array( 'title'=>_('Record add'), 'type'=>'info', 'body'=>_('Export Map entry added.') )); } $output .= Form::open(); $output .= View::factory('export/admin/map/add') ->set('eo',$eo); $output .= '
'.Form::submit('submit',_('Add'),array('class'=>'form_button')).'
'; $output .= Form::close(); Block::add(array( 'title'=>_('Add Export Map'), 'body'=>$output, )); } /** * Edit Export Maping items */ public function action_edit() { } } ?>