我使用Rails和React-Table来显示表.它到目前为止工作正常.但是如何在React-Table中添加编辑/删除列?
它甚至可能吗?
return (
<ReactTable
data={this.props.working_hours}
columns={columns}
defaultPageSize={50}
className="-striped -highlight"
/>
)
Run Code Online (Sandbox Code Playgroud) 我使用CodeIgniter,我在模型中有一个函数createRecord:
public function createRecord($aRecordToSave) {
$oLatestRecord = $this->getLatestRecord($aRecordToSave[$this->sForeignKey]);
var_dump($oLatestRecord);
$this->db->trans_begin();
$this->db->where($this->sForeignKey, $aRecordToSave[$this->sForeignKey]);
$this->db->update($this->sRecordsTable, array('latest' => 0));
}
Run Code Online (Sandbox Code Playgroud)
如果只在数据库中写入执行该功能,并且通过单击"保存"以显示视图,页面立即从编辑中重定向,如何显示var_dump输出?