// Update Accounting form

git-svn-id: http://dev.prestashop.com/svn/v1/branches/1.5.x@10226 b9a71923-0436-4b27-9f14-aed3839534dd
This commit is contained in:
vSchoener
2011-11-17 16:38:32 +00:00
parent 4621551acf
commit e050010261
7 changed files with 33 additions and 21 deletions
@@ -24,18 +24,6 @@
* International Registered Trademark & Property of PrestaShop SA
*}
<script type="text/javascript">
$(document).ready(function() {
$('.datepicker').datepicker({
prevText: '',
nextText: '',
dateFormat: 'yy-mm-dd'
});
});
</script>
{if $existingExport}
<div class="hint" style="display:block;">
{l s='The last export has been for this section:'}
@@ -51,10 +39,10 @@
<label for="beginDate">{l s='Begin to:'}</label>
<div class="margin-form">
<input class="datepicker" id="beginDate" type="text" value="" name="beginDate" />
<input class="datepicker" id="beginDate_{$type}" type="text" name="beginDate" value="{$begin_date}" />
</div>
<label for="endDate">{l s='End to:'}</label>
<div class="margin-form">
<input class="datepicker" id="endDate" type="text" value="" name="endDate" />
<input class="datepicker" id="endDate_{$type}" type="text" name="endDate" value="{$end_date}" />
</div>
@@ -27,14 +27,14 @@
<div class="formAccountingExport" id="block_global_export">
<fieldset>
<legend>{$title}</legend>
<form action="{$smarty.server.REQUEST_URI}" method="POST">
<form id="reconfiliation_form" action="{$smarty.server.REQUEST_URI}" method="POST">
{include file="$pathAccountExportTpl/common_form.tpl"}
<label for="clientPrefix">{l s='Journal:'}</label>
<div class="margin-form">
<input type="text" name="journal" />
<input type="text" name="journal" value="{$journal}"/>
</div>
<div class="margin-form">
<input type="submit" class="button" name="submitAccountingExportType" />
<input id="submitGlobalExport" type="submit" class="button" name="submitAccountingExportType" />
<input type="hidden" name="exportType" value="global_export"/>
</div>
</form>
@@ -40,6 +40,23 @@
});
});
$('#' + '{$defaultType}').fadeIn('fast');
$('.datepicker').each(function() {
console.log($(this));
$(this).datepicker({
prevText: '',
nextText: '',
dateFormat: 'yy-mm-dd'
});
});
$('.formAccountingExport form input[type="submit"]').each(function()
{
$(this).click(function() {
dateRegex = /^[2-9]\d{2}-\d{3}-\d{4}$/
return false;
});
});
});
</script>
@@ -27,11 +27,11 @@
<div class="formAccountingExport" id="block_reconciliation_export">
<fieldset>
<legend>{$title}</legend>
<form action="{$smarty.server.REQUEST_URI}" method="POST">
<form id="reconfiliation_form" action="{$smarty.server.REQUEST_URI}" method="POST">
{include file="$pathAccountExportTpl/common_form.tpl"}
<div class="margin-form">
<input type="submit" class="button" name="submitAccountingExportType" />
<input id="submitReconciliationExport" type="submit" class="button" name="submitAccountingExportType" />
<input type="hidden" name="exportType" value="reconciliation_export"/>
</div>
</form>