set the returned file as the new file when saving a process model file so we get the new contents hash w/ burnettk
This commit is contained in:
parent
20ee46899d
commit
998de63eca
|
@ -530,6 +530,8 @@ def _create_or_update_process_model_file(
|
|||
file_contents = SpecFileService.get_data(process_model, file.name)
|
||||
file.file_contents = file_contents
|
||||
file.process_model_id = process_model.id
|
||||
file_contents_hash = sha256(file_contents).hexdigest()
|
||||
file.file_contents_hash = file_contents_hash
|
||||
_commit_and_push_to_git(f"{message_for_git_commit} {process_model_identifier}/{file.name}")
|
||||
|
||||
return make_response(jsonify(file), http_status_to_return)
|
||||
|
|
|
@ -206,8 +206,11 @@ export default function ProcessModelEditDiagram() {
|
|||
setProcessModelFileInvalidText('');
|
||||
};
|
||||
|
||||
const navigateToProcessModelFile = (_result: any) => {
|
||||
const navigateToProcessModelFile = (file: ProcessFile) => {
|
||||
setDisplaySaveFileMessage(true);
|
||||
if (file.file_contents_hash) {
|
||||
setProcessModelFile(file);
|
||||
}
|
||||
if (!params.file_name) {
|
||||
const fileNameWithExtension = `${newFileName}.${searchParams.get(
|
||||
'file_type'
|
||||
|
|
Loading…
Reference in New Issue