Skip to content

Commit

Permalink
Add select all button
Browse files Browse the repository at this point in the history
  • Loading branch information
eudaldca committed Nov 29, 2023
1 parent ae89d30 commit b5e8a50
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 4 deletions.
1 change: 1 addition & 0 deletions src/Admin/langs/ca/messages.inc
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@ function getMessage ($id) {
$mess_arr['info_word_addmassive'] = 'Afegir massivament';
$mess_arr['info_word_exportmassive'] = 'Exportar tots els fills';
$mess_arr['info_word_join'] = 'Relacionar';
$mess_arr['info_word_select_all'] = 'Seleccionar pàgina';
$mess_arr['info_word_ID'] = 'ID';
$mess_arr['info_word_img'] = 'Img.';
$mess_arr['info_word_ID_explanation']='Ordenar per identificador';
Expand Down
9 changes: 5 additions & 4 deletions src/Admin/langs/en/messages.inc
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,7 @@ function getMessage ($id) {
$mess_arr['info_word_addmassive'] = 'Massive add';
$mess_arr['info_word_exportmassive'] = 'Massive export';
$mess_arr['info_word_join'] = 'Relate';
$mess_arr['info_word_select_all'] = 'Select page';
$mess_arr['info_word_ID'] = 'ID';
$mess_arr['info_word_img'] = 'Img.';
$mess_arr['info_word_ID_explanation'] = 'Order by ID';
Expand Down Expand Up @@ -220,7 +221,7 @@ function getMessage ($id) {
$mess_arr['acciones']="Actions";

$mess_arr['error_getting_apps']="Error getting App data, please try again";

$mess_arr['tab']="Tab";
$mess_arr['crop_image']="Crop image";
$mess_arr['leave_as_is']="Leave as is";
Expand All @@ -230,7 +231,7 @@ function getMessage ($id) {
$mess_arr['small_original']="Original too small";
$mess_arr['not_empty']="Not empty";
$mess_arr['original']="Original";

$mess_arr['save']="Save";
$mess_arr['saved']="Saved!";
$mess_arr['saved_wrong']="Something went wrong!";
Expand All @@ -243,7 +244,7 @@ function getMessage ($id) {
$mess_arr['current_password'] = 'Current password';
$mess_arr['new_password'] = 'New password';
$mess_arr['repeat_password'] = 'Repeat password';
$mess_arr['save_password'] = 'Save password';
$mess_arr['save_password'] = 'Save password';
$mess_arr['create_users'] = 'Create users';
$mess_arr['new_user'] = 'New user';
$mess_arr['role'] = 'Role';
Expand Down Expand Up @@ -274,4 +275,4 @@ function getMessage ($id) {

return $mess_arr[$id];
}
?>
?>
1 change: 1 addition & 0 deletions src/Admin/langs/es/messages.inc
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,7 @@ function getMessage ($id) {
$mess_arr['info_word_addmassive'] = 'Añadir masivamente';
$mess_arr['info_word_exportmassive'] = 'Exportar todos los hijos';
$mess_arr['info_word_join'] = 'Relacionar';
$mess_arr['info_word_select_all'] = 'Seleccionar página';
$mess_arr['info_word_ID'] = 'ID';
$mess_arr['info_word_img'] = 'Img.';
$mess_arr['info_word_ID_explanation'] = 'Ordenar por identificador';
Expand Down
5 changes: 5 additions & 0 deletions src/Admin/views/templates/instances_list.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
<form class="form" id="relation_all" name="relation_all" method="post" enctype="multipart/form-data" action="{{route('editora.action', 'join_all')}}">
{{ csrf_field() }}
<button class="btn clr-secondary" style="font-size:14px">{{getMessage('info_word_join')}}</button>
<button class="btn clr-primary" style="font-size:14px" onclick="selectAll()">{{getMessage('info_word_select_all')}}</button>
<input type="hidden" name="p_pagina" value="1"/>
<input type="hidden" name="p_class_id" value="{{$parent['class_id']}}"/>
<input type="hidden" name="p_relation_id" value="{{$parent['rel_id']}}"/>
Expand Down Expand Up @@ -128,5 +129,9 @@
oTable.search($(this).val()).draw() ;
})
} );
function selectAll() {
$('input[name="rel_chb[]"]').prop('checked', true);
}
</script>
@endsection

0 comments on commit b5e8a50

Please sign in to comment.