Support

Search results for ""

Sorry, no results found. Perhaps you would like to search the documentation?
All Topics
Rogerio Matos

Order Notes field – Display last note & Edit inline

Hello!
Order notes are very valuable and useful to us, so we would like to be able to see the notes we add to each order in WooCommerce Orders Columns. Currently it just displays a number (the number of notes) and when you overlay then it displays the notes.
It would be perfect if there would be a way to display the notes in text here and just display the latest note (user/admin note, NOT system notes /automatically generated system notes) and ideally to be able to edit them inline / add notes inline directly from the orders page without having to enter the order.

Basically a column field such as “Latest Order Notes”

Anyone has any idea this possible to achieve? Or be able to guide me in the right direction? Thank you very much in advance for the attention and advice

3 years, 11 months ago
Stefan van den Dungen Gronovius
Developer

Thanks for your input on this. When we created this column, we decided not to display all notes just as content in the column cell. If you have lots of notes, it would really change the layout of the table and height of the rows which is not something that you would expect. I do understand that it might be useful to see the notes for each order though. We could add another display for the notes column to display the message as is instead of a toolbox.

For this moment, you could overwrite the value for our ‘Order Notes’ column with a hook. The following hook will alter the default value and show the notes under each other with date and message.

function ac_column_value_usage( $value, $id, AC\Column $column ) {
	if( $column instanceof \ACA\WC\Column\ShopOrder\Notes ){
		$notes = wc_get_order_notes( [ 'order_id' => $id ] );
		$content = [];
		foreach ( $notes as $note ) {
			$note_content = sprintf( '<small><strong>%s</strong><br>%s</small>', $note->date_created->format( 'F j, Y - H:i' ), $note->content );
			$content[] = $note_content;
		}
		$value = implode( $content );
	}

	return $value;
}

add_filter( 'ac/column/value', 'ac_column_value_usage', 10, 3 );

Can you add this to your environment and tell me if that works for you?

3 years, 11 months ago
Rogerio Matos

Thank you very much for this suggestions of an alternative Stefan!
It works however just as you said it becomes very visually cumbersome as it displays all notes at once, including system created notes.

The ideal case scenario would be a “Latest note” column that would:
– Only display the latest note (The latest update is always the most valuable, and if someone would need to see more notes they could just use the current Order Notes column as is and hover the icon)
– Allow inline editing (The ability to quickly view and add admin notes to each order from the Orders page is
Because right now we can do almost everything we need from the orders page, but we still need to open each order manually in order to add notes (which we do often).
– Not display system / automatically created notes (Only display user admin created notes)

I made this visual example that I whipped up using ACF.
We can’t use this custom notes ACF workaround as there are a few problems it generates (Such as there are other management/CRM plugins which already integrate with the default woocommerce order notes, there is no order note history, etc)
Latest Notes Example

3 years, 11 months ago
Stefan van den Dungen Gronovius
Developer

The snippet was a quick workaround.
I’ve created a feature request based on your detailed description.

3 years, 11 months ago
Rogerio Matos

Thank you very much Stefan I appreciate it.
Is there any specific place to follow feature requests? In your honest opinion do you see this as something that could be implemented in the near future?

Once again thank you very much for your attention and advice.

3 years, 11 months ago
Stefan van den Dungen Gronovius
Developer

Showing the last note and make it editable is not that difficult to implement.
We don’t have a feature to actually add new notes though, and since we have an edit feature, not an ‘add’ feature in our plugin, I don’t think that we create something new to just create new notes. But I believe that the ‘Latest note’ with editing can be available in the next update.

 

We don’t have an open roadmap at the moment, but we’re working on that as well. And make it available to vote on requests as well.

3 years, 11 months ago
Rogerio Matos

Thank you for sharing your thoughts Stefan, being able to edit the note from the order page would really be perfect

3 years, 11 months ago
Stefan van den Dungen Gronovius
Developer

Did you receive my email with a concept version?

3 years, 11 months ago
William Araujo

Any way to show the order note sent by customer at checkout?

2 years, 1 month ago

You must be logged in to reply to this topic.