'Custom lookup method for Area(CAP) rows.Parameters
key and fields are not used, but are kept for API
compatibility reasons.
@param values: the cap_area IDs'

def lookup_rows(self, key, values, fields=None):

    db = current.db
    s3db = current.s3db
    artable = s3db.cap_area
    count = len(values)
    if (count == 1):
        query = (artable.id == values[0])
    else:
        query = artable.id.belongs(values)
    fields = [artable.id, artable.name]
    if self.translate:
        ltable = s3db.cap_area_name
        fields += [ltable.name_l10n]
        left = [ltable.on(((ltable.area_id == artable.id) & (ltable.language == current.session.s3.language)))]
    else:
        left = None
    rows = current.db(query).select(left=left, limitby=(0, count), *fields)
    return rows
