Skip to content

Commit

Permalink
[NO_ISSUE] fix constraints names (#3753)
Browse files Browse the repository at this point in the history
* [NO_ISSUE] fix constraints names
  • Loading branch information
pefernan authored Oct 25, 2024
1 parent ce37bdc commit 79b771a
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public class AttachmentEntity {
private Date updatedAt;

@ManyToOne
@JoinColumn(name = "task_id", foreignKey = @ForeignKey(name = "fk_user_task_attachment_tid"))
@JoinColumn(name = "task_id", foreignKey = @ForeignKey(name = "fk_user_tasks_attachments_tid"))
private UserTaskInstanceEntity taskInstance;

public String getId() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public class CommentEntity {
private Date updatedAt;

@ManyToOne(optional = false)
@JoinColumn(name = "task_id", foreignKey = @ForeignKey(name = "fk_user_task_comment_tid"))
@JoinColumn(name = "task_id", foreignKey = @ForeignKey(name = "fk_user_tasks_comments_tid"))
private UserTaskInstanceEntity taskInstance;

public String getId() {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -134,16 +134,16 @@ alter table if exists jbpm_user_tasks_excluded_users
add constraint fk_jbpm_user_tasks_excluded_users_tid foreign key (task_id) references jbpm_user_tasks(id) on delete cascade;

alter table if exists jbpm_user_tasks_attachments
drop constraint if exists fk_user_task_attachment_tid cascade;
drop constraint if exists fk_user_tasks_attachments_tid cascade;

alter table if exists jbpm_user_tasks_attachments
add constraint fk_user_task_attachment_tid foreign key (task_id) references jbpm_user_tasks(id) on delete cascade;
add constraint fk_user_tasks_attachments_tid foreign key (task_id) references jbpm_user_tasks(id) on delete cascade;

alter table if exists jbpm_user_tasks_comments
drop constraint if exists fk_user_task_comment_tid cascade;
drop constraint if exists fk_user_tasks_comments_tid cascade;

alter table if exists jbpm_user_tasks_comments
add constraint fk_user_task_comment_tid foreign key (task_id) references jbpm_user_tasks(id) on delete cascade;
add constraint fk_user_tasks_comments_tid foreign key (task_id) references jbpm_user_tasks(id) on delete cascade;

alter table if exists jbpm_user_tasks_inputs
drop constraint if exists fk_jbpm_user_tasks_inputs_tid cascade;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -134,16 +134,16 @@ alter table if exists jbpm_user_tasks_excluded_users
add constraint fk_jbpm_user_tasks_excluded_users_tid foreign key (task_id) references jbpm_user_tasks(id) on delete cascade;

alter table if exists jbpm_user_tasks_attachments
drop constraint if exists fk_user_task_attachment_tid cascade;
drop constraint if exists fk_user_tasks_attachments_tid cascade;

alter table if exists jbpm_user_tasks_attachments
add constraint fk_user_task_attachment_tid foreign key (task_id) references jbpm_user_tasks(id) on delete cascade;
add constraint fk_user_tasks_attachments_tid foreign key (task_id) references jbpm_user_tasks(id) on delete cascade;

alter table if exists jbpm_user_tasks_comments
drop constraint if exists fk_user_task_comment_tid cascade;
drop constraint if exists fk_user_tasks_comments_tid cascade;

alter table if exists jbpm_user_tasks_comments
add constraint fk_user_task_comment_tid foreign key (task_id) references jbpm_user_tasks(id) on delete cascade;
add constraint fk_user_tasks_comments_tid foreign key (task_id) references jbpm_user_tasks(id) on delete cascade;

alter table if exists jbpm_user_tasks_inputs
drop constraint if exists fk_jbpm_user_tasks_inputs_tid cascade;
Expand Down

0 comments on commit 79b771a

Please sign in to comment.