Skip to content

Instantly share code, notes, and snippets.

View yaymukund's full-sized avatar
🍅
tomato tomato

mukund yaymukund

🍅
tomato tomato
View GitHub Profile
class Category < ActiveRecord::Base
has_many :subcategories, :dependent => :destroy
has_many :users, :through => :subcategories
end
// Every style that will be repeated more than once should be written as a mixin
btn-states($btnColor) {
background-color: $btnColor;
&:hover {
background-color: darken($btnColor, 15%);
}
&:active {
class BillingController < ApplicationController
def index
@companies = Company.includes(:transactions).merge(Transaction.pending)
end
end