Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
marco76tv committed Jun 3, 2024
1 parent 0b4ef0d commit f6eff5a
Show file tree
Hide file tree
Showing 4 changed files with 56 additions and 56 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -33,3 +33,4 @@ package-lock.json
.php-cs-fixer.cache
node_modules
.php-cs-fixer.cache
.php-cs-fixer.cache
4 changes: 4 additions & 0 deletions .php-cs-fixer.cache
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<<<<<<< HEAD
=======
{"php":"8.3.7","version":"3.52.1","indent":" ","lineEnding":"\n","rules":{"align_multiline_comment":true,"array_syntax":{"syntax":"short"},"backtick_to_shell_exec":true,"binary_operator_spaces":true,"blank_line_before_statement":{"statements":["return"]},"braces_position":{"allow_single_line_anonymous_functions":true,"allow_single_line_empty_anonymous_classes":true},"class_attributes_separation":{"elements":{"method":"one"}},"class_definition":true,"class_reference_name_casing":true,"clean_namespace":true,"concat_space":true,"declare_parentheses":true,"echo_tag_syntax":true,"empty_loop_body":{"style":"braces"},"empty_loop_condition":true,"fully_qualified_strict_types":true,"function_declaration":true,"general_phpdoc_tag_rename":{"replacements":{"inheritDocs":"inheritDoc"}},"global_namespace_import":{"import_classes":false,"import_constants":false,"import_functions":false},"include":true,"increment_style":true,"integer_literal_case":true,"lambda_not_used_import":true,"linebreak_after_opening_tag":true,"magic_constant_casing":true,"magic_method_casing":true,"method_argument_space":{"on_multiline":"ignore"},"native_function_casing":true,"native_type_declaration_casing":true,"no_alias_language_construct_call":true,"no_alternative_syntax":true,"no_binary_string":true,"no_blank_lines_after_phpdoc":true,"no_empty_comment":true,"no_empty_phpdoc":true,"no_empty_statement":true,"no_extra_blank_lines":{"tokens":["attribute","case","continue","curly_brace_block","default","extra","parenthesis_brace_block","square_brace_block","switch","throw","use"]},"no_leading_namespace_whitespace":true,"no_mixed_echo_print":true,"no_multiline_whitespace_around_double_arrow":true,"no_null_property_initialization":true,"no_short_bool_cast":true,"no_singleline_whitespace_before_semicolons":true,"no_spaces_around_offset":true,"no_superfluous_phpdoc_tags":{"allow_hidden_params":true,"remove_inheritdoc":true},"no_trailing_comma_in_singleline":true,"no_unneeded_braces":{"namespaces":true},"no_unneeded_control_parentheses":{"statements":["break","clone","continue","echo_print","others","return","switch_case","yield","yield_from"]},"no_unneeded_import_alias":true,"no_unset_cast":true,"no_unused_imports":true,"no_useless_concat_operator":true,"no_useless_nullsafe_operator":true,"no_whitespace_before_comma_in_array":true,"normalize_index_brace":true,"nullable_type_declaration":true,"nullable_type_declaration_for_default_null_value":true,"object_operator_without_whitespace":true,"operator_linebreak":{"only_booleans":true},"ordered_imports":true,"ordered_types":{"null_adjustment":"always_last","sort_algorithm":"none"},"php_unit_fqcn_annotation":true,"php_unit_method_casing":true,"phpdoc_align":true,"phpdoc_annotation_without_dot":true,"phpdoc_indent":true,"phpdoc_inline_tag_normalizer":true,"phpdoc_no_access":true,"phpdoc_no_alias_tag":true,"phpdoc_no_package":true,"phpdoc_no_useless_inheritdoc":true,"phpdoc_order":true,"phpdoc_return_self_reference":true,"phpdoc_scalar":true,"phpdoc_separation":{"groups":[["Annotation","NamedArgumentConstructor","Target"],["author","copyright","license"],["category","package","subpackage"],["property","property-read","property-write"],["deprecated","link","see","since"]]},"phpdoc_single_line_var_spacing":true,"phpdoc_summary":true,"phpdoc_tag_type":{"tags":{"inheritDoc":"inline"}},"phpdoc_to_comment":true,"phpdoc_trim":true,"phpdoc_trim_consecutive_blank_line_separation":true,"phpdoc_types":true,"phpdoc_types_order":{"null_adjustment":"always_last","sort_algorithm":"none"},"phpdoc_var_without_name":true,"semicolon_after_instruction":true,"simple_to_complex_string_variable":true,"single_class_element_per_statement":true,"single_import_per_statement":true,"single_line_comment_spacing":true,"single_line_comment_style":{"comment_types":["hash"]},"single_line_throw":true,"single_quote":true,"single_space_around_construct":true,"space_after_semicolon":{"remove_in_empty_for_expressions":true},"standardize_increment":true,"standardize_not_equals":true,"statement_indentation":{"stick_comment_to_next_continuous_control_statement":true},"switch_continue_to_break":true,"trailing_comma_in_multiline":true,"trim_array_spaces":true,"type_declaration_spaces":true,"types_spaces":true,"unary_operator_spaces":true,"whitespace_after_comma_in_array":true,"yoda_style":true,"array_indentation":true,"cast_spaces":true,"blank_line_after_opening_tag":true,"blank_line_between_import_groups":true,"blank_lines_before_namespace":true,"compact_nullable_type_declaration":true,"declare_equal_normalize":true,"lowercase_cast":true,"lowercase_static_reference":true,"new_with_parentheses":true,"no_blank_lines_after_class_opening":true,"no_leading_import_slash":true,"no_whitespace_in_blank_line":true,"ordered_class_elements":{"order":["use_trait"]},"return_type_declaration":true,"short_scalar_cast":true,"single_trait_insert_per_statement":true,"ternary_operator_spaces":true,"visibility_required":true,"blank_line_after_namespace":true,"constant_case":true,"control_structure_braces":true,"control_structure_continuation_position":true,"elseif":true,"indentation_type":true,"line_ending":true,"lowercase_keywords":true,"no_break_comment":true,"no_closing_tag":true,"no_multiple_statements_per_line":true,"no_space_around_double_colon":true,"no_spaces_after_function_name":true,"no_trailing_whitespace":true,"no_trailing_whitespace_in_comment":true,"single_blank_line_at_eof":true,"single_line_after_imports":true,"spaces_inside_parentheses":true,"switch_case_semicolon_to_colon":true,"switch_case_space":true,"encoding":true,"full_opening_tag":true,"function_typehint_space":true,"declare_strict_types":true,"combine_consecutive_unsets":true,"not_operator_with_successor_space":true,"braces":{"position_after_functions_and_oop_constructs":"same"}},"hashes":{"Filament\/Pages\/Dashboard.php":"ad9883bc49f1cd9393b14a494753f2fc","Filament\/Pages\/DashboardV2.php":"001e298982230bbd05b3d7850487ef70","Filament\/Resources\/MixedChartResource.php":"789d4078fec20855aeb74b20b73f9abe","Filament\/Resources\/ChartResource.php":"2578aa8e9b79c7bae68f7bf322c2b1bc","Filament\/Resources\/ChartResource\/Pages\/ListCharts.php":"7a217761f0a81a3df6447a8b9401564e","Filament\/Resources\/ChartResource\/Pages\/EditChart.php":"2339f74a775662f9bd116b7f0410e345","Filament\/Resources\/ChartResource\/Pages\/CreateChart.php":"dffa6431f0e95bac0ea5662d2fd79a06","Filament\/Resources\/MixedChartResource\/Pages\/CreateMixedChart.php":"6cfec52d133cb20024a5a9fde74976ec","Filament\/Resources\/MixedChartResource\/Pages\/EditMixedChart.php":"a486e07b57520e1bbdcbec0f99cb32fc","Filament\/Resources\/MixedChartResource\/Pages\/ListMixedCharts.php":"c13fe6e455a88e4edc44ee2341fbf4f5","Filament\/Widgets\/Samples\/Sample01Chart.php":"9a9f43cbf4d0d6982ecb3362484f1854","Filament\/Widgets\/Samples\/Sample02Chart.php":"377480d626e4c1ebe767f3400d7861a4","Filament\/Widgets\/Samples\/Bar01Chart.php":"8a8a90a24581ea4313d343d32a26c97e","Filament\/Widgets\/Samples\/Doughnut01Chart.php":"fe939dfcef2a3451ca04310e87c2a543","Filament\/Widgets\/Samples\/OverlookWidget.php":"a20a294ce99549cec9d2888c406d70eb","Filament\/Widgets\/Samples\/Sample03Chart.php":"4e49a27a421687792bbe0f2078e72963","Filament\/Widgets\/Samples\/Bar02Chart.php":"185a010ebe53b35f91ab75ab2d9ab09e","docs\/listeners\/GenerateSitemap.php":"51f5bd441bbdaf816b4b0c5511a36002","docs\/config.production.php":"0389bfdb2066feea5487831e25c2aa1b","docs\/navigation.php":"4b48df06bfed09cf256c9ffa7a2346c0","docs\/bootstrap.php":"08c7c136892cf6aadd94bcdb6f64ca34","docs\/config.php":"43ebe437c536ee0f85d469f4394029c3","rector.php":"e8d5ae2ab48e7a7275a12ee3103c6f96","Datas\/AnswersChartData.php":"1c9588cd7e02e5e5ab69ffb990627ca5","Datas\/ChartData.php":"28faf06730a2c72db56ad138b1f5a3e9","Datas\/AnswerData.php":"116e4dba82ee49cbc2c6a8f3e821cebd","Config\/config.php":"d7c93a3ee9796c628b2b77f689e12461","Providers\/Filament\/AdminPanelProvider.php":"a28d14033c186ee7623bfe29e9a942d1","Providers\/RouteServiceProvider.php":"c62b9048288ce5bf3cd9e487014582c6","Providers\/ChartServiceProvider.php":"382e54a95faa1de143c4c36967305e30","Tables\/Columns\/ChartColumn.php":"c0bab38daad7136f150e7a36799201ba","Actions\/JpGraph\/V1\/Bar2Action.php":"ce0e56ccbc6cdef5d96c1c0f4468e501","Actions\/JpGraph\/V1\/LineSubQuestionAction.php":"f064dc921a696826b08ca922c5546ab0","Actions\/JpGraph\/V1\/Bar3Action.php":"2601958570abdb3692824b3f78cf42a9","Actions\/JpGraph\/V1\/PieAvgAction.php":"a7f4b5c50121d51fbdedc29849e0a96e","Actions\/JpGraph\/V1\/Horizbar1Action.php":"b31911a89167070252022dc28ab5eb95","Actions\/JpGraph\/V1\/Pie1Action.php":"f436995c704e251e7381e12b04b05ad3","Actions\/JpGraph\/ApplyGraphStyleAction.php":"2403d8cc39b442e2cdedb4aae97c55f2","Actions\/JpGraph\/ApplyPlotStyleAction.php":"f7445db56c54c924b537051c83787bcf","Actions\/JpGraph\/GetGraphAction.php":"37b36c1f9b821f9c12d56ad993937cb0","Actions\/Chart\/GetFontFamilyOptions.php":"3c7b5576bf288b7cc8b7cf77885ffe5b","Actions\/Chart\/GetTypeOptions.php":"f520c3f5a322ba7ac2045bbb6bf6f2e6","Actions\/Chart\/GetFontStyleOptions.php":"0e3183628f3e8e7a81c90c8c72861750","Models\/MixedChart.php":"0f57e02b2ffaf86296072707ad0a0208","Models\/Chart.php":"63e54cda41a8842b276864349c3ac17f","Models\/BaseModel.php":"e89cb52e72e667fbbd8264f6b8de3b27","Routes\/web.php":"4262ac35cd0de71602cf82e5679fcae8","Routes\/api.php":"a94e2d482ee54ca0a76d36db7c81b94b","phpinsights.php":"a903fc759ac88dad061accf0899a2622","Database\/Seeders\/ChartDatabaseSeeder.php":"e9a0cbed13c138e24cd6a3d2722d2507","Database\/Factories\/ChartFactory.php":"f9b38dc8b3f10a616f015eaa9b02e0e3","Database\/Factories\/MixedChartFactory.php":"2e383b7e1e9fd0b2fb0a57bb2338a820"}}
>>>>>>> 9d95fd1 (Dusting)
106 changes: 51 additions & 55 deletions Filament/Resources/ChartResource.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,23 +4,23 @@

