135 lines
5.3 KiB
PHP
Executable File
135 lines
5.3 KiB
PHP
Executable File
<?
|
|
if($result_code == '0000') {
|
|
echo '0000|||||';
|
|
$row_count = count($list);
|
|
|
|
|
|
$ci=& get_instance();
|
|
$ci->load->model('web/m_life');
|
|
$ci->load->model('web/m_column');
|
|
$ci->load->model('web/m_tag');
|
|
foreach ($list as $val) {
|
|
|
|
$idx = $val['idx'];
|
|
$delivery_count = $val['delivery_count'];
|
|
$reg_date = $val['reg_date'];
|
|
$main_idx = $val['main_idx'];
|
|
$content_type = $val['content_type'];
|
|
|
|
$now_date = date("Y-m-d").' 00:00:00';
|
|
$req_data = array();
|
|
$req_data['offset'] = $_POST['page']-1 * $_POST['limit'];
|
|
$req_data['limit'] = $_POST['limit'];
|
|
|
|
$req_data['offset'] = $req_data['offset'] < 0 ? 0 : $req_data['offset'];
|
|
|
|
if($content_type == '2') {
|
|
$article_count = $val['article_count'];
|
|
$delivery_title = $val['partner_name'];
|
|
$main_img = $val['partner_img'];
|
|
|
|
|
|
$req_data['sort_column'] = 'display_date';
|
|
$req_data['search_type'] = 'partner_idx';
|
|
$req_data['search_key'] = $val['main_idx'];
|
|
$delivery_row = $ci->m_column->column_list($req_data);
|
|
|
|
$delivery_row_display_date_txt = ''; $title=''; $article_view_url='';
|
|
if(count($delivery_row) > 0) {
|
|
$display_date = $delivery_row[0]['display_date'];
|
|
$delivery_row_display_date_txt = substr($display_date, 0, 16);
|
|
$title = $delivery_row[0]['title'];
|
|
$article_view_url = '/web/news/column_view/'.$delivery_row[0]['idx'];
|
|
}
|
|
|
|
$view_url = '/m/news/columnist/'.$main_idx;
|
|
|
|
$req_data['partner_idx'] = $val['main_idx'];
|
|
$req_data['now_date'] = $now_date;
|
|
|
|
$delivery_today_count = $ci->m_column->column_where_display_date_partner_idx_count($req_data);
|
|
|
|
|
|
} else if($content_type == '3') {
|
|
$article_count = $val['article_count'];
|
|
$delivery_title = $val['channel_name'];
|
|
$main_img = $val['channel_icon'];
|
|
|
|
|
|
$req_data['channel_idx'] = $val['main_idx'];
|
|
$delivery_row = $ci->m_life->life_where_channel_idx_list_limit1($req_data);
|
|
$display_date = $delivery_row['display_date'];
|
|
$delivery_row_display_date_txt = substr($display_date, 0, 16);
|
|
|
|
$article_view_url = '/m/life/life_view/'.$delivery_row['idx'];
|
|
$view_url = '/m/life/channel/'.$main_idx;
|
|
|
|
$req_data['channel_idx'] = $val['main_idx'];
|
|
$req_data['now_date'] = $now_date;
|
|
|
|
$delivery_today_count = $ci->m_life->life_where_display_date_channel_idx_count($req_data);
|
|
|
|
$title = $delivery_row['title'];
|
|
|
|
} else if($content_type == '9') {
|
|
$delivery_title = '#'.$main_idx;
|
|
$main_img = '';
|
|
|
|
$req_data['tag'] = $val['main_idx'];
|
|
$delivery_row = $ci->m_tag->tag_join_life_where_tag_list_limit1($req_data);
|
|
$article_count = $ci->m_tag->tag_join_life_where_tag_count($req_data);
|
|
|
|
$display_date = $delivery_row['display_date'];
|
|
$delivery_row_display_date_txt = substr($display_date, 0, 16);
|
|
|
|
|
|
$req_data['tag'] = $val['main_idx'];
|
|
$req_data['now_date'] = $now_date;
|
|
|
|
$delivery_today_count = $ci->m_tag->tag_join_life_where_display_date_count($req_data);
|
|
|
|
$article_view_url = '/m/life/life_view/'.$delivery_row['idx'];
|
|
$view_url = '/m/life/tag/'.$main_idx;
|
|
|
|
$title = $delivery_row['title'];
|
|
$title = mb_strimwidth($title, '0', '200', '..', 'utf-8');
|
|
|
|
}
|
|
|
|
|
|
?>
|
|
<input type="text" name="copy_delivery_url<?=$idx?>" id="copy_delivery_url<?=$idx?>" style="position:absolute;top:-9999em;" value="<?=WWW_CROSSMAP?><?=$view_url?>">
|
|
<input type="hidden" name="is_del[]" value="<?=$idx?>">
|
|
<div class="pop_cont_box">
|
|
<div class="pop_cont_title">
|
|
<a href="<?=$article_view_url?>"><?=@$delivery_row['title']?></a>
|
|
<p class="popup_date"><?=$delivery_row_display_date_txt?></p>
|
|
</div>
|
|
<div class="pop_cont_txt">
|
|
|
|
<span class="pop_cont_img" <?=($content_type == 9) ?"style='display:none'" :""?>><div onclick="setCookie('pre_page',<?=$content_type?>,'365');location.href='<?=$view_url?>'" style="border-radius:50px;cursor:pointer;width:50px;height:50px;background:url('<?=$main_img?>') no-repeat center; background-size:cover;"></div></span>
|
|
<div class="pop_cont_txt_box">
|
|
<p class="t_black"><a onclick="setCookie('pre_page',<?=$content_type?>,'365');location.href='<?=$view_url?>';"><?=$delivery_title?></a> <? if($delivery_today_count>0) {?><span class="pop_cont_like"><?=number_format($delivery_today_count)?>+</span><? }?></p>
|
|
<p><span class="beachblue"><?=number_format($article_count)?></span>개의 글이 있습니다. </p>
|
|
<p><span class="beachblue"><?=number_format($delivery_count)?></span>명에게 배달 중</p>
|
|
</div>
|
|
<div class="pop_cont_info">
|
|
<span class="fr" onclick="$(this).next().toggle();"><img src="/img/mobile/pop_info.png"></a></span>
|
|
<ul class="info_popup" style="display:none;">
|
|
<li><a href="javascript:delivery_del('<?=$idx?>');">삭제하기</a></li>
|
|
<li style="border-top:1px solid #ededed"><a href="javascript:copy_delivery_url('<?=$idx?>');">링크복사</a></li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<? }
|
|
|
|
}
|
|
|
|
if($more_list=='N') echo '<div style="height:50px"></div>';
|
|
|
|
echo '|||||'.$total_count.'|||||'.$more_list;
|
|
|
|
|
|
?>
|