_get.js 24 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226
  1. import _mixins from './_mixins';
  2. import _action from './_action';
  3. import _data from './_data';
  4. export default {
  5. /** 获得会话列表数据 */
  6. getChatList() {
  7. _mixins.methods.$httpSend({
  8. path: '/im/get/chatList',
  9. success(data) {
  10. // data.hasData = 1;
  11. // if(!data.length)data.hasData = 0;
  12. if (data.length) {
  13. data.sort((x, y) => {
  14. if (x.top == y.top) {
  15. return y.time - x.time;
  16. } else {
  17. return y.top - x.top;
  18. }
  19. })
  20. }
  21. _data.localData('chat_list', data);
  22. uni.$emit('data_chat_list', data);
  23. _action.setStatusTips();
  24. }
  25. });
  26. },
  27. getGroupChatList(data, sucess) {
  28. _mixins.methods.$httpSend({
  29. path: '/im/get/chatList',
  30. data: data,
  31. success(data) {
  32. console.log(1111)
  33. if (sucess) {
  34. sucess(data)
  35. }
  36. }
  37. });
  38. },
  39. /**
  40. * 获得对话数据
  41. * @param {
  42. 发送的数据
  43. send_data: {
  44. list_id: list_id,
  45. time: 0,
  46. 是否更新未读消息数
  47. is_up: 1,
  48. },
  49. 回调函数
  50. calllback(data){
  51. },
  52. 是否需要操作本地缓存数据
  53. is_action_data: 1,
  54. }
  55. */
  56. getChatData(config) {
  57. _mixins.methods.$httpSend({
  58. path: '/im/get/chatData',
  59. data: config.send_data,
  60. success(data) {
  61. // console.log('12312311213',data)
  62. if (config.is_action_data) {
  63. uni.$emit('data_chat_data', data);
  64. _data.localData(data.list_id, data);
  65. } else {
  66. console.log(data.list,'data_chat_data_unshift');
  67. uni.$emit('data_chat_data_unshift', data.list);
  68. }
  69. if ('callback' in config) {
  70. config.callback(data);
  71. }
  72. }
  73. });
  74. },
  75. /** 获得通讯录数据 */
  76. getFriendList(send_data, callback) {
  77. if (!send_data) {
  78. send_data = {};
  79. }
  80. _mixins.methods.$httpSend({
  81. path: '/im/get/friendList',
  82. data: send_data,
  83. success(data) {
  84. Object.keys(data.data).forEach(function(key) {
  85. console.log(key, data.data[key], 333);
  86. data.data[key].data.map((res, index) => {
  87. data.data[key].data[index].checked = false
  88. })
  89. })
  90. if (data.data.length || 'up' in send_data || Object.keys(data.data).length) {
  91. _data.localData('friend_list', data.data);
  92. uni.$emit('data_friend_list', data.data);
  93. }
  94. if (callback) {
  95. callback(data);
  96. }
  97. }
  98. });
  99. },
  100. /** 获得朋友圈数据 data要发送的数据 type 0加载最新数据 1加载历史数据 */
  101. getCircleList(send_data, callback) {
  102. _mixins.methods.$httpSend({
  103. path: '/im/get/circleData',
  104. data: send_data,
  105. success(data) {
  106. let key1 = 'circle_data',
  107. _data_key1 = 'data_circle_data';
  108. let circle_data = _data.localData(key1);
  109. if (!circle_data) {
  110. circle_data = [];
  111. }
  112. if (send_data.type) {
  113. circle_data.push(...data.data);
  114. } else {
  115. circle_data.unshift(...data.data);
  116. }
  117. uni.$emit(_data_key1, circle_data);
  118. _data.localData(key1, circle_data);
  119. if ('update' in send_data) {
  120. let key2 = 'circle_data_user',
  121. _data_key2 = 'data_circle_data_user';
  122. let circle_data2 = _data.localData(key2);
  123. if (!circle_data) {
  124. circle_data = [];
  125. }
  126. if (send_data.type) {
  127. circle_data2.push(...data.data);
  128. } else {
  129. circle_data2.unshift(...data.data);
  130. }
  131. uni.$emit(_data_key2, circle_data2);
  132. _data.localData(key2, circle_data2);
  133. }
  134. if (callback) {
  135. callback(data);
  136. }
  137. }
  138. });
  139. },
  140. /** 获得基础数据 */
  141. getUserCircleList(send_data, callback) {
  142. console.log('to')
  143. _mixins.methods.$httpSend({
  144. path: '/im/get/circleData',
  145. data: send_data,
  146. success(data) {
  147. console.log(1111111)
  148. let key2 = 'circle_data_user',
  149. _data_key2 = 'data_circle_data_user';
  150. let circle_data2 = _data.localData(key2);
  151. if (!circle_data2) {
  152. circle_data2 = [];
  153. }
  154. if (send_data.type) {
  155. circle_data2.push(...data.data);
  156. } else {
  157. circle_data2.unshift(...data.data);
  158. }
  159. uni.$emit(_data_key2, circle_data2);
  160. _data.localData(key2, circle_data2);
  161. if (callback) {
  162. callback(data);
  163. }
  164. }
  165. });
  166. },
  167. base() {
  168. _mixins.methods.$httpSend({
  169. path: '/im/get/base',
  170. success(data) {
  171. data.user_info.photo += '?_=' + Math.random();
  172. data.user_info.circle_img += '?_=' + Math.random();
  173. _data.data('user_info', data.user_info);
  174. uni.$emit('data_user_info', data.user_info);
  175. _data.data('bottom_url', data.bottom_url);
  176. _data.data('new_friend_tips_num', data.new_friend_tips_num);
  177. _data.data('no_reader_chat_num', data.no_reader_chat_num);
  178. _data.data('no_reader_circle', data.no_reader_circle);
  179. _data.data('no_reader_circle_chat_num', data.no_reader_circle_chat_num);
  180. _data.data('new_group_tips_num', data.new_group_tips_num);
  181. _data.data('kefu_list_id', data.kefu_list_id);
  182. _action.setStatusTips();
  183. _action.downloadPhoto();
  184. },
  185. fail(err) {
  186. console.log("err", err);
  187. }
  188. });
  189. },
  190. /** 获得好友申请列表数据 */
  191. getFriendApplyList(callback) {
  192. _mixins.methods.$httpSend({
  193. path: '/im/get/applyFriend',
  194. success(data) {
  195. _data.localData('friend_apply_list', data);
  196. uni.$emit('data_friend_apply_list', data);
  197. if (callback) {
  198. callback(data);
  199. }
  200. }
  201. });
  202. },
  203. /** 获得群认证列表数据 */
  204. getGroupApplyList(callback) {
  205. _mixins.methods.$httpSend({
  206. path: '/im/get/applyGroup',
  207. success(data) {
  208. _data.localData('group_apply_list', data);
  209. uni.$emit('data_group_apply_data', data);
  210. if (callback) {
  211. callback(data);
  212. }
  213. }
  214. });
  215. },
  216. //搜索聊天记录
  217. serchChatMsg(params, callback) {
  218. _mixins.methods.$httpSend({
  219. path: '/im/get/searchCahtMsg',
  220. data: params,
  221. success(data) {
  222. if (callback) {
  223. callback(data);
  224. }
  225. }
  226. });
  227. },
  228. //搜索好友
  229. searchFriends(params, callback) {
  230. _mixins.methods.$httpSend({
  231. path: '/im/get/searchFriends',
  232. data: params,
  233. success(data) {
  234. if (callback) {
  235. callback(data);
  236. }
  237. }
  238. });
  239. },
  240. //搜索群聊成员
  241. searchGroupFriends(params, callback) {
  242. _mixins.methods.$httpSend({
  243. path: '/im/group/searchFriends',
  244. data: params,
  245. success(data) {
  246. if (callback) {
  247. callback(data);
  248. }
  249. }
  250. });
  251. },
  252. //取消音/视频
  253. cancelCall(params, callback) {
  254. _mixins.methods.$httpSend({
  255. path: '/im/message/closeVideo',
  256. data: params,
  257. success(res) {
  258. if (callback) {
  259. callback(res);
  260. }
  261. }
  262. });
  263. },
  264. //同意/音视频
  265. agreeVedio(params, callback) {
  266. _mixins.methods.$httpSend({
  267. path: '/im/message/agreeVedio',
  268. data: params,
  269. success(res) {
  270. if (callback) {
  271. callback(res);
  272. }
  273. }
  274. });
  275. },
  276. createHongBao(params, callback, fail_callback) {
  277. _mixins.methods.$httpSend({
  278. path: '/im/message/createHongBao',
  279. data: params,
  280. success(res) {
  281. if (callback) {
  282. callback(res);
  283. }
  284. },
  285. fail_callback(res) {
  286. if (fail_callback) {
  287. fail_callback(res)
  288. }
  289. }
  290. });
  291. },
  292. checkBeforePay(params, callback, fail_callback) {
  293. _mixins.methods.$httpSend({
  294. path: '/im/user/checkBeforePay',
  295. data: params,
  296. success(res) {
  297. if (callback) {
  298. callback(res);
  299. }
  300. },
  301. fail_callback(res) {
  302. if (fail_callback) {
  303. fail_callback(res)
  304. }
  305. }
  306. });
  307. },
  308. getHongBao(params, callback, fail_callback) {
  309. _mixins.methods.$httpSend({
  310. path: '/im/message/getHongBao',
  311. data: params,
  312. success(res) {
  313. if (callback) {
  314. callback(res);
  315. }
  316. },
  317. fail_callback(res) {
  318. if (fail_callback) {
  319. fail_callback(res)
  320. }
  321. }
  322. });
  323. },
  324. getUserCapitalList(params, callback) {
  325. _mixins.methods.$httpSend({
  326. path: '/im/get/getUserCapitalList',
  327. data: params,
  328. success(res) {
  329. if (callback) {
  330. callback(res);
  331. }
  332. },
  333. });
  334. },
  335. getUserbankList(params, callback) {
  336. _mixins.methods.$httpSend({
  337. path: '/im/get/getUserbankList',
  338. data: params,
  339. success(res) {
  340. if (callback) {
  341. callback(res);
  342. }
  343. },
  344. });
  345. },
  346. addUserBank(params, callback) {
  347. _mixins.methods.$httpSend({
  348. path: '/im/get/addUserBank',
  349. data: params,
  350. success(fireParams) {
  351. uni.$emit('update_bank_list_data', fireParams);
  352. if (callback) {
  353. callback(fireParams);
  354. }
  355. },
  356. });
  357. },
  358. setUserTradePassword(params, callback) {
  359. _mixins.methods.$httpSend({
  360. path: '/im/user/setUserTradePassword',
  361. data: params,
  362. success(fireParams) {
  363. if (callback) {
  364. callback(fireParams);
  365. }
  366. },
  367. });
  368. },
  369. checkUserTradePassword(params, callback) {
  370. _mixins.methods.$httpSend({
  371. path: '/im/user/checkUserTradePassword',
  372. data: params,
  373. success(fireParams) {
  374. if (callback) {
  375. callback(fireParams);
  376. }
  377. },
  378. });
  379. },
  380. sendContact(params, callback) {
  381. _mixins.methods.$httpSend({
  382. path: '/im/app/setUserContact',
  383. data: params,
  384. success(ret) {
  385. if (callback) {
  386. callback(ret);
  387. }
  388. },
  389. });
  390. },
  391. getOnlineList(params, callback) {
  392. _mixins.methods.$httpSend({
  393. path: '/im/agent/getOnlineList',
  394. data: params,
  395. success(ret) {
  396. if (callback) {
  397. callback(ret);
  398. }
  399. },
  400. });
  401. },
  402. sendCard(params, callback) { //发送名片
  403. _mixins.methods.$httpSend({
  404. path: '/im/message/sendCard',
  405. data: params,
  406. success(ret) {
  407. if (callback) {
  408. callback(ret);
  409. }
  410. },
  411. });
  412. },
  413. getHongBaoDetail(params, callback) {
  414. _mixins.methods.$httpSend({
  415. path: '/im/get/getHongBaoDetail',
  416. data: params,
  417. success(ret) {
  418. if (callback) {
  419. callback(ret);
  420. }
  421. },
  422. });
  423. },
  424. getUserInfo(params, callback) {
  425. _mixins.methods.$httpSend({
  426. path: '/im/get/getUserInfo',
  427. data: params,
  428. success(ret) {
  429. console.log(ret)
  430. _data.data('user_info', ret);
  431. uni.$emit('data_user_info', ret);
  432. if (callback) {
  433. callback(ret);
  434. }
  435. },
  436. });
  437. },
  438. payAmount(params, callback, fail_callback) {
  439. _mixins.methods.$httpSend({
  440. path: '/im/user/payAmount',
  441. data: params,
  442. success(ret) {
  443. if (callback) {
  444. callback(ret);
  445. }
  446. },
  447. fail_callback(res) {
  448. if (fail_callback) {
  449. fail_callback(res)
  450. }
  451. }
  452. });
  453. },
  454. collectAmount(params, callback, fail_callback) {
  455. _mixins.methods.$httpSend({
  456. path: '/im/user/collectAmount',
  457. data: params,
  458. success(ret) {
  459. if (callback) {
  460. callback(ret);
  461. }
  462. },
  463. fail_callback(res) {
  464. if (fail_callback) {
  465. fail_callback(res)
  466. }
  467. }
  468. });
  469. },
  470. charge(params, callback, fail_callback) {
  471. _mixins.methods.$httpSend({
  472. path: '/im/pay/userCharge',
  473. data: params,
  474. success(ret) {
  475. if (callback) {
  476. callback(ret);
  477. }
  478. },
  479. fail_callback(res) {
  480. if (fail_callback) {
  481. fail_callback(res)
  482. }
  483. }
  484. });
  485. },
  486. getVedioPayConfig(params, callback, fail_callback) {
  487. _mixins.methods.$httpSend({
  488. path: '/im/get/getVedioPayConfig',
  489. data: params,
  490. success(ret) {
  491. if (callback) {
  492. callback(ret);
  493. }
  494. },
  495. fail_callback(res) {
  496. if (fail_callback) {
  497. fail_callback(res)
  498. }
  499. }
  500. });
  501. },
  502. payCicleOrder(params, callback, fail_callback) {
  503. _mixins.methods.$httpSend({
  504. path: '/im/pay/payCircleOrder',
  505. data: params,
  506. success(ret) {
  507. //更新状态
  508. if (callback) {
  509. callback(ret);
  510. }
  511. },
  512. fail_callback(res) {
  513. if (fail_callback) {
  514. fail_callback(res)
  515. }
  516. }
  517. });
  518. },
  519. getUserOrderList(params, callback, fail_callback) {
  520. _mixins.methods.$httpSend({
  521. path: '/im/order/getUserOrderList',
  522. data: params,
  523. success(ret) {
  524. if (callback) {
  525. callback(ret);
  526. }
  527. },
  528. fail_callback(res) {
  529. if (fail_callback) {
  530. fail_callback(res)
  531. }
  532. }
  533. });
  534. },
  535. updateOrderStatus(params, callback, fail_callback) {
  536. _mixins.methods.$httpSend({
  537. path: '/im/order/updateOrderStatus',
  538. data: params,
  539. success(ret) {
  540. if (callback) {
  541. callback(ret);
  542. }
  543. },
  544. fail_callback(res) {
  545. if (fail_callback) {
  546. fail_callback(res)
  547. }
  548. }
  549. });
  550. },
  551. payVideoAamount(params, callback, fail_callback) {
  552. _mixins.methods.$httpSend({
  553. path: '/im/pay/payVideoAamount',
  554. data: params,
  555. success(ret) {
  556. if (callback) {
  557. callback(ret);
  558. }
  559. },
  560. fail_callback(res) {
  561. if (fail_callback) {
  562. fail_callback(res)
  563. }
  564. }
  565. });
  566. },
  567. updateUserSayType(params, callback, fail_callback) {
  568. _mixins.methods.$httpSend({
  569. path: '/im/action/updateUserSayType',
  570. data: params,
  571. success(ret) {
  572. if (callback) {
  573. callback(ret);
  574. }
  575. },
  576. fail_callback(res) {
  577. if (fail_callback) {
  578. fail_callback(res)
  579. }
  580. }
  581. });
  582. },
  583. getWithDrawConfig(params, callback, fail_callback) {
  584. _mixins.methods.$httpSend({
  585. path: '/im/withdraw/getWithDrawConfig',
  586. data: params,
  587. success(ret) {
  588. if (callback) {
  589. callback(ret);
  590. }
  591. },
  592. fail_callback(res) {
  593. if (fail_callback) {
  594. fail_callback(res)
  595. }
  596. }
  597. });
  598. },
  599. withDrawMoney(params, callback, fail_callback) {
  600. _mixins.methods.$httpSend({
  601. path: '/im/withdraw/withDrawMoney',
  602. data: params,
  603. success(ret) {
  604. if (callback) {
  605. callback(ret);
  606. }
  607. },
  608. fail_callback(res) {
  609. if (fail_callback) {
  610. fail_callback(res)
  611. }
  612. }
  613. });
  614. },
  615. updateMiaoqiang(params, callback, fail_callback) {
  616. _mixins.methods.$httpSend({
  617. path: '/im/vendor/bigRegQiang',
  618. data: params,
  619. success(ret) {
  620. if (callback) {
  621. callback(ret);
  622. }
  623. },
  624. fail_callback(res) {
  625. if (fail_callback) {
  626. fail_callback(res)
  627. }
  628. }
  629. });
  630. },
  631. createLeiHongBao(params, callback, fail_callback) {
  632. _mixins.methods.$httpSend({
  633. path: '/im/vendor/createLeiHongBao',
  634. data: params,
  635. success(ret) {
  636. if (callback) {
  637. callback(ret);
  638. }
  639. },
  640. fail_callback(res) {
  641. if (fail_callback) {
  642. fail_callback(res)
  643. }
  644. }
  645. });
  646. },
  647. getLeiHongBao(params, callback, fail_callback) {
  648. _mixins.methods.$httpSend({
  649. path: '/im/vendor/getLeiHongBao',
  650. data: params,
  651. success(ret) {
  652. if (callback) {
  653. callback(ret);
  654. }
  655. },
  656. fail_callback(res) {
  657. if (fail_callback) {
  658. fail_callback(res)
  659. }
  660. }
  661. });
  662. },
  663. setHongBaoConfig(params, callback, fail_callback) {
  664. _mixins.methods.$httpSend({
  665. path: '/im/vendor/setHongBaoConfig',
  666. data: params,
  667. success(ret) {
  668. if (callback) {
  669. callback(ret);
  670. }
  671. },
  672. fail_callback(res) {
  673. if (fail_callback) {
  674. fail_callback(res)
  675. }
  676. }
  677. });
  678. },
  679. getUserVendor(params, callback, fail_callback) {
  680. _mixins.methods.$httpSend({
  681. path: '/im/vendor/getUserVendor',
  682. data: params,
  683. success(ret) {
  684. if (callback) {
  685. callback(ret);
  686. }
  687. },
  688. fail_callback(res) {
  689. if (fail_callback) {
  690. fail_callback(res)
  691. }
  692. }
  693. });
  694. },
  695. getVendorInfo(params, callback, fail_callback) {
  696. _mixins.methods.$httpSend({
  697. path: '/im/vendor/getVendor',
  698. data: params,
  699. success(ret) {
  700. console.log("dasdsada")
  701. if (callback) {
  702. callback(ret);
  703. }
  704. },
  705. fail_callback(res) {
  706. console.log("dasdsada")
  707. if (fail_callback) {
  708. fail_callback(res)
  709. }
  710. }
  711. });
  712. },
  713. getSysConfig(params, callback, fail_callback) {
  714. _mixins.methods.$httpSend({
  715. path: '/im/App/config',
  716. data: params,
  717. success(ret) {
  718. if (callback) {
  719. callback(ret);
  720. }
  721. },
  722. fail_callback(res) {
  723. if (fail_callback) {
  724. fail_callback(res)
  725. }
  726. }
  727. });
  728. },
  729. getSms(params, callback, fail_callback) {
  730. _mixins.methods.$httpSend({
  731. path: '/im/App/getSms',
  732. data: params,
  733. success(ret) {
  734. console.log(ret)
  735. if (callback) {
  736. callback(ret);
  737. }
  738. },
  739. fail_callback(res) {
  740. if (fail_callback) {
  741. fail_callback(res)
  742. }
  743. }
  744. });
  745. },
  746. vendorLogin(params, callback, fail_callback) {
  747. _mixins.methods.$httpSend({
  748. path: '/im/in/vendorLogin',
  749. data: params,
  750. success(ret) {
  751. console.log(ret)
  752. if (callback) {
  753. callback(ret);
  754. }
  755. },
  756. fail_callback(res) {
  757. if (fail_callback) {
  758. fail_callback(res)
  759. }
  760. }
  761. });
  762. },
  763. getRobotList(params, callback, fail_callback) {
  764. _mixins.methods.$httpSend({
  765. path: '/im/vendor/getRobotList',
  766. data: params,
  767. success(ret) {
  768. console.log(ret)
  769. if (callback) {
  770. callback(ret);
  771. }
  772. },
  773. fail_callback(res) {
  774. if (fail_callback) {
  775. fail_callback(res)
  776. }
  777. }
  778. });
  779. },
  780. addRobot(params, callback, fail_callback) {
  781. _mixins.methods.$httpSend({
  782. path: '/im/vendor/addRobot',
  783. data: params,
  784. success(ret) {
  785. console.log(ret)
  786. if (callback) {
  787. callback(ret);
  788. }
  789. },
  790. fail_callback(res) {
  791. if (fail_callback) {
  792. fail_callback(res)
  793. }
  794. }
  795. });
  796. },
  797. tuiQun(params, callback, fail_callback) {
  798. _mixins.methods.$httpSend({
  799. path: '/im/vendor/robotTuiQun',
  800. data: params,
  801. success(ret) {
  802. console.log(ret)
  803. if (callback) {
  804. callback(ret);
  805. }
  806. },
  807. fail_callback(res) {
  808. if (fail_callback) {
  809. fail_callback(res)
  810. }
  811. }
  812. });
  813. },
  814. autoBigRed(params, callback, fail_callback) {
  815. _mixins.methods.$httpSend({
  816. path: '/im/vendor/robotAutoHongbao',
  817. data: params,
  818. success(ret) {
  819. console.log(ret)
  820. if (callback) {
  821. callback(ret);
  822. }
  823. },
  824. fail_callback(res) {
  825. if (fail_callback) {
  826. fail_callback(res)
  827. }
  828. }
  829. });
  830. },
  831. updateUserTradePassword(params, callback, fail_callback) {
  832. _mixins.methods.$httpSend({
  833. path: '/im/vendor/updateUserTradePassword',
  834. data: params,
  835. success(ret) {
  836. console.log(ret)
  837. if (callback) {
  838. callback(ret);
  839. }
  840. },
  841. fail_callback(res) {
  842. if (fail_callback) {
  843. fail_callback(res)
  844. }
  845. }
  846. });
  847. },
  848. checkSmsCode(params, callback, fail_callback) {
  849. _mixins.methods.$httpSend({
  850. path: '/im/app/checkSmsCode',
  851. data: params,
  852. success(ret) {
  853. console.log(ret)
  854. if (callback) {
  855. callback(ret);
  856. }
  857. },
  858. fail_callback(res) {
  859. if (fail_callback) {
  860. fail_callback(res)
  861. }
  862. }
  863. });
  864. },
  865. saveGroupNickName(params, callback, fail_callback) {
  866. _mixins.methods.$httpSend({
  867. path: '/im/vendor/saveGroupNickName',
  868. data: params,
  869. success(ret) {
  870. console.log(ret)
  871. if (callback) {
  872. callback(ret);
  873. }
  874. },
  875. fail_callback(res) {
  876. if (fail_callback) {
  877. fail_callback(res)
  878. }
  879. }
  880. });
  881. },
  882. //群成员列表
  883. getMemberList(params, callback, fail_callback) {
  884. _mixins.methods.$httpSend({
  885. path: '/im/vendor/getMemberList',
  886. data: params,
  887. success(ret) {
  888. console.log(ret)
  889. if (callback) {
  890. callback(ret);
  891. }
  892. },
  893. fail_callback(res) {
  894. if (fail_callback) {
  895. fail_callback(res)
  896. }
  897. }
  898. });
  899. },
  900. groupAdd(params, callback, fail_callback) {
  901. _mixins.methods.$httpSend({
  902. path: '/im/message/addChat',
  903. data: params,
  904. success(ret) {
  905. if (callback) {
  906. callback(ret);
  907. }
  908. },
  909. fail_callback(res) {
  910. if (fail_callback) {
  911. fail_callback(res)
  912. }
  913. }
  914. });
  915. },
  916. getInviteName(params, callback, fail_callback) {
  917. _mixins.methods.$httpSend({
  918. path: '/im/vendor/getInviteName',
  919. data: params,
  920. success(ret) {
  921. if (callback) {
  922. callback(ret);
  923. }
  924. },
  925. fail_callback(res) {
  926. if (fail_callback) {
  927. fail_callback(res)
  928. }
  929. }
  930. });
  931. },
  932. zhendong(params, callback, fail_callback) {
  933. _mixins.methods.$httpSend({
  934. path: '/im/vendor/zhendong',
  935. data: params,
  936. success(ret) {
  937. if (callback) {
  938. callback(ret);
  939. }
  940. },
  941. fail_callback(res) {
  942. if (fail_callback) {
  943. fail_callback(res)
  944. }
  945. }
  946. });
  947. },
  948. getGroupDetail(params, callback, fail_callback) {
  949. _mixins.methods.$httpSend({
  950. path: '/im/vendor/getGroupDetail',
  951. data: params,
  952. success(ret) {
  953. if (callback) {
  954. callback(ret);
  955. }
  956. },
  957. fail_callback(res) {
  958. if (fail_callback) {
  959. fail_callback(res)
  960. }
  961. }
  962. });
  963. },
  964. copyNewQun(params, callback, fail_callback) {
  965. _mixins.methods.$httpSend({
  966. path: '/im/vendor/copyNewQun',
  967. data: params,
  968. success(ret) {
  969. if (callback) {
  970. callback(ret);
  971. }
  972. },
  973. fail_callback(res) {
  974. if (fail_callback) {
  975. fail_callback(res)
  976. }
  977. }
  978. });
  979. },
  980. getExpireBigRed(params, callback, fail_callback) {
  981. _mixins.methods.$httpSend({
  982. path: '/im/vendor/getExpireBigRed',
  983. data: params,
  984. success(ret) {
  985. if (callback) {
  986. callback(ret);
  987. }
  988. },
  989. fail_callback(res) {
  990. if (fail_callback) {
  991. fail_callback(res)
  992. }
  993. }
  994. });
  995. },
  996. sendChuoYiChuoMsg(params, callback, fail_callback) {
  997. _mixins.methods.$httpSend({
  998. path: '/im/vendor/sendChuoYiChuoMsg',
  999. data: params,
  1000. success(ret) {
  1001. if (callback) {
  1002. callback(ret);
  1003. }
  1004. },
  1005. fail_callback(res) {
  1006. if (fail_callback) {
  1007. fail_callback(res)
  1008. }
  1009. }
  1010. });
  1011. },
  1012. getCapitalList(params, callback, fail_callback) {
  1013. _mixins.methods.$httpSend({
  1014. path: '/im/vendor/getUserCapitalList',
  1015. data: params,
  1016. success(ret) {
  1017. if (callback) {
  1018. callback(ret);
  1019. }
  1020. },
  1021. fail_callback(res) {
  1022. if (fail_callback) {
  1023. fail_callback(res)
  1024. }
  1025. }
  1026. });
  1027. },
  1028. getArticleList(params, callback, fail_callback) {
  1029. _mixins.methods.$httpSend({
  1030. path: '/im/vendor/getArticleList',
  1031. data: params,
  1032. success(ret) {
  1033. if (callback) {
  1034. callback(ret);
  1035. }
  1036. },
  1037. fail_callback(res) {
  1038. if (fail_callback) {
  1039. fail_callback(res)
  1040. }
  1041. }
  1042. });
  1043. },
  1044. getArticleDetail(params, callback, fail_callback) {
  1045. _mixins.methods.$httpSend({
  1046. path: '/im/vendor/getArticleDetail',
  1047. data: params,
  1048. success(ret) {
  1049. if (callback) {
  1050. callback(ret);
  1051. }
  1052. },
  1053. fail_callback(res) {
  1054. if (fail_callback) {
  1055. fail_callback(res)
  1056. }
  1057. }
  1058. });
  1059. },
  1060. getUserStore(params, callback, fail_callback) {
  1061. _mixins.methods.$httpSend({
  1062. path: '/im/vendor/getUserStore',
  1063. data: params,
  1064. success(ret) {
  1065. if (callback) {
  1066. callback(ret);
  1067. }
  1068. },
  1069. fail_callback(res) {
  1070. if (fail_callback) {
  1071. fail_callback(res)
  1072. }
  1073. }
  1074. });
  1075. },
  1076. getStoreStatics(params, callback, fail_callback) {
  1077. _mixins.methods.$httpSend({
  1078. path: '/im/vendor/getStoreStatics',
  1079. data: params,
  1080. success(ret) {
  1081. if (callback) {
  1082. callback(ret);
  1083. }
  1084. },
  1085. fail_callback(res) {
  1086. if (fail_callback) {
  1087. fail_callback(res)
  1088. }
  1089. }
  1090. });
  1091. },
  1092. deleteStore(params, callback, fail_callback) {
  1093. _mixins.methods.$httpSend({
  1094. path: '/im/vendor/deleteStore',
  1095. data: params,
  1096. success(ret) {
  1097. if (callback) {
  1098. callback(ret);
  1099. }
  1100. },
  1101. fail_callback(res) {
  1102. if (fail_callback) {
  1103. fail_callback(res)
  1104. }
  1105. }
  1106. });
  1107. },
  1108. getMemberPhotos(params, callback, fail_callback) {
  1109. _mixins.methods.$httpSend({
  1110. path: '/im/vendor/getMemberPhotos',
  1111. data: params,
  1112. success(ret) {
  1113. if (callback) {
  1114. callback(ret);
  1115. }
  1116. },
  1117. fail_callback(res) {
  1118. if (fail_callback) {
  1119. fail_callback(res)
  1120. }
  1121. }
  1122. });
  1123. },
  1124. transMsg(params, callback, fail_callback) {
  1125. _mixins.methods.$httpSend({
  1126. path: '/im/vendor/transMsg',
  1127. data: params,
  1128. success(ret) {
  1129. if (callback) {
  1130. callback(ret);
  1131. }
  1132. },
  1133. fail_callback(res) {
  1134. if (fail_callback) {
  1135. fail_callback(res)
  1136. }
  1137. }
  1138. });
  1139. },
  1140. joinVoiceRoom(params, callback, fail_callback) {
  1141. _mixins.methods.$httpSend({
  1142. path: '/im/vendor/joinVoiceRoom',
  1143. data: params,
  1144. success(ret) {
  1145. if (callback) {
  1146. callback(ret);
  1147. }
  1148. },
  1149. fail_callback(res) {
  1150. if (fail_callback) {
  1151. fail_callback(res)
  1152. }
  1153. }
  1154. });
  1155. },
  1156. setVoiceRoomMsg(params, callback, fail_callback) {
  1157. _mixins.methods.$httpSend({
  1158. path: '/im/vendor/setVoiceRoomMsg',
  1159. data: params,
  1160. success(ret) {
  1161. if (callback) {
  1162. callback(ret);
  1163. }
  1164. },
  1165. fail_callback(res) {
  1166. if (fail_callback) {
  1167. fail_callback(res)
  1168. }
  1169. }
  1170. });
  1171. },
  1172. memberjoinVoiceRoom(params, callback, fail_callback) {
  1173. _mixins.methods.$httpSend({
  1174. path: '/im/vendor/memberjoinVoiceRoom',
  1175. data: params,
  1176. success(ret) {
  1177. if (callback) {
  1178. callback(ret);
  1179. }
  1180. },
  1181. fail_callback(res) {
  1182. if (fail_callback) {
  1183. fail_callback(res)
  1184. }
  1185. }
  1186. });
  1187. },
  1188. checkVoiceRoomState(params, callback, fail_callback) {
  1189. _mixins.methods.$httpSend({
  1190. path: '/im/vendor/checkVoiceRoomState',
  1191. data: params,
  1192. success(ret) {
  1193. if (callback) {
  1194. callback(ret);
  1195. }
  1196. },
  1197. fail_callback(res) {
  1198. if (fail_callback) {
  1199. fail_callback(res)
  1200. }
  1201. }
  1202. });
  1203. },
  1204. xiaoHui(params, callback, fail_callback) {
  1205. _mixins.methods.$httpSend({
  1206. path: '/im/group/xiaoHuiMessage',
  1207. data: params,
  1208. success(ret) {
  1209. if (callback) {
  1210. callback(ret);
  1211. }
  1212. },
  1213. fail_callback(res) {
  1214. if (fail_callback) {
  1215. fail_callback(res)
  1216. }
  1217. }
  1218. });
  1219. }
  1220. }