Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(16)  |  Call(16)  |  Derive(0)  |  Import(0)

src/m/e/mediadrop-HEAD/mediadrop/controllers/admin/media.py   mediadrop(Download)
            elif delete:
                file.storage.delete(file.unique_id)
                DBSession.delete(file)
                DBSession.flush()
                # media.files must be updated to reflect the file deletion above
                file.media = orig
                merged_files.append(file)
            DBSession.delete(input)
 
        # The original is a file or thumb stub, copy in the new values
        elif orig.slug.startswith('_stub_') \
        and not input.slug.startswith('_stub_'):
            DBSession.delete(input)
                # This will raise an OSError on Windows, but not *nix
                os.rename(src_path, dst_path)
            DBSession.delete(input)
 
        # Report an error
            success = False
            if id == 'new':
                DBSession.delete(media)
            if e.errno == 13:
                message = _('Permission denied, cannot write file')

src/m/e/mediadrop-HEAD/mediadrop/controllers/admin/categories.py   mediadrop(Download)
 
        if delete:
            DBSession.delete(cat)
            data = dict(
                success = True,

src/m/e/mediadrop-HEAD/mediadrop/controllers/admin/tags.py   mediadrop(Download)
 
        if delete:
            DBSession.delete(tag)
            data = dict(success=True, id=tag.id)
        else:

src/m/e/mediadrop-HEAD/mediadrop/controllers/admin/podcasts.py   mediadrop(Download)
 
        if delete:
            DBSession.delete(podcast)
            DBSession.commit()
            delete_thumbs(podcast)

src/m/e/mediadrop-HEAD/mediadrop/controllers/admin/users.py   mediadrop(Download)
 
        if delete:
            DBSession.delete(user)
            redirect(action='index', id=None)
 
        """
        user = fetch_row(User, id)
        DBSession.delete(user)
 
        if request.is_xhr:

src/m/e/mediadrop-HEAD/mediadrop/controllers/admin/groups.py   mediadrop(Download)
 
        if delete:
            DBSession.delete(group)
            redirect(action='index', id=None)
 
        """
        group = fetch_row(Group, id)
        DBSession.delete(group)
 
        if request.is_xhr:

src/m/e/mediadrop-HEAD/mediadrop/lib/auth/tests/mediadrop_permission_system_test.py   mediadrop(Download)
    def test_metagroup_assignment_does_not_fail_if_groups_are_not_found_in_db(self):
        DBSession.delete(self.anonymous)
        DBSession.delete(self.authenticated)
        DBSession.flush()