mirror of
https://github.com/btcpayserver/btcpayserver.git
synced 2025-02-27 07:57:33 +01:00
* Renamed "WithdrawAsync" to "WithdrawToStoreWalletAsync" * WIP * WIP withdrawal + Refactored Form saving to JObject * WIP * Form to fix bad values during withdrawing appears correctly * WIP * Lots of cleanup and refactoring + Password field and toggle password view * Cleanup + Finishing touches on withdrawals * Added "Destination" dummy text as this is always the destination. * Fixed broken test * Added support for withdrawing using qty as a percentage if it ends with "%". Needs more testing. * Fixed broken build * Fixed broken build (2) * Update BTCPayServer/wwwroot/swagger/v1/swagger.template.custodians.json Co-authored-by: d11n <mail@dennisreimann.de> * Update BTCPayServer/wwwroot/swagger/v1/swagger.template.custodians.json Co-authored-by: d11n <mail@dennisreimann.de> * Improved unit tests * Fixed swagger bug * Test improvements Make string conversion of quantity explicitely. * Fix build warnings * Swagger: Add missing operationId * Made change Dennis requested * Removed unused file * Removed incorrect comment * Extra contructor * Renamed client methods * Cleanup config before saving * Fixed broken controller * Refactor custodian * Fix build * Make decimal fields strings to match the rest of Greenfield * Improve parsing of % quantities --------- Co-authored-by: d11n <mail@dennisreimann.de> Co-authored-by: nicolas.dorier <nicolas.dorier@gmail.com>
64 lines
2.4 KiB
Text
64 lines
2.4 KiB
Text
@using BTCPayServer.Views.Apps
|
|
@using BTCPayServer.Abstractions.Extensions
|
|
@model BTCPayServer.Models.CustodianAccountViewModels.CreateCustodianAccountViewModel
|
|
@{
|
|
ViewData.SetActivePage(AppsNavPages.Create, "Add a custodian account");
|
|
}
|
|
|
|
@section PageFootContent {
|
|
<partial name="_ValidationScriptsPartial" />
|
|
}
|
|
|
|
<partial name="_StatusMessage" />
|
|
|
|
<h2 class="mt-1 mb-4">@ViewData["Title"]</h2>
|
|
|
|
<div class="row">
|
|
<div class="col-xl-8 col-xxl-constrain">
|
|
<form asp-action="CreateCustodianAccount">
|
|
@if (!ViewContext.ModelState.IsValid)
|
|
{
|
|
<div asp-validation-summary="ModelOnly" class="text-danger"></div>
|
|
}
|
|
@if (!string.IsNullOrEmpty(Model.SelectedCustodian))
|
|
{
|
|
<partial name="_FormTopMessages" model="Model.ConfigForm" />
|
|
}
|
|
else if(Model.Custodians.Count() > 0)
|
|
{
|
|
<div class="form-group">
|
|
<label asp-for="SelectedCustodian" class="form-label" data-required></label>
|
|
<select asp-for="SelectedCustodian" asp-items="Model.Custodians" class="form-select"></select>
|
|
</div>
|
|
}
|
|
else
|
|
{
|
|
<p>No custodians available. Install some plugins to add custodian / exchange support.</p>
|
|
}
|
|
|
|
@if (!string.IsNullOrEmpty(Model.SelectedCustodian))
|
|
{
|
|
<div class="form-group">
|
|
<label asp-for="SelectedCustodian" class="form-label" data-required></label>
|
|
<select disabled asp-for="SelectedCustodian" asp-items="Model.Custodians" class="form-select"></select>
|
|
<input type="hidden" asp-for="SelectedCustodian" />
|
|
</div>
|
|
|
|
<div class="form-group">
|
|
<label asp-for="Name" class="form-label" data-required></label>
|
|
<input asp-for="Name" class="form-control" required/>
|
|
<span asp-validation-for="Name" class="text-danger"></span>
|
|
</div>
|
|
|
|
<partial name="_Form" model="Model.ConfigForm" />
|
|
}
|
|
|
|
@if (Model.Custodians.Count() > 0)
|
|
{
|
|
<div class="form-group mt-4">
|
|
<input type="submit" value="Continue" class="btn btn-primary" id="Continue"/>
|
|
</div>
|
|
}
|
|
</form>
|
|
</div>
|
|
</div>
|