@MaBbKhawaja wrote:
i need o show my tabs on all inner and sub pages of my ionic app how can i achieve this ?
Posts: 1
Participants: 1
@MaBbKhawaja wrote:
i need o show my tabs on all inner and sub pages of my ionic app how can i achieve this ?
Posts: 1
Participants: 1
@Manel00 wrote:
Hi everyone,
I’m trying to do a TODO list like this
its a document, but just i can do is to add, the other ways are so hard to see the way to reach it. Anyone can give me some example? Another easier ways?
Thanks you so much
Posts: 1
Participants: 1
@lsantaniello wrote:
Hi all,
I want to use Onesignal tags in order to send a push a subset of my users.To register the user to receive the push notification, I use this code and it works successfully:
var notificationReceidedCallback = function (jsonData) { console.log(jsonData); console.log('notificationReceidedCallback: ' + JSON.stringify(jsonData)); }; var notificationOpenedCallback = function (jsonData) { console.log(jsonData); console.log('notificationOpenedCallback: ' + JSON.stringify(jsonData)); }; window["plugins"].OneSignal .startInit(FIREBASE_APP_ID, FIREBASE_SENDER_ID) //.InFocusDisplaying(OneSignal.OSInFocusDisplayOption.InAppAlert) .handleNotificationOpened(notificationOpenedCallback) .handleNotificationReceived(notificationReceidedCallback) .endInit();I don’t understand How add the register to specific tag. I read the official documentation https://documentation.onesignal.com/docs/web-push-sdk#section–sendtags- but I have problem at runtime:
OneSignal.push(function() { OneSignal.sendTags({ key: 'value', key2: 'value2', }).then(function(tagsSent) { // Callback called when tags have finished sending }); });In the console:
message: "Uncaught (in promise): TypeError: Cannot call method 'then' of undefined↵TypeError: Cannot call method 'then' of undefined↵ at MyApp.enablePush (http://localhost/build/main.js:2031:16)↵ at http://localhost/build/main.js:2090:31↵ at t.invoke (http://localhost/build/polyfills.js:3:14976)↵ at Object.zone._inner.zone._inner.fork.onInvoke (http://localhost/build/vendor.js:5396:33)↵ at t.invoke (http://localhost/build/polyfills.js:3:14916)↵ at r.run (http://localhost/build/polyfills.js:3:10143)↵ at http://localhost/build/polyfills.js:3:20242↵ at t.invokeTask (http://localhost/build/polyfills.js:3:15660)↵ at Object.zone._inner.zone._inner.fork.onInvokeTask (http://localhost/build/vendor.js:5387:33)↵ at t.invokeTask (http://localhost/build/polyfills.js:3:15581)"Could you please support me?
Thanks in advance
Luca
Posts: 1
Participants: 1
@ke1234 wrote:
I have an ionic template with a checkbox .The condition is that once the value checked , the value should pass into the user_filter array(user_filter array already declared and working well). While i clicked on the select box the console1 value displayed but the console 2 not , means the data doesn’t entered in the array .Does any one know the reasons! …
<<ion-item> <ion-label>Non A/C</ion-label> <ion-checkbox (click)="choose_type('type','Non A/C',$event)"></ion-checkbox> </ion-item>choose_type(type: string, value: any, event: { target: { checked: boolean; }; }) { console.log('Inside choose type function'); //console1 let index; console.log('Boolean value',event.target.checked); if (event.target.checked === true) { console.log('Inside ture value'); //console2 console.log('Value checked true'); this.user_filter[type].push(value); } else { index = this.user_filter[type].indexOf(value); this.user_filter[type].splice(index, 1); } console.log('User filter array',this.user_filter); }
Posts: 1
Participants: 1
@johnmorgan13 wrote:
Hi,
I want to include a static height / width google map element inside my tab
<content>area but I don’t want to enable a rubber-band effect or show scroll bars. How do I go about this?I tried overriding .scroll css rule with width: 100% and height:100%. This worked but definitely isn’t a good practice.
How about a content attribute that disables rubber-band scrolling, and another supporting facilitating full-width / full-height content?
Thanks & Regards,
John
Posts: 1
Participants: 1
@rigorio wrote:
I have cards that I want to show 2 by 2 per line
<ion-card class="cardo" *ngFor="let transient of transients" (click)="itemTapped($event, transient)">.cardo { width: 40%; }How do I make it so that they appear side by side?
Posts: 2
Participants: 1
@RahulPrakashSS wrote:
I am using Ionic V4.
ionBlur and ionFocus events are not triggering in ion-select
Posts: 1
Participants: 1
@Jalvarez05 wrote:
Hello Everyone .
I’m trying to openModal when user click on ion-avatar but it doesnt work on devices , it only works on PWA.
This is my code :
<ion-item> <ion-avatar item-start (click)="openSearchCountryModal();$event.stopPropagation()" tappable> <img *ngIf="country.flag" src="{{country.flag}}"> </ion-avatar> <ion-label floating>Phone</ion-label> <ion-input type="number" formControlName="phone" placeholder="phone"></ion-input> </ion-item>You can check the image here:
How can i achieve that ?
Posts: 1
Participants: 1
@sugisha wrote:
I want to get the location update if there are any significant changes even if the app is terminated. Is there any way to get the update?
Posts: 1
Participants: 1
@SwapnaliG wrote:
Ionic 4- InAppBrowser for android and ios platform
How to fetch javascript function return value, fetch response of open url /function to App???
Posts: 1
Participants: 1
@flaviotobias wrote:
I have installed the last version of facebook plugin from Ionic Native page
I’m trying to open the share dialog and the pluggin is issuing the following error:
On Chrome
ERROR TypeError: Object(…) is not a function
at Facebook.showDialog (index.js:31)
at ContentDetailPage.webpackJsonp.948.ContentDetailPage.facebookShare (content-detail.ts:860)
at SafeSubscriber._next (content-detail.ts:826)
at SafeSubscriber.__tryOrUnsub (Subscriber.js:238)
at SafeSubscriber.next (Subscriber.js:185)
at Subscriber._next (Subscriber.js:125)
at Subscriber.next (Subscriber.js:89)
at SafeSubscriber._next (app-server.ts:180)
at SafeSubscriber.__tryOrUnsub (Subscriber.js:238)
at SafeSubscriber.next (Subscriber.js:185)On Android
vendor.js:1704 ERROR TypeError: Object(…) is not a function
at Facebook.showDialog (vendor.js:82874)
at ContentDetailPage.webpackJsonp.948.ContentDetailPage.facebookShare (0.js:794)
at SafeSubscriber._next (0.js:769)
at SafeSubscriber.__tryOrUnsub (vendor.js:22574)
at SafeSubscriber.next (vendor.js:22521)
at Subscriber._next (vendor.js:22461)
at Subscriber.next (vendor.js:22425)
at SafeSubscriber._next (main.js:3732)
at SafeSubscriber.__tryOrUnsub (vendor.js:22574)
at SafeSubscriber.next (vendor.js:22521)Here is my code:
this.fb.showDialog({
method: ‘share’,
href: url,
caption: ‘Your comment’
description: this.condes,
picture: this.coverurl
}).then((response) => {
console.log('Share response: ',response);
}).catch((error) => {
console.log('Share error: ',error);
})Plugin versions:
Cordova Facebook
name=“cordova-plugin-facebook4” spec=“4.2.1”Ionic Native Facebook
“_from”: “@ionic-native/facebook”,
“_id”: “@ionic-native/facebook@5.2.0”,Here is my enviroment information:
Ionic:
ionic (Ionic CLI) : 4.12.0 (C:\Users\flavi\AppData\Roaming\npm\node_modules\ionic)
Ionic Framework : ionic-angular 3.9.2
@ionic/app-scripts : 3.2.1Cordova:
cordova (Cordova CLI) : 8.1.2 (cordova-lib@8.1.1)
Cordova Platforms : android 7.1.4, browser 5.0.4
Cordova Plugins : cordova-plugin-ionic-webview 1.1.1, (and 21 other plugins)System:
Android SDK Tools : 26.1.1 (D:\Dev\Android\Android-sdk)
NodeJS : v8.9.4 (C:\Program Files\nodejs\node.exe)
npm : 6.4.1
OS : Windows 10What can I do?
Thanks
Posts: 1
Participants: 1
@dmlkl wrote:
Hi all,
I tried to do polling for every 10 seconds, to get the latest status of the device by calling API. However, when I get data from the API, I will update the existing data (Array, at html using ngfor) and render to UI, it will cause the image flickering. Any idea on this issue? Or it just my bad coding?
Thanks.
Posts: 1
Participants: 1
@Jambox wrote:
Hi. I am using Ionic 4 to develop an app, and am having some problems when I try to build it for iOS. When I attempt to run the app in Xcode, it will fail in the linking phase with the following error:
ld: 346 duplicate symbols for architecture x86_64 clang: error: linker command failed with exit code 1 (use -v to see invocation).
This is preceded by a list of the duplicate symbols like so:
duplicate symbol OBJC_IVAR$_FIRInstanceIDURLQueryItem._name in: /Users/james/Library/Developer/Xcode/DerivedData/Jambox-ataoinheliizvyaczvbklhkqvhpf/Build/Products/Debug-iphonesimulator/FirebaseInstanceID/libFirebaseInstanceID.a(FIRInstanceIDURLQueryItem.o) Jambox/Plugins/cordova-plugin-firebase/FirebaseInstanceID.framework/FirebaseInstanceID(FIRInstanceIDURLQueryItem_ce817fff617a4255d51c2a25da32a1f0.o)
These are relating to the following frameworks:
- FirebaseInstanceID.framework
- GoogleUtilities.framework
- nanopb.framework
- FirebaseCore.framework
I have tried a few solutions to this problem, but none result in success:
1). Removing -ObjC and $(inherited) from Other Linker Flags - this causes the app to build and link successfully, but crash on startup with this error:
*** Terminating app due to uncaught exception ‘NSInvalidArgumentException’, reason: ‘+[FIRApp registerAsConfigurable:]: unrecognized selector sent to class 0x1080bc178’
2). Removing each framework in the list of duplicate symbols - this helps in lowering the number of duplicate symbols. I can get it down to 65 duplicate symbols until I have to remove GoogleUtilities.framework, which causes the build the fail with this error:
Undefined symbols for architecture x86_64:
“OBJC_CLASS$_GULObjectSwizzler”, referenced from: objc-class-ref in FirebasePerformance(FPRObjectInstrumentor_f65d32035cadef24185912716f0b12f9.o) objc-class-ref in FirebasePerformance(FPRNetworkTrace_3053ec2ab59f2fcfec4b18c29e4b4cec.o) objc-class-ref in FirebasePerformance(FPRNSURLConnectionInstrument_5611d225f62417fa73742554b6a45401.o) ld: symbol(s) not found for architecture x86_64 clang: error: linker command failed with exit code 1 (use -v to see invocation)3). Deleting DerivedData folder - I get the same errors after doing this.
4). Removing and adding the iOS platform - Same errors.
Posts: 1
Participants: 1
@egaldamez wrote:
Hello friends, first of all im new to Ionic and im working in using Services to pass variables from one form to another, i have a bit of a issue at the moment.
I have a login form, the submit button post the data to my backend api and gives a json in response with error codes and information that i need.
Then with the response i update the variables on my dataService to get all the info i need from the json and use it through all my app.
After i stored all the variables i need to get i alert them just to make sure they are available as you can see in the screen captures im adding.
![]()
Then if the login is correct, i go to the MAIN page and in the main page ts i use the ngOnInit to get the variables from my dataService to my main page.
But sometimes i don’t know why the variables apparently are not ready i think? correct me if i’m wrong about that.
How can i get this to workTHANKS IN ADVANCE
Example of my Login TS
Login(){
var hash = require(‘hash.js’);
var pass = hash.sha256().update(this.password).digest(‘hex’);
let urlSearchParams = new URLSearchParams();
urlSearchParams.append(‘idusuario’, this.usuario);
urlSearchParams.append(‘password’, pass);this.GetService.getData(`LOGINPREM?${urlSearchParams.toString()}`) .subscribe(async data => {this.result = JSON.stringify(data); // get data in result variable this.dataService.setjsonresult(this.result); alert(this.dataService.getjsonresult()); this.allData = JSON.parse(this.result); // parse json data and pass json string this.dataService.setuserID(this.allData['Cliente']); alert(this.dataService.getuserID()); this.dataService.setName(this.allData['Nombre']); alert(this.dataService.getName()); this.dataService.setPoints(this.allData['SaldoPuntos']); alert(this.dataService.getPoints()); if (this.allData['Error']== 200) { const toast = await this.toastController.create({ message: "Bienvenido " + this.allData['Nombre'], position: 'top', duration: 2000 }); toast.present(); //this.router.navigate(['/news', {Cliente: this.allData['Cliente']}]); //this.router.navigate(['/welcome', this.allData]); this.router.navigateByUrl('/menu/main'); return false; } else { const toast = await this.toastController.create({ message: "Codigo de Error: " + this.allData['Error'] + " Descripcion: " + this.allData['Descripcion'] , position: 'top', duration: 2000 }); toast.present(); //this.router.navigate(['/home', this.allData]); this.router.navigateByUrl('/login'); return false; } });}
Example of Main.ts
import { Component, OnInit } from ‘@angular/core’;
import { DataService } from ‘./…/…/services/data.service’;
import { CanActivate, Router, ActivatedRouteSnapshot, RouterStateSnapshot } from ‘@angular/router’;@Component({
selector: ‘app-main’,
templateUrl: ‘./main.page.html’,
styleUrls: [’./main.page.scss’],
})
export class MainPage implements OnInit {
cliente : any;
points: any;
id:any;
constructor(private router: Router, private dataService: DataService) { }ngOnInit() {
this.id = this.dataService.getuserID(); //if(!this.id){ //this.router.navigateByUrl('/login'); //}; this.cliente = this.dataService.getName(); this.points = parseInt(this.dataService.getPoints());}
}
Posts: 1
Participants: 1
@ady wrote:
Hello,
I’m having a problem with directives in Ionic 4. I’m trying to make a simple directive that just outputs something with console.log. To begin with, I tried importing the directive into app.module and declaring it, then importing it into my component and adding the attribute to the HTML element, but nothing happens. No errors, no logs in the console or anything.
Then I did a bit of reading and found out that some people have had trouble with directives and “lazy loading” in Ionic 4. I’ve since tried creating a “SharedModule” that imports, declares and exports the directive, then importing it to my app.module and component, but it still doesn’t seem to work at all as before.
I’m not sure if I’m doing this right so I’d really appreciate if anyone could scan my code and see if something doesn’t look right. Here are the main parts:
directives/marker.directive.ts
import { Directive, ElementRef } from '@angular/core'; @Directive({ selector: '[atlasMarker]' }) export class MarkerDirective { constructor(element:ElementRef) { console.log(element); } }shared/shared.module.ts
import { NgModule } from '@angular/core'; import { MarkerDirective } from '../directives/marker.directive'; @NgModule({ declarations: [ MarkerDirective ], exports: [ MarkerDirective ] }) export class SharedModule { }app.module.ts
import { NgModule } from '@angular/core'; import { BrowserModule } from '@angular/platform-browser'; import { RouteReuseStrategy } from '@angular/router'; import { HttpClientModule } from '@angular/common/http'; import { IonicModule, IonicRouteStrategy } from '@ionic/angular'; import { SplashScreen } from '@ionic-native/splash-screen/ngx'; import { StatusBar } from '@ionic-native/status-bar/ngx'; import { AppComponent } from './app.component'; import { AppRoutingModule } from './app-routing.module'; import { SharedModule } from './shared/shared.module'; @NgModule({ declarations: [ AppComponent ], entryComponents: [], imports: [ BrowserModule, HttpClientModule, IonicModule.forRoot(), AppRoutingModule, SharedModule ], providers: [ StatusBar, SplashScreen, { provide: RouteReuseStrategy, useClass: IonicRouteStrategy } ], bootstrap: [AppComponent] }) export class AppModule {}map/map.page.ts
import { Component } from '@angular/core'; import { NavController } from '@ionic/angular'; import { HttpService } from '../services/http.service'; import { MapService } from '../services/map.service'; import mapboxgl from 'mapbox-gl/dist/mapbox-gl'; import { SharedModule } from '../shared/shared.module'; @Component({ selector: 'app-map', templateUrl: './map.page.html', styleUrls: ['./map.page.scss'], }) export class MapPage { map:mapboxgl.Map; poll:any; constructor( private navController:NavController, private httpService:HttpService, private mapService:MapService ) { } ionViewDidEnter() { this.mapService.openMap(); this.poll = this.httpService.poll('map/poll', {}, 4000).subscribe((data) => { console.log(data); }); } ionViewDidLeave() { this.mapService.closeMap(); this.poll.unsubscribe(); } }map/map.page.html
<ion-content> <div id="map"></div> <div atlasMarker>Test</div> </ion-content>Sorry for the amount of code here. I’m not sure what’s happening so I thought it’d be better to include most of it. I did remove some parts that have nothing to do with the problem. I’m hoping there’s a simple solutions that I’m just not seeing.
Thanks very much to anyone that has a look!
Posts: 1
Participants: 1
@motionstrand wrote:
I built an app that I got into apple’s test flight and today I sent out the notifications to users to start beta testing, but for some reason it is showing the user the previous build. If the user closes the app and reopens the app it shows the current version.
In my config.xml file I have defined
<plugin name="cordova-plugin-ionic" spec="5.2.8"> <variable name="APP_ID" value="my app id" /> <variable name="CHANNEL_NAME" value="Master" /> <variable name="UPDATE_METHOD" value="auto" /> <variable name="UPDATE_API" value="https://api.ionicjs.com" /> <variable name="MAX_STORE" value="2" /> <variable name="MIN_BACKGROUND_DURATION" value="30" /> </plugin>My latest commit is assigned to the Master channel and this is the one not shown until the user force closes and then opens the app again.
Is something wrong here? Not sure why this is happening. This also was happening to me when I was testing on my own device using a development provisioning profile. I had to always open the app once, close it and reopen it to see the new build. Any ideas?
Posts: 1
Participants: 1
@rbender wrote:
Our organization has had our app in the Google Play store for a couple months running an internal test group (app is not publicly available). Just within the last few days, the app was suspended due to Malicious Behavior. Our app is only web components at this time with the use of a few Cordova plugins:
cordova-plugin-whitelist cordova-plugin-statusbar cordova-plugin-device cordova-plugin-splashscreen cordova-plugin-ionic-keyboard cordova-plugin-touch-id cordova-plugin-code-push cordova-plugin-file cordova-plugin-file-transfer cordova-plugin-zip cordova-plugin-app-version cordova-plugin-secure-storage cordova-plugin-fingerprint-aio cordova-plugin-ionic-webviewWe’ve appealed the suspension asking for more detail (as we have no idea what in our app could be considered malicious) but the only response we got back was the same link to the Malicious Behavior policy. We have looked at this in depth and find no reason to believe our app is malicious.
Has anyone else faced a similar issue? Without any additional information we have no course of remediation and are not able to move forward. Can anyone suggest a means of elevating the appeal, or a means to contact Google Play and get more concrete information? The only way we have now is through their support email (not very helpful).
Thank you.
Posts: 1
Participants: 1
@cyptus wrote:
the ionic diagnostic plugin interface is missing the requestRemoteNotificationsAuthorization method
see
and
is there any reason why this method is missing? how should i request this permission by hand?
Posts: 1
Participants: 1
@nsrathore wrote:
We have
A. app module,
B. one lazy load module
C. a module with component in it.When i lazy load the module using router it works,
i had used that C module component which also works but it no showing properly in that component.What i figure out that when we load a component either normally or using lazy load technique ionic add a class name “ion-page”.
And when i try to add a child component in that, it’s not visible, probably because of small height .
After i tried to add that class “ion-page”
manually to my component it display correctly.Image will explain it better
Posts: 1
Participants: 1
@edinhorod wrote:
Hi folks, I need to implement a calendar in a app with ionic v1, but I need to select multiples dates. I even try any plugins, but nothing was fit me. Someone can help me?
Posts: 1
Participants: 1