From ff558388ec75b0318eb3b31d5cf96f28408d138e Mon Sep 17 00:00:00 2001 From: jasquat <2487833+jasquat@users.noreply.github.com> Date: Wed, 27 Sep 2023 12:00:09 -0400 Subject: [PATCH] updated files table on pm show page to force single line and added migration to increase column size of process-model identifier in message triggerable table w/ burnettk (#515) Co-authored-by: jasquat --- .../migrations/versions/698a921acb46_.py | 37 +++++++++++++++++++ .../message_triggerable_process_model.py | 2 +- spiffworkflow-frontend/src/index.css | 11 ++++++ .../src/routes/ProcessModelShow.tsx | 14 +++++-- 4 files changed, 60 insertions(+), 4 deletions(-) create mode 100644 spiffworkflow-backend/migrations/versions/698a921acb46_.py diff --git a/spiffworkflow-backend/migrations/versions/698a921acb46_.py b/spiffworkflow-backend/migrations/versions/698a921acb46_.py new file mode 100644 index 000000000..a48978faa --- /dev/null +++ b/spiffworkflow-backend/migrations/versions/698a921acb46_.py @@ -0,0 +1,37 @@ +"""empty message + +Revision ID: 698a921acb46 +Revises: 4d438975ff4d +Create Date: 2023-09-27 11:15:33.302047 + +""" +from alembic import op +import sqlalchemy as sa + +# revision identifiers, used by Alembic. +revision = '698a921acb46' +down_revision = '4d438975ff4d' +branch_labels = None +depends_on = None + + +def upgrade(): + # ### commands auto generated by Alembic - please adjust! ### + with op.batch_alter_table('message_triggerable_process_model', schema=None) as batch_op: + batch_op.alter_column('process_model_identifier', + existing_type=sa.String(length=50), + type_=sa.String(length=255), + existing_nullable=False) + + # ### end Alembic commands ### + + +def downgrade(): + # ### commands auto generated by Alembic - please adjust! ### + with op.batch_alter_table('message_triggerable_process_model', schema=None) as batch_op: + batch_op.alter_column('process_model_identifier', + existing_type=sa.String(length=255), + type_=sa.String(length=50), + existing_nullable=False) + + # ### end Alembic commands ### diff --git a/spiffworkflow-backend/src/spiffworkflow_backend/models/message_triggerable_process_model.py b/spiffworkflow-backend/src/spiffworkflow_backend/models/message_triggerable_process_model.py index f7f1a100a..5f12c3ab7 100644 --- a/spiffworkflow-backend/src/spiffworkflow_backend/models/message_triggerable_process_model.py +++ b/spiffworkflow-backend/src/spiffworkflow_backend/models/message_triggerable_process_model.py @@ -7,6 +7,6 @@ class MessageTriggerableProcessModel(SpiffworkflowBaseDBModel): id = db.Column(db.Integer, primary_key=True) message_name: str = db.Column(db.String(255), index=True) - process_model_identifier: str = db.Column(db.String(50), nullable=False, index=True) + process_model_identifier: str = db.Column(db.String(255), nullable=False, index=True) updated_at_in_seconds: int = db.Column(db.Integer) created_at_in_seconds: int = db.Column(db.Integer) diff --git a/spiffworkflow-frontend/src/index.css b/spiffworkflow-frontend/src/index.css index 6ceb6d7d1..d45ae0570 100644 --- a/spiffworkflow-frontend/src/index.css +++ b/spiffworkflow-frontend/src/index.css @@ -856,3 +856,14 @@ div.onboarding { .completed-task-modal .cds--form__helper-text--disabled { --cds-text-disabled: rgba(22, 22, 22, .5); } + +.process-model-file-table { + width: 100%; + table-layout: fixed; + overflow: hidden; + white-space: nowrap; +} +.process-model-file-table-filename { + overflow: hidden; + text-overflow: ellipsis; +} diff --git a/spiffworkflow-frontend/src/routes/ProcessModelShow.tsx b/spiffworkflow-frontend/src/routes/ProcessModelShow.tsx index 742539934..bb89c2512 100644 --- a/spiffworkflow-frontend/src/routes/ProcessModelShow.tsx +++ b/spiffworkflow-frontend/src/routes/ProcessModelShow.tsx @@ -383,7 +383,11 @@ export default function ProcessModelShow() { } constructedTag = ( - + {fileLink} {primarySuffix} @@ -394,7 +398,11 @@ export default function ProcessModelShow() { }); return ( - +
@@ -648,7 +656,7 @@ export default function ProcessModelShow() { {readmeFileArea()} - +