Commit 6c576b56 by html5-李恒逸

修复:渠道看不到对应楼盘

parent 14799930
<?php
/**
*渠道与项目关系表
*
*
* @package application/model
* @version 2016-12-15
* @author libin
......@@ -12,7 +12,7 @@ class Channel_building_model extends My_Model{
* 使用到的表
*/
public $table = 'tb_channel_building';
/**
* 构造器
*/
......@@ -23,19 +23,17 @@ class Channel_building_model extends My_Model{
$this->db = $this->load->database('default', true);
}
/**
*
*
* 查询本人及下属所有楼盘
* @param int $where
* @return array 包含统计起止时间的数组
* @throws Exception
* @throws Exception
* @author lihengyi
* @version 2016-12-28
*/
public function get_all_building($where=''){
$this->db->select('B.id,B.building_id,B.building_title')
->from('tb_building B')
->join('tb_channel_building CB','B.id=CB.building_id','left')
->join('tb_channel E','E.id=CB.channel_id');
->from('tb_building B');
if($where!=''){
$this->db->where($where);
}
......@@ -45,11 +43,11 @@ class Channel_building_model extends My_Model{
return $result_array;
}
/**
*
*
* 查询本人及下属所有分销商
* @param int $where
* @return array 包含统计起止时间的数组
* @throws Exception
* @throws Exception
* @author lihengyi
* @version 2016-12-28
*/
......@@ -64,4 +62,4 @@ class Channel_building_model extends My_Model{
$result_array=$result->result_array();
return $result_array;
}
}
\ No newline at end of file
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment