Questions tagged as 'ruby'

2
answers

collect data from an index.htm.erb scaffold in ruby and take them to another scaffold index.html through a link

This is the code of index.html.erb of my scaffold contactos : <h1>Contactos</h1> <br> <table class= "table-hover"> <thead> <tr> <th>Nombre</th> <th>Apellid...
asked by 07.06.2018 / 13:22
2
answers

collect data from an index.htm.erb scaffold in ruby and take them to another scaffold index.html through a link

This is the code of index.html.erb of my scaffold contactos : <h1>Contactos</h1> <br> <table class= "table-hover"> <thead> <tr> <th>Nombre</th> <th>Apellid...
asked by 07.06.2018 / 13:22
1
answer

Rails 5, model all fields in capital letters

In ASP NET MVC I can create a class library where I have help classes for different situations (date conversion, encryption, etc.), but I have a specific one that receives my model and goes through the properties and those that are type Stri...
asked by 20.05.2018 / 20:18
1
answer

Add column to a Ruby scaffold

I am a beginner in Ruby and I have the following question: after having generated a scaffold called negotiations with the fields name: string last names: string I have noticed that I am missing one more, age: integer. I tried to generate it manu...
asked by 15.05.2018 / 22:17
1
answer

NoMethodError in Reservations # new with a form_for in Ruby on Rails

I'm doing a cabin rental system in RoR and I get this error in the view new of Reservations (reservations), which gives when I try to create a form in the view. If I show the empty object that passes the controller does not throw m...
asked by 29.04.2018 / 18:07
1
answer

I can not raise the server in Rails Mac os

When trying to raise the server with Rails from the terminal, it turns out that I have the following problem: MacBook-Pro-de-Brian:~ Brian$ rails new twitter /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/lib/ruby/2.3.0/rubygems.rb...
asked by 29.04.2018 / 22:31
1
answer

How to know if a model has 0 relations. Rails

I have a question about how to optimize a query, I'm doing it with a select to an active record query. How could I do this in a single SQL query. Here, for example, is a request. maintenance_service_requests has a Has and belong to many with...
asked by 12.04.2018 / 02:35
1
answer

help I have a problem in haml

This is my code !!!5 %html{class:"no-js", lang:"es"} %head %meta{charset:"utf-8"} %title La mejor comida. %meta{name:"description", content:"Come rico en el mejor restaurante de la ciudad, servicio de prime...
asked by 11.04.2018 / 16:59
0
answers

Problem finishing cart

I am setting up a shop, it consists of products, users, a cart, using several examples and getting in hand I make some modifications, but I find myself stuck in the following: At the end of the cart I want a button that closes it and allows the...
asked by 26.02.2018 / 15:35
0
answers

Simulate a "command + v" in Selenium web driver

I have a program made with ruby and selenium chromedriver. In windows to simulate a ctrl + v to the next line user.send_keys(:control, "v") and it worked correctly. But when doing it on Mac I could not. Try with user.send_keys(:c...
asked by 02.03.2018 / 16:23