Hello,
I'm noob, you can help me
I have this code
public function plan_de_tratare_a_riscurilor () { $crud = new grocery_CRUD(); $crud->set_table('nomenclator_riscuri'); $crud->columns('probabilitate','valoare_impact','risc','denumirea_resursei','v','a','mecanism_de_reducere','obiective', 'masuri_de_securitate','indicatori_de_performanta'); $crud->callback_column('risc', array($this, '_callback_column_risc'));
$crud->set_subject('Plan de tratare a riscurilor'); $output = $crud->render(); $data['judul'] = 'Plan de tratare a riscurilor'; $data['crumb'] = array( 'Plan de tratare a riscurilor' => '' ); $template = 'admin_template'; $view = 'grocery'; $this->outputview->output_admin($view, $template, $data, $output); }
public function _callback_column_risc ($value, $row) { $probabilitate = $row->probabilitate; $valoare_impact = $row->valoare_impact; $risc=$probabilitate * $valoare_impact; return $risc; }
How to do if column 'risc'>5 displays the entry else not displays