Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Redesign: admin #11144

Merged
merged 723 commits into from
Sep 22, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
723 commits
Select commit Hold shift + click to select a range
2c4f9b9
form duplicate meetings
jorgeatgu Aug 30, 2023
53dca83
form edit agenda
jorgeatgu Aug 30, 2023
04676f6
form close meetings
jorgeatgu Aug 30, 2023
0bbedcf
picker close button
jorgeatgu Aug 30, 2023
a814fe0
add scope and put the callout outside the form
jorgeatgu Aug 30, 2023
7e87e4d
Avoid exceptions updating organization colors when blank values are sent
entantoencuanto Aug 30, 2023
fbb85b3
replace the more-line icon with Manage
jorgeatgu Aug 30, 2023
92fdb28
Merge branch 'feature/redesign-admin' of https://github.com/decidim/d…
jorgeatgu Aug 30, 2023
d9afaea
Fix tertiary color in _redesigned_color_picker.scss
entantoencuanto Aug 30, 2023
4858a71
Add tertiary color to organization appearance colors form
entantoencuanto Aug 30, 2023
453fd18
update the tertiary color value via triadic_color_picker
jorgeatgu Aug 30, 2023
a9c90ca
use the css variables instead of the variables defined in the tailwin…
jorgeatgu Aug 30, 2023
2a75254
Update selectors in tests
entantoencuanto Aug 30, 2023
81fc9b7
Use accept_confirm in test
entantoencuanto Aug 30, 2023
b07e20e
Use within_admin_menu to access participants in officializations tests
entantoencuanto Aug 30, 2023
da922e3
Update selector
entantoencuanto Aug 30, 2023
502abe5
Fix selector in tests
entantoencuanto Aug 30, 2023
5a5bc91
form meetings invite
jorgeatgu Aug 30, 2023
13cce8e
markup select recipients to deliver
jorgeatgu Aug 30, 2023
6130e76
markup preview newsletter
jorgeatgu Aug 30, 2023
5d32145
styles to dropdown_trigger
jorgeatgu Aug 30, 2023
56e3149
Adapt tests to redesign
entantoencuanto Aug 30, 2023
3afaa5f
Adapt tests to redesign
entantoencuanto Aug 30, 2023
29bfaa2
Adapt tests to redesign
entantoencuanto Aug 30, 2023
fd21f30
Use selector to disambiguate submit on shared example
entantoencuanto Aug 30, 2023
9524169
Merge branch 'develop' into feature/redesign-admin
entantoencuanto Aug 30, 2023
a540a36
proposals notes
jorgeatgu Aug 31, 2023
6e9c700
proposal answer radio-buttons
jorgeatgu Aug 31, 2023
1285d8d
add margin to label--tabs
jorgeatgu Aug 31, 2023
3510227
update icon
jorgeatgu Aug 31, 2023
65a2d15
proposals paginate
jorgeatgu Aug 31, 2023
8bfbcd1
space between label from global settings
jorgeatgu Aug 31, 2023
9541104
Fix radio_buttons attributes to display dependent field
entantoencuanto Aug 31, 2023
e0ea8d9
Remove redundant class
entantoencuanto Aug 31, 2023
beef226
Merge branch 'feature/redesign-admin' of https://github.com/decidim/d…
jorgeatgu Aug 31, 2023
1a529f5
styles to select and textarea
jorgeatgu Aug 31, 2023
dfeab2a
steps elections
jorgeatgu Aug 31, 2023
91178b4
choose questionnaire templates
jorgeatgu Aug 31, 2023
809b9c0
add class to duplicate meeting
jorgeatgu Aug 31, 2023
980661a
add padding to agenda items and sub items
jorgeatgu Aug 31, 2023
329f5bf
replace the icon to duplicate items
jorgeatgu Aug 31, 2023
9e5d885
Update selectors of redesigned component test form
entantoencuanto Aug 31, 2023
415831a
Add field class in meeting form to fix dependent fields displaying
entantoencuanto Aug 31, 2023
e9c9f74
remove </div>
jorgeatgu Aug 31, 2023
b6a11ca
add card to choose_questionnaire_templates
jorgeatgu Aug 31, 2023
7827499
add assemblies types to the dropdown menu
jorgeatgu Aug 31, 2023
2a8eb1a
Fix proposals_pick tests helper method
entantoencuanto Aug 31, 2023
f811bcc
Fix selector in test
entantoencuanto Aug 31, 2023
5912daf
add accordion to title and description
jorgeatgu Aug 31, 2023
50a984f
Merge branch 'feature/redesign-admin' of https://github.com/decidim/d…
jorgeatgu Aug 31, 2023
10b6ded
Replace "Not published" with "Unpublished"
jorgeatgu Aug 31, 2023
bb87716
add space between radio buttons
jorgeatgu Aug 31, 2023
7af5c56
show/hide icons
jorgeatgu Aug 31, 2023
b606658
add a lighter bg to content-blocks cards
jorgeatgu Aug 31, 2023
97eaf54
Recover counter of selected in proposals admin index
entantoencuanto Aug 31, 2023
0f2e6c3
Sanitize properly title and meetings titles on proposals admin show
entantoencuanto Aug 31, 2023
c2d516e
Add data attributes and recover id on proposals admin show metadata
entantoencuanto Aug 31, 2023
92de749
Recover amendments count metadata in proposals admin show
entantoencuanto Aug 31, 2023
3136fac
Adapt proposals admin show tests to redesign
entantoencuanto Aug 31, 2023
6e998c8
Merge branch 'feature/redesign-admin' of https://github.com/decidim/d…
jorgeatgu Sep 1, 2023
ba1c8fe
click icon collapse
jorgeatgu Sep 1, 2023
072c1a2
unpublished
jorgeatgu Sep 1, 2023
27452ee
Fix end position in conditional
entantoencuanto Sep 1, 2023
fd89b9c
Change test to check content opened in new window
entantoencuanto Sep 1, 2023
15047ed
Adapt test to redesign
entantoencuanto Sep 1, 2023
b36a281
Update selector in test
entantoencuanto Sep 1, 2023
3225f51
Access admin page via admin menu
entantoencuanto Sep 1, 2023
9375a4b
Include paginate helper in elections trustees admin
entantoencuanto Sep 1, 2023
0ed5014
Use within_admin_menu
entantoencuanto Sep 1, 2023
e0f6d5c
Use within_admin_menu
entantoencuanto Sep 1, 2023
2859cf9
Adapt tests to redesign
entantoencuanto Sep 1, 2023
9a2981a
Fix polling_officers_pick admin helper method
entantoencuanto Sep 1, 2023
2745b14
Use within_admin_menu
entantoencuanto Sep 1, 2023
b0969cb
Use within_admin_menu
entantoencuanto Sep 1, 2023
c26c5f1
Update selector in test
entantoencuanto Sep 1, 2023
5eb5c59
Update selector in test
entantoencuanto Sep 1, 2023
89e72f2
si la respuesta tiene un error abrir el acordeon via rails and js
jorgeatgu Sep 1, 2023
3ff07a6
add icons to ballot styles
jorgeatgu Sep 1, 2023
03f7a30
trigger click if the button contains "question-error"
jorgeatgu Sep 1, 2023
d203a77
Merge branch 'feature/redesign-admin' of https://github.com/decidim/d…
jorgeatgu Sep 1, 2023
8437d94
Use within_admin_menu
entantoencuanto Sep 1, 2023
3023048
Update selector
entantoencuanto Sep 1, 2023
b68de22
Adapt test to redesign
entantoencuanto Sep 1, 2023
bbccea5
Update selectors in tests
entantoencuanto Sep 1, 2023
73d175f
Extend organization color picker test to tertiary color and adjust cl…
entantoencuanto Sep 4, 2023
c1ddc20
Remove deprecated example
entantoencuanto Sep 4, 2023
fc7cb85
add icon arrow line to manage menu
jorgeatgu Sep 4, 2023
43baa50
Update moderations tooltip to use redesign helper
entantoencuanto Sep 4, 2023
a3baf09
Remove redundant check in test
entantoencuanto Sep 4, 2023
a03a39f
Change data_picker js to disable picker
entantoencuanto Sep 4, 2023
1606937
Adapt test
entantoencuanto Sep 4, 2023
4a6a1d1
Use within_admin_menu
entantoencuanto Sep 4, 2023
8a16f72
Change tests to check content opened in new window
entantoencuanto Sep 4, 2023
3a5f3d2
responsive nav menu
jorgeatgu Sep 4, 2023
01fc623
Use within_admin_menu
entantoencuanto Sep 4, 2023
3795aa2
responsive layouts
jorgeatgu Sep 4, 2023
3da388d
responsive table scroll
jorgeatgu Sep 4, 2023
ece7f76
responsive secondary nav and title bar
jorgeatgu Sep 4, 2023
1085441
padding and margin zero to responsive dropdown
jorgeatgu Sep 4, 2023
3d4d791
Merge branch 'feature/redesign-admin' of https://github.com/decidim/d…
jorgeatgu Sep 4, 2023
32bbfdd
Recover import assembly link in admin assemblies layout
entantoencuanto Sep 4, 2023
b8d3372
Use within_admin_menu
entantoencuanto Sep 4, 2023
0c07f0c
Add selector in test to avoid ambiguity
entantoencuanto Sep 4, 2023
9d91945
Use within_admin_menu
entantoencuanto Sep 4, 2023
0f8e6be
dropdown admin log
jorgeatgu Sep 5, 2023
2c6df1c
Use within_admin_menu in tests
entantoencuanto Sep 5, 2023
9ba1a93
Update selector in tests
entantoencuanto Sep 5, 2023
008ad7b
Recover pagination in assembly members admin
entantoencuanto Sep 5, 2023
92f48bb
Update selector in tests
entantoencuanto Sep 5, 2023
a88bcd2
Remove deprecated sidebar test and use within_admin_menu
entantoencuanto Sep 5, 2023
eb7f490
Change selector in examples to avoid ambiguities
entantoencuanto Sep 5, 2023
9b025db
add aria-label to search button
jorgeatgu Sep 5, 2023
a11fabd
add aria-label to logo
jorgeatgu Sep 5, 2023
cf36003
replace import icon
jorgeatgu Sep 5, 2023
97e1a76
Merge branch 'feature/redesign-admin' of https://github.com/decidim/d…
jorgeatgu Sep 5, 2023
4ce395d
Recover answer proposal text in admin
entantoencuanto Sep 5, 2023
9f89896
Fix selectors in test and use click to display private notes
entantoencuanto Sep 5, 2023
8ce4b7c
Make imports upload field mandatory
entantoencuanto Sep 5, 2023
2f3bba3
Avoid errors in imports generating breadcrumb
entantoencuanto Sep 5, 2023
1254134
Fix test
entantoencuanto Sep 5, 2023
cc547aa
remove left position
jorgeatgu Sep 5, 2023
bce4309
remove background
jorgeatgu Sep 5, 2023
d06c9cf
save button at the top
jorgeatgu Sep 5, 2023
e37b86c
remove row column
jorgeatgu Sep 5, 2023
8399be5
Update selectors in tests
entantoencuanto Sep 5, 2023
5e25bee
replace accordion ids to solve accessibility issue
jorgeatgu Sep 5, 2023
2997f04
Use within_admin_menu in tests
entantoencuanto Sep 5, 2023
3dc00ff
Update selectors in test
entantoencuanto Sep 5, 2023
7c13f26
Avoid selector ambiguities
entantoencuanto Sep 5, 2023
68685f6
Change tests to check content opened in new window
entantoencuanto Sep 5, 2023
386dc26
Adapt test
entantoencuanto Sep 5, 2023
2cde74e
Remove deprecated sidebar test and use within_admin_menu
entantoencuanto Sep 5, 2023
d6c1d4a
Fix missing translation
entantoencuanto Sep 5, 2023
a7900f2
Fix expected text in tests
entantoencuanto Sep 5, 2023
97dc3f0
add aria-label to form.translated
jorgeatgu Sep 5, 2023
9fcb25e
Merge branch 'feature/redesign-admin' of https://github.com/decidim/d…
jorgeatgu Sep 5, 2023
f0e1628
Merge branch 'develop' into feature/redesign-admin
entantoencuanto Sep 5, 2023
3d6622e
Recover test
entantoencuanto Sep 5, 2023
23b0707
add redesigned styles to multiselect-test
jorgeatgu Sep 5, 2023
1a34b93
Merge branch 'feature/redesign-admin' of https://github.com/decidim/d…
jorgeatgu Sep 5, 2023
9ae1eea
revert left position
jorgeatgu Sep 5, 2023
b49358b
Avoid button selector ambiguities
entantoencuanto Sep 5, 2023
3617cf0
Remove unused translations
entantoencuanto Sep 5, 2023
4235918
Normalize locales
entantoencuanto Sep 5, 2023
21ed0be
Normalize locales: remove manage translations
entantoencuanto Sep 5, 2023
a8ec5a0
Fix linter offenses
entantoencuanto Sep 5, 2023
fb4d3c3
Fix linter offenses
entantoencuanto Sep 5, 2023
34ba649
lint scss
jorgeatgu Sep 6, 2023
b3c3a20
Merge branch 'feature/redesign-admin' of https://github.com/decidim/d…
jorgeatgu Sep 6, 2023
d41e21c
fix lint scss
jorgeatgu Sep 6, 2023
e730aae
fix lint scss
jorgeatgu Sep 6, 2023
6cacc26
fix lint erb
jorgeatgu Sep 6, 2023
4a8cd90
Recover initiatives print link from admin index
entantoencuanto Sep 6, 2023
6161fe4
add : to fix the proposals test
jorgeatgu Sep 6, 2023
e99f911
Merge branch 'feature/redesign-admin' of https://github.com/decidim/d…
jorgeatgu Sep 6, 2023
79052df
add icons to the admin_participatory_process_components_menu
jorgeatgu Sep 6, 2023
dedc797
Add group filter in participatory processes admin index
entantoencuanto Sep 6, 2023
41df4e4
WIP Add link to selected group and force space between elements
entantoencuanto Sep 6, 2023
c59f4da
Unskip filter processes tests
entantoencuanto Sep 6, 2023
5c90b31
Unskip test
entantoencuanto Sep 6, 2023
c0709df
Fix linter offense
entantoencuanto Sep 6, 2023
9de810b
add styles to dropdwon processes group
jorgeatgu Sep 6, 2023
9498739
Merge branch 'feature/redesign-admin' of https://github.com/decidim/d…
jorgeatgu Sep 6, 2023
0ec59cd
fix lint scss
jorgeatgu Sep 6, 2023
7e72b87
styles for newsletter and moderations
jorgeatgu Sep 6, 2023
e594bb0
add the admin_participatory_process_group_menu to the layout
jorgeatgu Sep 6, 2023
702ac18
set the size of the browser before the run the color picker test
jorgeatgu Sep 6, 2023
fbc4a2f
Set breadcrumb of participatory processes groups
entantoencuanto Sep 6, 2023
1229a41
replace delete icon
jorgeatgu Sep 6, 2023
4d5cc08
Merge branch 'feature/redesign-admin' of https://github.com/decidim/d…
jorgeatgu Sep 6, 2023
0c96560
Merge branch 'develop' into feature/redesign-admin
entantoencuanto Sep 6, 2023
4dfa25a
Use selectors instead of coordinates wich depends on window size to c…
entantoencuanto Sep 6, 2023
d553105
Add REDESIGN_PENDING skip tests
entantoencuanto Sep 6, 2023
f77a3b9
Merge branch 'develop' of https://github.com/decidim/decidim into fea…
jorgeatgu Sep 7, 2023
1b3c058
Change group filter translations
entantoencuanto Sep 7, 2023
7c77b2e
add border to items
jorgeatgu Sep 7, 2023
6f91047
Hide dropdown if present_diff is blank in logs presenters
entantoencuanto Sep 7, 2023
298b0fa
add styles to dropdown logs
jorgeatgu Sep 7, 2023
77b8578
add aria-label to dropdown logs
jorgeatgu Sep 7, 2023
1f34a1d
remove the max-width of the .container so that the content fits the m…
jorgeatgu Sep 8, 2023
792e793
Normalize locales
entantoencuanto Sep 8, 2023
0ddecce
Fix too long line linter offense
entantoencuanto Sep 8, 2023
3775eb5
Fix selector in tests
entantoencuanto Sep 8, 2023
31d140a
add sticky to the form buttons (update, new, create)
jorgeatgu Sep 8, 2023
c7661f3
fix the tabs from translate fields when add a service, agenda or answer
jorgeatgu Sep 8, 2023
b797187
add form__wrapper to questions
jorgeatgu Sep 8, 2023
a3b9357
add classes to edit images
jorgeatgu Sep 8, 2023
4b02c69
add styles to debate closes
jorgeatgu Sep 8, 2023
ff3238f
add row column to budgets form
jorgeatgu Sep 8, 2023
9efeda2
form reminders
jorgeatgu Sep 8, 2023
4cb93be
remove special characters
jorgeatgu Sep 8, 2023
233bf8d
form edit attachments
jorgeatgu Sep 8, 2023
ad5baf5
form import results
jorgeatgu Sep 8, 2023
d5b1b13
form import results
jorgeatgu Sep 8, 2023
8795261
Merge branch 'feature/redesign-admin' of https://github.com/decidim/d…
jorgeatgu Sep 8, 2023
2c0ff81
adjust the tooltip positioning
Crashillo Sep 11, 2023
94bf0b9
replace icons
Crashillo Sep 11, 2023
77ef8fd
Merge branch 'develop' into feature/redesign-admin
Crashillo Sep 11, 2023
d932134
fix typo
Crashillo Sep 11, 2023
67327c4
give space to import_results
Crashillo Sep 12, 2023
e2407e2
fix linter
Crashillo Sep 12, 2023
96d8c85
Merge branch 'develop' into feature/redesign-admin
entantoencuanto Sep 12, 2023
01c6fcd
refactor admin settings section submenu
Crashillo Sep 13, 2023
137d825
use dropdown for mobile view
Crashillo Sep 13, 2023
1ca6a59
missing forms to be refactorized
Crashillo Sep 14, 2023
4d2d360
refactor titles settings menu
Crashillo Sep 14, 2023
fa56c84
refactor titles moderations menu
Crashillo Sep 14, 2023
029f281
refactor titles static pages menu
Crashillo Sep 14, 2023
5c3cf96
refactor titles admins menu
Crashillo Sep 14, 2023
595f259
refactor titles newsletters menu
Crashillo Sep 14, 2023
cc6a878
refactor titles logs menu
Crashillo Sep 14, 2023
f8dabd7
refactor titles templates menu
Crashillo Sep 14, 2023
19b5b42
fix dropdown position
Crashillo Sep 14, 2023
dc7bd94
replace and normalize headings
Crashillo Sep 14, 2023
faf4261
Merge branch 'develop' into feature/redesign-admin
Crashillo Sep 14, 2023
dea0bb6
change translation
Crashillo Sep 14, 2023
9b29360
replace and normalize headings
Crashillo Sep 14, 2023
ea4a825
fix stylelint
Crashillo Sep 14, 2023
3628659
fix i18n
Crashillo Sep 14, 2023
8803c3c
fix tests
Crashillo Sep 15, 2023
abd2617
fix more tests
Crashillo Sep 15, 2023
cbb53e0
fix typo
Crashillo Sep 15, 2023
880a1da
fix test conferences
Crashillo Sep 15, 2023
1bacacb
fix tests
Crashillo Sep 15, 2023
b41cdae
add padding-bottom to container to avoid overflows
Crashillo Sep 15, 2023
cc339f9
fix typo
Crashillo Sep 15, 2023
a3a720b
Merge branch 'develop' into feature/redesign-admin
Crashillo Sep 18, 2023
6362bdf
fix tests
Crashillo Sep 18, 2023
93cd048
fix lint
Crashillo Sep 18, 2023
e2b1562
remove commented code
Crashillo Sep 18, 2023
fdc0a37
remove "theme" from paginator
Crashillo Sep 18, 2023
904513e
remove filters pagination
Crashillo Sep 18, 2023
1caac2f
remove code
Crashillo Sep 18, 2023
7bf9075
remove unused method
Crashillo Sep 18, 2023
367cb82
change paginator method
Crashillo Sep 18, 2023
8155e1f
restore button to deploy menu (will fail for settings)
Crashillo Sep 19, 2023
73ff738
unused translation
Crashillo Sep 19, 2023
e65b890
fix tests
Crashillo Sep 19, 2023
2712e8d
fix removal style
Crashillo Sep 19, 2023
6dd8809
remove commented code
Crashillo Sep 19, 2023
d73f932
fix test
Crashillo Sep 19, 2023
4ca2088
missing layout for titles
Crashillo Sep 19, 2023
e1dda5e
remove mock content, leaving the scaffolding
Crashillo Sep 19, 2023
1139ee4
deny the chance to change the admin colors
Crashillo Sep 19, 2023
973fff2
remove testing code
Crashillo Sep 19, 2023
adc9acc
isolate the core assets from the admin ones
Crashillo Sep 19, 2023
88bfb87
fix tests
Crashillo Sep 20, 2023
cf1a732
Merge branch 'develop' into feature/redesign-admin
Crashillo Sep 20, 2023
3c85374
fix tests
Crashillo Sep 20, 2023
5026c3d
Merge branch 'develop' into feature/redesign-admin
Crashillo Sep 21, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ module Admin
#
module ApplicationHelper
include Decidim::Admin::ResourceScopeHelper
include Decidim::PaginateHelper
end
end
end
Expand Down
Original file line number Diff line number Diff line change
@@ -1,27 +1,31 @@
<% add_decidim_page_title(t(".title")) %>
<%= form_tag(import_results_path, multipart: true, class: "form new_import") do %>
<div class="card">
<div class="card-divider">
<h2 class="card-title">
<%= t(".title") %>
</h2>
</div>

