forked from Qortal/qortal-ui
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
28 lines
685 B
28 lines
685 B
3 years ago
|
"use strict";
|
||
|
import ChatBase from "./chat/ChatBase.js"
|
||
2 years ago
|
import { QORT_DECIMALS } from "../constants.js"
|
||
3 years ago
|
|
||
|
export default class PublicizeTransaction extends ChatBase {
|
||
2 years ago
|
constructor() {
|
||
|
super()
|
||
|
this.type = 19
|
||
|
this.fee = 0
|
||
|
}
|
||
3 years ago
|
|
||
|
set proofOfWorkNonce(proofOfWorkNonce) {
|
||
|
this._proofOfWorkNonce = this.constructor.utils.int32ToBytes(proofOfWorkNonce)
|
||
|
}
|
||
2 years ago
|
set fee(fee) {
|
||
|
this._fee = fee * QORT_DECIMALS
|
||
|
this._feeBytes = this.constructor.utils.int64ToBytes(this._fee)
|
||
|
}
|
||
3 years ago
|
get params() {
|
||
|
const params = super.params;
|
||
|
params.push(
|
||
|
this._proofOfWorkNonce,
|
||
|
this._feeBytes
|
||
|
)
|
||
|
return params;
|
||
|
}
|
||
|
}
|