mirror of
				https://github.com/firefly-iii/firefly-iii.git
				synced 2025-10-31 02:36:28 +00:00 
			
		
		
		
	Expand forms and improve validation for multi-account piggy banks
This commit is contained in:
		
							
								
								
									
										10
									
								
								resources/views/form/multi-select.twig
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										10
									
								
								resources/views/form/multi-select.twig
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,10 @@ | ||||
| <div class="{{ classes }}" id="{{ name }}_holder"> | ||||
|     <label for="{{ options.id }}" class="col-sm-4 control-label">{{ label }}</label> | ||||
|  | ||||
|     <div class="col-sm-8"> | ||||
|         {{ Html.select(name~"[]", list, selected).id(options.id).class('form-control').attribute('multiple').attribute('autocomplete','off').attribute('spellcheck','false').attribute('placeholder', options.placeholder) }} | ||||
|         {% include 'form.help' %} | ||||
|         {% include 'form.feedback' %} | ||||
|  | ||||
|     </div> | ||||
| </div> | ||||
| @@ -8,7 +8,6 @@ | ||||
|  | ||||
|     <form method="POST" action="{{ route('piggy-banks.store') }}" accept-charset="UTF-8" class="form-horizontal" id="store" enctype="multipart/form-data"> | ||||
|         <input name="_token" type="hidden" value="{{ csrf_token() }}"> | ||||
|         <input type="hidden" name="repeats" value="0"/> | ||||
|         <div class="row"> | ||||
|             <div class="col-lg-6 col-md-6 col-sm-12 col-xs-12"> | ||||
|                 <div class="box box-primary"> | ||||
| @@ -16,10 +15,10 @@ | ||||
|                         <h3 class="box-title">{{ 'mandatoryFields'|_ }}</h3> | ||||
|                     </div> | ||||
|                     <div class="box-body"> | ||||
|  | ||||
|                         {{ ExpandedForm.text('name') }} | ||||
|                         {{ AccountForm.assetAccountList('account_id', null, {label: 'saveOnAccount'|_   }) }} | ||||
|                         {{ ExpandedForm.amountNoCurrency('targetamount') }} | ||||
|                         {{ AccountForm.assetLiabilityMultiAccountList('accounts', null, {label: 'saveOnAccounts'|_   }) }} | ||||
|  | ||||
|                         {{ ExpandedForm.amountNoCurrency('target_amount') }} | ||||
|  | ||||
|                     </div> | ||||
|                 </div> | ||||
| @@ -30,7 +29,7 @@ | ||||
|                         <h3 class="box-title">{{ 'optionalFields'|_ }}</h3> | ||||
|                     </div> | ||||
|                     <div class="box-body"> | ||||
|                         {{ ExpandedForm.date('targetdate') }} | ||||
|                         {{ ExpandedForm.date('target_date') }} | ||||
|                         {{ ExpandedForm.textarea('notes', null, {helpText: trans('firefly.field_supports_markdown')} ) }} | ||||
|                         {{ ExpandedForm.file('attachments[]', {'multiple': 'multiple','helpText': trans('firefly.upload_max_file_size', {'size': uploadSize|filesize}) }) }} | ||||
|                         {{ ExpandedForm.objectGroup() }} | ||||
|   | ||||
		Reference in New Issue
	
	Block a user