Crate pallet_asset_management
source ·Expand description
Asset_Management Pallet
The Asset_Management pallet is used for everything that is related to the asset management by its owners.
Overview
The Asset_Management gives the possibility to the asset Owners, through governance, to implement the following actions:
- Elect a Representative that will micro-manage the asset
- Demote a previously elected Representative
- Allow the representative to submit a list of Tenants to the Owners
- Allow the owners to vote on list of tenants submitted by the Representative
Dispatchable Functions
-
launch_representative_session- An Owner creates a referendum for the following available proposals:- Elect a Representative.
- Demote a Representative.
-
owners_vote- Each asset owner can vote in an ongoing referendum. -
request_asset_management- An active Representative can request an additional asset to manage. -
representative_approval- Call used as a proposal for Representative election. -
demote_representative- Call used as a proposal for Representative demotion. -
launch_tenant_session- A Representative creates a referendum for the following available proposals:- Admit a Tenant for a given asset.
- Evict a Tenant from a given asset.
The Representative has to submit a judgement about the tenant profile. This judgement
will be considered by the owners before voting.
Representatives receive a judgement fee from the aspiring tenant.
A positive result of the referendum will send a guaranty_deposit payment request to the
tenant. When the tenant finally pays the guaranty_deposit,his account is connected to the
asset through
link_tenant_to_assetand this marks the start of his contract with the owners.
-
link_tenant_to_asset- Call used as a proposal to link an accepted tenant with an existing asset. -
unlink_tenant_to_asset- Call used as a proposal to remove the link between a tenant and an asset. -
request_guaranty_payment- Call used to send a guaranty deposit payment request to a tenant.
Re-exports
pub use pallet_assets as Assetss;pub use pallet_democracy as Dem;pub use pallet_housing_fund as HFund;pub use pallet_identity as Ident;pub use pallet_nft as Nft;pub use pallet_onboarding as Onboarding;pub use pallet_payment as Payment;pub use pallet_roles as Roles;pub use pallet::*;pub use super::*;pub use super::*;Modules
Vec<T>.Macros
Ok.$x:expr and if not true return Err($y:expr).Structs
concat(blake2_128(key), key)T.StorageMap and a StorageValue<Value=u32> to keep track of how many items
are in a map, without needing to iterate all the values.Option<Value>T.Result<Value, PalletError>(key1, key2) couple. Similar to StorageMap but allow
to iterate and remove value associated to first key.(Key<Hasher1, key1>, Key<Hasher2, key2>, ..., Key<HasherN, keyN>).concat(twox64(key), key)ValueVec<T>, short for ‘vector’.Enums
Constants
error field defined in [ModuleError].
In FRAME, this is the maximum encoded size of a pallet error type.Traits
Dispatchable function (aka transaction) that can carry some static information along with
it, using the #[weight] attribute.MaxEncodedLen have a statically known maximum encoded size.Self.X, as parts per
X.Lookup in that it doesn’t (can cannot) require any
context.Self.Functions
o represents an unsigned extrinsic. Returns Ok or an Err otherwise.o represents the root. Returns Ok or an Err otherwise.o represents a signed extrinsic (i.e. transaction).
Returns Ok with the account that signed the extrinsic or an Err otherwise.o represents either a signed extrinsic (i.e. transaction) or the root.
Returns Ok with the account that signed the extrinsic, None if it was root, or an Err
otherwise.Type Definitions
BlockNumber associated type of system config.DispatchResultWithPostInfo that can be returned from
dispatchable functions and is automatically converted to the augmented type. Should be
used whenever the PostDispatchInfo does not need to be overwritten. As this should
be the common case it is the implicit return type when none is specified.Dispatchable in frame. When returned explicitly from
a dispatchable function it allows overriding the default PostDispatchInfo
returned from a dispatch.Origin associated type of system config.TransactionLongevity::max_value() means “forever”.Derive Macros
Clone but do not bound any generic. Docs are at frame_support::CloneNoBound.Debug but do not bound any generics. Docs are at frame_support::DebugNoBound.parity_scale_codec::Decode and for struct and enum.parity_scale_codec::Encode and parity_scale_codec::EncodeLike for struct and enum.frame_support::EqNoBound.parity_scale_codec::MaxEncodedLen for struct and enum.PartialEq but do not bound any generic. Docs are at
frame_support::PartialEqNoBound.Debug, if std is enabled it uses frame_support::DebugNoBound, if std is not
enabled it just returns "<stripped>".
This behaviour is useful to prevent bloating the runtime WASM blob from unneeded code.