Package: aa-miningtaxes
Mining TaxesAn Alliance Auth app for tracking mining activities and charging taxes.Credit to AA'smemberauditandbuybackplugins which formed the foundation for this plugin.ScreenshotsFeaturesMonthly leaderboards to show top miners.Supports multiple corps under one system (Add one character with the accountant role per corp in the admin setup)Supports corp moon mining tracking.Able to track when unrecognized characters are mining your corp's private moons.Tax credit system to offset, zero, or award tax credits to a given user.Supports separate tax rates for Regular Ore, Mercoxit, Gas, Ice, R64, R32, R16, R8, and R4.Tracks tax payments into the corp master wallet filtering with a user defined phrase.Set a monthly interest rate that penalizes for unpaid tax balances.Automatic monthly notifications and monthly interest applied with unpaid balance.Supports Fuzzworks and Janice for daily price updates.Supports refined price calculation versus raw ore prices (the higher price will be the taxed price).Supports multiple mining characters under one user.Monthly statistics and detailed tax calculations available to each user and auditor.Provides a current Ore price chart that is updated each day with the latest prices.Export tax information in CSV format.Installation instructionsIf you would like to useJanicefor pricing information, obtain an API key by following the instructions at the top of theSwagger documentationandFAQ.Install using pip:pip install aa-miningtaxesAddminingtaxesand 'django_celery_results' to INSTALLED_APPS inmyauth/settings/local.pyRun migrations:python manage.py migrateCollect and deploy static assets:python manage.py collectstaticPreload pricing informationpython manage.py miningtaxes_preload_pricesSet local settingsCELERY_RESULT_BACKEND = 'django-db'
CELERY_CACHE_BACKEND = 'django-cache'

MININGTAXES_PRICE_JANICE_API_KEY = "XXXX"
MININGTAXES_PRICE_METHOD = "Janice"

CELERYBEAT_SCHEDULE['miningtaxes_update_daily'] = {
    'task': 'miningtaxes.tasks.update_daily',
    'schedule':  crontab(minute=0, hour='1'),
}

# Notifiy everyone of their current taxes on the second day of every month.
CELERYBEAT_SCHEDULE['miningtaxes_notifications'] = {
    'task': 'miningtaxes.tasks.notify_taxes_due',
    'schedule': crontab(0, 0, day_of_month='2'),
}

# Charge interest and notify everyone on the 15th of every month.
CELERYBEAT_SCHEDULE['miningtaxes_apply_interest'] = {
    'task': 'miningtaxes.tasks.apply_interest',
    'schedule': crontab(0, 0, day_of_month='15'),
}Navigate to the admin panel and setup the accountants (1 per corp)Post-Setup instructionsAfter you have setup your accountants (1 per corp) in the Admin Setup panel, invite all the members of your corp to add their characters.If you enableMININGTAXES_TAX_ONLY_CORP_MOONS, remember that only moon mining of your corp moons will be taxes and other moons will be ignored.After everyone in the corp has added their characters, consider running to theminingtaxes_zero_allcommand to zero out everyone's taxes to prevent mining activity from the past from being taxed.When a new user joins your corp and adds their character to the plugin, also consider going into the audit tables and providing a tax credit so that it will zero out their past mining activity.Local settingsNameDescriptionDefaultMININGTAXES_UNKNOWN_TAX_RATEThe tax rate when a new type of ore is encountered that has not yet been added to the plugin in float (eg 0.10 means 10%)0.10MININGTAXES_TAX_ONLY_CORP_MOONSOnly tax corporate moons using moon observers as opposed to all moons appearing in the personal mining ledgers.TrueMININGTAXES_UPDATE_LEDGER_STALEMinutes after which a character's mining ledger is considered stale240MININGTAXES_REFINED_RATERefining rate for ores.0.9063MININGTAXES_ALWAYS_TAX_REFINEDAlways tax the refined rate instead of the raw ore price (if higher)FalseMININGTAXES_PRICE_METHODBy default Fuzzwork API will be used for pricing, if this is set to "Janice" then the Janice API will be used.FuzzworkMININGTAXES_PRICE_JANICE_API_KEYThe API key to access Janice API.MININGTAXES_PRICE_SOURCE_IDStation ID for fetching base prices. Supports IDs listed onFuzzworks API. Does not work with Janice API!60003760MININGTAXES_BLACKLISTList of system names that taxes should be ignored in. Case sensitive.[]MININGTAXES_TAX_HISECInclude taxing for mining activity in High Security SpaceTrueMININGTAXES_TAX_LOSECInclude taxing for mining activity in Low Security SpaceTrueMININGTAXES_TAX_NULLSECInclude taxing for mining activity in Null Security SpaceTrueMININGTAXES_TAX_JSPACEInclude taxing for mining activity in J-Space (Wormhole)TrueMININGTAXES_TAX_POCHVENInclude taxing for mining activity in Pochven (Trig Space)TruePermissionsNamePurposeExample Target Audiencebasic_accessCan access this app and see own tax information, current ore prices, and FAQ.Member Stateauditor_accessCan view everyone's tax information and see statistics on taxes.Auditorsadmin_accessCan set tax rate and add characters with the accountant role to pull information from the corp Master Wallet and the corp moons.LeadershipCommandsNameDescriptionminingtaxes_preload_pricesPreload all ores and refined materials from chosen Pricing API (Fuzzworks or Janice).miningtaxes_zero_allZero the tax balance of ALL characters.miningtaxes_update_manualTrigger a manual update for all data