Код: Выделить всё
Код: Выделить всё
$this->load->model('coupon_model');
$data['wonCount'] = $this->coupon_model->wonCount();
$this->loadPage('dashboard', $data);
Код: Выделить всё
public function wonCount()
{
return $this->db->query("SELECT COUNT(status) FROM coupon WHERE status = 'won'");
}
Серьезность: уведомление
Сообщение: неопределенная переменная: winCount
Как отобразить счетчик?>
Подробнее здесь: https://stackoverflow.com/questions/502 ... lect-query
Мобильная версия