mirror of
				https://gitlab.ub.uni-bielefeld.de/sfb1288inf/nopaque.git
				synced 2025-11-04 04:12:45 +00:00 
			
		
		
		
	Corpus List update
This commit is contained in:
		@@ -48,7 +48,8 @@
 | 
			
		||||
  'js/ResourceLists/TesseractOCRPipelineModelList.js',
 | 
			
		||||
  'js/ResourceLists/UserList.js',
 | 
			
		||||
  'js/ResourceLists/AdminUserList.js',
 | 
			
		||||
  'js/ResourceLists/CorpusFollowerList.js'
 | 
			
		||||
  'js/ResourceLists/CorpusFollowerList.js',
 | 
			
		||||
  'js/ResourceLists/DetailledPublicCorpusList.js'
 | 
			
		||||
%}
 | 
			
		||||
<script src="{{ ASSET_URL }}"></script>
 | 
			
		||||
{%- endassets %}
 | 
			
		||||
 
 | 
			
		||||
@@ -270,7 +270,7 @@ publicCorpusFollowerList.add(
 | 
			
		||||
{% endif %}
 | 
			
		||||
 | 
			
		||||
// #region Build Corpus Request
 | 
			
		||||
{% if cfr.has_permission('MANAGE_CORPUS') %}
 | 
			
		||||
{% if cfr.has_permission('MANAGE_FILES') %}
 | 
			
		||||
let followerBuildRequest = document.querySelector('#follower-build-request');
 | 
			
		||||
followerBuildRequest.addEventListener('click', () => {
 | 
			
		||||
  Requests.corpora.entity.build({{ corpus.hashid|tojson }})
 | 
			
		||||
 
 | 
			
		||||
@@ -143,7 +143,7 @@
 | 
			
		||||
  corpusList.add(
 | 
			
		||||
    [
 | 
			
		||||
      {% for corpus in corpora %}
 | 
			
		||||
      {{ corpus.to_json_serializeable(backrefs=True)|tojson }},
 | 
			
		||||
      {{ corpus.to_json_serializeable(backrefs=True, relationships=True)|tojson }},
 | 
			
		||||
      {% endfor %}
 | 
			
		||||
    ]
 | 
			
		||||
  );
 | 
			
		||||
 
 | 
			
		||||
@@ -70,11 +70,11 @@
 | 
			
		||||
      {% endfor %}
 | 
			
		||||
    ]
 | 
			
		||||
  );
 | 
			
		||||
  let publicCorpusList = new PublicCorpusList(document.querySelector('.public-corpus-list'));
 | 
			
		||||
  let publicCorpusList = new DetailledPublicCorpusList(document.querySelector('.public-corpus-list'));
 | 
			
		||||
  publicCorpusList.add(
 | 
			
		||||
    [
 | 
			
		||||
      {% for corpus in corpora %}
 | 
			
		||||
      {{ corpus.to_json_serializeable(backrefs=True)|tojson }},
 | 
			
		||||
      {{ corpus.to_json_serializeable(backrefs=True, relationships=True)|tojson }},
 | 
			
		||||
      {% endfor %}
 | 
			
		||||
    ]
 | 
			
		||||
  );
 | 
			
		||||
 
 | 
			
		||||
@@ -127,7 +127,7 @@ followedCorpusList.add(
 | 
			
		||||
  [
 | 
			
		||||
    {% for corpus in user.followed_corpora %}
 | 
			
		||||
      {% if (corpus.is_public or corpus.user == current_user or user == current_user or current_user.is_following_corpus(corpus)) %}
 | 
			
		||||
      {{ corpus.to_json_serializeable(backrefs=True)|tojson }},
 | 
			
		||||
      {{ corpus.to_json_serializeable(backrefs=True, relationships=True)|tojson }},
 | 
			
		||||
      {% endif %}
 | 
			
		||||
    {% endfor %}
 | 
			
		||||
  ]
 | 
			
		||||
@@ -137,7 +137,7 @@ publicCorpusList.add(
 | 
			
		||||
  [
 | 
			
		||||
    {% for corpus in user.corpora %}
 | 
			
		||||
      {% if corpus.is_public %}
 | 
			
		||||
      {{ corpus.to_json_serializeable(backrefs=True)|tojson }},
 | 
			
		||||
      {{ corpus.to_json_serializeable(backrefs=True, relationships=True)|tojson }},
 | 
			
		||||
      {% endif %}
 | 
			
		||||
    {% endfor %}
 | 
			
		||||
  ]
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user