Project

General

Profile

Feature #2714 ยป weblcms_266_abe016e5a505.patch

Laurent Opprecht, 01/03/2011 15:40

View differences:

php/lib/publisher/content_object_publisher.class.php
8 8
use common\libraries\Path;
9 9
use common\libraries\Translation;
10 10
use common\libraries\Utilities;
11
use common\libraries\PlatformSetting;
11 12

  
12 13
/**
13 14
 * $Id: content_object_publisher.class.php 216 2009-11-13 14:08:06Z kariboe $
......
67 68
        }
68 69

  
69 70
        $form = new ContentObjectPublicationForm(ContentObjectPublicationForm :: TYPE_MULTI, $ids, $this->parent, true, $this->parent->get_course());
70
        if ($form->validate())
71

  
72
        $display_form = (bool)PlatformSetting :: get('display_publication_screen', 'weblcms');
73
        if ($form->validate() || !$display_form)
71 74
        {
72 75
            $publication = $form->create_content_object_publications();
73 76

  
php/settings/settings_weblcms.xml
22 22
				</options>
23 23
			</setting>
24 24
		</category>
25
		<category name="publication">
26
			<setting name="display_publication_screen" field="checkbox" default="1">
27
				<options type="static">
28
					<option name="display_publication_screen" value="1" />
29
				</options>
30
			</setting>
31
		</category>
25 32
	</settings>
26 33
</application>
resources/i18n/en.i18n
385 385
CourseMenu = "Course Menu"
386 386
CourseCatalog = "Course Catalog"
387 387
CategoryId = "Category"
388
TitularId = "Titular"
388
TitularId = "Titular"
389
DisplayPublicationScreen = "Dispay publication screen"
    (1-1/1)