Questions tagged [bloc.io]

10 questions
9
votes
4 answers

I18n::MissingTranslationData: translation missing: en.faker error when seeding db

I want to seed the database with Faker, the problem is that I am getting an error when I do a: rake db:reset I get this message: rake aborted! I18n::MissingTranslationData: translation missing:…
bntzio
  • 1,274
  • 14
  • 27
2
votes
5 answers

Modifying an array item in Ruby if it includes a specific word

I can't find the solution for this problem, I did a research in order to find the problems and fix them but can't think for any answer yet. What I want to do is to convert a string into a Title cased string. For example: "The Lord Of The Rings" >…
bntzio
  • 1,274
  • 14
  • 27
1
vote
1 answer

undefined method for route in nested resource

What I want to accomplish is to create POST and DELETE links into my views, as a like button, for example. I have created a method (def liked) in my user model (user.rb) that will check if a user has liked a bookmark or not, and show 'unlike' or…
bntzio
  • 1,274
  • 14
  • 27
1
vote
1 answer

Mailgun routes not connecting to incoming controller

I'm having a hard time finding a solution (almost 3 days) my code in incoming_controller.rb seems to be right, I tested it in the rails console and appears that the only problem is that when I send an email (from my gmail account) to my mailgun…
bntzio
  • 1,274
  • 14
  • 27
0
votes
1 answer

Pundit Policy : Wikis not showing up for collaborators

I want different types of wikis to appear on the index view depending on the role of the user. The policy for admin and standard / guest users work as it should but when it comes to premium users and collaborations it gets a little messy. In my app…
Miguel Angel Quintana
  • 1,371
  • 2
  • 9
  • 12
0
votes
1 answer

User_id is not fetched in join table

I have a the following form:

Add collaborators to the wiki <%= @wiki.title %>

<%= form_for ([@wiki, @collaboration]) do |f| %> <% @users.each do |user| %>

<%= check_box_tag 'user_ids[]', user.id %> <%= label_tag…

user3706202
  • 197
  • 1
  • 3
  • 14
0
votes
2 answers

Faker seed data coding error

I’m a new rails student working on a project that has a user login, each user has one list and each list has many items. Items are nested under lists in my routes. I’m having a few issues. My code below loads one user and one list for that user,…
Dale Brown
  • 305
  • 1
  • 4
  • 8
0
votes
1 answer

Looping through a controller instance variable in a view in Rails

I'm fairly new to rails, and working on a application that would display daily submissions. I'm now trying to display posts for every day. So I did a few things: Set up the controller instance variable to a single @submissions, which takes the…
Bryan Parman
  • 115
  • 1
  • 7
0
votes
1 answer

Post does save in the right folder

I have a project a github which can be found here: https://github.com/marcvanderpeet12/bloccitmaster I have the following problem: If I go here: http://localhost:3000/topics/2 and add a new post I save a post but its not saved in the right folder…
user3706202
  • 197
  • 1
  • 3
  • 14
-2
votes
5 answers

why is console.log output different from a return output

I'm new to JavaScript so sorry for the amateur question but I feel as through the answer would help to make more sense of the course material, and assignments, in my online course. Here it is. When I write console.log like this: var getKeys =…