A ton of updates for Cin7's templates for multi-product people. Finished the first half of the mass-delete script for Sandata.
This commit is contained in:
@ -1,22 +1,32 @@
|
||||
{% assign omni = false %}
|
||||
{% assign core = false %}
|
||||
{% assign partners = false %}
|
||||
{% assign redirect = false %}
|
||||
|
||||
{% if current_person.signed_in? %}
|
||||
{% assign log_out = false %}
|
||||
{% for group in current_person.groups %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% if group.name contains 'Partners' %}
|
||||
{% assign partners = true %}
|
||||
{% else %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
{% if core and course.name contains 'Omni' %}
|
||||
{% assign redirect = true %}
|
||||
{% elsif omni and course.name contains 'Core' %}
|
||||
{% assign redirect = true %}
|
||||
{% endif %}
|
||||
{% if partners %}
|
||||
{% assign redirect = false %}
|
||||
{% else %}
|
||||
{% if core and course.name contains 'Omni' %}
|
||||
{% assign redirect = true %}
|
||||
{% elsif omni and course.name contains 'Core' %}
|
||||
{% assign redirect = true %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
|
||||
{% if redirect %}
|
||||
<script>window.location.replace('/app')</script>
|
||||
|
||||
@ -2,29 +2,31 @@
|
||||
<div class=" row">
|
||||
{% for course in courses.in_catalog %}
|
||||
{% if current_person.signed_in? %}
|
||||
{% if omni and if core %}
|
||||
{% if course.name contains 'Omni' or course.name contains 'Core' %}
|
||||
<div class="col-xs-12 col-md-6 col-lg-4 np-stretch-content">
|
||||
{% include "cards_course" with course %}
|
||||
</div>
|
||||
{% if omni %}
|
||||
{% if course.name contains 'Omni' %}
|
||||
|
||||
{% if partners %}
|
||||
<div class="col-xs-12 col-md-6 col-lg-4 np-stretch-content">
|
||||
{% include "cards_course" with course %}
|
||||
</div>
|
||||
{% else %}
|
||||
{% if omni %}
|
||||
{% if course.name contains 'Omni' %}
|
||||
<div class="col-xs-12 col-md-6 col-lg-4 np-stretch-content">
|
||||
{% include "cards_course" with course %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% elsif core %}
|
||||
{% if course.name contains 'Core' %}
|
||||
<div class="col-xs-12 col-md-6 col-lg-4 np-stretch-content">
|
||||
{% include "cards_course" with course %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% else %}
|
||||
<div class="col-xs-12 col-md-6 col-lg-4 np-stretch-content">
|
||||
{% include "cards_course" with course %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% elsif core %}
|
||||
{% if course.name contains 'Core' %}
|
||||
<div class="col-xs-12 col-md-6 col-lg-4 np-stretch-content">
|
||||
{% include "cards_course" with course %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% else %}
|
||||
<div class="col-xs-12 col-md-6 col-lg-4 np-stretch-content">
|
||||
{% include "cards_course" with course %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% else %}
|
||||
|
||||
@ -1,15 +1,20 @@
|
||||
{% assign omni = false %}
|
||||
{% assign core = false %}
|
||||
{% assign partners = false %}
|
||||
{% assign log_out = true %}
|
||||
|
||||
{% if current_person.signed_in? %}
|
||||
{% assign log_out = false %}
|
||||
{% for group in current_person.groups %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% if group.name contains 'Partners' %}
|
||||
{% assign partners = true %}
|
||||
{% else %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
@ -23,12 +28,18 @@
|
||||
{% include 'cards_course' %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% elsif omni %}
|
||||
{% elsif omni %}
|
||||
{% if course.properties.feature_course_omni == true %}
|
||||
<div class="card-wrapper">
|
||||
{% include 'cards_course' %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% elsif partners %}
|
||||
{% if course.properties.feature_course_omni == true or course.properties.feature_course_core == true %}
|
||||
<div class="card-wrapper">
|
||||
{% include 'cards_course' %}
|
||||
</div>
|
||||
{% endif %}
|
||||
{% else %}
|
||||
{% if course.properties.feature_course_omni == true or course.properties.feature_course_core == true %}
|
||||
<div class="card-wrapper">
|
||||
|
||||
@ -8,11 +8,11 @@
|
||||
{% for course in courses.in_catalog %}
|
||||
{% for category in course.categories %}
|
||||
{% if category.name contains 'Omni' %}
|
||||
{% unless unique_omni_categories contains category.name %}
|
||||
{% unless unique_omni_categories contains category.name %}
|
||||
<div class="category-option">
|
||||
<input class="filter-checkbox" type="checkbox" id="{{category.name}}" />
|
||||
<label>{{category.name}}</label>
|
||||
</div>
|
||||
</div>
|
||||
{% assign unique_omni_categories = unique_omni_categories | append: category.name %}
|
||||
{% endunless %}
|
||||
{% endif %}
|
||||
@ -26,11 +26,11 @@
|
||||
{% if course.name contains '[Core]' %}
|
||||
{% for category in course.categories %}
|
||||
{% if category.name contains 'Core' %}
|
||||
{% unless unique_core_categories contains category.name %}
|
||||
{% unless unique_core_categories contains category.name %}
|
||||
<div class="category-option">
|
||||
<input class="filter-checkbox" type="checkbox" id="{{category.name}}" />
|
||||
<label>{{category.name}}</label>
|
||||
</div>
|
||||
</div>
|
||||
{% assign unique_core_categories = unique_core_categories | append: category.name %}
|
||||
{% endunless %}
|
||||
{% endif %}
|
||||
@ -38,16 +38,16 @@
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</div>
|
||||
{%elsif log_out%}
|
||||
{% elsif log_out or partners %}
|
||||
<div class="filter-option-container" id="categoryFilters">
|
||||
{% assign unique_core_categories = "" %}
|
||||
{% for course in courses.in_catalog %}
|
||||
{% for category in course.categories %}
|
||||
{% unless unique_core_categories contains category.name %}
|
||||
{% unless unique_core_categories contains category.name %}
|
||||
<div class="category-option">
|
||||
<input class="filter-checkbox" type="checkbox" id="{{category.name}}" />
|
||||
<label>{{category.name}}</label>
|
||||
</div>
|
||||
</div>
|
||||
{% assign unique_core_categories = unique_core_categories | append: category.name %}
|
||||
{% endunless %}
|
||||
{% endfor %}
|
||||
@ -65,11 +65,11 @@
|
||||
<div class="time-option">
|
||||
<input class="duration-checkbox" type="checkbox" id="<20" />
|
||||
<label>< 20 min</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="time-option">
|
||||
<input class="duration-checkbox" type="checkbox" id="<30" />
|
||||
<label>< 30 min</label>
|
||||
</div>
|
||||
</div>
|
||||
<div class="time-option">
|
||||
<input class="duration-checkbox" type="checkbox" id="<45" />
|
||||
<label>< 45 min</label>
|
||||
@ -79,7 +79,7 @@
|
||||
<label>< 60 min</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<style>
|
||||
|
||||
@ -1,19 +1,23 @@
|
||||
{% assign omni = false %}
|
||||
{% assign core = false %}
|
||||
{% assign partners = false %}
|
||||
{% assign log_out = true %}
|
||||
|
||||
{% if current_person.signed_in? %}
|
||||
{% assign log_out = false %}
|
||||
{% for group in current_person.groups %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% if group.name contains 'Partners' %}
|
||||
{% assign partners = true %}
|
||||
{% else %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
|
||||
<footer class="np-footer">
|
||||
<div class="np-footer-top">
|
||||
{% if website_footer.show_navigation_links? %}
|
||||
|
||||
@ -1,15 +1,20 @@
|
||||
{% assign omni = false %}
|
||||
{% assign core = false %}
|
||||
{% assign partners = false %}
|
||||
{% assign log_out = true %}
|
||||
|
||||
{% if current_person.signed_in? %}
|
||||
{% assign log_out = false %}
|
||||
{% for group in current_person.groups %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% if group.name contains 'Partners' %}
|
||||
{% assign partners = true %}
|
||||
{% else %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
@ -244,7 +249,7 @@
|
||||
var searchInput = document.querySelector(".header-search-input");
|
||||
|
||||
searchIcon.addEventListener("click", function(event) {
|
||||
event.stopPropagation();
|
||||
event.stopPropagation();
|
||||
|
||||
if (searchInput.style.display === "block") {
|
||||
searchInput.style.display = "none";
|
||||
|
||||
@ -46,4 +46,4 @@
|
||||
.learning-path-carousel-core {
|
||||
margin: 0 1rem;
|
||||
}
|
||||
</style>
|
||||
</style>
|
||||
|
||||
@ -1,18 +1,26 @@
|
||||
{% assign omni = false %}
|
||||
{% assign core = false %}
|
||||
{% assign partners = false %}
|
||||
{% assign redirect = false %}
|
||||
|
||||
{% if current_person.signed_in? %}
|
||||
{% assign log_out = false %}
|
||||
{% for group in current_person.groups %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% if group.name contains 'Partners' %}
|
||||
{% assign partners = true %}
|
||||
{% else %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
{% if core and learning_path.name contains 'Omni' %}
|
||||
{% if partners %}
|
||||
{% assign redirect = false %}
|
||||
{% elsif core and learning_path.name contains 'Omni' %}
|
||||
{% assign redirect = true %}
|
||||
{% elsif omni and learning_path.name contains 'Core' %}
|
||||
{% assign redirect = true %}
|
||||
|
||||
@ -1,15 +1,19 @@
|
||||
<div class="np-learning-paths-resources">
|
||||
{% if items.any? %}
|
||||
{% for learning_path in items %}
|
||||
{% if core %}
|
||||
{% if learning_path.name contains 'Core' %}
|
||||
{% if partners %}
|
||||
{% include "cards_learning_path" with learning_path %}
|
||||
{% endif %}
|
||||
{% elsif omni %}
|
||||
{% else %}
|
||||
{% if core %}
|
||||
{% if learning_path.name contains 'Core' %}
|
||||
{% include "cards_learning_path" with learning_path %}
|
||||
{% endif %}
|
||||
{% elsif omni %}
|
||||
{% if learning_path.name contains 'Omni'%}
|
||||
{% include "cards_learning_path" with learning_path %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% else %}
|
||||
<div class="np-learning-paths-resources-container">
|
||||
|
||||
@ -1,15 +1,20 @@
|
||||
{% assign omni = false %}
|
||||
{% assign core = false %}
|
||||
{% assign partners = false %}
|
||||
{% assign log_out = true %}
|
||||
|
||||
{% if current_person.signed_in? %}
|
||||
{% assign log_out = false %}
|
||||
{% for group in current_person.groups %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% if group.name contains 'Partners' %}
|
||||
{% assign partners = true %}
|
||||
{% else %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
|
||||
@ -1,18 +1,20 @@
|
||||
{% assign omni = false %}
|
||||
{% assign core = false %}
|
||||
{% assign multiprod = false %}
|
||||
{% assign partners = false %}
|
||||
{% assign log_out = true %}
|
||||
|
||||
{% if current_person.signed_in? %}
|
||||
{% assign log_out = false %}
|
||||
{% for group in current_person.groups %}
|
||||
{% if group.name contains 'Core' and if group.name contains 'Omni' %}
|
||||
{% assign multiprod = true %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% if group.name contains 'Partners' %}
|
||||
{% assign partners = true %}
|
||||
{% else %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
@ -22,11 +24,13 @@
|
||||
<main class="np-main homepage">
|
||||
<div class="hero-homepage">
|
||||
<div class="np-max-width">
|
||||
{% if core %}
|
||||
{% if partners %}
|
||||
<div class="hero-text lora">Welcome to Cin7 Academy</div>
|
||||
{% elsif core %}
|
||||
<div class="hero-text lora">Welcome to Cin7 Core Academy</div>
|
||||
{% elsif omni %}
|
||||
<div class="hero-text lora">Welcome to Cin7 Omni Academy</div>
|
||||
{% elsif log_out or multiprod%}
|
||||
{% elsif log_out %}
|
||||
<div class="hero-text lora">Welcome to Cin7 Academy</div>
|
||||
{% comment %} {% elsif multiprod %} {% endcomment %}
|
||||
{% comment %} <div class="hero-text lora">Welcome to Cin7 Academy</div> {% endcomment %}
|
||||
@ -39,7 +43,7 @@
|
||||
|
||||
<div class="page-content">
|
||||
<div class="section np-max-width">
|
||||
{% if core %}
|
||||
{% if partners %}
|
||||
<div class="heading lora">Learn Cin7 Core by your function with Learning Paths</div>
|
||||
<div class="section-content">
|
||||
{% include 'learning_path_carousel_core' %}
|
||||
@ -48,17 +52,33 @@
|
||||
<div class="section-content">
|
||||
{% include "category_carousel_core"%}
|
||||
</div>
|
||||
{% elsif omni %}
|
||||
<div class="heading lora">New to Cin7 Omni? Start learning here!</div>
|
||||
<div class="section-content">
|
||||
{% include "category_carousel"%}
|
||||
</div>
|
||||
|
||||
{% elsif core %}
|
||||
<div class="heading lora">Learn Cin7 Core by your function with Learning Paths</div>
|
||||
<div class="section-content">
|
||||
{% include 'learning_path_carousel_core' %}
|
||||
</div>
|
||||
<div class="heading lora">Grow and broaden your Cin7 Core expertise with Deep Dives</div>
|
||||
<div class="section-content">
|
||||
{% include "category_carousel_core"%}
|
||||
</div>
|
||||
|
||||
{% elsif omni %}
|
||||
<div class="heading lora">New to Cin7 Omni? Start learning here!</div>
|
||||
<div class="section-content">
|
||||
{% include "category_carousel"%}
|
||||
</div>
|
||||
{% elsif log_out or multiprod %}
|
||||
|
||||
{% elsif log_out %}
|
||||
<div class="heading lora">Learn Cin7 Core by your function with Learning Paths</div>
|
||||
<div class="section-content">
|
||||
{% include 'learning_path_carousel_core' %}
|
||||
</div>
|
||||
<div class="heading lora">Grow and broaden your Cin7 Core expertise with Deep Dives</div>
|
||||
<div class="heading awdlorawda">Grow and broaden your Cin7 Core expertise with Deep Dives</div>
|
||||
<div class="section-content">
|
||||
{% include "category_carousel_core"%}
|
||||
</div>
|
||||
|
||||
@ -1,15 +1,20 @@
|
||||
{% assign omni = false %}
|
||||
{% assign core = false %}
|
||||
{% assign partners = false %}
|
||||
{% assign log_out = true %}
|
||||
|
||||
{% if current_person.signed_in? %}
|
||||
{% assign log_out = false %}
|
||||
{% for group in current_person.groups %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% if group.name contains 'Partners' %}
|
||||
{% assign partners = true %}
|
||||
{% else %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
@ -43,7 +48,7 @@
|
||||
const urlParams = new URLSearchParams(window.location.search);
|
||||
const categoriesFromURL = urlParams.getAll('category');
|
||||
if (categoriesFromURL.length === 0) {
|
||||
return;
|
||||
return;
|
||||
}
|
||||
const cards = document.querySelectorAll('.lp-card');
|
||||
|
||||
@ -55,9 +60,9 @@
|
||||
const filterCards = () => {
|
||||
cards.forEach(card => {
|
||||
if (cardMatchesCategories(card, categoriesFromURL)) {
|
||||
card.style.display = 'block';
|
||||
card.style.display = 'block';
|
||||
} else {
|
||||
card.style.display = 'none';
|
||||
card.style.display = 'none';
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
@ -1,19 +1,23 @@
|
||||
{% assign omni = false %}
|
||||
{% assign core = false %}
|
||||
{% assign partners = false %}
|
||||
{% assign log_out = true %}
|
||||
|
||||
{% if current_person.signed_in? %}
|
||||
{% assign log_out = false %}
|
||||
{% for group in current_person.groups %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% if group.name contains 'Partners' %}
|
||||
{% assign partners = true %}
|
||||
{% else %}
|
||||
{% if group.name contains 'Core' %}
|
||||
{% assign core = true %}
|
||||
{% elsif group.name contains 'Omni' %}
|
||||
{% assign omni = true %}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
|
||||
{% include "header" %}
|
||||
<main class="np-main np-search np-subpage-container np-max-width">
|
||||
<div class="np-resource-title">
|
||||
|
||||
Reference in New Issue
Block a user