category_tree.tpl.php 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. <?php
  2. defined('IN_ADMIN') or exit('No permission resources.');
  3. include $this->admin_tpl('header','admin');?>
  4. <div class="bk10"></div>
  5. <link rel="stylesheet" href="<?php echo CSS_PATH;?>jquery.treeview.css" type="text/css" />
  6. <script type="text/javascript" src="<?php echo JS_PATH;?>jquery.cookie.js"></script>
  7. <script type="text/javascript" src="<?php echo JS_PATH;?>jquery.treeview.js"></script>
  8. <?php if($ajax_show) {?>
  9. <script type="text/javascript" src="<?php echo JS_PATH;?>jquery.treeview.async.js"></script>
  10. <?php }?>
  11. <SCRIPT LANGUAGE="JavaScript">
  12. <!--
  13. <?php if($ajax_show) {?>
  14. $(document).ready(function(){
  15. $("#category_tree").treeview({
  16. control: "#treecontrol",
  17. url: "index.php?m=content&c=content&a=public_sub_categorys&menuid=<?php echo $_GET['menuid']?>",
  18. ajax: {
  19. data: {
  20. "additional": function() {
  21. return "time: " + new Date;
  22. },
  23. "modelid": function() {
  24. return "<?php echo $modelid?>";
  25. }
  26. },
  27. type: "post"
  28. }
  29. });
  30. });
  31. <?php } else {?>
  32. $(document).ready(function(){
  33. $("#category_tree").treeview({
  34. control: "#treecontrol",
  35. persist: "cookie",
  36. cookieId: "treeview-black"
  37. });
  38. });
  39. <?php }?>
  40. function open_list(obj) {
  41. window.top.$("#current_pos_attr").html($(obj).html());
  42. }
  43. //-->
  44. </SCRIPT>
  45. <style type="text/css">
  46. .filetree *{white-space:nowrap;}
  47. .filetree span.folder, .filetree span.file{display:auto;padding:1px 0 1px 16px;}
  48. </style>
  49. <div id="treecontrol">
  50. <span style="display:none">
  51. <a href="#"></a>
  52. <a href="#"></a>
  53. </span>
  54. <a href="#"><img src="<?php echo IMG_PATH;?>minus.gif" /> <img src="<?php echo IMG_PATH;?>application_side_expand.png" /> 展开/收缩</a>
  55. </div>
  56. <?php
  57. if($_GET['from']=='block') {
  58. ?>
  59. <ul class="filetree treeview"><li class="collapsable"><div class="hitarea collapsable-hitarea"></div><span><img src="<?php echo IMG_PATH.'icon/home.png';?>" width="15" height="14">&nbsp;<a href='?m=block&c=block_admin&a=public_visualization&type=index' target='right'><?php echo L('block_site_index');?></a></span></li></ul>
  60. <?php } else { ?>
  61. <ul class="filetree treeview"><li class="collapsable"><div class="hitarea collapsable-hitarea"></div><span><img src="<?php echo IMG_PATH.'icon/box-exclaim.gif';?>" width="15" height="14">&nbsp;<a href='?m=content&c=content&a=public_checkall&menuid=822' target='right'><?php echo L('checkall_content');?></a></span></li></ul>
  62. <?php } echo $categorys; ?>