Saleor Core: the high performance, composable, headless commerce API.
Python cartcheckoutcommercecomposablee-commerceecommercegraphqlheadlessheadless-commercemultichannelomsorder-managementpaymentspimpythonshopshopping-cartstore
Overhaul order note styling
dominik-zeglen9857678e673b
diff --git a/saleor/order/forms.py b/saleor/order/forms.pyindex f0389f2254..a13ead4853 100644--- a/saleor/order/forms.py+++ b/saleor/order/forms.py@@ -54,7 +54,7 @@ class OrderNoteForm(forms.ModelForm):model = OrderNotefields = ['content']widgets = {- 'content': forms.Textarea()}+ 'content': forms.Textarea({'rows': 3, 'placeholder': False})}labels = {'content': pgettext_lazy('Order note', 'Add note to order')}diff --git a/templates/order/_ordered_items_table.html b/templates/order/_ordered_items_table.htmlindex 1599a813da..da73abb4fb 100644--- a/templates/order/_ordered_items_table.html+++ b/templates/order/_ordered_items_table.html@@ -26,7 +26,7 @@</div></div>{% endif %}-<div class="table__header hidden-sm-down">+<div class="table__header d-none d-sm-block"><div class="row"><div class="col-md-6"><small>diff --git a/templates/order/details.html b/templates/order/details.htmlindex 238c0b2869..bea547c1a7 100644--- a/templates/order/details.html+++ b/templates/order/details.html@@ -66,11 +66,28 @@{% if notes %}<h2 class="order-notes__header">{% trans "Notes" context "Order notes list" %}</h2>{% for note in notes %}- <p>{{note.content}}</p>+ {% if note.is_public %}+ <small>+ {% if note.user == user %}+ {% blocktrans with date=note.date %}+ {{ date }} by you+ {% endblocktrans %}+ {% elif note.user.is_staff %}+ {% trans 'staff user' context 'Order note author is staff' as note_author_staff%}+ {% blocktrans with author=note_author_staff date=note.date %}+ {{ date }} by <span class="text-muted">{{ author }}</span>+ {% endblocktrans %}+ {% else %}+ {% blocktrans with author=note.author date=note.date %}+ {{ date }} by {{ author }}+ {% endblocktrans %}+ {% endif %}+ </small>+ <p>{{note.content}}</p>+ {% endif %}{% endfor %}{% endif %}<div class="order-notes">- <h2 class="order-notes__header">{% trans "Add a note to your order" context "Order summary add note title" %}</h2><form method="post" class="form-group">{% csrf_token %}{% bootstrap_form note_form display_labels=False %}