2013-02-20 69 views
1

標準的Django userena URL的期望用戶名是在URL中使用Django的userena但沒有用戶:我怎麼會在URL

/accounts/USER/ # for profile view 
/accounts/USER/edit/ # to edit the profile 

我的用戶配置文件都將被關閉,所以我寧願我的網址不包括用戶:

/accounts/ # would show the profile view (or signin if they aren't logged in) 
/accounts/edit/ # to edit the profile 

有沒有一種簡單的方法來做到這一點?

回答

1

瀏覽他們的文檔,它看起來不像它。您需要爲此編寫自己的url/views。

+0

顯然,正如girasquid所指出的那樣,沒有內置的東西 - 主要是因爲它們在各個地方對某些路徑進行了硬編碼,但也有一些其他假設。分叉我自己的副本,並破解它的工作。 – machomeautoguy 2013-02-25 17:29:30