mirror of
https://github.com/RolandWH/SIPPCompare.git
synced 2025-03-14 22:01:36 +00:00
simplify and fix fees logic
This commit is contained in:
parent
cafe2da484
commit
922f4b3a39
66
.idea/workspace.xml
generated
66
.idea/workspace.xml
generated
@ -4,20 +4,9 @@
|
||||
<option name="autoReloadType" value="SELECTIVE" />
|
||||
</component>
|
||||
<component name="ChangeListManager">
|
||||
<list default="true" id="1c319b92-4392-4dac-a78b-6bf35361fa44" name="Changes" comment="">
|
||||
<change afterPath="$PROJECT_DIR$/.gitignore" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/.idea/SIPPCompare.iml" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/.idea/inspectionProfiles/profiles_settings.xml" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/.idea/modules.xml" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/.idea/vcs.xml" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/gui/main_gui.ui" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/gui/output_window.ui" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/gui/platform_edit.ui" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/src/main.py" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/src/main_window.py" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/src/output_window.py" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/src/platform_edit.py" afterDir="false" />
|
||||
<list default="true" id="1c319b92-4392-4dac-a78b-6bf35361fa44" name="Changes" comment="initial commit">
|
||||
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/src/main_window.py" beforeDir="false" afterPath="$PROJECT_DIR$/src/main_window.py" afterDir="false" />
|
||||
</list>
|
||||
<option name="SHOW_DIALOG" value="false" />
|
||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||
@ -34,6 +23,18 @@
|
||||
<component name="Git.Settings">
|
||||
<option name="RECENT_GIT_ROOT_PATH" value="$PROJECT_DIR$" />
|
||||
</component>
|
||||
<component name="GitHubPullRequestSearchHistory"><![CDATA[{
|
||||
"lastFilter": {
|
||||
"state": "OPEN",
|
||||
"assignee": "RolandWH"
|
||||
}
|
||||
}]]></component>
|
||||
<component name="GithubPullRequestsUISettings"><![CDATA[{
|
||||
"selectedUrlAndAccountId": {
|
||||
"url": "https://github.com/RolandWH/SIPPCompare.git",
|
||||
"accountId": "58149c61-8599-4d08-aec1-eb13472087b5"
|
||||
}
|
||||
}]]></component>
|
||||
<component name="ProjectColorInfo">{
|
||||
"associatedIndex": 4
|
||||
}</component>
|
||||
@ -43,19 +44,19 @@
|
||||
<option name="hideEmptyMiddlePackages" value="true" />
|
||||
<option name="showLibraryContents" value="true" />
|
||||
</component>
|
||||
<component name="PropertiesComponent"><![CDATA[{
|
||||
"keyToString": {
|
||||
"Python.Run main.executor": "Run",
|
||||
"Python.main.executor": "Run",
|
||||
"Python.main_window.executor": "Run",
|
||||
"RunOnceActivity.ShowReadmeOnStart": "true",
|
||||
"RunOnceActivity.git.unshallow": "true",
|
||||
"git-widget-placeholder": "master",
|
||||
"ignore.virus.scanning.warn.message": "true",
|
||||
"last_opened_file_path": "C:/dev/SIPPCompare/main.py",
|
||||
"settings.editor.selected.configurable": "editor.preferences.fonts.default"
|
||||
<component name="PropertiesComponent">{
|
||||
"keyToString": {
|
||||
"Python.Run main.executor": "Run",
|
||||
"Python.main.executor": "Run",
|
||||
"Python.main_window.executor": "Run",
|
||||
"RunOnceActivity.ShowReadmeOnStart": "true",
|
||||
"RunOnceActivity.git.unshallow": "true",
|
||||
"git-widget-placeholder": "master",
|
||||
"ignore.virus.scanning.warn.message": "true",
|
||||
"last_opened_file_path": "C:/dev/SIPPCompare/main.py",
|
||||
"settings.editor.selected.configurable": "editor.preferences.fonts.default"
|
||||
}
|
||||
}]]></component>
|
||||
}</component>
|
||||
<component name="RecentsManager">
|
||||
<key name="MoveFile.RECENT_KEYS">
|
||||
<recent name="C:\dev\SIPPCompare\src" />
|
||||
@ -102,6 +103,15 @@
|
||||
<option name="presentableId" value="Default" />
|
||||
<updated>1737895685673</updated>
|
||||
</task>
|
||||
<task id="LOCAL-00001" summary="initial commit">
|
||||
<option name="closed" value="true" />
|
||||
<created>1738078065403</created>
|
||||
<option name="number" value="00001" />
|
||||
<option name="presentableId" value="LOCAL-00001" />
|
||||
<option name="project" value="LOCAL" />
|
||||
<updated>1738078065403</updated>
|
||||
</task>
|
||||
<option name="localTasksCounter" value="2" />
|
||||
<servers />
|
||||
</component>
|
||||
<component name="Vcs.Log.Tabs.Properties">
|
||||
@ -115,4 +125,8 @@
|
||||
</map>
|
||||
</option>
|
||||
</component>
|
||||
<component name="VcsManagerConfiguration">
|
||||
<MESSAGE value="initial commit" />
|
||||
<option name="LAST_COMMIT_MESSAGE" value="initial commit" />
|
||||
</component>
|
||||
</project>
|
@ -61,13 +61,16 @@ class SIPPCompare(QMainWindow):
|
||||
break
|
||||
|
||||
shares_value = (1 - (slider_val / 100)) * value_num
|
||||
share_plat_fees = self.share_plat_fee * shares_value
|
||||
if (share_plat_fees / 12) > self.share_plat_max_fee:
|
||||
if (self.share_plat_fee * shares_value / 12) > self.share_plat_max_fee:
|
||||
share_plat_fees = self.share_plat_max_fee * 12
|
||||
else:
|
||||
share_plat_fees = self.share_plat_fee * shares_value
|
||||
|
||||
share_trades_num = int(self.share_trades_combo.currentText())
|
||||
share_deal_fees = self.share_deal_fee * share_trades_num
|
||||
if (share_trades_num / 12) > self.share_deal_reduce_trades:
|
||||
if (share_trades_num / 12) >= self.share_deal_reduce_trades:
|
||||
share_deal_fees = self.share_deal_reduce_amount * share_trades_num
|
||||
else:
|
||||
share_deal_fees = self.share_deal_fee * share_trades_num
|
||||
|
||||
self.show_output_win(fund_plat_fees, fund_deal_fees, share_plat_fees, share_deal_fees)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user