This commit is contained in:
Franck Allimant
2014-01-21 14:51:43 +01:00
9 changed files with 14 additions and 10 deletions

View File

@@ -159,7 +159,7 @@ abstract class BaseCachedFile extends BaseAction
// Create directory (recursively) if it does not exists.
if ($create_if_not_exists && !is_dir($path)) {
if (!@mkdir($path, 0777, true)) {
throw new \RuntimeException(sprintf("Failed to create %s/%s file in cache directory", $cache_base));
throw new \RuntimeException(sprintf("Failed to create %s file in cache directory", $path));
}
}

View File

@@ -123,10 +123,11 @@ class Accessory extends Product
foreach ($results as $loopResultRow) {
$accessoryProductId = $loopResultRow->get('ID');
\Thelia\Log\Tlog::getInstance()->notice($this->accessoryId);
$loopResultRow
->set("ID" , $this->accessoryId[$accessoryProductId])
->set("POSITION", $this->accessoryPosition[$accessoryProductId])
->set("ACCESSORY_ID", $accessoryProductId)
;
}

View File

@@ -166,6 +166,7 @@ class AssociatedContent extends Content
->set("ID" , $this->contentId[$relatedContentId])
->set("CONTENT_ID", $relatedContentId)
->set("POSITION" , $this->contentPosition[$relatedContentId])
;
}

View File

@@ -267,7 +267,7 @@ class Document extends BaseI18nLoop implements PropelSearchLoopInterface
$loopResult->addRow($loopResultRow);
} catch (\Exception $ex) {
// Ignore the result and log an error
Tlog::getInstance()->addError("Failed to process document in document loop: ", $this->args);
Tlog::getInstance()->addError(sprintf("Failed to process document in document loop: %s", $ex->getMessage()), $this->args);
}
}

View File

@@ -105,7 +105,7 @@
<td class="actions">
<div class="btn-group">
{loop type="auth" name="can_create" role="ADMIN" resources="admin.product" access="UPDATE"}
<a class="btn btn-default btn-xs delete-content" title="{intl l='Delete this content'}" href="#delete_content_dialog" data-id="{$ID}" data-toggle="modal">
<a class="btn btn-default btn-xs delete-content" title="{intl l='Delete this content'}" href="#delete_content_dialog" data-id="{$CONTENT_ID}" data-toggle="modal">
<span class="glyphicon glyphicon-trash"></span>
</a>
{/loop}
@@ -226,7 +226,7 @@
<td class="actions">
<div class="btn-group">
{loop type="auth" name="can_create" role="ADMIN" resources="admin.product" access="UPDATE"}
<a class="btn btn-default btn-xs delete-accessory" title="{intl l='Delete this accessory'}" href="#delete_accessory_dialog" data-id="{$ID}" data-toggle="modal">
<a class="btn btn-default btn-xs delete-accessory" title="{intl l='Delete this accessory'}" href="#delete_accessory_dialog" data-id="{$ACCESSORY_ID}" data-toggle="modal">
<span class="glyphicon glyphicon-trash"></span>
</a>
{/loop}
@@ -523,7 +523,7 @@ $(function() {
$('.accessoryPositionChange').editable({
type : 'text',
title : '{intl l="Enter new accessory position"}',
title : "{intl l="Enter new accessory position"}",
mode : 'popup',
inputclass : 'input-mini',
placement : 'left',
@@ -541,7 +541,7 @@ $(function() {
$('.contentPositionChange').editable({
type : 'text',
title : '{intl l="Enter new content position"}',
title : "{intl l="Enter new content position"}",
mode : 'popup',
inputclass : 'input-mini',
placement : 'left',

View File

@@ -228,7 +228,7 @@
<td class="actions">
<div class="btn-group">
{loop type="auth" name="can_create" role="ADMIN" resource="admin.configuration.category" access="UPDATE"}
<a class="btn btn-default btn-xs delete-content" title="{intl l='Delete this content'}" href="#delete_content_dialog" data-id="{$ID}" data-toggle="modal">
<a class="btn btn-default btn-xs delete-content" title="{intl l='Delete this content'}" href="#delete_content_dialog" data-id="{$CONTENT_ID}" data-toggle="modal">
<span class="glyphicon glyphicon-trash"></span>
</a>
{/loop}

View File

@@ -152,7 +152,7 @@
</div>
</div>
</div>
{/block}
{block name="javascript-initialization"}
{javascripts file='assets/js/dropzone.js'}
<script src="{$asset_url}"></script>

View File

@@ -154,7 +154,9 @@ $(function() {
$('.nav-tabs a[data-href]').on('shown.bs.tab', function(ev) {
var $this = $(this);
$($this.attr('href')).load($this.data('href'), function(ev) {
eval($this.data('callback') + '();');
if($this.data('callback')) {
eval($this.data('callback') + '();');
}
});
});

0
web/install/I18n/en_US.php Normal file → Executable file
View File