1

EPrints は perl ベースのリポジトリです。WP の EPrints を参照してください。

私の司書は、次の方法で EPrins をセットアップするように私に依頼しました (「モノグラフ」タイプのドキュメントのみ)。

  1. 著者が 3 人以下の場合は、モノグラフのタイトルの前に「著者」を表示します。
  2. 3 人以上の著者がいる場合は、'$title / $authors' を出力します。

たとえば、最初の出版物には 7 人の著者が、2 番目の出版物には 2 人の著者がいます。

  1. ロシア語ウィクショナリーの引用コーパスの分析/ Smirnov A., Levashova T., Karpov A., Kipyatkova I., Ronzhin A., Krizhanovsky A., Krizhanovsky N. Research in Computing Science. 2012年
  2. Meyer CM, Gurevych I. Worth its Weight in Gold or Yet Another Resource - A Comparison Study of Wiktionary, OpenThesaurus and GermaNet . 2010年。
4

2 に答える 2

1

何度か試行錯誤を繰り返した結果... 大きな問題は、EPrints が純粋な Perl ではなく、ドキュメントがあまりないことです...

引用ファイル /eprints/cfg/citations/eprint/default.xmlを編集する必要があります)。次の解決策があります。

<!-- Monograph: if < 4 authors then print 'authors' before title -->
<when test="type = 'monograph'">

      <if test="is_set(creators_name)"> 

          <set name='authors' expr="creators_name">
              (Debug information) Number of authors: 
              <print expr="$authors.length()"/>.

              <set name='authors_len' expr="$authors.length()">

                  <if test="$authors_len lt 4">
                      <print expr="creators_name"/>
                  </if>
              </set>
          </set>
      </if> 
</when>

<!-- Title -->
<cite:linkhere><xhtml:em><print expr="title"/>:</xhtml:em></cite:linkhere>


<!-- "/ authors" after Title for monography if len(authors)>3 -->
<choose>
  <when test="type = 'monograph'">

      <if test="is_set(creators_name)"> 

          <set name='authors' expr="creators_name">
              <set name='authors_len' expr="$authors.length()">

                  <if test="$authors_len gt 3">
                     / <print expr="creators_name"/>
                  </if>

              </set>
          </set>
      </if>
  </when>

  <otherwise>
  </otherwise>
</choose>

それは機能しますが...同じ変数「authors_len」を2回計算しました。そして、この変数を再利用して一度だけ計算する方法がわかりません。

EPrints 関数 "is_set(authors_len)" を試し、"is_set($authors_len)" を試しましたが、EPrints は異なるエラー メッセージ o_O をスローします

于 2016-01-25T15:03:10.743 に答える