Version Description
Download this release
Release Info
Developer | bordoni |
Plugin | The Events Calendar |
Version | 4.6.6 |
Comparing to | |
See all releases |
Code changes from version 4.6.5 to 4.6.6
- common/readme.txt +7 -0
- common/src/Tribe/Container.php +37 -5
- common/src/Tribe/Main.php +3 -1
- common/src/Tribe/Template.php +383 -0
- common/src/Tribe/Utils/Callback.php +109 -0
- common/tribe-common.php +1 -1
- lang/the-events-calendar-ru_RU.mo +0 -0
- lang/the-events-calendar-ru_RU.po +17 -17
- lang/the-events-calendar.pot +121 -89
- readme.txt +9 -1
- src/Tribe/Aggregator/API/Import.php +2 -1
- src/Tribe/Aggregator/Admin_Bar.php +6 -1
- src/Tribe/Aggregator/Page.php +1 -0
- src/Tribe/Aggregator/Record/Abstract.php +7 -2
- src/Tribe/Aggregator/Service.php +20 -0
- src/Tribe/Aggregator/Tabs/New.php +11 -3
- src/Tribe/Main.php +2 -2
- src/admin-views/aggregator/tabs/import-form.php +1 -0
- src/resources/js/aggregator-fields.js +47 -5
- src/resources/js/aggregator-fields.min.js +1 -1
- the-events-calendar.php +1 -1
common/readme.txt
CHANGED
@@ -2,6 +2,12 @@
|
|
2 |
|
3 |
== Changelog ==
|
4 |
|
|
|
|
|
|
|
|
|
|
|
|
|
5 |
= [4.7.1] 2017-11-16 =
|
6 |
|
7 |
* Fix - Added support for translatable placeholder text when dropdown selectors are waiting on results being returned via ajax [84926]
|
@@ -120,3 +126,4 @@
|
|
120 |
|
121 |
* Fix - Resolved issue where the Meta Chunker attempted to inappropriately chunk meta for post post_types [80857]
|
122 |
* Language - 0 new strings added, 0 updated, 1 fuzzied, and 0 obsoleted [tribe-common]
|
|
2 |
|
3 |
== Changelog ==
|
4 |
|
5 |
+
= [4.7.2] 2017-11-21 =
|
6 |
+
|
7 |
+
* Feature - Added Template class which adds a few layers of filtering to any template file included
|
8 |
+
* Tweak - Included `tribe_callback_return` for static returns for Hooks
|
9 |
+
* Language - 0 new strings added, 0 updated, 1 fuzzied, and 0 obsoleted
|
10 |
+
|
11 |
= [4.7.1] 2017-11-16 =
|
12 |
|
13 |
* Fix - Added support for translatable placeholder text when dropdown selectors are waiting on results being returned via ajax [84926]
|
126 |
|
127 |
* Fix - Resolved issue where the Meta Chunker attempted to inappropriately chunk meta for post post_types [80857]
|
128 |
* Language - 0 new strings added, 0 updated, 1 fuzzied, and 0 obsoleted [tribe-common]
|
129 |
+
|
common/src/Tribe/Container.php
CHANGED
@@ -247,16 +247,48 @@ if ( ! function_exists( 'tribe_register_provider' ) ) {
|
|
247 |
* Returns a lambda function suitable to use as a callback; when called the function will build the implementation
|
248 |
* bound to `$classOrInterface` and return the value of a call to `$method` method with the call arguments.
|
249 |
*
|
250 |
-
* @
|
251 |
-
* @
|
252 |
-
* specified array arguments.
|
253 |
*
|
254 |
-
* @
|
|
|
|
|
|
|
|
|
|
|
255 |
*/
|
256 |
function tribe_callback( $slug, $method ) {
|
257 |
$container = Tribe__Container::init();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
258 |
|
259 |
-
return $
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
260 |
}
|
261 |
}
|
262 |
}
|
247 |
* Returns a lambda function suitable to use as a callback; when called the function will build the implementation
|
248 |
* bound to `$classOrInterface` and return the value of a call to `$method` method with the call arguments.
|
249 |
*
|
250 |
+
* @since 4.7
|
251 |
+
* @since TBD Included the $argsN params
|
|
|
252 |
*
|
253 |
+
* @param string $slug A class or interface fully qualified name or a string slug.
|
254 |
+
* @param string $method The method that should be called on the resolved implementation with the
|
255 |
+
* specified array arguments.
|
256 |
+
* @param mixed [$argsN] (optional) Any number of arguments that will be passed down to the Callback
|
257 |
+
*
|
258 |
+
* @return callable A PHP Callable based on the Slug and Methods passed
|
259 |
*/
|
260 |
function tribe_callback( $slug, $method ) {
|
261 |
$container = Tribe__Container::init();
|
262 |
+
$arguments = func_get_args();
|
263 |
+
$is_empty = 2 === count( $arguments );
|
264 |
+
|
265 |
+
if ( $is_empty ) {
|
266 |
+
$callable = $container->callback( $slug, $method );
|
267 |
+
} else {
|
268 |
+
$callback = $container->callback( 'callback', 'get' );
|
269 |
+
$callable = call_user_func_array( $callback, $arguments );
|
270 |
+
}
|
271 |
|
272 |
+
return $callable;
|
273 |
+
}
|
274 |
+
}
|
275 |
+
|
276 |
+
if ( ! function_exists( 'tribe_callback_return' ) ) {
|
277 |
+
/**
|
278 |
+
* Returns a tribe_callback for a very simple Return value method
|
279 |
+
*
|
280 |
+
* Example of Usage:
|
281 |
+
*
|
282 |
+
* add_filter( 'admin_title', tribe_callback_return( __( 'Ready to work.' ) ) );
|
283 |
+
*
|
284 |
+
* @since TBD
|
285 |
+
*
|
286 |
+
* @param mixed $value The value to be returned
|
287 |
+
*
|
288 |
+
* @return callable A PHP Callable based on the Slug and Methods passed
|
289 |
+
*/
|
290 |
+
function tribe_callback_return( $value ) {
|
291 |
+
return tribe_callback( 'callback', 'return_value', $value );
|
292 |
}
|
293 |
}
|
294 |
}
|
common/src/Tribe/Main.php
CHANGED
@@ -17,7 +17,7 @@ class Tribe__Main {
|
|
17 |
const OPTIONNAME = 'tribe_events_calendar_options';
|
18 |
const OPTIONNAMENETWORK = 'tribe_events_calendar_network_options';
|
19 |
|
20 |
-
const VERSION = '4.7.
|
21 |
|
22 |
const FEED_URL = 'https://theeventscalendar.com/feed/';
|
23 |
|
@@ -560,5 +560,7 @@ class Tribe__Main {
|
|
560 |
tribe_singleton( 'cost-utils', array( 'Tribe__Cost_Utils', 'instance' ) );
|
561 |
tribe_singleton( 'post-duplicate.strategy-factory', 'Tribe__Duplicate__Strategy_Factory' );
|
562 |
tribe_singleton( 'post-duplicate', 'Tribe__Duplicate__Post' );
|
|
|
|
|
563 |
}
|
564 |
}
|
17 |
const OPTIONNAME = 'tribe_events_calendar_options';
|
18 |
const OPTIONNAMENETWORK = 'tribe_events_calendar_network_options';
|
19 |
|
20 |
+
const VERSION = '4.7.2';
|
21 |
|
22 |
const FEED_URL = 'https://theeventscalendar.com/feed/';
|
23 |
|
560 |
tribe_singleton( 'cost-utils', array( 'Tribe__Cost_Utils', 'instance' ) );
|
561 |
tribe_singleton( 'post-duplicate.strategy-factory', 'Tribe__Duplicate__Strategy_Factory' );
|
562 |
tribe_singleton( 'post-duplicate', 'Tribe__Duplicate__Post' );
|
563 |
+
|
564 |
+
tribe_singleton( 'callback', 'Tribe__Utils__Callback' );
|
565 |
}
|
566 |
}
|
common/src/Tribe/Template.php
ADDED
@@ -0,0 +1,383 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
class Tribe__Template {
|
3 |
+
/**
|
4 |
+
* The folders into we will look for the template
|
5 |
+
*
|
6 |
+
* @since TBD
|
7 |
+
*
|
8 |
+
* @var array
|
9 |
+
*/
|
10 |
+
protected $folder = array();
|
11 |
+
|
12 |
+
/**
|
13 |
+
* The origin class for the plugin where the template lives
|
14 |
+
*
|
15 |
+
* @since TBD
|
16 |
+
*
|
17 |
+
* @var object
|
18 |
+
*/
|
19 |
+
public $origin;
|
20 |
+
|
21 |
+
/**
|
22 |
+
* The local context for templates, muteable on every self::template() call
|
23 |
+
*
|
24 |
+
* @since TBD
|
25 |
+
*
|
26 |
+
* @var array
|
27 |
+
*/
|
28 |
+
protected $context;
|
29 |
+
|
30 |
+
/**
|
31 |
+
* The global context for this instance of templates
|
32 |
+
*
|
33 |
+
* @since TBD
|
34 |
+
*
|
35 |
+
* @var array
|
36 |
+
*/
|
37 |
+
protected $global = array();
|
38 |
+
|
39 |
+
/**
|
40 |
+
* Allow chaing if class will extract data from the local context
|
41 |
+
*
|
42 |
+
* @since TBD
|
43 |
+
*
|
44 |
+
* @var boolean
|
45 |
+
*/
|
46 |
+
protected $template_context_extract = false;
|
47 |
+
|
48 |
+
/**
|
49 |
+
* Base template for where to look for template
|
50 |
+
*
|
51 |
+
* @since TBD
|
52 |
+
*
|
53 |
+
* @var array
|
54 |
+
*/
|
55 |
+
protected $template_base_path;
|
56 |
+
|
57 |
+
/**
|
58 |
+
* Configures the class origin plugin path
|
59 |
+
*
|
60 |
+
* @since TBD
|
61 |
+
*
|
62 |
+
* @param object|string $origin The base origin for the templates
|
63 |
+
*
|
64 |
+
* @return self
|
65 |
+
*/
|
66 |
+
public function set_template_origin( $origin = null ) {
|
67 |
+
if ( empty( $origin ) ) {
|
68 |
+
$origin = $this->origin;
|
69 |
+
}
|
70 |
+
|
71 |
+
if ( is_string( $origin ) ) {
|
72 |
+
// Origin needs to be a class with a `instance` method
|
73 |
+
if ( class_exists( $origin ) && method_exists( $origin, 'instance' ) ) {
|
74 |
+
$origin = call_user_func( array( $origin, 'instance' ) );
|
75 |
+
}
|
76 |
+
}
|
77 |
+
|
78 |
+
if ( empty( $origin->plugin_path ) && empty( $origin->pluginPath ) && ! is_dir( $origin ) ) {
|
79 |
+
throw new InvalidArgumentException( 'Invalid Origin Class for Template Instance' );
|
80 |
+
}
|
81 |
+
|
82 |
+
if ( ! is_string( $origin ) ) {
|
83 |
+
$this->origin = $origin;
|
84 |
+
$this->template_base_path = untrailingslashit( ! empty( $this->origin->plugin_path ) ? $this->origin->plugin_path : $this->origin->pluginPath );
|
85 |
+
} else {
|
86 |
+
$this->template_base_path = untrailingslashit( (array) explode( '/', $origin ) );
|
87 |
+
}
|
88 |
+
|
89 |
+
return $this;
|
90 |
+
}
|
91 |
+
|
92 |
+
/**
|
93 |
+
* Configures the class with the base folder in relation to the Origin
|
94 |
+
*
|
95 |
+
* @since TBD
|
96 |
+
*
|
97 |
+
* @param array|string $folder Which folder we are going to look for templates
|
98 |
+
*
|
99 |
+
* @return self
|
100 |
+
*/
|
101 |
+
public function set_template_folder( $folder = null ) {
|
102 |
+
// Allows configuring a already set class
|
103 |
+
if ( ! isset( $folder ) ) {
|
104 |
+
$folder = $this->folder;
|
105 |
+
}
|
106 |
+
|
107 |
+
// If Folder is String make it an Array
|
108 |
+
if ( is_string( $folder ) ) {
|
109 |
+
$folder = (array) explode( '/', $folder );
|
110 |
+
}
|
111 |
+
|
112 |
+
// Cast as Array and save
|
113 |
+
$this->folder = (array) $folder;
|
114 |
+
|
115 |
+
return $this;
|
116 |
+
}
|
117 |
+
|
118 |
+
/**
|
119 |
+
* Configures the class global context
|
120 |
+
*
|
121 |
+
* @since TBD
|
122 |
+
*
|
123 |
+
* @param array $context Default global Context
|
124 |
+
*
|
125 |
+
* @return self
|
126 |
+
*/
|
127 |
+
public function add_template_globals( $context = array() ) {
|
128 |
+
// Cast as Array merge and save
|
129 |
+
$this->global = wp_parse_args( (array) $context, $this->global );
|
130 |
+
|
131 |
+
return $this;
|
132 |
+
}
|
133 |
+
|
134 |
+
/**
|
135 |
+
* Configures if the class will extract context for template
|
136 |
+
*
|
137 |
+
* @since TBD
|
138 |
+
*
|
139 |
+
* @param bool $value Should we extract context for templates
|
140 |
+
*
|
141 |
+
* @return self
|
142 |
+
*/
|
143 |
+
public function set_template_context_extract( $value = false ) {
|
144 |
+
// Cast as bool and save
|
145 |
+
$this->template_context_extract = (bool) $value;
|
146 |
+
|
147 |
+
return $this;
|
148 |
+
}
|
149 |
+
|
150 |
+
/**
|
151 |
+
* Gets the base path for this Instance of Templates
|
152 |
+
*
|
153 |
+
* @since TBD
|
154 |
+
*
|
155 |
+
* @return string
|
156 |
+
*/
|
157 |
+
public function get_base_path() {
|
158 |
+
// Craft the Base Path
|
159 |
+
$path = array_merge( (array) $this->template_base_path, $this->folder );
|
160 |
+
|
161 |
+
// Implode to avoid Window Problems
|
162 |
+
$path = implode( DIRECTORY_SEPARATOR, $path );
|
163 |
+
|
164 |
+
/**
|
165 |
+
* Allows filtering of the base path for templates
|
166 |
+
*
|
167 |
+
* @param string $path Complete path to include the base folder
|
168 |
+
* @param self $template Current instance of the Tribe__Template
|
169 |
+
*/
|
170 |
+
return apply_filters( 'tribe_template_base_path', $path, $this );
|
171 |
+
}
|
172 |
+
|
173 |
+
/**
|
174 |
+
* Sets a Index inside of the global or local context
|
175 |
+
* Final to prevent extending the class when the `get` already exists on the child class
|
176 |
+
*
|
177 |
+
* @since TBD
|
178 |
+
*
|
179 |
+
* @see Tribe__Utils__Array::set
|
180 |
+
*
|
181 |
+
* @param array $index Specify each nested index in order.
|
182 |
+
* Example: array( 'lvl1', 'lvl2' );
|
183 |
+
* @param mixed $default Default value if the search finds nothing.
|
184 |
+
* @param boolean $is_local Use the Local or Global context
|
185 |
+
*
|
186 |
+
* @return mixed The value of the specified index or the default if not found.
|
187 |
+
*/
|
188 |
+
final public function get( $index, $default = null, $is_local = true ) {
|
189 |
+
$context = $this->global;
|
190 |
+
|
191 |
+
if ( true === $is_local ) {
|
192 |
+
$context = $this->context;
|
193 |
+
}
|
194 |
+
|
195 |
+
/**
|
196 |
+
* Allows filtering the the getting of Context variables, also short circuiting
|
197 |
+
* Following the same strucuture as WP Core
|
198 |
+
*
|
199 |
+
* @since TBD
|
200 |
+
*
|
201 |
+
* @param mixed $value The value that will be filtered
|
202 |
+
* @param array $index Specify each nested index in order.
|
203 |
+
* Example: array( 'lvl1', 'lvl2' );
|
204 |
+
* @param mixed $default Default value if the search finds nothing.
|
205 |
+
* @param boolean $is_local Use the Local or Global context
|
206 |
+
* @param self $template Current instance of the Tribe__Template
|
207 |
+
*/
|
208 |
+
$value = apply_filters( 'tribe_template_context_get', null, $index, $default, $is_local, $this );
|
209 |
+
if ( null !== $value ) {
|
210 |
+
return $value;
|
211 |
+
}
|
212 |
+
|
213 |
+
return Tribe__Utils__Array::get( $context, $index, $default );
|
214 |
+
}
|
215 |
+
|
216 |
+
/**
|
217 |
+
* Sets a Index inside of the global or local context
|
218 |
+
* Final to prevent extending the class when the `set` already exists on the child class
|
219 |
+
*
|
220 |
+
* @since TBD
|
221 |
+
*
|
222 |
+
* @see Tribe__Utils__Array::set
|
223 |
+
*
|
224 |
+
* @param string|array $index To set a key nested multiple levels deep pass an array
|
225 |
+
* specifying each key in order as a value.
|
226 |
+
* Example: array( 'lvl1', 'lvl2', 'lvl3' );
|
227 |
+
* @param mixed $value The value.
|
228 |
+
* @param boolean $is_local Use the Local or Global context
|
229 |
+
*
|
230 |
+
* @return array Full array with the key set to the specified value.
|
231 |
+
*/
|
232 |
+
final public function set( $index, $value = null, $is_local = true ) {
|
233 |
+
if ( true === $is_local ) {
|
234 |
+
return Tribe__Utils__Array::set( $this->context, $index, $value );
|
235 |
+
} else {
|
236 |
+
return Tribe__Utils__Array::set( $this->global, $index, $value );
|
237 |
+
}
|
238 |
+
}
|
239 |
+
|
240 |
+
/**
|
241 |
+
* Merges local and global context, and saves it locally
|
242 |
+
*
|
243 |
+
* @since TBD
|
244 |
+
*
|
245 |
+
* @param array $context Local Context array of data
|
246 |
+
* @param string $file Complete path to include the PHP File
|
247 |
+
* @param array $name Template name
|
248 |
+
*
|
249 |
+
* @return array
|
250 |
+
*/
|
251 |
+
public function merge_context( $context = array(), $file = null, $name = null ) {
|
252 |
+
// Allow for simple null usage as well as array() for nothing
|
253 |
+
if ( is_null( $context ) ) {
|
254 |
+
$context = array();
|
255 |
+
}
|
256 |
+
|
257 |
+
// Applies local context on top of Global one
|
258 |
+
$context = wp_parse_args( (array) $context, $this->global );
|
259 |
+
|
260 |
+
/**
|
261 |
+
* Allows filtering the Local context
|
262 |
+
*
|
263 |
+
* @since TBD
|
264 |
+
*
|
265 |
+
* @param array $context Local Context array of data
|
266 |
+
* @param string $file Complete path to include the PHP File
|
267 |
+
* @param array $name Template name
|
268 |
+
* @param self $template Current instance of the Tribe__Template
|
269 |
+
*/
|
270 |
+
$this->context = apply_filters( 'tribe_template_context', $context, $file, $name, $this );
|
271 |
+
|
272 |
+
return $this->context;
|
273 |
+
}
|
274 |
+
|
275 |
+
/**
|
276 |
+
* A very simple method to include a Aggregator Template, allowing filtering and additions using hooks.
|
277 |
+
*
|
278 |
+
* @since TBD
|
279 |
+
*
|
280 |
+
* @param string $name Which file we are talking about including
|
281 |
+
* @param array $context Any context data you need to expose to this file
|
282 |
+
* @param boolean $echo If we should also print the Template
|
283 |
+
*
|
284 |
+
* @return string Final Content HTML
|
285 |
+
*/
|
286 |
+
public function template( $name, $context = array(), $echo = true ) {
|
287 |
+
// If name is String make it an Array
|
288 |
+
if ( is_string( $name ) ) {
|
289 |
+
$name = (array) explode( '/', $name );
|
290 |
+
}
|
291 |
+
|
292 |
+
// Clean this Variable
|
293 |
+
$name = array_map( 'sanitize_title_with_dashes', $name );
|
294 |
+
|
295 |
+
// Apply the .php to the last item on the name
|
296 |
+
$name[ count( $name ) - 1 ] .= '.php';
|
297 |
+
|
298 |
+
// Build the File Path
|
299 |
+
$file = implode( DIRECTORY_SEPARATOR, array_merge( (array) $this->get_base_path(), $name ) );
|
300 |
+
|
301 |
+
/**
|
302 |
+
* A more Specific Filter that will include the template name
|
303 |
+
*
|
304 |
+
* @since TBD
|
305 |
+
*
|
306 |
+
* @param string $file Complete path to include the PHP File
|
307 |
+
* @param array $name Template name
|
308 |
+
* @param self $template Current instance of the Tribe__Template
|
309 |
+
*/
|
310 |
+
$file = apply_filters( 'tribe_template_file', $file, $name, $this );
|
311 |
+
|
312 |
+
// Before we load the file we check if it exists
|
313 |
+
if ( ! file_exists( $file ) ) {
|
314 |
+
return false;
|
315 |
+
}
|
316 |
+
|
317 |
+
ob_start();
|
318 |
+
|
319 |
+
// Merges the local data passed to template to the global scope
|
320 |
+
$this->merge_context( $context, $file, $name );
|
321 |
+
|
322 |
+
/**
|
323 |
+
* Fires an Action before including the template file
|
324 |
+
*
|
325 |
+
* @since TBD
|
326 |
+
*
|
327 |
+
* @param string $file Complete path to include the PHP File
|
328 |
+
* @param array $name Template name
|
329 |
+
* @param self $template Current instance of the Tribe__Template
|
330 |
+
*/
|
331 |
+
do_action( 'tribe_template_before_include', $file, $name, $this );
|
332 |
+
|
333 |
+
// Only do this if really needed (by default it wont)
|
334 |
+
if ( true === $this->template_context_extract && ! empty( $this->context ) ) {
|
335 |
+
// We don't allow Extrating of a variable called $name
|
336 |
+
if ( isset( $this->context['name'] ) ) {
|
337 |
+
unset( $this->context['name'] );
|
338 |
+
}
|
339 |
+
|
340 |
+
// We don't allow Extrating of a variable called $file
|
341 |
+
if ( isset( $this->context['file'] ) ) {
|
342 |
+
unset( $this->context['file'] );
|
343 |
+
}
|
344 |
+
|
345 |
+
// Make any provided variables available in the template variable scope
|
346 |
+
extract( $this->context ); // @codingStandardsIgnoreLine
|
347 |
+
}
|
348 |
+
|
349 |
+
include $file;
|
350 |
+
|
351 |
+
/**
|
352 |
+
* Fires an Action After including the template file
|
353 |
+
*
|
354 |
+
* @since TBD
|
355 |
+
*
|
356 |
+
* @param string $file Complete path to include the PHP File
|
357 |
+
* @param array $name Template name
|
358 |
+
* @param self $template Current instance of the Tribe__Template
|
359 |
+
*/
|
360 |
+
do_action( 'tribe_template_after_include', $file, $name, $this );
|
361 |
+
|
362 |
+
// Only fetch the contents after the action
|
363 |
+
$html = ob_get_clean();
|
364 |
+
|
365 |
+
/**
|
366 |
+
* Allow users to filter the final HTML
|
367 |
+
*
|
368 |
+
* @since TBD
|
369 |
+
*
|
370 |
+
* @param string $html The final HTML
|
371 |
+
* @param string $file Complete path to include the PHP File
|
372 |
+
* @param array $name Template name
|
373 |
+
* @param self $template Current instance of the Tribe__Template
|
374 |
+
*/
|
375 |
+
$html = apply_filters( 'tribe_template_html', $html, $file, $name, $this );
|
376 |
+
|
377 |
+
if ( $echo ) {
|
378 |
+
echo $html;
|
379 |
+
}
|
380 |
+
|
381 |
+
return $html;
|
382 |
+
}
|
383 |
+
}
|
common/src/Tribe/Utils/Callback.php
ADDED
@@ -0,0 +1,109 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
class Tribe__Utils__Callback {
|
4 |
+
|
5 |
+
/**
|
6 |
+
* Where we store all the Callbacks to allow removing of hooks
|
7 |
+
*
|
8 |
+
* @since TBD
|
9 |
+
*
|
10 |
+
* @var array
|
11 |
+
*/
|
12 |
+
public $items = array();
|
13 |
+
|
14 |
+
/**
|
15 |
+
* The Prefix we use for the Overloading replacement
|
16 |
+
*
|
17 |
+
* @since TBD
|
18 |
+
*
|
19 |
+
* @var string
|
20 |
+
*/
|
21 |
+
protected $prefix = 'callback_';
|
22 |
+
|
23 |
+
/**
|
24 |
+
* Returns a callable for on this class that doesn't exist, but passes in the Key for Di52 Slug and it's method
|
25 |
+
* and arguments. It will relayed via overloading __call() on this same class.
|
26 |
+
*
|
27 |
+
* The lambda function suitable to use as a callback; when called the function will build the implementation
|
28 |
+
* bound to `$classOrInterface` and return the value of a call to `$method` method with the call arguments.
|
29 |
+
*
|
30 |
+
* @since TBD
|
31 |
+
*
|
32 |
+
* @param string $slug A class or interface fully qualified name or a string slug.
|
33 |
+
* @param string $method The method that should be called on the resolved implementation with the
|
34 |
+
* specified array arguments.
|
35 |
+
*
|
36 |
+
* @return array The callable
|
37 |
+
*/
|
38 |
+
public function get( $slug, $method ) {
|
39 |
+
$container = Tribe__Container::init();
|
40 |
+
$arguments = func_get_args();
|
41 |
+
$is_empty = 2 === count( $arguments );
|
42 |
+
|
43 |
+
// Remove Slug and Method
|
44 |
+
array_shift( $arguments );
|
45 |
+
array_shift( $arguments );
|
46 |
+
|
47 |
+
$item = (object) array(
|
48 |
+
'slug' => $slug,
|
49 |
+
'method' => $method,
|
50 |
+
'arguments' => $arguments,
|
51 |
+
'is_empty' => $is_empty,
|
52 |
+
);
|
53 |
+
|
54 |
+
$key = md5( json_encode( $item ) );
|
55 |
+
|
56 |
+
// Prevent this from been reset
|
57 |
+
if ( isset( $this->items[ $key ] ) ) {
|
58 |
+
return $this->items[ $key ];
|
59 |
+
}
|
60 |
+
|
61 |
+
$item->callback = $container->callback( $item->slug, $item->method );
|
62 |
+
|
63 |
+
$this->items[ $key ] = $item;
|
64 |
+
|
65 |
+
return array( $this, $this->prefix . $key );
|
66 |
+
}
|
67 |
+
|
68 |
+
/**
|
69 |
+
* Returns the Value passed as a simple Routing method for tribe_callback_return
|
70 |
+
*
|
71 |
+
* @since TBD
|
72 |
+
*
|
73 |
+
* @param mixed $value Value to be Routed
|
74 |
+
*
|
75 |
+
* @return mixed
|
76 |
+
*/
|
77 |
+
public function return_value( $value ) {
|
78 |
+
return $value;
|
79 |
+
}
|
80 |
+
|
81 |
+
/**
|
82 |
+
* Calls the Lambda function provided by Di52 to allow passing of Params without having to create more
|
83 |
+
* methods into classes for simple callbacks that will only have a pre-determined value.
|
84 |
+
*
|
85 |
+
* @since TBD
|
86 |
+
*
|
87 |
+
* @param string $slug A class or interface fully qualified name or a string slug.
|
88 |
+
* @param string $method The method that should be called on the resolved implementation with the
|
89 |
+
* specified array arguments.
|
90 |
+
*
|
91 |
+
* @return mixed The Return value used
|
92 |
+
*/
|
93 |
+
public function __call( $method, $args ) {
|
94 |
+
$key = str_replace( $this->prefix, '', $method );
|
95 |
+
|
96 |
+
if ( ! isset( $this->items[ $key ] ) ) {
|
97 |
+
return false;
|
98 |
+
}
|
99 |
+
|
100 |
+
$item = $this->items[ $key ];
|
101 |
+
|
102 |
+
// Allow for previous compatibility with tribe_callback
|
103 |
+
if ( ! $item->is_empty ) {
|
104 |
+
$args = $item->arguments;
|
105 |
+
}
|
106 |
+
|
107 |
+
return call_user_func_array( $item->callback, $args );
|
108 |
+
}
|
109 |
+
}
|
common/tribe-common.php
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?php
|
2 |
/*
|
3 |
Description: An event settings framework for managing shared options
|
4 |
-
Version: 4.7.
|
5 |
Author: Modern Tribe, Inc.
|
6 |
Author URI: http://m.tri.be/1x
|
7 |
Text Domain: tribe-common
|
1 |
<?php
|
2 |
/*
|
3 |
Description: An event settings framework for managing shared options
|
4 |
+
Version: 4.7.2
|
5 |
Author: Modern Tribe, Inc.
|
6 |
Author URI: http://m.tri.be/1x
|
7 |
Text Domain: tribe-common
|
lang/the-events-calendar-ru_RU.mo
CHANGED
Binary file
|
lang/the-events-calendar-ru_RU.po
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
# This file is distributed under the same license as the Plugins - The Events Calendar - Stable (latest release) package.
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
-
"PO-Revision-Date: 2017-11-
|
6 |
"MIME-Version: 1.0\n"
|
7 |
"Content-Type: text/plain; charset=UTF-8\n"
|
8 |
"Content-Transfer-Encoding: 8bit\n"
|
@@ -809,7 +809,7 @@ msgstr ""
|
|
809 |
|
810 |
#: src/Tribe/Aggregator/Settings.php:290
|
811 |
msgid "three weeks"
|
812 |
-
msgstr ""
|
813 |
|
814 |
#: src/Tribe/Aggregator/Service.php:536
|
815 |
msgid "Events could not be imported. The URL provided did not have events in the proper format."
|
@@ -2421,11 +2421,11 @@ msgstr ""
|
|
2421 |
|
2422 |
#: src/Tribe/Aggregator/Tabs/New.php:530
|
2423 |
msgid "Learn More"
|
2424 |
-
msgstr ""
|
2425 |
|
2426 |
#: src/Tribe/Aggregator/Tabs/New.php:525 src/Tribe/Aggregator/Tabs/New.php:532
|
2427 |
msgid "opens in a new window"
|
2428 |
-
msgstr ""
|
2429 |
|
2430 |
#: src/Tribe/Aggregator/Tabs/New.php:523
|
2431 |
msgid "Buy It Now"
|
@@ -2547,7 +2547,7 @@ msgstr[2] ""
|
|
2547 |
|
2548 |
#: src/Tribe/Aggregator/Tabs/New.php:205
|
2549 |
msgid "1 import was scheduled."
|
2550 |
-
msgstr ""
|
2551 |
|
2552 |
#: src/Tribe/Aggregator/Tabs/New.php:81
|
2553 |
msgid "New Import"
|
@@ -2555,52 +2555,52 @@ msgstr ""
|
|
2555 |
|
2556 |
#: src/Tribe/Aggregator/Tabs/History.php:93
|
2557 |
msgid "History"
|
2558 |
-
msgstr ""
|
2559 |
|
2560 |
#: src/Tribe/Aggregator/Tabs/History.php:55
|
2561 |
#: src/Tribe/Aggregator/Tabs/Scheduled.php:57
|
2562 |
msgid "Records per page"
|
2563 |
-
msgstr ""
|
2564 |
|
2565 |
#: src/Tribe/Aggregator/Tabs/Favorite.php:37
|
2566 |
msgid "Favorite Imports"
|
2567 |
-
msgstr ""
|
2568 |
|
2569 |
#: src/Tribe/Aggregator/Tabs/Edit.php:143
|
2570 |
msgid "Your Scheduled Import has been updated!"
|
2571 |
-
msgstr ""
|
2572 |
|
2573 |
#: src/Tribe/Aggregator/Tabs/Edit.php:137
|
2574 |
msgid "View All Scheduled Imports"
|
2575 |
-
msgstr ""
|
2576 |
|
2577 |
#: src/Tribe/Aggregator/Tabs/Edit.php:131
|
2578 |
msgid "Scheduled import was successfully updated."
|
2579 |
-
msgstr ""
|
2580 |
|
2581 |
#: src/Tribe/Aggregator/Tabs/Edit.php:52
|
2582 |
msgid "Edit Import"
|
2583 |
-
msgstr ""
|
2584 |
|
2585 |
#: src/Tribe/Aggregator/Tabs/Abstract.php:145
|
2586 |
msgid "Please provide a Meetup URL when importing from Meetup."
|
2587 |
-
msgstr ""
|
2588 |
|
2589 |
#: src/Tribe/Aggregator/Tabs/Abstract.php:140
|
2590 |
msgid "Please provide a Facebook URL when importing from Facebook."
|
2591 |
-
msgstr ""
|
2592 |
|
2593 |
#: src/Tribe/Aggregator/Tabs/Abstract.php:189
|
2594 |
msgid "Please provide the URL that you wish to import."
|
2595 |
-
msgstr ""
|
2596 |
|
2597 |
#: src/Tribe/Aggregator/Tabs/Abstract.php:135
|
2598 |
msgid "Please provide the file that you wish to import."
|
2599 |
-
msgstr ""
|
2600 |
|
2601 |
#: src/Tribe/Aggregator/Tabs/Abstract.php:59
|
2602 |
msgid "There was a problem processing your import. Please try again."
|
2603 |
-
msgstr ""
|
2604 |
|
2605 |
#: src/Tribe/Aggregator/Service.php:170
|
2606 |
msgid "Connection timed out while transferring the feed. If you are dealing with large feeds you may need to customize the tribe_aggregator_connection_timeout filter."
|
2 |
# This file is distributed under the same license as the Plugins - The Events Calendar - Stable (latest release) package.
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
+
"PO-Revision-Date: 2017-11-17 08:37:12+0000\n"
|
6 |
"MIME-Version: 1.0\n"
|
7 |
"Content-Type: text/plain; charset=UTF-8\n"
|
8 |
"Content-Transfer-Encoding: 8bit\n"
|
809 |
|
810 |
#: src/Tribe/Aggregator/Settings.php:290
|
811 |
msgid "three weeks"
|
812 |
+
msgstr "три недели"
|
813 |
|
814 |
#: src/Tribe/Aggregator/Service.php:536
|
815 |
msgid "Events could not be imported. The URL provided did not have events in the proper format."
|
2421 |
|
2422 |
#: src/Tribe/Aggregator/Tabs/New.php:530
|
2423 |
msgid "Learn More"
|
2424 |
+
msgstr "Узнать больше"
|
2425 |
|
2426 |
#: src/Tribe/Aggregator/Tabs/New.php:525 src/Tribe/Aggregator/Tabs/New.php:532
|
2427 |
msgid "opens in a new window"
|
2428 |
+
msgstr "открывается в новом окне"
|
2429 |
|
2430 |
#: src/Tribe/Aggregator/Tabs/New.php:523
|
2431 |
msgid "Buy It Now"
|
2547 |
|
2548 |
#: src/Tribe/Aggregator/Tabs/New.php:205
|
2549 |
msgid "1 import was scheduled."
|
2550 |
+
msgstr "1 импортирование было запланировано."
|
2551 |
|
2552 |
#: src/Tribe/Aggregator/Tabs/New.php:81
|
2553 |
msgid "New Import"
|
2555 |
|
2556 |
#: src/Tribe/Aggregator/Tabs/History.php:93
|
2557 |
msgid "History"
|
2558 |
+
msgstr "История"
|
2559 |
|
2560 |
#: src/Tribe/Aggregator/Tabs/History.php:55
|
2561 |
#: src/Tribe/Aggregator/Tabs/Scheduled.php:57
|
2562 |
msgid "Records per page"
|
2563 |
+
msgstr "Записей на страницу"
|
2564 |
|
2565 |
#: src/Tribe/Aggregator/Tabs/Favorite.php:37
|
2566 |
msgid "Favorite Imports"
|
2567 |
+
msgstr "Избранные импортирования"
|
2568 |
|
2569 |
#: src/Tribe/Aggregator/Tabs/Edit.php:143
|
2570 |
msgid "Your Scheduled Import has been updated!"
|
2571 |
+
msgstr "Ваше запланированное импортирование обновлено!"
|
2572 |
|
2573 |
#: src/Tribe/Aggregator/Tabs/Edit.php:137
|
2574 |
msgid "View All Scheduled Imports"
|
2575 |
+
msgstr "Просмотреть все запланированные импортирования"
|
2576 |
|
2577 |
#: src/Tribe/Aggregator/Tabs/Edit.php:131
|
2578 |
msgid "Scheduled import was successfully updated."
|
2579 |
+
msgstr "Запланированное импортирование было успешно обновлено."
|
2580 |
|
2581 |
#: src/Tribe/Aggregator/Tabs/Edit.php:52
|
2582 |
msgid "Edit Import"
|
2583 |
+
msgstr "Редактировать импорт"
|
2584 |
|
2585 |
#: src/Tribe/Aggregator/Tabs/Abstract.php:145
|
2586 |
msgid "Please provide a Meetup URL when importing from Meetup."
|
2587 |
+
msgstr "Укажите URL Meetup при импорте из Meetup."
|
2588 |
|
2589 |
#: src/Tribe/Aggregator/Tabs/Abstract.php:140
|
2590 |
msgid "Please provide a Facebook URL when importing from Facebook."
|
2591 |
+
msgstr "Укажите URL Facebook при импорте с Facebook."
|
2592 |
|
2593 |
#: src/Tribe/Aggregator/Tabs/Abstract.php:189
|
2594 |
msgid "Please provide the URL that you wish to import."
|
2595 |
+
msgstr "Укажите URL, который вы хотите импортировать."
|
2596 |
|
2597 |
#: src/Tribe/Aggregator/Tabs/Abstract.php:135
|
2598 |
msgid "Please provide the file that you wish to import."
|
2599 |
+
msgstr "Укажите файл, который вы хотите импортировать."
|
2600 |
|
2601 |
#: src/Tribe/Aggregator/Tabs/Abstract.php:59
|
2602 |
msgid "There was a problem processing your import. Please try again."
|
2603 |
+
msgstr "Во время импортирования произошла ошибка. Попробуйте снова."
|
2604 |
|
2605 |
#: src/Tribe/Aggregator/Service.php:170
|
2606 |
msgid "Connection timed out while transferring the feed. If you are dealing with large feeds you may need to customize the tribe_aggregator_connection_timeout filter."
|
lang/the-events-calendar.pot
CHANGED
@@ -2,14 +2,14 @@
|
|
2 |
# This file is distributed under the same license as the The Events Calendar package.
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
-
"Project-Id-Version: The Events Calendar 4.6.
|
6 |
"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/the-events-"
|
7 |
"calendar\n"
|
8 |
-
"POT-Creation-Date: 2017-11-
|
9 |
"MIME-Version: 1.0\n"
|
10 |
"Content-Type: text/plain; charset=UTF-8\n"
|
11 |
"Content-Transfer-Encoding: 8bit\n"
|
12 |
-
"PO-Revision-Date: 2017-11-
|
13 |
"Last-Translator: \n"
|
14 |
"Language-Team: \n"
|
15 |
|
@@ -33,8 +33,8 @@ msgid "Edit %s"
|
|
33 |
msgstr ""
|
34 |
|
35 |
#: src/Tribe/Admin/Bar/Default_Configurator.php:73
|
36 |
-
#: src/Tribe/Aggregator/Page.php:
|
37 |
-
#: src/admin-views/aggregator/tabs/import-form.php:
|
38 |
msgid "Import"
|
39 |
msgstr ""
|
40 |
|
@@ -78,14 +78,14 @@ msgid "%s Categories"
|
|
78 |
msgstr ""
|
79 |
|
80 |
#: src/Tribe/Admin_List.php:252
|
81 |
-
#: src/admin-views/aggregator/tabs/import-form.php:
|
82 |
-
#: src/admin-views/aggregator/tabs/import-form.php:
|
83 |
msgid "Start Date"
|
84 |
msgstr ""
|
85 |
|
86 |
#: src/Tribe/Admin_List.php:253
|
87 |
-
#: src/admin-views/aggregator/tabs/import-form.php:
|
88 |
-
#: src/admin-views/aggregator/tabs/import-form.php:
|
89 |
msgid "End Date"
|
90 |
msgstr ""
|
91 |
|
@@ -95,7 +95,7 @@ msgid "All %s"
|
|
95 |
msgstr ""
|
96 |
|
97 |
#: src/Tribe/Aggregator/API/Origins.php:31
|
98 |
-
#: src/Tribe/Aggregator/Admin_Bar.php:88 src/Tribe/Aggregator/Service.php:
|
99 |
msgid "CSV File"
|
100 |
msgstr ""
|
101 |
|
@@ -180,7 +180,7 @@ msgid ""
|
|
180 |
"The image associated with your event could not be attached to the event."
|
181 |
msgstr ""
|
182 |
|
183 |
-
#: src/Tribe/Aggregator/Errors.php:46 src/Tribe/Aggregator/Service.php:
|
184 |
msgid ""
|
185 |
"The daily limit of %d import requests to the Event Aggregator service has "
|
186 |
"been reached. Please try again later."
|
@@ -385,80 +385,84 @@ msgid "There was an error fetching the results from your import:"
|
|
385 |
msgstr ""
|
386 |
|
387 |
#: src/Tribe/Aggregator/Page.php:84
|
388 |
-
msgid "
|
389 |
msgstr ""
|
390 |
|
391 |
#: src/Tribe/Aggregator/Page.php:85
|
392 |
-
msgid "Import All"
|
393 |
msgstr ""
|
394 |
|
395 |
#: src/Tribe/Aggregator/Page.php:86
|
396 |
-
msgid "Import
|
397 |
msgstr ""
|
398 |
|
399 |
#: src/Tribe/Aggregator/Page.php:87
|
400 |
-
msgid "
|
401 |
msgstr ""
|
402 |
|
403 |
#: src/Tribe/Aggregator/Page.php:88
|
404 |
-
msgid "Save
|
405 |
msgstr ""
|
406 |
|
407 |
#: src/Tribe/Aggregator/Page.php:89
|
408 |
-
msgid "
|
409 |
msgstr ""
|
410 |
|
411 |
#: src/Tribe/Aggregator/Page.php:90
|
412 |
-
msgid "Your
|
413 |
msgstr ""
|
414 |
|
415 |
#: src/Tribe/Aggregator/Page.php:91
|
|
|
|
|
|
|
|
|
416 |
msgid ""
|
417 |
"Removing this scheduled import will stop automatic imports from the source. "
|
418 |
"No events will be deleted."
|
419 |
msgstr ""
|
420 |
|
421 |
-
#: src/Tribe/Aggregator/Page.php:
|
422 |
#: src/Tribe/Aggregator/Record/List_Table.php:485
|
423 |
msgid "View Filters"
|
424 |
msgstr ""
|
425 |
|
426 |
-
#: src/Tribe/Aggregator/Page.php:
|
427 |
msgid "Hide Filters"
|
428 |
msgstr ""
|
429 |
|
430 |
-
#: src/Tribe/Aggregator/Page.php:
|
431 |
msgid "Please wait while your preview is fetched."
|
432 |
msgstr ""
|
433 |
|
434 |
-
#: src/Tribe/Aggregator/Page.php:
|
435 |
msgid "Please continue to wait while your preview is generated."
|
436 |
msgstr ""
|
437 |
|
438 |
-
#: src/Tribe/Aggregator/Page.php:
|
439 |
msgid ""
|
440 |
"If all goes according to plan, you will have your preview in a few moments."
|
441 |
msgstr ""
|
442 |
|
443 |
-
#: src/Tribe/Aggregator/Page.php:
|
444 |
msgid ""
|
445 |
"Your preview is taking a bit longer than expected, but it <i>is</i> still "
|
446 |
"being generated."
|
447 |
msgstr ""
|
448 |
|
449 |
-
#: src/Tribe/Aggregator/Page.php:
|
450 |
msgid "Events Import"
|
451 |
msgstr ""
|
452 |
|
453 |
-
#: src/Tribe/Aggregator/Page.php:
|
454 |
msgid "Facebook Events"
|
455 |
msgstr ""
|
456 |
|
457 |
-
#: src/Tribe/Aggregator/Page.php:
|
458 |
msgid "iCal Importer"
|
459 |
msgstr ""
|
460 |
|
461 |
-
#: src/Tribe/Aggregator/Page.php:
|
462 |
msgid ""
|
463 |
"It looks like you are using our legacy plugin, %1$s, along with our new "
|
464 |
"Event Aggregator service. Event Aggregator includes all the features of the "
|
@@ -472,7 +476,7 @@ msgid_plural ""
|
|
472 |
msgstr[0] ""
|
473 |
msgstr[1] ""
|
474 |
|
475 |
-
#: src/Tribe/Aggregator/Page.php:
|
476 |
msgid "Manage Active Plugins"
|
477 |
msgstr ""
|
478 |
|
@@ -484,15 +488,15 @@ msgstr ""
|
|
484 |
msgid "Record: "
|
485 |
msgstr ""
|
486 |
|
487 |
-
#: src/Tribe/Aggregator/Record/Abstract.php:
|
488 |
msgid "Deleted Attachment: %d"
|
489 |
msgstr ""
|
490 |
|
491 |
-
#: src/Tribe/Aggregator/Record/Abstract.php:
|
492 |
msgid " (opens in a new window)"
|
493 |
msgstr ""
|
494 |
|
495 |
-
#: src/Tribe/Aggregator/Record/Abstract.php:
|
496 |
msgid ""
|
497 |
"When this import was last scheduled to run, the daily limit for your Event "
|
498 |
"Aggregator license had already been reached."
|
@@ -868,15 +872,19 @@ msgid ""
|
|
868 |
"be understood. Please try again."
|
869 |
msgstr ""
|
870 |
|
871 |
-
#: src/Tribe/Aggregator/Service.php:
|
|
|
|
|
|
|
|
|
872 |
msgid "Sorry, but something went wrong. Please try again."
|
873 |
msgstr ""
|
874 |
|
875 |
-
#: src/Tribe/Aggregator/Service.php:
|
876 |
msgid "Events could not be imported. The import parameters were invalid."
|
877 |
msgstr ""
|
878 |
|
879 |
-
#: src/Tribe/Aggregator/Service.php:
|
880 |
msgid ""
|
881 |
"Events cannot be imported because Facebook has returned an error. This could "
|
882 |
"mean that the event ID does not exist, the event or source is marked as "
|
@@ -886,98 +894,122 @@ msgid ""
|
|
886 |
"knowledgebase</a>."
|
887 |
msgstr ""
|
888 |
|
889 |
-
#: src/Tribe/Aggregator/Service.php:
|
890 |
msgid "No upcoming Facebook events found."
|
891 |
msgstr ""
|
892 |
|
893 |
-
#: src/Tribe/Aggregator/Service.php:
|
894 |
msgid "The URL provided could not be reached."
|
895 |
msgstr ""
|
896 |
|
897 |
-
#: src/Tribe/Aggregator/Service.php:
|
898 |
msgid "The URL provided failed to load."
|
899 |
msgstr ""
|
900 |
|
901 |
-
#: src/Tribe/Aggregator/Service.php:
|
902 |
msgid "The image associated with your event could not be imported."
|
903 |
msgstr ""
|
904 |
|
905 |
-
#: src/Tribe/Aggregator/Service.php:
|
906 |
msgid ""
|
907 |
"The image associated with your event is not accessible with your API key."
|
908 |
msgstr ""
|
909 |
|
910 |
-
#: src/Tribe/Aggregator/Service.php:
|
911 |
msgid ""
|
912 |
"The import failed for an unknown reason. Please try again. If the problem "
|
913 |
"persists, please contact support."
|
914 |
msgstr ""
|
915 |
|
916 |
-
#: src/Tribe/Aggregator/Service.php:
|
917 |
msgid ""
|
918 |
"Events could not be imported. The URL provided did not have events in the "
|
919 |
"proper format."
|
920 |
msgstr ""
|
921 |
|
922 |
-
#: src/Tribe/Aggregator/Service.php:
|
923 |
msgid ""
|
924 |
"The file provided could not be opened. Please confirm that it is a properly "
|
925 |
"formatted .ics file."
|
926 |
msgstr ""
|
927 |
|
928 |
-
#: src/Tribe/Aggregator/Service.php:
|
929 |
msgid "Your Meetup API key is invalid."
|
930 |
msgstr ""
|
931 |
|
932 |
-
#: src/Tribe/Aggregator/Service.php:
|
933 |
msgid ""
|
934 |
"Event Aggregator cannot reach Meetup.com because you exceeded the request "
|
935 |
"limit for your Meetup API key."
|
936 |
msgstr ""
|
937 |
|
938 |
-
#: src/Tribe/Aggregator/Service.php:
|
939 |
msgid "The import is in progress."
|
940 |
msgstr ""
|
941 |
|
942 |
-
#: src/Tribe/Aggregator/Service.php:
|
943 |
msgid "The import will be starting soon."
|
944 |
msgstr ""
|
945 |
|
946 |
-
#: src/Tribe/Aggregator/Service.php:
|
947 |
msgid "Success"
|
948 |
msgstr ""
|
949 |
|
950 |
-
#: src/Tribe/Aggregator/Service.php:
|
951 |
msgid "Import created"
|
952 |
msgstr ""
|
953 |
|
954 |
-
#: src/Tribe/Aggregator/Service.php:
|
955 |
msgid "Successfully fetched Facebook Token"
|
956 |
msgstr ""
|
957 |
|
958 |
-
#: src/Tribe/Aggregator/Service.php:
|
959 |
msgid "Successfully loaded import origins"
|
960 |
msgstr ""
|
961 |
|
962 |
-
#: src/Tribe/Aggregator/Service.php:
|
963 |
msgid "Import is complete"
|
964 |
msgstr ""
|
965 |
|
966 |
-
#: src/Tribe/Aggregator/Service.php:
|
967 |
msgid "Import queued"
|
968 |
msgstr ""
|
969 |
|
970 |
-
#: src/Tribe/Aggregator/Service.php:
|
971 |
msgid "Events could not be imported. The URL provided could not be reached."
|
972 |
msgstr ""
|
973 |
|
974 |
-
#: src/Tribe/Aggregator/Service.php:
|
975 |
msgid ""
|
976 |
"The requested source does not have any upcoming and published events "
|
977 |
"matching the search criteria."
|
978 |
msgstr ""
|
979 |
|
980 |
-
#: src/Tribe/Aggregator/Service.php:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
981 |
msgid "Unknown service message"
|
982 |
msgstr ""
|
983 |
|
@@ -1227,39 +1259,39 @@ msgstr ""
|
|
1227 |
msgid "Unable to save credentials"
|
1228 |
msgstr ""
|
1229 |
|
1230 |
-
#: src/Tribe/Aggregator/Tabs/New.php:
|
1231 |
msgid "Import Using Event Aggregator"
|
1232 |
msgstr ""
|
1233 |
|
1234 |
-
#: src/Tribe/Aggregator/Tabs/New.php:
|
1235 |
msgid ""
|
1236 |
"With Event Aggregator, you can import events from Facebook, iCalendar, "
|
1237 |
"Google, and Meetup.com in a jiffy."
|
1238 |
msgstr ""
|
1239 |
|
1240 |
-
#: src/Tribe/Aggregator/Tabs/New.php:
|
1241 |
msgid "Buy It Now"
|
1242 |
msgstr ""
|
1243 |
|
1244 |
-
#: src/Tribe/Aggregator/Tabs/New.php:
|
1245 |
msgid "opens in a new window"
|
1246 |
msgstr ""
|
1247 |
|
1248 |
-
#: src/Tribe/Aggregator/Tabs/New.php:
|
1249 |
msgid "Learn More"
|
1250 |
msgstr ""
|
1251 |
|
1252 |
-
#: src/Tribe/Aggregator/Tabs/New.php:
|
1253 |
msgid "Your Event Aggregator license is expired."
|
1254 |
msgstr ""
|
1255 |
|
1256 |
-
#: src/Tribe/Aggregator/Tabs/New.php:
|
1257 |
msgid ""
|
1258 |
"Renew your license in order to import events from Facebook, iCalendar, "
|
1259 |
"Google, or Meetup."
|
1260 |
msgstr ""
|
1261 |
|
1262 |
-
#: src/Tribe/Aggregator/Tabs/New.php:
|
1263 |
msgid "Renew your Event Aggregator license"
|
1264 |
msgstr ""
|
1265 |
|
@@ -2280,7 +2312,7 @@ msgstr ""
|
|
2280 |
msgid "Upcoming Events"
|
2281 |
msgstr ""
|
2282 |
|
2283 |
-
#. #-#-#-#-# the-events-calendar.pot (The Events Calendar 4.6.
|
2284 |
#. Plugin Name of the plugin/theme
|
2285 |
#: src/Tribe/Main.php:727 src/Tribe/Main.php:1062
|
2286 |
#: src/functions/template-tags/general.php:1312
|
@@ -2487,8 +2519,8 @@ msgid ""
|
|
2487 |
"respond to your thread within 24-48 hours (during the week)."
|
2488 |
msgstr ""
|
2489 |
|
2490 |
-
#: src/Tribe/Main.php:1132 src/admin-views/aggregator/tabs/import-form.php:
|
2491 |
-
#: src/admin-views/aggregator/tabs/import-form.php:
|
2492 |
#: src/functions/template-tags/general.php:63
|
2493 |
msgid "Event"
|
2494 |
msgstr ""
|
@@ -4569,7 +4601,7 @@ msgstr ""
|
|
4569 |
#: src/admin-views/aggregator/origins/ical.php:111
|
4570 |
#: src/admin-views/aggregator/origins/ics.php:54
|
4571 |
#: src/admin-views/aggregator/origins/url.php:122
|
4572 |
-
#: src/admin-views/aggregator/tabs/import-form.php:
|
4573 |
msgid "Cancel"
|
4574 |
msgstr ""
|
4575 |
|
@@ -5177,42 +5209,42 @@ msgid ""
|
|
5177 |
"When you save this scheduled import, the events above will begin importing."
|
5178 |
msgstr ""
|
5179 |
|
5180 |
-
#: src/admin-views/aggregator/tabs/import-form.php:
|
5181 |
msgid ""
|
5182 |
"This is a preview of the type of content you will be getting in during the "
|
5183 |
"import based on what is on the calendar now."
|
5184 |
msgstr ""
|
5185 |
|
5186 |
-
#: src/admin-views/aggregator/tabs/import-form.php:
|
5187 |
msgid "Column Mapping:"
|
5188 |
msgstr ""
|
5189 |
|
5190 |
-
#: src/admin-views/aggregator/tabs/import-form.php:
|
5191 |
msgid ""
|
5192 |
"The following preview does not necessarily contain all of the data from your "
|
5193 |
"CSV file. The data displayed below is meant as a guide to help you map your "
|
5194 |
"CSV file's columns to the appropriate Event fields."
|
5195 |
msgstr ""
|
5196 |
|
5197 |
-
#: src/admin-views/aggregator/tabs/import-form.php:
|
5198 |
-
#: src/admin-views/aggregator/tabs/import-form.php:
|
5199 |
msgid "Select All"
|
5200 |
msgstr ""
|
5201 |
|
5202 |
-
#: src/admin-views/aggregator/tabs/import-form.php:
|
5203 |
-
#: src/admin-views/aggregator/tabs/import-form.php:
|
5204 |
msgid "Start Time"
|
5205 |
msgstr ""
|
5206 |
|
5207 |
-
#: src/admin-views/aggregator/tabs/import-form.php:
|
5208 |
msgid "Status:"
|
5209 |
msgstr ""
|
5210 |
|
5211 |
-
#: src/admin-views/aggregator/tabs/import-form.php:
|
5212 |
msgid "Category:"
|
5213 |
msgstr ""
|
5214 |
|
5215 |
-
#: src/admin-views/aggregator/tabs/import-form.php:
|
5216 |
msgid ""
|
5217 |
"Events will be imported with the timezone defined by the source. If no "
|
5218 |
"timezone is specified, events will be assigned your site's default timezone "
|
@@ -5222,7 +5254,7 @@ msgstr ""
|
|
5222 |
#: src/admin-views/create-organizer-fields.php:2
|
5223 |
#: src/admin-views/create-venue-fields.php:159
|
5224 |
#: src/admin-views/organizer-meta-box.php:31
|
5225 |
-
#: src/admin-views/venue-meta-box.php:
|
5226 |
#: src/views/modules/meta/organizer.php:43 src/views/modules/meta/venue.php:40
|
5227 |
msgid "Phone:"
|
5228 |
msgstr ""
|
@@ -5230,7 +5262,7 @@ msgstr ""
|
|
5230 |
#: src/admin-views/create-organizer-fields.php:8
|
5231 |
#: src/admin-views/create-venue-fields.php:173
|
5232 |
#: src/admin-views/organizer-meta-box.php:37
|
5233 |
-
#: src/admin-views/venue-meta-box.php:
|
5234 |
#: src/views/modules/meta/details.php:148
|
5235 |
#: src/views/modules/meta/organizer.php:65 src/views/modules/meta/venue.php:45
|
5236 |
msgid "Website:"
|
@@ -5264,7 +5296,7 @@ msgid "Country:"
|
|
5264 |
msgstr ""
|
5265 |
|
5266 |
#: src/admin-views/create-venue-fields.php:125
|
5267 |
-
#: src/admin-views/venue-meta-box.php:
|
5268 |
msgid "State or Province:"
|
5269 |
msgstr ""
|
5270 |
|
@@ -5274,12 +5306,12 @@ msgid "Venue State"
|
|
5274 |
msgstr ""
|
5275 |
|
5276 |
#: src/admin-views/create-venue-fields.php:135
|
5277 |
-
#: src/admin-views/venue-meta-box.php:
|
5278 |
msgid "Select a State:"
|
5279 |
msgstr ""
|
5280 |
|
5281 |
#: src/admin-views/create-venue-fields.php:145
|
5282 |
-
#: src/admin-views/venue-meta-box.php:
|
5283 |
msgid "Postal Code:"
|
5284 |
msgstr ""
|
5285 |
|
@@ -5293,8 +5325,8 @@ msgstr ""
|
|
5293 |
|
5294 |
#: src/admin-views/create-venue-fields.php:209
|
5295 |
#: src/admin-views/create-venue-fields.php:247
|
5296 |
-
#: src/admin-views/venue-meta-box.php:
|
5297 |
-
#: src/admin-views/venue-meta-box.php:
|
5298 |
msgid "Show Google Map:"
|
5299 |
msgstr ""
|
5300 |
|
@@ -5304,8 +5336,8 @@ msgstr ""
|
|
5304 |
|
5305 |
#: src/admin-views/create-venue-fields.php:227
|
5306 |
#: src/admin-views/create-venue-fields.php:264
|
5307 |
-
#: src/admin-views/venue-meta-box.php:
|
5308 |
-
#: src/admin-views/venue-meta-box.php:
|
5309 |
msgid "Show Google Maps Link:"
|
5310 |
msgstr ""
|
5311 |
|
@@ -5875,11 +5907,11 @@ msgid ""
|
|
5875 |
"can be useful when you have events in numerous different timezones."
|
5876 |
msgstr ""
|
5877 |
|
5878 |
-
#: src/admin-views/venue-meta-box.php:
|
5879 |
msgid "%s Name can not be empty"
|
5880 |
msgstr ""
|
5881 |
|
5882 |
-
#: src/admin-views/venue-meta-box.php:
|
5883 |
msgid "%s Name already exists"
|
5884 |
msgstr ""
|
5885 |
|
2 |
# This file is distributed under the same license as the The Events Calendar package.
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
+
"Project-Id-Version: The Events Calendar 4.6.6\n"
|
6 |
"Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/the-events-"
|
7 |
"calendar\n"
|
8 |
+
"POT-Creation-Date: 2017-11-21 16:24:13+00:00\n"
|
9 |
"MIME-Version: 1.0\n"
|
10 |
"Content-Type: text/plain; charset=UTF-8\n"
|
11 |
"Content-Transfer-Encoding: 8bit\n"
|
12 |
+
"PO-Revision-Date: 2017-11-21 16:24\n"
|
13 |
"Last-Translator: \n"
|
14 |
"Language-Team: \n"
|
15 |
|
33 |
msgstr ""
|
34 |
|
35 |
#: src/Tribe/Admin/Bar/Default_Configurator.php:73
|
36 |
+
#: src/Tribe/Aggregator/Page.php:247
|
37 |
+
#: src/admin-views/aggregator/tabs/import-form.php:232
|
38 |
msgid "Import"
|
39 |
msgstr ""
|
40 |
|
78 |
msgstr ""
|
79 |
|
80 |
#: src/Tribe/Admin_List.php:252
|
81 |
+
#: src/admin-views/aggregator/tabs/import-form.php:182
|
82 |
+
#: src/admin-views/aggregator/tabs/import-form.php:194
|
83 |
msgid "Start Date"
|
84 |
msgstr ""
|
85 |
|
86 |
#: src/Tribe/Admin_List.php:253
|
87 |
+
#: src/admin-views/aggregator/tabs/import-form.php:184
|
88 |
+
#: src/admin-views/aggregator/tabs/import-form.php:196
|
89 |
msgid "End Date"
|
90 |
msgstr ""
|
91 |
|
95 |
msgstr ""
|
96 |
|
97 |
#: src/Tribe/Aggregator/API/Origins.php:31
|
98 |
+
#: src/Tribe/Aggregator/Admin_Bar.php:88 src/Tribe/Aggregator/Service.php:626
|
99 |
msgid "CSV File"
|
100 |
msgstr ""
|
101 |
|
180 |
"The image associated with your event could not be attached to the event."
|
181 |
msgstr ""
|
182 |
|
183 |
+
#: src/Tribe/Aggregator/Errors.php:46 src/Tribe/Aggregator/Service.php:547
|
184 |
msgid ""
|
185 |
"The daily limit of %d import requests to the Event Aggregator service has "
|
186 |
"been reached. Please try again later."
|
385 |
msgstr ""
|
386 |
|
387 |
#: src/Tribe/Aggregator/Page.php:84
|
388 |
+
msgid "A warning was generated while fetching the results from your import:"
|
389 |
msgstr ""
|
390 |
|
391 |
#: src/Tribe/Aggregator/Page.php:85
|
392 |
+
msgid "Import All (%d)"
|
393 |
msgstr ""
|
394 |
|
395 |
#: src/Tribe/Aggregator/Page.php:86
|
396 |
+
msgid "Import All"
|
397 |
msgstr ""
|
398 |
|
399 |
#: src/Tribe/Aggregator/Page.php:87
|
400 |
+
msgid "Import Checked (%d)"
|
401 |
msgstr ""
|
402 |
|
403 |
#: src/Tribe/Aggregator/Page.php:88
|
404 |
+
msgid "Save Scheduled Import"
|
405 |
msgstr ""
|
406 |
|
407 |
#: src/Tribe/Aggregator/Page.php:89
|
408 |
+
msgid "Save Changes"
|
409 |
msgstr ""
|
410 |
|
411 |
#: src/Tribe/Aggregator/Page.php:90
|
412 |
+
msgid "Your import must include at least one event"
|
413 |
msgstr ""
|
414 |
|
415 |
#: src/Tribe/Aggregator/Page.php:91
|
416 |
+
msgid "Your preview doesn't have any records to import."
|
417 |
+
msgstr ""
|
418 |
+
|
419 |
+
#: src/Tribe/Aggregator/Page.php:92
|
420 |
msgid ""
|
421 |
"Removing this scheduled import will stop automatic imports from the source. "
|
422 |
"No events will be deleted."
|
423 |
msgstr ""
|
424 |
|
425 |
+
#: src/Tribe/Aggregator/Page.php:93
|
426 |
#: src/Tribe/Aggregator/Record/List_Table.php:485
|
427 |
msgid "View Filters"
|
428 |
msgstr ""
|
429 |
|
430 |
+
#: src/Tribe/Aggregator/Page.php:94
|
431 |
msgid "Hide Filters"
|
432 |
msgstr ""
|
433 |
|
434 |
+
#: src/Tribe/Aggregator/Page.php:96
|
435 |
msgid "Please wait while your preview is fetched."
|
436 |
msgstr ""
|
437 |
|
438 |
+
#: src/Tribe/Aggregator/Page.php:97
|
439 |
msgid "Please continue to wait while your preview is generated."
|
440 |
msgstr ""
|
441 |
|
442 |
+
#: src/Tribe/Aggregator/Page.php:98
|
443 |
msgid ""
|
444 |
"If all goes according to plan, you will have your preview in a few moments."
|
445 |
msgstr ""
|
446 |
|
447 |
+
#: src/Tribe/Aggregator/Page.php:99
|
448 |
msgid ""
|
449 |
"Your preview is taking a bit longer than expected, but it <i>is</i> still "
|
450 |
"being generated."
|
451 |
msgstr ""
|
452 |
|
453 |
+
#: src/Tribe/Aggregator/Page.php:256
|
454 |
msgid "Events Import"
|
455 |
msgstr ""
|
456 |
|
457 |
+
#: src/Tribe/Aggregator/Page.php:380
|
458 |
msgid "Facebook Events"
|
459 |
msgstr ""
|
460 |
|
461 |
+
#: src/Tribe/Aggregator/Page.php:384
|
462 |
msgid "iCal Importer"
|
463 |
msgstr ""
|
464 |
|
465 |
+
#: src/Tribe/Aggregator/Page.php:393
|
466 |
msgid ""
|
467 |
"It looks like you are using our legacy plugin, %1$s, along with our new "
|
468 |
"Event Aggregator service. Event Aggregator includes all the features of the "
|
476 |
msgstr[0] ""
|
477 |
msgstr[1] ""
|
478 |
|
479 |
+
#: src/Tribe/Aggregator/Page.php:406
|
480 |
msgid "Manage Active Plugins"
|
481 |
msgstr ""
|
482 |
|
488 |
msgid "Record: "
|
489 |
msgstr ""
|
490 |
|
491 |
+
#: src/Tribe/Aggregator/Record/Abstract.php:1067
|
492 |
msgid "Deleted Attachment: %d"
|
493 |
msgstr ""
|
494 |
|
495 |
+
#: src/Tribe/Aggregator/Record/Abstract.php:1082
|
496 |
msgid " (opens in a new window)"
|
497 |
msgstr ""
|
498 |
|
499 |
+
#: src/Tribe/Aggregator/Record/Abstract.php:1125
|
500 |
msgid ""
|
501 |
"When this import was last scheduled to run, the daily limit for your Event "
|
502 |
"Aggregator license had already been reached."
|
872 |
"be understood. Please try again."
|
873 |
msgstr ""
|
874 |
|
875 |
+
#: src/Tribe/Aggregator/Service.php:530
|
876 |
+
msgid "the UID part of the iCalendar Specification"
|
877 |
+
msgstr ""
|
878 |
+
|
879 |
+
#: src/Tribe/Aggregator/Service.php:534
|
880 |
msgid "Sorry, but something went wrong. Please try again."
|
881 |
msgstr ""
|
882 |
|
883 |
+
#: src/Tribe/Aggregator/Service.php:535
|
884 |
msgid "Events could not be imported. The import parameters were invalid."
|
885 |
msgstr ""
|
886 |
|
887 |
+
#: src/Tribe/Aggregator/Service.php:536
|
888 |
msgid ""
|
889 |
"Events cannot be imported because Facebook has returned an error. This could "
|
890 |
"mean that the event ID does not exist, the event or source is marked as "
|
894 |
"knowledgebase</a>."
|
895 |
msgstr ""
|
896 |
|
897 |
+
#: src/Tribe/Aggregator/Service.php:537
|
898 |
msgid "No upcoming Facebook events found."
|
899 |
msgstr ""
|
900 |
|
901 |
+
#: src/Tribe/Aggregator/Service.php:538
|
902 |
msgid "The URL provided could not be reached."
|
903 |
msgstr ""
|
904 |
|
905 |
+
#: src/Tribe/Aggregator/Service.php:539
|
906 |
msgid "The URL provided failed to load."
|
907 |
msgstr ""
|
908 |
|
909 |
+
#: src/Tribe/Aggregator/Service.php:540
|
910 |
msgid "The image associated with your event could not be imported."
|
911 |
msgstr ""
|
912 |
|
913 |
+
#: src/Tribe/Aggregator/Service.php:541
|
914 |
msgid ""
|
915 |
"The image associated with your event is not accessible with your API key."
|
916 |
msgstr ""
|
917 |
|
918 |
+
#: src/Tribe/Aggregator/Service.php:542
|
919 |
msgid ""
|
920 |
"The import failed for an unknown reason. Please try again. If the problem "
|
921 |
"persists, please contact support."
|
922 |
msgstr ""
|
923 |
|
924 |
+
#: src/Tribe/Aggregator/Service.php:543
|
925 |
msgid ""
|
926 |
"Events could not be imported. The URL provided did not have events in the "
|
927 |
"proper format."
|
928 |
msgstr ""
|
929 |
|
930 |
+
#: src/Tribe/Aggregator/Service.php:544
|
931 |
msgid ""
|
932 |
"The file provided could not be opened. Please confirm that it is a properly "
|
933 |
"formatted .ics file."
|
934 |
msgstr ""
|
935 |
|
936 |
+
#: src/Tribe/Aggregator/Service.php:545
|
937 |
msgid "Your Meetup API key is invalid."
|
938 |
msgstr ""
|
939 |
|
940 |
+
#: src/Tribe/Aggregator/Service.php:546
|
941 |
msgid ""
|
942 |
"Event Aggregator cannot reach Meetup.com because you exceeded the request "
|
943 |
"limit for your Meetup API key."
|
944 |
msgstr ""
|
945 |
|
946 |
+
#: src/Tribe/Aggregator/Service.php:548
|
947 |
msgid "The import is in progress."
|
948 |
msgstr ""
|
949 |
|
950 |
+
#: src/Tribe/Aggregator/Service.php:549
|
951 |
msgid "The import will be starting soon."
|
952 |
msgstr ""
|
953 |
|
954 |
+
#: src/Tribe/Aggregator/Service.php:550
|
955 |
msgid "Success"
|
956 |
msgstr ""
|
957 |
|
958 |
+
#: src/Tribe/Aggregator/Service.php:551
|
959 |
msgid "Import created"
|
960 |
msgstr ""
|
961 |
|
962 |
+
#: src/Tribe/Aggregator/Service.php:552
|
963 |
msgid "Successfully fetched Facebook Token"
|
964 |
msgstr ""
|
965 |
|
966 |
+
#: src/Tribe/Aggregator/Service.php:553
|
967 |
msgid "Successfully loaded import origins"
|
968 |
msgstr ""
|
969 |
|
970 |
+
#: src/Tribe/Aggregator/Service.php:554
|
971 |
msgid "Import is complete"
|
972 |
msgstr ""
|
973 |
|
974 |
+
#: src/Tribe/Aggregator/Service.php:555
|
975 |
msgid "Import queued"
|
976 |
msgstr ""
|
977 |
|
978 |
+
#: src/Tribe/Aggregator/Service.php:556
|
979 |
msgid "Events could not be imported. The URL provided could not be reached."
|
980 |
msgstr ""
|
981 |
|
982 |
+
#: src/Tribe/Aggregator/Service.php:557
|
983 |
msgid ""
|
984 |
"The requested source does not have any upcoming and published events "
|
985 |
"matching the search criteria."
|
986 |
msgstr ""
|
987 |
|
988 |
+
#: src/Tribe/Aggregator/Service.php:559
|
989 |
+
msgctxt ""
|
990 |
+
"The placeholder is for the localized version of the iCal UID specification "
|
991 |
+
"link"
|
992 |
+
msgid ""
|
993 |
+
"Some events at the requested source are missing the UID attribute required "
|
994 |
+
"by the iCalendar Specification. Creating a scheduled import would generate "
|
995 |
+
"duplicate events on each import. Instead, please use a One-Time import or "
|
996 |
+
"contact the source provider to fix the UID issue; linking them to %s may "
|
997 |
+
"help them more quickly resolve their feed's UID issue."
|
998 |
+
msgstr ""
|
999 |
+
|
1000 |
+
#: src/Tribe/Aggregator/Service.php:567
|
1001 |
+
msgctxt ""
|
1002 |
+
"The placeholder is for the localized version of the iCal UID specification "
|
1003 |
+
"link"
|
1004 |
+
msgid ""
|
1005 |
+
"Some events at the requested source are missing the UID attribute required "
|
1006 |
+
"by the iCalendar Specification. One-Time and ICS File imports are allowed "
|
1007 |
+
"but successive imports will create duplicated events on your site. Please "
|
1008 |
+
"contact the source provider to fix the UID issue; linking them to %s may "
|
1009 |
+
"help them more quickly resolve their feed's UID issue."
|
1010 |
+
msgstr ""
|
1011 |
+
|
1012 |
+
#: src/Tribe/Aggregator/Service.php:589
|
1013 |
msgid "Unknown service message"
|
1014 |
msgstr ""
|
1015 |
|
1259 |
msgid "Unable to save credentials"
|
1260 |
msgstr ""
|
1261 |
|
1262 |
+
#: src/Tribe/Aggregator/Tabs/New.php:529
|
1263 |
msgid "Import Using Event Aggregator"
|
1264 |
msgstr ""
|
1265 |
|
1266 |
+
#: src/Tribe/Aggregator/Tabs/New.php:531
|
1267 |
msgid ""
|
1268 |
"With Event Aggregator, you can import events from Facebook, iCalendar, "
|
1269 |
"Google, and Meetup.com in a jiffy."
|
1270 |
msgstr ""
|
1271 |
|
1272 |
+
#: src/Tribe/Aggregator/Tabs/New.php:534
|
1273 |
msgid "Buy It Now"
|
1274 |
msgstr ""
|
1275 |
|
1276 |
+
#: src/Tribe/Aggregator/Tabs/New.php:536 src/Tribe/Aggregator/Tabs/New.php:543
|
1277 |
msgid "opens in a new window"
|
1278 |
msgstr ""
|
1279 |
|
1280 |
+
#: src/Tribe/Aggregator/Tabs/New.php:541
|
1281 |
msgid "Learn More"
|
1282 |
msgstr ""
|
1283 |
|
1284 |
+
#: src/Tribe/Aggregator/Tabs/New.php:561
|
1285 |
msgid "Your Event Aggregator license is expired."
|
1286 |
msgstr ""
|
1287 |
|
1288 |
+
#: src/Tribe/Aggregator/Tabs/New.php:562
|
1289 |
msgid ""
|
1290 |
"Renew your license in order to import events from Facebook, iCalendar, "
|
1291 |
"Google, or Meetup."
|
1292 |
msgstr ""
|
1293 |
|
1294 |
+
#: src/Tribe/Aggregator/Tabs/New.php:565
|
1295 |
msgid "Renew your Event Aggregator license"
|
1296 |
msgstr ""
|
1297 |
|
2312 |
msgid "Upcoming Events"
|
2313 |
msgstr ""
|
2314 |
|
2315 |
+
#. #-#-#-#-# the-events-calendar.pot (The Events Calendar 4.6.6) #-#-#-#-#
|
2316 |
#. Plugin Name of the plugin/theme
|
2317 |
#: src/Tribe/Main.php:727 src/Tribe/Main.php:1062
|
2318 |
#: src/functions/template-tags/general.php:1312
|
2519 |
"respond to your thread within 24-48 hours (during the week)."
|
2520 |
msgstr ""
|
2521 |
|
2522 |
+
#: src/Tribe/Main.php:1132 src/admin-views/aggregator/tabs/import-form.php:185
|
2523 |
+
#: src/admin-views/aggregator/tabs/import-form.php:197
|
2524 |
#: src/functions/template-tags/general.php:63
|
2525 |
msgid "Event"
|
2526 |
msgstr ""
|
4601 |
#: src/admin-views/aggregator/origins/ical.php:111
|
4602 |
#: src/admin-views/aggregator/origins/ics.php:54
|
4603 |
#: src/admin-views/aggregator/origins/url.php:122
|
4604 |
+
#: src/admin-views/aggregator/tabs/import-form.php:235
|
4605 |
msgid "Cancel"
|
4606 |
msgstr ""
|
4607 |
|
5209 |
"When you save this scheduled import, the events above will begin importing."
|
5210 |
msgstr ""
|
5211 |
|
5212 |
+
#: src/admin-views/aggregator/tabs/import-form.php:160
|
5213 |
msgid ""
|
5214 |
"This is a preview of the type of content you will be getting in during the "
|
5215 |
"import based on what is on the calendar now."
|
5216 |
msgstr ""
|
5217 |
|
5218 |
+
#: src/admin-views/aggregator/tabs/import-form.php:163
|
5219 |
msgid "Column Mapping:"
|
5220 |
msgstr ""
|
5221 |
|
5222 |
+
#: src/admin-views/aggregator/tabs/import-form.php:169
|
5223 |
msgid ""
|
5224 |
"The following preview does not necessarily contain all of the data from your "
|
5225 |
"CSV file. The data displayed below is meant as a guide to help you map your "
|
5226 |
"CSV file's columns to the appropriate Event fields."
|
5227 |
msgstr ""
|
5228 |
|
5229 |
+
#: src/admin-views/aggregator/tabs/import-form.php:179
|
5230 |
+
#: src/admin-views/aggregator/tabs/import-form.php:191
|
5231 |
msgid "Select All"
|
5232 |
msgstr ""
|
5233 |
|
5234 |
+
#: src/admin-views/aggregator/tabs/import-form.php:183
|
5235 |
+
#: src/admin-views/aggregator/tabs/import-form.php:195
|
5236 |
msgid "Start Time"
|
5237 |
msgstr ""
|
5238 |
|
5239 |
+
#: src/admin-views/aggregator/tabs/import-form.php:203
|
5240 |
msgid "Status:"
|
5241 |
msgstr ""
|
5242 |
|
5243 |
+
#: src/admin-views/aggregator/tabs/import-form.php:215
|
5244 |
msgid "Category:"
|
5245 |
msgstr ""
|
5246 |
|
5247 |
+
#: src/admin-views/aggregator/tabs/import-form.php:267
|
5248 |
msgid ""
|
5249 |
"Events will be imported with the timezone defined by the source. If no "
|
5250 |
"timezone is specified, events will be assigned your site's default timezone "
|
5254 |
#: src/admin-views/create-organizer-fields.php:2
|
5255 |
#: src/admin-views/create-venue-fields.php:159
|
5256 |
#: src/admin-views/organizer-meta-box.php:31
|
5257 |
+
#: src/admin-views/venue-meta-box.php:150
|
5258 |
#: src/views/modules/meta/organizer.php:43 src/views/modules/meta/venue.php:40
|
5259 |
msgid "Phone:"
|
5260 |
msgstr ""
|
5262 |
#: src/admin-views/create-organizer-fields.php:8
|
5263 |
#: src/admin-views/create-venue-fields.php:173
|
5264 |
#: src/admin-views/organizer-meta-box.php:37
|
5265 |
+
#: src/admin-views/venue-meta-box.php:163
|
5266 |
#: src/views/modules/meta/details.php:148
|
5267 |
#: src/views/modules/meta/organizer.php:65 src/views/modules/meta/venue.php:45
|
5268 |
msgid "Website:"
|
5296 |
msgstr ""
|
5297 |
|
5298 |
#: src/admin-views/create-venue-fields.php:125
|
5299 |
+
#: src/admin-views/venue-meta-box.php:106
|
5300 |
msgid "State or Province:"
|
5301 |
msgstr ""
|
5302 |
|
5306 |
msgstr ""
|
5307 |
|
5308 |
#: src/admin-views/create-venue-fields.php:135
|
5309 |
+
#: src/admin-views/venue-meta-box.php:123
|
5310 |
msgid "Select a State:"
|
5311 |
msgstr ""
|
5312 |
|
5313 |
#: src/admin-views/create-venue-fields.php:145
|
5314 |
+
#: src/admin-views/venue-meta-box.php:137
|
5315 |
msgid "Postal Code:"
|
5316 |
msgstr ""
|
5317 |
|
5325 |
|
5326 |
#: src/admin-views/create-venue-fields.php:209
|
5327 |
#: src/admin-views/create-venue-fields.php:247
|
5328 |
+
#: src/admin-views/venue-meta-box.php:186
|
5329 |
+
#: src/admin-views/venue-meta-box.php:222
|
5330 |
msgid "Show Google Map:"
|
5331 |
msgstr ""
|
5332 |
|
5336 |
|
5337 |
#: src/admin-views/create-venue-fields.php:227
|
5338 |
#: src/admin-views/create-venue-fields.php:264
|
5339 |
+
#: src/admin-views/venue-meta-box.php:203
|
5340 |
+
#: src/admin-views/venue-meta-box.php:239
|
5341 |
msgid "Show Google Maps Link:"
|
5342 |
msgstr ""
|
5343 |
|
5907 |
"can be useful when you have events in numerous different timezones."
|
5908 |
msgstr ""
|
5909 |
|
5910 |
+
#: src/admin-views/venue-meta-box.php:268
|
5911 |
msgid "%s Name can not be empty"
|
5912 |
msgstr ""
|
5913 |
|
5914 |
+
#: src/admin-views/venue-meta-box.php:273
|
5915 |
msgid "%s Name already exists"
|
5916 |
msgstr ""
|
5917 |
|
readme.txt
CHANGED
@@ -4,7 +4,7 @@ Contributors: ModernTribe, borkweb, aguseo, barry.hughes, bordoni, brianjessee,
|
|
4 |
Tags: events, calendar, event, venue, organizer, dates, date, google maps, conference, workshop, concert, meeting, seminar, summit, class, modern tribe, tribe, widget
|
5 |
Donate link: http://m.tri.be/29
|
6 |
Requires at least: 4.5
|
7 |
-
Stable tag: 4.6.
|
8 |
Tested up to: 4.9
|
9 |
Requires PHP: 5.2.4
|
10 |
License: GPLv2 or later
|
@@ -308,6 +308,14 @@ The plugin is made with love by [Modern Tribe Inc](http://m.tri.be/2s).
|
|
308 |
|
309 |
== Changelog ==
|
310 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
311 |
= [4.6.5] 2017-11-16 =
|
312 |
|
313 |
* Fix - Improved legacy URL redirect logic to prevent unwanted redirects (our thanks to wesleyanhq and Adam Schwartz for highlighting this issue) [86942]
|
4 |
Tags: events, calendar, event, venue, organizer, dates, date, google maps, conference, workshop, concert, meeting, seminar, summit, class, modern tribe, tribe, widget
|
5 |
Donate link: http://m.tri.be/29
|
6 |
Requires at least: 4.5
|
7 |
+
Stable tag: 4.6.6
|
8 |
Tested up to: 4.9
|
9 |
Requires PHP: 5.2.4
|
10 |
License: GPLv2 or later
|
308 |
|
309 |
== Changelog ==
|
310 |
|
311 |
+
= [4.6.6] 2017-11-21 =
|
312 |
+
|
313 |
+
* Feature - Added Template class which adds a few layers of filtering to any template file included
|
314 |
+
* Tweak - Add clear warnings and errors to prevent and limit the import of iCalendar sources missing required fields [93600]
|
315 |
+
* Tweak - Included `tribe_callback_return` for static returns for Hooks
|
316 |
+
* Tweak - Improve Aggregator notices including error data on the responses [87326]
|
317 |
+
* Language - 4 new strings added, 79 updated, 0 fuzzied, and 0 obsoleted
|
318 |
+
|
319 |
= [4.6.5] 2017-11-16 =
|
320 |
|
321 |
* Fix - Improved legacy URL redirect logic to prevent unwanted redirects (our thanks to wesleyanhq and Adam Schwartz for highlighting this issue) [86942]
|
src/Tribe/Aggregator/API/Import.php
CHANGED
@@ -85,7 +85,8 @@ class Tribe__Events__Aggregator__API__Import extends Tribe__Events__Aggregator__
|
|
85 |
// let's try to use the localized version of the message if available
|
86 |
if ( ! empty( $response->message_code ) ) {
|
87 |
$default = ! empty( $response->message ) ? $response->message : $this->service->get_unknown_message();
|
88 |
-
$
|
|
|
89 |
}
|
90 |
|
91 |
if ( 'success_import-complete' !== $response->message_code ) {
|
85 |
// let's try to use the localized version of the message if available
|
86 |
if ( ! empty( $response->message_code ) ) {
|
87 |
$default = ! empty( $response->message ) ? $response->message : $this->service->get_unknown_message();
|
88 |
+
$message_args = is_array( $response->data ) ? $response->data : array();
|
89 |
+
$response->message = $this->service->get_service_message( $response->message_code, $message_args, $default );
|
90 |
}
|
91 |
|
92 |
if ( 'success_import-complete' !== $response->message_code ) {
|
src/Tribe/Aggregator/Admin_Bar.php
CHANGED
@@ -88,7 +88,12 @@ class Tribe__Events__Aggregator__Admin_Bar {
|
|
88 |
'name' => esc_attr__( 'CSV File', 'the-events-calendar' ),
|
89 |
),
|
90 |
);
|
91 |
-
|
|
|
|
|
|
|
|
|
|
|
92 |
|
93 |
foreach ( $origins as $origin ) {
|
94 |
$url = Tribe__Events__Aggregator__Page::instance()->get_url( array( 'ea-origin' => $origin->id ) );
|
88 |
'name' => esc_attr__( 'CSV File', 'the-events-calendar' ),
|
89 |
),
|
90 |
);
|
91 |
+
|
92 |
+
if ( empty( $service_response[0]->origin ) ) {
|
93 |
+
return;
|
94 |
+
}
|
95 |
+
|
96 |
+
$origins = array_merge( $origins, $service_response[0]->origin );
|
97 |
|
98 |
foreach ( $origins as $origin ) {
|
99 |
$url = Tribe__Events__Aggregator__Page::instance()->get_url( array( 'ea-origin' => $origin->id ) );
|
src/Tribe/Aggregator/Page.php
CHANGED
@@ -81,6 +81,7 @@ class Tribe__Events__Aggregator__Page {
|
|
81 |
'pm' => _x( 'PM', 'Meridian: pm', 'the-events-calendar' ),
|
82 |
'preview_timeout' => __( 'The preview is taking longer than expected. Please try again in a moment.', 'the-events-calendar' ),
|
83 |
'preview_fetch_error_prefix' => __( 'There was an error fetching the results from your import:', 'the-events-calendar' ),
|
|
|
84 |
'import_all' => __( 'Import All (%d)', 'the-events-calendar' ),
|
85 |
'import_all_no_number' => __( 'Import All', 'the-events-calendar' ),
|
86 |
'import_checked' => __( 'Import Checked (%d)', 'the-events-calendar' ),
|
81 |
'pm' => _x( 'PM', 'Meridian: pm', 'the-events-calendar' ),
|
82 |
'preview_timeout' => __( 'The preview is taking longer than expected. Please try again in a moment.', 'the-events-calendar' ),
|
83 |
'preview_fetch_error_prefix' => __( 'There was an error fetching the results from your import:', 'the-events-calendar' ),
|
84 |
+
'preview_fetch_warning_prefix' => __( 'A warning was generated while fetching the results from your import:', 'the-events-calendar' ),
|
85 |
'import_all' => __( 'Import All (%d)', 'the-events-calendar' ),
|
86 |
'import_all_no_number' => __( 'Import All', 'the-events-calendar' ),
|
87 |
'import_checked' => __( 'Import Checked (%d)', 'the-events-calendar' ),
|
src/Tribe/Aggregator/Record/Abstract.php
CHANGED
@@ -566,6 +566,7 @@ abstract class Tribe__Events__Aggregator__Record__Abstract {
|
|
566 |
'post_date' => current_time( 'mysql' ),
|
567 |
'post_status' => Tribe__Events__Aggregator__Records::$status->draft,
|
568 |
'post_parent' => $this->id,
|
|
|
569 |
'meta_input' => array(),
|
570 |
);
|
571 |
|
@@ -730,13 +731,17 @@ abstract class Tribe__Events__Aggregator__Record__Abstract {
|
|
730 |
'success:create-import' != $response->message_code
|
731 |
&& 'queued' != $response->message_code
|
732 |
) {
|
|
|
|
|
733 |
$error = new WP_Error(
|
734 |
$response->message_code,
|
735 |
Tribe__Events__Aggregator__Errors::build(
|
736 |
esc_html__( $response->message, 'the-events-calendar' ),
|
737 |
-
|
738 |
-
)
|
|
|
739 |
);
|
|
|
740 |
return $this->set_status_as_failed( $error );
|
741 |
}
|
742 |
|
566 |
'post_date' => current_time( 'mysql' ),
|
567 |
'post_status' => Tribe__Events__Aggregator__Records::$status->draft,
|
568 |
'post_parent' => $this->id,
|
569 |
+
'post_author' => $this->post->post_author,
|
570 |
'meta_input' => array(),
|
571 |
);
|
572 |
|
731 |
'success:create-import' != $response->message_code
|
732 |
&& 'queued' != $response->message_code
|
733 |
) {
|
734 |
+
$data = ! empty( $response->data ) ? $response->data : array();
|
735 |
+
|
736 |
$error = new WP_Error(
|
737 |
$response->message_code,
|
738 |
Tribe__Events__Aggregator__Errors::build(
|
739 |
esc_html__( $response->message, 'the-events-calendar' ),
|
740 |
+
$data
|
741 |
+
),
|
742 |
+
$data
|
743 |
);
|
744 |
+
|
745 |
return $this->set_status_as_failed( $error );
|
746 |
}
|
747 |
|
src/Tribe/Aggregator/Service.php
CHANGED
@@ -525,6 +525,11 @@ class Tribe__Events__Aggregator__Service {
|
|
525 |
* here so that they can be translated.
|
526 |
*/
|
527 |
protected function register_messages() {
|
|
|
|
|
|
|
|
|
|
|
528 |
$this->service_messages = array(
|
529 |
'error:create-import-failed' => __( 'Sorry, but something went wrong. Please try again.', 'the-events-calendar' ),
|
530 |
'error:create-import-invalid-params' => __( 'Events could not be imported. The import parameters were invalid.', 'the-events-calendar' ),
|
@@ -550,6 +555,21 @@ class Tribe__Events__Aggregator__Service {
|
|
550 |
'success:queued' => __( 'Import queued', 'the-events-calendar' ),
|
551 |
'error:invalid-other-url' => __( 'Events could not be imported. The URL provided could not be reached.', 'the-events-calendar' ),
|
552 |
'error:no-results' => __( 'The requested source does not have any upcoming and published events matching the search criteria.', 'the-events-calendar' ),
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
553 |
);
|
554 |
|
555 |
/**
|
525 |
* here so that they can be translated.
|
526 |
*/
|
527 |
protected function register_messages() {
|
528 |
+
$ical_uid_specification_link = sprintf(
|
529 |
+
'<a target="_blank" href="https://tools.ietf.org/html/rfc5545#section-3.8.4.7">%s</a>',
|
530 |
+
esc_html__( 'the UID part of the iCalendar Specification', 'the-events-calendar' )
|
531 |
+
);
|
532 |
+
|
533 |
$this->service_messages = array(
|
534 |
'error:create-import-failed' => __( 'Sorry, but something went wrong. Please try again.', 'the-events-calendar' ),
|
535 |
'error:create-import-invalid-params' => __( 'Events could not be imported. The import parameters were invalid.', 'the-events-calendar' ),
|
555 |
'success:queued' => __( 'Import queued', 'the-events-calendar' ),
|
556 |
'error:invalid-other-url' => __( 'Events could not be imported. The URL provided could not be reached.', 'the-events-calendar' ),
|
557 |
'error:no-results' => __( 'The requested source does not have any upcoming and published events matching the search criteria.', 'the-events-calendar' ),
|
558 |
+
'error:ical-missing-uids-schedule' => sprintf(
|
559 |
+
_x(
|
560 |
+
'Some events at the requested source are missing the UID attribute required by the iCalendar Specification. Creating a scheduled import would generate duplicate events on each import. Instead, please use a One-Time import or contact the source provider to fix the UID issue; linking them to %s may help them more quickly resolve their feed\'s UID issue.',
|
561 |
+
'The placeholder is for the localized version of the iCal UID specification link',
|
562 |
+
'the-events-calendar'
|
563 |
+
),
|
564 |
+
$ical_uid_specification_link
|
565 |
+
),
|
566 |
+
'warning:ical-missing-uids-manual' => sprintf(
|
567 |
+
_x(
|
568 |
+
'Some events at the requested source are missing the UID attribute required by the iCalendar Specification. One-Time and ICS File imports are allowed but successive imports will create duplicated events on your site. Please contact the source provider to fix the UID issue; linking them to %s may help them more quickly resolve their feed\'s UID issue.',
|
569 |
+
'The placeholder is for the localized version of the iCal UID specification link',
|
570 |
+
'the-events-calendar' ),
|
571 |
+
$ical_uid_specification_link
|
572 |
+
),
|
573 |
);
|
574 |
|
575 |
/**
|
src/Tribe/Aggregator/Tabs/New.php
CHANGED
@@ -450,10 +450,10 @@ class Tribe__Events__Aggregator__Tabs__New extends Tribe__Events__Aggregator__Ta
|
|
450 |
|
451 |
if ( is_wp_error( $result ) ) {
|
452 |
/** @var Tribe__Events__Aggregator__Service $service */
|
453 |
-
$service
|
454 |
-
$result
|
455 |
'message_code' => $result->get_error_code(),
|
456 |
-
'message' => $service->get_service_message( $result->get_error_code() ),
|
457 |
);
|
458 |
wp_send_json_error( $result );
|
459 |
}
|
@@ -493,6 +493,14 @@ class Tribe__Events__Aggregator__Tabs__New extends Tribe__Events__Aggregator__Ta
|
|
493 |
}
|
494 |
}
|
495 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
496 |
wp_send_json_success( $result );
|
497 |
}
|
498 |
|
450 |
|
451 |
if ( is_wp_error( $result ) ) {
|
452 |
/** @var Tribe__Events__Aggregator__Service $service */
|
453 |
+
$service = tribe( 'events-aggregator.service' );
|
454 |
+
$result = (object) array(
|
455 |
'message_code' => $result->get_error_code(),
|
456 |
+
'message' => $service->get_service_message( $result->get_error_code(), $result->get_error_data() ),
|
457 |
);
|
458 |
wp_send_json_error( $result );
|
459 |
}
|
493 |
}
|
494 |
}
|
495 |
|
496 |
+
// if there is a warning in the data let's localize it
|
497 |
+
if ( ! empty( $result->warning_code ) ) {
|
498 |
+
/** @var Tribe__Events__Aggregator__Service $service */
|
499 |
+
$service = tribe( 'events-aggregator.service' );
|
500 |
+
$default_warning = ! empty( $result->warning ) ? $result->warning : null;
|
501 |
+
$result->warning = $service->get_service_message( $result->warning_code, array(), $default_warning );
|
502 |
+
}
|
503 |
+
|
504 |
wp_send_json_success( $result );
|
505 |
}
|
506 |
|
src/Tribe/Main.php
CHANGED
@@ -32,9 +32,9 @@ if ( ! class_exists( 'Tribe__Events__Main' ) ) {
|
|
32 |
const VENUE_POST_TYPE = 'tribe_venue';
|
33 |
const ORGANIZER_POST_TYPE = 'tribe_organizer';
|
34 |
|
35 |
-
const VERSION = '4.6.
|
36 |
const MIN_ADDON_VERSION = '4.4';
|
37 |
-
const MIN_COMMON_VERSION = '4.7';
|
38 |
|
39 |
const WP_PLUGIN_URL = 'https://wordpress.org/extend/plugins/the-events-calendar/';
|
40 |
|
32 |
const VENUE_POST_TYPE = 'tribe_venue';
|
33 |
const ORGANIZER_POST_TYPE = 'tribe_organizer';
|
34 |
|
35 |
+
const VERSION = '4.6.6';
|
36 |
const MIN_ADDON_VERSION = '4.4';
|
37 |
+
const MIN_COMMON_VERSION = '4.7.2';
|
38 |
|
39 |
const WP_PLUGIN_URL = 'https://wordpress.org/extend/plugins/the-events-calendar/';
|
40 |
|
src/admin-views/aggregator/tabs/import-form.php
CHANGED
@@ -149,6 +149,7 @@ $csv_help = esc_html__( 'Select the Event Field that best matches your CSV file
|
|
149 |
$scheduled_save_help = esc_html__( 'When you save this scheduled import, the events above will begin importing.', 'the-events-calendar' );
|
150 |
?>
|
151 |
<div class="tribe-ea-table-container tribe-preview-container">
|
|
|
152 |
<div class="tribe-fetch-error-message"></div>
|
153 |
<div class="spinner-container">
|
154 |
<span class="spinner tribe-ea-active"></span>
|
149 |
$scheduled_save_help = esc_html__( 'When you save this scheduled import, the events above will begin importing.', 'the-events-calendar' );
|
150 |
?>
|
151 |
<div class="tribe-ea-table-container tribe-preview-container">
|
152 |
+
<div class="tribe-fetch-warning-message"></div>
|
153 |
<div class="tribe-fetch-error-message"></div>
|
154 |
<div class="spinner-container">
|
155 |
<span class="spinner tribe-ea-active"></span>
|
src/resources/js/aggregator-fields.js
CHANGED
@@ -154,6 +154,9 @@ tribe_aggregator.fields = {
|
|
154 |
obj.preview_import = function() {
|
155 |
obj.reset_polling_counter();
|
156 |
|
|
|
|
|
|
|
157 |
// when generating data for previews, temporarily remove the post ID and import ID values from their fields
|
158 |
var $post_id = $( '#tribe-post_id' );
|
159 |
$post_id.data( 'value', $post_id.val() );
|
@@ -297,20 +300,31 @@ tribe_aggregator.fields = {
|
|
297 |
} );
|
298 |
|
299 |
jqxhr.done( function( response ) {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
300 |
if ( ! response.success ) {
|
301 |
-
var
|
302 |
|
303 |
if ( 'undefined' !== typeof response.data.message ) {
|
304 |
-
|
305 |
} else if ( 'undefined' !== typeof response.data[0].message ) {
|
306 |
-
|
307 |
}
|
308 |
|
309 |
obj.display_fetch_error( [
|
310 |
'<b>',
|
311 |
ea.l10n.preview_fetch_error_prefix,
|
312 |
'</b>',
|
313 |
-
' ' +
|
314 |
].join( ' ' ) );
|
315 |
return;
|
316 |
}
|
@@ -552,7 +566,20 @@ tribe_aggregator.fields = {
|
|
552 |
};
|
553 |
|
554 |
/**
|
555 |
-
*
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
556 |
*/
|
557 |
obj.display_error = function( $container, message ) {
|
558 |
$container.prepend(
|
@@ -566,6 +593,21 @@ tribe_aggregator.fields = {
|
|
566 |
);
|
567 |
};
|
568 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
569 |
/**
|
570 |
* displays a success message to a container on the page
|
571 |
*/
|
154 |
obj.preview_import = function() {
|
155 |
obj.reset_polling_counter();
|
156 |
|
157 |
+
// clear the warning area
|
158 |
+
var $message_container = $( '.tribe-fetch-warning-message' ).html( '' );
|
159 |
+
|
160 |
// when generating data for previews, temporarily remove the post ID and import ID values from their fields
|
161 |
var $post_id = $( '#tribe-post_id' );
|
162 |
$post_id.data( 'value', $post_id.val() );
|
300 |
} );
|
301 |
|
302 |
jqxhr.done( function( response ) {
|
303 |
+
if ( 'undefined' !== typeof response.data.warning && response.data.warning ) {
|
304 |
+
var warning_message = response.data.warning;
|
305 |
+
|
306 |
+
obj.display_fetch_warning( [
|
307 |
+
'<b>',
|
308 |
+
ea.l10n.preview_fetch_warning_prefix,
|
309 |
+
'</b>',
|
310 |
+
' ' + warning_message
|
311 |
+
].join( ' ' ) );
|
312 |
+
}
|
313 |
+
|
314 |
if ( ! response.success ) {
|
315 |
+
var error_message;
|
316 |
|
317 |
if ( 'undefined' !== typeof response.data.message ) {
|
318 |
+
error_message = response.data.message;
|
319 |
} else if ( 'undefined' !== typeof response.data[0].message ) {
|
320 |
+
error_message = response.data[0].message;
|
321 |
}
|
322 |
|
323 |
obj.display_fetch_error( [
|
324 |
'<b>',
|
325 |
ea.l10n.preview_fetch_error_prefix,
|
326 |
'</b>',
|
327 |
+
' ' + error_message
|
328 |
].join( ' ' ) );
|
329 |
return;
|
330 |
}
|
566 |
};
|
567 |
|
568 |
/**
|
569 |
+
* Displays a fetch warning
|
570 |
+
*/
|
571 |
+
obj.display_fetch_warning = function( message ) {
|
572 |
+
var $message_container = $( '.tribe-fetch-warning-message' );
|
573 |
+
obj.$.preview_container.removeClass( 'tribe-fetching' ).addClass( 'tribe-fetch-warning' );
|
574 |
+
|
575 |
+
// clear out the error message area
|
576 |
+
$message_container.html('');
|
577 |
+
|
578 |
+
obj.display_warning( $message_container, message );
|
579 |
+
};
|
580 |
+
|
581 |
+
/**
|
582 |
+
* Displays an error to a container on the page
|
583 |
*/
|
584 |
obj.display_error = function( $container, message ) {
|
585 |
$container.prepend(
|
593 |
);
|
594 |
};
|
595 |
|
596 |
+
/**
|
597 |
+
* Displays a warning to a container on the page
|
598 |
+
*/
|
599 |
+
obj.display_warning = function( $container, message ) {
|
600 |
+
$container.prepend(
|
601 |
+
[
|
602 |
+
'<div class="notice notice-warning">',
|
603 |
+
'<p>',
|
604 |
+
message,
|
605 |
+
'</p>',
|
606 |
+
'</div>'
|
607 |
+
].join( '' )
|
608 |
+
);
|
609 |
+
};
|
610 |
+
|
611 |
/**
|
612 |
* displays a success message to a container on the page
|
613 |
*/
|
src/resources/js/aggregator-fields.min.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
var tribe_aggregator=tribe_aggregator||{};tribe_aggregator.fields={selector:{container:".tribe-ea",form:".tribe-ea-form",help:".tribe-ea-help",fields:".tribe-ea-field",dropdown:".tribe-ea-dropdown",origin_field:"#tribe-ea-field-origin",import_type_field:".tribe-import-type",media_button:".tribe-ea-media_button",datepicker:".tribe-datepicker",save_credentials_button:".enter-credentials .tribe-save",preview_container:".tribe-preview-container",preview_button:".tribe-preview:visible",refine_filters:".tribe-refine-filters",clear_filters_button:".tribe-clear-filters",finalize_button:".tribe-finalize",cancel_button:".tribe-cancel",schedule_delete_link:".tribe-ea-tab-scheduled a.submitdelete",tab_new:".tribe-ea-tab-new",action:"#tribe-action",view_filters:".tribe-view-filters"},media:{},$:{},construct:{},events:{},import_id:null,result_fetch_count:0,max_result_fetch_count:15,polling_frequency_index:0,polling_frequencies:[500,1e3,5e3,2e4],progress:{}},function(e,t,r,a){"use strict";r.init=function(){r.$.container=e(r.selector.container),r.$.form=e(r.selector.form),r.$.action=e(r.selector.action),r.$.fields=r.$.container.find(r.selector.fields),r.$.preview_container=e(r.selector.preview_container),e.each(r.construct,function(e,t){t(r.$.fields)});var t=e(document.getElementById("eventDetails"));t.data("datepicker_format")&&(tribe_ev.state.datepicker_format=t.data("datepicker_format")),e(document).on("keypress",r.selector.fields,r.events.trigger_field_change).on("click",r.selector.save_credentials_button,r.events.trigger_save_credentials).on("click",r.selector.clear_filters_button,r.clear_filters).on("click",r.selector.finalize_button,r.finalize_manual_import).on("click",r.selector.preview_button,r.preview_import).on("click",r.selector.cancel_button,r.events.cancel_edit).on("click",r.selector.schedule_delete_link,r.events.verify_schedule_delete).on("click",r.selector.view_filters,r.events.toggle_view_filters).on("blur",r.selector.datepicker,r.date_helper).on("submit",r.selector.tab_new,r.events.suppress_submission).on("change",r.selector.import_type_field,function(){r.reset_preview();var t=e(this),a=e(this).next(r.selector.fields);a.select2("val","schedule"===t.val()?"daily":"").change(),r.$.form.attr("data-type",t.val())}).on("change",r.selector.origin_field,function(){r.$.form.attr("data-origin",e(this).val()),r.reset_preview(),e(".tribe-bumpdown-active").removeClass("tribe-bumpdown-active"),e(".tribe-bumpdown:visible").hide(),e('.tribe-ea-tab-new .tribe-ea-dropdown:not([id$="tribe-ea-field-origin"])').select2("val","").change(),e(".tribe-ea-tab-new .tribe-ea-form input").val(function(){return this.defaultValue}).change(),"redirect"===e(this).val()&&(window.open("https://theeventscalendar.com/wordpress-event-aggregator/?utm_source=importoptions&utm_medium=plugin-tec&utm_campaign=in-app","_blank"),location.reload())}),e(".tribe-dependency").change(),tribe_timepickers.setup_timepickers(e(tribe_timepickers.selector.timepicker)),"edit"===r.$.action.val()&&(r.$.form.addClass("edit-form"),e(r.selector.finalize_button).html(a.l10n.edit_save)),"object"==typeof tribe_aggregator_save&&r.progress.init()},r.preview_import=function(){r.reset_polling_counter();var t=e("#tribe-post_id");t.data("value",t.val()),t.val("");var a=e("#tribe-import_id");a.data("value",a.val()),a.val("");var i=e(r.selector.preview_button),n=i.closest("form"),s=n.serialize();t.val(t.data("value")),a.val(t.data("value")),r.$.preview_container.addClass("tribe-fetching").removeClass("tribe-fetch-error"),r.$.form.removeClass("show-data"),i.prop("disabled",!0);var o=e(".dataTable").data("table");"undefined"!=typeof o&&o.clear().draw(),"edit"===r.$.action.val()?r.preview_save_import(s):r.create_import(s)},r.reset_polling_counter=function(){r.polling_frequency_index=0,r.result_fetch_count=0},r.reset_form=function(){r.$.fields.val("").trigger("change"),e(".tribe-ea-dropdown").select2("data",null),e('[id$="import_frequency"]').val("daily").trigger("change"),r.$.form.removeClass("show-data")},r.reset_preview=function(){r.$.form.removeClass("show-data"),e(".tribe-fetched, .tribe-fetching, .tribe-fetch-error").removeClass("tribe-fetched tribe-fetching tribe-fetch-error")},r.clear_filters=function(){e(r.selector.refine_filters).find("input, select").val("").trigger("change")},r.preview_save_import=function(t){var a=e.ajax({type:"POST",url:ajaxurl+"?action=tribe_aggregator_preview_import",data:t,dataType:"json"});a.done(r.handle_preview_create_results)},r.create_import=function(t){var a=e.ajax({type:"POST",url:ajaxurl+"?action=tribe_aggregator_create_import",data:t,dataType:"json"});a.done(r.handle_preview_create_results)},r.handle_preview_create_results=function(t){return t.success?(r.import_id=t.data.data.import_id,e("#tribe-import_id").val(r.import_id),"undefined"!=typeof t.data.data.items?(r.init_datatable(t.data.data),void r.$.preview_container.removeClass("tribe-fetching").addClass("tribe-fetched")):(r.$.container.find(".spinner-message").html(a.l10n.preview_polling[0]),void setTimeout(r.poll_for_results,r.polling_frequencies[r.polling_frequency_index]))):void r.display_fetch_error(["<b>",a.l10n.preview_fetch_error_prefix,"</b>"," "+t.data.message].join(" "))},r.poll_for_results=function(){r.result_fetch_count++;var t=e.ajax({type:"GET",url:ajaxurl+"?action=tribe_aggregator_fetch_import&import_id="+r.import_id,dataType:"json"});t.done(function(t){if(!t.success){var i;return"undefined"!=typeof t.data.message?i=t.data.message:"undefined"!=typeof t.data[0].message&&(i=t.data[0].message),void r.display_fetch_error(["<b>",a.l10n.preview_fetch_error_prefix,"</b>"," "+i].join(" "))}"error"===t.data.status?r.display_fetch_error(t.data.message):"success"!==t.data.status?(r.result_fetch_count>r.max_result_fetch_count&&(r.polling_frequency_index++,r.$.container.find(".spinner-message").html(a.l10n.preview_polling[r.polling_frequency_index]),r.result_fetch_count=0),"undefined"==typeof r.polling_frequencies[r.polling_frequency_index]?r.display_fetch_error(a.l10n.preview_timeout):setTimeout(r.poll_for_results,r.polling_frequencies[r.polling_frequency_index])):(t.data.data.items=t.data.data.events,r.init_datatable(t.data.data),r.$.preview_container.removeClass("tribe-fetching").addClass("tribe-fetched"),e(r.selector.preview_button).prop("disabled",!1))})},r.init_datatable=function(t){var i=!1,n=e(r.selector.origin_field).val(),s="csv"===n,o=e('[id$="import_type"]:visible'),l="manual";if("undefined"!=typeof a.default_settings[n])for(var c in a.default_settings[n])if(a.default_settings[n].hasOwnProperty(c)){var d=e("#tribe-ea-field-"+c);d.val(a.default_settings[n][c]).select2("val",a.default_settings[n][c]).trigger("change")}if(o.length&&(l=e("#"+o.first().attr("id").replace("s2id_","")).val()),"manual"===l&&!t.items.length){var n=t.origin,p="undefined"!=typeof a.l10n[n]&&"undefined"!=typeof a.l10n[n].no_results,u=p?a.l10n[n].no_results:a.l10n.no_results;return void r.display_fetch_error(u)}o.length&&"manual"!==l||(i=!0);var _=r.$.preview_container.find(".data-container table"),f=[];for(var g in t.items){var m=t.items[g];m.checkbox=i?'<input type="checkbox">':"",m.all_day?m.start_time=a.l10n.all_day:("undefined"!=typeof m.start_meridian&&m.start_meridian||(parseInt(m.start_hour,10)>11?m.start_meridian=a.l10n.pm:m.start_meridian=a.l10n.am),m.start_hour>12&&(m.start_hour=m.start_hour-12),m.start_time=(0===parseInt(m.start_hour,10)?12:m.start_hour)+":"+("00"+m.start_minute).slice(-2),m.start_time+=" "+m.start_meridian),f.push(m)}i&&!s?_.addClass("display-checkboxes"):_.removeClass("display-checkboxes"),r.$.form.addClass("show-data");var v={lengthMenu:[[5,10,25,50,-1],[5,10,25,50,tribe_l10n_datatables.pagination.all]],order:[[1,"asc"]],columnDefs:[{cellType:"th",className:"check-column",orderable:!1,targets:0}],data:f};if("undefined"!=typeof t.columns){v.columns=[{data:"checkbox"}];var h=_.find("thead tr"),b=_.find("tfoot tr"),w=e({}),y="",x="";if(h.find("th:first").nextAll().remove(),b.find("th:first").nextAll().remove(),s){var $=_.closest(".data-container");_.closest(".data-container").addClass("csv-data"),$.find(".tribe-preview-message .tribe-csv-filename").html(e("#tribe-ea-field-csv_file_name").text()),h.closest("thead").prepend('<tr class="tribe-column-map"><th scope="row" class="check-column column-cb"></th></tr>'),w=e(".tribe-column-map"),x=e("#tribe-ea-field-csv_content_type").val(),x=x.replace("tribe_","");var k=e("#tribe-csv-column-map-"+x);y=k.html()}var C=0;for(g in t.columns){if(v.columns.push({data:t.columns[g]}),h.append('<th scope="col">'+t.columns[g]+"</th>"),b.append('<th scope="col">'+t.columns[g]+"</th>"),s){var S=t.columns[g].toLowerCase().replace(" ","_").replace(/[^a-z0-9_]/,"");w.append('<th scope="col">'+y.replace('name="column_map[]"','name="aggregator[column_map]['+C+']" id="column-'+C+'"')+"</th>");var j=w.find("#column-"+C);"undefined"!=typeof a.csv_column_mapping[x][C]&&(S=a.csv_column_mapping[x][C]),j.find('option[value="'+S+'"]').prop("selected",!0)}C++}v.scrollX=!0}else v.columns=[{data:"checkbox"},{data:"start_date"},{data:"start_time"},{data:"end_date"},{data:"title"}],v.autoWidth=!1;_.tribeDataTable(v),r.wrap_cell_content(),_.on("select.dt",r.events.twiddle_finalize_button_text).on("deselect.dt",r.events.twiddle_finalize_button_text).on("draw.dt",r.wrap_cell_content);var T;"new"===r.$.action.val()&&(T="manual"===l&&s?a.l10n.import_all_no_number:"manual"===l?a.l10n.import_all.replace("%d",f.length):a.l10n.create_schedule),e(r.selector.finalize_button).html(T)},r.wrap_cell_content=function(){e(".dataTable").find("tbody td").each(function(){var t=e(this);t.html('<div class="tribe-td-height-limit">'+t.html()+"</div>")})},r.display_fetch_error=function(t){var a=e(".tribe-fetch-error-message");r.$.preview_container.removeClass("tribe-fetching").addClass("tribe-fetch-error"),a.html(""),r.display_error(a,t),e(r.selector.preview_button).prop("disabled",!1)},r.display_error=function(e,t){e.prepend(['<div class="notice notice-error">',"<p>",t,"</p>","</div>"].join(""))},r.display_success=function(e,t){e.prepend(['<div class="notice notice-success">',"<p>",t,"</p>","</div>"].join(""))},r.save_credentials=function(t){var r=t.find(".tribe-fieldset").find("input").serialize(),a=ajaxurl+"?action=tribe_aggregator_save_credentials",i=e.post(a,r);i.done(function(e){e.success&&(t.addClass("credentials-entered"),t.find('[name="has-credentials"]').val(1).change())})},r.finalize_manual_import=function(){var t=e("#tribe-ea-field-origin").val(),i=e(".dataTable"),n=window.tribe_data_table;if("eventbrite"===t)return void r.$.form.submit();if(i.hasClass("display-checkboxes")){var s=n.rows({selected:!0});if(s[0].length||(s=n.rows()),!s[0].length)return void r.display_error(e(".tribe-finalize-container"),a.l10n.events_required_for_manual_submit);var o=s.data(),l=[],c=null;if("facebook"===t?c="facebook_id":"meetup"===t?c="meetup_id":"ical"===t||"ics"===t||"gcal"===t?c="uid":"url"===t&&(c="id"),null!==c){for(var d in o)isNaN(d)||"undefined"!=typeof o[d][c]&&l.push(o[d][c]);e("#tribe-selected-rows").text(JSON.stringify(l))}else e("#tribe-selected-rows").text("all")}else e("#tribe-selected-rows").text("all");e(".dataTables_scrollBody").find('[name^="aggregator[column_map]"]').remove(),r.$.form.submit()},r.search_id=function(e){var t=null;return"undefined"!=typeof e.id?t=e.id:"undefined"!=typeof e.ID?t=e.ID:"undefined"!=typeof e.value&&(t=e.value),void 0==e?null:t},r.construct.dropdown=function(a){var i=a.filter(r.selector.dropdown).not(".select2-offscreen, .select2-container");return i.each(function(){var a=e(this),i={};if(a.is("select")||(i.id=r.search_id),i.allowClear=!0,a.is("[data-prevent-clear]")&&(i.allowClear=!1),a.is("[data-options]")&&(i.data=a.data("options")),a.is("[data-hide-search]")&&(i.minimumResultsForSearch=1/0),i.upsellFormatter=function(t){var r=e(t.element);return"string"==typeof r.data("subtitle")&&(t.text=t.text+'<br><span class="tribe-dropdown-subtitle">'+r.data("subtitle")+"</span>"),t.text},"tribe-ea-field-origin"===a.attr("id")&&(i.formatResult=i.upsellFormatter,i.formatSelection=i.upsellFormatter,i.escapeMarkup=function(e){return e}),a.is("[multiple]")&&(i.multiple=!0,t.isArray(a.data("separator"))?i.tokenSeparators=a.data("separator"):i.tokenSeparators=[a.data("separator")],i.separator=a.data("separator"),i.regexSeparatorElements=["^("],i.regexSplitElements=["(?:"],e.each(i.tokenSeparators,function(e,t){i.regexSeparatorElements.push("[^"+t+"]+"),i.regexSplitElements.push("["+t+"]")}),i.regexSeparatorElements.push(")$"),i.regexSplitElements.push(")"),i.regexSeparatorString=i.regexSeparatorElements.join(""),i.regexSplitString=i.regexSplitElements.join(""),i.regexToken=new RegExp(i.regexSeparatorString,"ig"),i.regexSplit=new RegExp(i.regexSplitString,"ig")),i.matcher=function(e,a){var n=0==a.toUpperCase().indexOf(e.toUpperCase());if(!n&&"undefined"!=typeof i.tags){var s=t.where(i.tags,{text:a});if(i.tags.length>0&&t.isObject(s)){var o=r.search_id(s[0]);n=0==o.toUpperCase().indexOf(e.toUpperCase())}}return n},a.is("[data-tags]")&&(i.tags=a.data("options"),i.initSelection=function(r,a){var n=[];e(r.val().split(i.regexSplit)).each(function(){var e={id:this,text:this};if(i.tags.length>0&&t.isObject(i.tags[0])){var r=t.where(i.tags,{value:this});r.length>0&&(e=r[0],e={id:e.value,text:e.text})}n.push(e)}),a(n)},i.createSearchChoice=function(e,t){if(e.match(i.regexToken))return{id:e,text:e}},0===i.tags.length&&(i.formatNoMatches=function(){return a.attr("placeholder")})),a.is("[data-source]")){var n=a.data("source");i.data={results:[]},i.escapeMarkup=function(e){return e},i.ajax={dataType:"json",type:"POST",url:window.ajaxurl,results:function(e){return e.data}},i.ajax.data=function(e,t){return{action:"tribe_aggregator_dropdown_"+n}}}a.select2(i)}).on("change",function(r){var a=e(this),i=e(this).data("value");a.is("[multiple]")&&a.is("[data-source]")&&(r.added?t.isArray(i)?i.push(r.added):i=[r.added]:i=t.isArray(i)?t.without(i,r.removed):[],a.data("value",i).attr("data-value",JSON.stringify(i)))}),i},r.construct.media_button=function(t){var a=t.filter(r.selector.media_button);return"undefined"!=typeof wp&&wp.media&&wp.media.editor?(a.each(function(){var t=e(this),a=t.data("input"),i=e("#"+a),n=e("#"+a+"_name"),s=r.media[a]=wp.media({title:t.data("mediaTitle"),library:{type:t.data("mimeType")},multiple:!1});s.on("select",function(){var e=s.state(),t=e.get("selection");t&&t.each(function(e){i.data({id:e.attributes.id,text:e.attributes.title}),i.val(e.attributes.id),i.change(),n.html(e.attributes.filename),n.attr("title",e.attributes.filename)})})}),r.$.container.on("click",r.selector.media_button,function(t){if(t.preventDefault(),e(this).is(":visible")){var a=e(this).data("input");return r.media[a].open(a),!1}}),a):a},r.events.trigger_field_change=function(){e(this).change()},r.events.trigger_save_credentials=function(){r.save_credentials(e(this).closest(".enter-credentials"))},r.events.suppress_submission=function(t){var r=e("#tribe-ea-field-origin").val();return!(!e("#tribe-selected-rows").val().length&&"eventbrite"!==r)||void t.preventDefault()},r.events.twiddle_finalize_button_text=function(t,i){if("new"===r.$.action.val()){var n=i.rows({selected:!0})[0].length,s=a.l10n.import_checked;n||(s=a.l10n.import_all,n=i.rows()[0].length),s=s.replace("%d",n),e(r.selector.finalize_button).html(s)}},r.events.cancel_edit=function(e){e.preventDefault();var t=window.location.href;t=t.replace("tab=edit","tab=scheduled"),t=t.replace(/id=\d+/,""),window.location.href=t},r.events.verify_schedule_delete=function(){return confirm(a.l10n.verify_schedule_delete)},r.events.toggle_view_filters=function(t){t.preventDefault();var r=e(this);r.toggleClass("tribe-active"),r.is(".tribe-active")?r.html(a.l10n.hide_filters):r.html(a.l10n.view_filters)},r.progress.init=function(){r.progress.data={},r.progress.$={},r.progress.$.notice=e(".tribe-notice-aggregator-update-msg"),r.progress.$.spinner=r.progress.$.notice.find("img"),r.progress.$.progress=r.progress.$.notice.find(".progress"),r.progress.$.tracker=r.progress.$.notice.find(".tracker"),r.progress.$.created=r.progress.$.tracker.find(".track-created .value"),r.progress.$.updated=r.progress.$.tracker.find(".track-updated .value"),r.progress.$.skipped=r.progress.$.tracker.find(".track-skipped .value"),r.progress.$.remaining=r.progress.$.tracker.find(".track-remaining .value"),r.progress.$.bar=r.progress.$.notice.find(".bar"),r.progress.data.time=Date.now(),setTimeout(r.progress.start)},r.progress.start=function(){r.progress.send_request(),r.progress.update(tribe_aggregator_save.progress,tribe_aggregator_save.progressText)},r.progress.handle_response=function(e){var t=Date.now(),a=t-r.progress.data.time;e.html&&r.progress.data.notice.html(e.html),e.progress&&r.progress.update(e),e["continue"]&&(a<500?setTimeout(r.progress.send_request,500-a):r.progress.send_request()),e.complete&&(r.progress.$.notice.find(".tribe-message").html(e.complete_text),r.progress.$.tracker.remove(),r.progress.$.notice.find(".progress-container").remove(),r.progress.$.notice.removeClass("warning").addClass("completed"))},r.progress.send_request=function(){var t={record:tribe_aggregator_save.record_id,check:tribe_aggregator_save.check,action:"tribe_aggregator_realtime_update"};e.post(ajaxurl,t,r.progress.handle_response,"json")},r.progress.update=function(e){var t=parseInt(e.progress,10);if(!(t<0||t>100)&&"undefined"!=typeof e.counts){var a=["created","updated","skipped"];for(var i in a)e.counts[a[i]]&&(r.progress.$[a[i]].html(e.counts[a[i]]),r.progress.$.tracker.hasClass("has-"+a[i])||r.progress.$.tracker.addClass("has-"+a[i]));r.progress.$.bar.css("width",t+"%"),r.progress.$.progress.attr("title",e.progress_text)}},r.progress.remove_notice=function(){var e={opacity:0,height:"toggle"};r.progress.$.notice.animate(e,1e3,function(){r.progress.$.notice.remove()})},r.date_helper=function(){var t;if(t=e(this),t.hasClass("tribe-datepicker")){var r=t.val();if(""!==r&&null!==r){var a=t.attr("id").match("tribe-ea-field-(.*)_start"),i=a[1];""!==i&&null!==i&&jQuery("#tribe-date-helper-date-"+i).html(r)}}},e(document).ready(r.init)}(jQuery,_,tribe_aggregator.fields,tribe_aggregator);
|
1 |
+
var tribe_aggregator=tribe_aggregator||{};tribe_aggregator.fields={selector:{container:".tribe-ea",form:".tribe-ea-form",help:".tribe-ea-help",fields:".tribe-ea-field",dropdown:".tribe-ea-dropdown",origin_field:"#tribe-ea-field-origin",import_type_field:".tribe-import-type",media_button:".tribe-ea-media_button",datepicker:".tribe-datepicker",save_credentials_button:".enter-credentials .tribe-save",preview_container:".tribe-preview-container",preview_button:".tribe-preview:visible",refine_filters:".tribe-refine-filters",clear_filters_button:".tribe-clear-filters",finalize_button:".tribe-finalize",cancel_button:".tribe-cancel",schedule_delete_link:".tribe-ea-tab-scheduled a.submitdelete",tab_new:".tribe-ea-tab-new",action:"#tribe-action",view_filters:".tribe-view-filters"},media:{},$:{},construct:{},events:{},import_id:null,result_fetch_count:0,max_result_fetch_count:15,polling_frequency_index:0,polling_frequencies:[500,1e3,5e3,2e4],progress:{}},function(e,t,r,a){"use strict";r.init=function(){r.$.container=e(r.selector.container),r.$.form=e(r.selector.form),r.$.action=e(r.selector.action),r.$.fields=r.$.container.find(r.selector.fields),r.$.preview_container=e(r.selector.preview_container),e.each(r.construct,function(e,t){t(r.$.fields)});var t=e(document.getElementById("eventDetails"));t.data("datepicker_format")&&(tribe_ev.state.datepicker_format=t.data("datepicker_format")),e(document).on("keypress",r.selector.fields,r.events.trigger_field_change).on("click",r.selector.save_credentials_button,r.events.trigger_save_credentials).on("click",r.selector.clear_filters_button,r.clear_filters).on("click",r.selector.finalize_button,r.finalize_manual_import).on("click",r.selector.preview_button,r.preview_import).on("click",r.selector.cancel_button,r.events.cancel_edit).on("click",r.selector.schedule_delete_link,r.events.verify_schedule_delete).on("click",r.selector.view_filters,r.events.toggle_view_filters).on("blur",r.selector.datepicker,r.date_helper).on("submit",r.selector.tab_new,r.events.suppress_submission).on("change",r.selector.import_type_field,function(){r.reset_preview();var t=e(this),a=e(this).next(r.selector.fields);a.select2("val","schedule"===t.val()?"daily":"").change(),r.$.form.attr("data-type",t.val())}).on("change",r.selector.origin_field,function(){r.$.form.attr("data-origin",e(this).val()),r.reset_preview(),e(".tribe-bumpdown-active").removeClass("tribe-bumpdown-active"),e(".tribe-bumpdown:visible").hide(),e('.tribe-ea-tab-new .tribe-ea-dropdown:not([id$="tribe-ea-field-origin"])').select2("val","").change(),e(".tribe-ea-tab-new .tribe-ea-form input").val(function(){return this.defaultValue}).change(),"redirect"===e(this).val()&&(window.open("https://theeventscalendar.com/wordpress-event-aggregator/?utm_source=importoptions&utm_medium=plugin-tec&utm_campaign=in-app","_blank"),location.reload())}),e(".tribe-dependency").change(),tribe_timepickers.setup_timepickers(e(tribe_timepickers.selector.timepicker)),"edit"===r.$.action.val()&&(r.$.form.addClass("edit-form"),e(r.selector.finalize_button).html(a.l10n.edit_save)),"object"==typeof tribe_aggregator_save&&r.progress.init()},r.preview_import=function(){r.reset_polling_counter();var t=(e(".tribe-fetch-warning-message").html(""),e("#tribe-post_id"));t.data("value",t.val()),t.val("");var a=e("#tribe-import_id");a.data("value",a.val()),a.val("");var i=e(r.selector.preview_button),n=i.closest("form"),s=n.serialize();t.val(t.data("value")),a.val(t.data("value")),r.$.preview_container.addClass("tribe-fetching").removeClass("tribe-fetch-error"),r.$.form.removeClass("show-data"),i.prop("disabled",!0);var o=e(".dataTable").data("table");"undefined"!=typeof o&&o.clear().draw(),"edit"===r.$.action.val()?r.preview_save_import(s):r.create_import(s)},r.reset_polling_counter=function(){r.polling_frequency_index=0,r.result_fetch_count=0},r.reset_form=function(){r.$.fields.val("").trigger("change"),e(".tribe-ea-dropdown").select2("data",null),e('[id$="import_frequency"]').val("daily").trigger("change"),r.$.form.removeClass("show-data")},r.reset_preview=function(){r.$.form.removeClass("show-data"),e(".tribe-fetched, .tribe-fetching, .tribe-fetch-error").removeClass("tribe-fetched tribe-fetching tribe-fetch-error")},r.clear_filters=function(){e(r.selector.refine_filters).find("input, select").val("").trigger("change")},r.preview_save_import=function(t){var a=e.ajax({type:"POST",url:ajaxurl+"?action=tribe_aggregator_preview_import",data:t,dataType:"json"});a.done(r.handle_preview_create_results)},r.create_import=function(t){var a=e.ajax({type:"POST",url:ajaxurl+"?action=tribe_aggregator_create_import",data:t,dataType:"json"});a.done(r.handle_preview_create_results)},r.handle_preview_create_results=function(t){return t.success?(r.import_id=t.data.data.import_id,e("#tribe-import_id").val(r.import_id),"undefined"!=typeof t.data.data.items?(r.init_datatable(t.data.data),void r.$.preview_container.removeClass("tribe-fetching").addClass("tribe-fetched")):(r.$.container.find(".spinner-message").html(a.l10n.preview_polling[0]),void setTimeout(r.poll_for_results,r.polling_frequencies[r.polling_frequency_index]))):void r.display_fetch_error(["<b>",a.l10n.preview_fetch_error_prefix,"</b>"," "+t.data.message].join(" "))},r.poll_for_results=function(){r.result_fetch_count++;var t=e.ajax({type:"GET",url:ajaxurl+"?action=tribe_aggregator_fetch_import&import_id="+r.import_id,dataType:"json"});t.done(function(t){if("undefined"!=typeof t.data.warning&&t.data.warning){var i=t.data.warning;r.display_fetch_warning(["<b>",a.l10n.preview_fetch_warning_prefix,"</b>"," "+i].join(" "))}if(!t.success){var n;return"undefined"!=typeof t.data.message?n=t.data.message:"undefined"!=typeof t.data[0].message&&(n=t.data[0].message),void r.display_fetch_error(["<b>",a.l10n.preview_fetch_error_prefix,"</b>"," "+n].join(" "))}"error"===t.data.status?r.display_fetch_error(t.data.message):"success"!==t.data.status?(r.result_fetch_count>r.max_result_fetch_count&&(r.polling_frequency_index++,r.$.container.find(".spinner-message").html(a.l10n.preview_polling[r.polling_frequency_index]),r.result_fetch_count=0),"undefined"==typeof r.polling_frequencies[r.polling_frequency_index]?r.display_fetch_error(a.l10n.preview_timeout):setTimeout(r.poll_for_results,r.polling_frequencies[r.polling_frequency_index])):(t.data.data.items=t.data.data.events,r.init_datatable(t.data.data),r.$.preview_container.removeClass("tribe-fetching").addClass("tribe-fetched"),e(r.selector.preview_button).prop("disabled",!1))})},r.init_datatable=function(t){var i=!1,n=e(r.selector.origin_field).val(),s="csv"===n,o=e('[id$="import_type"]:visible'),l="manual";if("undefined"!=typeof a.default_settings[n])for(var c in a.default_settings[n])if(a.default_settings[n].hasOwnProperty(c)){var d=e("#tribe-ea-field-"+c);d.val(a.default_settings[n][c]).select2("val",a.default_settings[n][c]).trigger("change")}if(o.length&&(l=e("#"+o.first().attr("id").replace("s2id_","")).val()),"manual"===l&&!t.items.length){var n=t.origin,p="undefined"!=typeof a.l10n[n]&&"undefined"!=typeof a.l10n[n].no_results,u=p?a.l10n[n].no_results:a.l10n.no_results;return void r.display_fetch_error(u)}o.length&&"manual"!==l||(i=!0);var _=r.$.preview_container.find(".data-container table"),f=[];for(var g in t.items){var m=t.items[g];m.checkbox=i?'<input type="checkbox">':"",m.all_day?m.start_time=a.l10n.all_day:("undefined"!=typeof m.start_meridian&&m.start_meridian||(parseInt(m.start_hour,10)>11?m.start_meridian=a.l10n.pm:m.start_meridian=a.l10n.am),m.start_hour>12&&(m.start_hour=m.start_hour-12),m.start_time=(0===parseInt(m.start_hour,10)?12:m.start_hour)+":"+("00"+m.start_minute).slice(-2),m.start_time+=" "+m.start_meridian),f.push(m)}i&&!s?_.addClass("display-checkboxes"):_.removeClass("display-checkboxes"),r.$.form.addClass("show-data");var v={lengthMenu:[[5,10,25,50,-1],[5,10,25,50,tribe_l10n_datatables.pagination.all]],order:[[1,"asc"]],columnDefs:[{cellType:"th",className:"check-column",orderable:!1,targets:0}],data:f};if("undefined"!=typeof t.columns){v.columns=[{data:"checkbox"}];var h=_.find("thead tr"),b=_.find("tfoot tr"),w=e({}),y="",x="";if(h.find("th:first").nextAll().remove(),b.find("th:first").nextAll().remove(),s){var $=_.closest(".data-container");_.closest(".data-container").addClass("csv-data"),$.find(".tribe-preview-message .tribe-csv-filename").html(e("#tribe-ea-field-csv_file_name").text()),h.closest("thead").prepend('<tr class="tribe-column-map"><th scope="row" class="check-column column-cb"></th></tr>'),w=e(".tribe-column-map"),x=e("#tribe-ea-field-csv_content_type").val(),x=x.replace("tribe_","");var k=e("#tribe-csv-column-map-"+x);y=k.html()}var C=0;for(g in t.columns){if(v.columns.push({data:t.columns[g]}),h.append('<th scope="col">'+t.columns[g]+"</th>"),b.append('<th scope="col">'+t.columns[g]+"</th>"),s){var S=t.columns[g].toLowerCase().replace(" ","_").replace(/[^a-z0-9_]/,"");w.append('<th scope="col">'+y.replace('name="column_map[]"','name="aggregator[column_map]['+C+']" id="column-'+C+'"')+"</th>");var j=w.find("#column-"+C);"undefined"!=typeof a.csv_column_mapping[x][C]&&(S=a.csv_column_mapping[x][C]),j.find('option[value="'+S+'"]').prop("selected",!0)}C++}v.scrollX=!0}else v.columns=[{data:"checkbox"},{data:"start_date"},{data:"start_time"},{data:"end_date"},{data:"title"}],v.autoWidth=!1;_.tribeDataTable(v),r.wrap_cell_content(),_.on("select.dt",r.events.twiddle_finalize_button_text).on("deselect.dt",r.events.twiddle_finalize_button_text).on("draw.dt",r.wrap_cell_content);var T;"new"===r.$.action.val()&&(T="manual"===l&&s?a.l10n.import_all_no_number:"manual"===l?a.l10n.import_all.replace("%d",f.length):a.l10n.create_schedule),e(r.selector.finalize_button).html(T)},r.wrap_cell_content=function(){e(".dataTable").find("tbody td").each(function(){var t=e(this);t.html('<div class="tribe-td-height-limit">'+t.html()+"</div>")})},r.display_fetch_error=function(t){var a=e(".tribe-fetch-error-message");r.$.preview_container.removeClass("tribe-fetching").addClass("tribe-fetch-error"),a.html(""),r.display_error(a,t),e(r.selector.preview_button).prop("disabled",!1)},r.display_fetch_warning=function(t){var a=e(".tribe-fetch-warning-message");r.$.preview_container.removeClass("tribe-fetching").addClass("tribe-fetch-warning"),a.html(""),r.display_warning(a,t)},r.display_error=function(e,t){e.prepend(['<div class="notice notice-error">',"<p>",t,"</p>","</div>"].join(""))},r.display_warning=function(e,t){e.prepend(['<div class="notice notice-warning">',"<p>",t,"</p>","</div>"].join(""))},r.display_success=function(e,t){e.prepend(['<div class="notice notice-success">',"<p>",t,"</p>","</div>"].join(""))},r.save_credentials=function(t){var r=t.find(".tribe-fieldset").find("input").serialize(),a=ajaxurl+"?action=tribe_aggregator_save_credentials",i=e.post(a,r);i.done(function(e){e.success&&(t.addClass("credentials-entered"),t.find('[name="has-credentials"]').val(1).change())})},r.finalize_manual_import=function(){var t=e("#tribe-ea-field-origin").val(),i=e(".dataTable"),n=window.tribe_data_table;if("eventbrite"===t)return void r.$.form.submit();if(i.hasClass("display-checkboxes")){var s=n.rows({selected:!0});if(s[0].length||(s=n.rows()),!s[0].length)return void r.display_error(e(".tribe-finalize-container"),a.l10n.events_required_for_manual_submit);var o=s.data(),l=[],c=null;if("facebook"===t?c="facebook_id":"meetup"===t?c="meetup_id":"ical"===t||"ics"===t||"gcal"===t?c="uid":"url"===t&&(c="id"),null!==c){for(var d in o)isNaN(d)||"undefined"!=typeof o[d][c]&&l.push(o[d][c]);e("#tribe-selected-rows").text(JSON.stringify(l))}else e("#tribe-selected-rows").text("all")}else e("#tribe-selected-rows").text("all");e(".dataTables_scrollBody").find('[name^="aggregator[column_map]"]').remove(),r.$.form.submit()},r.search_id=function(e){var t=null;return"undefined"!=typeof e.id?t=e.id:"undefined"!=typeof e.ID?t=e.ID:"undefined"!=typeof e.value&&(t=e.value),void 0==e?null:t},r.construct.dropdown=function(a){var i=a.filter(r.selector.dropdown).not(".select2-offscreen, .select2-container");return i.each(function(){var a=e(this),i={};if(a.is("select")||(i.id=r.search_id),i.allowClear=!0,a.is("[data-prevent-clear]")&&(i.allowClear=!1),a.is("[data-options]")&&(i.data=a.data("options")),a.is("[data-hide-search]")&&(i.minimumResultsForSearch=1/0),i.upsellFormatter=function(t){var r=e(t.element);return"string"==typeof r.data("subtitle")&&(t.text=t.text+'<br><span class="tribe-dropdown-subtitle">'+r.data("subtitle")+"</span>"),t.text},"tribe-ea-field-origin"===a.attr("id")&&(i.formatResult=i.upsellFormatter,i.formatSelection=i.upsellFormatter,i.escapeMarkup=function(e){return e}),a.is("[multiple]")&&(i.multiple=!0,t.isArray(a.data("separator"))?i.tokenSeparators=a.data("separator"):i.tokenSeparators=[a.data("separator")],i.separator=a.data("separator"),i.regexSeparatorElements=["^("],i.regexSplitElements=["(?:"],e.each(i.tokenSeparators,function(e,t){i.regexSeparatorElements.push("[^"+t+"]+"),i.regexSplitElements.push("["+t+"]")}),i.regexSeparatorElements.push(")$"),i.regexSplitElements.push(")"),i.regexSeparatorString=i.regexSeparatorElements.join(""),i.regexSplitString=i.regexSplitElements.join(""),i.regexToken=new RegExp(i.regexSeparatorString,"ig"),i.regexSplit=new RegExp(i.regexSplitString,"ig")),i.matcher=function(e,a){var n=0==a.toUpperCase().indexOf(e.toUpperCase());if(!n&&"undefined"!=typeof i.tags){var s=t.where(i.tags,{text:a});if(i.tags.length>0&&t.isObject(s)){var o=r.search_id(s[0]);n=0==o.toUpperCase().indexOf(e.toUpperCase())}}return n},a.is("[data-tags]")&&(i.tags=a.data("options"),i.initSelection=function(r,a){var n=[];e(r.val().split(i.regexSplit)).each(function(){var e={id:this,text:this};if(i.tags.length>0&&t.isObject(i.tags[0])){var r=t.where(i.tags,{value:this});r.length>0&&(e=r[0],e={id:e.value,text:e.text})}n.push(e)}),a(n)},i.createSearchChoice=function(e,t){if(e.match(i.regexToken))return{id:e,text:e}},0===i.tags.length&&(i.formatNoMatches=function(){return a.attr("placeholder")})),a.is("[data-source]")){var n=a.data("source");i.data={results:[]},i.escapeMarkup=function(e){return e},i.ajax={dataType:"json",type:"POST",url:window.ajaxurl,results:function(e){return e.data}},i.ajax.data=function(e,t){return{action:"tribe_aggregator_dropdown_"+n}}}a.select2(i)}).on("change",function(r){var a=e(this),i=e(this).data("value");a.is("[multiple]")&&a.is("[data-source]")&&(r.added?t.isArray(i)?i.push(r.added):i=[r.added]:i=t.isArray(i)?t.without(i,r.removed):[],a.data("value",i).attr("data-value",JSON.stringify(i)))}),i},r.construct.media_button=function(t){var a=t.filter(r.selector.media_button);return"undefined"!=typeof wp&&wp.media&&wp.media.editor?(a.each(function(){var t=e(this),a=t.data("input"),i=e("#"+a),n=e("#"+a+"_name"),s=r.media[a]=wp.media({title:t.data("mediaTitle"),library:{type:t.data("mimeType")},multiple:!1});s.on("select",function(){var e=s.state(),t=e.get("selection");t&&t.each(function(e){i.data({id:e.attributes.id,text:e.attributes.title}),i.val(e.attributes.id),i.change(),n.html(e.attributes.filename),n.attr("title",e.attributes.filename)})})}),r.$.container.on("click",r.selector.media_button,function(t){if(t.preventDefault(),e(this).is(":visible")){var a=e(this).data("input");return r.media[a].open(a),!1}}),a):a},r.events.trigger_field_change=function(){e(this).change()},r.events.trigger_save_credentials=function(){r.save_credentials(e(this).closest(".enter-credentials"))},r.events.suppress_submission=function(t){var r=e("#tribe-ea-field-origin").val();return!(!e("#tribe-selected-rows").val().length&&"eventbrite"!==r)||void t.preventDefault()},r.events.twiddle_finalize_button_text=function(t,i){if("new"===r.$.action.val()){var n=i.rows({selected:!0})[0].length,s=a.l10n.import_checked;n||(s=a.l10n.import_all,n=i.rows()[0].length),s=s.replace("%d",n),e(r.selector.finalize_button).html(s)}},r.events.cancel_edit=function(e){e.preventDefault();var t=window.location.href;t=t.replace("tab=edit","tab=scheduled"),t=t.replace(/id=\d+/,""),window.location.href=t},r.events.verify_schedule_delete=function(){return confirm(a.l10n.verify_schedule_delete)},r.events.toggle_view_filters=function(t){t.preventDefault();var r=e(this);r.toggleClass("tribe-active"),r.is(".tribe-active")?r.html(a.l10n.hide_filters):r.html(a.l10n.view_filters)},r.progress.init=function(){r.progress.data={},r.progress.$={},r.progress.$.notice=e(".tribe-notice-aggregator-update-msg"),r.progress.$.spinner=r.progress.$.notice.find("img"),r.progress.$.progress=r.progress.$.notice.find(".progress"),r.progress.$.tracker=r.progress.$.notice.find(".tracker"),r.progress.$.created=r.progress.$.tracker.find(".track-created .value"),r.progress.$.updated=r.progress.$.tracker.find(".track-updated .value"),r.progress.$.skipped=r.progress.$.tracker.find(".track-skipped .value"),r.progress.$.remaining=r.progress.$.tracker.find(".track-remaining .value"),r.progress.$.bar=r.progress.$.notice.find(".bar"),r.progress.data.time=Date.now(),setTimeout(r.progress.start)},r.progress.start=function(){r.progress.send_request(),r.progress.update(tribe_aggregator_save.progress,tribe_aggregator_save.progressText)},r.progress.handle_response=function(e){var t=Date.now(),a=t-r.progress.data.time;e.html&&r.progress.data.notice.html(e.html),e.progress&&r.progress.update(e),e["continue"]&&(a<500?setTimeout(r.progress.send_request,500-a):r.progress.send_request()),e.complete&&(r.progress.$.notice.find(".tribe-message").html(e.complete_text),r.progress.$.tracker.remove(),r.progress.$.notice.find(".progress-container").remove(),r.progress.$.notice.removeClass("warning").addClass("completed"))},r.progress.send_request=function(){var t={record:tribe_aggregator_save.record_id,check:tribe_aggregator_save.check,action:"tribe_aggregator_realtime_update"};e.post(ajaxurl,t,r.progress.handle_response,"json")},r.progress.update=function(e){var t=parseInt(e.progress,10);if(!(t<0||t>100)&&"undefined"!=typeof e.counts){var a=["created","updated","skipped"];for(var i in a)e.counts[a[i]]&&(r.progress.$[a[i]].html(e.counts[a[i]]),r.progress.$.tracker.hasClass("has-"+a[i])||r.progress.$.tracker.addClass("has-"+a[i]));r.progress.$.bar.css("width",t+"%"),r.progress.$.progress.attr("title",e.progress_text)}},r.progress.remove_notice=function(){var e={opacity:0,height:"toggle"};r.progress.$.notice.animate(e,1e3,function(){r.progress.$.notice.remove()})},r.date_helper=function(){var t;if(t=e(this),t.hasClass("tribe-datepicker")){var r=t.val();if(""!==r&&null!==r){var a=t.attr("id").match("tribe-ea-field-(.*)_start"),i=a[1];""!==i&&null!==i&&jQuery("#tribe-date-helper-date-"+i).html(r)}}},e(document).ready(r.init)}(jQuery,_,tribe_aggregator.fields,tribe_aggregator);
|
the-events-calendar.php
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
/*
|
3 |
Plugin Name: The Events Calendar
|
4 |
Description: The Events Calendar is a carefully crafted, extensible plugin that lets you easily share your events. Beautiful. Solid. Awesome.
|
5 |
-
Version: 4.6.
|
6 |
Author: Modern Tribe, Inc.
|
7 |
Author URI: http://m.tri.be/1x
|
8 |
Text Domain: the-events-calendar
|
2 |
/*
|
3 |
Plugin Name: The Events Calendar
|
4 |
Description: The Events Calendar is a carefully crafted, extensible plugin that lets you easily share your events. Beautiful. Solid. Awesome.
|
5 |
+
Version: 4.6.6
|
6 |
Author: Modern Tribe, Inc.
|
7 |
Author URI: http://m.tri.be/1x
|
8 |
Text Domain: the-events-calendar
|