-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathBylaws.sol
111 lines (68 loc) · 2.67 KB
/
Bylaws.sol
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
/*
2015 Ryan Michael Tate
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
*/
contract Bylaws {
/*
Decentralized Autonomous Ventures have bylaws which help the
organization operate internally.
These bylaws can be amended by the Directorate Contract
via Extra-Ordinary Resolution
For example: Both Ordinary and Extra-Ordinary Resolution thresholds can be
set via Extra-Ordinary Resolution voting
Extra-Ordinary Resolutions are resolutions that need a greater percentage of
the collective vote to pass than Ordinary Resolutions.
Ordinary Resolutions are usually set by greater than 51% or 67%
majority vote.
The default threshold value for Ordinary Resolution is set to 67%
The default threshold value for Extra-Ordinary Resolution is set to 90%
*/
// uint internal ORT;
// Ordinary Resolution Threshold Value;
// uint internal EORT;
// Extra-Ordinary Resolution Threshold Value;
// uint OpenResolutionLimit;
// Open Resolution Limit (ORL) sets the maximum...
// amount of open resolutions that can exist at one time
struct ByLawsConfig {
uint ORT;
uint EORT;
uint ORL;
bool equalWeighted; // default is true; false == shareWeighted;
uint resolutionPeriod;
}
ByLawsConfig public bylaws;
function Bylaws(){
bylaws.ORT = (100 * 67/100); // 67%
bylaws.EORT = (100 * 90/100); // 90%
bylaws.ORL = 5;
bylaws.equalWeighted = true;
bylaws.resolutionPeriod = 2 weeks;
}
function setORT(uint percentage) internal returns (bool){
bylaws.ORT = (100 * percentage / 100);
return true;
}
function setEORT(uint percentage) internal returns (bool){
bylaws.EORT = (100 * percentage / 100);
return true;
}
function setWeighting(bool equalWeighted) internal returns (bool){
bylaws.equalWeighted = equalWeighted;
return true;
}
function setORL(uint limit) internal returns (bool){
bylaws.ORL = limit;
return true;
}
function setRP(uint period) internal returns (bool){
bylaws.resolutionPeriod = period;
return true;
}
}