Browse Source

Add missing set count

master
venkataakhil 1 year ago
parent
commit
37fa63c8b5
  1. 9
      smart_service/apis/publish_api.py

9
smart_service/apis/publish_api.py

@ -287,7 +287,7 @@ def new_publish(args, publish_type, vehicle, language, version):
""" Save file (Internal/Global) """
with open(file_name, 'w') as outfile:
outfile.write(json.dumps(json_file))
# get_step_total_count(file_name)
get_step_total_count(file_name)
""" Remove previous internal publish file """
if publish_type.lower() == 'internal':
@ -311,9 +311,9 @@ def new_publish(args, publish_type, vehicle, language, version):
if str(version) == '1.00':
with open(full_update_file_name, 'w') as outfile:
outfile.write(json.dumps(json_file))
with open(new_full_update_file_name, 'w') as outfile:
outfile.write(json.dumps(json_file))
# get_step_total_count(full_update_file_name)
# with open(new_full_update_file_name, 'w') as outfile:
# outfile.write(json.dumps(json_file))
get_step_total_count(full_update_file_name)
else:
pub_ver = frappe.db.sql(''' SELECT vehicle,`language`,format(version,2) as version,publish_type FROM tabPublish where vehicle = '{}'
@ -326,6 +326,7 @@ def new_publish(args, publish_type, vehicle, language, version):
file_flag, final_update_file = merge_json_files(
prev_full_update_file, file_name, full_update_file_name)
get_step_total_count(final_update_file)
if file_flag:
return True, file_name.split('public')[1]
else:

Loading…
Cancel
Save