Medical Billing Software Company
- Tim has worked in data integration and spends time using Microsoft applications such as Microsoft Excel.
Apple Genius
| /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require': /Library/Ruby/Gems/2.0.0/gems/learn-co-3.2.18/lib/learn/options_sanitizer.rb:123: syntax error, unexpected ',' (SyntaxError) | |
| def rebuild_args!(flag_arg:, add_test_command:) | |
| ^ | |
| /Library/Ruby/Gems/2.0.0/gems/learn-co-3.2.18/lib/learn/options_sanitizer.rb:221: syntax error, unexpected keyword_end, expecting end-of-input | |
| from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require' | |
| from /Library/Ruby/Gems/2.0.0/gems/learn-co-3.2.18/lib/learn.rb:7:in `<top (required)>' | |
| from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require' | |
| from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/rubygems/core_ext/kernel_require.rb:55:in `require' | |
| from /Library/Ruby/Gems/2.0.0/gems/learn-co-3.2.18/bin/le |
| <h1>Add Activity</h1> | |
| <%= form_for @activity do |f| %> | |
| <%= f.label :name, "Activity Name" %></br> | |
| <%= f.text_field :name %></br> | |
| <%= f.label :address_one, "Address 1" %></br> | |
| <%= f.text_field :address_one %></br> | |
| <%= f.label :address_two, "Address 2" %></br> | |
| <%= f.text_field :address_two %></br> | |
| <%= f.label :city, "City" %></br> |
| def create | |
| @activity = Activity.new(activity_params) | |
| categories = [] | |
| params[:activity][:category_ids].each do |id| | |
| categories << Category.find(id) | |
| end | |
| @activity.categories << categories |
| class User < MiniRecord::Model | |
| self.attribute_names = [:id, :first_name, :last_name, :email, :birth_date, :created_at, :updated_at] | |
| def self.all | |
| MiniRecord::Database.execute('SELECT * FROM users').map do |row| | |
| User.new(row) | |
| end | |
| end |
| module MiniRecord | |
| class Database | |
| def self.connection | |
| fail NoConnectionError, "Call MiniRecord::Database.database= to set database." unless connected? | |
| @connection | |
| end | |
| def self.connected? |
| require 'data_mapper' | |
| require 'bcrypt' | |
| if ENV['RACK_ENV'] != 'production' | |
| require 'dotenv' | |
| Dotenv.load('.env') | |
| end | |
| DataMapper.setup(:default, ENV['DATABASE_URL']) |
| class Group | |
| include DataMapper::Resource | |
| property :id, Serial | |
| property :group_name, String, { :required => true, | |
| :unique => true, | |
| :messages => { :is_unique => "League name is taken. Please choose another." } | |
| } | |
| property :password, BCryptHash, :required => true | |
| validates_confirmation_of :password |
| require 'sinatra' | |
| require_relative 'models' | |
| enable :sessions | |
| ## HELPER/METHODS | |
| ## ================================== | |
| helpers do |
| # setup.rb makes sure we're setting up our environment correctly, i.e., | |
| # requiring the necessary gems, connecting to the correct database, etc. | |
| require './setup' | |
| # database.rb is where we're defining our DataMapper models | |
| require './database' | |
| # DATA SCHEME | |
| # user [name, location, join date, retweets, followers_count] |