changeset 1023:3d924264419a bibplugin_bibtex_display

few CSS tweaks
author luisf <luis.figueira@eecs.qmul.ac.uk>
date Tue, 13 Nov 2012 11:20:59 +0000
parents 63f8c4f2cf67
children 503ed68a4e0f b0e0ffb43fa1
files vendor/plugins/redmine_bibliography/app/models/publication.rb vendor/plugins/redmine_bibliography/app/views/projects/_bibliography_box.html.erb vendor/plugins/redmine_bibliography/assets/stylesheets/bibliography.css
diffstat 3 files changed, 17 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/vendor/plugins/redmine_bibliography/app/models/publication.rb	Mon Nov 12 20:16:35 2012 +0000
+++ b/vendor/plugins/redmine_bibliography/app/models/publication.rb	Tue Nov 13 11:20:59 2012 +0000
@@ -82,9 +82,11 @@
     end
     
     if style == :ieee
-      CiteProc.process bib.to_citeproc, :style => :ieee, :format => :html
-    else
-      bib.to_s :include => :meta_content
+      CiteProc.process bib.to_citeproc, :style => :ieee, :format => :html      
+    else 
+      bibtex = bib.to_s :include => :meta_content
+      bibtex.strip!
+      logger.error { bibtex }
     end  
   end
 end
--- a/vendor/plugins/redmine_bibliography/app/views/projects/_bibliography_box.html.erb	Mon Nov 12 20:16:35 2012 +0000
+++ b/vendor/plugins/redmine_bibliography/app/views/projects/_bibliography_box.html.erb	Tue Nov 13 11:20:59 2012 +0000
@@ -20,9 +20,7 @@
          <%= link_to_function "[Bibtex]", onclick="toggleBibtex(this)" -%> 
        </dd>
        <dd class="bibtex-textarea collapsed" style="display: none;">
-         <textarea> 
-           <%= publication.print_entry(:bibtex) -%>         
-         </textarea>         
+         <textarea readonly><%= publication.print_entry(:bibtex) -%></textarea>         
        </dd>
    <% end -%>
      </dl>
--- a/vendor/plugins/redmine_bibliography/assets/stylesheets/bibliography.css	Mon Nov 12 20:16:35 2012 +0000
+++ b/vendor/plugins/redmine_bibliography/assets/stylesheets/bibliography.css	Tue Nov 13 11:20:59 2012 +0000
@@ -47,5 +47,15 @@
   margin-left: 25px;
 }
 
+div#bibliography h3 { 
+  background: url(../../../images/table_multiple.png) no-repeat 0% 50%; 
+  padding-left: 20px;
+}
 
-div#bibliography h3 { background: url(../../../images/table_multiple.png) no-repeat 0% 50%; padding-left: 20px; }
+div#bibliography textarea {
+  width: 90%;
+  height: 200px;
+  font: normal 8px;
+  padding: 2px 10px;
+  border: solid 1px #ddd;  
+}
\ No newline at end of file