<div class="card-section">
<div class="mb-s">
<p><%= t(".info",
link_new_status: new_status_path,
link_new_result: new_result_path,
link_export_csv: link_to(t(".download_export"),exports_path(current_component, id: "results", format: "CSV"), method: :post)
).try("html_safe") %></p>
<div class="item_show__header">
<h2 class="item_show__header-title">
<%= t(".title") %>
</h2>
</div>
<div class="item__edit item__edit-1col">
<div class="item__edit-form">
<%= form_tag(import_results_path, multipart: true, class: "form form-defaults new_import") do %>
<div class="card py-4">
<div class="card-section space-y-4">
<div class="row column">
<p><%= t(".info",
link_new_status: new_status_path,
link_new_result: new_result_path,
link_export_csv: link_to(t(".download_export"),exports_path(current_component, id: "results", format: "CSV"), method: :post)
).try("html_safe") %></p>
</div>
<div class="row column">
<%= file_field_tag :csv_file %>
</div>
</div>
</div>
<div class="row column">
<%= file_field_tag :csv_file %>
<div class="item__edit-sticky">
<div class="item__edit-sticky-container">
<%= submit_tag t(".import"), class: "button button__sm button__secondary" %>
</div>
</div>
</div>
<% end %>
</div>

<div class="button--double form-general-submit">
<%= submit_tag t(".import"), class: "button" %>
</div>
<% end %>
</div>
Original file line number Diff line number Diff line change
@@ -1,34 +1,44 @@
<% add_decidim_page_title(t(".title")) %>
<%= form_for(@form, url: projects_import_index_path(@accountability), html: { class: "form import_projects" }) do |f| %>
<% if @form.origin_components.any? %>
<div class="card">
<div class="card-divider">
<h2 class="card-title"><%= t(".title") %></h2>
</div>
<div class="card-section">
<div class="row column">
<%= f.select :origin_component_id, @form.origin_components_collection, prompt: t(".select_component"), label: t(".origin_component_id") %>
</div>
<div class="row column">
<% @form.origin_components.each do |component| %>
<small id="component_<%= component.id %>" class="help-text hide
<%= " form-error is-visible" if @form.selected_projects_count(component).zero? %>">
<%= t(".new_items", count: @form.selected_projects_count(component)) %>
</small>
<% end %>
</div>
<div class="row column">
<%= f.check_box :import_all_selected_projects, label: t(".import_all_selected_projects") %>
<div class="item_show__header">
<h2 class="item_show__header-title">
<%= t(".title") %>
</h2>
</div>

