Commit ea346881 authored by Renán Sosa Guillen's avatar Renán Sosa Guillen

L1C product population

parent f92053cd
......@@ -70,6 +70,8 @@ class Command(BaseCommand):
PRODUCT_EXISTS = Product_l1c.objects.filter(identifier=file_name).exists()
if not PRODUCT_EXISTS:
file_path = path + "/" + file
try:
data_dict = self.generate_json(file_name)
# print json.dumps(data_dict, indent=3, sort_keys=True, default=str)
......@@ -77,7 +79,7 @@ class Command(BaseCommand):
product_l1c = Product_l1c(
uuid = data_dict['id'],
identifier = data_dict['Identifier'],
file_path = path,
file_path = file_path,
json = json.dumps(data_dict, indent=3, sort_keys=True, ensure_ascii=True, default=str)
)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment