gpranav88-zz / clothzy-MVP

Clothzy MVP
0 stars 0 forks source link

Filter products according to user selection #1

Open agamdua opened 10 years ago

agamdua commented 10 years ago

The following filters should work when a user is browsing through merchandise:

To be updated.

agamdua commented 10 years ago

Possibly drop down to jQuery for the time being? Since the following method is stock jQuery rather than a plugin, it should work alright.

 $('input[type=checkbox]').each(function () {
       var sThisVal = (this.checked ? $(this).val() : "");
  });

Source: http://stackoverflow.com/questions/5450104/using-jquery-getting-all-checked-checkboxes-with-a-certain-class-name

agamdua commented 10 years ago

@kartikdhar, have a look I'll talk to you 5.30-6

kartikdhar commented 10 years ago

if it works, great...let's chat when you come to office then

Kartik A. Dhar kartik.dhar@gmail.com

On 5 February 2014 14:59, Agam Dua notifications@github.com wrote:

@kartikdhar https://github.com/kartikdhar, have a look I'll talk to you 5.30-6

Reply to this email directly or view it on GitHubhttps://github.com/agamdua/clothzy/issues/1#issuecomment-34149827 .

agamdua commented 10 years ago

Ugh, problem was not population of checkboxes, problem was in watching the $scope. That problem remains.

However, this gives me an idea - if in jQuery, one can monitor checkboxes across class using the CSS selector, one can probably make an onClick or ng-click() on the whole CSS class that triggers the above jQuery function that collects the data bout checkboxes. Will come back to this.

agamdua commented 10 years ago

https://gist.github.com/agamdua/5deae704d4a03575dd17

URI change is working, known issues documented in this commit message

@gpranav88 - have a look