3.2. Data Models

Below are the various data models in Eve W-Space.

3.2.1. core

class core.models.Alliance(*args, **kwargs)[source]

Represents an alliance, data pulled from api

class core.models.ConfigEntry(*args, **kwargs)[source]

A configuration setting that may be changed at runtime.

class core.models.Constellation(*args, **kwargs)[source]

Core model for static constellation data, references Region

class core.models.Corporation(*args, **kwargs)[source]

Represents a corporation, data pulled from api

class core.models.Faction(*args, **kwargs)[source]

Faction(id, name, description, iconid)

class core.models.Location(*args, **kwargs)[source]

Core model for SDD mapDenormalize table that generic locations map to.

class core.models.LocationWormholeClass(*args, **kwargs)[source]

Core model for SDD mapLocationWormholeClasses used to generate system tables.

class core.models.MarketGroup(*args, **kwargs)[source]

A market group from the Eve SDD.

class core.models.NewsFeed(*args, **kwargs)[source]

Contains information about an RSS feed. If user is None, the feed is global.

class core.models.Region(*args, **kwargs)[source]

Core model for static region data

class core.models.StarbaseResource(*args, **kwargs)[source]

Core model for SDD invStarbaseResources table. Maps tower types to their fuel

class core.models.StarbaseResourcePurpose(*args, **kwargs)[source]

Core model for SDD invControlTowerResourcePurpose table.

class core.models.SystemData(*args, **kwargs)[source]

Core model for static system data from the SDD, references Region and Constellation

class core.models.SystemJump(*args, **kwargs)[source]

Core model for SDD mapSolarSystemJumps used in A* calcs.

class core.models.Type(*args, **kwargs)[source]

A type from the Eve SDD invTypes table.

3.2.2. Map

class Map.models.Destination(*args, **kwargs)[source]

Represents a corp-wide destination whose range should be shown in the map.

class Map.models.KSystem(*args, **kwargs)[source]

KSystem(id, name, constellation_id, region_id, x, y, z, security, systemdata_ptr_id, sysclass, importance, occupied, info, lastscanned, npckills, podkills, shipkills, updated, first_visited, last_visited, system_ptr_id, sov, jumps)


Returns the light-year distance to the destination.


Returns the number of gate jumps to the destination by shortest route.

class Map.models.Map(*args, **kwargs)[source]

Stores the maps available in the map tool. root relates to System model.

add_log(user, action, visible=False)[source]

Adds a log entry into a MapLog for the map.

add_system(user, system, friendlyname, parent=None)[source]

Adds the provided system to the map with the provided friendly name. Returns the new MapSystem object.


Returns the json representation of the map for the mapping Javascript.


Clears the tooltip and json caches for the map.


Returns the highest permision that user has on the map. 0 = No Access 1 = Read Access 2 = Write Access

snapshot(user, name, description)[source]

Makes and returns a snapshot of the map.

class Map.models.MapLog(*args, **kwargs)[source]

Represents an action that has taken place on a map (e.g. adding a signature). This is used for pushing updates since last page load to clients.

class Map.models.MapPermission(*args, **kwargs)[source]

Relates a user group to it’s map permissions. Non-restricted groups will have change access to all maps.

class Map.models.MapSystem(*args, **kwargs)[source]

Stores information regarding which systems are active in which maps at the present time.

connect_to(system, topType, bottomType, topBubbled=False, bottomBubbled=False, timeStatus=0, massStatus=0)[source]

Connect self to system and add the connecting WH to map, self is the bottom system. Returns the connecting wormhole.


Removes the supplied system and all of its children.

class Map.models.Signature(*args, **kwargs)[source]

Stores the signatures active in all systems. Relates to System model.


Toggles the site activation.


Toggles the NPCs cleared.


Toggles the sig escalation.


Increments the downtime count and does downtime cleanup of updated and activated.

save(*args, **kwargs)[source]

Ensure that Sig IDs are proper.


Toggles ownership.


Mark the signature as having been updated since DT.

class Map.models.SignatureForm(data=None, files=None, auto_id=u'id_%s', prefix=None, initial=None, error_class=<class 'django.forms.util.ErrorList'>, label_suffix=None, empty_permitted=False, instance=None)[source]

This form should only be used with commit=False since it does not set the system or updated fields.

class Map.models.SignatureType(*args, **kwargs)[source]

Stores the list of possible signature types for the map tool. Custom signature types may be added at will.

class Map.models.SiteSpawn(*args, **kwargs)[source]

