|
2 | 2 | var _globals = {
|
3 | 3 | new_project: '<%= gettext "Project created successfully!" %>',
|
4 | 4 | delete_project_message: '<%= gettext "Project deleted successfully!" %>',
|
| 5 | + update_project_message: '<%= gettext "Project updated successfully!" %>', |
5 | 6 | delete_project_alert: '<%= gettext "You are trying to delete a project! are you sure?" %>',
|
6 | 7 | delete_project_endpoint: '<%= Routes.project_path(@conn, :delete, "UUID") %>',
|
7 | 8 | project_view_page: '<%= Routes.page_path(@conn, :project, "UUID") %>'
|
|
161 | 162 | <ul>
|
162 | 163 | <li>
|
163 | 164 | <a href={Routes.page_path(@conn, :projects)}>
|
164 |
| - <div class="tooltip-item in-active" data-bs-toggle="tooltip" data-bs-placement="right" title="Blank Page" data-bs-original-title="Blank Page" aria-label="Blank Page"></div> |
165 | 165 | <span>
|
166 | 166 | <i class="iconly-Curved-PaperPlus"></i>
|
167 | 167 | <span><%= gettext "Projects" %></span>
|
|
170 | 170 | </li>
|
171 | 171 | <li>
|
172 | 172 | <a href={Routes.page_path(@conn, :snapshots)}>
|
173 |
| - <div class="tooltip-item in-active" data-bs-toggle="tooltip" data-bs-placement="right" title="Blank Page" data-bs-original-title="Blank Page" aria-label="Blank Page"></div> |
174 | 173 | <span>
|
175 | 174 | <i class="iconly-Curved-PaperPlus"></i>
|
176 | 175 | <span><%= gettext "Snapshots" %></span>
|
|
180 | 179 | <%= if @data.is_super do %>
|
181 | 180 | <li>
|
182 | 181 | <a href={Routes.page_path(@conn, :teams)}>
|
183 |
| - <div class="tooltip-item in-active" data-bs-toggle="tooltip" data-bs-placement="right" title="Blank Page" data-bs-original-title="Blank Page" aria-label="Blank Page"></div> |
184 | 182 | <span>
|
185 | 183 | <i class="iconly-Curved-PaperPlus"></i>
|
186 | 184 | <span><%= gettext "Teams" %></span>
|
|
189 | 187 | </li>
|
190 | 188 | <li>
|
191 | 189 | <a href={Routes.page_path(@conn, :users)}>
|
192 |
| - <div class="tooltip-item in-active" data-bs-toggle="tooltip" data-bs-placement="right" title="Blank Page" data-bs-original-title="Blank Page" aria-label="Blank Page"></div> |
193 | 190 | <span>
|
194 | 191 | <i class="iconly-Curved-PaperPlus"></i>
|
195 | 192 | <span><%= gettext "Users" %></span>
|
|
198 | 195 | </li>
|
199 | 196 | <li>
|
200 | 197 | <a href={Routes.page_path(@conn, :settings)}>
|
201 |
| - <div class="tooltip-item in-active" data-bs-toggle="tooltip" data-bs-placement="right" title="Blank Page" data-bs-original-title="Blank Page" aria-label="Blank Page"></div> |
202 | 198 | <span>
|
203 | 199 | <i class="iconly-Curved-PaperPlus"></i>
|
204 | 200 | <span><%= gettext "Settings" %></span>
|
|
295 | 291 | <td style="text-align: center">${formatDatetime(project.createdAt)}</td>
|
296 | 292 | <td>
|
297 | 293 | <button @click="viewProjectAction(project.id)" class="btn btn-dashed btn-sm text-warning-100 border-warning-100 hp-hover-text-color-warning-80 hp-hover-border-color-warning-80"><%= gettext "View" %></button>
|
298 |
| - <!--<button @click="editProjectAction(project.id)" class="btn btn-dashed btn-sm text-black-100 border-black-100 hp-hover-text-color-black-80 hp-hover-border-color-black-80"><%= gettext "Edit" %></button>--> |
| 294 | + <button @click="editProjectAction(project.id)" class="btn btn-dashed btn-sm text-black-100 border-black-100 hp-hover-text-color-black-80 hp-hover-border-color-black-80" data-bs-toggle="modal" data-bs-target="#edit_project_modal"><%= gettext "Edit" %></button> |
299 | 295 | <button @click="deleteProjectAction(project.id)" class="btn btn-dashed btn-sm text-danger border-danger hp-hover-text-color-danger-2 hp-hover-border-color-danger-2"><%= gettext "Delete" %></button>
|
300 | 296 | </td>
|
301 | 297 | </tr>
|
|
393 | 389 | </div>
|
394 | 390 | </div>
|
395 | 391 |
|
| 392 | + <div class="modal fade" id="edit_project_modal" tabindex="-1" aria-labelledby="editProjectLabel" aria-hidden="true" data-action={Routes.team_path(@conn, :list)}> |
| 393 | + <div class="modal-dialog modal-dialog-centered"> |
| 394 | + <div class="modal-content"> |
| 395 | + <div class="modal-header py-16 px-24"> |
| 396 | + <h5 class="modal-title" id="editProjectLabel"><%= gettext "Edit Project" %></h5> |
| 397 | + <button type="button" class="btn-close hp-bg-none d-flex align-items-center justify-content-center" data-bs-dismiss="modal" aria-label="Close"> |
| 398 | + <i class="ri-close-line hp-text-color-dark-0 lh-1" style="font-size: 24px;"></i> |
| 399 | + </button> |
| 400 | + </div> |
| 401 | + |
| 402 | + <div class="divider m-0"></div> |
| 403 | + |
| 404 | + <form id="update_project_form" action={Routes.project_path(@conn, :update, "UUID")} method="post" v-on:submit.prevent="updateProjectAction"> |
| 405 | + <input type="hidden" value="" name="uuid"> |
| 406 | + <div class="modal-body"> |
| 407 | + <div class="row gx-8"> |
| 408 | + <div class="col-12"> |
| 409 | + <div class="mb-24"> |
| 410 | + <label class="form-label"><%= gettext "Name" %></label> |
| 411 | + <input type="text" class="form-control" name="name" required="required" minlength="2" maxlength="60"> |
| 412 | + </div> |
| 413 | + </div> |
| 414 | + |
| 415 | + <div class="col-12"> |
| 416 | + <div class="mb-24"> |
| 417 | + <label class="form-label"><%= gettext "Slug" %></label> |
| 418 | + <input type="text" class="form-control" name="slug" required="required" minlength="2" maxlength="60"> |
| 419 | + </div> |
| 420 | + </div> |
| 421 | + |
| 422 | + <div class="col-12"> |
| 423 | + <div class="mb-24"> |
| 424 | + <label class="form-label"><%= gettext "Description" %></label> |
| 425 | + <textarea name="description" class="form-control" required="required" minlength="2" maxlength="250"></textarea> |
| 426 | + </div> |
| 427 | + </div> |
| 428 | + |
| 429 | + <div class="col-12"> |
| 430 | + <div class="mb-24"> |
| 431 | + <label class="form-label"><%= gettext "Team" %></label> |
| 432 | + <select class="form-select" name="team_id" required="required"> |
| 433 | + <template v-for="team in teams"> |
| 434 | + <option :value="team.id">${team.name}</option> |
| 435 | + </template> |
| 436 | + </select> |
| 437 | + </div> |
| 438 | + </div> |
| 439 | + </div> |
| 440 | + </div> |
| 441 | + |
| 442 | + <div class="modal-footer pt-0 px-24 pb-24"> |
| 443 | + <div class="divider"></div> |
| 444 | + <button type="submit" class="m-0 btn btn-primary w-100" :disabled="isInProgress"><%= gettext "Submit" %></button> |
| 445 | + </div> |
| 446 | + </form> |
| 447 | + </div> |
| 448 | + </div> |
| 449 | + </div> |
396 | 450 | </div>
|
397 | 451 |
|
398 | 452 | <footer class="w-100 py-18 px-16 py-sm-24 px-sm-32 hp-bg-color-black-20 hp-bg-color-dark-90">
|
|
0 commit comments