net::ERR_CONNECTION_REFUSED (WEB PAGE NOT AVAILABLE) IONIC V4 APP - sapui5

i am added kapsel plugins to my ionic app.and generated build and installed apk in app.i am getting this error
web page at http://localhost/smp/ui/iab.html could not be loaded because:
net::ERR_CONNECTION_REFUSED
ionic cordova plugin
cordova-plugin-device 2.0.3 "Device"
cordova-plugin-dialogs 2.0.2 "Notification"
cordova-plugin-ionic-keyboard 2.1.3 "cordova-plugin-ionic-keyboard"
cordova-plugin-ionic-webview 4.1.1 "cordova-plugin-ionic-webview"
cordova-plugin-splashscreen 5.0.2 "Splashscreen"
cordova-plugin-statusbar 2.4.2 "StatusBar"
cordova-plugin-whitelist 1.3.3 "Whitelist"
kapsel-plugin-authproxy 4.2.8 "AuthProxy"
kapsel-plugin-corelibs 4.2.8 "CoreLibs"
kapsel-plugin-i18n 4.2.8 "i18n"
kapsel-plugin-inappbrowser 4.2.8 "InAppBrowser"
kapsel-plugin-logon 4.2.8 "Logon"
kapsel-plugin-ui5 4.2.8 "ui5"
Please find attachment
https://odsol-my.sharepoint.com/:i:/g/personal/gsreddy_ondevice_co_uk/EVT4LR3rt55Jk3IyCiLNHO8Bkd8rxYZnFAdzAw2wbcaolA?e=HQgvC8

Normally I would expect to see a port number next to the localhost url like the default 8100:
http://localhost:8100/
Have you hardcoded the wrong url somewhere?

Related

Property 'iOSExternalAccessory' does not exist on type 'CordovaPlugins'

I have created a new Ionic 4 menu template app and then I have installed the following plugin with deps. using the CLI command
ionic cordova add https://github.com/stevef51/cordova-ios-external-accessories
However when I try ionic cordova prepare ios, I am presented the following error.
ERROR in src/app/home/home.page.ts:25:39 - error TS2339: Property 'iOSExternalAccessory' does not exist on type 'CordovaPlugins'.
25 var pluginAPI = cordova.plugins.iOSExternalAccessory;
~~~~~~~~~~~~~~~~~~~~
[ERROR] An error occurred while running subprocess ng.
When I run the command
ionic cordova plugin list, I can see it installed
com.virtualmgr.iOSExternalAccessory 1.0.0 "iOSExternalAccessory"
cordova-plugin-ble-central 1.2.2 "BLE"
cordova-plugin-bluetooth-serial 0.4.7 "Bluetooth Serial"
cordova-plugin-bluetoothle 4.5.5 "Bluetooth LE"
cordova-plugin-compat 1.2.0 "Compat"
cordova-plugin-device 2.0.2 "Device"
cordova-plugin-ionic-keyboard 2.1.3 "cordova-plugin-ionic-keyboard"
cordova-plugin-ionic-webview 4.1.1 "cordova-plugin-ionic-webview"
cordova-plugin-splashscreen 5.0.2 "Splashscreen"
cordova-plugin-statusbar 2.4.2 "StatusBar"
cordova-plugin-whitelist 1.3.3 "Whitelist"
The code is dead simple: a click event, if I take it out the BLE code works just fine, however I am forced to use this plugin as the handheld scanner I am using does not support BLE as it does not show up in the list of accessories when I scan for BLE devices.
scanForDevices(){
var pluginAPI = cordova.plugins.iOSExternalAccessory;
this.ble.scan([], 5).subscribe(device => {
console.log(JSON.stringify(device));
});
}
I have made contact with the developer of the plugin, he has no Ionic experience, unfortunately.
Any and all advice would be appreciated.
I have worked it out.
I was missing the declare let cordova: any; at the top of my file.

Cordova app on iOS 9x not working

