Checked items now work

This address issue #118.  The download and delete actions work as expected.  Internally, there are two new endpoints: resource/download GET and resource DELETE.  The download can actually get item, folder, user, and collection resources, and the delete can work on any model that has a remove method.
I had done this because it made testing easier.  I'll take the time to make
the testing better.

On Tue, Oct 14, 2014 at 9:36 PM, Zach Mullen <notifications@github.com>
wrote:

> In girder/models/item.py:
>
> > +                                result which is the json string of the
> > +                                metadata.  This is given a name of
> > +                                metadata[-(number).json that is distinct from
> > +                                any file within the item.
> > +        :param subpath: if True and the item has more than one file, metadata,
> > +                        or the sole file is not named the same as the item,
> > +                        then the returned paths include the item name.
> > +        """
> > +        if subpath:
> > +            files = [file for file in self.childFiles(item=doc, limit=2)]
> > +            if (len(files) != 1 or files[0]['name'] != doc['name'] or
> > +                    (includeMetadata and len(doc.get('meta', {})))):
> > +                path = os.path.join(path, doc['name'])
> > +        metadataFile = {"format": "metadata#.json"}
> > +        for file in self.childFiles(
> > +                item=doc, limit=0, sort=[('created', pymongo.ASCENDING)],
>
> I'm disinclined to sort by a non-indexed field, can we just remove the
> sort here since the order doesn't matter for the zip format?
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/girder/girder/pull/398/files#r18870926>.
>