ManyouHelper.php 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. <?php
  2. /**
  3. * [Discuz!] (C)2001-2099 Comsenz Inc.
  4. * This is NOT a freeware, use is subject to license terms
  5. *
  6. * $Id: ManyouHelper.php 25512 2011-11-14 02:31:42Z yexinhao $
  7. */
  8. if(!defined('IN_DISCUZ')) {
  9. exit('Access Denied');
  10. }
  11. class Cloud_Service_ManyouHelper {
  12. protected static $_instance;
  13. public static function getInstance() {
  14. if (!(self::$_instance instanceof self)) {
  15. self::$_instance = new self();
  16. }
  17. return self::$_instance;
  18. }
  19. public function __construct() {
  20. }
  21. public function getMethodCode($module, $method) {
  22. $methods = array(
  23. 'Search.getUserGroupPermissions' => 10,
  24. 'Search.getUpdatedPosts' => 11,
  25. 'Search.removePostLogs' => 12,
  26. 'Search.getPosts' => 13,
  27. 'Search.getNewPosts' => 14,
  28. 'Search.getAllPosts' => 15,
  29. 'Search.removePosts' => 16,
  30. 'Search.getUpdatedThreads' => 17,
  31. 'Search.removeThreadLogs' => 18,
  32. 'Search.getThreads' => '1a',
  33. 'Search.getNewThreads' => '1b',
  34. 'Search.getAllThreads' => '1c',
  35. 'Search.getForums' => '1d',
  36. 'Search.recycleThreads' => '1e',
  37. 'Search.recycleThreads' => '1f',
  38. 'Search.setConfig' => '20',
  39. 'Search.getConfig' => '21',
  40. 'Search.setHotWords' => '22',
  41. 'Cloud.getApps' => '30',
  42. 'Cloud.setApp' => '31',
  43. 'Cloud.openCloud' => '32',
  44. 'Cloud.getStatus' => '33',
  45. 'Connect.setConfig' => '34',
  46. 'Union.addAdvs' => '35',
  47. 'Common.setConfig' => '40',
  48. 'Common.getNav' => '41',
  49. 'Site.getUpdatedUsers' => '42',
  50. 'Site.getUpdatedFriends' => '43',
  51. 'Site.getAllUsers' => '44',
  52. 'Site.getStat' => '45',
  53. 'Users.getInfo' => '50',
  54. 'Users.getFriendInfo' => '51',
  55. 'Users.getExtraInfo' => '52',
  56. 'Friends.get' => '53',
  57. 'Friends.areFriends' => '54',
  58. 'Application.update' => '55',
  59. 'Application.remove' => '56',
  60. 'Application.setFlag' => '57',
  61. 'UserApplication.add' => '58',
  62. 'UserApplication.remove' => '5a',
  63. 'UserApplication.update' => '5b',
  64. 'UserApplication.getInstalled' => '5c',
  65. 'UserApplication.get' => '5d',
  66. 'Feed.publishTemplatizedAction' => '5e',
  67. 'Notifications.send' => '5f',
  68. 'Notifications.get' => '60',
  69. 'Profile.setMYML' => '61',
  70. 'Profile.setActionLink' => '62',
  71. 'Request.send' => '63',
  72. 'NewsFeed.get' => '64',
  73. 'VideoAuth.setAuthStatus' => '65',
  74. 'VideoAuth.auth' => '66',
  75. 'Users.getFormHash' => '67',
  76. 'Credit.get' => '70',
  77. 'Credit.update' => '71',
  78. 'MiniBlog.post' => '72',
  79. 'MiniBlog.get' => '73',
  80. 'Photo.createAlbum' => '74',
  81. 'Photo.updateAlbum' => '75',
  82. 'Photo.removeAlbum' => '76',
  83. 'Photo.getAlbums' => '77',
  84. 'Photo.upload' => '78',
  85. 'Photo.get' => '7a',
  86. 'Photo.update' => '7b',
  87. 'Photo.remove' => '7c',
  88. 'ImbotMsn.setBindStatus' => '7d',
  89. );
  90. return $methods[$module . '.' . $method];
  91. }
  92. }