'Add a Lx filter for the current location to this
resource.
@param resource: the resource'

@staticmethod
def _add_lx_filter(resource, lx):

    from s3query import FS
    query = (FS('location_id$path').contains(('/%s/' % lx)) | FS('location_id$path').like(('%s/%%' % lx)))
    resource.add_filter(query)