I am testing my cordova app via Xcode simulator on multiple phone types running various versions of 9x through 11x. The app installs and works as intended on all devices running 10x and 11x but is not working on devices running 9x (specifically 9.3). On 9x devices, my app splash screen shows up and then the screen goes white.
In Xcode console I get zero errors or warnings - from a console perspective it just looks like a successful install. However, when trying to access Safari -> Develop -> Simulator - the app is not appearing as running so I can't view anything in Safari. I have no idea what to look for or what could be causing this. Any ideas or thoughts as to where/what to look for? This is consistently happening on any simulator device running 9.3 (5s, 6, 6 plus, 6s, 6s plus)
My app is running:
Cordova 4.5.0
Ionic: 1.7.14
cocoapods 1.3.1
And my installed plugins:
cl.rmd.cordova.dialoggps 0.0.2 "DialogGPS"
com.lampa.startapp 0.1.4 "startApp"
com.ludei.webview.plus 2.3.0 "Webview+"
com.peerio.cordova.plugin.carrier 1.0.1 "Carrier"
com.phonegap.plugins.nativesettingsopener 1.0.1 "Native settings"
com.vliesaputra.deviceinformation 1.0.1 "DeviceInformation"
cordova-instagram-plugin 0.5.5 "Instagram"
cordova-plugin-admobpro 2.29.22 "AdMob Plugin Pro"
cordova-plugin-appavailability 0.4.2 "AppAvailability"
cordova-plugin-appinfo 2.1.2 "AppInfo Plugin"
cordova-plugin-apprate 1.3.0 "AppRate"
cordova-plugin-compat 1.2.0 "Compat"
cordova-plugin-console 1.1.0 "Console"
cordova-plugin-device 1.1.4 "Device"
cordova-plugin-device-motion 1.2.5 "Device Motion"
cordova-plugin-device-orientation 1.0.7 "Device Orientation"
cordova-plugin-dialogs 1.3.3 "Notification"
cordova-plugin-email 1.2.6 "EmailComposer"
cordova-plugin-extension 1.5.2 "Cordova Plugin Extension"
cordova-plugin-fastrde-checkgps 1.0.0 "checkGPS"
cordova-plugin-file 4.3.3 "File"
cordova-plugin-firebase 0.1.24 "Google Firebase Plugin"
cordova-plugin-geolocation 1.0.1 "Geolocation"
cordova-plugin-globalization 1.0.7 "Globalization"
cordova-plugin-inappbrowser 1.7.1 "InAppBrowser"
cordova-plugin-network-information 1.3.3 "Network Information"
cordova-plugin-queries-schemes 0.1.1 "App Queries Strings"
cordova-plugin-request-location-accuracy 2.2.2 "Request Location Accuracy"
cordova-plugin-sim 1.3.3 "SIM"
cordova-plugin-splashscreen 4.0.3 "Splashscreen"
cordova-plugin-statusbar 2.2.1 "StatusBar"
cordova-plugin-vibration 2.1.5 "Vibration"
cordova-plugin-whitelist 1.3.1 "Whitelist"
cordova-sms-plugin 0.1.11 "Cordova SMS Plugin"
cordova-universal-clipboard 0.1.0 "Clipboard"
cordova.plugins.diagnostic 3.7.1 "Diagnostic"
ionic-plugin-keyboard 2.2.1 "Keyboard"
On a side note, it would be easy to just ignore 9x and keep my app at 10x/11x, however, nearly 10% of the iOS install base is still running iOS 9x - thats a pretty significant user base to ignore.

Cannot debug ionic app

I have an ionic v1 app.
It uses following plugins:
cordova-plugin-console 1.0.4 "Console"
cordova-plugin-device 1.1.3 "Device"
cordova-plugin-firebase 0.1.19 "Google Firebase Plugin"
cordova-plugin-globalization 1.0.6-dev "Globalization"
cordova-plugin-inappbrowser 1.7.0 "InAppBrowser"
cordova-plugin-splashscreen 4.0.0 "Splashscreen"
cordova-plugin-statusbar 2.2.0 "StatusBar"
cordova-plugin-transport-security 0.1.2 "App Transport Security"
ionic-plugin-keyboard 2.2.1 "Keyboard"
phonegap-facebook-plugin 0.12.0 "Facebook Connect"
When I try to run something like cordova run browser I have following output
Linting www/js/views.js
File www/js/views.js has no errors.
-----------------------------------------
Error: Cannot read property 'variables' of undefined
How can I fix this?