Contains the site spawn list for a site as HTML.

class Map.models.Snapshot(*args, **kwargs)[source]

Represents a snapshot of the JSON strings that are used to draw a map.

class Map.models.System(*args, **kwargs)[source]

Stores the permanent record of a solar system. This table should not have rows added or removed through Django.

class Map.models.WSystem(*args, **kwargs)[source]

WSystem(id, name, constellation_id, region_id, x, y, z, security, systemdata_ptr_id, sysclass, importance, occupied, info, lastscanned, npckills, podkills, shipkills, updated, first_visited, last_visited, system_ptr_id, static1_id, static2_id, effect)

class Map.models.Wormhole(*args, **kwargs)[source]

An instance of a wormhole in a map. Wormhole have a ‘top’ and a ‘bottom’, the top refers to the side that is found first (and the bottom is obviously the other side)

class Map.models.WormholeType(*args, **kwargs)[source]

Stores the permanent information on wormhole types. Any changes to this table should be made with caution.


Returns a readable destination. Cx for w-space and H, L, N otherwise.

3.2.3. POS

class POS.models.CorpPOS(*args, **kwargs)[source]

A corp-controlled POS with manager and password data.

class POS.models.POS(*args, **kwargs)[source]

Represents a POS somewhere in space.


Fills in a POS’s fitting from a copy / paste of d-scan results.


Fills in a POS’s fitting from an iterable (normally parsed d-scan)


Returns the size of the tower, Small Medium or Large.

class POS.models.POSApplication(*args, **kwargs)[source]

Represents an application for a personal POS.

class POS.models.POSVote(*args, **kwargs)[source]

Represents a vote on a personal POS application.

3.2.4. account

class account.models.EWSUser(*args, **kwargs)[source]

An abstract base class implementing a fully featured User model with admin-compliant permissions.

Username, password and email are required. Other fields are optional.

email_user(subject, message, from_email=None)[source]

Sends an email to this User.


Returns the first_name plus the last_name, with a space in between.


Returns the short name for the user.

update_location(sys_id, charid, charname, shipname, shiptype)[source]

Updates the cached locations dict for this user.

class account.models.GroupProfile(*args, **kwargs)[source]

GroupProfile defines custom fields tied to each Group record.

class account.models.RegistrationForm(data=None, files=None, auto_id=u'id_%s', prefix=None, initial=None, error_class=<class 'django.forms.util.ErrorList'>, label_suffix=None, empty_permitted=False, instance=None)[source]

Extends the django registration form to add fields.

account.models.create_group_profile(sender, instance, created, **kwargs)[source]

Handle group creation event and create a new group profile.

3.2.5. Alerts

class Alerts.models.Subscription(*args, **kwargs)[source]

Mapping table that relates Users to their subscriped SubscriptionGroups.

class Alerts.models.SubscriptionGroup(*args, **kwargs)[source]

Contians the definition for alert broadcast groups.

Returns a tuple of permissions for the subscription group as such:
(can_broadcast, can_join)

A user’s highest permissions in both are returned and special gorups will always return can_join = False.

class Alerts.models.SubscriptionGroupPermission(*args, **kwargs)[source]

Mapping table that relates Groups to their permissions for SubscriptionGroups.

3.2.6. API

class API.models.APIAccessGroup(*args, **kwargs)[source]

Stores the access mask access groups from the CallList call.

class API.models.APIAccessRequirement(*args, **kwargs)[source]

Stores the required access for member API keys for a corp.

class API.models.APIAccessType(*args, **kwargs)[source]

Stores the access masks and types pulled from the CallList call.

is_required_for_user(user, corp)[source]

Returns True if the APIAccessType is required for this user / corp. Also returns True if the APIAccessType is required for any of the user’s groups.


Returns True if the provided key allows this APIAccessType.

class API.models.APICharacter(*args, **kwargs)[source]

API Character contains the API security information of a single character.


Returns a list of titles for this character.

class API.models.APIGroupMapping(*args, **kwargs)[source]

Maps API-obtained corps and titles to Django groups.

class API.models.APIKey(*args, **kwargs)[source]

API Key object relates to User and contains key id, vcode, and validation information.

get_authenticated_api(cache_handler=<module 'API.cache_handler' from '/var/build/user_builds/eve-w-space/checkouts/develop/evewspace/API/cache_handler.pyc'>)[source]

Returns an eveapi api object with the proper auth context for this key. Uses the built-in cacheHandler by default.

