To check out this repository please hg clone the following URL, or open the URL using EasyMercurial or your preferred Mercurial client.
root / plugins / redmine_bibliography / app / models / bibtex_entry_type.rb @ 1432:ebda59ca84db
History | View | Annotate | Download (1.7 KB)
| 1 | 542:23a9272bf766 | luis | class BibtexEntryType < ActiveRecord::Base |
|---|---|---|---|
| 2 | 946:a0c9cc95bcf3 | luis | unloadable |
| 3 | 685:4481db876cdb | luis | |
| 4 | 1394:0f918e37e1d6 | luis | @@fields = Hash['article', ['journal', 'year', 'volume', 'number', 'pages', 'month', 'note' ], |
| 5 | 685:4481db876cdb | luis | 'book' , [ 'editor', 'publisher', 'volume', 'series', 'address', 'edition', 'month', 'year', 'note' ], |
| 6 | 'booklet' , [ 'howpublished', 'address', 'year', 'month', 'note', 'key' ], |
||
| 7 | 'conference', [ 'booktitle', 'year', 'editor', 'pages', 'organization', 'publisher', 'address', 'month', 'note' ], |
||
| 8 | 'inbook', [ 'editor', 'publisher', 'chapter', 'pages', 'volume', 'series', 'address', 'edition', 'year', 'note' ], |
||
| 9 | 'incollection', [ 'editor', 'publisher', 'chapter', 'pages', 'volume', 'series', 'address', 'edition', 'year', 'note' ], |
||
| 10 | 'inproceedings', [ 'booktitle', 'year', 'editor', 'pages', 'organization', 'publisher', 'address', 'month', 'note' ], |
||
| 11 | 'manual', [ 'organization', 'address', 'edition', 'month', 'year', 'note' ], |
||
| 12 | 'masterthesis', [ 'school', 'year', 'address', 'month', 'note' ], |
||
| 13 | 'misc', [ 'howpublished', 'month', 'year', 'note' ], |
||
| 14 | 'phdthesis', [ 'school', 'year', 'address', 'month', 'note' ], |
||
| 15 | 'proceedings', [ 'booktitle', 'year', 'editor', 'pages', 'organization', 'publisher', 'address', 'month', 'note' ], |
||
| 16 | 'techreport', [ 'year', 'type', 'number', 'address', 'month', 'note' ], |
||
| 17 | 'unpublished', [ 'note', 'month', 'year' ]] |
||
| 18 | |||
| 19 | 586:658cfb481618 | chris | def redundant? |
| 20 | name == 'conference' # conference is a duplicate of inproceedings |
||
| 21 | end
|
||
| 22 | 685:4481db876cdb | luis | |
| 23 | 586:658cfb481618 | chris | def label |
| 24 | l("field_bibtex_#{name}")
|
||
| 25 | end
|
||
| 26 | 685:4481db876cdb | luis | |
| 27 | def self.fields (type) |
||
| 28 | 1394:0f918e37e1d6 | luis | @@fields[ self.find(type).name ] |
| 29 | 685:4481db876cdb | luis | end
|
| 30 | 542:23a9272bf766 | luis | end |