change view mode ++ type filters

Signed-off-by: bachy <git@g-u-i.net>
This commit is contained in:
bachy
2012-10-30 18:03:56 +01:00
parent 3faebabce1
commit 65ea77dea2
7 changed files with 243 additions and 76 deletions

View File

@@ -33,7 +33,7 @@ function materio_search_api_settings(){
$form['availableviewmodes'] = array(
'#type'=>'select',
'#options'=>$viewmode_options,
'#default_value' => variable_get('availableviewmodes', -1),
'#default_value' => variable_get('availableviewmodes', array()),
'#title' => t('Availble View modes'),
'#multiple' => true,
);
@@ -45,5 +45,16 @@ function materio_search_api_settings(){
'#title' => t('Defalut View mode'),
);
foreach (variable_get('availableviewmodes', array()) as $viewmode => $value) {
$form[$viewmode.'_limite'] = array(
'#type'=>'textfield',
'#size'=>5,
'#default_value' => variable_get($viewmode.'_limite', '10'),
'#title' => t('@vm limite', array('@vm'=>$viewmode)),
);
}
return system_settings_form($form);
}