临时保存

master
blak-kong 2 years ago
parent a4f5c3be86
commit 217d7255fa

@ -345,7 +345,6 @@ export default class Instrument extends Component<any, any> {
serial: channelInfo.serial,
instrumentId: channelInfo.id,
});
console.log("bindingInstrument", res);
Taro.hideLoading();
if (res.data.code === 200) {
// this.setState({ isVisibleBinding: false });
@ -402,7 +401,7 @@ export default class Instrument extends Component<any, any> {
} = this.state;
return (
<Block>
{/* <PopupAlert
<PopupAlert
isShow={true}
isClose={true}
title="提示"
@ -411,7 +410,7 @@ export default class Instrument extends Component<any, any> {
textAlgin="center"
close={this.closeDev}
confirm={this.closeDev}
/> */}
/>
<Navbar titleSlot="仪器绑定" isBack={true} />
<PopupAlert
isShow={isBindingError}

@ -143,6 +143,10 @@ class IntegralList extends Component<any, any> {
// 用户是否已关闭提醒
GetOfficialAccount = async () => {
Taro.showLoading({
title: "请求中...",
mask: true,
});
let res = await GetOfficialAccount();
if (res.data.code === 200) {
if (!res.data.data) {
@ -153,8 +157,11 @@ class IntegralList extends Component<any, any> {
};
// 用户是否关注公众号
GetIsAttentionOfficialAccount = async () => {
Taro.showLoading({
title: "请求中...",
mask: true,
});
let res = await GetIsAttentionOfficialAccount();
console.log("GetIsAttentionOfficialAccount", res);
if (res.data.code === 200) {
if (!res.data.data) {
// 如果false则是没关注
@ -174,6 +181,10 @@ class IntegralList extends Component<any, any> {
};
GetObtainUserIntegral = async () => {
Taro.showLoading({
title: "请求中...",
mask: true,
});
let { list, pageNum, pageSize } = this.state;
let res = await GetObtainUserIntegral({
pageNum,
@ -195,6 +206,10 @@ class IntegralList extends Component<any, any> {
};
GetIntegralRule = async () => {
Taro.showLoading({
title: "请求中...",
mask: true,
});
let res = await GetIntegralRule();
console.log("GetIntegralRule", res);
if (res.data.code === 200) {

@ -116,6 +116,11 @@ class User extends Component<any, any> {
});
};
// 开发中弹窗
devOpen = (e) => {
this.setState({ isDev: true });
};
// 不检查登录跳转
goUrlNoRegister = (e) => {
let url = e.currentTarget.dataset.url;
@ -265,7 +270,8 @@ class User extends Component<any, any> {
<View
className="block"
data-url="/pages/instrument_manage/index?isback=1"
onClick={this.goUrlNoRegister}
// onClick={this.goUrlNoRegister}
onClick={this.devOpen}
>
<Image
className="bg_img"

@ -1,4 +1,11 @@
import { go, back, showModal, setStorageSync, getStorageSync } from "./traoAPI";
import {
go,
back,
showModal,
setStorageSync,
getStorageSync,
loading,
} from "./traoAPI";
import { WCUserLogin } from "./Interface";
import Taro from "@tarojs/taro";
import formdata from "./wxFormdata/formData";
@ -20,6 +27,8 @@ export const Ajax = (params) => {
// mask: true,
// });
const whiteListLoading = [""]; // loading
// 防止多次点击
const requestUrlList = global_requestUrlList;
const whiteList = []; // 白名单:不自动重新请求
@ -88,7 +97,10 @@ export const Ajax = (params) => {
// });
},
complete() {
Taro.hideLoading();
if (requestUrlList.length === 0) {
Taro.hideLoading();
}
// const requestUrlList = global_requestUrlList;
// const newRequestUrlList = requestUrlList.splice(
// requestUrlList.indexOf(params.url),

Loading…
Cancel
Save