summaryrefslogtreecommitdiff
path: root/www
diff options
context:
space:
mode:
Diffstat (limited to 'www')
-rw-r--r--www/js/WizardCtrl.js16
-rw-r--r--www/templates/wizard.html2
2 files changed, 14 insertions, 4 deletions
diff --git a/www/js/WizardCtrl.js b/www/js/WizardCtrl.js
index 537a6839..8f481d2d 100644
--- a/www/js/WizardCtrl.js
+++ b/www/js/WizardCtrl.js
@@ -153,10 +153,20 @@ angular.module('zmApp.controllers').controller('zmApp.WizardCtrl', ['$scope', '$
{
NVRDataModel.log("Success: on " + urls[0] + t);
//$ionicLoading.hide();
- return urls[0];
+ d.resolve(urls[0]);
+ return d.promise;
+ //return urls[0];
}, function(err)
{
- NVRDataModel.log("zmWizard:Failed on " + urls[0] + t + " with error " + JSON.stringify(err));
+ NVRDataModel.log("zmWizard:Failed on " + urls[0] + t + " with error " + JSON.stringify(err) );
+ // this is actually a success - I might get empty status
+ // or something
+ if (err.status < 300)
+ {
+ NVRDataModel.log ("I am taking this as a cgi-bin success - "+urls[0]);
+ d.resolve(urls[0]);
+ return d.promise;
+ }
return findFirstReachableUrl(urls.slice(1), tail);
});
}
@@ -302,7 +312,7 @@ angular.module('zmApp.controllers').controller('zmApp.WizardCtrl', ['$scope', '$
function(error)
{
$ionicLoading.hide();
- //console.log("No cgi-bin found: " + error);
+ console.log("No cgi-bin found: " + JSON.stringify(error));
$scope.wizard.streamingValidText = $translate.instant('kPortalCgiBinFailed');
$scope.wizard.streamingColor = "#e74c3c";
d.reject(false);
diff --git a/www/templates/wizard.html b/www/templates/wizard.html
index 82f01c8b..60d1e1ef 100644
--- a/www/templates/wizard.html
+++ b/www/templates/wizard.html
@@ -11,7 +11,7 @@
<p>{{'kWizConfigPain' | translate}}</p>
<h4>{{'kWizPortalUrl' | translate}}</h4>
<label class="item item-input">
- <input autocorrect="off" autocapitalize="none" autocomplete="off" type="text" placeholder="{{'kPortalUrlExample | translate}}" ng-model="wizard.portalurl">
+ <input autocorrect="off" autocapitalize="none" autocomplete="off" type="text" placeholder="{{'kPortalUrlExample' | translate}}" ng-model="wizard.portalurl">
</label>
<p ng-if="$root.platformOS=='android'" style="font-size:0.8em; color:gray">{{'kDisableSamsung' | translate}}</p>
<a class="button icon-left ion-information-circled button-clear button-dark" ng-click="toggleTip()">{{wizard.tiptext}}</a>