Index: classes/class.tx_staticdstools.php
===================================================================
--- classes/class.tx_staticdstools.php (revision 29771)
+++ classes/class.tx_staticdstools.php (working copy)
@@ -29,6 +29,12 @@
*/
class tx_staticDStools {
+ /**
+ * Step for the wizard. Can be manipulated by internal function
+ *
+ * @var int $step
+ */
+ protected $step = 0;
/**
*
@@ -36,14 +42,14 @@
* @param object Instance of the class t3lib_tsStyleConfig
*/
function staticDsWizard($params, $pObj) {
- $step = t3lib_div::_GP('dsWizardDoIt') ? intval(t3lib_div::_GP('dsWizardStep')) : 0;
+ $this->step = t3lib_div::_GP('dsWizardDoIt') ? intval(t3lib_div::_GP('dsWizardStep')) : 0;
$conf = unserialize($GLOBALS['TYPO3_CONF_VARS']['EXT']['extConf']['templavoila']);
- $title = $GLOBALS['LANG']->sL('LLL:EXT:templavoila/res1/language/template_conf.xml:staticDS.wizard.title.' . $step);
- $description = $GLOBALS['LANG']->sL('LLL:EXT:templavoila/res1/language/template_conf.xml:staticDS.wizard.description.' . $step);
+ $title = $GLOBALS['LANG']->sL('LLL:EXT:templavoila/res1/language/template_conf.xml:staticDS.wizard.title.' . $this->step);
+ $description = $GLOBALS['LANG']->sL('LLL:EXT:templavoila/res1/language/template_conf.xml:staticDS.wizard.description.' . $this->step);
$out = '
' . htmlspecialchars($title) . '
';
- switch($step) {
+ switch($this->step) {
case 1:
$ok = array(TRUE, TRUE);
if (t3lib_div::_GP('dsWizardDoIt')) {
@@ -63,9 +69,11 @@
$controls .= $this->getDsRecords($conf['staticDS.']);
}
}
- $submitText = $conf['staticDS.']['enable'] ? $GLOBALS['LANG']->sL('LLL:EXT:templavoila/res1/language/template_conf.xml:staticDS.wizard.submit3') : $GLOBALS['LANG']->sL('LLL:EXT:templavoila/res1/language/template_conf.xml:staticDS.wizard.submit2');
- $controls .= '
- ';
+ if ($this->step < 3) {
+ $submitText = $conf['staticDS.']['enable'] ? $GLOBALS['LANG']->sL('LLL:EXT:templavoila/res1/language/template_conf.xml:staticDS.wizard.submit3') : $GLOBALS['LANG']->sL('LLL:EXT:templavoila/res1/language/template_conf.xml:staticDS.wizard.submit2');
+ $controls .= '
+ ';
+ }
break;
default:
$controls .= '
@@ -101,6 +109,7 @@
$writeDsIds = array();
$writeIds = t3lib_div::_GP('staticDSwizard');
$options = t3lib_div::_GP('staticDSwizardoptions');
+ $checkAll = t3lib_div::_GP('sdw-checkall');
if (count($writeIds)) {
$writeDsIds = array_keys($writeIds);
@@ -121,7 +130,7 @@
' . $GLOBALS['LANG']->sL('LLL:EXT:templavoila/res1/language/template_conf.xml:staticDS.wizard.usage') . ' |
- |
+
';
foreach($rows as $row) {
$dirPath = PATH_site . ($row['scope'] == 2 ? $conf['path_fce'] : $conf['path_page']);
@@ -167,6 +176,7 @@
// delete DS records
$GLOBALS['TYPO3_DB']->exec_UPDATEquery('tx_templavoila_datastructure', 'uid=' . $row['uid'], array('deleted' => 1));
$updateMessage = $GLOBALS['LANG']->sL('LLL:EXT:templavoila/res1/language/template_conf.xml:staticDS.wizard.updated');
+ $this->step = 3;
}
@@ -180,7 +190,7 @@
if (count($writeDsIds) && in_array($row['uid'], $writeDsIds)) {
$out .= 'written to "' . $outPath . '" | ';
} else {
- $out .= ' | ';
+ $out .= ' | ';
}
$out .= '';
}
@@ -188,7 +198,7 @@
if ($conf['enable']) {
if ($updateMessage) {
- $out .= '' . $updateMessage . '
' . $GLOBALS['LANG']->sL('LLL:EXT:templavoila/res1/language/template_conf.xml:staticDS.wizard.clearcache') . '
';
+ $out .= '' . $updateMessage . '
' . $GLOBALS['LANG']->sL('LLL:EXT:templavoila/res1/language/template_conf.xml:staticDS.wizard.clearcache') . '
';
} else {
$out .= '' . $GLOBALS['LANG']->sL('LLL:EXT:templavoila/res1/language/template_conf.xml:staticDS.wizard.description2.1') . '
';
$out .= '
Index: res1/language/template_conf.xml
===================================================================
--- res1/language/template_conf.xml (revision 29771)
+++ res1/language/template_conf.xml (working copy)
@@ -24,7 +24,7 @@
-
+