http.js 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724
  1. import $http from "./request/requestConfig"
  2. import {
  3. BASE_URI
  4. } from "../pages/utils/constant.js";
  5. import qs from 'qs';
  6. const baseUri = '/smartParkH5Server'
  7. const parkActivity = '/wx/meetingAppoint'
  8. export function login(data) {
  9. return $http.post(
  10. '/wx/auth/login_by_app_main?' + qs.stringify(data), {}, {})
  11. }
  12. export function addRectificationManagement(data) {
  13. return $http.post(
  14. '/wx/RectificationController/addRectificationManagement',
  15. data, {}
  16. )
  17. }
  18. export function bindWxOpenId(data) {
  19. return $http.post(
  20. '/wx/frameUser/bindWxOpenId',
  21. data, {}
  22. )
  23. }
  24. export function getMeetingAppointListAppCount(data) {
  25. return $http.post(
  26. '/wx/meetingAppoint/getMeetingAppointListAppCount',
  27. { states: '1,3' }, {}
  28. )
  29. }
  30. export function handleListNum(data) {
  31. return $http.post(
  32. '/wx/workPaneController/handleListNum',
  33. data, {}
  34. )
  35. }
  36. export function getReadSize(data) {
  37. return $http.post(
  38. '/wx/workPaneController/getReadSize',
  39. data, {}
  40. )
  41. }
  42. export function getVenueAppointListAppCount(data) {
  43. return $http.post(
  44. '/wx/WxParkVenueAppointController/getVenueAppointListAppCount',
  45. { states: '1,3' }, {}
  46. )
  47. }
  48. export function editWanderAboutStatus(data) {
  49. return $http.post(
  50. '/wx/repair/editWanderAboutStatus',
  51. data, {}
  52. )
  53. }
  54. export function unbindWxId(data) {
  55. return $http.post(
  56. '/wx/frameUser/unbindWxOpenId',
  57. data, {}
  58. )
  59. }
  60. export function getUserLocalStorageInfo() {
  61. const userInfo = JSON.parse(
  62. uni.getStorageSync("laocui_user_info"));
  63. return userInfo
  64. }
  65. export function uploadPDF() {
  66. uni.showLoading({
  67. title: '加载中',
  68. mask: true
  69. });
  70. return new Promise((resolve, reject) => {
  71. uni.chooseMessageFile({
  72. count: 1, //默认100
  73. type: 'file',
  74. success: (res) => {
  75. uni.uploadFile({
  76. url: BASE_URI + "/wx/fileController/upload",
  77. filePath: res.tempFiles[0].path,
  78. name: "file",
  79. formData: {
  80. user: "test"
  81. },
  82. success(successRes) {
  83. // 上传完成需要更新 fileList
  84. let data = JSON.parse(successRes.data);
  85. uni.showToast({
  86. title: '提交成功',
  87. duration: 500
  88. });
  89. resolve({
  90. url: data.data[0],
  91. name: res.tempFiles[0].name
  92. })
  93. },
  94. fail(res) { },
  95. });
  96. },
  97. fail(e) {
  98. uni.showToast({
  99. title: '提交成功',
  100. duration: 0
  101. });
  102. }
  103. });
  104. })
  105. }
  106. export function getBuildDetails(data) {
  107. return $http.post(
  108. '/wx/MnpBuildingController/getById',
  109. data, {}
  110. )
  111. }
  112. export function addZaiti(data) {
  113. return $http.post(
  114. '/wx/ParkRoomController/add',
  115. data, {}
  116. )
  117. }
  118. export function getPartyBranchList(data) {
  119. return $http.post(
  120. '/wx/partyBranch/getPartyBranchList',
  121. data, {}
  122. )
  123. }
  124. export function selectByCompanyId(data) {
  125. return $http.post(
  126. '/wx/SocialCarrierController/selectByCompanyId',
  127. data, {}
  128. )
  129. }
  130. export function getRoomNameByCompanyId(data) {
  131. return $http.post(
  132. '/wx/ParkContractManageController/getRoomNameByCompanyId', data, {}
  133. )
  134. }
  135. export function getAreaByIds(data) {
  136. return $http.post(
  137. '/wx/ParkRoomController/getAreaByIds',
  138. data, {}
  139. )
  140. }
  141. export function getTreeData2(data) {
  142. return $http.post(
  143. '/wx/ParkInfoController/getTreeData2',
  144. data, {}
  145. )
  146. }
  147. export function getTreeData3(data = {}) {
  148. return $http.post(
  149. '/wx/ParkInfoController/getTreeData3',
  150. data, {}
  151. )
  152. }
  153. export function getTreeData7() {
  154. return $http.post(
  155. '/wx/ParkInfoController/getTreeData7',
  156. null, {}
  157. )
  158. }
  159. export function getTreeData6(data) {
  160. return $http.post(
  161. '/wx/ParkInfoController/getTreeData6',
  162. data, {}
  163. )
  164. }
  165. export function getTreeData4(data) {
  166. return $http.post(
  167. '/wx/ParkInfoController/getTreeData4',
  168. data, {}
  169. )
  170. }
  171. export function getActivationRanking(data) {
  172. return $http.post(
  173. '/wx/partyBranch/getActivationRanking',
  174. data, {}
  175. )
  176. }
  177. export function findRectificationManagementInOutList(data) {
  178. return $http.post(
  179. '/wx/RectificationController/findRectificationManagementInOutList',
  180. data, {}
  181. )
  182. }
  183. export function findRectificationManagementInOutById(e) {
  184. return $http.post(
  185. '/wx/RectificationController/findRectificationManagementInOutById', {
  186. id: e
  187. }, {}
  188. )
  189. }
  190. export function repairList(data) {
  191. return $http.post(
  192. '/wx/repair/serviceList',
  193. data, {}
  194. )
  195. }
  196. export function repairList2(data) {
  197. return $http.post(
  198. '/wx/repair/dispatchList',
  199. data, {}
  200. )
  201. }
  202. export function addSafetySelfCheckingManage(data) {
  203. return $http.post(
  204. '/wx/SafetyController/addSafetySelfCheckingManage',
  205. data, {}
  206. )
  207. }
  208. export function updateSafetySelfCheckingManage(data) {
  209. return $http.post(
  210. '/wx/SafetyController/updateSafetySelfCheckingManage',
  211. data, {}
  212. )
  213. }
  214. export function editRepair(data) {
  215. return $http.post(
  216. '/wx/repair/handleReport',
  217. data, {}
  218. )
  219. }
  220. export function addRepair(data) {
  221. return $http.post(
  222. '/wx/repair/addReport',
  223. data, {}
  224. )
  225. }
  226. export function getRepairDispatchById(id) {
  227. return $http.post(
  228. '/wx/repair/getById', {
  229. id: id
  230. }, {}
  231. )
  232. }
  233. export function getInfoListByRepairId(id) {
  234. return $http.post(
  235. '/wx/repair/getInfoListByRepairId', {
  236. reportRepairId: id
  237. }, {}
  238. )
  239. }
  240. export function getDispatchToPerson(data) {
  241. return $http.post(
  242. '/wx/repair/getDispatchToPerson',
  243. data, {}
  244. )
  245. }
  246. export function getHandleInfoById(data) {
  247. return $http.post(
  248. '/wx/repair/getHandleInfoById',
  249. { id: data }, {}
  250. )
  251. }
  252. export function getCompanyById(data) {
  253. return $http.post(
  254. '/wx/repair/getCompanyById', data, {},
  255. )
  256. }
  257. export function getWxCompanyTags(e) {
  258. return $http.post(
  259. '/wx/MnpTagInfoController/tagInfoList', e, {}
  260. )
  261. }
  262. export function tagsBind(e) {
  263. return $http.post(
  264. '/wx/MnpTagInfoController/bind', e, {}
  265. )
  266. }
  267. export function getDetial(e) {
  268. return $http.post(
  269. '/wx/meetingAppoint/meetingAppointDetail', e, {}
  270. )
  271. }
  272. export function saleControllerGetById(e) {
  273. return $http.post(
  274. '/wx/SaleController/getById', {
  275. id: e
  276. }, {}
  277. )
  278. }
  279. export function getAppUserMain(data) {
  280. return $http.post(
  281. '/wx/company/getById',
  282. data, {}
  283. )
  284. }
  285. export function confirmAudit(data) {
  286. return $http.post(
  287. '/wx/meetingAppoint/confirmAudit',
  288. data, {}
  289. )
  290. }
  291. export function getCompanyTags(e) {
  292. return $http.post(
  293. '/wx/MnpTagInfoController/getCompanyTags', e, {}
  294. )
  295. }
  296. export function getCompanyTagsByQybq(qybq) {
  297. return $http.post(
  298. '/wx/MnpTagInfoController/getCompanyTagsByQybq', {
  299. qybq: qybq
  300. }, {})
  301. }
  302. export function companyECdit(data) {
  303. return $http.post(
  304. '/wx/company/edit', data, {})
  305. }
  306. export function tagInfoList(e) {
  307. return $http.post(
  308. '/wx/MnpTagInfoController/tagInfoList',
  309. e, {})
  310. }
  311. export function findDeptList() {
  312. return $http.post(
  313. '/wx/SaleController/findDeptList', {}, {})
  314. }
  315. export function tagCategoryList() {
  316. return $http.post(
  317. '/wx/MnpTagController/tagCategoryList', {}, {}
  318. )
  319. }
  320. export function interviewEscalationListAll(id) {
  321. return $http.post('/wx/interviewEscalation/listAll', {
  322. companyId: id
  323. }, {})
  324. }
  325. export function getUserInfo(data) {
  326. let laocui_user_info = JSON.parse(uni.getStorageSync('laocui_user_info'))
  327. return $http.post(
  328. '/wx/frameUser/getMyInfo?userId=' + laocui_user_info.user.id, {}, {})
  329. }
  330. export function getWxUserById(userId) {
  331. return $http.get('/wx/frameUser/getWxUserById?userId=' + userId, {})
  332. }
  333. export function getRoomInfo(e) {
  334. return $http.post(
  335. '/wx/ParkRoomController/getById', {
  336. id: e
  337. }, {})
  338. }
  339. export function getCompanyHouseDetails(e) {
  340. return $http.post(
  341. '/wx/company/getById', {
  342. id: e
  343. }, {})
  344. }
  345. export function handleList(e) {
  346. return $http.post(
  347. '/wx/workPaneController/handleList',
  348. e, {})
  349. }
  350. export function readList(e) {
  351. return $http.post(
  352. '/wx/workPaneController/readList',
  353. e, {})
  354. }
  355. // handleList?
  356. export function findCompanyTags(e) {
  357. return $http.post(
  358. '/wx/MnpTagInfoController/getCompanyTags/' + e, {}, {})
  359. }
  360. export function removeTagsBind(e) {
  361. return $http.post(
  362. '/wx/MnpTagInfoController/removeBind', e, {}
  363. )
  364. }
  365. export function addInterview(e) {
  366. return $http.post(
  367. "/wx/interviewEscalation/add", e, {})
  368. }
  369. export function editInterview(e) {
  370. return $http.post(
  371. "/wx/interviewEscalation/edit", e, {})
  372. }
  373. export function getInterviewList(e) {
  374. return $http.post(
  375. "/wx/interviewEscalation/list", e, {})
  376. }
  377. export function getInterviewDetails(e) {
  378. return $http.post(
  379. "/wx/interviewEscalation/getById", {
  380. id: e
  381. }, {})
  382. }
  383. export function findSafetySelfCheckingPlanById(e) {
  384. return $http.post(
  385. "/wx/SafetyController/findSafetySelfCheckingPlanById", {
  386. id: e
  387. }, {})
  388. }
  389. //
  390. export function findSafetySelfCheckingPlanList(e) {
  391. return $http.post(
  392. "/wx/SafetyController/findSafetySelfCheckingPlanList",
  393. e, {})
  394. }
  395. export function getBySaveStatus(e) {
  396. return $http.post(
  397. "/wx/interviewEscalation/getBySaveStatus", {
  398. createdBy: e
  399. }, {})
  400. }
  401. export function companyExamineAdd(e) {
  402. return $http.post(
  403. "/wx/company/add", e, {})
  404. }
  405. export function listByModel(e) {
  406. return $http.post(
  407. '/wx/SaleController/findSaleManagementListByRoomId',
  408. e, {})
  409. }
  410. export function listVo(e) {
  411. // 查询园区列表,不需要参数
  412. return $http.post(
  413. '/wx/company/listVo', e, {})
  414. }
  415. // /wx/SafetyController/addSafetySelfCheckingPlan
  416. export function addSafetySelfCheckingPlan(e) {
  417. // 查询园区列表,不需要参数
  418. return $http.post(
  419. '/wx/SafetyController/addSafetySelfCheckingPlan', {
  420. ...e
  421. }, {})
  422. }
  423. export function findSafetySelfCheckingManagetById(e) {
  424. // 查询园区列表,不需要参数
  425. return $http.post(
  426. '/wx/SafetyController/findSafetySelfCheckingManagetById', {
  427. id: e
  428. }, {})
  429. }
  430. export function findSafetySelfCheckingManageList(e) {
  431. // 查询园区列表,不需要参数
  432. return $http.post(
  433. '/wx/SafetyController/findSafetySelfCheckingManageList', e, {})
  434. }
  435. export function findYuanQuList() {
  436. // 查询园区列表,不需要参数
  437. return $http.post(
  438. '/wx/SaleController/findYuanQuList', {}, {})
  439. }
  440. export function findLongPanList(id) {
  441. // 用园区ID查询楼盘列表
  442. return $http.post(
  443. '/wx/SaleController/findLouPanList', {
  444. id: id
  445. }, {})
  446. }
  447. export function findLouDongList(id) {
  448. // 用园区ID查询楼盘列表
  449. return $http.post(
  450. '/wx/SaleController/findLouDongList', {
  451. id: id
  452. }, {})
  453. }
  454. export function clickCollect(e) {
  455. return $http.post(
  456. '/wx/parkActivity/clickCollect',
  457. e, {})
  458. }
  459. export function insertRegisSignInfo(e) {
  460. return $http.post(
  461. '/wx/parkActivity/insertRegisSignInfo',
  462. e, {})
  463. }
  464. export function richScan(e) {
  465. return $http.post(
  466. '/wx/parkActivity/richScan',
  467. e, {})
  468. }
  469. export function getActivityById(id, signInCode, userId) {
  470. return $http.get(
  471. '/wx/parkActivity/getBySignInCode?id=' + id + '&userId=' + userId + "&signInCode=" + signInCode, {}, {})
  472. }
  473. export function getActivityById1(id, signInCode, userId) {
  474. // /wx/parkActivity/getActivityById?id=1183797041860444160&userId=SCNjNSP7LJ9aarv1cNw
  475. return $http.get(
  476. '/wx/parkActivity/getActivityById?id=' + id + '&userId=' + userId, {}, {})
  477. }
  478. // /wx/userPower/getUserPower?userId=1088765543780974592
  479. export function getUserPower(e) {
  480. return $http.post(
  481. '/wx/userPower/getUserPower', {
  482. userId: e
  483. }, {})
  484. }
  485. export function editPassword(e) {
  486. return $http.post(
  487. '/wx/frameUser/editPassword', e, {})
  488. }
  489. export function updateListRectificationManagement(e) {
  490. return $http.post(
  491. '/wx/RectificationController/updateListRectificationManagement', e, {})
  492. }
  493. export function findListBySaleManagementId(e) {
  494. return $http.post(
  495. '/wx/SaleController/findListBySaleManagementId', e, {})
  496. }
  497. export function findSuccessListBySaleManagementId(e) {
  498. return $http.post(
  499. '/wx/SaleController/findSuccessListBySaleManagementId', e, {})
  500. }
  501. // /wx/RectificationController/findUserListByRoleWuye
  502. export function findUserListByRoleWuye() {
  503. // 用园区ID查询楼盘列表
  504. return $http.post(
  505. '/wx/RectificationController/findUserListByRoleWuye',
  506. {}, {})
  507. }
  508. export function listAllUserMain() {
  509. // 用园区ID查询楼盘列表
  510. return $http.post(
  511. '/wx/UserMainExpandController/listAllUserMain',
  512. {}, {})
  513. }
  514. export function userList(e) {
  515. // http://192.168.2.112:9011/wx/frameUser/userList
  516. return $http.post(
  517. '/wx/frameUser/userList',
  518. e
  519. , {})
  520. }
  521. export function findAllSimpleCompanies(e) {
  522. // http://192.168.2.112:9011/wx/frameUser/userList
  523. return $http.post(
  524. '/wx/company/findAllSimpleCompanies', { searchInfo: e.qymc, pageNum: 1, pageSize: 10000 }, {})
  525. }
  526. export function findTrackUserList() {
  527. // http://192.168.2.112:9011/wx/frameUser/userList
  528. return $http.post(
  529. '/wx/SaleController/findTrackUserList', {}, {})
  530. }
  531. export function getSelectUserTwo(e) {
  532. // 用园区ID查询楼盘列表
  533. return $http.post(
  534. '/wx/frameUser/getSelectUserTwo', {
  535. searchName: e
  536. }, {})
  537. }
  538. export function getSelectDeptTwo(e) {
  539. // 用园区ID查询楼盘列表
  540. return $http.post(
  541. '/wx/frameUser/getSelectDeptTwo',
  542. {
  543. searchName: e
  544. }, {})
  545. }
  546. export function findRoomInfoListByIds(e) {
  547. // 用园区ID查询楼盘列表
  548. return $http.post(
  549. '/wx/SaleController/findRoomInfoListByIds',
  550. {
  551. ids: e
  552. }, {})
  553. }
  554. export function findCompanyList() {
  555. // 用园区ID查询楼盘列表
  556. return $http.post(
  557. '/wx/SaleController/findCompanyList', {}, {})
  558. }
  559. export function addyixiang(e) {
  560. return $http.post(
  561. '/wx/SaleController/add',
  562. e, {})
  563. }
  564. export function editSave(e) {
  565. return $http.post(
  566. '/wx/SaleController/editSave',
  567. e, {})
  568. }
  569. export function findCompanyInfoList(data) {
  570. return $http.post(
  571. "/wx/SaleController/findCompanyInfoList",
  572. data, {}
  573. )
  574. }
  575. export function findRoomByCondition(params) {
  576. // 用园区ID查询楼盘列表
  577. return $http.post(
  578. '/wx/SaleController/findRoomByCondition', params, {})
  579. }
  580. export function getCompanyAll(qymc) {
  581. return $http.post(
  582. '/wx/company/listAll', {
  583. qymc: qymc ? qymc : ""
  584. }, {})
  585. }
  586. export function getByCodes(params) {
  587. // 用园区ID查询楼盘列表
  588. return $http.post(
  589. '/wx/sysDict/getByCodes',
  590. {
  591. codes: params
  592. }, {})
  593. }
  594. export function list(data) {
  595. return $http.post(
  596. parkActivity + '/getMeetingAppointList',
  597. data, {}
  598. )
  599. }
  600. export function listApp(data) {
  601. return $http.post(
  602. parkActivity + '/getMeetingAppointListApp',
  603. data, {}
  604. )
  605. }
  606. export function cancelAppoint(data) {
  607. return $http.post(
  608. parkActivity + '/cancelAppoint',
  609. data, {}
  610. )
  611. }
  612. // /wx/SaleController/
  613. export function getRepairList(data) {
  614. return $http.post(
  615. '/wx/repair/handleList',
  616. data, {}
  617. )
  618. }
  619. export function confirmList(data) {
  620. return $http.post(
  621. '/wx/repair/confirmList',
  622. data, {}
  623. )
  624. }
  625. export function confirmReport(data) {
  626. return $http.post(
  627. '/wx/repair/confirmReport',
  628. data, {}
  629. )
  630. }
  631. export function handleReportBack(data) {
  632. return $http.post(
  633. '/wx/repair/handleReportBack',
  634. data, {}
  635. )
  636. }
  637. export function dispatchType(data) {
  638. return $http.post(
  639. '/wx/repair/dispatch',
  640. data, {}
  641. )
  642. }
  643. export function dispatchCancel(data) {
  644. return $http.post(
  645. '/wx/repair/dispatchCancel',
  646. data, {}
  647. )
  648. }
  649. export function editReportInfo(data) {
  650. return $http.post(
  651. '/wx/repair/editReportInfo',
  652. data, {}
  653. )
  654. }