mirror of
https://github.com/Qortal/qortal-ui.git
synced 2025-07-22 12:24:18 +00:00
build
config
core
crypto
api
bitcoin
deps
transactions
arbitrary
chat
groups
AddGroupAdminTransaction.js
CancelGroupBanTransaction.js
CancelGroupInviteTransaction.js
CreateGroupTransaction.js
GroupApprovalTransaction.js
GroupBanTransaction.js
GroupInviteTransaction.js
GroupKickTransaction.js
JoinGroupTransaction.js
LeaveGroupTransaction.js
RemoveGroupAdminTransaction.js
SetGroupTransaction.js
UpdateGroupTransaction.js
names
polls
reward-share
trade-portal
AirdropTransaction.js
DelegationTransaction.js
DeployAtTransaction.js
MessageTransaction.js
PaymentTransaction.js
PublicizeTransaction.js
TransactionBase.js
TransferPrivsTransaction.js
arbitraryV3.js
processTransaction.js
registerName_dnsthing.js
transactions.js
utils
wallet
PhraseWallet.js
api.js
constants.js
createTransaction.js
createWallet.js
decryptStoredWallet.js
fetch-request.js
kdf.js
registerUsername.js
storeWallet.js
tradeRequest.js
api.js
api_deps.js
config.js
img
lib
locales
plugins
scripts
snap
splash
.editorconfig
.gitattributes
.gitignore
CONTRIBUTING.md
LICENSE
README.md
build-setup.js
build.bat
build.js
build.sh
electron-builder.yml
electron.js
package-lock.json
package.json
run_server.bat
server.js
set-up-snap.sh
watch-inline.js
watch.js
110 lines
3.3 KiB
JavaScript
110 lines
3.3 KiB
JavaScript
import TransactionBase from '../TransactionBase'
|
|
import { QORT_DECIMALS } from '../../constants'
|
|
|
|
export default class UpdateGroupTransaction extends TransactionBase {
|
|
constructor() {
|
|
super()
|
|
this.type = 23
|
|
}
|
|
|
|
render(html) {
|
|
return html`
|
|
${this._updategroupdialog1}
|
|
<div style="background: #eee; padding: 8px; margin: 8px 0; border-radius: 5px;">
|
|
<div><span style="color: #000;">${this._updategroupdialog3}: ${this._rGroupNewOwnerDesc}</span></div>
|
|
<hr style="border: 2px solid #03a9f4;">
|
|
<div><span style="color: #000;">${this._updategroupdialog4}: ${this._rGroupNewName}</span></div>
|
|
<hr style="border: 2px solid #03a9f4;">
|
|
<div><span style="color: #000;">${this._updategroupdialog5}: ${this._rGroupNewDesc}</span></div>
|
|
<hr style="border: 2px solid #03a9f4;">
|
|
<div><span style="color: #000;">${this._updategroupdialog6}: ${this._rGroupTypeDesc}</span></div>
|
|
</div>
|
|
${this._updategroupdialog2}
|
|
`
|
|
}
|
|
|
|
set updategroupdialog1(updategroupdialog1) {
|
|
this._updategroupdialog1 = updategroupdialog1
|
|
}
|
|
|
|
set updategroupdialog2(updategroupdialog2) {
|
|
this._updategroupdialog2 = updategroupdialog2
|
|
}
|
|
|
|
set updategroupdialog3(updategroupdialog3) {
|
|
this._updategroupdialog3 = updategroupdialog3
|
|
}
|
|
|
|
set updategroupdialog4(updategroupdialog4) {
|
|
this._updategroupdialog4 = updategroupdialog4
|
|
}
|
|
|
|
set updategroupdialog5(updategroupdialog5) {
|
|
this._updategroupdialog5 = updategroupdialog5
|
|
}
|
|
|
|
set groupTypeDesc(groupTypeDesc) {
|
|
this._rGroupTypeDesc = groupTypeDesc
|
|
}
|
|
|
|
set fee(fee) {
|
|
this._fee = fee * QORT_DECIMALS
|
|
this._feeBytes = this.constructor.utils.int64ToBytes(this._fee)
|
|
}
|
|
|
|
set newGroupId(newGroupId) {
|
|
this._rGroupNewBytes = this.constructor.utils.int32ToBytes(newGroupId)
|
|
}
|
|
|
|
set newOwner(newOwner) {
|
|
this._rGroupNewOwnerDesc = newOwner
|
|
this._rGroupNewOwner = newOwner instanceof Uint8Array ? newOwner : this.constructor.Base58.decode(newOwner)
|
|
}
|
|
|
|
set newName(newName) {
|
|
this._rGroupNewName = newName
|
|
this._rGroupNewNameBytes = this.constructor.utils.stringtoUTF8Array(this._rGroupNewName)
|
|
this._rGroupNewNameLength = this.constructor.utils.int32ToBytes(this._rGroupNewNameBytes.length)
|
|
}
|
|
|
|
set newDescription(newDescription) {
|
|
this._rGroupNewDesc = newDescription
|
|
this._rGroupNewDescBytes = this.constructor.utils.stringtoUTF8Array(this._rGroupNewDesc)
|
|
this._rGroupNewDescLength = this.constructor.utils.int32ToBytes(this._rGroupNewDescBytes.length)
|
|
}
|
|
|
|
set newIsOpen(newIsOpen) {
|
|
this._rGroupNewType = new Uint8Array(1)
|
|
this._rGroupNewType[0] = newIsOpen
|
|
}
|
|
|
|
set newApprovalThreshold(newApprovalThreshold) {
|
|
this._rGroupNewApprovalThreshold = new Uint8Array(1)
|
|
this._rGroupNewApprovalThreshold[0] = newApprovalThreshold
|
|
}
|
|
|
|
set newMinimumBlockDelay(newMinimumBlockDelay) {
|
|
this._rGroupNewMinimumBlockDelayBytes = this.constructor.utils.int32ToBytes(newMinimumBlockDelay)
|
|
}
|
|
|
|
set newMaximumBlockDelay(newMaximumBlockDelay) {
|
|
this._rGroupNewMaximumBlockDelayBytes = this.constructor.utils.int32ToBytes(newMaximumBlockDelay)
|
|
}
|
|
|
|
get params() {
|
|
const params = super.params
|
|
params.push(
|
|
this._rGroupNewBytes,
|
|
this._rGroupNewOwner,
|
|
this._rGroupNewDescLength,
|
|
this._rGroupNewDescBytes,
|
|
this._rGroupNewType,
|
|
this._rGroupNewApprovalThreshold,
|
|
this._rGroupNewMinimumBlockDelayBytes,
|
|
this._rGroupNewMaximumBlockDelayBytes,
|
|
this._feeBytes
|
|
)
|
|
return params
|
|
}
|
|
}
|