Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Submitting FarMar Rails for Emily & Sarah #19

Open
wants to merge 59 commits into
base: ergsat/master
Choose a base branch
from
Open
Changes from 1 commit
Commits
Show all changes
59 commits
Select commit Hold shift + click to select a range
8b626ea
created import_stuff.rb file to translate CSV file into SQL-readable …
trowbrsa Nov 18, 2015
4f7b992
deleted secret message
emgord Nov 18, 2015
b7a89dd
Merge branch 'ergsat/master' of github.com:emgord/FarMarRails into er…
emgord Nov 18, 2015
1bfb960
created models for market, vendor, product and sales, migrated db
emgord Nov 18, 2015
60dfccf
Seeded database with Market csv information
trowbrsa Nov 18, 2015
4d2d085
Seeded database with all CSV files
trowbrsa Nov 18, 2015
233134f
Created all controllers
trowbrsa Nov 18, 2015
a49f60c
Created index views for Market and Vendor
trowbrsa Nov 18, 2015
c1f535b
added view for home page, and partial to make a list of links
emgord Nov 18, 2015
4553315
tried to make some changes to the linklist partial, but ended up stic…
emgord Nov 18, 2015
031efa1
Created partial for Market > Vendor Show method
trowbrsa Nov 18, 2015
c1189d7
Added html styling for Market's detail page
trowbrsa Nov 18, 2015
391cf77
added edit and delete for markets
emgord Nov 18, 2015
725796c
Created a show page for Vendors and defined the show method
trowbrsa Nov 18, 2015
4a0b7bc
added edit function for markets
emgord Nov 19, 2015
0c18cb2
added update method for markets
emgord Nov 19, 2015
9f4e218
Half-completed product edit and create method
trowbrsa Nov 19, 2015
d1a5451
Merge branch 'ergsat/master' of github.com:emgord/FarMarRails into er…
trowbrsa Nov 19, 2015
4846775
experimented with nesting routes
emgord Nov 19, 2015
ea5b9f3
Created an edit method for updating vendor products
trowbrsa Nov 19, 2015
ad9fb54
Completed update method for Vendor Products
trowbrsa Nov 19, 2015
e77f334
began working on destroy method
emgord Nov 19, 2015
71d7134
Merge branch 'ergsat/master' of github.com:emgord/FarMarRails into er…
emgord Nov 19, 2015
13c6750
Made adjustments to create method for products but still not fully fu…
trowbrsa Nov 19, 2015
e6d1fff
working on create method for markets
emgord Nov 19, 2015
ca6a658
Merge branch 'ergsat/master' of github.com:emgord/FarMarRails into er…
emgord Nov 19, 2015
44c0e63
Added hidden form to New page to capture params
trowbrsa Nov 19, 2015
fde31bb
Merge branch 'ergsat/master' of github.com:emgord/FarMarRails into er…
trowbrsa Nov 19, 2015
4c8c3e8
added destroy method for products
emgord Nov 19, 2015
2e5351d
finished create method for markets
emgord Nov 19, 2015
e29bbeb
began adding css
emgord Nov 19, 2015
63dcc78
Added 'edit' method for vendors
trowbrsa Nov 19, 2015
d51531c
Added delete method for market vendors
trowbrsa Nov 20, 2015
96c6457
Added create method for vendors on market page
trowbrsa Nov 20, 2015
5f77202
CSS styling
emgord Nov 20, 2015
d7e4649
Merge branch 'ergsat/master' of github.com:emgord/FarMarRails into er…
emgord Nov 20, 2015
0f49816
Incomplete 'new' view for new vendor
trowbrsa Nov 20, 2015
3920686
added css for forms
emgord Nov 20, 2015
410d687
Added ability to add a new vendor as a market
trowbrsa Nov 20, 2015
e81cf40
added styling market detail page
emgord Nov 20, 2015
05236ad
Merge branch 'ergsat/master' of github.com:emgord/FarMarRails into er…
emgord Nov 20, 2015
a9c343d
Created a new view page for general users to view markets
trowbrsa Nov 20, 2015
95ad978
added function to add new sale to a product
emgord Nov 20, 2015
670b146
Added a method to show total sales for a vendor
trowbrsa Nov 20, 2015
4e5abfc
Added method for calculating total sales for current month
trowbrsa Nov 20, 2015
552b56f
Added headers to edit page
trowbrsa Nov 20, 2015
4a19379
added partial for show sales for vendors
emgord Nov 20, 2015
11f5bfd
Added css styling for nav bar
trowbrsa Nov 20, 2015
8c9cb82
Additional css styling
trowbrsa Nov 20, 2015
0598b3c
Merge branch 'ergsat/master' of github.com:emgord/FarMarRails into er…
trowbrsa Nov 20, 2015
672a2bb
styling for vendor page
emgord Nov 20, 2015
2e2cd95
Added nav bar to market pages
trowbrsa Nov 20, 2015
43abbc1
Merge branch 'ergsat/master' of github.com:emgord/FarMarRails into er…
emgord Nov 20, 2015
20e5f57
Added nav link to product page
trowbrsa Nov 20, 2015
3cbb302
Finished nav bars for all pages
trowbrsa Nov 20, 2015
0148e71
Moved SQL to development and added pg gem to production
trowbrsa Nov 20, 2015
b920794
Did a bundle install for gems
trowbrsa Nov 20, 2015
8deb24f
Upgrade spring gem and binstubs
trowbrsa Nov 21, 2015
2c3a31c
fixed some of the nav bars and added some that were missing
emgord Nov 22, 2015
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
added update method for markets
emgord committed Nov 19, 2015
commit 0c18cb2d71c81c4e56c3ad7c319bfbe194f3c7c5
12 changes: 12 additions & 0 deletions app/controllers/markets_controller.rb
Original file line number Diff line number Diff line change
@@ -21,4 +21,16 @@ def edit
@title = "Edit Market"
@action = :update
end

def update
Market.update(params[:id], market_params[:market] )
redirect_to market_path(params[:id])
end

private

def market_params
params.permit(market:[:name, :address, :city, :county, :state, :zip])
end

end