Skip to content

v1.0.6 chainx.js 相关类型 #260

@liuchengxu

Description

@liuchengxu
  • 不带 V1 的是以前就有的结构体,票龄类型用 u64.
  • 带 V1 的新加的结构体,票龄类型用 u128.

staking:

pub struct NominationRecord {
    pub nomination: Balance,
    pub last_vote_weight: u64,
    pub last_vote_weight_update: BlockNumber,
    pub revocations: Vec<(BlockNumber, Balance)>,
}

pub struct NominationRecordV1 {
    pub nomination: Balance,
    pub last_vote_weight: u128,
    pub last_vote_weight_update: BlockNumber,
    pub revocations: Vec<(BlockNumber, Balance)>,
}

pub struct IntentionProfs {
    pub total_nomination: Balance,
    pub last_total_vote_weight: u64,
    pub last_total_vote_weight_update: BlockNumber,
}

pub struct IntentionProfsV1 {
    pub total_nomination: Balance,
    pub last_total_vote_weight: u128,
    pub last_total_vote_weight_update: BlockNumber,
}

tokens:

pub struct PseduIntentionVoteWeight {
    pub last_total_deposit_weight: u64,
    pub last_total_deposit_weight_update: BlockNumber,
}

pub struct PseduIntentionVoteWeightV1 {
    pub last_total_deposit_weight: u128,
    pub last_total_deposit_weight_update: BlockNumber,
}

pub struct DepositVoteWeight {
    pub last_deposit_weight: u64,
    pub last_deposit_weight_update: BlockNumber,
}

pub struct DepositVoteWeightV1 {
    pub last_deposit_weight: u128,
    pub last_deposit_weight_update: BlockNumber,
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions