http.js 15 KB

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