hexiao.js 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177
  1. import request from '@/utils/requestAdmin'
  2. //返送验证码
  3. export function getVerificationCode(tel,userType){
  4. return request({
  5. url: `/miniapp/sendYzm?tel=`+ tel+"&userType="+userType,
  6. method: 'post',
  7. })
  8. }
  9. //登录
  10. export function login(tel,code,userType,jsCode){
  11. return request({
  12. url: `/miniapp/login`,
  13. method: 'post',
  14. params: {
  15. phone:tel,
  16. userType:userType,
  17. code:code,
  18. jsCode
  19. }
  20. })
  21. }
  22. export function getAdminUserInfo(){
  23. return request({
  24. url: `/miniapp/getAdminUserInfo`,
  25. method: 'post',
  26. })
  27. }
  28. export function getQrcodeNum(code){
  29. return request({
  30. url: `/ywy/getQrcodeNum`,
  31. method: 'post',
  32. params: {
  33. qrCode:code
  34. }
  35. })
  36. }
  37. export function active(data){
  38. return request({
  39. url: `/ywy/active`,
  40. method: 'post',
  41. data: data
  42. })
  43. }
  44. export function getRetailDetail(id){
  45. return request({
  46. url: `/store/show`,
  47. method: 'post',
  48. params: {
  49. id:id
  50. }
  51. })
  52. }
  53. export function removeRetail(id){
  54. return request({
  55. url: `/store/delete`,
  56. method: 'post',
  57. params: {
  58. id:id
  59. }
  60. })
  61. }
  62. export function getStoreList(pageIndex,pageSize,storeName){
  63. return request({
  64. url: `/store/queryPage`,
  65. method: 'post',
  66. params: {
  67. pageIndex:pageIndex,
  68. pageSize:pageSize,
  69. storeName:storeName
  70. }
  71. })
  72. }
  73. export function addStore(store_name,contact_name,contact_phone,address){
  74. return request({
  75. url: `/store/save`,
  76. method: 'post',
  77. params: {
  78. store_name:store_name,
  79. contact_name:contact_name,
  80. contact_phone:contact_phone,
  81. address:address
  82. }
  83. })
  84. }
  85. export function updateStore(id,store_name,contact_name,contact_phone,address){
  86. return request({
  87. url: `/store/update`,
  88. method: 'post',
  89. params: {
  90. id:id,
  91. store_name:store_name,
  92. contact_name:contact_name,
  93. contact_phone:contact_phone,
  94. address:address
  95. }
  96. })
  97. }
  98. /**
  99. * 查询上货记录
  100. * @param pageIndex
  101. * @param pageSize
  102. * @returns {*}
  103. */
  104. export function queryActiveRecord(pageIndex,pageSize){
  105. return request({
  106. url: `/ywy/queryActiveRecord`,
  107. method: 'post',
  108. params: {
  109. pageIndex:pageIndex,
  110. pageSize:pageSize
  111. }
  112. })
  113. }
  114. export function ywyList(keyword){
  115. return request({
  116. url: `/jxs/jxsRetailListQuery`,
  117. method: 'post',
  118. params: {
  119. keyword:keyword
  120. }
  121. })
  122. }
  123. export function areaList(keyword){
  124. return request({
  125. url: `/jxs/jxsAreaList`,
  126. method: 'post',
  127. })
  128. }
  129. export function addYwy(data){
  130. return request({
  131. url: `/jxs/jxsSaveRetail`,
  132. method: 'post',
  133. data: data
  134. })
  135. }
  136. export function updateYwy(data){
  137. return request({
  138. url: `/jxs/jxsUpdateYwy`,
  139. method: 'post',
  140. data: data
  141. })
  142. }
  143. export function delYwy(id){
  144. return request({
  145. url: `/jxs/deleteYwy`,
  146. method: 'post',
  147. params: {
  148. ywyId:id
  149. }
  150. })
  151. }