ver. 0.276: ShopOrder migration, Integrations cleanup, global admin search

This commit is contained in:
2026-02-15 16:37:57 +01:00
parent 0a2d13090f
commit d012a694c2
34 changed files with 2196 additions and 1063 deletions

View File

@@ -0,0 +1,38 @@
<script type="text/javascript">
$(function() {
function toggleInpostField() {
if ($('#transport_id').val() != '2') {
$('#inpost_paczkomat').closest('.row').hide();
} else {
$('#inpost_paczkomat').closest('.row').show();
}
}
toggleInpostField();
$('body').on('change', '#transport_id', function() {
toggleInpostField();
});
$('body').on('click', '.btn-paczkomat', function() {
window.easyPackAsyncInit = function () {
easyPack.init({
mapType: 'osm',
searchType: 'osm',
});
easyPack.mapWidget('inpost-map', function(point) {
$('#inpost_paczkomat').val(point.name + ' | ' + point.address.line1 + ', ' + point.address.line2);
$('.inpost-map-container').hide();
});
};
$('.inpost-map-container').show();
});
$('body').on('click', '#order-save', function(e) {
e.preventDefault();
$('#fg-order-details').attr('method', 'POST').attr('action', '/admin/shop_order/order_save/').submit();
});
});
</script>