tg-prepare 1.0.0__py3-none-any.whl → 1.1.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of tg-prepare might be problematic. Click here for more details.
- {tg_prepare-1.0.0.dist-info → tg_prepare-1.1.0.dist-info}/METADATA +1 -1
- {tg_prepare-1.0.0.dist-info → tg_prepare-1.1.0.dist-info}/RECORD +16 -23
- tgp_backend/directories.py +0 -4
- tgp_backend/project.py +9 -9
- tgp_backend/tgclient.py +0 -1
- tgp_ui/app.py +9 -11
- tgp_ui/static/js/main.js +48 -13
- tgp_ui/templates/layout.html +73 -32
- tgp_ui/templates/macros.html +28 -25
- tgp_ui/templates/project.html +4 -3
- tgp_ui/templates/projects.html +1 -1
- tgp_ui/templates/publication.html +156 -0
- tgp_ui/static/js/jstree.min.js +0 -3
- tgp_ui/templates/empty.html +0 -4
- tgp_ui/templates/jsfiler.html +0 -6
- tgp_ui/templates/layout2.html +0 -99
- tgp_ui/templates/main.html +0 -5
- tgp_ui/templates/project_nxc.html +0 -37
- tgp_ui/templates/publish.html +0 -120
- tgp_ui/templates/tei_browser.html +0 -14
- {tg_prepare-1.0.0.dist-info → tg_prepare-1.1.0.dist-info}/WHEEL +0 -0
- {tg_prepare-1.0.0.dist-info → tg_prepare-1.1.0.dist-info}/entry_points.txt +0 -0
- {tg_prepare-1.0.0.dist-info → tg_prepare-1.1.0.dist-info}/licenses/LICENSE +0 -0
- {tg_prepare-1.0.0.dist-info → tg_prepare-1.1.0.dist-info}/top_level.txt +0 -0
tgp_ui/templates/layout2.html
DELETED
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
<!DOCTYPE html>
|
|
2
|
-
<html lang="en">
|
|
3
|
-
|
|
4
|
-
<head>
|
|
5
|
-
<meta charset="utf-8" />
|
|
6
|
-
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no" />
|
|
7
|
-
<meta name="description" content="" />
|
|
8
|
-
<meta name="author" content="" />
|
|
9
|
-
<title>{{ title }}</title>
|
|
10
|
-
<link rel="icon" type="image/x-icon" href="{{ url_for('static', filename='img/favicon.ico') }}" />
|
|
11
|
-
<link rel="stylesheet" type="text/css" href="{{ url_for('static', filename='css/bootstrap.min.css') }}" />
|
|
12
|
-
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.11.3/font/bootstrap-icons.min.css">
|
|
13
|
-
<link rel="stylesheet" type="text/css" href="{{ url_for('static', filename='css/simpleXML.css') }}" />
|
|
14
|
-
<link rel="stylesheet" type="text/css" href="{{ url_for('static', filename='css/main.css') }}" />
|
|
15
|
-
</head>
|
|
16
|
-
|
|
17
|
-
<body>
|
|
18
|
-
<div class="wrapper">
|
|
19
|
-
<aside id="sidebar" class="expand">
|
|
20
|
-
<div class="d-flex">
|
|
21
|
-
<button class="toggle-btn" type="button">
|
|
22
|
-
<i class="bi bi-grid"></i>
|
|
23
|
-
</button>
|
|
24
|
-
<div class="sidebar-logo">
|
|
25
|
-
<a href="#">{{ title }}</a>
|
|
26
|
-
</div>
|
|
27
|
-
</div>
|
|
28
|
-
<ul class="sidebar-nav">
|
|
29
|
-
<li class="sidebar-item">
|
|
30
|
-
<a href={{ url_for("projects") }} class="sidebar-link" title="Projects">
|
|
31
|
-
<i class="bi bi-view-list"></i>
|
|
32
|
-
<span>Overview</span>
|
|
33
|
-
</a>
|
|
34
|
-
</li>
|
|
35
|
-
{% for project in get_projects() %}
|
|
36
|
-
<li class="sidebar-item">
|
|
37
|
-
<a href="{{ url_for('project', projectname=project.name) }}" class="sidebar-link"
|
|
38
|
-
data-bs-target="#project_{{ loop.index }}" aria-expanded="false"
|
|
39
|
-
aria-controls="project_{{ loop.index }}">
|
|
40
|
-
{% if current_project == project.name %}
|
|
41
|
-
<i class="bi bi-circle-fill"></i>
|
|
42
|
-
{% else %}
|
|
43
|
-
<i class="bi bi-circle"></i>
|
|
44
|
-
{% endif %}
|
|
45
|
-
<span>{{ project.name }}</span>
|
|
46
|
-
</a>
|
|
47
|
-
<ul id="project_{{ loop.index }}"
|
|
48
|
-
class="sidebar-dropdown nav list-unstyled ps-3 {{ 'collapse' if current_project != project.name }}"
|
|
49
|
-
data-bs-parent="#sidebar">
|
|
50
|
-
<li class="sidebar-item">
|
|
51
|
-
<a class="sidebar-link nav-link" data-bs-toggle="tab" href="#tab_storage" role="tab"
|
|
52
|
-
aria-controls="tab_storage" aria-selected="false">
|
|
53
|
-
<i class="bi bi-folder2-open"></i>
|
|
54
|
-
Storage
|
|
55
|
-
</a>
|
|
56
|
-
</li>
|
|
57
|
-
{% for c in project.collections %}
|
|
58
|
-
{% set collection_config = project.collections[c]['config'] %}
|
|
59
|
-
<li class="sidebar-item">
|
|
60
|
-
<a class="sidebar-link nav-link collection-tab" data-bs-toggle="tab" href="#tab_{{ c }}"
|
|
61
|
-
role="tab" aria-controls="tab_{{ c }} aria-selected=" false"
|
|
62
|
-
data-url="{{ url_for('collection', projectname=project.name, name=c) }}"
|
|
63
|
-
data-name="{{ c }}">
|
|
64
|
-
<i class="spinner-border spinner-border-sm" role="status" style="display:none;"></i>
|
|
65
|
-
<i class="bi bi-{{ loop.index }}-circle"></i>
|
|
66
|
-
{{collection_config.short_title}}
|
|
67
|
-
</a>
|
|
68
|
-
</li>
|
|
69
|
-
{% endfor %}
|
|
70
|
-
<li class="sidebar-item">
|
|
71
|
-
<a class="sidebar-link nav-link" data-bs-toggle="tab" href="#tab_publish" role="tab"
|
|
72
|
-
aria-controls="tab_publish" aria-selected="false">
|
|
73
|
-
<i class="bi bi-cloud-upload"></i>
|
|
74
|
-
Publish
|
|
75
|
-
</a>
|
|
76
|
-
</li>
|
|
77
|
-
</ul>
|
|
78
|
-
</li>
|
|
79
|
-
{% endfor %}
|
|
80
|
-
</aside>
|
|
81
|
-
<div class="main p-3">
|
|
82
|
-
<div class="text-center">
|
|
83
|
-
<h1>
|
|
84
|
-
<span>
|
|
85
|
-
{{ sub_title }}
|
|
86
|
-
</span>
|
|
87
|
-
</h1>
|
|
88
|
-
</div>
|
|
89
|
-
{% block content %}{% endblock content %}
|
|
90
|
-
</div>
|
|
91
|
-
</div>
|
|
92
|
-
<script src="{{ url_for('static', filename='js/jquery.min.js') }}"></script>
|
|
93
|
-
<script src="{{ url_for('static', filename='js/bootstrap.bundle.min.js') }}"></script>
|
|
94
|
-
<script src="{{ url_for('static', filename='js/simpleXML.js') }}"></script>
|
|
95
|
-
<script src="{{ url_for('static', filename='js/main.js') }}"></script>
|
|
96
|
-
</script>
|
|
97
|
-
</body>
|
|
98
|
-
|
|
99
|
-
</html>
|
tgp_ui/templates/main.html
DELETED
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
{% extends 'layout2.html' %}
|
|
2
|
-
{% block content %}
|
|
3
|
-
<div class="row">
|
|
4
|
-
<div class="tab-content pt-2" id="tab-content">
|
|
5
|
-
<div class="tab-pane {{'active' if tab=='upload' }}" id="tab_upload" role="tabpanel">
|
|
6
|
-
{% include 'file_upload.html' %}
|
|
7
|
-
</div>
|
|
8
|
-
<div class="tab-pane {{'active' if tab=='files' }}" id="tab_files" role="tabpanel">
|
|
9
|
-
{% for item in project.list_files_and_folder() %}
|
|
10
|
-
{% include 'file_tree.html' %}
|
|
11
|
-
{% endfor %}
|
|
12
|
-
</div>
|
|
13
|
-
{% for c in project.collections %}
|
|
14
|
-
{% set collection_config = project.collections[c]['config'] %}
|
|
15
|
-
<div class="tab-pane {{'active' if tab==collection_config.short_title}}" id="tab_{{ c }}" role="tabpanel">
|
|
16
|
-
</div>
|
|
17
|
-
{% endfor %}
|
|
18
|
-
<div class="tab-pane {{'active' if tab=='publish' }}" id="tab_publish" role="tabpanel">
|
|
19
|
-
{% include 'publish.html' %}
|
|
20
|
-
</div>
|
|
21
|
-
<div class="tab-pane {{'active' if tab=='nextcloud' }}" id="tab_nextcloud" role="tabpanel">
|
|
22
|
-
{% for item in project.nextcloud.nxc_list_files_and_folders() %}
|
|
23
|
-
{% include 'file_tree.html' %}
|
|
24
|
-
{% endfor %}
|
|
25
|
-
</div>
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
</div>
|
|
29
|
-
</div>
|
|
30
|
-
|
|
31
|
-
<div class="modal fade" id="xpathParserModal" tabindex="-1" aria-labelledby="xpathParserModalLabel" aria-hidden="true">
|
|
32
|
-
</div>
|
|
33
|
-
|
|
34
|
-
<div class="modal fade" id="teiExplorer" tabindex="-1" aria-labelledby="teiExplorerLabel" aria-hidden="true">
|
|
35
|
-
</div>
|
|
36
|
-
|
|
37
|
-
{% endblock %}
|
tgp_ui/templates/publish.html
DELETED
|
@@ -1,120 +0,0 @@
|
|
|
1
|
-
<div class="col-sm-6">
|
|
2
|
-
<div class="row">
|
|
3
|
-
|
|
4
|
-
<h4><b>Publish</b> project to <b>TextGrid-Testinstance</b></h4>
|
|
5
|
-
</div>
|
|
6
|
-
{% set tg_session_id = project.main_config.get_tg_session_id('test')%}
|
|
7
|
-
<form class="row border-bottom pb-3 tab-submit" method="POST"
|
|
8
|
-
action="{{ url_for('save_session_id', projectname=project.name, instance='test') }}" method="POST">
|
|
9
|
-
<div class="col-6">
|
|
10
|
-
<input type="text" class="form-control" name="tg_auth_session_id" placeholder="TgAuth Session ID"
|
|
11
|
-
value="{{tg_session_id if tg_session_id}}">
|
|
12
|
-
</div>
|
|
13
|
-
<div class="col-6">
|
|
14
|
-
<button type="submit" class="btn btn-primary">
|
|
15
|
-
<span class="bi bi-floppy2-fill"></span>
|
|
16
|
-
<span class="spinner-border spinner-border-sm" style="display:none;" role="status"
|
|
17
|
-
aria-hidden="true"></span>
|
|
18
|
-
</button>
|
|
19
|
-
</div>
|
|
20
|
-
</form>
|
|
21
|
-
{% if tg_session_id %}
|
|
22
|
-
<div class="row text-start">
|
|
23
|
-
<span class="py-2">Select from existing projects</span>
|
|
24
|
-
{% for tg_project in project.get_tgp('test').get_tg_projects() %}
|
|
25
|
-
<div class="tg-project-row">
|
|
26
|
-
<a href="#" class="text-dark select-tg-project" title="Select project"
|
|
27
|
-
data-url="{{ url_for('save_tg_project_id', projectname=project.name, instance='test') }}"
|
|
28
|
-
data-tg_project_id="{{ tg_project.id }}">
|
|
29
|
-
{% set tg_project_id = project.main_config.get_tg_project_id('test')%}
|
|
30
|
-
{% if tg_project_id == tg_project.id %}
|
|
31
|
-
<span class="bi bi-circle-fill"></span>
|
|
32
|
-
{% else %}
|
|
33
|
-
<span class="bi bi-circle"></span>
|
|
34
|
-
{% endif %}
|
|
35
|
-
</a>
|
|
36
|
-
<b>{{ tg_project.name }}</b>
|
|
37
|
-
-
|
|
38
|
-
<span class="tgProjectHits">{{ tg_project.contents }}</span> <span>Elements</span>
|
|
39
|
-
(<i>{{ tg_project.id }}</i>)
|
|
40
|
-
<a href="#" class="text-dark delete-tg-project" title="Delete project"
|
|
41
|
-
data-url="{{ url_for('delete_tg_project_id', projectname=project.name, instance='test', tg_project_id= tg_project.id ) }}"
|
|
42
|
-
data-hits_url="{{ url_for('get_tg_project_hits', projectname=project.name, instance='test', tg_project_id= tg_project.id ) }}">
|
|
43
|
-
<span class="bi bi-trash text-danger"></span>
|
|
44
|
-
<span class="spinner-border spinner-border-sm" style="display:none;" role="status"
|
|
45
|
-
aria-hidden="true"></span>
|
|
46
|
-
</a>
|
|
47
|
-
</div>
|
|
48
|
-
{% endfor%}
|
|
49
|
-
<span class="py-2">
|
|
50
|
-
or create a new project:
|
|
51
|
-
</span>
|
|
52
|
-
</div>
|
|
53
|
-
<form class="row border-bottom pb-3 tab-submit" method="POST"
|
|
54
|
-
action="{{ url_for('create_tg_project', projectname=project.name, instance='test') }}" method="POST">
|
|
55
|
-
<div class="col-6">
|
|
56
|
-
<input type="text" class="form-control" name="tg_projectname" placeholder="TG Projectname">
|
|
57
|
-
</div>
|
|
58
|
-
<div class="col-6">
|
|
59
|
-
<button type="submit" class="btn btn-primary">
|
|
60
|
-
<span class="bi bi-pencil-square"></span>
|
|
61
|
-
<span class="spinner-border spinner-border-sm" style="display:none;" role="status"
|
|
62
|
-
aria-hidden="true"></span>
|
|
63
|
-
</button>
|
|
64
|
-
</div>
|
|
65
|
-
</form>
|
|
66
|
-
<form class="row pt-3 tab-submit" method="POST"
|
|
67
|
-
action="{{ url_for('publish_project', projectname=project.name, instance='test') }}" method="POST">
|
|
68
|
-
<div class="col-6">
|
|
69
|
-
<h5>Publish project</h5>
|
|
70
|
-
</div>
|
|
71
|
-
{% if project.main_config.get_tg_project_id('test') %}
|
|
72
|
-
<div class="col-6">
|
|
73
|
-
<button type="submit" class="btn btn-primary">
|
|
74
|
-
<span class="bi bi-rocket-takeoff"></span>
|
|
75
|
-
<span class="spinner-border spinner-border-sm" style="display:none;" role="status"
|
|
76
|
-
aria-hidden="true"></span>
|
|
77
|
-
</button>
|
|
78
|
-
</div>
|
|
79
|
-
<div class="col-12 bg-light m-2 p-2 fst-bold">
|
|
80
|
-
<p>
|
|
81
|
-
<b>Whats next?</b>
|
|
82
|
-
<ul class="list-group list-group-numbered">
|
|
83
|
-
<li class="list-group-item">Go to <a href="https://test.textgridrep.org/projects">Testinstance</a></li>
|
|
84
|
-
<li class="list-group-item">Display 'Unpublished projects' <i>My TextGrid/Unpublished Data</i></li>
|
|
85
|
-
<li class="list-group-item">Check if everything looks as favored</li>
|
|
86
|
-
</ul>
|
|
87
|
-
</p>
|
|
88
|
-
</div>
|
|
89
|
-
{% else %}
|
|
90
|
-
<div class="col-12 bg-light m-2 p-2 fst-italic">
|
|
91
|
-
<h5>Attention</h5>
|
|
92
|
-
<p>
|
|
93
|
-
<b>You need to select a TextGrid project in order to publish your project to
|
|
94
|
-
TextGrid-Testinstance!</b>
|
|
95
|
-
</p>
|
|
96
|
-
</div>
|
|
97
|
-
{% endif %}
|
|
98
|
-
</form>
|
|
99
|
-
{% else %}
|
|
100
|
-
<div class="bg-light m-2 p-2 fst-italic">
|
|
101
|
-
<h5>Attention</h5>
|
|
102
|
-
<p>
|
|
103
|
-
<b>You need to provide a "TgAuth Session ID" in order to publish your project to
|
|
104
|
-
TextGrid-Testinstance!</b>
|
|
105
|
-
<p>
|
|
106
|
-
1. Please first go to <a
|
|
107
|
-
href="https://test.textgridlab.org/1.0/Shibboleth.sso/Login?target=/1.0/secure/TextGrid-WebAuth.php?authZinstance=test.textgridlab.org"
|
|
108
|
-
target="_blank">this page</a>!
|
|
109
|
-
(You may need to log in via DARIAH-AAI)
|
|
110
|
-
</p>
|
|
111
|
-
<p>
|
|
112
|
-
2. Then click on "More Details" and copy the "TgAuth Session ID" to
|
|
113
|
-
your clipboard.
|
|
114
|
-
</p>
|
|
115
|
-
<p>
|
|
116
|
-
3. Finally, paste it into the input field above and save it.
|
|
117
|
-
</p>
|
|
118
|
-
</div>
|
|
119
|
-
{% endif %}
|
|
120
|
-
</div>
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
{% extends 'layout.html' %}
|
|
2
|
-
{% block content %}
|
|
3
|
-
|
|
4
|
-
<div class="container-fluid">
|
|
5
|
-
<div class="row g-3">
|
|
6
|
-
{% for desc in desc_list %}
|
|
7
|
-
<div class="col-6 p-3">
|
|
8
|
-
<h4> {{ desc['title']}} </h4>
|
|
9
|
-
<div class="desc_content" style="display: none;"> {{desc['content']}} </div>
|
|
10
|
-
</div>
|
|
11
|
-
{% endfor %}
|
|
12
|
-
</div>
|
|
13
|
-
</div>
|
|
14
|
-
{% endblock %}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|