news.php 3.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. <?php
  2. use mobile\assets\AppAsset;
  3. use common\fm\Opencc;
  4. use yii\helpers\Url;
  5. AppAsset::addCss($this, Yii::$app->request->baseUrl . "/overseas/css/lpnewslist.css");
  6. AppAsset::addScript($this, Yii::$app->request->baseUrl . '/overseas/js/menu/iscroll.js'); //菜单滑动
  7. AppAsset::addScript($this, Yii::$app->request->baseUrl . '/overseas/js/menu/navbarscroll.js'); //菜单滑动
  8. AppAsset::addScript($this, Yii::$app->request->baseUrl . "/overseas/js/amazeui/amazeui.js");
  9. AppAsset::addScript($this, Yii::$app->request->baseUrl . '/overseas/js/menu/lpnav.js');
  10. AppAsset::addScript($this, Yii::$app->request->baseUrl . '/overseas/js/search_public.js');
  11. $this->title = '楼盘动态';
  12. ?>
  13. <div id="serachBox2">
  14. <?php $this->beginContent('@app/views/public/nav.php'); ?>
  15. <?php $this->endContent(); ?>
  16. <!-- 导航 -->
  17. <?php $this->beginContent('@app/views/public/housenav.php', ['hid' => $hid]); ?>
  18. <?php $this->endContent(); ?>
  19. <?php if (!empty($model)&&!empty($model['data'])) { ?>
  20. <div class="y_lphomenew">
  21. <div class="y_lphomenew_main">
  22. <div class="y_lphomenew_cent">
  23. <ul>
  24. <?php foreach ($model['data'] as $val) { ?>
  25. <li>
  26. <div class="y_newtextmain">
  27. <a href="/news/details/<?= $val['id'] ?>">
  28. <p class="y_title c"><i><img src="/overseas/img/ico_38.png"
  29. alt=""></i><span><?= $val['subject'] ?></span>
  30. </p>
  31. <div class="y_newstext">
  32. <em class="list_tb2"><img src="/overseas/img/ico_39.png" alt=""></em>
  33. <em class="list_tb"><img src="/overseas/img/ico_lpnewes.png" alt=""></em>
  34. <p class="y_text"><?= $val['abstract'] ?></p>
  35. <p class="y_img c">
  36. <?php if (!empty($val['thumb'])) {
  37. $img = json_decode($val['thumb'], true);
  38. foreach ($img as $v) { ?>
  39. <i>
  40. <img src="<?= Yii::$app->params['httpImg']['host'], Yii::$app->params['httpImg']['newsthumb'], $v ?>"
  41. alt="">
  42. </i>
  43. <?php }
  44. } ?>
  45. </p>
  46. <p class="y_shijian"><?= $val['open_time'] ?></p>
  47. </div>
  48. </a>
  49. </div>
  50. <div style="height:15px;"></div>
  51. </li>
  52. <?php } ?>
  53. </ul>
  54. </div>
  55. </div>
  56. </div>
  57. <?php } else { ?>
  58. <div class="y_nodata">
  59. <div style="background:#fff; padding:20px;"><img src="/overseas/img/y_nodata.png" alt="" width="100%"
  60. height="auto"/></div>
  61. </div>
  62. <?php } ?>
  63. </div>