2021-04-15 12:55:13 +01:00
|
|
|
<!-- svxfile.html - this text visible because this template has been included -->
|
2011-07-11 02:10:22 +01:00
|
|
|
{% extends "base.html" %}
|
|
|
|
{% block title %}{{ title }}{% endblock %}
|
|
|
|
|
|
|
|
{% block head %}
|
2021-10-25 23:02:27 +01:00
|
|
|
<!-- Should we wait until CodeMirror 6.0 is available https://codemirror.net/6/ -->
|
2021-03-26 17:33:58 +00:00
|
|
|
<!-- <script type="text/javascript" src="{{settings.JSLIB_URL}}jquery-form/jquery.form.min.js"></script> <!-- INVALID-->
|
|
|
|
<!-- <script type="text/javascript" src="{{settings.JSLIB_URL}}codemirror/codemirror.min.js"></script> <!-- INVALID-->
|
2011-07-11 02:10:22 +01:00
|
|
|
|
2021-03-26 17:33:58 +00:00
|
|
|
<!-- Not in use and not needed for simple text editor jquery
|
2011-07-11 02:10:22 +01:00
|
|
|
<script type="text/javascript">
|
|
|
|
var codeeditor;
|
|
|
|
$(document).ready(function()
|
|
|
|
{
|
|
|
|
codeeditor = CodeMirror.fromTextArea("id_code",
|
|
|
|
{
|
|
|
|
parserfile: ["parsesurvex.js"],
|
2021-03-21 01:37:52 +00:00
|
|
|
stylesheet: "{{settings.MEDIA_URL}}CodeMirror-0.62/css/survexcolors.css", # INVALID
|
|
|
|
path: "{{settings.MEDIA_URL}}CodeMirror-0.62/js/", # INVALID
|
2011-07-11 02:10:22 +01:00
|
|
|
textWrapping: false,
|
|
|
|
lineNumbers: false,
|
|
|
|
indentUnit: 4,
|
|
|
|
tabMode: "spaces"
|
|
|
|
});
|
|
|
|
$("#id_outputtype").val("ajax");
|
|
|
|
var options =
|
|
|
|
{
|
|
|
|
target: '#difflistajax',
|
|
|
|
beforeSubmit: function() { $("textarea#id_code").value = codeeditor.getCode().length; },
|
|
|
|
success: function() { codeeditor.focus(); }
|
|
|
|
};
|
|
|
|
$('#codewikiform').ajaxForm(options); // bind form using 'ajaxForm'
|
|
|
|
});
|
|
|
|
|
|
|
|
</script>
|
2021-03-26 17:33:58 +00:00
|
|
|
-->
|
2011-07-11 02:10:22 +01:00
|
|
|
{% endblock %}
|
|
|
|
|
|
|
|
{% block content %}
|
2021-04-14 21:08:06 +01:00
|
|
|
{% if warning %}
|
|
|
|
<h1 style="color: red">Survex Template - will save as file '{{ title }}.svx'</h1>
|
|
|
|
{% else %}
|
2011-07-11 02:10:22 +01:00
|
|
|
<h1>Survex File: {{ title }}</h1>
|
2021-04-14 21:08:06 +01:00
|
|
|
{% endif %}
|
2011-07-11 02:10:22 +01:00
|
|
|
|
|
|
|
{% if svxincludes %}
|
2021-03-26 17:33:58 +00:00
|
|
|
<p><b>Included files:</b>
|
|
|
|
{% for svxinclude in svxincludes %}
|
|
|
|
<a href="{{svxinclude}}.svx">{{svxinclude}}</a>
|
|
|
|
{% endfor %}
|
2011-07-11 02:10:22 +01:00
|
|
|
</p>
|
|
|
|
{% endif %}
|
|
|
|
|
2021-03-26 21:20:08 +00:00
|
|
|
|
2019-04-14 22:45:31 +01:00
|
|
|
<form id="codewikiform" action="" method="POST">{% csrf_token %}
|
2011-07-11 02:10:22 +01:00
|
|
|
<div class="codeframebit">{{form.code}}</div>
|
|
|
|
<div style="display:none">{{form.filename}} {{form.dirname}} {{form.datetime}} {{form.outputtype}}</div>
|
2020-05-31 20:46:12 +01:00
|
|
|
<input type="submit" name="diff" value="Differences between edited and saved versions of this file" />
|
|
|
|
<input type="submit" name="save" value="Save this edited svx file"/>
|
|
|
|
<input type="submit" name="process" value="Run 'cavern' on this svx file" title="executes cavern"/>
|
2011-07-11 02:10:22 +01:00
|
|
|
</form>
|
|
|
|
|
|
|
|
<div id="difflistajax">
|
|
|
|
<pre>
|
|
|
|
{% for diffline in difflist %}{{diffline}}
|
|
|
|
{% endfor %}
|
|
|
|
</pre>
|
|
|
|
|
|
|
|
{% if logmessage %}
|
2021-03-26 17:33:58 +00:00
|
|
|
{% if has_3d %}
|
2022-03-11 16:22:37 +00:00
|
|
|
<p>Click here to view the <a href='{% url "threed" title %}'>3d file</a> produced as output</p>
|
2021-03-26 17:33:58 +00:00
|
|
|
{% else %}
|
2022-03-11 16:22:37 +00:00
|
|
|
<p><b>No 3d file generated. There was an ERROR<br>Read the full <a href='{% url "svxlog" title %}'>.log file</a>
|
|
|
|
the <a href='{% url "err" title %}'>.err file</a> and fix this .svx file</b></p>
|
2021-03-26 17:33:58 +00:00
|
|
|
{% endif %}
|
2022-03-11 16:22:37 +00:00
|
|
|
<!-- <pre>
|
|
|
|
LOGMESSAGES
|
|
|
|
{{logmessage}}
|
2021-03-26 17:33:58 +00:00
|
|
|
</pre>
|
2022-03-11 16:22:37 +00:00
|
|
|
-->
|
2011-07-11 02:10:22 +01:00
|
|
|
{% endif %}
|
|
|
|
</div>
|
2023-02-26 22:13:37 +00:00
|
|
|
<span style="font-family: monospace; font-size: 130%; ">
|
|
|
|
{% for sb in svxblocks %}
|
2023-02-27 16:42:08 +00:00
|
|
|
<details {% if forloop.first %} open{% endif %}>
|
|
|
|
<summary><b><a href="/expedition/{{sb.date|date:"Y"}}">{{sb.date|date:"Y"}}</a>{{sb.date|date:"-m-d"}}</b> {{sb.title}} '{{sb.name}}'</summary>
|
2023-02-26 22:13:37 +00:00
|
|
|
List of Logbook entries, wallets and other survex files on {{sb.date|date:"Y-m-d"}}.
|
|
|
|
<br />
|
|
|
|
[Work in progress, Feb. 2023...]<br />
|
|
|
|
{% include 'onthisdate.html' %}
|
|
|
|
</details>
|
|
|
|
{% empty %}
|
|
|
|
Cannot find any survex blocks in this survex file. <br />
|
|
|
|
Report this to a nerd if you think this is incorrect.
|
|
|
|
{% endfor %}
|
|
|
|
</span>
|
2011-07-11 02:10:22 +01:00
|
|
|
{% endblock %}
|