<div class="item__edit item__edit-1col">
<div class="item__edit-form">
<%= form_for(@form, url: projects_import_index_path(@accountability), html: { class: "form form-defaults import_projects" }) do |f| %>
<% if @form.origin_components.any? %>
<div class="form__wrapper">
<div class="card">
<div class="card-divider"></div>
<div class="card-section">
<div class="row column">
<%= f.select :origin_component_id, @form.origin_components_collection, prompt: t(".select_component"), label: t(".origin_component_id") %>
</div>
<div class="row column">
<% @form.origin_components.each do |component| %>
<small id="component_<%= component.id %>" class="help-text hide
<%= " form-error is-visible" if @form.selected_projects_count(component).zero? %>">
<%= t(".new_items", count: @form.selected_projects_count(component)) %>
</small>
<% end %>
</div>
<div class="row column">
<%= f.check_box :import_all_selected_projects, label: t(".import_all_selected_projects") %>
</div>
</div>
</div>
</div>
</div>
</div>

<div class="button--double form-general-submit">
<%= f.submit t(".create") %>
</div>
<% else %>
<p><%= t(".no_components") %></p>
<% end %>
<% end %>
<div class="form__wrapper-block flex-col-reverse md:flex-row justify-between">
<%= f.submit t(".create"), class: "button button__sm button__secondary" %>
</div>
<% else %>
<p><%= t(".no_components") %></p>
<% end %>
<% end %>
</div>
</div>

