-
-
Notifications
You must be signed in to change notification settings - Fork 812
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
adds sales order line item price #1545
Conversation
Looks like a great idea :) |
@SchrodingersGat @eeintech |
@matmair Where is that modal view? |
@matmair I imagine you want the cells to align between tables right? You can edit the For instance, here is a 3 column table, with no headers: <table class='table table-striped table-condensed'>
<tr>
<td style='width:40%'><b>{% trans 'Unit Cost' %}</b></td>
<td style='width:30%'>Min: {% include "price.html" with price=min_unit_buy_price %}</td>
<td style='width:30%'>Max: {% include "price.html" with price=max_unit_buy_price %}</td>
</tr>
<tr>
<td><b>{% trans 'Total Cost' %}</b></td>
<td>Min: {% include "price.html" with price=min_total_buy_price %}</td>
<td>Max: {% include "price.html" with price=max_total_buy_price %}</td>
</tr>
<tr>
<td colspan='3'>
<span class='warning-msg'><i>{% trans 'No supplier pricing available' %}</i></span>
</td>
</tr>
</table> And for the 2 columns header: <table class='table table-striped table-condensed'>
<tr>
<td style='width:40%'><b>{% trans 'Unit Cost' %}</b></td>
<td style='width:60%'>Min: {% include "price.html" with price=min_unit_buy_price %}</td>
</tr>
<tr>
<td><b>{% trans 'Total Cost' %}</b></td>
<td>Min: {% include "price.html" with price=min_total_buy_price %}</td>
</tr>
<tr>
<td colspan='2'>
<span class='warning-msg'><i>{% trans 'No supplier pricing available' %}</i></span>
</td>
</tr>
</table> This gives me: |
Also this might not be the cleanest way to do it in CSS, you may want to create your own class for this table and define the width there. Using the |
@eeintech yes exactly thank you |
save the changes to the db and return success-json
@SchrodingersGat this closes 2 tasks on #1425, I will tick them after this PR is merged |
@matmair looks great, fantastic effort on this :) I've had a bit of a play around, the only thing that jumps out at me - when you add a part to a sales order which has price breaks associated with it, should it automatically calculate the sale price based on the selected quantity? |
@SchrodingersGat please set the following tasks in #1425 as done:
I added the functionality to auto-set price if a pricebreak is set |
As part of #1425