mirror of
https://github.com/BiPhan4/DefiHackathon-2022.git
synced 2025-04-02 10:41:42 -04:00
new changes
This commit is contained in:
parent
a67aa7df28
commit
4bba0e9776
3 changed files with 57 additions and 24 deletions
62
contracts/counter/Cargo.lock
generated
62
contracts/counter/Cargo.lock
generated
|
@ -37,9 +37,9 @@ checksum = "44c32f031ea41b4291d695026c023b95d59db2d8a2c7640800ed56bc8f510f22"
|
|||
|
||||
[[package]]
|
||||
name = "cosmwasm-crypto"
|
||||
version = "0.16.0"
|
||||
version = "0.16.6"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "bfa1715a9b71c7c31385a3f021dee2fd0a17b82043ab937467e103aa25043d2e"
|
||||
checksum = "aa6d40e8d484d04dd66e8d5795a3b36d9aaedda2cd75eeed2e00d56fd4923bdb"
|
||||
dependencies = [
|
||||
"digest",
|
||||
"ed25519-zebra",
|
||||
|
@ -50,9 +50,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "cosmwasm-derive"
|
||||
version = "0.16.0"
|
||||
version = "0.16.6"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "9f6e6dff07965015c4fcdf477c4becde738a2bfb40cf6239bdcea9335016c5a2"
|
||||
checksum = "848c6ddf2e7dc61c2ebfce263307fce5f66a65ab30e22ac97bf431ed4c5da7f1"
|
||||
dependencies = [
|
||||
"syn",
|
||||
]
|
||||
|
@ -69,13 +69,14 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "cosmwasm-std"
|
||||
version = "0.16.0"
|
||||
version = "0.16.6"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "92bdeee0ebba164ebbef9380522cc50f889db38acc1f1210f6b55ee2244b8c59"
|
||||
checksum = "b8eeb09d759020f5793fa7f61bb107bf651cf355735b62845b686ab05b78e164"
|
||||
dependencies = [
|
||||
"base64",
|
||||
"cosmwasm-crypto",
|
||||
"cosmwasm-derive",
|
||||
"forward_ref",
|
||||
"schemars",
|
||||
"serde",
|
||||
"serde-json-wasm",
|
||||
|
@ -93,6 +94,20 @@ dependencies = [
|
|||
"serde",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "counter"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"cosmwasm-schema",
|
||||
"cosmwasm-std",
|
||||
"cosmwasm-storage",
|
||||
"cw-storage-plus",
|
||||
"cw2",
|
||||
"schemars",
|
||||
"serde",
|
||||
"thiserror",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "cpufeatures"
|
||||
version = "0.1.5"
|
||||
|
@ -145,15 +160,27 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "cw-storage-plus"
|
||||
version = "0.8.0"
|
||||
version = "0.8.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "6ef70f7912bed72ff56a4f704aee279b6ef4cd0a5f3aa2732ad371e3f6d3ea71"
|
||||
checksum = "c1e867b9972b83b32e00e878dfbff48299ba26618dabeb19b9c56fae176dc225"
|
||||
dependencies = [
|
||||
"cosmwasm-std",
|
||||
"schemars",
|
||||
"serde",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "cw2"
|
||||
version = "0.8.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "4d48454f96494aa1018556cd457977375cc8c57ef3e5c767cfa2ea5ec24b0258"
|
||||
dependencies = [
|
||||
"cosmwasm-std",
|
||||
"cw-storage-plus",
|
||||
"schemars",
|
||||
"serde",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "der"
|
||||
version = "0.4.1"
|
||||
|
@ -230,6 +257,12 @@ dependencies = [
|
|||
"subtle",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "forward_ref"
|
||||
version = "1.0.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "c8cbd1169bd7b4a0a20d92b9af7a7e0422888bd38a6f5ec29c1fd8c1558a272e"
|
||||
|
||||
[[package]]
|
||||
name = "generic-array"
|
||||
version = "0.14.4"
|
||||
|
@ -338,19 +371,6 @@ dependencies = [
|
|||
"unicode-xid",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "project-name"
|
||||
version = "0.1.0"
|
||||
dependencies = [
|
||||
"cosmwasm-schema",
|
||||
"cosmwasm-std",
|
||||
"cosmwasm-storage",
|
||||
"cw-storage-plus",
|
||||
"schemars",
|
||||
"serde",
|
||||
"thiserror",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "quote"
|
||||
version = "1.0.9"
|
||||
|
|
|
@ -3,7 +3,7 @@ use serde::{Deserialize, Serialize};
|
|||
|
||||
#[derive(Serialize, Deserialize, Clone, Debug, PartialEq, JsonSchema)]
|
||||
pub struct InstantiateMsg {
|
||||
pub count: i32,
|
||||
pub count: i32, //what do we initialize?
|
||||
}
|
||||
|
||||
#[derive(Serialize, Deserialize, Clone, Debug, PartialEq, JsonSchema)]
|
||||
|
@ -11,6 +11,8 @@ pub struct InstantiateMsg {
|
|||
pub enum ExecuteMsg {
|
||||
Increment {},
|
||||
Reset { count: i32 },
|
||||
//we will get user address and names. Then divide bill. Then take money from users and put into our own contract.
|
||||
//
|
||||
}
|
||||
|
||||
#[derive(Serialize, Deserialize, Clone, Debug, PartialEq, JsonSchema)]
|
||||
|
|
|
@ -2,7 +2,7 @@ use schemars::JsonSchema;
|
|||
use serde::{Deserialize, Serialize};
|
||||
|
||||
use cosmwasm_std::Addr;
|
||||
use cw_storage_plus::Item;
|
||||
use cw_storage_plus::Item; //import map and figure out how to use it
|
||||
|
||||
#[derive(Serialize, Deserialize, Clone, Debug, PartialEq, JsonSchema)]
|
||||
pub struct State {
|
||||
|
@ -11,3 +11,14 @@ pub struct State {
|
|||
}
|
||||
|
||||
pub const STATE: Item<State> = Item::new("state");
|
||||
|
||||
/*
|
||||
add states:
|
||||
|
||||
1 - the bill(s) / item
|
||||
2 - the customers /map
|
||||
3 - Need to figure out a way to store money that we've taken from users. Third state is item again?
|
||||
|
||||
1 - how to use map and item to store customers or any state
|
||||
2 - how to display bill to user
|
||||
*/
|
||||
|
|
Loading…
Add table
Reference in a new issue