<%= append_javascript_pack_tag "decidim_accountability_admin_imports" %>
Original file line number Diff line number Diff line change
@@ -1,71 +1,72 @@
<div class="card">
<div class="card-divider">
<h2 class="card-title"><%= title %></h2>
</div>

<div class="card-section">
<div class="row column">
<%= form.translated :text_field, :title, autofocus: true %>
</div>

<div class="row column">
<%= form.translated :editor, :description %>
</div>
<div class="form__wrapper">
<div class="card">
<div class="card-divider"></div>

<% if @form.parent_id %>
<div class="card-section">
<div class="row column">
<%= form.translated :text_field, :title, autofocus: true, aria: { label: :title } %>
</div>

<div class="row column">
<%= form.select :parent_id, parent_results.map { |result| [translated_attribute(result.title), result.id] }, include_blank: true %>
<%= form.translated :editor, :description, aria: { label: :description } %>
</div>

<% else %>
<% if @form.parent_id %>

<% if current_component.has_subscopes? %>
<div class="row column">
<%= scopes_picker_field form, :decidim_scope_id, root: current_component.scope %>
<%= form.select :parent_id, parent_results.map { |result| [translated_attribute(result.title), result.id] }, include_blank: true %>
</div>
<% end %>

<div class="row column">
<%= form.categories_select :decidim_category_id, current_participatory_space.categories, include_blank: true, disable_parents: false %>
</div>
<% else %>

