Comments (8)
@dpa99c - Something def broke. I have two apps. App-1 is still using LaunchReview @3.1.1 and the external App Store window launches just find. In the newer app, App-2, I am using LaunchReview @4.0.0, but it has the same/identical functions as App-1. But on the newer App-2, but its not prompt the dialog box and the external launch is not opening. I am getting same behavior on two different Android devices running, Android 7 and Android 10. I haven't tested on iOS yet.
Specifically, I am seeing:
$scope.rateApp = function() {
if (LaunchReview.isRatingSupported()) {
console.log("Supported: true") ;
$scope.rateAppReview() ;
} else {
console.log("Supported: false") ;
$scope.rateAppLuanch() ;
}
}
$scope.rateAppReview = function() {
var MAX_DIALOG_WAIT_TIME = 5000; //max time to wait for rating dialog to display
var ratingTimerId;
LaunchReview.rating(function(result) {
console.log("Rating: "+result) ; // outputs: "Rating: 0"
if (result === "requested") {
ratingTimerId = setTimeout(function() {
$scope.rateAppStore() ;
}, MAX_DIALOG_WAIT_TIME);
} else if (result === "shown") {
clearTimeout(ratingTimerId);
} else if(result === "dismissed") {
}
},function(err){
errMgmt("menu/rateApp",2600.1,"Error opening rating dialog: " + err) ;
$scope.rateAppStore() ;
});
}
Console is outputting:
Supported: true
Rating: 0
Its not opening the dialog box...and with a rating result == 0
, its never making into any of the rating result
conditions (ie: requested, shown, dismissed). So, the question is, why would isRatingSupported() return true, but then in rating() itself the result is returning displaying 0 (which I interpret as 'false')?
As a temp work around on App-2, I had to add a result condition to pop the App Store review screens:
LaunchReview.rating(function(result) {
console.log("Rating: "+result) ; // outputs: "Rating: 0"
if (result === "requested") {
ratingTimerId = setTimeout(function() {
$scope.rateAppStore() ;
}, MAX_DIALOG_WAIT_TIME);
} else if (result === "shown") {
clearTimeout(ratingTimerId);
} else if(result === "dismissed") {
} else if (result === 0) {
$scope.rateAppStore() ;
}
}) ;
from cordova-launch-review.
Please try building and running the example project app which is a known working codebase for reference.
from cordova-launch-review.
Hi, thank for this answer.
I installed it, I put the id for my existing app on the play store, and I got the same result : the LaunchReview works work but for the Inapp rating, i only get the success alert on both my android devices.
from cordova-launch-review.
If I run the latest version of the plugin in the example project with the package ID of one of my own apps, it works fine:
So if you're sure the app package ID is valid/exists in the Play Store, then the problem must be in your development environment.
I suggest debugging in Android Studio and looking at the logcat output for errors.
However I'm closing this as I'm satisfied from testing that this plugin functionality is working correctly - I also have it deployed in live apps and see it being used by real Android users.
from cordova-launch-review.
Even if it's an environment issue (which is a guess), it would be better to let it open in case another developer have the same problem and can help, don't you think ?
from cordova-launch-review.
Ok, i tried with a fresh installation of cordova (10.0.0), and android studio on another computer, and the example still doesn't work on android.
from cordova-launch-review.
@dpa99c - is 4.0.0 specifically for Android 11 thus the updated .rating() returning a result==0
response that means something to Android 11 and has no relevance to Android 7 - 10 ? Just a thought.
from cordova-launch-review.
@dpa99c - just took a look at the code again. I see the Advanced .rating() has changed from previous version. I updated my code but the problem is still happening because result==0
and regardless of platform === "android"
the dialog box is not prompting and there is no condition to use the external app rating window.
To get it to work, still had to modify with the following - but this works on Android 7 - 10, I have not been able to test it on Android 11 and am thinking my code workaround would cause the in-app dialog launch AND the external app store rating to launch.
var MAX_DIALOG_WAIT_TIME = 5000; //max time to wait for rating dialog to display
var ratingTimerId;
LaunchReview.rating(function(result){
if(cordova.platformId === "ios" || result === 0){
if(result === "requested"){
console.log("Requested display of rating dialog");
ratingTimerId = setTimeout(function(){
console.warn("Rating dialog was not shown (after " + MAX_DIALOG_WAIT_TIME + "ms)");
}, MAX_DIALOG_WAIT_TIME);
}else if(result === "shown"){
console.log("Rating dialog displayed");
clearTimeout(ratingTimerId);
}else if(result === "dismissed"){
console.log("Rating dialog dismissed");
}
} else if(cordova.platformId === "android"){
console.log("Rating dialog displayed");
}
},function(err){
console.log("Error opening rating dialog: " + err);
});
from cordova-launch-review.
Related Issues (20)
- Predefined rating value HOT 1
- Why "Submit" button is disabled? HOT 4
- App rating dialog takes a bit of time to appear HOT 1
- The donate button in the github readme is broken. HOT 3
- rating() function returns no other results than "requested" HOT 2
- Multi-language supported ? HOT 1
- display a review dialog after x time of use / lunch - Android - HOT 1
- how can i call the review after x lunchs HOT 1
- Add support for in-app reviews on Android HOT 4
- Android inapp review - optional comment HOT 1
- If the rating dialog is displayed successfully on iOS, the result will not be returned. HOT 3
- New 4.0.0 rating(result) is returning 0, dialog not opening. HOT 5
- Ionic 5 using native api capacitor HOT 1
- how to open the "write review"tab on iOS ? HOT 1
- ERROR NullInjectorError: R3InjectorError(Or)[t -> t -> t]: NullInjectorError: No provider for t! HOT 1
- Android doesn't open the Google Play In-App Reviews APIs of the app. HOT 1
- Error after posting review (android)
- iOS `requestReview` API was deprecated. HOT 3
- package.json missing dependency HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cordova-launch-review.