mirror of
https://github.com/everoddandeven/monerod-gui.git
synced 2025-03-12 09:30:30 +00:00
Add aux pow implementation
This commit is contained in:
parent
e6c5fbdc15
commit
ca4745578e
2 changed files with 72 additions and 1 deletions
|
@ -248,6 +248,66 @@
|
|||
<button *ngIf="gettingCalcPow" class="w-100 btn btn-primary btn-lg" type="button" disabled>Calculating PoW Hash ...</button>
|
||||
</div>
|
||||
|
||||
<div class="tab-pane fade" id="pills-add-aux-pow" role="tabpanel" aria-labelledby="pills-add-aux-pow-tab" tabindex="0">
|
||||
<div *ngIf="addAuxPowError != ''" class="alert alert-danger d-flex align-items-center justify-content-center text-center" role="alert">
|
||||
<h4><i class="bi bi-exclamation-triangle m-2"></i></h4>
|
||||
<div>
|
||||
{{ addAuxPowError }}
|
||||
</div>
|
||||
</div>
|
||||
<div *ngIf="addAuxPowSuccess" class="alert alert-success d-flex align-items-center justify-content-center text-center" role="alert">
|
||||
<h4><i class="bi bi-check-circle m-2"></i></h4>
|
||||
<div>
|
||||
Added aux pow
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="row g-5 p-2">
|
||||
<div class="cold-md-7 col-lg-12">
|
||||
<div class="row gy-3">
|
||||
<h4 class="mb-3">Easily enable merge mining with Monero without requiring software that manually alters the extra field in the coinbase tx to include the merkle root of the aux blocks</h4>
|
||||
|
||||
<div class="col-sm-12">
|
||||
<label for="add-aux-pow-block-template-blob" class="form-label">Block Template Blob</label>
|
||||
<textarea [(ngModel)]="addAuxPowBlockTemplateBlob" [ngModelOptions]="{standalone: true}" type="text" class="form-control" id="calc-pow-blob-data" placeholder=""
|
||||
rows="15" cols="15" ></textarea>
|
||||
<div class="invalid-feedback">
|
||||
Invalid blob data.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-sm-12">
|
||||
<label for="add-aux-pow-aux-pow" class="form-label">Aux Pow</label>
|
||||
<textarea [(ngModel)]="addAuxPowAuxPowJsonString" [ngModelOptions]="{standalone: true}" type="text" class="form-control" id="add-aux-pow-aux-pow" placeholder="[
|
||||
{
|
||||
id: <string>
|
||||
hash: <string>
|
||||
}
|
||||
... ,
|
||||
{
|
||||
id: <string>
|
||||
hash: <string>
|
||||
}
|
||||
]
|
||||
"
|
||||
rows="15" cols="15" ></textarea>
|
||||
<div class="invalid-feedback">
|
||||
Invalid blob data.
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<hr class="my-4">
|
||||
|
||||
<button *ngIf="!addingAuxPow" class="w-100 btn btn-primary btn-lg" type="button" (click)="addAuxPow()">Add Aux PoW</button>
|
||||
<button *ngIf="addingAuxPow" class="w-100 btn btn-primary btn-lg" type="button" disabled>Adding Aux PoW ...</button>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="tab-pane fade" id="pills-submit-block" role="tabpanel" aria-labelledby="pills-submit-block-tab" tabindex="0">
|
||||
<div *ngIf="submitBlockError != ''" class="alert alert-danger d-flex align-items-center justify-content-center text-center" role="alert">
|
||||
|
|
|
@ -7,7 +7,7 @@ import { NavbarLink } from '../../shared/components/navbar/navbar.model';
|
|||
import { MineableTxBacklog } from '../../../common/MineableTxBacklog';
|
||||
import { Chain } from '../../../common/Chain';
|
||||
import { CoreIsBusyError } from '../../../common/error';
|
||||
import { BlockTemplate, GeneratedBlocks, MiningStatus } from '../../../common';
|
||||
import { AuxPoW, BlockTemplate, GeneratedBlocks, MiningStatus } from '../../../common';
|
||||
|
||||
@Component({
|
||||
selector: 'app-mining',
|
||||
|
@ -80,6 +80,13 @@ export class MiningComponent implements AfterViewInit {
|
|||
public stopMiningError: string = '';
|
||||
public stopMiningSuccess: boolean = false;
|
||||
|
||||
public addAuxPowAuxPowJsonString: string = '';
|
||||
public addAuxPowBlockTemplateBlob: string = '';
|
||||
public auxPowArray: AuxPoW[] = [];
|
||||
public addingAuxPow: boolean = false;
|
||||
public addAuxPowSuccess: boolean = false;
|
||||
public addAuxPowError: string = '';
|
||||
|
||||
public get validStartMiningMinerAddress(): boolean {
|
||||
return this.startMiningMinerAddress != '';
|
||||
}
|
||||
|
@ -341,6 +348,10 @@ export class MiningComponent implements AfterViewInit {
|
|||
this.stoppingMining = false;
|
||||
}
|
||||
|
||||
public async addAuxPow(): Promise<void> {
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
class Card {
|
||||
|
|
Loading…
Reference in a new issue