@@ -86,12 +86,12 @@ public static function date( $label, $name, $value = '', $validation = '', $desc
8686 );
8787 }
8888
89- public static function select ( $ label , $ name , $ options , $ value = '' , $ validation = '' , $ description = '' , $ disabled = false , $ type = 'select ' , $ component = '' , $ props = [] )
89+ public static function select ( $ label , $ name , $ options , $ value = '' , $ validation = '' , $ description = '' , $ disabled = false , $ type = 'select ' , $ component = '' , $ props = [], $ refresh = false )
9090 {
91- return compact ( 'label ' , 'name ' , 'validation ' , 'options ' , 'value ' , 'description ' , 'disabled ' , 'type ' , 'component ' , 'props ' );
91+ return compact ( 'label ' , 'name ' , 'validation ' , 'options ' , 'value ' , 'description ' , 'disabled ' , 'type ' , 'component ' , 'props ' , ' refresh ' );
9292 }
9393
94- public static function searchSelect ( $ label , $ name , $ value = '' , $ options = [], $ validation = '' , $ description = '' , $ disabled = false , $ component = '' , $ props = [] )
94+ public static function searchSelect ( $ label , $ name , $ value = '' , $ options = [], $ validation = '' , $ description = '' , $ disabled = false , $ component = '' , $ props = [], $ refresh = false )
9595 {
9696 return self ::select (
9797 label: $ label ,
@@ -102,10 +102,17 @@ public static function searchSelect( $label, $name, $value = '', $options = [],
102102 value: $ value ,
103103 type: 'search-select ' ,
104104 component: $ component ,
105- props: $ props
105+ props: $ props ,
106+ disabled: $ disabled ,
107+ refresh: $ refresh
106108 );
107109 }
108110
111+ public static function refreshConfig ( string $ url , string $ watch , array $ data = [] )
112+ {
113+ return compact ( 'url ' , 'watch ' , 'data ' );
114+ }
115+
109116 public static function textarea ( $ label , $ name , $ value = '' , $ validation = '' , $ description = '' , $ disabled = false )
110117 {
111118 return self ::text (
@@ -240,17 +247,11 @@ public static function daterange( $label, $name, $value = '', $validation = '',
240247 );
241248 }
242249
243- public static function custom ( $ label , $ name , $ type , $ value = '' , $ validation = '' , $ description = '' , $ disabled = false , $ options = [] )
250+ public static function custom ( $ label , $ component )
244251 {
245- return self ::select (
246- label: $ label ,
247- name: $ name ,
248- validation: $ validation ,
249- description: $ description ,
250- disabled: $ disabled ,
251- options: $ options ,
252- type: $ type ,
253- value: $ value
254- );
252+ return [
253+ 'label ' => $ label ,
254+ 'component ' => $ component
255+ ];
255256 }
256257}
0 commit comments