本文整理汇总了PHP中Sylius\Bundle\SettingsBundle\Schema\SettingsBuilderInterface::setDefaults方法的典型用法代码示例。如果您正苦于以下问题:PHP SettingsBuilderInterface::setDefaults方法的具体用法?PHP SettingsBuilderInterface::setDefaults怎么用?PHP SettingsBuilderInterface::setDefaults使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Sylius\Bundle\SettingsBundle\Schema\SettingsBuilderInterface
的用法示例。
在下文中一共展示了SettingsBuilderInterface::setDefaults方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: function
function it_uses_callback_to_build_settings(SettingsBuilderInterface $settingsBuilder)
{
$this->beConstructedWith(function (SettingsBuilderInterface $settingsBuilder) {
$settingsBuilder->setDefaults(['foo' => 'bar']);
}, function () {
});
$settingsBuilder->setDefaults(['foo' => 'bar'])->shouldBeCalled();
$this->buildSettings($settingsBuilder);
}
示例2: buildSettings
/**
* {@inheritdoc}
*/
public function buildSettings(SettingsBuilderInterface $builder)
{
$tools = $this->getProcessedToolChain();
$builder->setDefaults(array('homepage_view' => 'activity_big', 'show_tool_shortcuts' => '', 'active_tools_on_create' => $tools, 'display_coursecode_in_courselist' => 'false', 'display_teacher_in_courselist' => 'true', 'student_view_enabled' => 'true', 'go_to_course_after_login' => 'false', 'show_navigation_menu' => 'false', 'enable_tool_introduction' => 'false', 'breadcrumbs_course_homepage' => 'course_title', 'example_material_course_creation' => 'true', 'allow_course_theme' => 'true', 'allow_users_to_create_courses' => 'true', 'show_courses_descriptions_in_catalog' => 'true', 'send_email_to_admin_when_create_course' => 'false', 'allow_user_course_subscription_by_course_admin' => 'true', 'course_validation' => 'false', 'course_validation_terms_and_conditions_url' => '', 'course_hide_tools' => [], 'scorm_cumulative_session_time' => 'true', 'courses_default_creation_visibility' => '2', 'allow_public_certificates' => 'false', 'allow_lp_return_link' => 'true', 'course_creation_use_template' => '', 'hide_scorm_export_link' => 'false', 'hide_scorm_copy_link' => 'false', 'hide_scorm_pdf_link' => 'false', 'course_catalog_published' => 'false', 'course_images_in_courses_list' => 'false'))->setAllowedTypes(array('homepage_view' => array('string'), 'show_tool_shortcuts' => array('string'), 'active_tools_on_create' => array('array'), 'course_hide_tools' => array('array'), 'display_coursecode_in_courselist' => array('string'), 'display_teacher_in_courselist' => array('string'), 'student_view_enabled' => array('string')))->setTransformer('active_tools_on_create', new ArrayToIdentifierTransformer())->setTransformer('course_hide_tools', new ArrayToIdentifierTransformer());
}
示例3: buildSettings
/**
* {@inheritdoc}
*/
public function buildSettings(SettingsBuilderInterface $builder)
{
$builder->setDefaults(array('header_extra_content' => '', 'footer_extra_content' => ''))->setAllowedTypes(array('header_extra_content' => array('string'), 'footer_extra_content' => array('string')));
}
示例4: buildSettings
/**
* {@inheritdoc}
*/
public function buildSettings(SettingsBuilderInterface $builder)
{
$builder->setDefaults(array('enabled' => ''))->setAllowedTypes(array('enabled' => array('string')));
}
示例5: buildSettings
/**
* {@inheritdoc}
*/
public function buildSettings(SettingsBuilderInterface $builder)
{
$builder->setDefaults(array('decode_utf8' => 'false', 'messaging_allow_send_push_notification' => 'false', 'messaging_gdc_project_number' => '', 'messaging_gdc_api_key' => ''))->setAllowedTypes(array('messaging_gdc_project_number' => ['string'], 'messaging_gdc_api_key' => ['string']));
}
示例6: buildSettings
/**
* {@inheritdoc}
*/
public function buildSettings(SettingsBuilderInterface $builder)
{
$builder->setDefaults(array('exercise_min_score' => '0', 'exercise_max_score' => '0', 'enable_quiz_scenario' => ''))->setAllowedTypes(array('exercise_min_score' => array('string'), 'exercise_max_score' => array('string'), 'enable_quiz_scenario' => array('string')));
}
示例7: buildSettings
/**
* {@inheritdoc}
*/
public function buildSettings(SettingsBuilderInterface $builder)
{
$builder->setDefaults(array('institution' => 'Chamilo.org', 'institution_url' => 'http://www.chamilo.org', 'site_name' => 'Chamilo site', 'timezone' => 'Europe/Paris', 'theme' => 'chamilo', 'gravatar_enabled' => 'false', 'gravatar_type' => 'mm', 'gamification_mode' => ' ', 'order_user_list_by_official_code' => 'false', 'cookie_warning' => 'false', 'donotlistcampus' => 'false', 'catalog_show_courses_sessions' => '0', 'course_catalog_hide_private' => 'false'))->setAllowedTypes(array('institution' => array('string'), 'institution_url' => array('string'), 'site_name' => array('string'), 'timezone' => array('string'), 'gravatar_enabled' => array('string'), 'gravatar_type' => array('string')));
}
示例8: buildSettings
public function buildSettings(SettingsBuilderInterface $builder)
{
$builder->setDefaults(['facebook' => null, 'twitter' => null, 'youtube' => null, 'google_plus' => null, 'linkedin' => null, 'pinterest' => null, 'instagram' => null]);
}
示例9: buildSettings
/**
* {@inheritdoc}
*/
public function buildSettings(SettingsBuilderInterface $builder)
{
$builder->setDefaults(array('filter_terms' => '', 'allow_browser_sniffer' => '', 'admins_can_set_users_pass' => ''))->setAllowedTypes(array('filter_terms' => array('string'), 'allow_browser_sniffer' => array('string'), 'admins_can_set_users_pass' => array('string')));
}
示例10: buildSettings
/**
* {@inheritdoc}
*/
public function buildSettings(SettingsBuilderInterface $builder)
{
$builder->setDefaults(array('gradebook_enable' => '', 'gradebook_score_display_coloring' => '', 'gradebook_score_display_custom' => '', 'gradebook_score_display_colorsplit' => '', 'gradebook_score_display_upperlimit' => '', 'gradebook_number_decimals' => '0', 'allow_hr_skills_management' => '', 'teachers_can_change_score_settings' => '', 'teachers_can_change_grade_model_settings' => '', 'gradebook_enable_grade_model' => '', 'gradebook_default_weight' => '100', 'gradebook_locking_enabled' => '', 'gradebook_default_grade_model_id' => '', 'gradebook_show_percentage_in_rep' => ''))->setAllowedTypes(array('gradebook_enable' => array('string'), 'gradebook_number_decimals' => array('string'), 'gradebook_default_weight' => array('string')));
}
示例11: buildSettings
/**
* {@inheritdoc}
*/
public function buildSettings(SettingsBuilderInterface $builder)
{
$builder->setDefaults(array('allow_social_tool' => '', 'allow_students_to_create_groups_in_social' => ''))->setAllowedTypes(array('allow_social_tool' => array('string'), 'allow_students_to_create_groups_in_social' => array('string')));
}
示例12: buildSettings
/**
* {@inheritdoc}
*/
public function buildSettings(SettingsBuilderInterface $builder)
{
$builder->setDefaults(array('gradebook_enable' => 'true', 'gradebook_score_display_custom' => 'false', 'gradebook_score_display_colorsplit' => '50', 'gradebook_score_display_upperlimit' => 'false', 'gradebook_number_decimals' => '0', 'teachers_can_change_score_settings' => 'true', 'teachers_can_change_grade_model_settings' => 'true', 'gradebook_enable_grade_model' => 'false', 'gradebook_default_weight' => '100', 'gradebook_locking_enabled' => 'false', 'gradebook_default_grade_model_id' => '', 'gradebook_show_percentage_in_reports' => '', 'my_display_coloring' => 'false', 'student_publication_to_take_in_gradebook' => 'first', 'gradebook_detailed_admin_view' => 'false', 'openbadges_backpack' => 'https://backpack.openbadges.org/'))->setAllowedTypes(array('gradebook_enable' => array('string'), 'gradebook_number_decimals' => array('string'), 'gradebook_default_weight' => array('string'), 'student_publication_to_take_in_gradebook' => array('string'), 'gradebook_detailed_admin_view' => array('string')));
}
示例13: buildSettings
/**
* {@inheritdoc}
*/
public function buildSettings(SettingsBuilderInterface $builder)
{
$builder->setDefaults(array('allow_email_editor' => '', 'math_mimetex' => '', 'math_asciimathML' => '', 'enabled_asciisvg' => '', 'include_asciimathml_script' => '', 'youtube_for_students' => '', 'block_copy_paste_for_students' => '', 'more_buttons_maximized_mode' => '', 'enabled_wiris' => '', 'allow_spellcheck' => '', 'force_wiki_paste_as_plain_text' => '', 'enabled_googlemaps' => '', 'enabled_imgmap' => '', 'enabled_support_svg' => '', 'enabled_insertHtml' => '', 'enabled_support_pixlr' => '', 'htmlpurifier_wiki' => '', 'enable_iframe_inclusion' => ''))->setAllowedTypes(array());
}
示例14: buildSettings
/**
* {@inheritdoc}
*/
public function buildSettings(SettingsBuilderInterface $builder)
{
$builder->setDefaults(['enabled' => false])->setAllowedTypes(['enabled' => ['bool']]);
}
示例15: buildSettings
/**
* {@inheritdoc}
*/
public function buildSettings(SettingsBuilderInterface $builder)
{
$builder->setDefaults(array('registration' => '', 'allow_registration' => '', 'allow_registration_as_teacher' => '', 'allow_lostpassword' => '', 'page_after_login' => '', 'extendedprofile_registration' => '', 'allow_terms_conditions' => '', 'student_page_after_login' => '', 'teacher_page_after_login' => '', 'drh_page_after_login' => '', 'sessionadmin_page_after_login' => '', 'student_autosubscribe' => '', 'teacher_autosubscribe' => '', 'drh_autosubscribe' => '', 'sessionadmin_autosubscribe' => '', 'platform_unsubscribe_allowed' => ''))->setAllowedTypes(array('registration' => array('string'), 'allow_registration' => array('string'), 'allow_registration_as_teacher' => array('string'), 'allow_lostpassword' => array('string')));
}