方维二次开发

wangtongphp

  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

 

方维订餐系统将商户的所有图片调到商铺详情里面,在上一篇已经解决了,这里有另外一种方法:

 

在store_view.html 加入下面一句

    <!--add by  QQ 1006440989 -->
                    <div style="height:30px;"></div>
                    <ul id="pic-album">
                     {foreach from=$pic_list item=pic_item name="pic_item"}
                     <li style="height:20px;"></li>
                     <li class="{if $pic_item.id eq $pic_info.id}current{/if}"><div><a href="{url x="store" r="photos" p="id=$store_info.id&image_type=$images_group_id&pid=$pic_item.id"}#pic-bd"><img   src="{$pic_item.image}" alt="{$pic_item.brief}"></a></div></li>
                    {/foreach}
                    </ul>
                    <div style="height:30px;"></div>

 

在viewModule.class 加下面

 

//add by QQ1006440989
            $pic_list = $GLOBALS['db']->getAll("select id,image,click_count,images_group_id,brief,user_id,create_time from ".DB_PREFIX."supplier_location_images where status = 1 and supplier_location_id=".intval($store_info['id'])." $extImgType order by sort desc, id desc");
            $GLOBALS['tmpl']->assign("pic_list",$pic_list);

 

 

这样可以把餐厅 的图片都调用到详情里面

 

posted on 2014-01-14 20:34  方维二次开发  阅读(480)  评论(0编辑  收藏  举报