def get_user_path_storage(user, cnpj, prod): conn.authenticate_request(request.authorization) models = get_storage_model(user_id=user, cnpj_id=cnpj, prod_id=prod, container=BlobsContainers.paths) return dumps(models, indent=4)
def get_user_recommendations_storage(user, cnpj, prod): conn.authenticate_request(request.authorization) models = get_storage_model(user_id=user, cnpj_id=cnpj, prod_id=prod) return dumps(models, indent=4)
def get_prod_recommendations_storage(prod): conn.authenticate_request(request.authorization) models = get_storage_model(prod_id=prod) return dumps(models, indent=4)
def get_user_path(user, cnpj, prod): conn.authenticate_request(request.authorization) models = get_path_model(user_id=user, cnpj_id=cnpj, prod_id=prod) return dumps(models, indent=4)
def get_prod_path(prod): conn.authenticate_request(request.authorization) models = get_path_model(prod_id=prod) return dumps(models, indent=4)
def get_cnpj_cycles(cnpj, prod): conn.authenticate_request(request.authorization) models = get_cycles_model(cnpj_id=cnpj, prod_id=prod) return dumps(models, indent=4)
def home(): conn.authenticate_request(request.authorization) return 'Welcome to the SIGA project!'
def get_cnpj_cycles_storage(cnpj, prod): conn.authenticate_request(request.authorization) models = get_storage_model(cnpj_id=cnpj, prod_id=prod, container=BlobsContainers.cycles) return dumps(models, indent=4)