class API.models.APIShipLog(*args, **kwargs)[source]

API Ship Log contains a timestamped record of a ship being flown by a character.

class API.models.CorpAPIKey(*args, **kwargs)[source]

Corp API keys used for corp stuff.


Returns a list of title names for this Corporation.


Validate a corp API key. Return False if invalid, True if valid.

Returns:bool – True if valid, False if invalid
class API.models.MemberAPIKey(*args, **kwargs)[source]

API key for individual member account.


Returns a list of Groups that this key is authorized for. The list will be empty if the key fails validation and the hard_fail permission is set.


Validate a character API key. Return False if invalid, True if valid.

Reutrns:bool – True if valid, False if invalid

3.2.7. SiteTracker

class SiteTracker.models.Claim(*args, **kwargs)[source]

Represents a User’s claim for a claim period.

class SiteTracker.models.ClaimPeriod(*args, **kwargs)[source]

Represents a claim period that Users can claim against.

class SiteTracker.models.Fleet(*args, **kwargs)[source]

Represents a SiteTracker fleet.


Return a list of active members.


Closes the SiteTracker fleet.

credit_site(site_type, system, boss)[source]

Credits a site.


Adds user to fleet.


Removes user from fleet.


Change the current fleet boss.

class SiteTracker.models.PayoutEntry(*args, **kwargs)[source]

Represents an entry in the payout report.

class SiteTracker.models.PayoutReport(*args, **kwargs)[source]

Represents a payout report and contains general information about the payout period.

class SiteTracker.models.SiteRecord(*args, **kwargs)[source]

Represents the record of a site run.


Return True if user’s credit is pending.

class SiteTracker.models.SiteRole(*args, **kwargs)[source]

Represents a role for a sitetracker fleet.

class SiteTracker.models.SiteType(*args, **kwargs)[source]

Represents a type of site that can be credited.

class SiteTracker.models.SiteWeight(*args, **kwargs)[source]

Represents the raw points available for a site type / system class combo

class SiteTracker.models.SystemWeight(*args, **kwargs)[source]

Respresents a multiplier for site credit for a system.

class SiteTracker.models.UserLog(*args, **kwargs)[source]

Represents a user’s sitetracker log.


Returns a list of site records which are pending credit.

class SiteTracker.models.UserSite(*args, **kwargs)[source]

Represents a user’s credit for a site.


Mark the site approved.

3.2.8. Recruitment

class Recruitment.models.Action(*args, **kwargs)[source]

Represents an action that can be taken on an application e.g Intel Ran

class Recruitment.models.AppAction(*args, **kwargs)[source]

Represents an action taken on an application.

class Recruitment.models.AppQuestion(*args, **kwargs)[source]

Represents a question to be asked on the application.

class Recruitment.models.AppResponse(*args, **kwargs)[source]

Represents a response to a custom application question.

class Recruitment.models.AppVote(*args, **kwargs)[source]

Represents a vote on an application

class Recruitment.models.Application(*args, **kwargs)[source]

Represents a recruitment application.

class Recruitment.models.Interest(*args, **kwargs)[source]

Represents an option for the ‘What are you interests? question’

class Recruitment.models.Interview(*args, **kwargs)[source]

Represents an interview for an application.

class Recruitment.models.StandigsRequirement(*args, **kwargs)[source]

Represents a standing to be checked against applications.

3.2.9. Teamspeak

class Teamspeak.models.GroupMap(*args, **kwargs)[source]

Maps Django user groups to Teamspeak groups.

class Teamspeak.models.TeamspeakServer(*args, **kwargs)[source]

Stores teamspeak server configuration.

3.2.10. Jabber

class Jabber.models.JabberAccount(*args, **kwargs)[source]

A jabber account to send messages to. JID is in user@host.tld format

class Jabber.models.JabberSubscription(*args, **kwargs)[source]

A registered User / Group combo for jabber.

3.2.11. Cart

class Cart.models.CartItem(*args, **kwargs)[source]

CartItem(id, cart_id, item_id, qty, unitcost)

class Cart.models.Request(*args, **kwargs)[source]

Request(id, originuser_id, totalcost, itemcount, corprequest, daterequested, datefilled, fillcost, deliveredto, datepaid, filluser_id)

class Cart.models.RequestItem(*args, **kwargs)[source]

RequestItem(id, request_id, item_id, qty, unitcost)

class Cart.models.ShoppingCart(*args, **kwargs)[source]

Represents an active shopping cart.