Posts by brenodiogo • 181 points
14 posts
-
1
votes1
answer78
viewsA: Change sidemenu items in Ionic 5
Apparently you are dealing with login event. In this case, it is advisable to use the Guard. More details here. Anyway, to communicate between two Components you can create an intermediate service.…
-
0
votes1
answer91
viewsA: ngFor duplicating values when changing and returning page
The problem lies in that line: this.day_rmmdatas.push(day_rmmdata); The first time you enter the page, the array this.day_rmmdatas is empty. However, the second time you return to the page, the…
-
0
votes2
answers750
viewsA: How to pick up *ngFor Angular 7 item
When you call const empresa = this.form.get('Empresa').value; the value being sought is the property value option field. Since this property is null, the value passed is the value that is between…
-
0
votes1
answer254
viewsA: How to save additional data to the Firebase user account with Ionic app?
In this case, you will probably want to do a CRUD (Create, Read, Update and Delete). This video shows you how to do. Considering that you already have integrations with firebase, just go to your…
-
0
votes1
answer130
viewsA: Angular - ng2-Charts - Heading on x-axis
ng2-Charts uses Chart.js. You find many examples here. Now there is doubt about what exactly you want to show on the x-axis. If it is the measured value, you can use that plugin. In the sample page…
-
0
votes1
answer65
viewsA: Generate content dynamically with single observable
I don’t know if I understand this correctly, but it seems to me that there is a certain confusion of concepts. By clicking on "has attachment", the function onClickAnexo() should be responsible for…
angularanswered brenodiogo 181 -
1
votes1
answer345
viewsA: how to manipulate an object inside an array in typescript
If you only want the value of the selected field, you don’t even need to fill in the attribute value: <select (change)="onChange($event.target.value)"> <option *ngFor="let perfil of…
-
0
votes1
answer60
viewsA: Priority in a notification using firebase
I imagine you’re wearing the FCM Ionic plugin. On the documentation page, there is an example using the field "Priority":"high": { "notification":{ "title":"Notification title", "body":"Notification…
firebaseanswered brenodiogo 181 -
1
votes1
answer36
viewsA: Ionic 3 problems with get in estorage
Well, there are at least 2 errors. 1 - You are making a request to a local server that does not have CORS enabled. You can see more about CORS here. In short, applications in Ionic are a webview.…
-
0
votes1
answer972
viewsA: How to add data to the JSON file in Angular 6
Well, maybe there is some confusion when manipulating JSON objects. For example, you can simply: var todasMensagens:any = [ { "texto": "Oi galera, como vocês estão?", "data": "2018-09-25T21:08:52",…
-
3
votes1
answer262
viewsA: What is the question line += 1 in this code?
In short, the operator += sums the following value and adds it to the previous variable. In the case of: questao +=1 is (more or less)* equivalent to questao = questao + 1 *Not exactly equivalent,…
pythonanswered brenodiogo 181 -
3
votes2
answers79
viewsA: Read file without displaying space
To remove all special characters, can use the isalnum function(): frase = "O rato roeu a roupa\n Do rei de Roma" #Remove todos os caracteres especiais frase = ''.join(e for e in frase if…
pythonanswered brenodiogo 181 -
0
votes1
answer187
viewsA: Sum and Multiplication with items of a CSV
Well, the menu item is accessed by line[1] as a string. Then you need to convert to float if you want to multiply by the number of guests: float(line[1]). In that case: import csv arquivo =…
-
0
votes2
answers189
viewsA: JSON.stringfy of large objects with Angular 8
In this case, I believe the best way is to work with a model. You create a new file called person.model.ts with the following code: export class Municipio{ id: number; } export class User { id:…