namespace Modules\Chart\Filament\Resources;

use Filament\Forms\Form;
use Filament\Tables\Table;
use Modules\Chart\Models\Chart;
use Filament\Resources\Resource;
use Filament\Forms\Components\Select;
use Filament\Forms\Components\Toggle;
use Filament\Tables\Actions\EditAction;
// use Modules\Chart\Filament\Resources\ChartResource\RelationManagers;
use Filament\Tables\Columns\TextColumn;
// use Filament\Forms;
use Filament\Forms\Components\TextInput;
use Filament\Forms\Components\Toggle;
use Filament\Forms\Form;
use Filament\Resources\Resource;
use Filament\Tables\Actions\BulkActionGroup;
use Filament\Tables\Actions\DeleteBulkAction;
// use Modules\Chart\Filament\Resources\ChartResource\RelationManagers;
use Filament\Tables\Actions\EditAction;
// use Filament\Forms;
use Filament\Tables\Columns\TextColumn;
use Filament\Tables\Table;
use Modules\Chart\Actions\Chart\GetTypeOptions;
use Modules\Chart\Filament\Resources\ChartResource\Pages\CreateChart;
use Modules\Chart\Filament\Resources\ChartResource\Pages\EditChart;
use Modules\Chart\Filament\Resources\ChartResource\Pages\ListCharts;
use Modules\Chart\Filament\Resources\ChartResource\Pages\CreateChart;
use Modules\Chart\Models\Chart;

