人人商城

display.tpl.php 18KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337
  1. <?php defined('IN_IA') or exit('Access Denied');?><?php (!empty($this) && $this instanceof WeModuleSite || 0) ? (include $this->template('common/header', TEMPLATE_INCLUDEPATH)) : (include template('common/header', TEMPLATE_INCLUDEPATH));?>
  2. <div class="panel panel-cut" id="js-account-display" ng-controller="AccountDisplay" ng-cloak>
  3. <!--选项卡-->
  4. <div class="panel-heading mixMenu-panel-heading">
  5. <ul class="navbar-nav">
  6. <?php if(is_array($nav_top_fold)) { foreach($nav_top_fold as $nav) { ?>
  7. <li <?php if($type == $nav['name']) { ?> class="on-tab" <?php } ?>>
  8. <a href="<?php if(empty($nav['url'])) { ?><?php echo url('home/welcome/' . $nav['name']);?><?php } else { ?><?php echo url('account/display/', array('type'=>$nav['name'], 'title'=>$nav['title']))?><?php } ?>" <?php if(!empty($nav['blank'])) { ?>target="_blank"<?php } ?>>
  9. <?php echo $nav['title'];?>
  10. </a>
  11. </li>
  12. <?php } } ?>
  13. </ul>
  14. </div>
  15. <!--主体内容-->
  16. <div class="panel-body mixMenu-panel-body" >
  17. <!--全部应用-->
  18. <div class="cut-list ">
  19. <!--搜索、新建、管理-->
  20. <div class="we7-page-search cut-header">
  21. <div ng-cloak>
  22. <form action="./index.php" method="get">
  23. <input type="hidden" name="c" value="account">
  24. <input type="hidden" name="a" value="display">
  25. <input type="hidden" name="do" value="display" ng-if="type == 'all'">
  26. <input type="hidden" name="type" value="{{type}}">
  27. <input type="hidden" name="title" value="{{title}}">
  28. <input type="text" name="letter" ng-model="activeLetter" ng-style="{'display': 'none'}">
  29. <div class="row">
  30. <?php if($founders) { ?>
  31. <div class="col-md-3 col-lg-2 hidden">
  32. <div class="input-group" style="width: 100%;">
  33. <select name="founder_id" class="form-control">
  34. <option value="0">请选择副创始人</option>
  35. <?php if(is_array($founders)) { foreach($founders as $founder) { ?>
  36. <option value="<?php echo $founder['uid'];?>" <?php if($founder['uid'] == $founder_id) { ?>selected<?php } ?>><?php echo $founder['username'];?></option>
  37. <?php } } ?>
  38. </select>
  39. </div>
  40. </div>
  41. <?php } ?>
  42. <div class="col-md-6">
  43. <div class="input-group">
  44. <input type="text" class="form-control" name="keyword" value="<?php echo $_GPC['keyword'];?>" placeholder="请输入{{title}}名称">
  45. <span class="input-group-btn"><button class="btn btn-primary button"><i class="wi wi-search"></i></button></span>
  46. </div>
  47. </div>
  48. </div>
  49. </form>
  50. </div>
  51. <div class="font-default pull-right">
  52. <div class="creat" ng-switch="type">
  53. <a ng-switch-when="all" href="javascript:;" data-toggle="modal" data-target="#owner-modal" class="color-default"><i class="wi wi-registersite"></i>新增平台</a>
  54. <?php if(!empty($account_info['uniacid_limit']) && (!empty($account_info['founder_uniacid_limit']) && $_W['user']['owner_uid'] || empty($_W['user']['owner_uid'])) || $_W['isfounder'] && !user_is_vice_founder()) { ?>
  55. <a ng-switch-when="account" href="./index.php?c=account&a=post-step" class="color-default">
  56. <i class="wi wi-registersite"></i>新增公众号
  57. </a>
  58. <?php } ?>
  59. <?php if(!empty($account_info['wxapp_limit']) && (!empty($account_info['founder_wxapp_limit']) && $_W['user']['owner_uid'] || empty($_W['user']['owner_uid'])) || $_W['isfounder'] && !user_is_vice_founder()) { ?>
  60. <a ng-switch-when="wxapp" href="<?php echo url('wxapp/post/design_method')?>" class="color-default"><i class="wi wi-registersite"></i>新建微信小程序</a>
  61. <?php } ?>
  62. <?php if(!empty($account_info['webapp_limit']) && (!empty($account_info['founder_webapp_limit']) && $_W['user']['owner_uid'] || empty($_W['user']['owner_uid'])) || $_W['isfounder'] && !user_is_vice_founder()) { ?>
  63. <a ng-switch-when="webapp" href="./index.php?c=webapp&a=manage&do=create_display" class="color-default">
  64. <i class="wi wi-registersite"></i>新增PC
  65. </a>
  66. <?php } ?>
  67. <?php if(!empty($account_info['phoneapp_limit']) && (!empty($account_info['founder_phoneapp_limit']) && $_W['user']['owner_uid'] || empty($_W['user']['owner_uid'])) || $_W['isfounder'] && !user_is_vice_founder()) { ?>
  68. <a ng-switch-when="phoneapp" href="<?php echo url('phoneapp/manage/create_display')?>" class="color-default"><i class="wi wi-registersite"></i>新建APP</a>
  69. <?php } ?>
  70. <?php if(!empty($account_info['xzapp_limit']) && (!empty($account_info['founder_xzapp_limit']) && $_W['user']['owner_uid'] || empty($_W['user']['owner_uid'])) || $_W['isfounder'] && !user_is_vice_founder()) { ?>
  71. <a ng-switch-when="xzapp" href="<?php echo url('xzapp/post-step')?>" class="color-default"><i class="wi wi-registersite"></i>新建熊掌号</a>
  72. <?php } ?>
  73. <?php if(!empty($account_info['aliapp_limit']) && (!empty($account_info['founder_aliapp_limit']) && $_W['user']['owner_uid'] || empty($_W['user']['owner_uid'])) || $_W['isfounder'] && !user_is_vice_founder()) { ?>
  74. <a ng-switch-when="aliapp" href="<?php echo url('miniapp/post', array('type' => ACCOUNT_TYPE_ALIAPP_NORMAL))?>" class="color-default"><i class="wi wi-registersite"></i>新建支付宝小程序</a>
  75. <?php } ?>
  76. </div>
  77. <div class="setting" ng-switch="type">
  78. <?php if(in_array($_W['highest_role'], array(ACCOUNT_MANAGE_NAME_FOUNDER, ACCOUNT_MANAGE_NAME_VICE_FOUNDER, ACCOUNT_MANAGE_NAME_OWNER,ACCOUNT_MANAGE_NAME_MANAGER))) { ?>
  79. <a ng-switch-when="account" href="<?php echo url('account/manage', array('account_type' => ACCOUNT_TYPE_OFFCIAL_NORMAL))?>" class="color-default">
  80. <i class="wi wi-manage"></i>
  81. 公众号管理
  82. </a>
  83. <a ng-switch-when="webapp" href="<?php echo url('account/manage', array('account_type' => ACCOUNT_TYPE_WEBAPP_NORMAL))?>" class="color-default">
  84. <i class="wi wi-manage"></i>
  85. PC管理
  86. </a>
  87. <?php } ?>
  88. <a ng-switch-when="wxapp" href="<?php echo url('account/manage', array('account_type' => ACCOUNT_TYPE_APP_NORMAL))?>" class="color-default">
  89. <i class="wi wi-manage"></i>微信小程序管理
  90. </a>
  91. <a ng-switch-when="phoneapp" href="<?php echo url('account/manage', array('account_type' => ACCOUNT_TYPE_PHONEAPP_NORMAL))?>" class="color-default">
  92. <i class="wi wi-manage"></i>
  93. APP管理
  94. </a>
  95. <a ng-switch-when="xzapp" href="<?php echo url('account/manage', array('account_type' => ACCOUNT_TYPE_XZAPP_NORMAL))?>" class="color-default">
  96. <i class="wi wi-manage"></i>
  97. 熊掌号管理
  98. </a>
  99. <a ng-switch-when="aliapp" href="<?php echo url('account/manage', array('account_type' => ACCOUNT_TYPE_ALIAPP_NORMAL))?>" class="color-default">
  100. <i class="wi wi-manage"></i>
  101. 支付宝小程序管理
  102. </a>
  103. </div>
  104. </div>
  105. </div>
  106. <!--首字母检索-->
  107. <div class="clearfix"></div>
  108. <ul class="letters-list" ng-cloak>
  109. <li ng-repeat="letter in alphabet" ng-style="{'background-color': letter == activeLetter ? '#ddd' : 'none'}" ng-class="{'active': letter == activeLetter}" ng-click="searchModule(letter)" class="ng-scope">
  110. <a href="javascript:;" ng-bind="letter" class="ng-binding"></a>
  111. </li>
  112. </ul>
  113. <div class="count we7-margin-bottom hidden">
  114. <?php if($total_list) { ?>
  115. <span class="we7-margin-right">公众号 : <?php echo $total_list['account'];?></span>
  116. <span class="we7-margin-right">熊账号 : <?php echo $total_list['xzapp'];?></span>
  117. <span class="we7-margin-right">微信小程序 : <?php echo $total_list['wxapp'];?></span>
  118. <span class="we7-margin-right">PC : <?php echo $total_list['webapp'];?></span>
  119. <span class="we7-margin-right">APP : <?php echo $total_list['phoneapp'];?></span>
  120. <span class="we7-margin-right">支付宝小程序 : <?php echo $total_list['aliapp'];?></span>
  121. <?php } else { ?>
  122. <span class="we7-margin-right"><?php echo $title;?>总量 : <?php echo $total;?></span>
  123. <?php } ?>
  124. </div>
  125. <!--列表数据-->
  126. <!--add-->
  127. <div class="mixMenu-list clearfix" ng-if="list" infinite-scroll='loadMore()' infinite-scroll-disabled='busy' infinite-scroll-distance='0' infinite-scroll-use-document-bottom="true">
  128. <!--add-->
  129. <div class="item module-list-item ng-scope" ng-repeat="detail in list|orderBy:'endtime_status'" ng-if="list" style="" ng-class="detail.endtime_status == 1 ? 'expire' : ''">
  130. <div class="content">
  131. <img class="item-logo" ng-src="{{detail.logo}}" onerror="this.src='./resource/images/nopic-107.png'">
  132. <div class="item-footer">
  133. <div class="item-icon">
  134. <i ng-if="detail.type == types.account_normal" class="wi wi-wechat"></i>
  135. <i ng-if="detail.type == types.account_auth" class="wi wi-wechat"></i>
  136. <i ng-if="detail.type == types.wxapp_normal" class="wi wi-wxapp"></i>
  137. <i ng-if="detail.type == types.wxapp_auth" class="wi wi-wxapp"></i>
  138. <i ng-if="detail.type == types.webapp" class="wi wi-pc"></i>
  139. <i ng-if="detail.type == types.phoneapp" class="wi wi-app"></i>
  140. <i ng-if="detail.type == types.xzapp" class="wi wi-xzapp"></i>
  141. <i ng-if="detail.type == types.aliapp" class="wi wi-aliapp"></i>
  142. </div>
  143. <div class="info">
  144. <div class="name" ng-bind="detail.name"></div>
  145. <div class="type" ng-if="detail.type == types.account_normal || detail.type == types.account_auth">
  146. <span ng-if="detail.level == 1">类型:普通订阅号</span>
  147. <span ng-if="detail.level == 2">类型:普通服务号</span>
  148. <span ng-if="detail.level == 3">类型:认证订阅号</span>
  149. <span ng-if="detail.level == 4">类型:认证服务号</span>
  150. </div>
  151. <div class="type" ng-if="detail.type == types.wxapp_normal || detail.type == types.wxapp_auth || detail.type == types.phoneapp">
  152. <span>版本:{{detail.current_version.version}}</span>
  153. </div>
  154. <div class="type" ng-if="detail.type == types.webapp">
  155. <span>类型:PC应用</span>
  156. </div>
  157. <div class="type" ng-if="detail.type == types.xzapp">
  158. <span>类型:熊掌号</span>
  159. </div>
  160. <div class="type" ng-if="detail.type == types.aliapp">
  161. <span>类型:支付宝小程序</span>
  162. </div>
  163. </div>
  164. </div>
  165. </div>
  166. <!--鼠标悬停遮罩效果-->
  167. <div class="mask">
  168. <!-- 进入公众号/PC -->
  169. <a href="{{detail.switchurl}}&type={{detail.type}}" class="entry" ng-if="detail.type == types.account_normal || detail.type == types.account_auth"><div>进入公众号 <i class="wi wi-angle-right"></i></div></a>
  170. <!-- 进入PC -->
  171. <a href="{{detail.switchurl}}" class="entry" ng-if="detail.type == types.webapp"><div>进入PC <i class="wi wi-angle-right"></i></div></a>
  172. <!-- 进入小程序 -->
  173. <a ng-href="{{links.switch}}uniacid={{detail.uniacid}}&multiid={{detail.current_version.multiid}}&version_id={{detail.current_version.id}}&type={{detail.type}}" class="entry" ng-if="detail.type == types.wxapp_normal || detail.type == types.wxapp_auth"><div>进入微信小程序 <i class="wi wi-angle-right"></i></div></a>
  174. <!-- 进入 APP -->
  175. <a ng-href="{{links.switch}}uniacid={{detail.uniacid}}&version_id={{detail.current_version.id}}&type={{detail.type}}" class="entry" ng-if="detail.type == types.phoneapp">
  176. <div>进入APP <i class="wi wi-angle-right"></i></div>
  177. </a>
  178. <!-- 进入熊掌号 -->
  179. <a href="{{detail.switchurl}}&type={{detail.type}}" class="entry" ng-if="detail.type == types.xzapp"><div>进入熊掌号 <i class="wi wi-angle-right"></i></div></a>
  180. <!-- 进入支付宝小程序 -->
  181. <a href="{{detail.switchurl}}&type={{detail.type}}" class="entry" ng-if="detail.type == types.aliapp"><div>进入支付宝小程序 <i class="wi wi-angle-right"></i></div></a>
  182. <!-- 小程序/APP 查看版本 -->
  183. <a href="javascript:;" class="cut-btn" ng-click="showVersions($event)" ng-if="detail.type == types.wxapp_normal || detail.type == types.wxapp_auth || detail.type == types.phoneapp">
  184. <i class="wi wi-changing-over"></i>
  185. </a>
  186. <!-- 添加到首页 -->
  187. <?php if(!permission_check_account_user('see_user_profile_account_num')) { ?>
  188. <a ng-href="{{links.welcome}}uniacid={{detail.uniacid}}" onclick="return ajaxopen(this.href);" class="home-show" title="添加到首页常用功能">
  189. <i class="wi wi-eye"></i>
  190. </a>
  191. <?php } ?>
  192. <!-- 置顶 -->
  193. <a href="javascript:;" class="stick" ng-click="stick(detail.uniacid, detail.type)" title="置顶">
  194. <i class="wi wi-stick-sign"></i>
  195. </a>
  196. </div>
  197. <!-- 小程序/APP版本查看 -->
  198. <div class="cut-select" ng-mouseleave="hideSelect($event)" ng-if="detail.versions">
  199. <div class="arrow-left"></div>
  200. <div class="cut-item">
  201. <a href="javascript:;">
  202. <div class="detail" ng-repeat="version in detail.versions">
  203. <div class="text-over">
  204. <span ng-class="{true:'wi wi-app', false:'wi wi-small-routine'}[detail.type == account_type_phoneapp]"></span>
  205. {{version.version}}
  206. </div>
  207. <a class="cut-select-mask" href="{{links.switch}}&uniacid={{detail.uniacid}}&multiid={{version.multiid}}&version_id={{version.id}}&type={{detail.type}}">
  208. <div class="entry">选择进入 <i class="wi wi-angle-right"></i></div>
  209. </a>
  210. </div>
  211. </a>
  212. </div>
  213. <div class="cut-select-pager">
  214. <a href="{{links.wxapp_more_version}}&uniacid={{detail.uniacid}}" class="more color-default" ng-if="detail.type == types.wxapp_normal || detail.type == types.wxapp_auth">更多 >></a>
  215. </div>
  216. </div>
  217. </div>
  218. </div>
  219. <ul ng-if="!list" style="text-align:center;width:100%"><span ng-if="!list">暂无数据</span></ul>
  220. </div>
  221. </div>
  222. <!--新建弹窗-->
  223. <div class="modal" id="owner-modal">
  224. <div class="modal-dialog">
  225. <div class="modal-content">
  226. <div class="modal-header">
  227. <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
  228. <h3 class="modal-title">新建</h3>
  229. </div>
  230. <div class="modal-body">
  231. <div class="mask-creat">
  232. <ul>
  233. <?php if(!empty($account_info['uniacid_limit']) && (!empty($account_info['founder_uniacid_limit']) && $_W['user']['owner_uid'] || empty($_W['user']['owner_uid'])) || $_W['isfounder'] && !user_is_vice_founder()) { ?>
  234. <li><i class="wi wi-wx-circle"></i><br/><a href="./index.php?c=account&a=post-step" class="name" title="新建公众号"></a></li>
  235. <?php } ?>
  236. <?php if(!empty($account_info['wxapp_limit']) && (!empty($account_info['founder_wxapp_limit']) && $_W['user']['owner_uid'] || empty($_W['user']['owner_uid'])) || $_W['isfounder'] && !user_is_vice_founder()) { ?>
  237. <li><i class="wi wi-wxapp"></i><br/><a href="<?php echo url('wxapp/post/design_method')?>" class="name" title="新建微信小程序"></a></li>
  238. <?php } ?>
  239. <?php if(!empty($account_info['webapp_limit']) && (!empty($account_info['founder_webapp_limit']) && $_W['user']['owner_uid'] || empty($_W['user']['owner_uid'])) || $_W['isfounder'] && !user_is_vice_founder()) { ?>
  240. <li><i class="wi wi-pc-circle"></i><br/><a href="./index.php?c=webapp&a=manage&do=create_display" class="name" title="新建PC"></a></li>
  241. <?php } ?>
  242. <?php if(!empty($account_info['phoneapp_limit']) && (!empty($account_info['founder_phoneapp_limit']) && $_W['user']['owner_uid'] || empty($_W['user']['owner_uid'])) || $_W['isfounder'] && !user_is_vice_founder()) { ?>
  243. <li><i class="wi wi-app"></i><br/><a href="<?php echo url('phoneapp/manage/create_display')?>" class="name" title="新建APP"></a></li>
  244. <?php } ?>
  245. <?php if(!empty($account_info['xzapp_limit']) && (!empty($account_info['founder_xzapp_limit']) && $_W['user']['owner_uid'] || empty($_W['user']['owner_uid'])) || $_W['isfounder'] && !user_is_vice_founder()) { ?>
  246. <li><i class="wi wi-xzapp"></i><br/><a href="<?php echo url('xzapp/post-step')?>" class="name" title="新建熊掌号"></a></li>
  247. <?php } ?>
  248. <?php if(!empty($account_info['aliapp_limit']) && (!empty($account_info['founder_aliapp_limit']) && $_W['user']['owner_uid'] || empty($_W['user']['owner_uid'])) || $_W['isfounder'] && !user_is_vice_founder()) { ?>
  249. <li><i class="wi wi-aliapp"></i><br/><a href="<?php echo url('miniapp/post', array('type' => ACCOUNT_TYPE_ALIAPP_NORMAL))?>" class="name" title="新建支付宝小程序"></a></li>
  250. <?php } ?>
  251. </ul>
  252. </div>
  253. </div>
  254. <div class="modal-footer">
  255. <button type="button" class="btn btn-default" data-dismiss="modal">取消</button>
  256. </div>
  257. </div>
  258. </div>
  259. </div>
  260. </div>
  261. <script>
  262. angular.module('accountApp').value('config', {
  263. 'list' : <?php echo !empty($list) ? json_encode($list) : 'null'?>,
  264. 'type' : "<?php echo $type;?>",
  265. 'title' : "<?php echo $title;?>",
  266. 'keyword' : "<?php echo $keyword;?>",
  267. 'letter' : "<?php echo $letter;?>",
  268. 'founder_id' : "<?php echo $founder_id;?>",
  269. 'total' : '<?php echo $total;?>',
  270. 'account_type_phoneapp' : "<?php echo ACCOUNT_TYPE_PHONEAPP_NORMAL;?>",
  271. 'links' : {
  272. 'rank' : "<?php echo url('account/display/rank')?>",
  273. 'switch' : "<?php echo url('account/display/switch')?>",
  274. 'welcome' : "<?php echo url('home/welcome/add_welcome')?>",
  275. 'wxapp_more_version' : "<?php echo url('wxapp/version/display')?>",
  276. 'aliapp_more_version' : "<?php echo url('miniapp/version/display')?>",
  277. 'phoneapp_more_version' : "<?php echo url('phoneapp/version/display')?>"
  278. },
  279. 'types' : {
  280. 'account_normal' : "<?php echo ACCOUNT_TYPE_OFFCIAL_NORMAL;?>",
  281. 'account_auth' : "<?php echo ACCOUNT_TYPE_OFFCIAL_AUTH;?>",
  282. 'wxapp_normal' : "<?php echo ACCOUNT_TYPE_APP_NORMAL;?>",
  283. 'wxapp_auth' : "<?php echo ACCOUNT_TYPE_APP_AUTH;?>",
  284. 'webapp' : "<?php echo ACCOUNT_TYPE_WEBAPP_NORMAL;?>",
  285. 'phoneapp' : "<?php echo ACCOUNT_TYPE_PHONEAPP_NORMAL;?>",
  286. 'xzapp' : "<?php echo ACCOUNT_TYPE_XZAPP_NORMAL;?>",
  287. 'aliapp' : "<?php echo ACCOUNT_TYPE_ALIAPP_NORMAL;?>",
  288. },
  289. scrollUrl : "<?php echo url('account/display', array('type'=>$type))?>"
  290. });
  291. angular.bootstrap($('#js-account-display'), ['accountApp']);
  292. </script>
  293. <?php (!empty($this) && $this instanceof WeModuleSite || 0) ? (include $this->template('common/footer', TEMPLATE_INCLUDEPATH)) : (include template('common/footer', TEMPLATE_INCLUDEPATH));?>