Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
R
robo-dividend
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wenwen.tang
robo-dividend
Commits
b98d2a14
Commit
b98d2a14
authored
Nov 18, 2022
by
纪超
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
完善依赖注入可配置
parent
58c6bd58
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
0 deletions
+8
-0
api.py
api.py
+6
-0
injectable.py
framework/injectable.py
+2
-0
__init__.py
signal/__init__.py
+0
-0
No files found.
api.py
View file @
b98d2a14
...
...
@@ -173,3 +173,9 @@ class PortfoliosBuilder(ABC):
:return 投资组合数据{risk: {...}},计算明细数据 {...}
'''
pass
class
ControlSignal
(
ABC
):
def
handle
(
self
,
day
,
risk
:
PortfoliosRisk
):
pass
framework/injectable.py
View file @
b98d2a14
...
...
@@ -36,7 +36,9 @@ def component(cls=None, bean_name=None):
if
bean_name
not
in
names_config
or
names_config
[
bean_name
]
is
None
:
raise
InjectableError
(
f
"bean name[{bean_name}] is already defined."
)
if
class_name
(
cls
)
!=
names_config
[
bean_name
]:
__COMPONENT_CLASS
.
remove
(
cls
)
return
cls
__COMPONENT_CLASS
.
remove
(
__NAME_COMPONENT
[
bean_name
])
__NAME_COMPONENT
[
bean_name
]
=
cls
return
cls
...
...
signal/__init__.py
0 → 100644
View file @
b98d2a14
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment