welcome.html 3.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. {template 'common/header'}
  2. <div class="welcome-container" id="js-home-welcome" ng-controller="WelcomeCtrl" ng-cloak>
  3. <div class="welcome-container">
  4. <div class="panel we7-panel account-stat">
  5. <div class="panel-heading">
  6. 今日关键指标/昨日关键指标
  7. </div>
  8. <div class="panel-body we7-padding-vertical">
  9. <div class="col-sm-3 text-center">
  10. <div class="title">新关注</div>
  11. <div>
  12. <span class="today" ng-init="0" ng-bind="fans_kpi.today.new"></span>
  13. <span class="pipe">/</span>
  14. <span class="yesterday" ng-init="0" ng-bind="fans_kpi.yesterday.new"></span>
  15. </div>
  16. </div>
  17. <div class="col-sm-3 text-center">
  18. <div class="title">取消关注</div>
  19. <div>
  20. <span class="today" ng-init="0" ng-bind="fans_kpi.today.cancel"></span>
  21. <span class="pipe">/</span>
  22. <span class="yesterday" ng-init="0" ng-bind="fans_kpi.yesterday.cancel"></span>
  23. </div>
  24. </div>
  25. <div class="col-sm-3 text-center">
  26. <div class="title">净增关注</div>
  27. <div>
  28. <span class="today" ng-init="0" ng-bind="fans_kpi.today.jing_num"></span>
  29. <span class="pipe">/</span>
  30. <span class="yesterday" ng-init="0" ng-bind="fans_kpi.yesterday.jing_num"></span>
  31. </div>
  32. </div>
  33. <div class="col-sm-3 text-center">
  34. <div class="title">累计关注</div>
  35. <div>
  36. <span class="today" ng-init="0" ng-bind="fans_kpi.today.cumulate"></span>
  37. </div>
  38. </div>
  39. </div>
  40. </div>
  41. <div class="panel we7-panel notice notice-tab">
  42. <div class="panel-heading">
  43. {if permission_check_account_user('see_notice_post')}<a href="./index.php?c=article&a=notice&do=post" class="color-default pull-right we7-margin-left">+新建</a>{/if}
  44. <a href="./index.php?c=article&a=notice-show" class="color-default pull-right">更多</a>
  45. <div class="menu">
  46. <span class="topic active notice">公告</span>
  47. </div>
  48. </div>
  49. <ul class="list-group active">
  50. <li class="list-group-item" ng-repeat="notice in notices" ng-if="notices">
  51. <a ng-href="{{notice.url}}" class="text-over" target="_blank" ng-style="{'color': notice.style.color, 'font-weight': notice.style.bold ? 'bold' : 'normal'}" ng-bind="notice.title"></a>
  52. <span class="pull-right color-gray" ng-bind="notice.createtime"></span>
  53. </li>
  54. <li class="list-group-item text-center" ng-if="!notices">
  55. <span>暂无数据</span>
  56. </li>
  57. </ul>
  58. </div>
  59. </div>
  60. </div>
  61. <script>
  62. angular.module('homeApp').value('config', {
  63. notices: {php echo !empty($notices) ? json_encode($notices) : 'null'},
  64. });
  65. angular.bootstrap($('#js-home-welcome'), ['homeApp']);
  66. $(function(){
  67. $('[data-toggle="tooltip"]').tooltip();
  68. var $topic = $('.welcome-container .notice .menu .topic');
  69. var $ul = $('.welcome-container .notice ul');
  70. $topic.mouseover(function(){
  71. var $this = $(this);
  72. var $index = $this.index();
  73. if ($this.is('.we7notice')) {
  74. $this.parent().prev().hide();
  75. } else {
  76. $this.parent().prev().show();
  77. }
  78. $topic.removeClass('active');
  79. $this.addClass('active');
  80. $ul.removeClass('active');
  81. $ul.eq($index).addClass('active');
  82. })
  83. })
  84. </script>
  85. {template 'common/footer'}