$cordovaLocalNotification - TypeError - cannot read property 'local' of undefined

I am running into an issue while utilizing $cordovaLocalNotification within my ionic app where the below code yields an error message TypeError: Cannot read property 'local' of undefined
try{
if($scope.active.checked){
$cordovaLocalNotification.schedule({
id: 1,
title: 'Notification',
text: 'You are currently publishing your location.'
}).then(function(result){
AlertService.notify('Success', 'Successfully notified customer')
}, function(err){
AlertService.notify('Error', 'Failed to notify customer')
});
} else {
$cordovaLocalNotification.cancel(1);
}
}catch(err){
AlertService.notify('Issue', err)
}
So, after reading a few responses around needing to verify ionicPlatform.ready() and ensuring the plugin is installed properly (and verifying those aren't the issues), I am at a lost. I believe this issue is caused by cordova.plugins.notification not being defined, but I'm not sure why this plugin isn't being loaded properly.
From Ionic, I have the following plugins:
cordova-plugin-app-event 1.2.0 "Application Events"
cordova-plugin-camera 2.3.0 "Camera"
cordova-plugin-compat 1.0.0 "Compat"
cordova-plugin-console 1.0.4 "Console"
cordova-plugin-device 1.1.3 "Device"
cordova-plugin-geolocation 2.4.0 "Geolocation"
cordova-plugin-splashscreen 4.0.0 "Splashscreen"
cordova-plugin-statusbar 2.2.0 "StatusBar"
cordova-plugin-whitelist 1.3.0 "Whitelist"
de.appplant.cordova.plugin.local-notification 0.8.4 "LocalNotification"
ionic-plugin-keyboard 2.2.1 "Keyboard"
So far, for my own sanity, I have:
Installed the plugin manually using cordova plugin add de.appplant.cordova.plugin.local-notification
Removed platform, remove plugins, then execute ionic state restore
Also, a good item to note is I am utilizing ionicView to test. All/any help would be appreciated.
It turns out that mocking this on the emulator or physical device works fine. So it was a good learning experience that not all cordova plugins operate in ionicView

I get a Could not find InAppBrowser plugin in ionic ios app

I have created a simple Ionic app in which I want to integrate Facebook login, however when I try to sign in, I get the message Could not find InAppBrowser plugin.
After searching a bit on the web I found out that it might be because of the plugin name which has changed overtime from cordova-plugin-inappbrowser to org.apache.cordova.inappbrowser.
The suggested solution were to edit the ng-cordova.js file to reference the plugin name I was using, but when I went to edit it, it was already referencing both plugin names inside that function :
isInAppBrowserInstalled: function(cordovaMetadata) {
var inAppBrowserNames = ["cordova-plugin-inappbrowser", "org.apache.cordova.inappbrowser"];
return inAppBrowserNames.some(function(name) {
return cordovaMetadata.hasOwnProperty(name);
});
},
I tried to alert(JSON.stringify(cordovaMetadata)); to see what was going on, but it returned an empty object like {}.
Also, if I do cordova plugin ls, here is what I get:
cordova-plugin-console 1.0.1 "Console"
cordova-plugin-device 1.0.1 "Device"
cordova-plugin-file 3.0.0 "File"
cordova-plugin-inappbrowser 1.0.1 "InAppBrowser"
cordova-plugin-media 1.0.1 "Media"
cordova-plugin-splashscreen 2.1.0 "Splashscreen"
cordova-plugin-statusbar 1.0.1 "StatusBar"
cordova-plugin-whitelist 1.0.0 "Whitelist"
ionic-plugin-keyboard 1.0.7 "Keyboard"
i had the same problem, and instead of using:
"cordova plugin add org.apache.cordova.inappbrowser"
I used:
"cordova plugin add https://git-wip-us.apache.org/repos/asf/cordova-plugin-inappbrowser.git"
And it works, i follow the instructions of this link:
https://github.com/nraboy/ng-cordova-oauth/issues/57
Good luck