ui: Add rate lookup helper when creating offers.

This commit is contained in:
tecnovert
2021-11-21 22:59:39 +02:00
parent 54ad0e496c
commit 8a9f4f9e38
11 changed files with 238 additions and 27 deletions

View File

@@ -56,10 +56,15 @@
<option value="100"{% if data.fee_to_extra==100 %} selected{% endif %}>100%</option>
</select></td></tr>
{% endif %}
</td><td>Rate</td><td><input type="text" id="rate" name="rate" value="{{ data.rate }}" readonly></td></tr>
<tr><td>Amount Variable</td><td colspan=3><input type="checkbox" id="amt_var" name="amt_var_" value="av" {% if data.amt_var==true %} checked="true"{% endif %} disabled></td></tr>
<tr><td>Rate Variable</td><td colspan=3><input type="checkbox" id="rate_var" name="rate_var_" value="rv" {% if data.rate_var==true %} checked="true"{% endif %} disabled></td></tr>
<tr class="padded_row"><td>Offer valid (hrs)</td><td><input type="number" name="validhrs" min="1" max="48" value="{{ data.validhrs }}"></td></tr>
<tr><td>Contract locked (hrs)</td><td><input type="number" name="lockhrs" min="1" max="96" value="{{ data.lockhrs }}"></td>{% if data.swap_style != 'xmr' %}<td colspan=2>Participate txn will be locked for half the time.</td>{% endif %}</tr>
<tr><td>Auto Accept Bids</td><td colspan=3><input type="checkbox" name="autoaccept" value="aa" {% if data.autoaccept==true %} checked="true"{% endif %}></td></tr>
<tr><td>Auto Accept Bids</td><td colspan=3><input type="checkbox" id="autoaccept" name="autoaccept" value="aa" {% if data.autoaccept==true %} checked="true"{% endif %}></td></tr>
</table>
<input name="check_offer" type="submit" value="Continue">
@@ -69,6 +74,12 @@
<input type="hidden" name="addr_from" value="{{ data.addr_from }}">
<input type="hidden" name="coin_from" value="{{ data.coin_from }}">
<input type="hidden" name="coin_to" value="{{ data.coin_to }}">
{% if data.amt_var==true %}
<input type="hidden" name="amt_var" value="true">
{% endif %}
{% if data.rate_var==true %}
<input type="hidden" name="rate_var" value="true">
{% endif %}
</form>
</body></html>