keeping filter and pagination when saving OrderJournal
This commit is contained in:
@@ -223,6 +223,10 @@
|
||||
<div id="new-journal-<?=$order->id?>" class="card-body hidden">
|
||||
<form method="post" action="<?=self::getUrl("OrderJournal", "save")?>">
|
||||
<input type="hidden" name="order_id" value="<?=$order->id?>" />
|
||||
<input type="hidden" name="s" value="<?=$pagination['start']?>" />
|
||||
<?php foreach($filter as $n => $v): ?>
|
||||
<input type="hidden" name="filter[<?=$n?>]" value="<?=$v?>" />
|
||||
<?php endforeach; ?>
|
||||
<textarea name="text" class="form-control mb-2" style="height:120px;"></textarea>
|
||||
<button class="btn btn-sm btn-primary" type="submit"><i class="fas fa-save"></i> Speichern</button>
|
||||
</form>
|
||||
@@ -550,6 +554,10 @@
|
||||
<div id="new-journal-<?=$order->id?>" class="card-body hidden">
|
||||
<form method="post" action="<?=self::getUrl("OrderJournal", "save")?>">
|
||||
<input type="hidden" name="order_id" value="<?=$order->id?>" />
|
||||
<input type="hidden" name="s" value="<?=$pagination['start']?>" />
|
||||
<?php foreach($filter as $n => $v): ?>
|
||||
<input type="hidden" name="filter[<?=$n?>]" value="<?=$v?>" />
|
||||
<?php endforeach; ?>
|
||||
<textarea name="text" class="form-control mb-2" style="height:120px;"></textarea>
|
||||
<button class="btn btn-sm btn-primary" type="submit"><i class="fas fa-save"></i> Speichern</button>
|
||||
</form>
|
||||
@@ -755,7 +763,6 @@
|
||||
});
|
||||
|
||||
|
||||
|
||||
function toggleOrder(id) {
|
||||
$('#order-detail-' + id).toggle();
|
||||
if($('#order-detail-' + id).is(":hidden")) {
|
||||
@@ -768,7 +775,6 @@
|
||||
}
|
||||
|
||||
|
||||
|
||||
function scrollToDiv(element){
|
||||
element = element.replace("link", "");
|
||||
$('html,body').unbind().animate({scrollTop: $(element).offset().top-180},'slow');
|
||||
@@ -778,7 +784,7 @@
|
||||
toggleOrder(<?=$highlight?>);
|
||||
scrollToDiv("#order-<?=$highlight?>");
|
||||
<?php if($addJournal): ?>
|
||||
$('#new-journal-<?=$highlight?>').toggle()
|
||||
$('#new-journal-<?=$highlight?>').toggle();
|
||||
$('#new-journal-<?=$highlight?> textarea[name=text]').focus();
|
||||
<?php endif; ?>
|
||||
<?php endif; ?>
|
||||
|
||||
Reference in New Issue
Block a user