mirror of
https://github.com/evennia/evennia.git
synced 2026-03-21 23:36:30 +01:00
Last point where Player & Account coexist - migrate here first.
This commit is contained in:
parent
63c96de443
commit
34443fa4e6
6 changed files with 65 additions and 15 deletions
27
evennia/comms/migrations/0015_auto_20170706_2041.py
Normal file
27
evennia/comms/migrations/0015_auto_20170706_2041.py
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# Generated by Django 1.11.2 on 2017-07-06 20:41
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.db import migrations
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('comms', '0014_auto_20170705_1736'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.RemoveField(
|
||||
model_name='channeldb',
|
||||
name='db_subscriptions',
|
||||
),
|
||||
migrations.RemoveField(
|
||||
model_name='msg',
|
||||
name='db_receivers_players',
|
||||
),
|
||||
migrations.RemoveField(
|
||||
model_name='msg',
|
||||
name='db_sender_players',
|
||||
),
|
||||
]
|
||||
|
|
@ -80,9 +80,6 @@ class Msg(SharedMemoryModel):
|
|||
# Sender is either a player, an object or an external sender, like
|
||||
# an IRC channel; normally there is only one, but if co-modification of
|
||||
# a message is allowed, there may be more than one "author"
|
||||
# TODO Player-Account
|
||||
db_sender_players = models.ManyToManyField("players.PlayerDB", related_name='sender_player_set',
|
||||
blank=True, verbose_name='sender(player)', db_index=True)
|
||||
db_sender_accounts = models.ManyToManyField("accounts.AccountDB", related_name='sender_account_set',
|
||||
blank=True, verbose_name='sender(account)', db_index=True)
|
||||
|
||||
|
|
@ -96,9 +93,6 @@ class Msg(SharedMemoryModel):
|
|||
# The destination objects of this message. Stored as a
|
||||
# comma-separated string of object dbrefs. Can be defined along
|
||||
# with channels below.
|
||||
# TODO Player-Account
|
||||
db_receivers_players = models.ManyToManyField('players.PlayerDB', related_name='receiver_player_set',
|
||||
blank=True, help_text="player receivers")
|
||||
db_receivers_accounts = models.ManyToManyField('accounts.AccountDB', related_name='receiver_account_set',
|
||||
blank=True, help_text="account receivers")
|
||||
|
||||
|
|
@ -615,9 +609,6 @@ class ChannelDB(TypedObject):
|
|||
- db_object_subscriptions: The Object subscriptions.
|
||||
|
||||
"""
|
||||
# TODO Player-Account
|
||||
db_subscriptions = models.ManyToManyField("players.PlayerDB",
|
||||
related_name="subscription_set", blank=True, verbose_name='subscriptions', db_index=True)
|
||||
db_account_subscriptions = models.ManyToManyField("accounts.AccountDB",
|
||||
related_name="account_subscription_set", blank=True, verbose_name='account subscriptions', db_index=True)
|
||||
|
||||
|
|
|
|||
19
evennia/objects/migrations/0009_remove_objectdb_db_player.py
Normal file
19
evennia/objects/migrations/0009_remove_objectdb_db_player.py
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# Generated by Django 1.11.2 on 2017-07-06 20:41
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.db import migrations
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('objects', '0008_auto_20170705_1736'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.RemoveField(
|
||||
model_name='objectdb',
|
||||
name='db_player',
|
||||
),
|
||||
]
|
||||
|
|
@ -170,9 +170,6 @@ class ObjectDB(TypedObject):
|
|||
# will automatically save and cache the data more efficiently.
|
||||
|
||||
# If this is a character object, the player is connected here.
|
||||
# TODO Player-Account
|
||||
db_player = models.ForeignKey("players.PlayerDB", null=True, verbose_name='player', on_delete=models.SET_NULL,
|
||||
help_text='a Player connected to this object, if any.')
|
||||
db_account = models.ForeignKey("accounts.AccountDB", null=True, verbose_name='account', on_delete=models.SET_NULL,
|
||||
help_text='an Account connected to this object, if any.')
|
||||
|
||||
|
|
|
|||
19
evennia/scripts/migrations/0011_remove_scriptdb_db_player.py
Normal file
19
evennia/scripts/migrations/0011_remove_scriptdb_db_player.py
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
# Generated by Django 1.11.2 on 2017-07-06 20:41
|
||||
from __future__ import unicode_literals
|
||||
|
||||
from django.db import migrations
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
('scripts', '0010_auto_20170705_1736'),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.RemoveField(
|
||||
model_name='scriptdb',
|
||||
name='db_player',
|
||||
),
|
||||
]
|
||||
|
|
@ -86,9 +86,6 @@ class ScriptDB(TypedObject):
|
|||
# A reference to the database object affected by this Script, if any.
|
||||
db_obj = models.ForeignKey("objects.ObjectDB", null=True, blank=True, verbose_name='scripted object',
|
||||
help_text='the object to store this script on, if not a global script.')
|
||||
# TODO Player-Account
|
||||
db_player = models.ForeignKey("players.PlayerDB", null=True, blank=True, verbose_name="scripted player",
|
||||
help_text='the player to store this script on (should not be set if obj is set)')
|
||||
db_account = models.ForeignKey("accounts.AccountDB", null=True, blank=True, verbose_name="scripted account",
|
||||
help_text='the account to store this script on (should not be set if db_obj is set)')
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue