Garder trace du vendeur

This commit is contained in:
Vincent Vandemeulebrouck 2021-04-14 22:40:12 +02:00
parent a282575422
commit 413893bc67
2 changed files with 9 additions and 7 deletions

View File

@ -150,7 +150,9 @@ export class RdDItem extends Item {
let chatData = duplicate(Misc.data(this));
const properties = this[`_${chatData.type}ChatData`]();
chatData["properties"] = properties
if (this.actor){
chatData.actor = {id: this.actor.id };
}
//Check if the posted item should have availability/pay buttons
chatData.hasPrice = "cout" in chatData.data;
chatData.data.cout_deniers = 0;

View File

@ -15,21 +15,21 @@
<b>Quantité: </b> <span class="postQuantity">{{postQuantity}}</span>
{{/if}}
{{#if postPrice}}
<b>Prix: </b> <span class="postPrice">{{postPrice}} Sols</span><br>
<b>Prix: </b> <span class="postPrice">{{postPrice}} Sols</span>
{{/if}}
</span>
</span><br>
{{/if}}
{{#if finalPrice}}
<span>
<b>Prix Total: </b> <span class="postPrice">{{finalPrice}} Sols</span><br>
</span>
{{/if}}
</p>
{{#if hasPrice}}
<span class="chat-card-button-area">
<a class='payer-button chat-card-button market-button' data-jsondata='{{jsondata}}'
data-somme-denier="{{data.cout_deniers_total}}" data-quantite="{{data.quantite}}">Payer</a>
<a class='payer-button chat-card-button market-button'
data-jsondata='{{jsondata}}'
{{#if actor.id}}data-actor-id='{{actor.id}}'{{/if}}
data-somme-denier="{{data.cout_deniers_total}}" data-quantite="{{data.quantite}}">Payer</a>
</span>
{{/if}}