Posts by Daniel Obara • 346 points
17 posts
-
1
votes1
answer481
viewsA: How to Relationship in Seeds and Factories in Adonisjs
Resolved as follows: Removed from Factory.js as Factories.Blueprint Settings, and also removed the settings and plans Seeds files. My file Factory.js was as follows: /** @type…
-
1
votes1
answer481
viewsQ: How to Relationship in Seeds and Factories in Adonisjs
I have the following question regarding Seeds and Factories. I have the following scenario: When the user is created automatically I need to create a settings record in the Userconfig table with the…
-
0
votes1
answer221
viewsA: You need the id for 'params.id' on the route and I already have the id in auth.user.id? Adonisjs
After studies it was understood that since we already have access to the user ID through the authentication middleware, we do not need to go through params on the route. However, since the…
-
1
votes1
answer1128
viewsA: React Starter. Take data typed in Input
all right? I believe you’ve already found your answer, but you’re going to solve it anyway. In this case to perform the tests I had the input label fill in the value passed by the father. I tested…
-
0
votes1
answer221
viewsQ: You need the id for 'params.id' on the route and I already have the id in auth.user.id? Adonisjs
I have the following question when creating my user’s Routes and Controller. I see that when I create the route with Route.Source automatically Adonis creates the CRUD routes and passing the ID in…
-
0
votes1
answer33
viewsA: How to popular data from another table when a new user is created in Adonisjs
I was able to solve it this way: First we need to have the relationship having the user FK in the user_config record. class ConfigurationsSchema extends Schema { up() { this.create("configurations",…
-
1
votes1
answer33
viewsQ: How to popular data from another table when a new user is created in Adonisjs
I am starting in Adonisjs and came across the following scenario: I have a table of user_config that is populated from the creation of a new user. Doubt: I would like to know first how to do so that…
-
1
votes1
answer341
viewsA: How to pull data from BD to Table ? (REACTJS + NODEJS + API)
good afternoon. Although we’re already talking at Discord I suggest: 1º API running, check the ports where your api is running. 2º Use some tool to test requests as for example: Insomnia. 3° Check…
-
1
votes1
answer197
viewsA: Vue code not indented in VS Code
Opa Matheus, all right? To format the codes we usually select at the bottom right of Vscode (In the image is Javascript next to Eslint) the type of language we are working and depending on the…
-
1
votes2
answers1137
viewsA: Store JWT token and redirect
Gabriel, as you asked how you would do.. follows another example: HTML: <input id="tokenField" type="hidden" /> <input id="submitButton" type="button" /> Javascript:…
-
1
votes2
answers1137
viewsA: Store JWT token and redirect
Hello Gabriel all right? You can store the token in the client localStorage or in a cookie. But apparently you are trying to send the POST token of a Ubmit form in which we know that it is not…
-
3
votes1
answer269
viewsA: Save text from one TEXTAREA with button and print to another div
good morning. I will explain the step by step according to your questions. How to save a text from a Textarea to a variable? Our input’s and button: <input id="primeiroInput"> <button…
-
2
votes1
answer25
viewsA: catch how much a video has already been uploaded (buffer)
Hello Otavio all right? I did some research on this and found some content on the site https://developer.mozilla.org/en-US/docs/Web/Guide/Audio_and_video_delivery/buffering_seeking_time_ranges The…
javascriptanswered Daniel Obara 346 -
2
votes2
answers125
viewsA: How to translate the isset function of php to an equivalent in javascript
I think it would be right to use Typeof instead of tipeof. this.distancia[i] = typeof this.mapa[this.no_inicio][i]
-
4
votes1
answer1792
viewsA: Carousel in the material-ui
Hello, follow code to make an image Carousel in Material-ui following the standard of their documentation. import React from 'react'; import PropTypes from 'prop-types'; import { withStyles } from…
-
1
votes1
answer54
viewsA: Calling Controller method and get the function print
First check if your controller is imported in this document for example: import userController from "./userController"; Then put the console log inside the function to see if it returns.…
-
0
votes1
answer971
viewsA: How to pass values to another component on routes?
Anderson, I’ve already had to do this once and usually to pass parameters/data to other components we use props or pass to the unstructured data. But in this case in specific authentication, I used…