sethelp db help entry creation fix, @laxy_property removed
evennia.web.website.tests all pass evennia.commands.default.tests.TestHelp all pass (sethelp command test is in that unit test)
This commit is contained in:
parent
a661e4801b
commit
8eb7ffa70b
3 changed files with 17 additions and 16 deletions
|
|
@ -57,10 +57,6 @@ class HelpEntry(SharedMemoryModel):
|
|||
"help key", max_length=255, unique=True, help_text="key to search for"
|
||||
)
|
||||
|
||||
@lazy_property
|
||||
def key(self):
|
||||
return self.db_key
|
||||
|
||||
# help category
|
||||
db_help_category = models.CharField(
|
||||
"help category",
|
||||
|
|
@ -69,10 +65,6 @@ class HelpEntry(SharedMemoryModel):
|
|||
help_text="organizes help entries in lists",
|
||||
)
|
||||
|
||||
@lazy_property
|
||||
def help_category(self):
|
||||
return self.db_help_category
|
||||
|
||||
# the actual help entry text, in any formatting.
|
||||
db_entrytext = models.TextField(
|
||||
"help entry", blank=True, help_text="the main body of help text"
|
||||
|
|
@ -233,11 +225,10 @@ class HelpEntry(SharedMemoryModel):
|
|||
"""
|
||||
|
||||
try:
|
||||
url = reverse(
|
||||
return reverse(
|
||||
"%s-detail" % slugify(self._meta.verbose_name),
|
||||
kwargs={"category": slugify(self.db_help_category), "topic": slugify(self.db_key)},
|
||||
)
|
||||
return url
|
||||
except Exception:
|
||||
return "#"
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue