Skip to content

Commit 8df59fa

Browse files
authored
Fix project column edit (#34890)
Fix #34888
1 parent e17dfce commit 8df59fa

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

templates/projects/view.tmpl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,12 +130,12 @@
130130
<input class="project-column-id" type="hidden" name="id">
131131
<div class="required field">
132132
<label class="project-column-title-label" for="project-column-title-input">title</label>
133-
<input id="project-column-title-input" name="title" value="{{.Title}}" required>
133+
<input id="project-column-title-input" name="title" required>
134134
</div>
135135
<div class="field">
136136
<label class="project-column-color-label" for="project-column-color-input">color</label>
137137
<div class="js-color-picker-input column">
138-
<input maxlength="7" placeholder="#c320f6" id="project-column-color-input" name="color" value="{{.Color}}">
138+
<input maxlength="7" placeholder="#c320f6" id="project-column-color-input" name="color">
139139
{{template "repo/issue/label_precolors"}}
140140
</div>
141141
</div>

web_src/js/features/repo-projects.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,6 @@ function initRepoProjectColumnEdit(writableProjectBoard: Element): void {
114114
window.location.reload(); // newly added column, need to reload the page
115115
return;
116116
}
117-
fomanticQuery(elModal).modal('hide');
118117

119118
// update the newly saved column title and color in the project board (to avoid reload)
120119
const elEditButton = writableProjectBoard.querySelector<HTMLButtonElement>(`.show-project-column-modal-edit[${attrDataColumnId}="${columnId}"]`);
@@ -134,6 +133,8 @@ function initRepoProjectColumnEdit(writableProjectBoard: Element): void {
134133
elBoardColumn.style.removeProperty('color');
135134
queryElemChildren<HTMLElement>(elBoardColumn, '.divider', (divider) => divider.style.removeProperty('color'));
136135
}
136+
137+
fomanticQuery(elModal).modal('hide');
137138
} finally {
138139
elForm.classList.remove('is-loading');
139140
}

0 commit comments

Comments
 (0)