forked from enviPath/enviPy
adjusted migration
Initial bayer app Show Pack Classification Adjusted docker compose to bayer specifics Adjusted Dockerfile for Bayer Adding secret flags to group, add secret pools to packages Adjusted View for Package creation Prep configs, added Package Create Modal wip More on PES wip wip Wip minor PW interactions API PES wip Make Select Widget reflect required make required generallay available Update UI if pathway mode is set to build Added ais circle adjustments Initial Zoom, fix AD Creation wip
This commit is contained in:
@ -22,7 +22,7 @@
|
||||
{% for tpl in action_button_templates %}
|
||||
{% include tpl %}
|
||||
{% endfor %}
|
||||
<li role="separator" class="divider"></li>
|
||||
<li role="separator" class="divider h-px"></li>
|
||||
{% endif %}
|
||||
<li>
|
||||
<a
|
||||
@ -74,7 +74,7 @@
|
||||
Rules</a
|
||||
>
|
||||
</li>
|
||||
<li role="separator" class="divider"></li>
|
||||
<li role="separator" class="divider h-px"></li>
|
||||
<li>
|
||||
<a
|
||||
class="button"
|
||||
@ -99,11 +99,16 @@
|
||||
<i class="glyphicon glyphicon-plus"></i> Set Aliases</a
|
||||
>
|
||||
</li>
|
||||
<li role="separator" class="divider"></li>
|
||||
<li role="separator" class="divider h-px"></li>
|
||||
<li>
|
||||
<a
|
||||
class="button"
|
||||
onclick="document.getElementById('delete_pathway_node_modal').showModal(); return false;"
|
||||
onclick="
|
||||
const modal = document.getElementById('delete_pathway_node_modal');
|
||||
modal.showModal();
|
||||
window.dispatchEvent(new Event('modal-opened'));
|
||||
return false;
|
||||
"
|
||||
>
|
||||
<i class="glyphicon glyphicon-trash"></i> Delete Compound</a
|
||||
>
|
||||
@ -111,7 +116,12 @@
|
||||
<li>
|
||||
<a
|
||||
class="button"
|
||||
onclick="document.getElementById('delete_pathway_edge_modal').showModal(); return false;"
|
||||
onclick="
|
||||
const modal = document.getElementById('delete_pathway_edge_modal');
|
||||
modal.showModal();
|
||||
window.dispatchEvent(new Event('modal-opened'));
|
||||
return false;
|
||||
"
|
||||
>
|
||||
<i class="glyphicon glyphicon-trash"></i> Delete Reaction</a
|
||||
>
|
||||
|
||||
@ -5,7 +5,7 @@
|
||||
|
||||
{% block action_button %}
|
||||
<div class="flex items-center gap-2">
|
||||
{% if meta.can_edit %}
|
||||
{% if meta.can_edit or not meta.url_contains_package %}
|
||||
<button
|
||||
type="button"
|
||||
class="btn btn-primary btn-sm"
|
||||
|
||||
@ -3,14 +3,16 @@
|
||||
{% block page_title %}Models{% endblock %}
|
||||
|
||||
{% block action_button %}
|
||||
{% if meta.can_edit and meta.enabled_features.MODEL_BUILDING %}
|
||||
<button
|
||||
type="button"
|
||||
class="btn btn-primary btn-sm"
|
||||
onclick="document.getElementById('new_model_modal').showModal(); return false;"
|
||||
>
|
||||
New Model
|
||||
</button>
|
||||
{% if meta.can_edit or not meta.url_contains_package %}
|
||||
{% if meta.enabled_features.MODEL_BUILDING %}
|
||||
<button
|
||||
type="button"
|
||||
class="btn btn-primary btn-sm"
|
||||
onclick="document.getElementById('new_model_modal').showModal(); return false;"
|
||||
>
|
||||
New Model
|
||||
</button>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endblock action_button %}
|
||||
|
||||
|
||||
@ -3,7 +3,6 @@
|
||||
{% block page_title %}Packages{% endblock %}
|
||||
|
||||
{% block action_button %}
|
||||
{% if meta.can_edit %}
|
||||
<div class="flex items-center gap-2">
|
||||
<button
|
||||
type="button"
|
||||
@ -71,7 +70,6 @@
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endblock action_button %}
|
||||
|
||||
{% block action_modals %}
|
||||
|
||||
@ -3,7 +3,7 @@
|
||||
{% block page_title %}Pathways{% endblock %}
|
||||
|
||||
{% block action_button %}
|
||||
{% if meta.can_edit %}
|
||||
{% if meta.can_edit or not meta.url_contains_package %}
|
||||
<div class="flex items-center gap-2">
|
||||
<a
|
||||
class="btn btn-primary btn-sm"
|
||||
|
||||
@ -3,7 +3,7 @@
|
||||
{% block page_title %}Reactions{% endblock %}
|
||||
|
||||
{% block action_button %}
|
||||
{% if meta.can_edit %}
|
||||
{% if meta.can_edit or not meta.url_contains_package %}
|
||||
<button
|
||||
type="button"
|
||||
class="btn btn-primary btn-sm"
|
||||
|
||||
@ -3,7 +3,7 @@
|
||||
{% block page_title %}Rules{% endblock %}
|
||||
|
||||
{% block action_button %}
|
||||
{% if meta.can_edit %}
|
||||
{% if meta.can_edit or not meta.url_contains_package %}
|
||||
<button
|
||||
type="button"
|
||||
class="btn btn-primary btn-sm"
|
||||
|
||||
@ -11,7 +11,7 @@
|
||||
{% endblock action_modals %}
|
||||
|
||||
{% block action_button %}
|
||||
{% if meta.can_edit %}
|
||||
{% if meta.can_edit or not meta.url_contains_package %}
|
||||
<button
|
||||
type="button"
|
||||
class="btn btn-primary btn-sm"
|
||||
|
||||
@ -3,7 +3,7 @@
|
||||
{% block page_title %}{{ page_title|default:"Structures" }}{% endblock %}
|
||||
|
||||
{% block action_button %}
|
||||
{% if meta.can_edit %}
|
||||
{% if meta.can_edit or not meta.url_contains_package %}
|
||||
<button
|
||||
type="button"
|
||||
class="btn btn-primary btn-sm"
|
||||
|
||||
@ -35,6 +35,7 @@
|
||||
<use href="{% static "/images/logo-name.svg" %}#ep-logo-name" />
|
||||
</svg>
|
||||
</a>
|
||||
<img src="{% static 'images/bayer-logo.svg' %}" width="40">
|
||||
</div>
|
||||
|
||||
{% if not public_mode %}
|
||||
@ -88,12 +89,23 @@
|
||||
>Scenario</a
|
||||
>
|
||||
</li>
|
||||
<hr/>
|
||||
<li>
|
||||
<a href="{{ meta.server_url }}/group" id="scenarioLink"
|
||||
>Group</a
|
||||
>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<div class="navbar-end">
|
||||
{% if meta.url_contains_package and meta.current_package.get_classification_level_display == "Restricted" %}
|
||||
<img src="{% static 'images/restricted_mid.png' %}" width="200">
|
||||
{% elif meta.url_contains_package and meta.current_package.get_classification_level_display == "Secret" %}
|
||||
<img src="{% static 'images/secret_mid.png' %}" width="120">
|
||||
{% endif %}
|
||||
{% if not public_mode %}
|
||||
<a id="search-trigger" role="button" class="cursor-pointer">
|
||||
<div
|
||||
|
||||
@ -44,6 +44,7 @@
|
||||
:class="{ 'select-error': $store.validationErrors.hasError(fieldName, context) }"
|
||||
x-model="value"
|
||||
:multiple="multiple"
|
||||
:required="isRequired"
|
||||
>
|
||||
<option value="" :selected="!value">Select...</option>
|
||||
|
||||
|
||||
@ -65,11 +65,11 @@
|
||||
},
|
||||
|
||||
get showMlrr() {
|
||||
return this.selectedType === 'mlrr';
|
||||
return this.selectedType === 'ml-relative-reasoning';
|
||||
},
|
||||
|
||||
get showRbrr() {
|
||||
return this.selectedType === 'rbrr';
|
||||
return this.selectedType === 'rule-based-relative-reasoning';
|
||||
},
|
||||
|
||||
get showEnviformer() {
|
||||
|
||||
@ -203,11 +203,11 @@
|
||||
id="model-based-prediction-setting-threshold"
|
||||
name="model-based-prediction-setting-threshold"
|
||||
class="input input-bordered w-full"
|
||||
placeholder="0.25"
|
||||
value="0.25"
|
||||
type="number"
|
||||
min="0"
|
||||
max="1"
|
||||
step="0.05"
|
||||
step="any"
|
||||
/>
|
||||
</div>
|
||||
|
||||
|
||||
@ -4,6 +4,25 @@
|
||||
id="delete_pathway_edge_modal"
|
||||
class="modal"
|
||||
x-data="modalForm({ state: { selectedEdge: '', imageUrl: '' } })"
|
||||
@modal-opened.window="
|
||||
const links = d3.selectAll('path.highlighted');
|
||||
|
||||
if (!links.empty()) {
|
||||
const el = links.node();
|
||||
const selectElement = document.getElementById('delete_pathway_edge_edges');
|
||||
console.log(el);
|
||||
console.log(el.__data__);
|
||||
for (let option of selectElement.options) {
|
||||
if (option.value === el.__data__.url) {
|
||||
option.selected = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
selectElement.dispatchEvent(new Event('change'));
|
||||
|
||||
}
|
||||
"
|
||||
@close="reset()"
|
||||
>
|
||||
<div class="modal-box">
|
||||
|
||||
@ -4,6 +4,22 @@
|
||||
id="delete_pathway_node_modal"
|
||||
class="modal"
|
||||
x-data="modalForm({ state: { selectedNode: '', imageUrl: '' } })"
|
||||
@modal-opened.window="
|
||||
const el = d3.select('circle.highlighted').node();
|
||||
|
||||
if (el !== null) {
|
||||
const selectElement = document.getElementById('delete_pathway_node_nodes');
|
||||
|
||||
for (let option of selectElement.options) {
|
||||
if (option.value === el.__data__.url) {
|
||||
option.selected = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
selectElement.dispatchEvent(new Event('change'));
|
||||
}
|
||||
"
|
||||
@close="reset()"
|
||||
>
|
||||
<div class="modal-box">
|
||||
|
||||
@ -56,8 +56,8 @@
|
||||
<ul class="menu bg-base-200 rounded-box">
|
||||
{% for um in group.user_member.all %}
|
||||
<li>
|
||||
<a href="{{ um.url }}" class="hover:bg-base-300"
|
||||
>{{ um.username }}
|
||||
<a href="{% if not user.is_superuser %}{{ um.url }}{% else %}{{ "#" }}{% endif %}" class="hover:bg-base-300"
|
||||
>{{ um.username }}
|
||||
{% if not um.is_active %}<i>(inactive)</i>{% endif %}</a
|
||||
>
|
||||
</li>
|
||||
|
||||
@ -1,4 +1,5 @@
|
||||
{% extends "framework_modern.html" %}
|
||||
{% load envipytags %}
|
||||
|
||||
{% block content %}
|
||||
|
||||
@ -54,6 +55,12 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{% epdb_slot_templates "epdb.objects.node.viz" as viz_templates %}
|
||||
|
||||
{% for tpl in viz_templates %}
|
||||
{% include tpl %}
|
||||
{% endfor %}
|
||||
|
||||
<!-- Image Representation -->
|
||||
<div class="collapse-arrow bg-base-200 collapse">
|
||||
<input type="checkbox" checked />
|
||||
|
||||
@ -106,12 +106,12 @@
|
||||
</div>
|
||||
|
||||
<!-- Graphical Representation -->
|
||||
<div class="collapse-arrow bg-base-200 collapse">
|
||||
<div class="collapse-arrow bg-base-200 collapse overflow-y-auto">
|
||||
<input type="checkbox" checked />
|
||||
<div class="collapse-title text-xl font-medium">
|
||||
Graphical Representation
|
||||
</div>
|
||||
<div class="collapse-content">
|
||||
<div class="collapse-content ">
|
||||
<div class="bg-base-100 mb-2 rounded-lg p-2">
|
||||
<div class="navbar bg-base-100 rounded-lg">
|
||||
<div class="flex-1">
|
||||
@ -140,7 +140,7 @@
|
||||
</div>
|
||||
<ul
|
||||
tabindex="0"
|
||||
class="dropdown-content menu bg-base-100 rounded-box z-50 w-52 p-2"
|
||||
class="dropdown-content menu bg-base-100 rounded-box z-50 w-96 p-2"
|
||||
>
|
||||
{% include "actions/objects/pathway.html" %}
|
||||
</ul>
|
||||
|
||||
@ -105,7 +105,7 @@
|
||||
></iframe>
|
||||
</div>
|
||||
|
||||
<label class="select mb-8 w-full">
|
||||
<label class="select mb-8 w-full" id="prediction-setting-label">
|
||||
<span class="label">Predictor</span>
|
||||
<select id="prediction-setting" name="prediction-setting">
|
||||
<option disabled>Select a Setting</option>
|
||||
@ -148,6 +148,22 @@
|
||||
</div>
|
||||
{# prettier-ignore-start #}
|
||||
<script>
|
||||
// Hide predictor selection and update button text if mode is "build"
|
||||
function radioChange(event) {
|
||||
if (event.target.value === "build") {
|
||||
document.getElementById("prediction-setting-label").hidden = true;
|
||||
document.getElementById("predict-submit-button").innerText = "Build";
|
||||
} else {
|
||||
document.getElementById("prediction-setting-label").hidden = false;
|
||||
document.getElementById("predict-submit-button").innerText = "Predict";
|
||||
}
|
||||
}
|
||||
|
||||
const radioButtons = document.querySelectorAll('input[name="predict"]');
|
||||
radioButtons.forEach(radio => {
|
||||
radio.addEventListener('change', radioChange);
|
||||
});
|
||||
|
||||
// Helper function to safely get Ketcher instance from iframe
|
||||
function getKetcherInstance(iframeId) {
|
||||
const ketcherFrame = document.getElementById(iframeId);
|
||||
|
||||
@ -110,8 +110,6 @@
|
||||
<div
|
||||
class="text-base-content/50 flex items-center justify-center space-x-6 text-sm"
|
||||
>
|
||||
<a href="/legal" class="link link-hover">Legal</a>
|
||||
<span class="text-base-content/30">•</span>
|
||||
<a href="/terms" class="link link-hover">Terms of Use</a>
|
||||
<span class="text-base-content/30">•</span>
|
||||
<a href="/privacy" class="link link-hover">Privacy Policy</a>
|
||||
|
||||
Reference in New Issue
Block a user