如果有緊急事故或特別安排,例如活動延期或取消等,可於活動主頁彈出視窗,顯示通告:
於活動的「內容管理」,於「主頁」下,查看有沒有「 彈出視窗 - Popup Window」,有的話,只需把狀態設為「有效」,即可顯示。
如沒有,可使用「滙入」功能,把以下代碼滙入至內容管理:
滙入代碼:
{
"id": 42432,
"type": 3,
"status": 0,
"parent_id": 24029,
"cat_id": 0,
"cat2_id": 0,
"template_id": 127,
"link_cat_id": 0,
"link_post_id": 0,
"link_gallery_id": 0,
"title": "彈出視窗 - Popup Window",
"body": "<h2><span style=\"color: #ff0000;\"><strong>*特別通告*\u000b<br \/><\/strong><\/span><\/h2>\r\nLorem ipsum dolor sit amet, consectetur adipisicing elit. Doloribus ea, eveniet dolores. Nam dolorum tempore nihil doloribus, ex cupiditate, repudiandae inventore natus distinctio odio quasi ipsam libero et expedita esse.<br \/><br \/> Lorem ipsum dolor sit amet, consectetur adipisicing elit. Temporibus natus omnis dolorum commodi, nisi optio! Quo ipsam sunt laborum quasi quam possimus voluptatem, sint, quia accusantium officiis earum sed nam!",
"body_2": "<h1> <\/h1>",
"link_url_target": "_self",
"created_at": "2020-04-15 17:41:58",
"updated_at": "2020-04-15 17:47:56",
"published_at": "2020-02-17 13:14:15",
"order": 0,
"hidden_navbar": 0,
"d_show_intro": 0,
"d_show_body": 1,
"d_show_date": 0,
"d_css_class": 0,
"d_show_cat2": 0,
"d_show_link_cat": 0,
"d_show_link_post": 0,
"d_show_link_gallery": 0,
"d_intro_height": 200,
"d_body_height": 400,
"d_images_no": 0,
"d_files_no": 0,
"event_id": 43,
"user_id": 1,
"lm_user_id": 1,
"child_count": 0,
"d_intro_plaintext": 0,
"d_body_plaintext": 0,
"d_show_bgcolor": 0,
"params": {
"template_show_title": "1",
"template_show_title_separator": "1",
"template_bgimage_classes": [],
"template_show_pub_at": "1",
"template_show_intro": "1",
"template_show_firstimage": "1",
"enable_cpt": "0",
"d_show_subtitle": "0",
"d_image_show_title": "0",
"d_image_show_link": "0",
"d_image_show_link_target": "0",
"d_image_show_link_label": "0",
"d_show_tab_layout": "1",
"d_show_gallery": "0",
"d_show_custom_css": "1",
"d_show_custom_js": "1",
"d_show_lang": "0",
"d_show_pub": "1"
},
"sysuse": 0,
"gallery_count": 0,
"file_count": 0,
"image_count": 0,
"need_login": -1,
"views": 0,
"parent": {
"id": 24029,
"type": 11,
"status": 1,
"parent_id": 0,
"cat_id": 3,
"cat2_id": 0,
"code": "ev_home",
"template_id": 0,
"layout_template_id": 59,
"link_cat_id": 0,
"link_post_id": 0,
"link_gallery_id": 0,
"title": "主頁",
"title_2": "Home",
"link_url_target": "_self",
"created_at": "2018-05-09 17:03:36",
"updated_at": "2019-05-31 15:50:05",
"published_at": "2016-07-25 14:16:02",
"order": 123,
"template_file": "main",
"hidden_navbar": 0,
"d_show_intro": 0,
"d_show_body": 1,
"d_show_date": 0,
"d_css_class": 1,
"d_show_cat2": 0,
"d_show_link_cat": 1,
"d_show_link_post": 1,
"d_show_link_gallery": 1,
"d_intro_height": 200,
"d_body_height": 400,
"d_images_no": 99,
"d_files_no": 0,
"event_id": 43,
"lm_user_id": 1,
"child_count": 5,
"d_intro_plaintext": 0,
"d_body_plaintext": 0,
"d_show_bgcolor": 0,
"params": {
"template_show_title": "1",
"template_show_title_separator": "1",
"template_show_pub_at": "1",
"template_show_intro": "1",
"template_show_firstimage": "1",
"template_show_scroll_to_top": "0",
"blacklist_user_package_ids": [],
"enable_cpt": "0",
"d_show_subtitle": "0",
"d_image_show_title": "0",
"d_image_show_link_label": "0"
},
"sysuse": 0,
"gallery_count": 0,
"file_count": 0,
"image_count": 0,
"need_login": -1,
"views": 0
},
"images": [],
"galleries": [],
"template": {
"id": 127,
"theme_id": 2,
"theme_code": "jg",
"code": "modal_popup",
"type": "script",
"status": 1,
"pagetypes": [
"3"
],
"dparams": [],
"created_at": "2019-03-22 12:28:03",
"updated_at": "2019-04-08 17:20:52",
"preview_parent": "jg.script.cookie_disclaimer_agree_only",
"php": "{{-- Force cookie disclaimer --}} \r\n@isset ($row)\r\n@push('footer_script2')\r\n@php\r\n $pivot_params = (isset($pivot_params) == false ) ? null: $pivot_params;\r\n\r\n \/\/get params from pageable privot or partial\r\n $expiry_day = ThemeHelper::getTemplateParam($row, $pivot_params, 'template_cookie_disclaimer_expire_day', 7);\r\n@endphp\r\n\r\n<script>\r\n$(document).ready(function() { \r\n\r\n \/\/check if cookie saved in client\r\n\r\n var body = {!! json_encode(['myString' => Helper::tb($row)]) !!};\r\n var dialog = bootbox.dialog({\r\n message: '<p class=\"text-center\"><\/p>' + body.myString,\r\n closeButton: true,\r\n onEscape: true,\r\n backdrop: true,\r\n size: 'large',\r\n className: 'mypopup mypopup-{{ $row->id }}',\r\n buttons: {\r\n confirm: {\r\n label: '<i class=\"fa fa-check\"><\/i> OK',\r\n className: 'btn-primary c-theme-btn'\r\n }\r\n }\r\n }); \r\n \r\n});\r\n<\/script>\r\n@endpush\r\n@endisset"
}
}
滙入後,把狀態設為「有效」,即可顯示。