소스 검색

提交代码~

release/210823_需求对对碰
王饶冀 3 년 전
부모
커밋
573b9329b4
2개의 변경된 파일12개의 추가작업 그리고 9개의 파일을 삭제
  1. 11
    8
      pages/myModule/components/myRelease/myRelease.js
  2. 1
    1
      utils/request.js

+ 11
- 8
pages/myModule/components/myRelease/myRelease.js 파일 보기

@@ -94,11 +94,9 @@ Page({
that.productReleasePost(item);
}
},
// 上架/下架需求 Fn
productReleasePost(item) {
wx.showLoading({
title: '加载中',
mask:true
})
this.showLoading();
let { businessCommunicationDemandId, state } = item;
$request.post(`/businessCommunicationDemand/outDemand.action`,
{ businessCommunicationDemandId, state }
@@ -141,12 +139,10 @@ Page({
}
})
},
// 删除需求 Fn
productDelPost(item) {
let { businessCommunicationDemandId } = item;
wx.showLoading({
title: '加载中',
mask:true
})
this.showLoading();
$request.post(`/businessCommunicationDemand/deleteDemand.action`,
{ businessCommunicationDemandId }
).then(res => {
@@ -172,6 +168,13 @@ Page({
wx.hideLoading()
})
},
// 数据加载提示
showLoading(title) {
wx.showLoading({
title: title ? title : '加载中',
mask: true
})
},
getListData() {
let { page, size, customerId, keyword, currentTab } = this.data;
$request.get('/businessCommunicationDemand/getDemandByStateAndCustomerId.action',

+ 1
- 1
utils/request.js 파일 보기

@@ -12,7 +12,7 @@ const request = async (url, options, contentType) => {
}
}, 500);
})
!!contentType?contentType:contentType="application/x-www-form-urlencoded'"
!!contentType?contentType:contentType="application/json"
return new Promise( (resolve, reject) => {
wx.request({
url: `${app.mangerUrl}${url}?openId=${openId}`,//获取域名接口地址

Loading…
취소
저장