coopcycle / coopcycle-web

Logistics & marketplace platform. Only for worker-owned business.
https://coopcycle.org
Other
564 stars 128 forks source link

In order to [undersand what's wrong] As a [store user] I want [an error message improved] instead of "price could not be calculated" #3705

Open rayon9coop opened 1 year ago

rayon9coop commented 1 year ago

In order to achieve something Make users autonomous and save time in phone calls.

As a role Dispatch : not need to answer phone calls "I can't order and I don't know why..." Store owner: could understand alone why they can't order the deliveries (too far, to large, too heavy, too late,...)

I want something to be added or changed I want to be able to configure personalised messages for several scenarios:

Whereas currently this happens For now, the only error message displayed when some order aren't fitting with tarification rules is "Price could not be calculated". Only one message is displayed, no matter the reason why.

alexsegura commented 1 year ago

This message appears when no pricing rules matches, most probably in the "first rule that matches" mode. It is It is hard to translate simply "why" we couldn't find a price in this case, pricing rules conditions can be complex and converting them to text would lead to very long sentences (also we would need to translate them to their opposite)

Like "because the pickup is outside of zone A and the dropoff is inside zone B and the distance is not superior to 5km"

What you are asking would be something else, a pre-validation of data, not price calculation.

Paul-Eraman-CoopCycle commented 11 months ago

Could we have pricing rules that don´t return a price but return an error? As in, I can say that under 5 kilos its no added charge on base price, 5-10 kilos it adds 5 euros, and over 10 kilos it returns "We don´t deliver packages over 10 kilos"

and then a coop could create its own error messages, or not, depending on their needs?

rayon9coop commented 11 months ago

At least, if the error message must be generic, it could be: "The price could not be calculated, please contact [name of coop] at [email adress]"