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
--- a/launch-config-westend.json
+++ b/launch-config-westend.json
@@ -79,9 +79,9 @@
     },
     "parachains": [
         {
-            "bin": "../unique-chain/target/release/nft",
+            "bin": "../unique-chain/target/release/unique-collator",
             "chain": "westend-local",
-            "balance": "1000000000000000000000",
+            "balance": "1000000000000000000000000",
             "nodes": [
                 {
                     "port": 31200,
modifiedlaunch-config.jsondiffbeforeafterboth
--- a/launch-config.json
+++ b/launch-config.json
@@ -57,7 +57,7 @@
         {
             "bin": "../unique-chain/target/release/unique-collator",
             "id": "2000",
-            "balance": "1000000000000000000000",
+            "balance": "1000000000000000000000000",
             "nodes": [
                 {
                     "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
--- a/runtime/src/lib.rs
+++ b/runtime/src/lib.rs
@@ -243,7 +243,7 @@
 impl FeeCalculator for FixedFee {
 	fn min_gas_price() -> U256 {
 		// Targeting 0.15 UNQ per transfer
-		1_024_947_215u32.into()
+		1_024_947_215_000u32.into()
 	}
 }
 
@@ -403,7 +403,7 @@
 	type WeightInfo = pallet_balances::weights::SubstrateWeight<Self>;
 }
 
-pub const MICROUNIQUE: Balance = 1_000_000_000;
+pub const MICROUNIQUE: Balance = 1_000_000_000_000;
 pub const MILLIUNIQUE: Balance = 1_000 * MICROUNIQUE;
 pub const CENTIUNIQUE: Balance = 10 * MILLIUNIQUE;
 pub const UNIQUE: Balance = 100 * CENTIUNIQUE;
@@ -481,7 +481,7 @@
 	fn polynomial() -> WeightToFeeCoefficients<Self::Balance> {
 		smallvec!(WeightToFeeCoefficient {
 			// Targeting 0.1 Unique per NFT transfer
-			coeff_integer: 142_688u32.into(),
+			coeff_integer: 142_688_000u32.into(),
 			coeff_frac: Perbill::zero(),
 			negative: false,
 			degree: 1,
modifiedtests/src/util/helpers.tsdiffbeforeafterboth
--- a/tests/src/util/helpers.ts
+++ b/tests/src/util/helpers.ts
@@ -69,7 +69,7 @@
 
 export const U128_MAX = (1n << 128n) - 1n;
 
-const MICROUNIQUE = 1_000_000_000n;
+const MICROUNIQUE = 1_000_000_000_000n;
 const MILLIUNIQUE = 1_000n * MICROUNIQUE;
 const CENTIUNIQUE = 10n * MILLIUNIQUE;
 export const UNIQUE = 100n * CENTIUNIQUE;