// use Illuminate\Database\Eloquent\Builder;
// use Illuminate\Database\Eloquent\SoftDeletingScope;
Expand All @@ -34,49 +34,48 @@ class ChartResource extends Resource
public static function form(Form $form): Form
{
return $form
->schema([
Select::make('type')->options(app(GetTypeOptions::class)->execute()),
Select::make('group_by')->options([null => '---', 'date:o-W' => 'Settimanale', 'date:Y-M' => 'Mensile', 'date:Y-M-d' => 'Giornaliero', 'field:Q41' => 'field:Q41']),
Select::make('sort_by')->options([null => '---', 'date:o-W' => 'Settimanale', 'date:Y-m' => 'Mensile', 'date:Y-m-d' => 'Giornaliero', '_value' => '_value', 'field:Q41' => 'field:Q41']),
TextInput::make('width'),
TextInput::make('height'),
Toggle::make('show_box')->inline(false),

// Forms\Components\TextInput::make('bg_color'),

Select::make('font_family')->options([
10 => 'FF_COURIER',
11 => 'FF_VERDANA',
12 => 'FF_TIMES',
14 => 'FF_COMIC',
15 => 'FF_ARIAL',
16 => 'FF_GEORGIA',
17 => 'FF_TREBUCHE',
// 18 => 'FF_COLIBRI',
]),
Select::make('font_style')->options([
9001 => 'FS_NORMAL',
9002 => 'FS_BOLD',
9003 => 'FS_ITALIC',
// 9004 => 'FS_BOLDIT',
9004 => 'FS_BOLDITALIC',
]),
Select::make('font_size')->options([
'8' => '8',
'10' => '10',
'12' => '12',
'14' => '14',
'16' => '16',
'18' => '18',
]),

// Forms\Components\TextInput::make('backtop'),
// Forms\Components\TextInput::make('backbottom'),
// Forms\Components\TextInput::make('backleft'),
// Forms\Components\TextInput::make('backright'),
// Forms\Components\TextInput::make('font_size_question'),
->schema([
Select::make('type')->options(app(GetTypeOptions::class)->execute()),
Select::make('group_by')->options([null => '---', 'date:o-W' => 'Settimanale', 'date:Y-M' => 'Mensile', 'date:Y-M-d' => 'Giornaliero', 'field:Q41' => 'field:Q41']),
Select::make('sort_by')->options([null => '---', 'date:o-W' => 'Settimanale', 'date:Y-m' => 'Mensile', 'date:Y-m-d' => 'Giornaliero', '_value' => '_value', 'field:Q41' => 'field:Q41']),
TextInput::make('width'),
TextInput::make('height'),
Toggle::make('show_box')->inline(false),

// Forms\Components\TextInput::make('bg_color'),

Select::make('font_family')->options([
10 => 'FF_COURIER',
11 => 'FF_VERDANA',
12 => 'FF_TIMES',
14 => 'FF_COMIC',
15 => 'FF_ARIAL',
16 => 'FF_GEORGIA',
17 => 'FF_TREBUCHE',
// 18 => 'FF_COLIBRI',
]),
Select::make('font_style')->options([
9001 => 'FS_NORMAL',
9002 => 'FS_BOLD',
9003 => 'FS_ITALIC',
// 9004 => 'FS_BOLDIT',
9004 => 'FS_BOLDITALIC',
]),
Select::make('font_size')->options([
'8' => '8',
'10' => '10',
'12' => '12',
'14' => '14',
'16' => '16',
'18' => '18',
]),

]);
// Forms\Components\TextInput::make('backtop'),
// Forms\Components\TextInput::make('backbottom'),
// Forms\Components\TextInput::make('backleft'),
// Forms\Components\TextInput::make('backright'),
// Forms\Components\TextInput::make('font_size_question'),
]);
}

public static function table(Table $table): Table
Expand All @@ -92,9 +91,6 @@ public static function table(Table $table): Table
TextColumn::make('font_family'),
TextColumn::make('font_style'),
TextColumn::make('font_size'),



])
->filters([
])
Expand Down
1 change: 0 additions & 1 deletion Filament/Widgets/Samples/OverlookWidget.php
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,6 @@ public function getData(): array
'url' => $res->getUrl('index'),
];
}

})
->filter()
// ->when($plugin->shouldSortAlphabetical(), fn ($collection) => $collection->sortBy('name'))
Expand Down

0 comments on commit f6eff5a

Please sign in to comment.