php - 在 1 个表 codeigniter 中添加 2 个历史记录
问题描述
我有这个HTML
显示历史的表,我像这样显示数据
我的控制器:
$data['cashoutrequest'] = $this->investor->getCashoutRequest($this->session->userdata('refcode'));
$data['investHistory'] = $this->investor->account_history($this->session->userdata('refcode'));
我的观点:
<?php if($cashoutrequest != null) {?>
<?php $i=1;foreach($cashoutrequest as $rec): ?>
<?php foreach($investHistory as $rec2): ?>
<tr>
<td><?php echo $rec['referal_code']; ?></td>
<td><?php echo $rec['activity']; ?></td>
<td><?php echo $rec['description']; ?></td>
<td><?php echo $rec['date']; ?></td>
<?php if($rec['status'] == 0) { echo "<td>pending</td>"; } else { echo "<td>confirmed</td>"; } ?>
</tr>
<?php endforeach; ?>
<?php endforeach;?>
<?php } ?>
我还想显示一些有关投资历史的数据,但它不起作用。它什么也不显示。
解决方案
推荐阅读
- javafx - JavaFX 如何在 CSS 中设置高斯模糊
- python - 部署为包时 Python 导入错误
- python - How to patch an asynchronous class method?
- python-3.x - 安装 pyrebase 时出错
- php - Deploying Laravel 5.4 to Shared Hosting
- csv - Spark 读取 csv 文件时出错
- r - Extract error matrix from manova analysis in r
- sql - Case expression for date format conversion
- visual-studio - Can't add source directory for Intellisense
- cognos - Need help building a Data Item in Cognos Report Studio