From 76c6148a4bfd3f6e091566286b518afa29cf61ca Mon Sep 17 00:00:00 2001 From: cyc Date: Thu, 13 Feb 2020 14:56:59 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E6=9F=A5=E8=AF=A2sql?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- application/controllers/information.php | 6 +++++- application/models/logs_model.php | 9 +++++++-- 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/application/controllers/information.php b/application/controllers/information.php index 74243eb1..6d235c9b 100644 --- a/application/controllers/information.php +++ b/application/controllers/information.php @@ -702,7 +702,11 @@ class Information extends CI_Controller function backup_content($log_id) { $data['log_info'] = $this->Logs_model->read($log_id); - $data['log_list'] = $this->Logs_model->get_all_backup_list($data['log_info']->log_res_id); + if($data['log_info']->log_action == 'backup_amp'){ + $data['log_list'] = $this->Logs_model->get_all_backup_list($data['log_info']->log_res_id,true); + }else{ + $data['log_list'] = $this->Logs_model->get_all_backup_list($data['log_info']->log_res_id); + } $this->load->view('bootstrap/header', $data); $this->load->view('bootstrap/information_backup_content'); $this->load->view('bootstrap/footer'); diff --git a/application/models/logs_model.php b/application/models/logs_model.php index d3839794..38d1353e 100644 --- a/application/models/logs_model.php +++ b/application/models/logs_model.php @@ -51,10 +51,15 @@ class Logs_model extends CI_Model { } //获取所有备份信息内容 - function get_all_backup_list($is_id) { + function get_all_backup_list($is_id,$amp=false) { $this->init(); $this->log_res_id = " AND il.log_res_id =" . $this->HT->escape($is_id); - $this->log_action = " AND (il.log_action = 'backup_info' or il.log_action = 'backup_amp')"; + if($amp){ + $this->log_action = " AND (il.log_action = 'backup_amp')"; + }else{ + $this->log_action = " AND (il.log_action = 'backup_info')"; + } + return $this->get_list(); }