-
Refactoring - replace jquery updating page with partial view refresh
I have a voting page, where user can vote up and down a restaurant. It triggers an ajax call to update the votes in database. Meanwhile a jquery snippet takes care of updating the vote count on the page. It works alright. But the code is tedious. <tr>…
-
Capybara Database Locked
I've been writing capybara integration tests. It's been going well, until I hit an error. It happens when I want to update a meeting. It uses capybara with chromedriver. The error message shows: $SQLite3::BusyException: database is locked: commit transaction The error happens when these lines…
-
Google Chart Listener Issue
So I've been stuck at this bug for a couple of hours. It's a google chart and I simply just added a listener to display another chart. it's like this: function drawPieChart(data, id, settitle){ var data = google.visualization.arrayToDataTable([ ['Numbers', '…
-
Phusion Passenger Deployment and Config Setting
Well... after spending about a week refactoring all configuration files and stuff, it's time to deploy. Hesitated for a second whether I should do it after hours, but then it's all tested and just a simple svn update. Why bother? Right after I svn update and…
-
form_for and Update Action
I've been stuck at work for this weird error message. I have a form, which structured like: <%=form_for @cnf, :url=>{:action=>"tpg_note"} do |c|%> <%= c.hidden_field 'cust_id'%> <div> <p><…
-
Get Ckeditor Setup
I'm just gonna work through getting ckeditor setup with Rails 3.1 The original setup process is at: here [https://github.com/galetahub/ckeditor/blob/master/README.rdoc]. It looks not too complicated, but it involves getting asset pipeline setup and everything. It could get into issues depending…