1

I want to create a small web app which would display a list of movies, with a Google spreadsheet set as a database. So far, I was able to connect my spreadsheet to my app and I also added some filters to it. (As a side note, this thread really helped me in the process.)

Here is a very simplified version of my app: http://plnkr.co/edit/BtbSCVOh7KJsMHjANxMP?p=preview

I still have 3 problems with my <select>, which I can't fix despite trying for hours:

  • I can't sort my <options> alphabetically. Trying with orderBy didn't return anything.
  • I can't figure out a way to split my categories when there are more than one for a movie.
  • If the "categorie" field in my spreadsheet is empty, it will return a blank <option> which I would like to remove or hide.

My guess is that I'll need to update my function one way or another, but I'm a bit lost at the moment.

Any help on this would be really appreciated!

Community
  • 1
  • 1
Ronan
  • 177
  • 1
  • 12
  • Angular's `orderBy` only supports arrays, not objects. You'll need a custom filter because the title and category data is in an objects. Possible starting point: http://stackoverflow.com/questions/14478106/angularjs-sorting-by-property – thebenedict Nov 19 '13 at 14:16
  • Thanks! I'll see if I can find a way to make this work for my case. – Ronan Nov 20 '13 at 09:02
  • Sorry I came looking for something else.. i found it in your code.. so using it as a base.. thanks for sharing.. saved me some time :) – whizcreed Mar 11 '14 at 11:53

0 Answers0