<% end %>
<% if current_component.has_subscopes? %>
<div class="row column">
<%= scopes_select_field form, :decidim_scope_id, root: current_component.scope %>
</div>
<% end %>

<div class="row">
<div class="columns xlarge-6">
<%= form.date_field :start_date %>
</div>
<div class="row column">
<%= form.categories_select :decidim_category_id, current_participatory_space.categories, include_blank: true, disable_parents: false %>
</div>

<div class="columns xlarge-6">
<%= form.date_field :end_date %>
</div>
</div>
<% end %>

<div class="row">
<div class="columns xlarge-6">
<%= form.select :decidim_accountability_status_id, statuses.map { |status| [translated_attribute(status.name), status.id, { "data-progress" => status.progress }] }, include_blank: true %>
<div class="row">
<div class="columns xlarge-6">
<%= form.date_field :start_date %>
</div>

<div class="columns xlarge-6">
<%= form.date_field :end_date %>
</div>
</div>

<div class="columns xlarge-6">
<%= form.number_field :progress %>
<div class="row">
<div class="columns xlarge-6">
<%= form.select :decidim_accountability_status_id, statuses.map { |status| [translated_attribute(status.name), status.id, { "data-progress" => status.progress }] }, include_blank: true %>
</div>

<div class="columns xlarge-6">
<%= form.number_field :progress %>
</div>
</div>
</div>

