Project edit
This commit is contained in:
35
views/prjspec.erb
Normal file
35
views/prjspec.erb
Normal file
@@ -0,0 +1,35 @@
|
||||
<%= erb :header %>
|
||||
<script src="js/jquery.dropdown.min.js"></script>
|
||||
<div class="container">
|
||||
<form action="/gitspec/<%= ERB::Util.url_encode(@proj_id) %>/<%= ERB::Util.url_encode(@git_id) %>" method="post">
|
||||
<div class="mb-3">
|
||||
<label for="projname" class="form-label">Установить имя spec файла для гит проекта</label>
|
||||
<input type="text" class="form-control" id="speccustom" name="speccustom" value="<%= @spec_file %>">
|
||||
</div>
|
||||
<div class="mb-3">
|
||||
<label for="description" class="form-label">Доступные spec файлы</label>
|
||||
<div class="filelist">
|
||||
<select class="form-control" id="filelst" name="filelst">
|
||||
<% @files_list.each do |item| %>
|
||||
<% if !@spec_file.nil? && item.include?(@spec_file) %>
|
||||
<option value="<%= item %>" selected><%= item %></option>
|
||||
<% else %>
|
||||
<option value="<%= item %>"><%= item %></option>
|
||||
<% end %>
|
||||
<% end %>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="mb-3 text-center">
|
||||
<button type="submit" class="btn btn-primary" name="save" value="1">Сохранить</button>
|
||||
<button type="submit" class="btn btn-danger" name="delete" value="2">Удалить установленный spec</button>
|
||||
<button type="submit" class="btn btn-secondary" name="delete" value="2">Отмена</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<script>
|
||||
$('.filelist').dropdown({
|
||||
searchNoData: '<li style="color:#ddd">Нет данных</li>',
|
||||
});
|
||||
</script>
|
||||
<%= erb :footer %>
|
||||
Reference in New Issue
Block a user