tutus-chain/pkg/core
Tutus Development 5678ae0e46 Complete Collocatio native contract for PIO/EIO/CIO investments
Implement comprehensive investment infrastructure with three tiers:
- PIO (Public Investment Opportunity): Universal citizen access
- EIO (Employee Investment Opportunity): Workplace democracy
- CIO (Contractor Investment Opportunity): Gig economy empowerment

New Features:

Violation System:
- recordViolation: Record violations with evidence and penalties
- resolveViolation: Resolve violations with committee authority
- getViolation: Query violation records
- Auto-ban after MaxViolationsBeforeBan threshold

Employment Verification (EIO eligibility):
- verifyEmployment: Register employee-employer relationships
- revokeEmployment: End employment verification
- getEmploymentStatus: Query employment records
- EIO eligibility requires active employment

Contractor Verification (CIO eligibility):
- verifyContractor: Register contractor-platform relationships
- revokeContractor: End contractor verification
- getContractorStatus: Query contractor records
- CIO eligibility requires active contractor status

Returns Distribution:
- distributeReturns: Proportional returns to all investors
- cancelOpportunity: Refund investors on cancellation

Education Integration:
- completeInvestmentEducation: Mark investor education complete
- Scire certification tracking for eligibility

Query Methods:
- getInvestmentsByOpportunity: List investments per opportunity
- getInvestmentsByInvestor: List investments per investor
- getOpportunitiesByType: Filter by PIO/EIO/CIO
- getOpportunitiesByStatus: Filter by lifecycle status

Lifecycle Automation (PostPersist):
- Auto-close opportunities past investment deadline
- Auto-fail opportunities below minimum participants
- Runs every 100 blocks for performance

State Serialization:
- Add ToStackItem/FromStackItem for EmploymentVerification
- Add ToStackItem/FromStackItem for ContractorVerification
- Add ToStackItem/FromStackItem for InvestmentViolation

Tests:
- 14 test cases for config, counters, queries, error handling

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-21 04:18:23 +00:00
..
block Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00
chaindump Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00
dao Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00
fee Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00
interop Fix remaining Neo/Gas references to Tutus/Lub in test files 2025-12-21 02:43:45 +00:00
mempool Add free GAS for Vita holders with cross-chain fee splitting 2025-12-20 04:27:55 +00:00
mempoolevent Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00
mpt Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00
native Complete Collocatio native contract for PIO/EIO/CIO investments 2025-12-21 04:18:23 +00:00
state Complete Collocatio native contract for PIO/EIO/CIO investments 2025-12-21 04:18:23 +00:00
stateroot Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00
statesync Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00
storage Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00
test_data Initial Tutus chain fork from NeoGo 2025-12-19 14:23:04 +00:00
transaction Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00
basic_chain_test.go Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00
bench_test.go Fix remaining Neo/Gas references to Tutus/Lub in test files 2025-12-21 02:43:45 +00:00
blockchain.go Complete Annos to Tutus rename across codebase 2025-12-21 00:56:43 +00:00
blockchain_core_test.go Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00
blockchain_neotest_test.go Fix remaining Neo/Gas references to Tutus/Lub in test files 2025-12-21 02:43:45 +00:00
custom_native_test.go Fix remaining Neo/Gas references to Tutus/Lub in test files 2025-12-21 02:43:45 +00:00
doc.go Initial Tutus chain fork from NeoGo 2025-12-19 14:23:04 +00:00
headerhashes.go Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00
helper_test.go Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00
interops.go Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00
native_designate_test.go Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00
prometheus.go Initial Tutus chain fork from NeoGo 2025-12-19 14:23:04 +00:00
util.go Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00
util_test.go Update all imports from neo-go to tutus-chain 2025-12-19 14:28:17 +00:00