Commit 831c8ac8 by 朱建香

1201

parent 6ccb82b6
...@@ -27,6 +27,8 @@ function init() { ...@@ -27,6 +27,8 @@ function init() {
}, function (err) { }, function (err) {
console.log('error', err); console.log('error', err);
}); });
}else{
openScanCode(self);
} }
}, },
methods:{ methods:{
......
...@@ -419,6 +419,7 @@ function getDevices(self){ ...@@ -419,6 +419,7 @@ function getDevices(self){
iot.business.sds.getDevicesByUser({ iot.business.sds.getDevicesByUser({
success: (response) => { success: (response) => {
console.log(response); console.log(response);
// alert(JSON.stringify(response));
let data = uPublic.checkResponseData(response.data); let data = uPublic.checkResponseData(response.data);
if(response.data == 'success'){ if(response.data == 'success'){
setValueOfSwitch(self, true); setValueOfSwitch(self, true);
......
...@@ -47,6 +47,7 @@ function init() { ...@@ -47,6 +47,7 @@ function init() {
this.showLoginButtonFlag = flag; this.showLoginButtonFlag = flag;
}, },
onLoginButtonTap(){ onLoginButtonTap(){
uComponents.showLoading(this);
loginButtonTap(this); loginButtonTap(this);
}, },
getClientId(){ getClientId(){
...@@ -83,7 +84,7 @@ function initComponentsConfig() { ...@@ -83,7 +84,7 @@ function initComponentsConfig() {
} }
function loginButtonTap(self){ function loginButtonTap(self){
uComponents.showLoading(self);
// if(window.iotDebug){ // if(window.iotDebug){
// iotDebug.push('start: initSDSLogin'); // iotDebug.push('start: initSDSLogin');
// } // }
......
...@@ -34,6 +34,8 @@ function init() { ...@@ -34,6 +34,8 @@ function init() {
}, function (err) { }, function (err) {
console.log('error', err); console.log('error', err);
}); });
} else {
openScanCode(self);
} }
}, },
......
...@@ -24271,6 +24271,7 @@ function getDevices(self) { ...@@ -24271,6 +24271,7 @@ function getDevices(self) {
_public.iot.business.sds.getDevicesByUser({ _public.iot.business.sds.getDevicesByUser({
success: function success(response) { success: function success(response) {
console.log(response); console.log(response);
// alert(JSON.stringify(response));
var data = _public.uPublic.checkResponseData(response.data); var data = _public.uPublic.checkResponseData(response.data);
if (response.data == 'success') { if (response.data == 'success') {
setValueOfSwitch(self, true); setValueOfSwitch(self, true);
......
...@@ -55,6 +55,7 @@ function init() { ...@@ -55,6 +55,7 @@ function init() {
this.showLoginButtonFlag = flag; this.showLoginButtonFlag = flag;
}, },
onLoginButtonTap: function onLoginButtonTap() { onLoginButtonTap: function onLoginButtonTap() {
_public.uComponents.showLoading(this);
loginButtonTap(this); loginButtonTap(this);
}, },
getClientId: function getClientId() { getClientId: function getClientId() {
...@@ -91,7 +92,7 @@ function initComponentsConfig() { ...@@ -91,7 +92,7 @@ function initComponentsConfig() {
} }
function loginButtonTap(self) { function loginButtonTap(self) {
_public.uComponents.showLoading(self);
// if(window.iotDebug){ // if(window.iotDebug){
// iotDebug.push('start: initSDSLogin'); // iotDebug.push('start: initSDSLogin');
// } // }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment