Exemplo n.º 1
0
    def line_validates(line):

        result = validateData.validate_natural(line['id']) and \
                 validateData.validate_natural(line['invoice']) and \
                 validateData.validate_natural(line['item'])
                 
        return result
Exemplo n.º 2
0
    def product_validates(product):

        result = validateData.validate_natural(product['id']) and \
                 validateData.validate_string(product['product']) and\
                 validateData.validate_natural(product['price'])
        return result
Exemplo n.º 3
0
    def client_validates(client):

        result = validateData.validate_natural(client['id']) and \
                 validateData.validate_string(client['name'])
        return result
Exemplo n.º 4
0
    def invoice_validates(invoice):

        result = validateData.validate_natural(invoice['id']) and \
                 validateData.validate_natural(invoice['clientid']) and\
                 validateData.validate_date(invoice['date'])
        return result