On Tuesday, December 3, 2019 at 5:55:24 PM UTC-5, Daniel Baez wrote:
>
>
>- What is going wrong with your DB that its built-in caching is
>insufficient?
> - Load, there are millions of queries running a sec now, and the
> Active Model classes I want to update are read constant
arge, it
seems like you might be over-thinking this.
Jim Crate
On Saturday, August 10, 2019 at 9:56:21 PM UTC-7, San Ji wrote:
>
> Thank you, Phil
> The latter suggestion is actually what I planned to do, with nginx handle
> the path routing instead of having separated endpoints.
As outlined in
https://snyk.io/blog/malicious-remote-code-execution-backdoor-discovered-in-the-popular-bootstrap-sass-ruby-gem/
TLDR
If you use bootstrap-sass version 3.2.0.3, just do bundle update
bootstrap-sass and you're good to go
--
-
On Wednesday, February 6, 2019 at 4:32:26 AM UTC-8, Rob Jonson wrote:
>
>
> If there is an administrator, please consider removing the individual from
> this list.
>
> If there is no administrator, then my request to everyone else is to treat
> this like trolling, and just stop feeding the troll
On Sat, Jun 9, 2018 at 5:54 AM, Robert Phillips wrote:
> why is id off by one or defined different in edit vs in update? I will
> explain what I mean
>
> I have a controller called Bottles and a model Bottle
>
> My config\routes.rb file has the line- resources :bottles
>
> I have this controller
On Tue, Feb 27, 2018 at 1:32 PM, fugee ohu wrote:
> I mounted an engine and it has it's own assets pipeline How do I override
> or add to it? It's in a subdirectory under the gem root path
> /app/assets/stylesheets/blogit There's no application.css file in the
> folder, only other css files I cre
7;,'Hired','Provisionally
Hired','Hired','Provisionally Hired','Hired']
if (employment_status - ['Hired', 'Provisionally Hired']).empty?
# ...
end
That removes the values you are looking for from the original array, and if
it's empty
Hey Ralph,
Happy to help! The readme is a great
resource: https://github.com/turbolinks/turbolinks
Jim
On Friday, July 7, 2017 at 3:22:48 PM UTC-4, Ralph Shnelvar wrote:
>
> May all the gods of all the religions bless you, your house, your family,
> your extended family, and you
On Tue, Jul 11, 2017 at 9:27 PM, Ralph Shnelvar wrote:
> In a file named spec/spec_helper.rb I see
> # See http://rubydoc.info/gems/rspec-core/RSpec/Core/Configuration
> RSpec.configure do |config|
> # The settings below are suggested to provide a good initial experience
> # with RSpec, but feel
Why not try and see if it works?
On Friday, July 7, 2017 at 11:52:39 AM UTC-4, fugee ohu wrote:
>
> Can I apply method calls to current_user directly like
> current_user.pictures instead of @user=User.find(current_user.id);
> @user.picures
>
--
You received this message because you are subscr
like http://code.runnable.com
Jim
On Wednesday, July 5, 2017 at 1:51:46 AM UTC-4, Ralph Shnelvar wrote:
>
> This is my first post here. Comments on style, etc., are appreciated.
>
> An answer is even more appreciated.
>
> This is a continuation of my question at
> https://stack
On Wed, Jun 28, 2017 at 1:38 PM, fugee ohu wrote:
>
>
> On Tuesday, June 27, 2017 at 8:01:40 PM UTC-4, Walter Lee Davis wrote:
>>
>>
>> > On Jun 27, 2017, at 9:12 AM, fugee ohu wrote:
>> >
>> >
>> >
>> > On Tuesday, June 27, 2017 at 7:32:33 AM UTC-4, Walter Lee Davis wrote:
>> >
>> > > On Jun 27
On Wed, Jun 7, 2017 at 11:24 AM, Jim Ruther Nill wrote:
>
>
> On Wed, Jun 7, 2017 at 11:21 AM, fugee ohu wrote:
>
>> The rails scaffolding generator creates delete links as objects in index
>> views so why when I google how to pass params to a delete link all the
>>
On Wed, Jun 7, 2017 at 11:21 AM, fugee ohu wrote:
> The rails scaffolding generator creates delete links as objects in index
> views so why when I google how to pass params to a delete link all the
> answers are examples where a path is used My links don't have a path, they
> have an object That'
Hi guys,
I'm posting another "looking for remote work" post as things have settled
down with
the last project.
If anyone is looking for a Rails developer with solid experience, just hit
me up and let's
talk. I can commit around 4 hours a day as I have full time work.
Thanks a lot and have a gre
eps you from using postgres for development?
>
> Thanks,
> Joe
>
> On Thursday, April 27, 2017 at 7:02:48 PM UTC-4, jim wrote:
>>
>>
>>
>> On Fri, Apr 28, 2017 at 8:54 AM, Joe Guerra wrote:
>>
>>> Hi, I got stuck on a migration (basically to fix
On Fri, Apr 28, 2017 at 8:54 AM, Joe Guerra wrote:
> Hi, I got stuck on a migration (basically to fix a column name). I
> actually went into the table itself and corrected the problem. My herkou
> migration gets stuck, and I've got other migrations behind it that aren't
> running.
>
If you've
Hi Tariq,
I'm available! Just let me know what you need and see what we can set up.
Cheers,
Jim
On Fri, Mar 31, 2017 at 10:33 PM, tariq khan wrote:
> Hi Jim,
>hope you will be fine, i read your post so i want to contact
> you, i need a web developer who work
Hi Falk,
I'm definitely interested. My hourly rate is $50/hour. I usually do a
trial period involving
1-2 simple tasks. If you're keen, let me know :)
On Thu, Mar 16, 2017 at 5:04 PM, FALK LIEDER
wrote:
> Hi Jim,
>
> I just saw your post on the Ruby on Rails list, and I
Hi,
I am deeply sorry if this is an inappropriate post for this group. Please
disregard if it is.
I'm Jim, a Rails developer for about 8 years (turning 9 in May). I'm
looking for a part time
project that I could work on after office hours as I am away from my family
and have an
ample
ActiveRecord will handle converting a Time into something your database
understands, so you don't need to worry about that. You can also write the
where clause manually like you did, or you can use arel, which would be my
preference. You can also chain .where()'s, since they just return
Activ
ays back into a Hash.
We do this with by calling #to_h
<http://ruby-doc.org/core-2.4.0/Array.html#method-i-to_h> on the Array,
which will interpret the Array as an Array containing other Arrays of
key-value pairs and return a Hash.
There's a lot going on in those
to fork a new long-running process. It
handles closing/re-opening database connections, etc.
https://github.com/tra/spawnling
Another alternative could be Server-Sent Events (SSE), which works with
Passenger > 4.0.5. It will require changes in how you set up the front end
as well, but is goo
Your test database isn't being cleared after each test run. Normally this
problem is solved by running each test in a transaction which is rolled
back at the completion of each test. You can enable this in RSpec with the
use_transactional_fixtures option.
Alternatively, check out the database_
Personally, I would view the Receipt Summary as its own class, maybe
ReceiptRpt::ReceiptSummary. I'd probably do the work currently in your
receiptsummary method in the initialize method, then store the values that
you need in your view in instance variables, and define attr_readers for
them.
students and
districts (your reporting districts), correct? You could add a field in
that table to indicate the primary district.
If a student will only ever have one primary district, I would generally
prefer the first way.
Jim Crate
--
You received this message because you are subs
ou could do this:
current_user.profile.friendables.accepted.where(Friendable.arel_table[:
from_id].eq(current_user.id).or(Friendable.arel_table[:to_id].eq(
current_user.id)))
Jim
On Friday, April 8, 2016 at 4:45:42 AM UTC-4, Giedrius Rimkus wrote:
>
> You can achieve this with:
>
You got it!
Yup, it's on you, but it's surprisingly simple since you're only working on
the response side. In just a few lines of code, I've done some cool stuff
without a page refresh or client side framework.
Jim
On Tuesday, March 15, 2016 at 2:44:10 PM UTC-4, Ruby-
No problem - glad you got it worked out!
On Tuesday, March 15, 2016 at 9:43:06 PM UTC-4, Justin Stanczak wrote:
>
> OMG I'm just stupid. I just figured out what my issue is. All is working
> fine, I just forgot to use the includes. Geez. Sorry for the waste of time,
> and thanks for helping out.
Interesting. Have you tried clearing Rails' tmp files with `rake
tmp:clear`? I've seen that clear up weird asset-related issues.
If that doesn't work, would it be possible to push your app to GitHub or
somewhere public so I could take a look? If the code is private, you could
potentially cre
The Rails guide has a great write-up on
this:
http://guides.rubyonrails.org/working_with_javascript_in_rails.html#form-for
Essentially, remote: true will handle submitting your form via ajax for
you, but it's on you to handle the response (since that's going to be very
application-specific).
omponents, you can add it to the sass load paths (as you've
done), and that should work after a server restart. Is your
foundation.scss file in vendor/assets/components/foundation-sites/scss?
Jim
On Monday, March 14, 2016 at 9:55:20 PM UTC-4, Justin Stanczak wrote:
>
>
>
Hello! Room 118 Solutions (http://room118solutions.com) is a small web
application consultancy specializing in Ruby on Rails. We’ve reached our
capacity and we’re looking for a Rails freelancer to help us out. This
would be an ongoing relationship with lots of growth potential.
Technologie
On Wednesday, January 13, 2016 at 12:13:36 PM UTC-5, Jim wrote:
>
>
> If you want to load matching As without instantiating the Cs, you could do
> something like:
>
> A.where(id: C.where(code: params[:codes]).pluck(:a_id))
>
> If you are going to instantiate all As and Cs
found_c = C.where(code: params[:codes]).includes(:a)
found_a = found_c.collect(&:a).uniq
Jim
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email
On Sun, Sep 27, 2015 at 4:41 AM, Colin Law wrote:
> On 26 September 2015 at 19:29, Jim Ruther Nill wrote:
> > hmm maybe relevant
> > http://www.benknowscode.com/2014/02/ruby-date-time-range-intervals.html
>
> Thanks, if I interpret that correctly it is saying that what I a
hmm maybe relevant
http://www.benknowscode.com/2014/02/ruby-date-time-range-intervals.html
On Sun, Sep 27, 2015 at 12:03 AM, Colin Law wrote:
> Can someone explain this for me please?
>
> range = (DateTime.now..DateTime.now+1.hour).step(10.minute)
> => # 17:41:18 +0100:step(600 seconds)>
> 2.1.
On Saturday, September 5, 2015, Sadaf Noor wrote:
> Also posted at stackoverflow:
> http://stackoverflow.com/questions/32414734/setting-foreign-keys-at-rails-yet-record-association-name-returning-nil
>
> ( Please don't downvote )
>
>
> 2015-09-05 21:22 GMT+06:00 Sadaf Noor >:
>
>> Please help me
I'm trying to maintain a system written in Ruby 1.9.3 and Rails 3.2.13. My
Gemfile.lock (retrieved from a working Heroku repo) calls for
bootstrap-0.0.1, but I can't find it anywhere. I can't find any discussion
on the web about this issue. How do I get a copy of it?
--
You received this messa
ind it amusing that you are talking both about the
trouble you are having understanding it, and also how you think it is cool
and will be using it in your project. Too bad for the client, I
suppose...maybe they like sprinkles in their coffee too.
Jim
--
You received this message becaus
s Mac OS X. A bit of googling has always helped me
fix or work around any issues I might have had. Having the same Ruby
environment in production as development is very helpful.
Also, I would guess the email is being sent from a rake task? Any
particular reason to use a launch daemon instead
+1 for Pundit. I prefer it over CanCan these days, especially for your
use-case.
Jim
On Thursday, January 8, 2015 at 3:02:47 PM UTC-5, Ruby-Forum.com User wrote:
>
> I have two user models one for businesses and one for buyers. How would
> I be able to restrict the create method
Hi guys,
I am Jim, a Rails developer from the Philippines. I worked as a remote
developer
for an Australia-based company for 4 years.
I've started using Rails around May of 2008 so I have extensive knowledge
of old
Rails versions.
I would like to try out being a full time freelancer s
ck may still
not clear. Just like with checks, it takes a couple days for the checks to
clear (or not), so you have to have business processes in place to
reconcile against Authorize.net and not consider a payment actually paid
until Authorize.net has cleared the check and put the money in you
nothing to do with Rails of any version. Besides that,
rmagick is compatible with Rails 4.
The current repository is at https://github.com/gemhome/rmagick and all
tickets should be placed there.
Jim
--
You received this message because you are subscribed to the Google Groups "Ruby
o
Hi Gavin, you'll need to provide your email if you wish people to reply to
you :)
On Fri, Nov 7, 2014 at 5:01 PM, Gavin Marriott wrote:
> Are you a skilled Ruby on Rails Developer? Then our client would love to
> hear from you.
> My client is a global Pre-IPO company with four offices worldwide
I think I've tried the gem before but have since switched to the
chooser solution since it was a lot easier to implement. In your
case, since you want to save to the user's dropbox folder, just
use the saver solution https://www.dropbox.com/developers/dropins/saver
On Sun, Nov 2, 2014 at 7:07 AM,
you can also run a task that archives past dates to a duplicate table since
you'll
rarely need them. maybe you can keep 1 month data in the table that you're
writing to. this way, you won't have to worry about the exponential growth
of
the table you're always accessing.
On Sun, Oct 12, 2014 at 7:
Interestingly, at just 1K votes per second sustained for 10 hours, you
could record a vote for the entire population of California! At 2K/sec for
12 hours, you could record votes for every single person in California,
Texas, New York, and Florida!
As for the question at hand, depending on how
assenger and Apache, so the stack
you're familiar with should work just fine.
Jim
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to rubyonr
t in question, the object will not be updated until you reload it.
Jim
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to rubyonrails-talk+u
nguage, using any framework.
To be honest, I have written code that requires a reload where certain
functionality is invoked. I have a callback on deleting a related many
that modifies a value in the parent. However, that code really should be
refactored such that the children are not destroye
I can remember
(at least since rails 2.0.x).
Scenarios where you would actually need to re-query the database *every
time you access a relation* are rare. If you really need to, you have that
option, but in no way should that be a default.
Jim
On Monday, August 18, 2014 12:29:06 AM UT
To work in development mode, Apache isn't needed. Just run the Rails server:
$ rails s
Then your browser finds it:
http://192.168.1.51:3000/blog
Sent from my iPhone
> On Aug 4, 2014, at 6:22 PM, McHenry wrote:
>
> OK, I am lost...
>
> I have installed both Ruby & Rails.
>
> $ ruby -v
> ru
On Wed, Jul 23, 2014 at 10:59 AM, Michael Solovyov
wrote:
> Hi everyone,
>
>
>
> My name is Michael Solovyov and I'm the co-founder & CTO of a
> rails-based start-up. We have built a product for other businesses to help
> their users adopt their products.
>
>
>
> We've built the application, d
On Wed, Jul 16, 2014 at 1:13 AM, Carlo Giustinoni <
carlo.giustin...@gmail.com> wrote:
> this is the worst installation package I have ever encountered, I
> installed using www.railsinstaller.org, I installed the VS2010 shell,
> when I try to generate script for anew project I get this error
>
> S
, but
apparently Passenger has issues if the "nobody" user owns the app.
Jim
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to rubyon
Brew, then you do not want to list
passenger as a requirement in your rails app Gemfile. Personally, I only
list app-specific gems in the Gemfile, and leave out the server-specific
details like Passenger.
Jim
--
You received this message because you are subscribed to the Google Groups "Rub
le" directive to have an incorrect path. When I do that,
apache silently fails to start (i.e. nothing in the access or error logs).
Jim Crate
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To unsubscribe from this grou
On Saturday, June 28, 2014 9:54:15 AM UTC-4, Scott Ribe wrote:
> On Jun 28, 2014, at 7:20 AM, Jim > wrote:
>
> > In fact, the reason I started using the built-in apache was because I
> got tired of MacPorts blowing away all my config files seemingly at random.
>
> Ug
because I got
tired of MacPorts blowing away all my config files seemingly at random.
Jim
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to rubyonr
via rbenv,
it will be just fine installed with the system ruby. However, you will
need the PassengerRuby directive so it knows where to find the ruby and gem
set to use when it instantiates your project.
Jim
--
You received this message because you are subscribed to the Google Groups "Ruby
on R
> and couldn't display http://localhost/most/rannumgenerator/index
> (rannumgenerator is controller I generated in most project).
>
> Wonder if something that I should do for Mac Mavericks or some setting for
> Apache that I am not aware?
>
You may need to look in your error log (probably
+1 I think it's not important news if Rails is gay or not
On Wed, May 28, 2014 at 11:16 AM, Ken D'Ambrosio wrote:
> Hi, all. I'm not a frequent contributor -- I'm just ramping up on Rails.
> But I've been on the 'Net for quite some time. And back in the days of
> yore, on Usenet, we had mode
Hi Mateusz,
I want to contribute to this project. Can you pelase email me at
juloo...@aol.com
Thanks
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To unsubscribe from this group and stop rec
I just tried this, again no luck :(
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to rubyonrails-talk+u
I am following the Gmaps4Rails tutorial and trying to implement it in a
bootstrap framework, but am having problems. The map won't load
correctly... See here: http://i.imgur.com/qMiczCe.png. Zooming in
function does not work.
I tried the workaround but it has only helped marginally. This appears
t
their selection from
the first select. It's not ideal, but it's a reasonable fallback.
Jim
On Tuesday, March 4, 2014 4:28:04 AM UTC-5, Ruby-Forum.com User wrote:
>
> Hello,
>
> I am trying load a drop down list based on selection from first
> drop
> down list.
On Wed, Mar 5, 2014 at 9:32 PM, Walter Lee Davis wrote:
>
> On Mar 5, 2014, at 6:40 AM, Frederick Cheung wrote:
>
> >
> >
> > On Wednesday, March 5, 2014 7:02:34 AM UTC, Walter Lee Davis wrote:
> > I need to use the model name 'Action' (which will not work in Rails
> 4.0.3) for business reasons (
I was very resistant to it at first, as well. As it turns out, it was
really for no good reason at all. After diving in and forcing myself to
use it on a project, comparing that project's CS to an older project's JS
sold me on using it forever. It's simply easier to read, more concise, and
t
You can also check out Pundit (https://github.com/elabs/pundit).
Jim
On Monday, March 3, 2014 10:24:21 AM UTC-5, Rita Ferreira wrote:
>
> Hi,
> I'd like to have your opinion/help in the following situation:
>
> I want to install a Gem to Access Control according to user roles
w APIs ahead of
MacOS, so it is often nice when they are ported to the MacOS frameworks as
well. Now that OS releases are on yearly schedules for both platforms
there is much more parity between the frameworks.
Jim
--
You received this message because you are subscribed to the Google Groups &
It looks like this may help http://stackoverflow.com/a/14118913
Jim
On Sunday, February 23, 2014 5:38:04 AM UTC-5, Askhat Bolatkhan wrote:
>
> Showing *D:/RailsInstaller/blog/app/views/layouts/application.html.erb* where
> line *#6* raised:
>
>
> module.js:3
On Thursday, January 30, 2014 4:13:58 PM UTC-5, Russ S wrote:
> So, we are searching for creative solutions to the upgrade problem. One
> idea is to start rewriting the application in Rails 4 and run it alongside
> the Rails 1 application. As features are added to the Rails 4 version, the
> sam
or may not help, since you don't know if they're still doing
whatever caused them to use so much memory by the time you find them.
Couldn't hurt to try, though.
http://pivotallabs.com/inspect-running-ruby-processes-using-xray-and-kill-3/
Jim Crate
--
You received this message
I have a scenario where I created a few has_many :through associations
which I am having trouble updating. I do appreciate any help! Thank you!
Here is my setup:
ruby 1.9.3p392
Rails 3.2.13
Here is the scenario:
I have 3 models that are related
There are many Industries, many
I got a NoMethodError when i called <%= @post.admin_user.name %>, don't
know how to fix it.
Extracted source (around line #4):
<%= @post.title %>
<%= @post.body %>
Post created at <%= @post.created_at.strftime('%b %d. %Y')
%>
<%= @post.admin_user.name %>
Category: <%= lin
On Fri, Jun 28, 2013 at 12:11 AM, Bryan Migliorisi wrote:
> Our application is a very large (read: "enterprise") Single Page
> Application.
>
> Even though our app is 99% client side with a Java RESTful API, we built
> the web application on top of rails because the Asset Pipeline seemed like
> a
On Thu, Jun 20, 2013 at 10:30 AM, Patrick Curl wrote:
> # Need a little push in the right direction.
> @prices = [
> "amazon_new" => [
> "image" => "imageurl.com",
> "url" => "bookurl.com",
> "price" => 45.55
> ],
>
> "amazon_used" => [
>
I haven't seen the paperclip code but I think you can look at the
preprocessors used by default by paperclip.
You usually see logs when paperclip does some processing using rmagick
which may be a clue as to what
part of the lib you want to look at.
On Wed, Jun 12, 2013 at 11:15 PM, Walter Lee Dav
i think you can also use app for the url_helpers
app.posts_path for example
On Thu, May 30, 2013 at 2:21 PM, Frederick Cheung <
frederick.che...@gmail.com> wrote:
>
>
> On Wednesday, May 29, 2013 10:25:59 PM UTC+1, Ruby-Forum.com User wrote:
>>
>> With
>> > rails console --sandbox
>> I cant tes
p h.values_at[*ar]
should be
p h.values_at(*ar)
On Wed, May 1, 2013 at 12:50 PM, Love U Ruby wrote:
> While the below code working :-
>
>
> m = {:a => 2, :b => 3,:c => 44,:g => 14}
> a = [:a,:b,:g]
> p m.values_at(*[:a,:b,:g]) #=> [2, 3, 14]
>
> why the below not working?
>
> h = {
> 'arg0'
d::Base
scope :teachers, where(:person_type => 'Teacher')
scope :students, where(:person_type => 'Student')
end
Then, you could get members, teachers, and students for teams like this:
team.members
team.members.teachers
team.members.students
Jim
>
>
--
You received
0guide%20Apache.html#_resource_control_and_optimization_options
Also, you can check the status and memory usage of your Passenger/Rails
processes using the commands documented here:
http://www.modrails.com/documentation/Users%20guide%20Apache.html#_analysis_and_system_maintenance
Jim
--
You received this message because you a
would be:
SubCategory.where("LOWER(name) like LOWER(?)", "#{params[:q]}%")
Or, according to a bit of googling, this would automatically do a case
insensitive query correctly for the current database:
subcats=Subcategory.arel_table
Subcategory.where(subcats[:name].matches("%#{params[:
I would do just like I've done for automated tasks in several other Rails
apps I've written: make a rake task for it which can be triggered via cron
job. The rake task can simply trigger a model method to do whatever needs
done. This keeps all code relevant to the app in the application (and m
On Thursday, February 14, 2013 5:31:38 PM UTC-5, Nick Apperley wrote:
>
> Managed to access the website by adding *Listen 1025* to the Apache
> config file, and adding an entry to the hosts file. Have used a different
> port for the website (in its VirtualHost entry). Port 80 is already taken
>
On Thu, Jan 31, 2013 at 9:52 PM, Fabian Peter wrote:
> Hello,
>
> I'm trying to join 2 tables with ruby on rails 3.2.
>
> rails generate model product name:string
> rails generate model price product_id:integer price:integer
> date:datetime
>
> product.rb:
> class Product < ActiveRecord::Base
>
Hey guys,
If you have time to read something today, please visit the latest entry on
NetEngine's blog.
http://netengine.com.au/blog/learning-while-conducting-the-triggerapp-upgrade/
This will grant me a case of beer if I gain at least 60 views today. hehe
Thanks!
--
---
use
validates_associated and use a before_validation callback
>
> Le mercredi 30 janvier 2013 15:27:43 UTC+1, jim a écrit :
>>
>>
>> On Wed, Jan 30, 2013 at 6:48 PM, oto iashvili wrote:
>>
>>> I want to do
>>> @ad = Ad.attributes(params[:ad])
>>
On Wed, Jan 30, 2013 at 5:34 PM, Abdullah Esmail
wrote:
> Hello.
> I have come across a scenario where I need to save multiple records for
> multiple users on the same page.
>
> User has_many :shifts
> Shift belongs_to :user
>
> I need to show multiple shifts for each user on the same page and the
a getter and
setter method for each kind of details that you want.
If you don't want to do that, create an attr_accessor for the details, and
create the detail record in a callback.
>
>
> Le mardi 29 janvier 2013 13:39:18 UTC+1, jim a écrit :
>>
>>
>>
>>
>
ing association records. Try to look
into virtual attributes
and callbacks.
>
>
> Le lundi 28 janvier 2013 01:10:30 UTC+1, jim a écrit :
>>
>>
>>
>>
>> On Mon, Jan 28, 2013 at 6:27 AM, oto iashvili wrote:
>>
>>> hi,
>>>
>>>
On Mon, Jan 28, 2013 at 6:27 AM, oto iashvili
wrote:
> hi,
>
> i' trying to re-create my project from php to rails. But now Im faced with
> a pb to witch I had solution with php, but I cant figure how to make it
> work with rails
>
> here my tables
>
> ads
> id
> category_id
> title
> text
On Sat, Jan 26, 2013 at 8:58 PM, Linus Pettersson <
linus.petters...@gmail.com> wrote:
> Hi!
>
> I have a model which has a field that can have three values only. I store
> the value in the database as an integer, 0, 1 or 2, but when I display it I
> want a more appropriate text. And, I want it to
a concat of the values instead of simple
addition. try hours.map { |h| h.hour.to_f }.sum
>
> How to? Do I also have to group otherwise..?
> Thanks for support.
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
On Fri, Jan 25, 2013 at 3:47 PM, suchi gupta wrote:
> <%render :partial =>'new_campaign_partial'%>
>
>
> <%= link_to_function "Add a campaign" do |page|
> inser_html :bottom, :new_campaign, :partial=>'new_campaign_partial'
>end%>
>
If I remember correctly, link_to_function does not
On Thu, Jan 24, 2013 at 10:49 PM, BalaRaju Vankala
wrote:
> Thank you @Werner its Working.
>
>
> On Thu, Jan 24, 2013 at 7:59 PM, Werner
> wrote:
>
>> something like that:
>>
>> *<% 1.upto(2) do |i| %>
>> <%= text_field_tag "fields[#{i}][user_name]",'', :class => "user_name" %>
>> <%= radio_butto
On Thu, Jan 24, 2013 at 10:38 PM, Werner wrote:
> Jim..sorry.. not my day...
> have to contemplate about your solution.
>
> I wonder..
>
> HourUser.includes(:user).where.group_by { |h| h.week_id }
>
> <% @hours.keys.sort.each do |h| %>
> <%= @hour
On Thu, Jan 24, 2013 at 7:55 PM, Werner wrote:
> Hi Jim.. thanks so far..
>
> in the moment this is a bit too far for me.
>
>
> Just remember that to get a certain value, you'll have to pass an array as
> the index
> ie sums[[33,2]] to get 70
> => this is uncle
1 - 100 of 652 matches
Mail list logo