2015-05-19 46 views
0

我在文檔中按照這些步驟(http://docs.ckan.org/en/latest/extensions/adding-custom-fields.html)在數據集來源中添加了額外的字段。CKAN - 在輸入值和更新數據集表單後,附加字段不會顯示在附加信息中

我能夠獲得額外的領域顯示在數據集表單的「管理」頁面。但是,在輸入額外字段的值並更新數據集表單後,額外字段不會顯示在摘要頁面中...

任何人都知道如何解決此問題?非常感謝 !

回答

1

您必須更新您提到的教程的CKAN模板follow the instructions

E.g.在package/snippets/additional_info.html中加入:

{% ckan_extends %} 

{% block extras %} 
    {% if pkg_dict.custom_text %} 
    <tr> 
     <th scope="row" class="dataset-label">{{ _("Custom Text") }}</th> 
     <td class="dataset-details">{{ pkg_dict.custom_text }}</td> 
    </tr> 
    {% endif %} 
{% endblock %}