# HG changeset patch # User neko259 # Date 2013-08-28 12:07:21 # Node ID 449be9e64990fac01beb9f8031410667e261f929 # Parent b129e048885c46f9c1b650ee52130c65a95a1387 Added refmaps for the threads list. diff --git a/boards/authors.py b/boards/authors.py --- a/boards/authors.py +++ b/boards/authors.py @@ -10,5 +10,15 @@ authors = { 'name': 'Ilyas Babayev', 'contacts': ['zamesilyasa@gmail.com'], 'roles': ['author', 'developer'], - } + }, + 'ritsufag': { + 'name': 'Aiko Kirino', + 'contacts': ['ritsufag@gmail.com'], + 'roles': ['javascript developer', 'designer'], + }, + 'Tenno Seremel': { + 'name': 'anonymous', + 'contacts': ['html@serenareem.net'], + 'roles': ['javascript developer', 'designer'], + }, } \ No newline at end of file diff --git a/boards/locale/ru/LC_MESSAGES/django.mo b/boards/locale/ru/LC_MESSAGES/django.mo index d88197738e1c31bc82a3f6e7ba0737a254693806..fab2a85e6c2bce0efffefc5e0bacd7014b0a845e GIT binary patch literal 2485 zc$|$>+iw(Q6#vAfmlag-enGz)K@exzZM`&07g^}GH14*w-Qq18r`?ZsWOrtnnWZ%F z(1M_(NWH{MAYL$r2NRRhi(Oh;{sB$Ci4Q)Q_+sKCFTQBvgTM2A(-sm)oMh(r%{jkw z&hMNv^ZUlgrwrEiQda2k;+YEpYAajNK1h58MEJ5_li*d0;&- z3yc8whxi6?E%0sNdf)-zW}pwO0iFwa7l2XVMc^aAOJUs4z`KCIg#JH5{xx77@UM{f zZ)jhGM+>kvqTgF1+TRgk7m!-(3;nM~w2n7JEJSpl2SfBi-cdZ}Fq_ec*3%5~I^aIw zcFI?yXE+9Y3iuuHPT)^9TK8`?I^Ul)dVbe{+i0FJz5?6<+z5Ox#B;UU{{yfc_-n1s z^LU-!)6;c2PkWu_zZK%4Iz5+nL;L`bQ^3#abo{1zZQok2`H6aMZw1~<^QqT)3-!9c zqapA8dfm_YkpDdp<4`fQcgjiM0oI^+bVWj>y>AT9G$Y#YJxuT60j9sNbItuznPM0>eAml3^(ji?ea(~DbX2E0Wia+GI9@}Gj z)&MV=?!kgHY;$kK_RS+Pwihg4a9a$A5v%P$JnS7!ZA zvA`79W0r3gtpSExKrVBk&w|;f!riX(ju`Nbj)Jitqp%!1$-C2gUrM)U`2I{!Z%0>W zlp1h-Bj*iT1!GTT&@=K*l1IC{@`hRsf{a!*+QxXI$%r=_jW6)VrsQ*p?eV5~97Ll> z9Jahw-fNk3kCE##TGM=AS2EYJ{q?TSOq8}{w*B!cX<(+l=N_9tk@jTq9!-I0Y;)$(#EvKiXZaxMtC4 zbKH`bhaQqR&+MZ{YY zaenNW4gn{=4KWGCG;Z4&W%A=-OwRJ)xSW+&f^jB4lv8+F3P$PWBRMJOsw|VA5VwKJFO;lHD#MTD27eZTlvpmnFay&p z8Y7n0qRfg%IWM5#I85`hN?IpDM1?6OWt^k-lAMP6;~YiCbw^XA8TG\n" "Language-Team: LANGUAGE \n" @@ -173,4 +173,10 @@ msgstr "Последнее обновление: " #~ msgstr "автор" #~ msgid "developer" -#~ msgstr "разработчик" \ No newline at end of file +#~ msgstr "разработчик" + +#~ msgid "javascript developer" +#~ msgstr "разработчик javascript" + +#~ msgid "designer" +#~ msgstr "дизайнер" diff --git a/boards/static/js/main.js b/boards/static/js/main.js --- a/boards/static/js/main.js +++ b/boards/static/js/main.js @@ -11,4 +11,6 @@ openEffect: 'none', closeEffect: 'none' }); + + addRefLinkMap(); }) diff --git a/boards/static/js/thread.js b/boards/static/js/thread.js --- a/boards/static/js/thread.js +++ b/boards/static/js/thread.js @@ -95,44 +95,6 @@ function addQuickReply(postId) { $("html, body").animate({ scrollTop: $(textAreaId).offset().top }, "slow"); } -function addRefLinkMap() { - var postByNum = [], refMap = []; - - $('.post').each(function() { - var self = $(this); - - var postNum = self.attr('id'); - //add post by id - postByNum[postNum] = self; - //add ref link - self.find('p').children('a').each(function() { - if($(this).text().indexOf('>>') == 0) { - var refNum = $(this).text().match(/\d+/); - - if(postByNum[refNum]) { - if(!refMap[refNum]) - refMap[refNum] = []; - - //if !exist - if((',' + refMap[refNum].toString() + ',').indexOf(',' + postNum + ',') < 0) { - refMap[refNum].push(postNum); - }; - } - } - }); - }); - - var label_replies = gettext('Replies') + ':'; - for(var pNum in refMap) { - if(typeof refMap[pNum] === 'object') { - //append refmap panel - if(!$("#refmap_"+pNum).length) { - var data = label_replies + refMap[pNum].toString().replace(/(\d+)/g, ' >>$1'); - $('#'+pNum+'').find('.message').after($('
'+data+'
')); - } - } - } -} $(document).ready(function(){ diff --git a/boards/templates/boards/base.html b/boards/templates/boards/base.html --- a/boards/templates/boards/base.html +++ b/boards/templates/boards/base.html @@ -21,7 +21,8 @@ - + +
@@ -50,4 +51,4 @@
- \ No newline at end of file + diff --git a/boards/templates/boards/posting_general.html b/boards/templates/boards/posting_general.html --- a/boards/templates/boards/posting_general.html +++ b/boards/templates/boards/posting_general.html @@ -23,9 +23,9 @@ {% for thread in threads %}
{% if thread.can_bump %} -
+
{% else %} -
+
{% endif %} {% if thread.image %}
@@ -67,9 +67,9 @@
{% for post in thread.get_last_replies %} {% if thread.can_bump %} -
+
{% else %} -
+
{% endif %} {% if post.image %}
diff --git a/boards/templates/boards/thread.html b/boards/templates/boards/thread.html --- a/boards/templates/boards/thread.html +++ b/boards/templates/boards/thread.html @@ -113,4 +113,4 @@ {% trans 'Last update: ' %}{{ posts.0.last_edit_time }} -{% endblock %} \ No newline at end of file +{% endblock %}