doctype html
html
head
- if CmAdmin.config.enable_tracking
/ Google Tag Manager
script
| (function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':
| new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
| j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src=
| 'https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);
| })(window,document,'script','dataLayer','GTM-N6898ZX9');
/ End Google Tag Manager
script
| window.dataLayer = window.dataLayer || [];
| dataLayer.push({
| 'projectName': "#{project_name_with_env}"
| });
title
= project_name_with_env
meta[name="viewport" content="width=device-width,initial-scale=1"]
= csrf_meta_tags
= csp_meta_tag
= stylesheet_link_tag 'cm_admin/cm_admin', media: 'all', 'data-turbo-track': 'reload'
= javascript_importmap_tags
= javascript_import_module_tag "cm_admin/application"
script src="https://kit.fontawesome.com/9c93dde7a7.js" data-mutate-approach="sync"
= stylesheet_link_tag 'cm_admin/custom', media: 'all', 'data-turbo-track': 'reload'
link href="https://cdn.jsdelivr.net/npm/select2@4.1.0-rc.0/dist/css/select2.min.css" rel="stylesheet" /
script src="https://raw.githack.com/SortableJS/Sortable/master/Sortable.js"
link[rel="stylesheet" href="https://cdn.jsdelivr.net/npm/select2-bootstrap-5-theme@1.3.0/dist/select2-bootstrap-5-theme.min.css"]
link[rel="stylesheet" href="https://cdn.jsdelivr.net/npm/select2-bootstrap-5-theme@1.3.0/dist/select2-bootstrap-5-theme.rtl.min.css"]
body
- if CmAdmin.config.enable_tracking
/ Google Tag Manager (noscript)
noscript
iframe src="https://www.googletagmanager.com/ns.html?id=GTM-N6898ZX9" height="0" width="0" style="display:none;visibility:hidden"
/ End Google Tag Manager (noscript)
.cm-admin
= render 'layouts/left_sidebar_nav'
.panel-area
- if defined?(@action) && (@action&.layout_type.to_s == 'cm_association_show' || @action.parent == "show")
.show-page
.show-page__header.page-top-bar
== render 'cm_admin/main/top_navbar'
== render 'cm_admin/main/tabs', via_xhr: false
.show-page__inner
= yield
- elsif defined?(@action) && (@action&.layout_type.to_s == 'cm_association_index' || @action.parent == "index")
.show-page
.show-page__header.page-top-bar
== render 'cm_admin/main/top_navbar'
- if @ar_object.model_name
== render 'cm_admin/main/tabs', via_xhr: false
- if @associated_model && (@associated_model.filters.present? || has_valid_policy(@associated_ar_object, :export))
.cm-index-page__filters
.filters-bar
== render partial: 'cm_admin/main/filters', locals: { filters: @associated_model.filters }
- if has_valid_policy(@associated_ar_object, :export)
.export-container
button.btn-dark data-bs-toggle="modal" data-bs-target="#exportModal"
i.fa-regular.fa-file-export.me-1
| Export
= yield
- else
= yield
div data-behaviour="flash-container"
= render 'layouts/cm_flash_message'
div data-behaviour="export-modal-container"
= render 'layouts/custom_action_modals'