foundryvtt-reve-de-dragon/templates/item-service-sheet.html

104 lines
4.9 KiB
HTML
Raw Normal View History

<form class="{{cssClass}}" autocomplete="off">
{{>"systems/foundryvtt-reve-de-dragon/templates/header-item.html"}}
<section class="sheet-body">
<div class="flexcol form-group small-editor">
{{editor description target="system.description" button=true owner=owner editable=(or isGM isOwner) engine="prosemirror"}}
</div>
{{!--
<div class="flexcol">
<ul class="item-list alterne-list">
<li class="item flexrow list-item">
<label class="flex-grow">Service</label>
<label>Moral</label>
<label>Qualité</label>
<label>Prix (sols)</label>
<label>
{{#unless disabled}}
<a class="service-add"><i class="fas fa-plus-circle"></i></a>
{{/unless}}
</label>
</li>
{{#each system.services as |service key|}}
<li class="item flexrow list-item" data-key="{{key}}">
<input {{@root.disabled}} type="text" name="services[{{key}}].name" value="{{service.name}}" data-dtype="String" />
<input {{@root.disabled}} type="checkbox" name="services[{{key}}].system.moral" {{#if service.system.moral}}checked{{/if}} />
<input {{@root.disabled}} type="number" name="services[{{key}}].system.qualite" value="{{service.system.qualite}}" data-dtype="Number" min="-10" max="10"/>
<input {{@root.disabled}} type="number" class="input-prix" name="services[{{key}}].system.cout" value="{{numberFormat service.system.cout decimals=2 sign=false}}" data-dtype="Number" min="0" />
<div class="item-controls">
<a class="service-acheter" title="Acheter"><i class="fa-sharp fa-solid fa-coins"></i></a>
{{#unless @root.disabled}}
<a class="service-vendre" title="Proposer"><i class="fas fa-comments-dollar"></i></a>
<a class="service-delete" title="Supprimer"><i class="fas fa-trash"></i></a>
{{/unless}}
</div>
</li>
{{/each}}
</ul>
</div>
<br>
--}}
<div class="form-group">
<input {{@root.disabled}} class="attribute-value" type="checkbox" name="system.illimite" {{#if system.illimite}}checked{{/if}}/>
<span for="system.illimite">Quantité en vente illimitée</span>
</div>
<div class="flexcol">
<ul class="item-list alterne-list">
<li class="item flexrow list-item">
<label class="flex-grow">A vendre</label>
{{#unless system.illimite}}
<label>Quantite</label>
{{/unless}}
<label>Prix (sols)</label>
<div class="item-controls">
{{#unless disabled}}
<a class="sub-item-info-add" title="Utiliser le drag&amp;drop pour ajouter un objet dans la liste">
<i class="fa-solid fa-circle-info"></i>
</a>
{{/unless}}
</div>
</li>
{{#each system.items as |item key|}}
<li class="item flexrow list-item service-item" data-item-id="{{item.id}}" data-pack="{{item.pack}}" data-key="{{key}}">
<label class="flex-grow">
{{#if item.img}}<img class="sheet-competence-img" src="{{item.img}}" title="{{item.name}}"/>{{/if}}
{{> 'systems/foundryvtt-reve-de-dragon/templates/common/compendium-link.hbs'
pack=item.pack id=item.id name=item.name}}
</label>
{{#unless @root.system.illimite}}
<span class="flexrow">
{{#unless @root.disabled}}
<a class="sub-item-quantite-moins"><i class="fas fa-minus-square"></i></a>
{{/unless}}
<input {{@root.disabled}} type="number" class="sub-item-quantite" name="items[{{key}}].system.quantite" value="{{item.system.quantite}}" data-dtype="Number" />
{{#unless @root.disabled}}
<a class="sub-item-quantite-plus"><i class="fas fa-plus-square"></i></a>
{{/unless}}
</span>
{{/unless}}
<span class="flexrow">
<input {{@root.disabled}} type="number" class="input-prix number-x3 sub-item-cout" name="items[{{key}}].system.cout" value="{{numberFormat item.system.cout decimals=2 sign=false}}" data-dtype="Number" />
</span>
<div class="item-controls">
<a class="sub-item-acheter" title="Acheter"><i class="fa-regular fa-coins"></i></a>
{{#unless @root.disabled}}
<a class="sub-item-vendre" title="Vendre"><i class="fas fa-comments-dollar"></i></a>
<a class="sub-item-delete" title="Supprimer"><i class="fas fa-trash"></i></a>
{{/unless}}
</div>
</li>
{{/each}}
</ul>
</div>
{{#if isGM}}
<br>
<div class="flexcol">
<span><label>Description (MJ seulement): </label></span>
<div class="form-group medium-editor">
{{editor descriptionmj target="system.descriptionmj" button=true owner=owner editable=true engine="prosemirror"}}
</div>
</div>
{{/if}}
</section>
</form>