<% if Decidim::Accountability.enable_proposal_linking %>
<% if Decidim::Accountability.enable_proposal_linking %>
<div class="row column">
<%= proposals_picker(form, :proposals, proposals_picker_results_path) %>
</div>
<% end %>

<div class="row column">
<%= proposals_picker(form, :proposals, proposals_picker_results_path) %>
<% if @form.projects %>
<%= form.select :project_ids,
@form.projects,
{},
{ multiple: true, class: "chosen-select" } %>
<% end %>
</div>
<% end %>

<div class="row column">
<% if @form.projects %>
<%= form.select :project_ids,
@form.projects,
{},
{ multiple: true, class: "chosen-select" } %>
<% end %>
</div>

</div>
</div>

</div>
Original file line number Diff line number Diff line change
@@ -1,10 +1,21 @@
<% add_decidim_page_title(t(".title")) %>
<%= decidim_form_for(@form, html: { class: "form edit_result" }) do |f| %>
<%= render partial: "form", object: f, locals: { title: t(".title") } %>
<div class="item_show__header">
<h2 class="item_show__header-title">
<%= t(".title") %>
</h2>
</div>

<div class="button--double form-general-submit">
<%= f.submit t(".update") %>
</div>
<% end %>
<div class="item__edit item__edit-1col">
<div class="item__edit-form">
<%= decidim_form_for(@form, html: { class: "form form-defaults edit_result" }) do |f| %>
<%= render partial: "form", object: f, locals: { title: t(".title") } %>
<div class="item__edit-sticky">
<div class="item__edit-sticky-container">
<%= f.submit t(".update"), class: "button button__sm button__secondary" %>
</div>
</div>
<% end %>
</div>
</div>

<%= append_javascript_pack_tag "decidim_accountability_admin" %>