人人商城

group.html 28KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700
  1. {template 'common/header'}
  2. {if $do == 'display'}
  3. <div class="we7-page-title">
  4. 应用权限套餐
  5. </div>
  6. <ul class="we7-page-tab">
  7. <li class="active"><a href="{php echo url('module/group/display') }">应用权限套餐列表 </a></li>
  8. </ul>
  9. <div class="js-system-module_group" ng-controller="moduleGroupCtrl" ng-cloak>
  10. <div class="combo-list">
  11. <div class="we7-page-search clearfix">
  12. {if permission_check_account_user('see_module_manage_system_group_add')}
  13. <div class="pull-right">
  14. <a href="{php echo url('module/group/post')}" class="btn btn-primary">+添加应用权限套餐</a>
  15. </div>
  16. {/if}
  17. <form action="" method="get" class="we7-form row">
  18. <div class="form-group we7-padding-none col-sm-4">
  19. <input type="hidden" name="c" value="module">
  20. <input type="hidden" name="a" value="group">
  21. <input type="hidden" name="do" value="display">
  22. <div class="input-group">
  23. <input class="form-control" name="name" value="{$_GPC['name']}" type="text" placeholder="名称" >
  24. <span class="input-group-btn"><button class="btn btn-default"><i class="fa fa-search"></i></button></span>
  25. </div>
  26. </div>
  27. </form>
  28. </div>
  29. <table class="table we7-table table-hover vertical-middle">
  30. <col width="180px" />
  31. <col width="70px"/>
  32. <col width="70px" />
  33. <col width="70px" />
  34. <col width="70px" />
  35. <col width="70px" />
  36. <col width="70px" />
  37. <col width="70px" />
  38. <col width="350px" />
  39. <tr>
  40. <th class="text-left">套餐名称</th>
  41. <th class="text-center"><i class="wi wi-wx-apply" style="font-size: 24px"></i></th>
  42. <th class="text-center"><i class="wi wi-wxapp-apply" style="font-size: 24px"></i></th>
  43. <th class="text-center"><i class="wi wi-wx-template" style="font-size: 24px"></i></th>
  44. <th class="text-center"><i class="wi wi-pc-apply" style="font-size: 24px"></i></th>
  45. <th class="text-center"><i class="wi wi-app-apply" style="font-size: 24px"></i></th>
  46. <th class="text-center"><i class="wi wi-xzapp-apply" style="font-size: 24px"></i></th>
  47. <th class="text-center"><i class="wi wi-aliapp-apply" style="font-size: 24px"></i></th>
  48. <th class="text-right">操作</th>
  49. </tr>
  50. {loop $modules_group_list $module_group}
  51. <tr >
  52. <td class="text-left">{$module_group['name']}</td>
  53. <td class="text-center"><span data-toggle="tooltip" data-placement="bottom" title="" data-original-title="公众号应用个数">{php echo intval($module_group['account_num'])}</span></td>
  54. <td class="text-center"><span data-toggle="tooltip" data-placement="bottom" title="" data-original-title="微信小程序应用个数">{php echo intval($module_group['wxapp_num'])}</span></td>
  55. <td class="text-center"><span data-toggle="tooltip" data-placement="bottom" title="" data-original-title="模版个数">{php echo intval($module_group['template_num'])}</span></td>
  56. <td class="text-center"><span data-toggle="tooltip" data-placement="bottom" title="" data-original-title="PC应用个数">{php echo intval($module_group['webapp_num'])}</span></td>
  57. <td class="text-center"><span data-toggle="tooltip" data-placement="bottom" title="" data-original-title="APP应用个数">{php echo intval($module_group['phoneapp_num'])}</span></td>
  58. <td class="text-center"><span data-toggle="tooltip" data-placement="bottom" title="" data-original-title="熊掌号应用个数">{php echo intval($module_group['xzapp_num'])}</span></td>
  59. <td class="text-center"><span data-toggle="tooltip" data-placement="bottom" title="" data-original-title="支付宝小程序应用个数">{php echo intval($module_group['aliapp_num'])}</span></td>
  60. <td>
  61. <div class="link-group">
  62. <a href="javascript:;" class="color-default js-unfold" data-toggle="table-collapse" data-target="toggle-{$module_group['id']}" ng-click="changeText($event)">展开</a>
  63. {if $_W['role'] == ACCOUNT_MANAGE_NAME_FOUNDER || $_W['role'] == ACCOUNT_MANAGE_NAME_VICE_FOUNDER}
  64. <a href="{php echo url('module/group/post', array('id' => $module_group['id']))}">编辑套餐</a>
  65. <a href="{php echo url('module/group/delete', array('id' => $module_group['id']))}" class="del" onclick="return confirm('确定要删除套餐吗?')">删除</a>
  66. {/if}
  67. </div>
  68. </td>
  69. </tr>
  70. <tr class="collapse bg-light-gray" aria-expanded="true" data-id="toggle-{$module_group['id']}">
  71. <td colspan="10">
  72. <div class="col-sm-1 color-gray text-left we7-padding-none">公众号应用</div>
  73. <div class="col-sm-11">
  74. {loop $module_group['account_modules'] $module}
  75. <div class="col-sm-3 text-left text-over">
  76. <!--<img src="{$module['logo']}" style="width:50px;height:50px;">-->
  77. <!--<a href="">{$module['title']}</a>-->
  78. {if empty($module['main_module'])}
  79. <img src="{$module['logo']}" alt="">
  80. {$module['title']}
  81. {else}
  82. <span class="img">
  83. <img src="{$module['logo']}" alt="子应用icon" class="plugin-img"/>
  84. <img src="{$modules[$module['main_module']]['logo']}" alt="主应用icon" class="module-img"/>
  85. </span>
  86. {/if}
  87. </div>
  88. {/loop}
  89. </div>
  90. </td>
  91. </tr>
  92. <tr class="collapse bg-light-gray" aria-expanded="true" data-id="toggle-{$module_group['id']}">
  93. <td colspan="10">
  94. <div class="col-sm-1 color-gray text-left we7-padding-none">微信小程序应用</div>
  95. <div class="col-sm-11">
  96. {loop $module_group['wxapp_modules'] $wxapp}
  97. <div class="col-sm-3 text-left text-over">
  98. <img src="{$wxapp['logo']}">
  99. <a href="">{$wxapp['title']}</a>
  100. </div>
  101. {/loop}
  102. </div>
  103. </td>
  104. </tr>
  105. <tr class="collapse bg-light-gray" aria-expanded="true" data-id="toggle-{$module_group['id']}">
  106. <td colspan="10">
  107. <div class="col-sm-1 color-gray text-left we7-padding-none">PC应用</div>
  108. <div class="col-sm-11">
  109. {loop $module_group['webapp_modules'] $webapp}
  110. <div class="col-sm-3 text-left text-over">
  111. <img src="{$webapp['logo']}">
  112. <a href="">{$webapp['title']}</a>
  113. </div>
  114. {/loop}
  115. </div>
  116. </td>
  117. </tr>
  118. <tr class="collapse bg-light-gray" aria-expanded="true" data-id="toggle-{$module_group['id']}">
  119. <td colspan="10">
  120. <div class="col-sm-1 color-gray text-left we7-padding-none">APP应用</div>
  121. <div class="col-sm-11">
  122. {loop $module_group['phoneapp_modules'] $phoneapp}
  123. <div class="col-sm-3 text-left text-over">
  124. <img src="{$phoneapp['logo']}">
  125. <a href="">{$phoneapp['title']}</a>
  126. </div>
  127. {/loop}
  128. </div>
  129. </td>
  130. </tr>
  131. <tr class="collapse bg-light-gray" aria-expanded="true" data-id="toggle-{$module_group['id']}">
  132. <td colspan="10">
  133. <div class="col-sm-1 color-gray text-left we7-padding-none">熊掌号应用</div>
  134. <div class="col-sm-11">
  135. {loop $module_group['xzapp_modules'] $xzapp}
  136. <div class="col-sm-3 text-left text-over">
  137. <img src="{$xzapp['logo']}">
  138. <a href="">{$xzapp['title']}</a>
  139. </div>
  140. {/loop}
  141. </div>
  142. </td>
  143. </tr>
  144. <tr class="collapse bg-light-gray" aria-expanded="true" data-id="toggle-{$module_group['id']}">
  145. <td colspan="10">
  146. <div class="col-sm-1 color-gray text-left we7-padding-none">支付宝小程序应用</div>
  147. <div class="col-sm-11">
  148. {loop $module_group['aliapp_modules'] $aliapp}
  149. <div class="col-sm-3 text-left text-over">
  150. <img src="{$aliapp['logo']}">
  151. <a href="">{$aliapp['title']}</a>
  152. </div>
  153. {/loop}
  154. </div>
  155. </td>
  156. </tr>
  157. <tr class="collapse bg-light-gray" aria-expanded="true" data-id="toggle-{$module_group['id']}">
  158. <td colspan="10">
  159. <div class="col-sm-1 color-gray text-left we7-padding-none">模板</div>
  160. <div class="col-sm-11">
  161. {loop $module_group['templates'] $template}
  162. <div class="col-sm-3 text-left text-over">
  163. <i class="glyphicon glyphicon-th-large"></i>
  164. <a href="">{$template['title']}</a>
  165. </div>
  166. {/loop}
  167. </div>
  168. </td>
  169. </tr>
  170. {/loop}
  171. </table>
  172. </div>
  173. </div>
  174. <div class="pull-right">
  175. {$pager}
  176. </div>
  177. <script>
  178. angular.bootstrap($('.js-system-module_group'), ['moduleApp']);
  179. $('[data-toggle="table-collapse"]').on('click',function(){
  180. var id = '[data-id="'+$(this).data('target')+'"]';
  181. $(id).collapse('toggle');
  182. });
  183. </script>
  184. {elseif $do == 'post'}
  185. <div class="js-modulegroup-post" ng-controller="moduleGroupPostCtrl" ng-cloak>
  186. <div class="combo-list-add">
  187. <ol class="breadcrumb we7-breadcrumb">
  188. <a href="{php echo url('module/group')}"><i class="wi wi-back-circle"></i> </a>
  189. <li>
  190. <a href="{php echo url('module/group') }">套餐应用列表</a>
  191. </li>
  192. <li>
  193. 添加套餐应用列表
  194. </li>
  195. </ol>
  196. <div class="we7-form">
  197. <div class="form-group">
  198. <label for="" class="control-label col-sm-3">应用套餐名称</label>
  199. <div class="form-controls col-sm-8">
  200. <input type="text" ng-model="moduleGroup.name" class="form-control"/>
  201. </div>
  202. </div>
  203. </div>
  204. <div class="panel we7-panel">
  205. <div class="panel-heading">
  206. 选择公众号应用
  207. </div>
  208. <div class="panel-body we7-padding">
  209. <div class="row">
  210. <div class="col-sm-2 text-left" ng-repeat="module in groupHaveModuleApp" style="overflow: hidden">
  211. <img ng-src="{{ module.logo }}" alt="" style="width:33px;height:33px;" ng-if="module.main_module == ''">
  212. <span class="img" ng-if="module.main_module != ''">
  213. <img ng-src="{{ module.logo }}" alt="子应用icon" class="plugin-img"/>
  214. <img ng-src="{{ groupHaveModuleApp[module.main_module].main_module_logo || groupNotHaveModuleApp[module.main_module].main_module_logo }}" alt="主应用icon" class="module-img"/>
  215. </span>
  216. <span class="name">{{ module.title }}</span>
  217. <span class="del bg-default" ng-click="delHaveModule(module)">删除</span>
  218. </div>
  219. <div class="col-sm-2 add-more">
  220. <div class="we7-input-img input-more input-img">
  221. <a href="" class="input-addon" ng-click="addModule()">
  222. <span class="color-gray"></span>
  223. </a>
  224. </div>
  225. </div>
  226. </div>
  227. </div>
  228. </div>
  229. <div class="panel we7-panel">
  230. <div class="panel-heading">
  231. 选择微信小程序应用
  232. </div>
  233. <div class="panel-body we7-padding">
  234. <div class="row">
  235. <div class="col-sm-2 text-left" ng-repeat="module in groupHaveModuleWxapp" style="overflow: hidden">
  236. <img ng-src="{{ module.logo }}" alt="" class="img">{{ module.title }}
  237. <span class="del bg-default" ng-click="delHaveModuleWxapp(module)">删除</span>
  238. </div>
  239. <div class="col-sm-2 add-more">
  240. <div class="we7-input-img input-more input-img">
  241. <a href="" class="input-addon" ng-click="addModuleWxapp()">
  242. <span class="color-gray"></span>
  243. </a>
  244. </div>
  245. </div>
  246. </div>
  247. </div>
  248. </div>
  249. <div class="panel we7-panel">
  250. <div class="panel-heading">
  251. 选择模板
  252. </div>
  253. <div class="panel-body we7-padding">
  254. <div class="row">
  255. <div class="col-sm-2 text-left text-over" ng-repeat="template in groupHaveTemplate">
  256. <i class="wi wi-home"></i>
  257. <a href="">{{ template.title }}</a>
  258. <span class="del bg-default" ng-click="delHaveTemplate(template)">删除</span>
  259. </div>
  260. <div class="col-sm-2 add-more">
  261. <div class="we7-input-img input-more input-img">
  262. <a href="" class="input-addon" ng-click="adTemplate()">
  263. <span class="color-gray"></span>
  264. </a>
  265. </div>
  266. </div>
  267. </div>
  268. </div>
  269. </div>
  270. <div class="panel we7-panel">
  271. <div class="panel-heading">
  272. 选择PC应用
  273. </div>
  274. <div class="panel-body we7-padding">
  275. <div class="row">
  276. <div class="col-sm-2 text-left" ng-repeat="module in groupHaveModuleWebapp" style="overflow: hidden">
  277. <img ng-src="{{ module.logo }}" alt="" class="img">{{ module.title }}
  278. <span class="del bg-default" ng-click="delHaveModuleWebapp(module)">删除</span>
  279. </div>
  280. <div class="col-sm-2 add-more">
  281. <div class="we7-input-img input-more input-img">
  282. <a href="" class="input-addon" ng-click="addModuleWebapp()">
  283. <span class="color-gray"></span>
  284. </a>
  285. </div>
  286. </div>
  287. </div>
  288. </div>
  289. </div>
  290. <div class="panel we7-panel">
  291. <div class="panel-heading">
  292. 选择APP应用
  293. </div>
  294. <div class="panel-body we7-padding">
  295. <div class="row">
  296. <div class="col-sm-2 text-left" ng-repeat="module in groupHaveModulePhoneapp" style="overflow: hidden">
  297. <img ng-src="{{ module.logo }}" alt="" class="img">{{ module.title }}
  298. <span class="del bg-default" ng-click="delHaveModulePhoneapp(module)">删除</span>
  299. </div>
  300. <div class="col-sm-2 add-more">
  301. <div class="we7-input-img input-more input-img">
  302. <a href="" class="input-addon" ng-click="addModulePhoneapp()">
  303. <span class="color-gray"></span>
  304. </a>
  305. </div>
  306. </div>
  307. </div>
  308. </div>
  309. </div>
  310. <div class="panel we7-panel">
  311. <div class="panel-heading">
  312. 选择熊掌号应用
  313. </div>
  314. <div class="panel-body we7-padding">
  315. <div class="row">
  316. <div class="col-sm-2 text-left" ng-repeat="module in groupHaveModuleXzapp" style="overflow: hidden">
  317. <img ng-src="{{ module.logo }}" alt="" class="img">{{ module.title }}
  318. <span class="del bg-default" ng-click="delHaveModuleXzapp(module)">删除</span>
  319. </div>
  320. <div class="col-sm-2 add-more">
  321. <div class="we7-input-img input-more input-img">
  322. <a href="" class="input-addon" ng-click="addModuleXzapp()">
  323. <span class="color-gray"></span>
  324. </a>
  325. </div>
  326. </div>
  327. </div>
  328. </div>
  329. </div>
  330. <div class="panel we7-panel">
  331. <div class="panel-heading">
  332. 选择支付宝小程序应用
  333. </div>
  334. <div class="panel-body we7-padding">
  335. <div class="row">
  336. <div class="col-sm-2 text-left" ng-repeat="module in groupHaveModuleAliapp" style="overflow: hidden">
  337. <img ng-src="{{ module.logo }}" alt="" class="img">{{ module.title }}
  338. <span class="del bg-default" ng-click="delHaveModuleAliapp(module)">删除</span>
  339. </div>
  340. <div class="col-sm-2 add-more">
  341. <div class="we7-input-img input-more input-img">
  342. <a href="" class="input-addon" ng-click="addModuleAliapp()">
  343. <span class="color-gray"></span>
  344. </a>
  345. </div>
  346. </div>
  347. </div>
  348. </div>
  349. </div>
  350. </div>
  351. <div class="uploader-modal modal fade module" id="add_template" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
  352. <div class="modal-dialog we7-modal-dialog" style="width:800px">
  353. <div class="modal-content">
  354. <div class="modal-header">
  355. <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
  356. <h4 class="modal-title">添加模板(点击添加)</h4>
  357. </div>
  358. <div class="modal-body material-content clearfix">
  359. <div class="material-body">
  360. <div class="row">
  361. <div class="col-sm-2 select-module" ng-repeat="template in groupNotHaveTemplate" ng-click="selectOrCancelModule(template, 'template')">
  362. <div class="item" ng-class="{true:'active',false:''}[template.selected]">
  363. <i class="wi wi-home" style="color: #ddd;font-size: 48px;position:relative; top:-15px; margin: 0;"></i>
  364. <div class="name">{{ template.title }}</div>
  365. <div class="mask">
  366. <span class="wi wi-right"></span>
  367. </div>
  368. </div>
  369. </div>
  370. </div>
  371. </div>
  372. <!--注意全部有分页-->
  373. <div class="material-pager text-right clearfix">
  374. <div class="pull-left we7-form">
  375. <input type="checkbox" id="selected-all2" ng-change= 'selecteAllTemplate(alltemplatesel)' ng-model='alltemplatesel'>
  376. <label for="selected-all2">全选</label>
  377. </div>
  378. <ul class="pagination">
  379. </ul>
  380. </div>
  381. </div>
  382. <div class="modal-footer">
  383. <button type="button" class="btn btn-primary" ng-click="addHaveTemplate()">确定</button>
  384. <button type="button" class="btn btn-default" ng-click="cancel('add_template')">取消</button>
  385. </div>
  386. </div>
  387. </div>
  388. </div>
  389. <div class="uploader-modal modal fade module" id="add_module" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
  390. <div class="modal-dialog modal-dialog modal-lg we7-modal-dialog">
  391. <div class="modal-content">
  392. <div class="modal-header">
  393. <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
  394. <h4 class="modal-title">添加模块(点击添加)</h4>
  395. </div>
  396. <div class="modal-body material-content clearfix">
  397. <div class="material-head">
  398. <form action="" method="get" class="form-horizontal clearfix form-inline" role="form">
  399. <div class="input-group pull-left col-sm-4">
  400. <input type="text" name="keyword" id="" ng-model='keyword' ng-change="filterKeyword(keyword)" class="form-control" placeholder="搜索关键字"/>
  401. <span class="input-group-btn"><button type="button" class="btn btn-default"><i class="wi wi-search"></i></button></span>
  402. </div>
  403. </form>
  404. </div>
  405. <div class="material-body">
  406. <div class="row">
  407. <div class="col-sm-2 select-module" ng-show="!module.hide" ng-repeat="module in groupNotHaveModuleApp" ng-click="selectOrCancelModule(module, 'module')">
  408. <div class="item" ng-class="{true:'active',false:''}[module.selected]">
  409. <img ng-src="{{ module.logo }}" alt="" class="icon" ng-if="module.main_module == ''"/>
  410. <span class="img" ng-if="module.main_module != ''">
  411. <img ng-src="{{ module.logo }}" alt="子应用icon" class="plugin-img"/>
  412. <img ng-src="{{ module.main_module_logo }}" alt="主应用icon" class="module-img"/>
  413. </span>
  414. <div class="name">{{ module.title }}</div>
  415. <div class="mask">
  416. <span class="wi wi-right"></span>
  417. </div>
  418. </div>
  419. </div>
  420. </div>
  421. </div>
  422. <!--注意全部有分页-->
  423. <div class="material-pager text-right clearfix">
  424. <div class="pull-left we7-form">
  425. <input type="checkbox" id="selected-all" ng-change= 'selecteAllModule(allmodulesel)' ng-model='allmodulesel'>
  426. <label for="selected-all">全选</label>
  427. </div>
  428. <ul class="pagination">
  429. </ul>
  430. </div>
  431. </div>
  432. <div class="modal-footer">
  433. <button type="button" class="btn btn-primary" ng-click="addHaveModule()">确定</button>
  434. <button type="button" class="btn btn-default" ng-click="cancel('add_module')">取消</button>
  435. </div>
  436. </div>
  437. </div>
  438. </div>
  439. <div class="uploader-modal modal fade module" id="add_module_wxapp" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
  440. <div class="modal-dialog we7-modal-dialog" >
  441. <div class="modal-content">
  442. <div class="modal-header">
  443. <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
  444. <h4 class="modal-title">添加微信小程序(点击添加)</h4>
  445. </div>
  446. <div class="modal-body material-content clearfix">
  447. <div class="material-body">
  448. <div class="row">
  449. <div class="col-sm-2 select-module" ng-repeat="module in groupNotHaveModuleWxapp" ng-click="selectOrCancelModule(module, 'module_wxapp')">
  450. <div class="item" ng-class="{true:'active',false:''}[module.selected]">
  451. <img ng-src="{{ module.logo }}" alt="" class="icon" ng-if="module.main_module == ''"/>
  452. <div class="name">{{ module.title }}</div>
  453. <div class="mask">
  454. <span class="wi wi-right"></span>
  455. </div>
  456. </div>
  457. </div>
  458. </div>
  459. </div>
  460. <!--注意全部有分页-->
  461. <div class="material-pager text-right clearfix">
  462. <div class="pull-left we7-form">
  463. <input type="checkbox" id="selected-all1" ng-change="selecteAllWxapp(allwxappsel)" ng-model="allwxappsel">
  464. <label for="selected-all1">全选</label>
  465. </div>
  466. <ul class="pagination">
  467. </ul>
  468. </div>
  469. </div>
  470. <div class="modal-footer">
  471. <button type="button" class="btn btn-primary" ng-click="addHaveModuleWxapp()">确定</button>
  472. <button type="button" class="btn btn-default" ng-click="cancel('add_module_wxapp')">取消</button>
  473. </div>
  474. </div>
  475. </div>
  476. </div>
  477. <div class="uploader-modal modal fade module" id="add_module_webapp" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
  478. <div class="modal-dialog we7-modal-dialog" >
  479. <div class="modal-content">
  480. <div class="modal-header">
  481. <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
  482. <h4 class="modal-title">添加PC应用(点击添加)</h4>
  483. </div>
  484. <div class="modal-body material-content clearfix">
  485. <div class="material-body">
  486. <div class="row">
  487. <div class="col-sm-2 select-module" ng-repeat="module in groupNotHaveModuleWebapp" ng-click="selectOrCancelModule(module, 'module_webapp')">
  488. <div class="item" ng-class="{true:'active',false:''}[module.selected]">
  489. <img ng-src="{{ module.logo }}" alt="" class="icon"/>
  490. <div class="name">{{ module.title }}</div>
  491. <div class="mask">
  492. <span class="wi wi-right"></span>
  493. </div>
  494. </div>
  495. </div>
  496. </div>
  497. </div>
  498. <!--注意全部有分页-->
  499. <div class="material-pager text-right clearfix">
  500. <div class="pull-left we7-form">
  501. <input type="checkbox" id="selected-all3" ng-change="selecteAllWebapp(allwebappsel)" ng-model="allwebappsel">
  502. <label for="selected-all3">全选</label>
  503. </div>
  504. <ul class="pagination">
  505. </ul>
  506. </div>
  507. </div>
  508. <div class="modal-footer">
  509. <button type="button" class="btn btn-primary" ng-click="addHaveModuleWebapp()">确定</button>
  510. <button type="button" class="btn btn-default" ng-click="cancel('add_module_webapp')">取消</button>
  511. </div>
  512. </div>
  513. </div>
  514. </div>
  515. <div class="uploader-modal modal fade module" id="add_module_phoneapp" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
  516. <div class="modal-dialog we7-modal-dialog" >
  517. <div class="modal-content">
  518. <div class="modal-header">
  519. <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
  520. <h4 class="modal-title">添加APP应用(点击添加)</h4>
  521. </div>
  522. <div class="modal-body material-content clearfix">
  523. <div class="material-body">
  524. <div class="row">
  525. <div class="col-sm-2 select-module" ng-repeat="module in groupNotHaveModulePhoneapp" ng-click="selectOrCancelModule(module, 'module_phoneapp')">
  526. <div class="item" ng-class="{true:'active',false:''}[module.selected]">
  527. <img ng-src="{{ module.logo }}" alt="" class="icon"/>
  528. <div class="name">{{ module.title }}</div>
  529. <div class="mask">
  530. <span class="wi wi-right"></span>
  531. </div>
  532. </div>
  533. </div>
  534. </div>
  535. </div>
  536. <!--注意全部有分页-->
  537. <div class="material-pager text-right clearfix">
  538. <div class="pull-left we7-form">
  539. <input type="checkbox" id="selected-all4" ng-change="selecteAllPhoneapp(allphoneappsel)" ng-model="allphoneappsel">
  540. <label for="selected-all4">全选</label>
  541. </div>
  542. <ul class="pagination">
  543. </ul>
  544. </div>
  545. </div>
  546. <div class="modal-footer">
  547. <button type="button" class="btn btn-primary" ng-click="addHaveModulePhoneapp()">确定</button>
  548. <button type="button" class="btn btn-default" ng-click="cancel('add_module_phoneapp')">取消</button>
  549. </div>
  550. </div>
  551. </div>
  552. </div>
  553. <div class="uploader-modal modal fade module" id="add_module_xzapp" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
  554. <div class="modal-dialog we7-modal-dialog" >
  555. <div class="modal-content">
  556. <div class="modal-header">
  557. <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
  558. <h4 class="modal-title">添加熊掌号应用(点击添加)</h4>
  559. </div>
  560. <div class="modal-body material-content clearfix">
  561. <div class="material-body">
  562. <div class="row">
  563. <div class="col-sm-2 select-module" ng-repeat="module in groupNotHaveModuleXzapp" ng-click="selectOrCancelModule(module, 'module_xzapp')">
  564. <div class="item" ng-class="{true:'active',false:''}[module.selected]">
  565. <img ng-src="{{ module.logo }}" alt="" class="icon"/>
  566. <div class="name">{{ module.title }}</div>
  567. <div class="mask">
  568. <span class="wi wi-right"></span>
  569. </div>
  570. </div>
  571. </div>
  572. </div>
  573. </div>
  574. <!--注意全部有分页-->
  575. <div class="material-pager text-right clearfix">
  576. <div class="pull-left we7-form">
  577. <input type="checkbox" id="selected-all5" ng-change="selecteAllXzapp(allxzappsel)" ng-model="allxzappsel">
  578. <label for="selected-all5">全选</label>
  579. </div>
  580. <ul class="pagination">
  581. </ul>
  582. </div>
  583. </div>
  584. <div class="modal-footer">
  585. <button type="button" class="btn btn-primary" ng-click="addHaveModuleXzapp()">确定</button>
  586. <button type="button" class="btn btn-default" ng-click="cancel('add_module_xzapp')">取消</button>
  587. </div>
  588. </div>
  589. </div>
  590. </div>
  591. <div class="uploader-modal modal fade module" id="add_module_aliapp" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
  592. <div class="modal-dialog we7-modal-dialog" >
  593. <div class="modal-content">
  594. <div class="modal-header">
  595. <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button>
  596. <h4 class="modal-title">添加支付宝小程序应用(点击添加)</h4>
  597. </div>
  598. <div class="modal-body material-content clearfix">
  599. <div class="material-body">
  600. <div class="row">
  601. <div class="col-sm-2 select-module" ng-repeat="module in groupNotHaveModuleAliapp" ng-click="selectOrCancelModule(module, 'module_aliapp')">
  602. <div class="item" ng-class="{true:'active',false:''}[module.selected]">
  603. <img ng-src="{{ module.logo }}" alt="" class="icon"/>
  604. <div class="name">{{ module.title }}</div>
  605. <div class="mask">
  606. <span class="wi wi-right"></span>
  607. </div>
  608. </div>
  609. </div>
  610. </div>
  611. </div>
  612. <!--注意全部有分页-->
  613. <div class="material-pager text-right clearfix">
  614. <div class="pull-left we7-form">
  615. <input type="checkbox" id="selected-all6" ng-change="selecteAllAliapp(allaliappsel)" ng-model="allaliappsel">
  616. <label for="selected-all6">全选</label>
  617. </div>
  618. <ul class="pagination">
  619. </ul>
  620. </div>
  621. </div>
  622. <div class="modal-footer">
  623. <button type="button" class="btn btn-primary" ng-click="addHaveModuleAliapp()">确定</button>
  624. <button type="button" class="btn btn-default" ng-click="cancel('add_module_aliapp')">取消</button>
  625. </div>
  626. </div>
  627. </div>
  628. </div>
  629. <span class="btn btn-primary we7-padding-horizontal" ng-click="saveGroup()">提交</span>
  630. </div>
  631. <script>
  632. require(['underscore'], function() {
  633. angular.module('moduleApp').value('config', {
  634. 'moduleGroup' : {php echo json_encode($module_group)},
  635. 'groupHaveModuleApp' : {php echo json_encode($group_have_module_app)},
  636. 'groupHaveModuleWxapp' : {php echo json_encode($group_have_module_wxapp)},
  637. 'groupHaveModuleWebapp' : {php echo json_encode($group_have_module_webapp)},
  638. 'groupHaveModulePhoneapp' : {php echo json_encode($group_have_module_phoneapp)},
  639. 'groupHaveModuleXzapp' : {php echo json_encode($group_have_module_xzapp)},
  640. 'groupHaveModuleAliapp' : {php echo json_encode($group_have_module_aliapp)},
  641. 'groupNotHaveModuleApp' : {php echo json_encode($group_not_have_module_app)},
  642. 'groupNotHaveModuleWebapp' : {php echo json_encode($group_not_have_module_webapp)}, // angular filter 只能数组
  643. 'groupNotHaveModulePhoneapp' : {php echo json_encode($group_not_have_module_phoneapp)},
  644. 'groupNotHaveModuleWxapp' : {php echo json_encode($group_not_have_module_wxapp)},
  645. 'groupNotHaveModuleXzapp' : {php echo json_encode($group_not_have_module_xzapp)},
  646. 'groupNotHaveModuleAliapp' : {php echo json_encode($group_not_have_module_aliapp)},
  647. 'groupHaveTemplate' : {php echo json_encode($group_have_template)},
  648. 'groupNotHaveTemplate' : {php echo json_encode($group_not_have_template)},
  649. 'url' : "{php echo url('module/group/save')}"
  650. });
  651. angular.bootstrap($('.js-modulegroup-post'), ['moduleApp']);
  652. $('[data-toggle="table-collapse"]').on('click',function(){
  653. var id = '[data-id="'+$(this).data('target')+'"]';
  654. $(id).collapse('toggle');
  655. });
  656. });
  657. </script>
  658. {/if}
  659. {template 'common/footer'}