git.delta.rocks / unique-network / refs/commits / f438afa8f1cc

difftreelog

change decimals from 15 to 18

Igor Kozyrev2021-12-02parent: #7b6d12c.patch.diff
in: master

5 files changed

modifiedlaunch-config-westend.jsondiffbeforeafterboth
79 },79 },
80 "parachains": [80 "parachains": [
81 {81 {
82 "bin": "../unique-chain/target/release/nft",82 "bin": "../unique-chain/target/release/unique-collator",
83 "chain": "westend-local",83 "chain": "westend-local",
84 "balance": "1000000000000000000000",84 "balance": "1000000000000000000000000",
85 "nodes": [85 "nodes": [
86 {86 {
87 "port": 31200,87 "port": 31200,
modifiedlaunch-config.jsondiffbeforeafterboth
57 {57 {
58 "bin": "../unique-chain/target/release/unique-collator",58 "bin": "../unique-chain/target/release/unique-collator",
59 "id": "2000",59 "id": "2000",
60 "balance": "1000000000000000000000",60 "balance": "1000000000000000000000000",
61 "nodes": [61 "nodes": [
62 {62 {
63 "port": 31200,63 "port": 31200,
modifiednode/cli/src/chain_spec.rsdiffbeforeafterboth
5353
54pub fn development_config(id: ParaId) -> ChainSpec {54pub fn development_config(id: ParaId) -> ChainSpec {
55 let mut properties = Map::new();55 let mut properties = Map::new();
56 properties.insert("tokenSymbol".into(), "testUNQ".into());56 properties.insert("tokenSymbol".into(), "OPL".into());
57 properties.insert("tokenDecimals".into(), 15.into());57 properties.insert("tokenDecimals".into(), 15.into());
58 properties.insert("ss58Format".into(), 42.into()); // Generic Substrate wildcard (SS58 checksum preimage)58 properties.insert("ss58Format".into(), 42.into());
5959
60 ChainSpec::from_genesis(60 ChainSpec::from_genesis(
61 // Name61 // Name
modifiedruntime/src/lib.rsdiffbeforeafterboth
243impl FeeCalculator for FixedFee {243impl FeeCalculator for FixedFee {
244 fn min_gas_price() -> U256 {244 fn min_gas_price() -> U256 {
245 // Targeting 0.15 UNQ per transfer245 // Targeting 0.15 UNQ per transfer
246 1_024_947_215u32.into()246 1_024_947_215_000u32.into()
247 }247 }
248}248}
249249
403 type WeightInfo = pallet_balances::weights::SubstrateWeight<Self>;403 type WeightInfo = pallet_balances::weights::SubstrateWeight<Self>;
404}404}
405405
406pub const MICROUNIQUE: Balance = 1_000_000_000;406pub const MICROUNIQUE: Balance = 1_000_000_000_000;
407pub const MILLIUNIQUE: Balance = 1_000 * MICROUNIQUE;407pub const MILLIUNIQUE: Balance = 1_000 * MICROUNIQUE;
408pub const CENTIUNIQUE: Balance = 10 * MILLIUNIQUE;408pub const CENTIUNIQUE: Balance = 10 * MILLIUNIQUE;
409pub const UNIQUE: Balance = 100 * CENTIUNIQUE;409pub const UNIQUE: Balance = 100 * CENTIUNIQUE;
481 fn polynomial() -> WeightToFeeCoefficients<Self::Balance> {481 fn polynomial() -> WeightToFeeCoefficients<Self::Balance> {
482 smallvec!(WeightToFeeCoefficient {482 smallvec!(WeightToFeeCoefficient {
483 // Targeting 0.1 Unique per NFT transfer483 // Targeting 0.1 Unique per NFT transfer
484 coeff_integer: 142_688u32.into(),484 coeff_integer: 142_688_000u32.into(),
485 coeff_frac: Perbill::zero(),485 coeff_frac: Perbill::zero(),
486 negative: false,486 negative: false,
487 degree: 1,487 degree: 1,
modifiedtests/src/util/helpers.tsdiffbeforeafterboth
6969
70export const U128_MAX = (1n << 128n) - 1n;70export const U128_MAX = (1n << 128n) - 1n;
7171
72const MICROUNIQUE = 1_000_000_000n;72const MICROUNIQUE = 1_000_000_000_000n;
73const MILLIUNIQUE = 1_000n * MICROUNIQUE;73const MILLIUNIQUE = 1_000n * MICROUNIQUE;
74const CENTIUNIQUE = 10n * MILLIUNIQUE;74const CENTIUNIQUE = 10n * MILLIUNIQUE;
75export const UNIQUE = 100n * CENTIUNIQUE;75export const UNIQUE = 100n * CENTIUNIQUE;