http.js 14 KB

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