gpranav88-zz / clothzy-MVP

Clothzy MVP
0 stars 0 forks source link

Front page search functionality #3

Closed agamdua closed 10 years ago

agamdua commented 10 years ago

Branch name: 'search'

agamdua commented 10 years ago

Initially proposed route (for record sake):

Proposed route:

initialSearch: function($resource) {
                return $resource('/api/search/:keywords')
                    keywords: '@keywords'
            }

Where

:keywords

will be the search query separated by dashes.

agamdua commented 10 years ago

Recommended on IRC to use $httpbackend as a mock and write some dummy filters to prototype Angular functionality without necessarily communicating with a backend.

The Angular docs on filters have an example featuring search functionality.

Also, description of Angular filters from docs:

Selects a subset of items from array and returns it as a new array.

agamdua commented 10 years ago

@gpranav88 - can you have a look at the search controller (line 166, clothzy.js, branch: search).

It's obviously WIP, need to brainstorm a little when I come in.