Skip to content

Commit

Permalink
rules: fix storing useraction created by a username of more than 100 …
Browse files Browse the repository at this point in the history
…chars
  • Loading branch information
biolds authored and regit committed Jun 5, 2018
1 parent 48ed2d0 commit 0ac3d59
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 1 deletion.
20 changes: 20 additions & 0 deletions rules/migrations/0062_useraction_username.py
@@ -0,0 +1,20 @@
# -*- coding: utf-8 -*-
# Generated by Django 1.11.13 on 2018-06-05 08:21
from __future__ import unicode_literals

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('rules', '0061_auto_20180507_1410'),
]

operations = [
migrations.AlterField(
model_name='useraction',
name='username',
field=models.CharField(max_length=150),
),
]
2 changes: 1 addition & 1 deletion rules/models.py
Expand Up @@ -228,7 +228,7 @@ class UserAction(models.Model):
date = models.DateTimeField('event date', default=timezone.now)
comment = models.TextField(null=True, blank=True)
user = models.ForeignKey(User, default=None, on_delete=models.SET_NULL, null=True, blank=True)
username = models.CharField(max_length=100)
username = models.CharField(max_length=150)
ua_objects = GenericRelation('UserActionObject', related_query_name='ua_objects')

# Compatibilty
Expand Down

0 comments on commit 0ac3d59

Please sign in to comment.