<?php
/*
|--------------------------------------------------------------------------
| home
|--------------------------------------------------------------------------
*/
$view

->set('name', 'news') 
->set('title', '企业动态')  
 
->import('inc/head') 

# 定义名称
->fetch('body@t', '1')   
->fetch('.banner img@src', 'main/api.config#news_pic') 
->fetch('.banner b', 'main/api.config#news_name') 
->fetch('.banner span', 'main/api.config#news_desc') 

->fetch(array('.float-shares img@src', 0), 'main/api.config#wechat') 
->fetch(array('.float-shares img@src', 1), 'main/api.config#douyin') 
->fetch(array('.float-shares img@src', 2), 'main/api.config#weibo') 


->loop
(
    '.news-tab a',
    'main/api.news_cate',
    array
    (
        'href' => '$v.link',
    	'class' => '$v.class',
    	'html' => '$v.name',
    )
)

->loop
(
    '.news-list dl',
    'main/api.news',
    array
    (
        'a|0' => array
        (
        	'href' => '$v.link',
        	'img' => array
        	(
        		'src' => '$v.pic_cover',
        	)
        ),
    	
        'a|1' => array
        (
        	'href' => '$v.link',
        	'html' => '$v.name',
        ),
        'p' => '$v.desc',
        'span' => '$v.cdate',	
    )
)

->fetch('#page','<{Dever::page("current")}>') 


# display
->display();