Changeset 1023371
- Timestamp:
- 11/10/2014 09:03:42 PM (11 years ago)
- Location:
- restaurant-manager
- Files:
-
- 14 edited
-
tags/v1.1.6/assets/css/admin-style.css (modified) (1 diff)
-
tags/v1.1.6/assets/css/style.css (modified) (1 diff)
-
tags/v1.1.6/class-plugin.php (modified) (2 diffs)
-
tags/v1.1.6/framework/php/shortcodes/tinymce/js/min/tmce-synth-tinymce-sc-plugin-4x.min.js (modified) (1 diff)
-
tags/v1.1.6/includes/functions-helpers.php (modified) (1 diff)
-
tags/v1.1.6/includes/shortcodes/components/reservation.php (modified) (1 diff)
-
tags/v1.1.6/includes/shortcodes/components/restaurant-menu.php (modified) (1 diff)
-
trunk/assets/css/admin-style.css (modified) (1 diff)
-
trunk/assets/css/style.css (modified) (1 diff)
-
trunk/class-plugin.php (modified) (2 diffs)
-
trunk/framework/php/shortcodes/tinymce/js/min/tmce-synth-tinymce-sc-plugin-4x.min.js (modified) (1 diff)
-
trunk/includes/functions-helpers.php (modified) (1 diff)
-
trunk/includes/shortcodes/components/reservation.php (modified) (1 diff)
-
trunk/includes/shortcodes/components/restaurant-menu.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
restaurant-manager/tags/v1.1.6/assets/css/admin-style.css
r1022451 r1023371 560 560 font-weight: bold; 561 561 } 562 /* =Restaurant Menus563 -------------------------------------------------------------- */564 #syn_restaurant_manager_addons .addons-list {565 display: table;566 table-layout: fixed;567 width: 100%;568 }569 #syn_restaurant_manager_addons .addon-item {570 display: table-cell;571 padding: 0 20px 20px 0;572 width: 33.33333333%;573 }574 #syn_restaurant_manager_addons .addon-block {575 border: 1px solid #e1e1e1;576 background-color: #ffffff;577 margin: 0 20px 20px 0;578 -webkit-box-sizing: border-box;579 -moz-box-sizing: border-box;580 box-sizing: border-box;581 }582 #syn_restaurant_manager_addons .addon-title {583 margin: 0;584 padding: 20px;585 border-bottom: 1px solid #e1e1e1;586 }587 #syn_restaurant_manager_addons .addon-content {588 padding: 20px;589 overflow: hidden;590 border-bottom: 1px solid #e1e1e1;591 }592 #syn_restaurant_manager_addons .addon-content:before,593 #syn_restaurant_manager_addons .addon-content:after {594 clear: both;595 content: '\0020';596 display: block;597 overflow: hidden;598 visibility: hidden;599 width: 0;600 height: 0;601 }602 #syn_restaurant_manager_addons .addon-image {603 float: left;604 display: block;605 margin: 0 20px 20px 0;606 width: 150px;607 height: 150px;608 }609 #syn_restaurant_manager_addons .addon-footer {610 line-height: 28px;611 padding: 20px;612 background-color: #fcfafa;613 }614 #syn_restaurant_manager_addons .addon-footer:before,615 #syn_restaurant_manager_addons .addon-footer:after {616 clear: both;617 content: '\0020';618 display: block;619 overflow: hidden;620 visibility: hidden;621 width: 0;622 height: 0;623 }624 #syn_restaurant_manager_addons .addon-footer .read-more-link {625 text-decoration: none;626 }627 #syn_restaurant_manager_addons .addon-footer .buy-now {628 float: right;629 } -
restaurant-manager/tags/v1.1.6/assets/css/style.css
r1022451 r1023371 1 /* 2 Created on : 14-Oct-2014, 11:32:12 3 Author : Ryan 4 */ 5 /* 6 To change this license header, choose License Headers in Project Properties. 7 To change this template file, choose Tools | Templates 8 and open the template in the editor. 9 */ 10 /* 11 Created on : 16-Oct-2014, 19:45:31 12 Author : Ryan 13 */ 14 /* 15 Created on : 16-Oct-2014, 19:54:37 16 Author : Ryan 17 */ 18 /* 19 Created on : 30-Oct-2014, 16:01:22 20 Author : Ryan 21 */ 22 @font-face { 23 font-family: 'restaurant-manager-icons'; 24 src: url('../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.eot?eb23kt'); 25 src: url('../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.eot?#iefixeb23kt') format('embedded-opentype'), url('../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.woff?eb23kt') format('woff'), url('../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.ttf?eb23kt') format('truetype'), url('../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.svg?eb23kt#restaurant-manager-icons') format('svg'); 26 font-weight: normal; 27 font-style: normal; 28 } 29 [class^="rman-"], 30 [class*=" rman-"] { 31 font-family: 'restaurant-manager-icons'; 32 speak: none; 33 font-style: normal; 34 font-weight: normal; 35 font-variant: normal; 36 text-transform: none; 37 line-height: 1; 38 /* Better Font Rendering =========== */ 39 -webkit-font-smoothing: antialiased; 40 -moz-osx-font-smoothing: grayscale; 41 } 42 .rman-flame:before { 43 content: "\f0df"; 44 } 45 .rman-clock-o:before { 46 content: "\f017"; 47 } 48 .rman-times-circle:before { 49 content: "\f057"; 50 } 51 .rman-calendar:before { 52 content: "\f073"; 53 } 54 .rman-chevron-circle-up:before { 55 content: "\f139"; 56 } 57 .rman-chevron-circle-down:before { 58 content: "\f13a"; 59 } 60 .rman-syntaxstudio:before { 61 content: "\e600"; 62 } 63 .rman-knife-and-fork:before { 64 content: "\e601"; 65 } 66 #syn_restaurant_manager { 67 /* =Form 68 -------------------------------------------------------------- */ 69 } 70 #syn_restaurant_manager .synth-form label.error { 71 color: red; 72 width: 100%; 73 font-size: 90%; 74 } 75 #syn_restaurant_manager .synth-form label.error:before { 76 display: inline; 77 width: auto; 78 height: auto; 79 line-height: normal; 80 vertical-align: baseline; 81 background-image: none; 82 background-position: 0% 0%; 83 background-repeat: repeat; 84 margin-top: 0; 85 font-family: FontAwesome; 86 font-weight: normal; 87 font-style: normal; 88 text-decoration: inherit; 89 -webkit-font-smoothing: antialiased; 90 content: "\f057"; 91 margin-right: 4px; 92 } 93 #syn_restaurant_manager .synth-form .form-field { 94 overflow: auto; 95 margin-bottom: 20px; 96 } 97 #syn_restaurant_manager .synth-form .form-label { 98 display: inline-block; 99 width: 100%; 100 margin: 0; 101 } 102 #syn_restaurant_manager .synth-form .form-label label { 103 width: 100%; 104 } 105 #syn_restaurant_manager .synth-form .form-control { 106 display: inline-block; 107 width: 90%; 108 margin: 0; 109 } 110 #syn_restaurant_manager .synth-form .form-control .inline-error { 111 color: red; 112 display: none; 113 } 114 #syn_restaurant_manager .synth-form .form-control textarea { 115 height: 100px; 116 } 117 #syn_restaurant_manager .synth-form .captcha { 118 position: relative; 119 width: 30%; 120 } 121 #syn_restaurant_manager .synth-form .captcha .captcha-sum { 122 position: absolute; 123 display: inline-block; 124 padding: 8px 6px; 125 font-weight: bold; 126 } 127 #syn_restaurant_manager .synth-form .captcha .captcha-result { 128 padding-left: 60px; 129 } 130 #syn_restaurant_manager .synth-form input[type=text], 131 #syn_restaurant_manager .synth-form textarea { 132 width: 100%; 133 } 134 #syn_restaurant_manager .synth-form label input[type="checkbox"] { 135 position: relative; 136 vertical-align: middle; 137 bottom: 1px; 138 margin: 0 5px 0 0; 139 } 140 /*Restaurant Menu*/ 141 .syn-restaurant-menu { 142 position: relative; 143 margin: 0; 144 padding: 0; 145 list-style-type: none; 146 } 147 .syn-restaurant-menu li { 148 margin: 0; 149 padding: 0; 150 } 151 .syn-restaurant-menu .syn-menu-title { 152 font-weight: bold; 153 } 154 .syn-restaurant-menu .syn-menu-content { 155 margin: 0 0 30px 0; 156 padding: 0; 157 } 158 .syn-restaurant-menu .syn-menu-content:before, 159 .syn-restaurant-menu .syn-menu-content:after { 160 clear: both; 161 content: '\0020'; 162 display: block; 163 overflow: hidden; 164 visibility: hidden; 165 width: 0; 166 height: 0; 167 } 168 .syn-restaurant-menu .syn-menu-excerpt { 169 float: left; 170 display: inline-block; 171 width: 70%; 172 } 173 .syn-restaurant-menu .syn-menu-price { 174 float: right; 175 display: inline-block; 176 width: 20%; 177 text-align: right; 178 } 179 .syn-restaurant-menu .syn-menu-properties { 180 clear: both; 181 display: block; 182 } 183 .syn-restaurant-menu .syn-menu-properties span { 184 padding: 0 10px; 185 } 186 .syn-restaurant-menu .syn-menu-properties span:first-child { 187 padding: 0 10px 0 0; 188 } 189 .syn-restaurant-menu .syn-spice-rating .rating-star { 190 padding: 0; 191 } 192 .syn-restaurant-menu .syn-spice-rating .rating-star:first-child { 193 padding: 0; 194 } 1 @font-face{font-family:restaurant-manager-icons;src:url(../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.eot?eb23kt);src:url(../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.eot?#iefixeb23kt) format('embedded-opentype'),url(../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.woff?eb23kt) format('woff'),url(../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.ttf?eb23kt) format('truetype'),url(../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.svg?eb23kt#restaurant-manager-icons) format('svg');font-weight:400;font-style:normal}[class^=rman-],[class*=" rman-"]{font-family:restaurant-manager-icons;speak:none;font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.rman-flame:before{content:"\f0df"}.rman-clock-o:before{content:"\f017"}.rman-times-circle:before{content:"\f057"}.rman-calendar:before{content:"\f073"}.rman-chevron-circle-up:before{content:"\f139"}.rman-chevron-circle-down:before{content:"\f13a"}.rman-syntaxstudio:before{content:"\e600"}.rman-knife-and-fork:before{content:"\e601"}#syn_restaurant_manager .synth-form label.error{color:red;width:100%;font-size:90%}#syn_restaurant_manager .synth-form label.error:before{display:inline;width:auto;height:auto;line-height:normal;vertical-align:baseline;background-image:none;background-position:0 0;background-repeat:repeat;margin-top:0;font-family:FontAwesome;font-weight:400;font-style:normal;text-decoration:inherit;-webkit-font-smoothing:antialiased;content:"\f057";margin-right:4px}#syn_restaurant_manager .synth-form .form-field{overflow:auto;margin-bottom:20px}#syn_restaurant_manager .synth-form .form-label{display:inline-block;width:100%;margin:0}#syn_restaurant_manager .synth-form .form-label label{width:100%}#syn_restaurant_manager .synth-form .form-control{display:inline-block;width:90%;margin:0}#syn_restaurant_manager .synth-form .form-control .inline-error{color:red;display:none}#syn_restaurant_manager .synth-form .form-control textarea{height:100px}#syn_restaurant_manager .synth-form .captcha{position:relative;width:30%}#syn_restaurant_manager .synth-form .captcha .captcha-sum{position:absolute;display:inline-block;padding:8px 6px;font-weight:700}#syn_restaurant_manager .synth-form .captcha .captcha-result{padding-left:60px}#syn_restaurant_manager .synth-form input[type=text],#syn_restaurant_manager .synth-form textarea{width:100%}.syn-restaurant-menu{position:relative;margin:0;padding:0;list-style-type:none}.syn-restaurant-menu li{margin:0;padding:0}.syn-restaurant-menu .syn-menu-title{font-weight:700}.syn-restaurant-menu .syn-menu-content{margin:0 0 30px;padding:0}.syn-restaurant-menu .syn-menu-content:before,.syn-restaurant-menu .syn-menu-content:after{clear:both;content:'\0020';display:block;overflow:hidden;visibility:hidden;width:0;height:0}.syn-restaurant-menu .syn-menu-excerpt{float:left;display:inline-block;width:70%}.syn-restaurant-menu .syn-menu-price{float:right;display:inline-block;width:20%;text-align:right}.syn-restaurant-menu .syn-menu-properties{clear:both;display:block}.syn-restaurant-menu .syn-menu-properties span{padding:0 10px}.syn-restaurant-menu .syn-menu-properties span:first-child{padding:0 10px 0 0}.syn-restaurant-menu .syn-spice-rating .rating-star{padding:0}.syn-restaurant-menu .syn-spice-rating .rating-star:first-child{padding:0} -
restaurant-manager/tags/v1.1.6/class-plugin.php
r1022451 r1023371 30 30 */ 31 31 public function install_database_tables() { 32 32 33 33 } 34 34 … … 168 168 169 169 wp_enqueue_style('restaurant-manager-style', plugins_url('/assets/css/style.css', __FILE__)); 170 wp_enqueue_style('jquery-pickdate-style', $this->_config->plugin_url . '/assets/js/pickdate/themes/pickdate.css'); 170 171 171 172 //wp_enqueue_script('syntaxthemes-controls-script', plugins_url('/assets/js/synth-controls.js', __FILE__), array('jquery', 'jquery-ui-core', 'jquery-ui-slider', 'jquery-ui-datepicker', 'jquery-timepicker-script'), false, true); -
restaurant-manager/tags/v1.1.6/framework/php/shortcodes/tinymce/js/min/tmce-synth-tinymce-sc-plugin-4x.min.js
r1022451 r1023371 1 jQuery(document).ready(function() { 2 3 "use strict"; 4 5 (function() { 6 7 var button_name = 'restaurant_shortcodes'; 8 var plugin_name = syn_restaurant_manager_shortcodes.globals[button_name]['plugin_name']; 9 10 tinymce.create('tinymce.plugins.' + plugin_name, { 11 /** 12 * Initializes the plugin, this will be executed after the plugin has been created. 13 * This call is done before the editor instance has finished it's initialization so use the onInit event 14 * of the editor instance to intercept that event. 15 * 16 * @param {tinymce.Editor} ed Editor instance that the plugin is initialized in. 17 * @param {string} url Absolute URL to where the plugin is located. 18 */ 19 init: function(editor, url) { 20 21 editor.addButton(button_name, { 22 type: 'menuButton', 23 text: '', 24 title: syn_restaurant_manager_shortcodes.globals[button_name].title, 25 image: syn_restaurant_manager_shortcodes.globals[button_name].image, 26 icons: button_name, 27 menu: this.createMenu(editor) 28 }); 29 30 editor.addCommand('openSynthModal' + button_name, function(ui, params) { 31 32 var modal = new syn_restaurant_manager_js.SynthModal(params); 33 return false; 34 }); 35 }, 36 /** 37 * Creates control instances based in the incomming name. This method is normally not 38 * needed since the addButton method of the tinymce.Editor class is a more easy way of adding buttons 39 * but you sometimes need to create more complex controls like listboxes, split buttons etc then this 40 * method can be used to create those. 41 * 42 * @param {String} n Name of the control to create. 43 * @param {tinymce.ControlManager} cm Control manager to use inorder to create new control. 44 * @return {tinymce.ui.Control} New control instance or null if no control was created. 45 */ 46 createMenu: function(editor) { 47 48 var menu_options = []; 49 var shortcodes = syn_restaurant_manager_shortcodes.globals[button_name].config; 50 var submenu = []; 51 52 for (var i in shortcodes) { 53 54 submenu[shortcodes[i].menu] = []; 55 } 56 57 for (var title in submenu) { 58 59 if (title !== 'undefined') { 60 61 menu_options.push({text: title, menu: []}); 62 } 63 } 64 65 for (var j in shortcodes) { 66 67 if (shortcodes[j].show_in_menu !== false) { 68 var current_menu = menu_options; 69 70 for (var title in menu_options) { 71 72 if (title !== 'undefined') 73 { 74 if (menu_options[title].text === shortcodes[j].menu) { 75 current_menu = menu_options[title].menu; 76 } 77 } 78 } 79 80 var click_event = (shortcodes[j].modal_editor === false) ? this.directToEditorWrite : this.modalToEditorWrite; 81 current_menu.push({text: shortcodes[j].heading, onclick: click_event, shortcode: shortcodes[j]}); 82 } 83 } 84 85 return menu_options; 86 87 }, 88 directToEditorWrite: function() { 89 90 var shortcode = this.settings.shortcode; 91 tinymce.activeEditor.execCommand("mceInsertContent", false, window.switchEditors.wpautop(shortcode.editor_insert)); 92 }, 93 modalToEditorWrite: function() { 94 95 var shortcode = this.settings.shortcode; 96 tinymce.activeEditor.execCommand('openSynthModal' + button_name, false, 97 { 98 scope: tinymce.activeEditor, 99 modal_class: shortcode.modal_class, 100 modal_title: shortcode.heading, 101 modal_button: shortcode.modal_button, 102 ajax_hook: shortcode.name, 103 load_callback: shortcode.modal_support, 104 save_callback: function(values) { 105 106 var params = []; 107 var output; 108 109 var prefix = shortcode.name + '_'; 110 111 for (var val in values) { 112 113 var name = val.replace(prefix, ""); 114 if (name !== val && name !== prefix) { 115 116 params[name] = values[val]; 117 delete values[val]; 118 } 119 } 120 values = null; 121 122 output = window.switchEditors.wpautop(syn_restaurant_manager_js_core.create_shortcode_tag(shortcode.name, params)); 123 tinymce.activeEditor.execCommand("mceInsertContent", false, output); 124 } 125 }); 126 }, 127 /** 128 * Returns information about the plugin as a name/value array. 129 * The current keys are longname, author, authorurl, infourl and version. 130 * 131 * @return {Object} Name/value array containing information about the plugin. 132 */ 133 getInfo: function() { 134 return { 135 longname: 'Shortcodes Manager', 136 author: 'Ryan Haworth', 137 authorurl: 'http://www.syntaxthemes.co.uk', 138 version: "1.0" 139 }; 140 } 141 }); 142 // Register plugin 143 tinymce.PluginManager.add(plugin_name, tinymce.plugins.syn_restaurant_manager_shortcodes_plugin); 144 })(); 145 }); 146 147 1 jQuery(document).ready(function(){"use strict";!function(){var t="restaurant_shortcodes",e=syn_restaurant_manager_shortcodes.globals[t].plugin_name;tinymce.create("tinymce.plugins."+e,{init:function(e){e.addButton(t,{type:"menuButton",text:"",title:syn_restaurant_manager_shortcodes.globals[t].title,image:syn_restaurant_manager_shortcodes.globals[t].image,icons:t,menu:this.createMenu(e)}),e.addCommand("openSynthModal"+t,function(t,e){new syn_restaurant_manager_js.SynthModal(e);return!1})},createMenu:function(){var e=[],n=syn_restaurant_manager_shortcodes.globals[t].config,a=[];for(var o in n)a[n[o].menu]=[];for(var r in a)"undefined"!==r&&e.push({text:r,menu:[]});for(var i in n)if(n[i].show_in_menu!==!1){var s=e;for(var r in e)"undefined"!==r&&e[r].text===n[i].menu&&(s=e[r].menu);var c=n[i].modal_editor===!1?this.directToEditorWrite:this.modalToEditorWrite;s.push({text:n[i].heading,onclick:c,shortcode:n[i]})}return e},directToEditorWrite:function(){var t=this.settings.shortcode;tinymce.activeEditor.execCommand("mceInsertContent",!1,window.switchEditors.wpautop(t.editor_insert))},modalToEditorWrite:function(){var e=this.settings.shortcode;tinymce.activeEditor.execCommand("openSynthModal"+t,!1,{scope:tinymce.activeEditor,modal_class:e.modal_class,modal_title:e.heading,modal_button:e.modal_button,ajax_hook:e.name,load_callback:e.modal_support,save_callback:function(t){var n,a=[],o=e.name+"_";for(var r in t){var i=r.replace(o,"");i!==r&&i!==o&&(a[i]=t[r],delete t[r])}t=null,n=window.switchEditors.wpautop(syn_restaurant_manager_js_core.create_shortcode_tag(e.name,a)),tinymce.activeEditor.execCommand("mceInsertContent",!1,n)}})},getInfo:function(){return{longname:"Shortcodes Manager",author:"Ryan Haworth",authorurl:"http://www.syntaxthemes.co.uk",version:"1.0"}}}),tinymce.PluginManager.add(e,tinymce.plugins.syn_restaurant_manager_shortcodes_plugin)}()}); -
restaurant-manager/tags/v1.1.6/includes/functions-helpers.php
r1022451 r1023371 1 1 <?php 2 3 function syn_restaurant_manager_the_content_filter($content) { 4 5 // array of custom shortcodes requiring the fix 6 $block = join("|", array('syn_restaurant_reservation', 'syn_restaurant_menu')); 7 8 // opening tag 9 $rep = preg_replace("/(<p>)?\[($block)(\s[^\]]+)?\](<\/p>|<br \/>)?/", "[$2$3]", $content); 10 11 // closing tag 12 $rep = preg_replace("/(<p>)?\[\/($block)](<\/p>|<br \/>)?/", "[/$2]", $rep); 13 14 return $rep; 15 } 16 17 add_filter("the_content", "syn_restaurant_manager_the_content_filter"); 2 18 3 19 /** -
restaurant-manager/tags/v1.1.6/includes/shortcodes/components/reservation.php
r1022451 r1023371 176 176 if ($this->do_add_script) { 177 177 178 wp_enqueue_style('jquery-pickdate-style', $this->_config->plugin_url . '/assets/js/pickdate/themes/pickdate.css');179 180 178 wp_enqueue_script('restaurant-manager-script', $this->_config->plugin_url . '/assets/js/synth-restaurant.js', array('jquery', 'jquery-ui-core', 'jquery-ui-datepicker', 'jquery-pickdate-picker-script', 'jquery-pickdate-date-script', 'jquery-pickdate-time-script'), false, true); 181 179 wp_enqueue_script('jquery-validation-script', $this->_config->plugin_url . '/framework/js/validation/jquery.validate.min.js', array('jquery'), '1.11.1', true); -
restaurant-manager/tags/v1.1.6/includes/shortcodes/components/restaurant-menu.php
r1022451 r1023371 134 134 </h4> 135 135 <div class="syn-menu-content"> 136 < span class="syn-menu-excerpt"><?php the_excerpt() ?></span>136 <div class="syn-menu-excerpt"><?php the_excerpt() ?></div> 137 137 <?php if ($full_price && ($full_price !== '0.00') && ($display_price === 'on')) { ?> 138 138 <span class="syn-menu-price"><?php echo $currency_symbol . $full_price ?></span> -
restaurant-manager/trunk/assets/css/admin-style.css
r1021648 r1023371 560 560 font-weight: bold; 561 561 } 562 /* =Restaurant Menus563 -------------------------------------------------------------- */564 #syn_restaurant_manager_addons .addons-list {565 display: table;566 table-layout: fixed;567 width: 100%;568 }569 #syn_restaurant_manager_addons .addon-item {570 display: table-cell;571 padding: 0 20px 20px 0;572 width: 33.33333333%;573 }574 #syn_restaurant_manager_addons .addon-block {575 border: 1px solid #e1e1e1;576 background-color: #ffffff;577 margin: 0 20px 20px 0;578 -webkit-box-sizing: border-box;579 -moz-box-sizing: border-box;580 box-sizing: border-box;581 }582 #syn_restaurant_manager_addons .addon-title {583 margin: 0;584 padding: 20px;585 border-bottom: 1px solid #e1e1e1;586 }587 #syn_restaurant_manager_addons .addon-content {588 padding: 20px;589 overflow: hidden;590 border-bottom: 1px solid #e1e1e1;591 }592 #syn_restaurant_manager_addons .addon-content:before,593 #syn_restaurant_manager_addons .addon-content:after {594 clear: both;595 content: '\0020';596 display: block;597 overflow: hidden;598 visibility: hidden;599 width: 0;600 height: 0;601 }602 #syn_restaurant_manager_addons .addon-image {603 float: left;604 display: block;605 margin: 0 20px 20px 0;606 width: 150px;607 height: 150px;608 }609 #syn_restaurant_manager_addons .addon-footer {610 line-height: 28px;611 padding: 20px;612 background-color: #fcfafa;613 }614 #syn_restaurant_manager_addons .addon-footer:before,615 #syn_restaurant_manager_addons .addon-footer:after {616 clear: both;617 content: '\0020';618 display: block;619 overflow: hidden;620 visibility: hidden;621 width: 0;622 height: 0;623 }624 #syn_restaurant_manager_addons .addon-footer .read-more-link {625 text-decoration: none;626 }627 #syn_restaurant_manager_addons .addon-footer .buy-now {628 float: right;629 } -
restaurant-manager/trunk/assets/css/style.css
r1021648 r1023371 1 /* 2 Created on : 14-Oct-2014, 11:32:12 3 Author : Ryan 4 */ 5 /* 6 To change this license header, choose License Headers in Project Properties. 7 To change this template file, choose Tools | Templates 8 and open the template in the editor. 9 */ 10 /* 11 Created on : 16-Oct-2014, 19:45:31 12 Author : Ryan 13 */ 14 /* 15 Created on : 16-Oct-2014, 19:54:37 16 Author : Ryan 17 */ 18 /* 19 Created on : 30-Oct-2014, 16:01:22 20 Author : Ryan 21 */ 22 @font-face { 23 font-family: 'restaurant-manager-icons'; 24 src: url('../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.eot?eb23kt'); 25 src: url('../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.eot?#iefixeb23kt') format('embedded-opentype'), url('../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.woff?eb23kt') format('woff'), url('../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.ttf?eb23kt') format('truetype'), url('../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.svg?eb23kt#restaurant-manager-icons') format('svg'); 26 font-weight: normal; 27 font-style: normal; 28 } 29 [class^="rman-"], 30 [class*=" rman-"] { 31 font-family: 'restaurant-manager-icons'; 32 speak: none; 33 font-style: normal; 34 font-weight: normal; 35 font-variant: normal; 36 text-transform: none; 37 line-height: 1; 38 /* Better Font Rendering =========== */ 39 -webkit-font-smoothing: antialiased; 40 -moz-osx-font-smoothing: grayscale; 41 } 42 .rman-flame:before { 43 content: "\f0df"; 44 } 45 .rman-clock-o:before { 46 content: "\f017"; 47 } 48 .rman-times-circle:before { 49 content: "\f057"; 50 } 51 .rman-calendar:before { 52 content: "\f073"; 53 } 54 .rman-chevron-circle-up:before { 55 content: "\f139"; 56 } 57 .rman-chevron-circle-down:before { 58 content: "\f13a"; 59 } 60 .rman-syntaxstudio:before { 61 content: "\e600"; 62 } 63 .rman-knife-and-fork:before { 64 content: "\e601"; 65 } 66 #syn_restaurant_manager { 67 /* =Form 68 -------------------------------------------------------------- */ 69 } 70 #syn_restaurant_manager .synth-form label.error { 71 color: red; 72 width: 100%; 73 font-size: 90%; 74 } 75 #syn_restaurant_manager .synth-form label.error:before { 76 display: inline; 77 width: auto; 78 height: auto; 79 line-height: normal; 80 vertical-align: baseline; 81 background-image: none; 82 background-position: 0% 0%; 83 background-repeat: repeat; 84 margin-top: 0; 85 font-family: FontAwesome; 86 font-weight: normal; 87 font-style: normal; 88 text-decoration: inherit; 89 -webkit-font-smoothing: antialiased; 90 content: "\f057"; 91 margin-right: 4px; 92 } 93 #syn_restaurant_manager .synth-form .form-field { 94 overflow: auto; 95 margin-bottom: 20px; 96 } 97 #syn_restaurant_manager .synth-form .form-label { 98 display: inline-block; 99 width: 100%; 100 margin: 0; 101 } 102 #syn_restaurant_manager .synth-form .form-label label { 103 width: 100%; 104 } 105 #syn_restaurant_manager .synth-form .form-control { 106 display: inline-block; 107 width: 90%; 108 margin: 0; 109 } 110 #syn_restaurant_manager .synth-form .form-control .inline-error { 111 color: red; 112 display: none; 113 } 114 #syn_restaurant_manager .synth-form .form-control textarea { 115 height: 100px; 116 } 117 #syn_restaurant_manager .synth-form .captcha { 118 position: relative; 119 width: 30%; 120 } 121 #syn_restaurant_manager .synth-form .captcha .captcha-sum { 122 position: absolute; 123 display: inline-block; 124 padding: 8px 6px; 125 font-weight: bold; 126 } 127 #syn_restaurant_manager .synth-form .captcha .captcha-result { 128 padding-left: 60px; 129 } 130 #syn_restaurant_manager .synth-form input[type=text], 131 #syn_restaurant_manager .synth-form textarea { 132 width: 100%; 133 } 134 #syn_restaurant_manager .synth-form label input[type="checkbox"] { 135 position: relative; 136 vertical-align: middle; 137 bottom: 1px; 138 margin: 0 5px 0 0; 139 } 140 /*Restaurant Menu*/ 141 .syn-restaurant-menu { 142 position: relative; 143 margin: 0; 144 padding: 0; 145 list-style-type: none; 146 } 147 .syn-restaurant-menu li { 148 margin: 0; 149 padding: 0; 150 } 151 .syn-restaurant-menu .syn-menu-title { 152 font-weight: bold; 153 } 154 .syn-restaurant-menu .syn-menu-content { 155 margin: 0 0 30px 0; 156 padding: 0; 157 } 158 .syn-restaurant-menu .syn-menu-content:before, 159 .syn-restaurant-menu .syn-menu-content:after { 160 clear: both; 161 content: '\0020'; 162 display: block; 163 overflow: hidden; 164 visibility: hidden; 165 width: 0; 166 height: 0; 167 } 168 .syn-restaurant-menu .syn-menu-excerpt { 169 float: left; 170 display: inline-block; 171 width: 70%; 172 } 173 .syn-restaurant-menu .syn-menu-price { 174 float: right; 175 display: inline-block; 176 width: 20%; 177 text-align: right; 178 } 179 .syn-restaurant-menu .syn-menu-properties { 180 clear: both; 181 display: block; 182 } 183 .syn-restaurant-menu .syn-menu-properties span { 184 padding: 0 10px; 185 } 186 .syn-restaurant-menu .syn-menu-properties span:first-child { 187 padding: 0 10px 0 0; 188 } 189 .syn-restaurant-menu .syn-spice-rating .rating-star { 190 padding: 0; 191 } 192 .syn-restaurant-menu .syn-spice-rating .rating-star:first-child { 193 padding: 0; 194 } 1 @font-face{font-family:restaurant-manager-icons;src:url(../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.eot?eb23kt);src:url(../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.eot?#iefixeb23kt) format('embedded-opentype'),url(../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.woff?eb23kt) format('woff'),url(../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.ttf?eb23kt) format('truetype'),url(../fonts/restaurant-manager-icons/fonts/restaurant-manager-icons.svg?eb23kt#restaurant-manager-icons) format('svg');font-weight:400;font-style:normal}[class^=rman-],[class*=" rman-"]{font-family:restaurant-manager-icons;speak:none;font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.rman-flame:before{content:"\f0df"}.rman-clock-o:before{content:"\f017"}.rman-times-circle:before{content:"\f057"}.rman-calendar:before{content:"\f073"}.rman-chevron-circle-up:before{content:"\f139"}.rman-chevron-circle-down:before{content:"\f13a"}.rman-syntaxstudio:before{content:"\e600"}.rman-knife-and-fork:before{content:"\e601"}#syn_restaurant_manager .synth-form label.error{color:red;width:100%;font-size:90%}#syn_restaurant_manager .synth-form label.error:before{display:inline;width:auto;height:auto;line-height:normal;vertical-align:baseline;background-image:none;background-position:0 0;background-repeat:repeat;margin-top:0;font-family:FontAwesome;font-weight:400;font-style:normal;text-decoration:inherit;-webkit-font-smoothing:antialiased;content:"\f057";margin-right:4px}#syn_restaurant_manager .synth-form .form-field{overflow:auto;margin-bottom:20px}#syn_restaurant_manager .synth-form .form-label{display:inline-block;width:100%;margin:0}#syn_restaurant_manager .synth-form .form-label label{width:100%}#syn_restaurant_manager .synth-form .form-control{display:inline-block;width:90%;margin:0}#syn_restaurant_manager .synth-form .form-control .inline-error{color:red;display:none}#syn_restaurant_manager .synth-form .form-control textarea{height:100px}#syn_restaurant_manager .synth-form .captcha{position:relative;width:30%}#syn_restaurant_manager .synth-form .captcha .captcha-sum{position:absolute;display:inline-block;padding:8px 6px;font-weight:700}#syn_restaurant_manager .synth-form .captcha .captcha-result{padding-left:60px}#syn_restaurant_manager .synth-form input[type=text],#syn_restaurant_manager .synth-form textarea{width:100%}.syn-restaurant-menu{position:relative;margin:0;padding:0;list-style-type:none}.syn-restaurant-menu li{margin:0;padding:0}.syn-restaurant-menu .syn-menu-title{font-weight:700}.syn-restaurant-menu .syn-menu-content{margin:0 0 30px;padding:0}.syn-restaurant-menu .syn-menu-content:before,.syn-restaurant-menu .syn-menu-content:after{clear:both;content:'\0020';display:block;overflow:hidden;visibility:hidden;width:0;height:0}.syn-restaurant-menu .syn-menu-excerpt{float:left;display:inline-block;width:70%}.syn-restaurant-menu .syn-menu-price{float:right;display:inline-block;width:20%;text-align:right}.syn-restaurant-menu .syn-menu-properties{clear:both;display:block}.syn-restaurant-menu .syn-menu-properties span{padding:0 10px}.syn-restaurant-menu .syn-menu-properties span:first-child{padding:0 10px 0 0}.syn-restaurant-menu .syn-spice-rating .rating-star{padding:0}.syn-restaurant-menu .syn-spice-rating .rating-star:first-child{padding:0} -
restaurant-manager/trunk/class-plugin.php
r1021565 r1023371 30 30 */ 31 31 public function install_database_tables() { 32 32 33 33 } 34 34 … … 168 168 169 169 wp_enqueue_style('restaurant-manager-style', plugins_url('/assets/css/style.css', __FILE__)); 170 wp_enqueue_style('jquery-pickdate-style', $this->_config->plugin_url . '/assets/js/pickdate/themes/pickdate.css'); 170 171 171 172 //wp_enqueue_script('syntaxthemes-controls-script', plugins_url('/assets/js/synth-controls.js', __FILE__), array('jquery', 'jquery-ui-core', 'jquery-ui-slider', 'jquery-ui-datepicker', 'jquery-timepicker-script'), false, true); -
restaurant-manager/trunk/framework/php/shortcodes/tinymce/js/min/tmce-synth-tinymce-sc-plugin-4x.min.js
r1022451 r1023371 1 jQuery(document).ready(function() { 2 3 "use strict"; 4 5 (function() { 6 7 var button_name = 'restaurant_shortcodes'; 8 var plugin_name = syn_restaurant_manager_shortcodes.globals[button_name]['plugin_name']; 9 10 tinymce.create('tinymce.plugins.' + plugin_name, { 11 /** 12 * Initializes the plugin, this will be executed after the plugin has been created. 13 * This call is done before the editor instance has finished it's initialization so use the onInit event 14 * of the editor instance to intercept that event. 15 * 16 * @param {tinymce.Editor} ed Editor instance that the plugin is initialized in. 17 * @param {string} url Absolute URL to where the plugin is located. 18 */ 19 init: function(editor, url) { 20 21 editor.addButton(button_name, { 22 type: 'menuButton', 23 text: '', 24 title: syn_restaurant_manager_shortcodes.globals[button_name].title, 25 image: syn_restaurant_manager_shortcodes.globals[button_name].image, 26 icons: button_name, 27 menu: this.createMenu(editor) 28 }); 29 30 editor.addCommand('openSynthModal' + button_name, function(ui, params) { 31 32 var modal = new syn_restaurant_manager_js.SynthModal(params); 33 return false; 34 }); 35 }, 36 /** 37 * Creates control instances based in the incomming name. This method is normally not 38 * needed since the addButton method of the tinymce.Editor class is a more easy way of adding buttons 39 * but you sometimes need to create more complex controls like listboxes, split buttons etc then this 40 * method can be used to create those. 41 * 42 * @param {String} n Name of the control to create. 43 * @param {tinymce.ControlManager} cm Control manager to use inorder to create new control. 44 * @return {tinymce.ui.Control} New control instance or null if no control was created. 45 */ 46 createMenu: function(editor) { 47 48 var menu_options = []; 49 var shortcodes = syn_restaurant_manager_shortcodes.globals[button_name].config; 50 var submenu = []; 51 52 for (var i in shortcodes) { 53 54 submenu[shortcodes[i].menu] = []; 55 } 56 57 for (var title in submenu) { 58 59 if (title !== 'undefined') { 60 61 menu_options.push({text: title, menu: []}); 62 } 63 } 64 65 for (var j in shortcodes) { 66 67 if (shortcodes[j].show_in_menu !== false) { 68 var current_menu = menu_options; 69 70 for (var title in menu_options) { 71 72 if (title !== 'undefined') 73 { 74 if (menu_options[title].text === shortcodes[j].menu) { 75 current_menu = menu_options[title].menu; 76 } 77 } 78 } 79 80 var click_event = (shortcodes[j].modal_editor === false) ? this.directToEditorWrite : this.modalToEditorWrite; 81 current_menu.push({text: shortcodes[j].heading, onclick: click_event, shortcode: shortcodes[j]}); 82 } 83 } 84 85 return menu_options; 86 87 }, 88 directToEditorWrite: function() { 89 90 var shortcode = this.settings.shortcode; 91 tinymce.activeEditor.execCommand("mceInsertContent", false, window.switchEditors.wpautop(shortcode.editor_insert)); 92 }, 93 modalToEditorWrite: function() { 94 95 var shortcode = this.settings.shortcode; 96 tinymce.activeEditor.execCommand('openSynthModal' + button_name, false, 97 { 98 scope: tinymce.activeEditor, 99 modal_class: shortcode.modal_class, 100 modal_title: shortcode.heading, 101 modal_button: shortcode.modal_button, 102 ajax_hook: shortcode.name, 103 load_callback: shortcode.modal_support, 104 save_callback: function(values) { 105 106 var params = []; 107 var output; 108 109 var prefix = shortcode.name + '_'; 110 111 for (var val in values) { 112 113 var name = val.replace(prefix, ""); 114 if (name !== val && name !== prefix) { 115 116 params[name] = values[val]; 117 delete values[val]; 118 } 119 } 120 values = null; 121 122 output = window.switchEditors.wpautop(syn_restaurant_manager_js_core.create_shortcode_tag(shortcode.name, params)); 123 tinymce.activeEditor.execCommand("mceInsertContent", false, output); 124 } 125 }); 126 }, 127 /** 128 * Returns information about the plugin as a name/value array. 129 * The current keys are longname, author, authorurl, infourl and version. 130 * 131 * @return {Object} Name/value array containing information about the plugin. 132 */ 133 getInfo: function() { 134 return { 135 longname: 'Shortcodes Manager', 136 author: 'Ryan Haworth', 137 authorurl: 'http://www.syntaxthemes.co.uk', 138 version: "1.0" 139 }; 140 } 141 }); 142 // Register plugin 143 tinymce.PluginManager.add(plugin_name, tinymce.plugins.syn_restaurant_manager_shortcodes_plugin); 144 })(); 145 }); 146 147 1 jQuery(document).ready(function(){"use strict";!function(){var t="restaurant_shortcodes",e=syn_restaurant_manager_shortcodes.globals[t].plugin_name;tinymce.create("tinymce.plugins."+e,{init:function(e){e.addButton(t,{type:"menuButton",text:"",title:syn_restaurant_manager_shortcodes.globals[t].title,image:syn_restaurant_manager_shortcodes.globals[t].image,icons:t,menu:this.createMenu(e)}),e.addCommand("openSynthModal"+t,function(t,e){new syn_restaurant_manager_js.SynthModal(e);return!1})},createMenu:function(){var e=[],n=syn_restaurant_manager_shortcodes.globals[t].config,a=[];for(var o in n)a[n[o].menu]=[];for(var r in a)"undefined"!==r&&e.push({text:r,menu:[]});for(var i in n)if(n[i].show_in_menu!==!1){var s=e;for(var r in e)"undefined"!==r&&e[r].text===n[i].menu&&(s=e[r].menu);var c=n[i].modal_editor===!1?this.directToEditorWrite:this.modalToEditorWrite;s.push({text:n[i].heading,onclick:c,shortcode:n[i]})}return e},directToEditorWrite:function(){var t=this.settings.shortcode;tinymce.activeEditor.execCommand("mceInsertContent",!1,window.switchEditors.wpautop(t.editor_insert))},modalToEditorWrite:function(){var e=this.settings.shortcode;tinymce.activeEditor.execCommand("openSynthModal"+t,!1,{scope:tinymce.activeEditor,modal_class:e.modal_class,modal_title:e.heading,modal_button:e.modal_button,ajax_hook:e.name,load_callback:e.modal_support,save_callback:function(t){var n,a=[],o=e.name+"_";for(var r in t){var i=r.replace(o,"");i!==r&&i!==o&&(a[i]=t[r],delete t[r])}t=null,n=window.switchEditors.wpautop(syn_restaurant_manager_js_core.create_shortcode_tag(e.name,a)),tinymce.activeEditor.execCommand("mceInsertContent",!1,n)}})},getInfo:function(){return{longname:"Shortcodes Manager",author:"Ryan Haworth",authorurl:"http://www.syntaxthemes.co.uk",version:"1.0"}}}),tinymce.PluginManager.add(e,tinymce.plugins.syn_restaurant_manager_shortcodes_plugin)}()}); -
restaurant-manager/trunk/includes/functions-helpers.php
r1021565 r1023371 1 1 <?php 2 3 function syn_restaurant_manager_the_content_filter($content) { 4 5 // array of custom shortcodes requiring the fix 6 $block = join("|", array('syn_restaurant_reservation', 'syn_restaurant_menu')); 7 8 // opening tag 9 $rep = preg_replace("/(<p>)?\[($block)(\s[^\]]+)?\](<\/p>|<br \/>)?/", "[$2$3]", $content); 10 11 // closing tag 12 $rep = preg_replace("/(<p>)?\[\/($block)](<\/p>|<br \/>)?/", "[/$2]", $rep); 13 14 return $rep; 15 } 16 17 add_filter("the_content", "syn_restaurant_manager_the_content_filter"); 2 18 3 19 /** -
restaurant-manager/trunk/includes/shortcodes/components/reservation.php
r1021489 r1023371 176 176 if ($this->do_add_script) { 177 177 178 wp_enqueue_style('jquery-pickdate-style', $this->_config->plugin_url . '/assets/js/pickdate/themes/pickdate.css');179 180 178 wp_enqueue_script('restaurant-manager-script', $this->_config->plugin_url . '/assets/js/synth-restaurant.js', array('jquery', 'jquery-ui-core', 'jquery-ui-datepicker', 'jquery-pickdate-picker-script', 'jquery-pickdate-date-script', 'jquery-pickdate-time-script'), false, true); 181 179 wp_enqueue_script('jquery-validation-script', $this->_config->plugin_url . '/framework/js/validation/jquery.validate.min.js', array('jquery'), '1.11.1', true); -
restaurant-manager/trunk/includes/shortcodes/components/restaurant-menu.php
r1021565 r1023371 134 134 </h4> 135 135 <div class="syn-menu-content"> 136 < span class="syn-menu-excerpt"><?php the_excerpt() ?></span>136 <div class="syn-menu-excerpt"><?php the_excerpt() ?></div> 137 137 <?php if ($full_price && ($full_price !== '0.00') && ($display_price === 'on')) { ?> 138 138 <span class="syn-menu-price"><?php echo $currency_symbol . $full_price ?></span>
Note: See TracChangeset
for help on using the changeset viewer.