def clearBBDD(self):
        # Clean Solr
        search_index.clear_index()

        # Clean the database
        model.repo.rebuild_db()

        # Delete previous users
        db.init_db(model)
        users = db.AllowedUser.get()
        for user in users:
            model.Session.delete(user)
        model.Session.commit()
    def clearBBDD(self):
        # Clean Solr
        search_index.clear_index()

        # Clean the database
        model.repo.rebuild_db()

        # Delete previous users
        db.init_db(model)
        users = db.AllowedUser.get()
        for user in users:
            model.Session.delete(user)
        model.Session.commit()
    def clearBBDD(self):
        # Clean Solr
        search_index.clear_index()

        # Clean the database
        model.repo.rebuild_db()

        # Delete previous users
        db.init_db(model)
        datarequests = db.DataRequest.get()
        for datarequest in datarequests:
            model.Session.delete(datarequest)

        comments = db.Comment.get()
        for comment in comments:
            model.Session.delete(comment)

        model.Session.commit()
    def clearBBDD(self):
        # Clean Solr
        search_index.clear_index()

        # Clean the database
        model.repo.rebuild_db()

        # Delete previous users
        db.init_db(model)
        datarequests = db.DataRequest.get()
        for datarequest in datarequests:
            model.Session.delete(datarequest)

        comments = db.Comment.get()
        for comment in comments:
            model.Session.delete(comment)

        model.Session.commit()