Author Archives: David Sulc

Adding a namespaced Rails generator to a standalone Ruby gem

I wanted to add a generator to the SugarCRM ruby gem, but couldn’t find any straightforward resources on doing just that: taking a standalone ruby gem, and adding a generator that is available from within a Rails environment. To make matters … Continue reading

Posted in Rails, Ruby, SugarCRM Ruby gem | 2 Comments

Contributing to open source

Although contributing to open source projects now seems natural to me, there was a time when it was quite daunting and I had no idea where to start. Here, I’ll guide you through the steps I took to add some … Continue reading

Posted in Rails | Comments Off on Contributing to open source

Why Service-Oriented Architecture makes sense

Service-Oriented Architecture (SOA) has been around for a long time, but in the last years it has started to become the obvious solution to many problems: where RPC, and CORBA are unwieldy, and big entreprisey J2EE apps communicating with SOAP … Continue reading

Posted in Architecture | Comments Off on Why Service-Oriented Architecture makes sense

Self-marking required fields in Rails 3

In a Rails 3 project I’m currently working on, I wanted to mark required fields automatically: if the model required the field to be present (via validates :presence => true or validates_presence_of), that field in the form would automatically be … Continue reading

Posted in Rails | 19 Comments

Your laptop is a liability

You got up early this morning to catch your flight, but your taxi still got stuck in traffic. After checking in (thank God for electronic check in!), you’re now stuck at the security check behind someone who evidently decided storing … Continue reading

Posted in Uncategorized | Tagged , , | Comments Off on Your laptop is a liability

Consuming a public Rails API with jQuery

A previous post explained how to implement a public API in Rails. Here, we will cover how this API can be consumed with a cross-domain request using jQuery. The idea We’ll create a simple html file containing <ul> elements with … Continue reading

Posted in AJAX, jQuery | 4 Comments

Implementing a public API in Rails 3

As you’re probably aware, Rails helps out a lot when using generators: in addition to generating the views, it also provides XML access to data. What we’ll cover today is implementing a basic public API that can be consumed from … Continue reading

Posted in Rails | 10 Comments

Ruby Gem for SugarCRM: Advanced use

This is an article about “advanced” use of the SugarCRM Ruby gem. We’ve previously covered using basic gem functionality, and building a simple rails app using the gem to make a CRM portal, so you might want to take a … Continue reading

Posted in CRM, Ruby, SugarCRM Ruby gem | Comments Off on Ruby Gem for SugarCRM: Advanced use

Ruby Gem for SugarCRM: Ruby on Rails Integration

Having gone over the basics in a previous article, we will now cover how you can get a basic Rails 3 app (using the SugarCRM Ruby gem) up and running. (The SugarCRM Ruby gem relies on ActiveSupport >= 3, and … Continue reading

Posted in CRM, Rails, Ruby, SugarCRM Ruby gem | 4 Comments

Ruby Gem for SugarCRM: the Basics

The Ruby gem for SugarCRM has already been briefly presented in a SugarCRM Developer Zone article, but has been drastically improved over the last months. In the following lines, we’ll go over a few of these improvements and show you … Continue reading

Posted in CRM, Ruby, SugarCRM Ruby gem | 7 Comments