mirror of
https://github.com/sartography/cr-connect-workflow.git
synced 2025-02-23 21:28:32 +00:00
Merge branch 'feature/spec_files_wthout_db' of https://github.com/sartography/cr-connect-workflow into feature/spec_files_wthout_db
This commit is contained in:
commit
881ee78e68
@ -77,7 +77,8 @@ class LookupService(object):
|
|||||||
if lookup_model.is_ldap: # LDAP is always current
|
if lookup_model.is_ldap: # LDAP is always current
|
||||||
is_current = True
|
is_current = True
|
||||||
else:
|
else:
|
||||||
current_date = SpecFileService.last_modified(workflow.workflow_spec, lookup_model.file_name)
|
workflow_spec = WorkflowSpecService().get_spec(workflow.workflow_spec_id)
|
||||||
|
current_date = SpecFileService.last_modified(workflow_spec, lookup_model.file_name)
|
||||||
is_current = current_date == lookup_model.last_updated
|
is_current = current_date == lookup_model.last_updated
|
||||||
|
|
||||||
if not is_current:
|
if not is_current:
|
||||||
|
@ -49,8 +49,7 @@ class TestLookupService(BaseTest):
|
|||||||
file_path = os.path.join(app.root_path, '..', 'tests', 'data',
|
file_path = os.path.join(app.root_path, '..', 'tests', 'data',
|
||||||
'enum_options_with_search', 'sponsors_modified.xlsx')
|
'enum_options_with_search', 'sponsors_modified.xlsx')
|
||||||
file = open(file_path, 'rb')
|
file = open(file_path, 'rb')
|
||||||
workflow_spec_model = session.query(WorkflowSpecModel)\
|
workflow_spec_model = self.workflow_spec_service.get_spec(workflow.workflow_spec_id)
|
||||||
.filter(WorkflowSpecModel.id == workflow.workflow_spec_id).first()
|
|
||||||
SpecFileService().update_file(workflow_spec_model, "sponsors.xlsx", file.read())
|
SpecFileService().update_file(workflow_spec_model, "sponsors.xlsx", file.read())
|
||||||
file.close()
|
file.close()
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user