Version Description
- new filter: added pmxe_after_iteration action
- bugfix: increase custom query meta limit
- bugfix: remove deprecated function calls for PHP 7.2 compatibility
- bugfix: address various PHP warnings and notices
- bugfix: graceful failure for non:writable uploads folder
- bugfix: warning when exporting WooCommerce orders using Automatic Scheduling
- bugfix: WooCommerce product variations exported as separate products when adding product attributes to custom export fields
- bugfix: small UI and spacing issues
- bugfix: prices with more than two decimal places are not exported correctly
- bugfix: exporting empty ACF values shifts rows in CSV exports
- bugfix: Australia missing from scheduling timezones
- bugfix: unable to filter or export WooCommerce product visibility data
- bugfix: Automatic scheduling UI spacing issues
- bugfix: unrelated errors are reported in functions.php file
Download this release
Release Info
Developer | soflyy |
Plugin | Export WordPress data to XML/CSV |
Version | 1.2.1 |
Comparing to | |
See all releases |
Code changes from version 1.2.0 to 1.2.1
- actions/wp_ajax_scheduling_dialog_content.php +13 -16
- actions/wp_ajax_wpae_filtering.php +4 -0
- classes/config.php +32 -24
- classes/input.php +2 -3
- classes/wpallimport.php +4 -2
- controllers/admin/export.php +6 -4
- controllers/admin/manage.php +42 -8
- controllers/controller/admin.php +1 -1
- dist/app.js +13 -10
- dist/app.min.js +4 -4
- filters/pmxe_url_filter.php +5 -0
- libraries/WpaeXmlProcessor.php +6 -4
- libraries/XmlCsvExport.php +1 -1
- libraries/XmlExportACF.php +7 -3
- libraries/XmlExportCpt.php +4 -0
- libraries/XmlExportEngine.php +7 -7
- libraries/XmlExportMediaGallery.php +10 -6
- libraries/XmlExportWooCommerce.php +5 -10
- libraries/XmlExportWooCommerceOrder.php +18 -2
- models/export/record.php +5 -5
- readme.txt +18 -2
- src/App/Controller/SchedulingLicenseController.php +14 -0
- src/App/Service/Pro/VariationOptions/VariationOptions.php +6 -2
- src/App/Service/VariationOptions/VariationOptions.php +23 -6
- src/App/Specification/IsImportAllowed.php +53 -0
- src/App/UnsecuredController/SchedulingController.php +3 -1
- src/Pro/Filtering/FilteringBase.php +1 -1
- src/Scheduling/Export.php +1 -1
- src/Scheduling/Timezone/TimezoneSelect.php +2 -0
- src/Scheduling/views/ConnectionIcon.php +24 -12
- src/Scheduling/views/SchedulingHelp.php +1 -1
- src/Scheduling/views/SchedulingOptions.php +14 -16
- src/Scheduling/views/SchedulingUI.php +13 -15
- static/css/admin.css +11 -2
- static/js/admin.js +49 -4
- views/admin/export/options.php +29 -8
- views/admin/export/process.php +17 -34
- views/admin/export/success_page.php +132 -0
- views/admin/export/template.php +22 -22
- views/admin/manage/update.php +5 -2
- wp-all-export.php +93 -76
actions/wp_ajax_scheduling_dialog_content.php
CHANGED
@@ -195,7 +195,7 @@ function pmxe_wp_ajax_scheduling_dialog_content()
|
|
195 |
|
196 |
#add-subscription-field {
|
197 |
position: absolute;
|
198 |
-
left: -
|
199 |
top: -1px;
|
200 |
height: 46px;
|
201 |
border-radius: 5px;
|
@@ -242,12 +242,12 @@ function pmxe_wp_ajax_scheduling_dialog_content()
|
|
242 |
margin-bottom: 5px;
|
243 |
color: #40acad;
|
244 |
text-decoration: none;
|
|
|
245 |
}
|
246 |
|
247 |
.manual-scheduling {
|
248 |
margin-left: 26px;
|
249 |
}
|
250 |
-
|
251 |
.chosen-container .chosen-results {
|
252 |
|
253 |
margin: 0 4px 4px 0 !important;
|
@@ -549,6 +549,8 @@ function pmxe_wp_ajax_scheduling_dialog_content()
|
|
549 |
$('.save-changes').removeClass('disabled');
|
550 |
window.pmxeHasSchedulingSubscription = true;
|
551 |
|
|
|
|
|
552 |
} else {
|
553 |
|
554 |
$('#subscribe-button .easing-spinner').hide();
|
@@ -567,7 +569,7 @@ function pmxe_wp_ajax_scheduling_dialog_content()
|
|
567 |
|
568 |
setTimeout(function () {
|
569 |
$('#add-subscription-field').animate({width: '140px'}, 225);
|
570 |
-
$('#add-subscription-field').animate({left: '-
|
571 |
}, 300);
|
572 |
|
573 |
$('#add-subscription-field').val('');
|
@@ -624,7 +626,7 @@ function pmxe_wp_ajax_scheduling_dialog_content()
|
|
624 |
<?php require __DIR__ . '/../src/Scheduling/views/CommonJs.php'; ?>
|
625 |
<div id="post-preview" class="wpallexport-preview wpallexport-scheduling-dialog">
|
626 |
<p class="wpallexport-preview-title"><strong>Scheduling Options</strong></p>
|
627 |
-
<div class="wpallexport-preview-content" style="max-height:
|
628 |
|
629 |
<div style="margin-bottom: 20px;">
|
630 |
<label>
|
@@ -637,17 +639,12 @@ function pmxe_wp_ajax_scheduling_dialog_content()
|
|
637 |
<label>
|
638 |
<input type="radio" name="scheduling_enable"
|
639 |
value="1" <?php if ($post['scheduling_enable'] == 1) { ?> checked="checked" <?php } ?>/>
|
640 |
-
<h4 style="margin
|
641 |
-
<span class="connection-icon"
|
642 |
-
|
643 |
-
|
644 |
-
<?php if (!$scheduling->checkConnection()
|
645 |
-
<span
|
646 |
-
<span <?php if (!$scheduling->checkConnection() && $scheduling->checkLicense()) { ?> style="color: #f2b03d;" <?php } ?>>Unable to connect -</span>
|
647 |
-
<a style="text-decoration: underline; color: #0073aa;"
|
648 |
-
href="http://wpallimport.com/support"
|
649 |
-
target="_blank">please contact support</a>.
|
650 |
-
</span>
|
651 |
<?php } ?>
|
652 |
</h4>
|
653 |
</label>
|
@@ -714,7 +711,7 @@ function pmxe_wp_ajax_scheduling_dialog_content()
|
|
714 |
</label>
|
715 |
</div>
|
716 |
<input type="hidden" name="scheduling_monthly_days"
|
717 |
-
value="<?php echo $post['scheduling_monthly_days']; ?>" id="monthly_days"/>
|
718 |
<?php
|
719 |
if (isset($post['scheduling_monthly_days'])) {
|
720 |
$monthlyArray = explode(',', $post['scheduling_monthly_days']);
|
195 |
|
196 |
#add-subscription-field {
|
197 |
position: absolute;
|
198 |
+
left: -155px;
|
199 |
top: -1px;
|
200 |
height: 46px;
|
201 |
border-radius: 5px;
|
242 |
margin-bottom: 5px;
|
243 |
color: #40acad;
|
244 |
text-decoration: none;
|
245 |
+
margin-left: 0;
|
246 |
}
|
247 |
|
248 |
.manual-scheduling {
|
249 |
margin-left: 26px;
|
250 |
}
|
|
|
251 |
.chosen-container .chosen-results {
|
252 |
|
253 |
margin: 0 4px 4px 0 !important;
|
549 |
$('.save-changes').removeClass('disabled');
|
550 |
window.pmxeHasSchedulingSubscription = true;
|
551 |
|
552 |
+
$('.wpai-no-license').hide();
|
553 |
+
$('.wpai-license').show();
|
554 |
} else {
|
555 |
|
556 |
$('#subscribe-button .easing-spinner').hide();
|
569 |
|
570 |
setTimeout(function () {
|
571 |
$('#add-subscription-field').animate({width: '140px'}, 225);
|
572 |
+
$('#add-subscription-field').animate({left: '-155px'}, 225);
|
573 |
}, 300);
|
574 |
|
575 |
$('#add-subscription-field').val('');
|
626 |
<?php require __DIR__ . '/../src/Scheduling/views/CommonJs.php'; ?>
|
627 |
<div id="post-preview" class="wpallexport-preview wpallexport-scheduling-dialog">
|
628 |
<p class="wpallexport-preview-title"><strong>Scheduling Options</strong></p>
|
629 |
+
<div class="wpallexport-preview-content" style="max-height: 700px; overflow: visible;">
|
630 |
|
631 |
<div style="margin-bottom: 20px;">
|
632 |
<label>
|
639 |
<label>
|
640 |
<input type="radio" name="scheduling_enable"
|
641 |
value="1" <?php if ($post['scheduling_enable'] == 1) { ?> checked="checked" <?php } ?>/>
|
642 |
+
<h4 style="margin: 0; position: relative; display: inline-block;"><?php _e('Automatic Scheduling', PMXE_Plugin::LANGUAGE_DOMAIN); ?>
|
643 |
+
<span class="connection-icon">
|
644 |
+
<?php include __DIR__ . '/../src/Scheduling/views/ConnectionIcon.php'; ?>
|
645 |
+
</span>
|
646 |
+
<?php if (!$scheduling->checkConnection()) { ?>
|
647 |
+
<span class="wpai-license wpai-license-text" style="display: inline-block; font-weight: normal; <?php if(!$hasActiveLicense) { ?> display: none; <?php }?> color: #f2b03d; ">Unable to connect - <a target="_blank" style="text-decoration: underline;" href="http://wpallimport.com/support">please contact support</a>.</span>
|
|
|
|
|
|
|
|
|
|
|
648 |
<?php } ?>
|
649 |
</h4>
|
650 |
</label>
|
711 |
</label>
|
712 |
</div>
|
713 |
<input type="hidden" name="scheduling_monthly_days"
|
714 |
+
value="<?php if(isset($post['scheduling_monthly_days'])) echo $post['scheduling_monthly_days']; ?>" id="monthly_days"/>
|
715 |
<?php
|
716 |
if (isset($post['scheduling_monthly_days'])) {
|
717 |
$monthlyArray = explode(',', $post['scheduling_monthly_days']);
|
actions/wp_ajax_wpae_filtering.php
CHANGED
@@ -55,6 +55,10 @@ function pmxe_wp_ajax_wpae_filtering(){
|
|
55 |
|
56 |
if ( XmlExportEngine::$is_auto_generate_enabled ):
|
57 |
?>
|
|
|
|
|
|
|
|
|
58 |
<?php if(isset($post['cpt'])) { ?>
|
59 |
<span class="wp_all_export_btn_with_note">
|
60 |
<a href="javascript:void(0);" class="back rad3 auto-generate-template" style="float:none; background: #425f9a; padding: 0 50px; margin-right: 10px; color: #fff; font-weight: normal;"><?php printf(__('Migrate %s', 'wp_all_export_plugin'), wp_all_export_get_cpt_name(array($post['cpt']), 2, $post)); ?></a>
|
55 |
|
56 |
if ( XmlExportEngine::$is_auto_generate_enabled ):
|
57 |
?>
|
58 |
+
<div class="wpallexport-free-edition-notice" id="migrate-orders-notice" style="padding: 20px; margin-bottom: 10px; display: none;">
|
59 |
+
<a class="upgrade_link" target="_blank" href="https://www.wpallimport.com/checkout/?edd_action=add_to_cart&download_id=118611&edd_options%5Bprice_id%5D=1&utm_source=wordpress.org&utm_medium=migrate+orders&utm_campaign=free+wp+all+export+plugin"><?php _e('Upgrade to the Pro edition of WP All Export to Migrate Orders', PMXE_Plugin::LANGUAGE_DOMAIN);?></a>
|
60 |
+
<p><?php _e('If you already own it, remove the free edition and install the Pro edition.', PMXE_Plugin::LANGUAGE_DOMAIN);?></p>
|
61 |
+
</div>
|
62 |
<?php if(isset($post['cpt'])) { ?>
|
63 |
<span class="wp_all_export_btn_with_note">
|
64 |
<a href="javascript:void(0);" class="back rad3 auto-generate-template" style="float:none; background: #425f9a; padding: 0 50px; margin-right: 10px; color: #fff; font-weight: normal;"><?php printf(__('Migrate %s', 'wp_all_export_plugin'), wp_all_export_get_cpt_name(array($post['cpt']), 2, $post)); ?></a>
|
classes/config.php
CHANGED
@@ -1,15 +1,18 @@
|
|
1 |
<?php
|
|
|
2 |
/**
|
3 |
* Class to load config files
|
4 |
-
*
|
5 |
* @author Pavel Kulbakin <p.kulbakin@gmail.com>
|
6 |
*/
|
7 |
class PMXE_Config implements IteratorAggregate {
|
|
|
8 |
/**
|
9 |
* Config variables stored
|
10 |
* @var array
|
11 |
*/
|
12 |
protected $config = array();
|
|
|
13 |
/**
|
14 |
* List of loaded files in order to avoid loading same file several times
|
15 |
* @var array
|
@@ -26,29 +29,33 @@ class PMXE_Config implements IteratorAggregate {
|
|
26 |
$config = new self();
|
27 |
return $config->loadFromFile($filePath, $section);
|
28 |
}
|
29 |
-
|
30 |
-
|
31 |
-
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
-
|
|
|
|
|
|
|
|
|
52 |
/**
|
53 |
* Return value of setting with specified name
|
54 |
* @param string $field Setting name
|
@@ -67,6 +74,7 @@ class PMXE_Config implements IteratorAggregate {
|
|
67 |
public function __isset($field) {
|
68 |
return isset($this->config[$field]);
|
69 |
}
|
|
|
70 |
/**
|
71 |
* Magic method to implement object-like access to config parameters
|
72 |
* @param string $field
|
1 |
<?php
|
2 |
+
|
3 |
/**
|
4 |
* Class to load config files
|
5 |
+
*
|
6 |
* @author Pavel Kulbakin <p.kulbakin@gmail.com>
|
7 |
*/
|
8 |
class PMXE_Config implements IteratorAggregate {
|
9 |
+
|
10 |
/**
|
11 |
* Config variables stored
|
12 |
* @var array
|
13 |
*/
|
14 |
protected $config = array();
|
15 |
+
|
16 |
/**
|
17 |
* List of loaded files in order to avoid loading same file several times
|
18 |
* @var array
|
29 |
$config = new self();
|
30 |
return $config->loadFromFile($filePath, $section);
|
31 |
}
|
32 |
+
|
33 |
+
/**
|
34 |
+
* Load config file
|
35 |
+
* @param string $filePath
|
36 |
+
* @param string [optional] $section
|
37 |
+
* @return PMXE_Config
|
38 |
+
*/
|
39 |
+
public function loadFromFile($filePath, $section = NULL)
|
40 |
+
{
|
41 |
+
if (!is_null($section)) {
|
42 |
+
$this->config[$section] = self::createFromFile($filePath);
|
43 |
+
} else {
|
44 |
+
$filePath = realpath($filePath);
|
45 |
+
if ($filePath and !in_array($filePath, $this->loaded)) {
|
46 |
+
|
47 |
+
require $filePath;
|
48 |
+
|
49 |
+
if (!isset($config)) {
|
50 |
+
$config = array();
|
51 |
+
}
|
52 |
+
}
|
53 |
+
$this->loaded[] = $filePath;
|
54 |
+
$this->config = array_merge($this->config, $config);
|
55 |
+
}
|
56 |
+
return $this;
|
57 |
+
}
|
58 |
+
|
59 |
/**
|
60 |
* Return value of setting with specified name
|
61 |
* @param string $field Setting name
|
74 |
public function __isset($field) {
|
75 |
return isset($this->config[$field]);
|
76 |
}
|
77 |
+
|
78 |
/**
|
79 |
* Magic method to implement object-like access to config parameters
|
80 |
* @param string $field
|
classes/input.php
CHANGED
@@ -23,13 +23,12 @@ class PMXE_Input {
|
|
23 |
$this->addFilter('strip_tags');
|
24 |
$this->addFilter('esc_sql');
|
25 |
$this->addFilter('esc_js');
|
26 |
-
|
27 |
$this->removeFilter('htmlspecialchars');
|
28 |
$this->removeFilter('strip_tags');
|
29 |
$this->removeFilter('esc_sql');
|
30 |
$this->removeFilter('esc_js');
|
31 |
-
|
32 |
-
return $result;
|
33 |
}
|
34 |
|
35 |
public function post($paramName, $default = NULL) {
|
23 |
$this->addFilter('strip_tags');
|
24 |
$this->addFilter('esc_sql');
|
25 |
$this->addFilter('esc_js');
|
26 |
+
$result = $this->read($_GET, $paramName, $default);
|
27 |
$this->removeFilter('htmlspecialchars');
|
28 |
$this->removeFilter('strip_tags');
|
29 |
$this->removeFilter('esc_sql');
|
30 |
$this->removeFilter('esc_js');
|
31 |
+
return $result;
|
|
|
32 |
}
|
33 |
|
34 |
public function post($paramName, $default = NULL) {
|
classes/wpallimport.php
CHANGED
@@ -144,6 +144,8 @@ final class PMXE_Wpallimport
|
|
144 |
'is_update_parent' => 0,
|
145 |
'is_update_attachments' => 0,
|
146 |
'is_update_acf' => 0,
|
|
|
|
|
147 |
'update_acf_logic' => 'only',
|
148 |
'acf_list' => '',
|
149 |
'is_update_product_type' => 1,
|
@@ -243,12 +245,12 @@ final class PMXE_Wpallimport
|
|
243 |
self::$templateOptions['pmwi_order']['is_update_taxes'] = 0;
|
244 |
self::$templateOptions['pmwi_order']['is_update_refunds'] = 0;
|
245 |
self::$templateOptions['pmwi_order']['is_update_total'] = 0;
|
246 |
-
|
247 |
self::$templateOptions['pmwi_order']['status'] = 'wc-pending';
|
248 |
self::$templateOptions['pmwi_order']['billing_source'] = 'existing';
|
249 |
self::$templateOptions['pmwi_order']['billing_source_match_by'] = 'username';
|
250 |
self::$templateOptions['pmwi_order']['shipping_source'] = 'guest';
|
251 |
-
|
252 |
self::$templateOptions['pmwi_order']['products_repeater_mode'] = 'csv';
|
253 |
self::$templateOptions['pmwi_order']['products_repeater_mode_separator'] = '|';
|
254 |
self::$templateOptions['pmwi_order']['products_source'] = 'existing';
|
144 |
'is_update_parent' => 0,
|
145 |
'is_update_attachments' => 0,
|
146 |
'is_update_acf' => 0,
|
147 |
+
'is_update_comment_status' => 0,
|
148 |
+
'import_img_tags' => 1,
|
149 |
'update_acf_logic' => 'only',
|
150 |
'acf_list' => '',
|
151 |
'is_update_product_type' => 1,
|
245 |
self::$templateOptions['pmwi_order']['is_update_taxes'] = 0;
|
246 |
self::$templateOptions['pmwi_order']['is_update_refunds'] = 0;
|
247 |
self::$templateOptions['pmwi_order']['is_update_total'] = 0;
|
248 |
+
self::$templateOptions['pmwi_order']['is_guest_matching'] = 1;
|
249 |
self::$templateOptions['pmwi_order']['status'] = 'wc-pending';
|
250 |
self::$templateOptions['pmwi_order']['billing_source'] = 'existing';
|
251 |
self::$templateOptions['pmwi_order']['billing_source_match_by'] = 'username';
|
252 |
self::$templateOptions['pmwi_order']['shipping_source'] = 'guest';
|
253 |
+
self::$templateOptions['pmwi_order']['copy_from_billing'] = 1;
|
254 |
self::$templateOptions['pmwi_order']['products_repeater_mode'] = 'csv';
|
255 |
self::$templateOptions['pmwi_order']['products_repeater_mode_separator'] = '|';
|
256 |
self::$templateOptions['pmwi_order']['products_source'] = 'existing';
|
controllers/admin/export.php
CHANGED
@@ -110,10 +110,12 @@ class PMXE_Admin_Export extends PMXE_Controller_Admin
|
|
110 |
if (is_array($this->data['post']['cpt'])) $this->data['post']['cpt'] = $this->data['post']['cpt'][0];
|
111 |
|
112 |
// Delete history
|
113 |
-
|
114 |
-
|
115 |
-
|
116 |
-
|
|
|
|
|
117 |
}
|
118 |
}
|
119 |
|
110 |
if (is_array($this->data['post']['cpt'])) $this->data['post']['cpt'] = $this->data['post']['cpt'][0];
|
111 |
|
112 |
// Delete history
|
113 |
+
if(is_dir(PMXE_ROOT_DIR.'/history')) {
|
114 |
+
$history_files = PMXE_Helper::safe_glob(PMXE_ROOT_DIR . '/history/*', PMXE_Helper::GLOB_RECURSE | PMXE_Helper::GLOB_PATH);
|
115 |
+
if (!empty($history_files)) {
|
116 |
+
foreach ($history_files as $filePath) {
|
117 |
+
@file_exists($filePath) and @unlink($filePath);
|
118 |
+
}
|
119 |
}
|
120 |
}
|
121 |
|
controllers/admin/manage.php
CHANGED
@@ -218,7 +218,7 @@ class PMXE_Admin_Manage extends PMXE_Controller_Admin {
|
|
218 |
|
219 |
PMXE_Plugin::$session->save_data();
|
220 |
|
221 |
-
if ( ! $this->errors->get_error_codes()) {
|
222 |
|
223 |
// deligate operation to other controller
|
224 |
$controller = new PMXE_Admin_Export();
|
@@ -230,12 +230,8 @@ class PMXE_Admin_Manage extends PMXE_Controller_Admin {
|
|
230 |
|
231 |
$this->errors->remove('count-validation');
|
232 |
if ( ! $this->errors->get_error_codes()) {
|
233 |
-
|
234 |
-
|
235 |
-
window.location.href = "<?php echo add_query_arg('pmxe_nt', urlencode(__('Options updated', 'wp_all_export_plugin')), $this->baseUrl); ?>";
|
236 |
-
</script>
|
237 |
-
<?php
|
238 |
-
die();
|
239 |
}
|
240 |
|
241 |
}
|
@@ -342,7 +338,7 @@ class PMXE_Admin_Manage extends PMXE_Controller_Admin {
|
|
342 |
} else {
|
343 |
|
344 |
$uploads = wp_upload_dir();
|
345 |
-
|
346 |
$id = $this->input->get('id');
|
347 |
|
348 |
$export = new PMXE_Export_Record();
|
@@ -489,4 +485,42 @@ class PMXE_Admin_Manage extends PMXE_Controller_Admin {
|
|
489 |
}
|
490 |
}
|
491 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
492 |
}
|
218 |
|
219 |
PMXE_Plugin::$session->save_data();
|
220 |
|
221 |
+
if ( ! $this->errors->get_error_codes() && $this->input->post('record-count')) {
|
222 |
|
223 |
// deligate operation to other controller
|
224 |
$controller = new PMXE_Admin_Export();
|
230 |
|
231 |
$this->errors->remove('count-validation');
|
232 |
if ( ! $this->errors->get_error_codes()) {
|
233 |
+
wp_redirect(add_query_arg('pmxe_nt', urlencode(__('Options updated', 'wp_all_export_plugin')), $this->baseUrl));
|
234 |
+
die();
|
|
|
|
|
|
|
|
|
235 |
}
|
236 |
|
237 |
}
|
338 |
} else {
|
339 |
|
340 |
$uploads = wp_upload_dir();
|
341 |
+
|
342 |
$id = $this->input->get('id');
|
343 |
|
344 |
$export = new PMXE_Export_Record();
|
485 |
}
|
486 |
}
|
487 |
|
488 |
+
/**
|
489 |
+
* @param $post
|
490 |
+
* @return string
|
491 |
+
*/
|
492 |
+
protected function getFriendlyName($post)
|
493 |
+
{
|
494 |
+
$friendly_name = '';
|
495 |
+
$post_types = PMXE_Plugin::$session->get('cpt');
|
496 |
+
if (!empty($post_types)) {
|
497 |
+
if (in_array('users', $post_types)) {
|
498 |
+
$friendly_name = 'Users Export - ' . date("Y F d H:i");
|
499 |
+
return $friendly_name;
|
500 |
+
} elseif (in_array('shop_customer', $post_types)) {
|
501 |
+
$friendly_name = 'Customers Export - ' . date("Y F d H:i");
|
502 |
+
return $friendly_name;
|
503 |
+
} elseif (in_array('comments', $post_types)) {
|
504 |
+
$friendly_name = 'Comments Export - ' . date("Y F d H:i");
|
505 |
+
return $friendly_name;
|
506 |
+
} elseif (in_array('taxonomies', $post_types)) {
|
507 |
+
$tx = get_taxonomy($post['taxonomy_to_export']);
|
508 |
+
if (!empty($tx->labels->name)) {
|
509 |
+
$friendly_name = $tx->labels->name . ' Export - ' . date("Y F d H:i");
|
510 |
+
return $friendly_name;
|
511 |
+
} else {
|
512 |
+
$friendly_name = 'Taxonomy Terms Export - ' . date("Y F d H:i");
|
513 |
+
return $friendly_name;
|
514 |
+
}
|
515 |
+
} else {
|
516 |
+
$post_type_details = get_post_type_object(array_shift($post_types));
|
517 |
+
$friendly_name = $post_type_details->labels->name . ' Export - ' . date("Y F d H:i");
|
518 |
+
return $friendly_name;
|
519 |
+
}
|
520 |
+
} else {
|
521 |
+
$friendly_name = 'WP_Query Export - ' . date("Y F d H:i");
|
522 |
+
return $friendly_name;
|
523 |
+
}
|
524 |
+
}
|
525 |
+
|
526 |
}
|
controllers/controller/admin.php
CHANGED
@@ -34,7 +34,7 @@ abstract class PMXE_Controller_Admin extends PMXE_Controller {
|
|
34 |
parent::__construct();
|
35 |
|
36 |
// add special filter for url fields
|
37 |
-
$this->input->addFilter(
|
38 |
|
39 |
// enqueue required sripts and styles
|
40 |
global $wp_styles;
|
34 |
parent::__construct();
|
35 |
|
36 |
// add special filter for url fields
|
37 |
+
$this->input->addFilter('pmxe_url_filter');
|
38 |
|
39 |
// enqueue required sripts and styles
|
40 |
global $wp_styles;
|
dist/app.js
CHANGED
@@ -39626,7 +39626,10 @@ GoogleMerchants.controller('mainController', ['$scope', '$rootScope', '$timeout'
|
|
39626 |
dimensions: 'useWooCommerceProductValues',
|
39627 |
convertTo: 'cm',
|
39628 |
adjustPriceType: '%',
|
39629 |
-
weight: ''
|
|
|
|
|
|
|
39630 |
},
|
39631 |
template: {
|
39632 |
save: false,
|
@@ -40079,11 +40082,13 @@ GoogleMerchants.controller('googleCategorySelectorController', ['$scope', '$log'
|
|
40079 |
if(angular.isDefined($scope.mappings[currentChild.id])){
|
40080 |
// but not by the user
|
40081 |
if(!$scope.mappings[currentChild.id].byUser) {
|
40082 |
-
|
40083 |
id: catId,
|
40084 |
name: catName,
|
40085 |
byUser: false
|
40086 |
};
|
|
|
|
|
40087 |
}
|
40088 |
} else {
|
40089 |
$scope.mappings[currentChild.id] = {
|
@@ -40110,16 +40115,11 @@ GoogleMerchants.controller('googleCategorySelectorController', ['$scope', '$log'
|
|
40110 |
|
40111 |
$scope.visible = false;
|
40112 |
|
40113 |
-
var categoryData = {
|
40114 |
-
id: category.id,
|
40115 |
-
name: categoryName
|
40116 |
-
};
|
40117 |
-
|
40118 |
$scope.selectedCategory = categoryName;
|
40119 |
$scope.mappings[$scope.node.id] = {id: category.id, name: categoryName, byUser: true};
|
40120 |
|
40121 |
// New cascade logic
|
40122 |
-
selectCategoryRecursive(category.
|
40123 |
};
|
40124 |
|
40125 |
$scope.loadCategories = function(search) {
|
@@ -40571,7 +40571,7 @@ angular.module("basicInformation/basicInformation.tpl.html", []).run(["$template
|
|
40571 |
" <div class=\"wpallexport-collapsed-content\" id=\"basic-product-information\" ng-slide-down=\"basicInformation.open\" duration=\"0.5\">\n" +
|
40572 |
" <div class=\"wpallexport-collapsed-content-inner\">\n" +
|
40573 |
"\n" +
|
40574 |
-
" <h4>Item Title
|
40575 |
" <div class=\"input\">\n" +
|
40576 |
" <label><input type=\"radio\" ng-model=\"basicInformation.itemTitle\" value=\"productTitle\"/>Use the product title</label>\n" +
|
40577 |
" </div>\n" +
|
@@ -41226,6 +41226,9 @@ angular.module("shipping/shipping.tpl.html", []).run(["$templateCache", function
|
|
41226 |
" <span ng-if=\"!shipping.adjustShippingPrice\" style=\"width: 6px; display: inline-block;\">+</span>\n" +
|
41227 |
" <span ng-if=\"shipping.adjustShippingPrice\" style=\"width: 6px; display: inline-block;\">-</span>\n" +
|
41228 |
" Adjust Shipping Price</a>\n" +
|
|
|
|
|
|
|
41229 |
" <div ng-slide-down=\"shipping.adjustShippingPrice\" class=\"adjust-price\" duration=\"0.2\" style=\"margin-top: 5px; \">\n" +
|
41230 |
" <input type=\"text\" style=\"margin-top: 0; margin-right: 0;\" class=\"wpae-default-input\" ng-model=\"shipping.adjustShippingPriceValue\" droppable /><select style=\"margin-top:5px;\" ng-model=\"shipping.adjustPriceType\">\n" +
|
41231 |
" <option value=\"%\">%</option>\n" +
|
@@ -41248,7 +41251,7 @@ angular.module("shipping/shipping.tpl.html", []).run(["$templateCache", function
|
|
41248 |
" <input type=\"radio\" ng-model=\"shipping.dimensions\" value=\"useWooCommerceProductValues\"/>Use WooCommerce's product values and convert them to\n" +
|
41249 |
" <select ng-model=\"shipping.convertTo\" style=\"width: 175px; height: 30px; padding: 0 0 0 8px; margin-left: 5px; margin-top: 5px; \">\n" +
|
41250 |
" <option value=\"cm\">Centimeters (cm)</option>\n" +
|
41251 |
-
" <option value=\"
|
41252 |
" </select>\n" +
|
41253 |
" </label>\n" +
|
41254 |
" </div>\n" +
|
39626 |
dimensions: 'useWooCommerceProductValues',
|
39627 |
convertTo: 'cm',
|
39628 |
adjustPriceType: '%',
|
39629 |
+
weight: '',
|
39630 |
+
shippingHeight: '',
|
39631 |
+
shippingLength: '',
|
39632 |
+
shippingWidth: ''
|
39633 |
},
|
39634 |
template: {
|
39635 |
save: false,
|
40082 |
if(angular.isDefined($scope.mappings[currentChild.id])){
|
40083 |
// but not by the user
|
40084 |
if(!$scope.mappings[currentChild.id].byUser) {
|
40085 |
+
var newCategory = {
|
40086 |
id: catId,
|
40087 |
name: catName,
|
40088 |
byUser: false
|
40089 |
};
|
40090 |
+
|
40091 |
+
$scope.mappings[currentChild.id] = newCategory;
|
40092 |
}
|
40093 |
} else {
|
40094 |
$scope.mappings[currentChild.id] = {
|
40115 |
|
40116 |
$scope.visible = false;
|
40117 |
|
|
|
|
|
|
|
|
|
|
|
40118 |
$scope.selectedCategory = categoryName;
|
40119 |
$scope.mappings[$scope.node.id] = {id: category.id, name: categoryName, byUser: true};
|
40120 |
|
40121 |
// New cascade logic
|
40122 |
+
selectCategoryRecursive(category.id, categoryName, $scope.node);
|
40123 |
};
|
40124 |
|
40125 |
$scope.loadCategories = function(search) {
|
40571 |
" <div class=\"wpallexport-collapsed-content\" id=\"basic-product-information\" ng-slide-down=\"basicInformation.open\" duration=\"0.5\">\n" +
|
40572 |
" <div class=\"wpallexport-collapsed-content-inner\">\n" +
|
40573 |
"\n" +
|
40574 |
+
" <h4>Item Title <a style=\"margin-top: 7px;\" class=\"wpallexport-help\" tipsy=\"Google Merchant Center only shows the first 70 characters of titles and crops everything over 150 characters.\">?</a></h4>\n" +
|
40575 |
" <div class=\"input\">\n" +
|
40576 |
" <label><input type=\"radio\" ng-model=\"basicInformation.itemTitle\" value=\"productTitle\"/>Use the product title</label>\n" +
|
40577 |
" </div>\n" +
|
41226 |
" <span ng-if=\"!shipping.adjustShippingPrice\" style=\"width: 6px; display: inline-block;\">+</span>\n" +
|
41227 |
" <span ng-if=\"shipping.adjustShippingPrice\" style=\"width: 6px; display: inline-block;\">-</span>\n" +
|
41228 |
" Adjust Shipping Price</a>\n" +
|
41229 |
+
" <input type=\"hidden\" ng-model=\"shipping.shippingHeight\"/>\n" +
|
41230 |
+
" <input type=\"hidden\" ng-model=\"shipping.shippingLength\"/>\n" +
|
41231 |
+
" <input type=\"hidden\" ng-model=\"shipping.shippingWidth\"/>\n" +
|
41232 |
" <div ng-slide-down=\"shipping.adjustShippingPrice\" class=\"adjust-price\" duration=\"0.2\" style=\"margin-top: 5px; \">\n" +
|
41233 |
" <input type=\"text\" style=\"margin-top: 0; margin-right: 0;\" class=\"wpae-default-input\" ng-model=\"shipping.adjustShippingPriceValue\" droppable /><select style=\"margin-top:5px;\" ng-model=\"shipping.adjustPriceType\">\n" +
|
41234 |
" <option value=\"%\">%</option>\n" +
|
41251 |
" <input type=\"radio\" ng-model=\"shipping.dimensions\" value=\"useWooCommerceProductValues\"/>Use WooCommerce's product values and convert them to\n" +
|
41252 |
" <select ng-model=\"shipping.convertTo\" style=\"width: 175px; height: 30px; padding: 0 0 0 8px; margin-left: 5px; margin-top: 5px; \">\n" +
|
41253 |
" <option value=\"cm\">Centimeters (cm)</option>\n" +
|
41254 |
+
" <option value=\"in\">Inches (in)</option>\n" +
|
41255 |
" </select>\n" +
|
41256 |
" </label>\n" +
|
41257 |
" </div>\n" +
|
dist/app.min.js
CHANGED
@@ -4,7 +4,7 @@ debug:function(){var c=e("debug");return function(){a&&c.apply(b,arguments)}}()}
|
|
4 |
h=b.getSeconds(),i=b.getMilliseconds()),new Date(d,0,j.getDate()+k,f,g,h,i)}}return NaN}function Bd(a,b){return function(c,d){var e,g;if(z(c))return c;if(x(c)){if('"'===c.charAt(0)&&'"'===c.charAt(c.length-1)&&(c=c.substring(1,c.length-1)),hg.test(c))return new Date(c);if(a.lastIndex=0,e=a.exec(c))return e.shift(),g=d?{yyyy:d.getFullYear(),MM:d.getMonth()+1,dd:d.getDate(),HH:d.getHours(),mm:d.getMinutes(),ss:d.getSeconds(),sss:d.getMilliseconds()/1e3}:{yyyy:1970,MM:1,dd:1,HH:0,mm:0,ss:0,sss:0},f(e,function(a,c){c<b.length&&(g[b[c]]=+a)}),new Date(g.yyyy,g.MM-1,g.dd,g.HH,g.mm,g.ss||0,1e3*g.sss||0)}return NaN}}function Cd(a,b,c,d){return function(e,f,g,h,i,j,k){function l(a){return a&&!(a.getTime&&a.getTime()!==a.getTime())}function m(a){return u(a)&&!z(a)?c(a)||void 0:a}Dd(e,f,g,h),zd(e,f,g,h,i,j);var n,o=h&&h.$options.getOption("timezone");if(h.$$parserName=a,h.$parsers.push(function(a){if(h.$isEmpty(a))return null;if(b.test(a)){var d=c(a,n);return o&&(d=aa(d,o)),d}}),h.$formatters.push(function(a){if(a&&!z(a))throw Qg("datefmt","Expected `{0}` to be a date",a);return l(a)?(n=a,n&&o&&(n=aa(n,o,!0)),k("date")(a,d,o)):(n=null,"")}),u(g.min)||g.ngMin){var p;h.$validators.min=function(a){return!l(a)||t(p)||c(a)>=p},g.$observe("min",function(a){p=m(a),h.$validate()})}if(u(g.max)||g.ngMax){var q;h.$validators.max=function(a){return!l(a)||t(q)||c(a)<=q},g.$observe("max",function(a){q=m(a),h.$validate()})}}}function Dd(a,b,c,d){var e=b[0];(d.$$hasNativeValidators=v(e.validity))&&d.$parsers.push(function(a){var c=b.prop(Yd)||{};return c.badInput||c.typeMismatch?void 0:a})}function Ed(a){a.$$parserName="number",a.$parsers.push(function(b){return a.$isEmpty(b)?null:kg.test(b)?parseFloat(b):void 0}),a.$formatters.push(function(b){if(!a.$isEmpty(b)){if(!y(b))throw Qg("numfmt","Expected `{0}` to be a number",b);b=b.toString()}return b})}function Fd(a){return u(a)&&!y(a)&&(a=parseFloat(a)),oe(a)?void 0:a}function Gd(a){return(0|a)===a}function Hd(a){var b=a.toString(),c=b.indexOf(".");if(-1===c){if(-1<a&&a<1){var d=/e-(\d+)$/.exec(b);if(d)return Number(d[1])}return 0}return b.length-c-1}function Id(a,b,c){var d=Number(a),e=!Gd(d),f=!Gd(b),g=!Gd(c);if(e||f||g){var h=e?Hd(d):0,i=f?Hd(b):0,j=g?Hd(c):0,k=Math.max(h,i,j),l=Math.pow(10,k);d*=l,b*=l,c*=l,e&&(d=Math.round(d)),f&&(b=Math.round(b)),g&&(c=Math.round(c))}return(d-b)%c==0}function Jd(a,b,c,d,e,f){Dd(a,b,c,d),Ed(d),zd(a,b,c,d,e,f);var g,h;if((u(c.min)||c.ngMin)&&(d.$validators.min=function(a){return d.$isEmpty(a)||t(g)||a>=g},c.$observe("min",function(a){g=Fd(a),d.$validate()})),(u(c.max)||c.ngMax)&&(d.$validators.max=function(a){return d.$isEmpty(a)||t(h)||a<=h},c.$observe("max",function(a){h=Fd(a),d.$validate()})),u(c.step)||c.ngStep){var i;d.$validators.step=function(a,b){return d.$isEmpty(b)||t(i)||Id(b,g||0,i)},c.$observe("step",function(a){i=Fd(a),d.$validate()})}}function Kd(a,b,c,d,e,f){function g(a,d){b.attr(a,c[a]),c.$observe(a,d)}function h(a){if(l=Fd(a),!oe(d.$modelValue))if(k){var c=b.val();l>c&&(c=l,b.val(c)),d.$setViewValue(c)}else d.$validate()}function i(a){if(m=Fd(a),!oe(d.$modelValue))if(k){var c=b.val();m<c&&(b.val(m),c=m<l?l:m),d.$setViewValue(c)}else d.$validate()}function j(a){n=Fd(a),oe(d.$modelValue)||(k&&d.$viewValue!==b.val()?d.$setViewValue(b.val()):d.$validate())}Dd(a,b,c,d),Ed(d),zd(a,b,c,d,e,f);var k=d.$$hasNativeValidators&&"range"===b[0].type,l=k?0:void 0,m=k?100:void 0,n=k?1:void 0,o=b[0].validity,p=u(c.min),q=u(c.max),r=u(c.step),s=d.$render;d.$render=k&&u(o.rangeUnderflow)&&u(o.rangeOverflow)?function(){s(),d.$setViewValue(b.val())}:s,p&&(d.$validators.min=k?function(){return!0}:function(a,b){return d.$isEmpty(b)||t(l)||b>=l},g("min",h)),q&&(d.$validators.max=k?function(){return!0}:function(a,b){return d.$isEmpty(b)||t(m)||b<=m},g("max",i)),r&&(d.$validators.step=k?function(){return!o.stepMismatch}:function(a,b){return d.$isEmpty(b)||t(n)||Id(b,l||0,n)},g("step",j))}function Ld(a,b,c,d,e,f){zd(a,b,c,d,e,f),xd(d),d.$$parserName="url",d.$validators.url=function(a,b){var c=a||b;return d.$isEmpty(c)||ig.test(c)}}function Md(a,b,c,d,e,f){zd(a,b,c,d,e,f),xd(d),d.$$parserName="email",d.$validators.email=function(a,b){var c=a||b;return d.$isEmpty(c)||jg.test(c)}}function Nd(a,b,c,d){var e=!c.ngTrim||"false"!==re(c.ngTrim);t(c.name)&&b.attr("name",i());var f=function(a){var f;b[0].checked&&(f=c.value,e&&(f=re(f)),d.$setViewValue(f,a&&a.type))};b.on("click",f),d.$render=function(){var a=c.value;e&&(a=re(a)),b[0].checked=a===d.$viewValue},c.$observe("value",d.$render)}function Od(a,b,c,d,e){var f;if(u(d)){if(f=a(d),!f.constant)throw Qg("constexpr","Expected constant expression for `{0}`, but saw `{1}`.",c,d);return f(b)}return e}function Pd(a,b,c,d,e,f,g,h){var i=Od(h,a,"ngTrueValue",c.ngTrueValue,!0),j=Od(h,a,"ngFalseValue",c.ngFalseValue,!1),k=function(a){d.$setViewValue(b[0].checked,a&&a.type)};b.on("click",k),d.$render=function(){b[0].checked=d.$viewValue},d.$isEmpty=function(a){return!1===a},d.$formatters.push(function(a){return T(a,i)}),d.$parsers.push(function(a){return a?i:j})}function Qd(a,b){function c(a,b){if(!a||!a.length)return[];if(!b||!b.length)return a;var c=[];a:for(var d=0;d<a.length;d++){for(var e=a[d],f=0;f<b.length;f++)if(e===b[f])continue a;c.push(e)}return c}function d(a){return a&&a.split(" ")}function e(a){var b=a;return pe(a)?b=a.map(e).join(" "):v(a)&&(b=Object.keys(a).filter(function(b){return a[b]}).join(" ")),b}function g(a){var b=a;if(pe(a))b=a.map(g);else if(v(a)){var c=!1;b=Object.keys(a).filter(function(b){var d=a[b];return!c&&t(d)&&(c=!0),d}),c&&b.push(void 0)}return b}a="ngClass"+a;var h;return["$parse",function(i){return{restrict:"AC",link:function(j,k,l){function m(a){a=p(d(a),1),l.$addClass(a)}function n(a){a=p(d(a),-1),l.$removeClass(a)}function o(a,b){var e=d(a),f=d(b),g=c(e,f),h=c(f,e),i=p(g,-1),j=p(h,1);l.$addClass(j),l.$removeClass(i)}function p(a,b){var c=[];return f(a,function(a){(b>0||z[a])&&(z[a]=(z[a]||0)+b,z[a]===+(b>0)&&c.push(a))}),c.join(" ")}function q(a){a===b?m(t):n(t),A=a}function r(a){var b=e(a);b!==t&&s(b)}function s(a){A===b&&o(t,a),t=a}var t,u=l[a].trim(),v=":"===u.charAt(0)&&":"===u.charAt(1),w=v?g:e,x=i(u,w),y=v?r:s,z=k.data("$classCounts"),A=!0;z||(z=sa(),k.data("$classCounts",z)),"ngClass"!==a&&(h||(h=i("$index",function(a){return 1&a})),j.$watch(h,q)),j.$watch(x,y,v)}}}]}function Rd(a,b,c,d,e,f,g,h,i){this.$viewValue=Number.NaN,this.$modelValue=Number.NaN,this.$$rawModelValue=void 0,this.$validators={},this.$asyncValidators={},this.$parsers=[],this.$formatters=[],this.$viewChangeListeners=[],this.$untouched=!0,this.$touched=!1,this.$pristine=!0,this.$dirty=!1,this.$valid=!0,this.$invalid=!1,this.$error={},this.$$success={},this.$pending=void 0,this.$name=i(c.name||"",!1)(a),this.$$parentForm=cg,this.$options=Rg,this.$$parsedNgModel=e(c.ngModel),this.$$parsedNgModelAssign=this.$$parsedNgModel.assign,this.$$ngModelGet=this.$$parsedNgModel,this.$$ngModelSet=this.$$parsedNgModelAssign,this.$$pendingDebounce=null,this.$$parserValid=void 0,this.$$currentValidationRunId=0,Object.defineProperty(this,"$$scope",{value:a}),this.$$attr=c,this.$$element=d,this.$$animate=f,this.$$timeout=g,this.$$parse=e,this.$$q=h,this.$$exceptionHandler=b,ud(this),Sd(this)}function Sd(a){a.$$scope.$watch(function(b){var c=a.$$ngModelGet(b);if(c!==a.$modelValue&&(a.$modelValue===a.$modelValue||c===c)){a.$modelValue=a.$$rawModelValue=c,a.$$parserValid=void 0;for(var d=a.$formatters,e=d.length,f=c;e--;)f=d[e](f);a.$viewValue!==f&&(a.$$updateEmptyClasses(f),a.$viewValue=a.$$lastCommittedViewValue=f,a.$render(),a.$$runValidators(a.$modelValue,a.$viewValue,p))}return c})}function Td(a){this.$$options=a}function Ud(a,b){f(b,function(b,c){u(a[c])||(a[c]=b)})}function Vd(a,b){a.prop("selected",b),a.attr("selected",b)}var Wd={objectMaxDepth:5},Xd=/^\/(.+)\/([a-z]*)$/,Yd="validity",Zd=Object.prototype.hasOwnProperty,$d=function(a){return x(a)?a.toLowerCase():a},_d=function(a){return x(a)?a.toUpperCase():a},ae=function(a){return x(a)?a.replace(/[A-Z]/g,function(a){return String.fromCharCode(32|a.charCodeAt(0))}):a},be=function(a){return x(a)?a.replace(/[a-z]/g,function(a){return String.fromCharCode(-33&a.charCodeAt(0))}):a};"i"!=="I".toLowerCase()&&($d=ae,_d=be);var ce,de,ee,fe,ge=[].slice,he=[].splice,ie=[].push,je=Object.prototype.toString,ke=Object.getPrototypeOf,le=d("ng"),me=a.angular||(a.angular={}),ne=0;ce=a.document.documentMode;var oe=Number.isNaN||function(a){return a!==a};p.$inject=[],q.$inject=[];var pe=Array.isArray,qe=/^\[object (?:Uint8|Uint8Clamped|Uint16|Uint32|Int8|Int16|Int32|Float32|Float64)Array]$/,re=function(a){return x(a)?a.trim():a},se=function(a){return a.replace(/([-()[\]{}+?*.$^|,:#<!\\])/g,"\\$1").replace(/\x08/g,"\\x08")},te=function(){if(!u(te.rules)){var b=a.document.querySelector("[ng-csp]")||a.document.querySelector("[data-ng-csp]");if(b){var c=b.getAttribute("ng-csp")||b.getAttribute("data-ng-csp");te.rules={noUnsafeEval:!c||-1!==c.indexOf("no-unsafe-eval"),noInlineStyle:!c||-1!==c.indexOf("no-inline-style")}}else te.rules={noUnsafeEval:function(){try{return new Function(""),!1}catch(a){return!0}}(),noInlineStyle:!1}}return te.rules},ue=function(){if(u(ue.name_))return ue.name_;var b,c,d,e,f=we.length;for(c=0;c<f;++c)if(d=we[c],b=a.document.querySelector("["+d.replace(":","\\:")+"jq]")){e=b.getAttribute(d+"jq");break}return ue.name_=e},ve=/:/g,we=["ng-","data-ng-","ng:","x-ng-"],xe=function(b){var c=b.currentScript;if(!c)return!0;if(!(c instanceof a.HTMLScriptElement||c instanceof a.SVGScriptElement))return!1;var d=c.attributes;return[d.getNamedItem("src"),d.getNamedItem("href"),d.getNamedItem("xlink:href")].every(function(a){if(!a)return!0;if(!a.value)return!1;var c=b.createElement("a");if(c.href=a.value,b.location.origin===c.origin)return!0;switch(c.protocol){case"http:":case"https:":case"ftp:":case"blob:":case"file:":case"data:":return!0;default:return!1}})}(a.document),ye=/[A-Z]/g,ze=!1,Ae=1,Be=3,Ce=8,De=9,Ee=11,Fe={full:"1.6.6",major:1,minor:6,dot:6,codeName:"interdimensional-cable"};Ia.expando="ng339";var Ge=Ia.cache={},He=1;Ia._data=function(a){return this.cache[a[this.expando]]||{}};var Ie=/-([a-z])/g,Je=/^-ms-/,Ke={mouseleave:"mouseout",mouseenter:"mouseover"},Le=d("jqLite"),Me=/^<([\w-]+)\s*\/?>(?:<\/\1>|)$/,Ne=/<|&#?\w+;/,Oe=/<([\w:-]+)/,Pe=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:-]+)[^>]*)\/>/gi,Qe={option:[1,'<select multiple="multiple">',"</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};Qe.optgroup=Qe.option,Qe.tbody=Qe.tfoot=Qe.colgroup=Qe.caption=Qe.thead,Qe.th=Qe.td;var Re=a.Node.prototype.contains||function(a){return!!(16&this.compareDocumentPosition(a))},Se=Ia.prototype={ready:Ya,toString:function(){var a=[];return f(this,function(b){a.push(""+b)}),"["+a.join(", ")+"]"},eq:function(a){return de(a>=0?this[a]:this[this.length+a])},length:0,push:ie,sort:[].sort,splice:[].splice},Te={};f("multiple,selected,checked,disabled,readOnly,required,open".split(","),function(a){Te[$d(a)]=a});var Ue={};f("input,select,option,textarea,button,form,details".split(","),function(a){Ue[a]=!0});var Ve={ngMinlength:"minlength",ngMaxlength:"maxlength",ngMin:"min",ngMax:"max",ngPattern:"pattern",ngStep:"step"};f({data:Oa,removeData:Ma,hasData:Ea,cleanData:function(a){for(var b=0,c=a.length;b<c;b++)Ma(a[b])}},function(a,b){Ia[b]=a}),f({data:Oa,inheritedData:Ua,scope:function(a){return de.data(a,"$scope")||Ua(a.parentNode||a,["$isolateScope","$scope"])},isolateScope:function(a){return de.data(a,"$isolateScope")||de.data(a,"$isolateScopeNoTemplate")},controller:Ta,injector:function(a){return Ua(a,"$injector")},removeAttr:function(a,b){a.removeAttribute(b)},hasClass:Pa,css:function(a,b,c){if(b=za(b),!u(c))return a.style[b];a.style[b]=c},attr:function(a,b,c){var d,e=a.nodeType;if(e!==Be&&2!==e&&e!==Ce&&a.getAttribute){var f=$d(b),g=Te[f];if(!u(c))return d=a.getAttribute(b),g&&null!==d&&(d=f),null===d?void 0:d;null===c||!1===c&&g?a.removeAttribute(b):a.setAttribute(b,g?f:c)}},prop:function(a,b,c){if(!u(c))return a[b];a[b]=c},text:function(){function a(a,b){if(t(b)){var c=a.nodeType;return c===Ae||c===Be?a.textContent:""}a.textContent=b}return a.$dv="",a}(),val:function(a,b){if(t(b)){if(a.multiple&&"select"===O(a)){var c=[];return f(a.options,function(a){a.selected&&c.push(a.value||a.text)}),c}return a.value}a.value=b},html:function(a,b){if(t(b))return a.innerHTML;Ka(a,!0),a.innerHTML=b},empty:Va},function(a,b){Ia.prototype[b]=function(b,c){var d,e,f=this.length;if(a!==Va&&t(2===a.length&&a!==Pa&&a!==Ta?b:c)){if(v(b)){for(d=0;d<f;d++)if(a===Oa)a(this[d],b);else for(e in b)a(this[d],e,b[e]);return this}for(var g=a.$dv,h=t(g)?Math.min(f,1):f,i=0;i<h;i++){var j=a(this[i],b,c);g=g?g+j:j}return g}for(d=0;d<f;d++)a(this[d],b,c);return this}}),f({removeData:Ma,on:function(a,b,c,d){if(u(d))throw Le("onargs","jqLite#on() does not support the `selector` or `eventData` parameters");if(Da(a)){var e=Na(a,!0),f=e.events,g=e.handle;g||(g=e.handle=_a(a,f));for(var h=b.indexOf(" ")>=0?b.split(" "):[b],i=h.length,j=function(b,d,e){var h=f[b];h||(h=f[b]=[],h.specialHandlerWrapper=d,"$destroy"===b||e||a.addEventListener(b,g)),h.push(c)};i--;)b=h[i],Ke[b]?(j(Ke[b],bb),j(b,void 0,!0)):j(b)}},off:La,one:function(a,b,c){a=de(a),a.on(b,function d(){a.off(b,c),a.off(b,d)}),a.on(b,c)},replaceWith:function(a,b){var c,d=a.parentNode;Ka(a),f(new Ia(b),function(b){c?d.insertBefore(b,c.nextSibling):d.replaceChild(b,a),c=b})},children:function(a){var b=[];return f(a.childNodes,function(a){a.nodeType===Ae&&b.push(a)}),b},contents:function(a){return a.contentDocument||a.childNodes||[]},append:function(a,b){var c=a.nodeType;if(c===Ae||c===Ee){b=new Ia(b);for(var d=0,e=b.length;d<e;d++){var f=b[d];a.appendChild(f)}}},prepend:function(a,b){if(a.nodeType===Ae){var c=a.firstChild;f(new Ia(b),function(b){a.insertBefore(b,c)})}},wrap:function(a,b){Ha(a,de(b).eq(0).clone()[0])},remove:Wa,detach:function(a){Wa(a,!0)},after:function(a,b){var c=a,d=a.parentNode;if(d){b=new Ia(b);for(var e=0,f=b.length;e<f;e++){var g=b[e];d.insertBefore(g,c.nextSibling),c=g}}},addClass:Ra,removeClass:Qa,toggleClass:function(a,b,c){b&&f(b.split(" "),function(b){var d=c;t(d)&&(d=!Pa(a,b)),(d?Ra:Qa)(a,b)})},parent:function(a){var b=a.parentNode;return b&&b.nodeType!==Ee?b:null},next:function(a){return a.nextElementSibling},find:function(a,b){return a.getElementsByTagName?a.getElementsByTagName(b):[]},clone:Ja,triggerHandler:function(a,b,c){var d,e,g,h=b.type||b,i=Na(a),j=i&&i.events,k=j&&j[h];k&&(d={preventDefault:function(){this.defaultPrevented=!0},isDefaultPrevented:function(){return!0===this.defaultPrevented},stopImmediatePropagation:function(){this.immediatePropagationStopped=!0},isImmediatePropagationStopped:function(){return!0===this.immediatePropagationStopped},stopPropagation:p,type:h,target:a},b.type&&(d=l(d,b)),e=va(k),g=c?[d].concat(c):[d],f(e,function(b){d.isImmediatePropagationStopped()||b.apply(a,g)}))}},function(a,b){Ia.prototype[b]=function(b,c,d){for(var e,f=0,g=this.length;f<g;f++)t(e)?(e=a(this[f],b,c,d),u(e)&&(e=de(e))):Sa(e,a(this[f],b,c,d));return u(e)?e:this}}),Ia.prototype.bind=Ia.prototype.on,Ia.prototype.unbind=Ia.prototype.off;var We=Object.create(null);eb.prototype={_idx:function(a){return a===this._lastKey?this._lastIndex:(this._lastKey=a,this._lastIndex=this._keys.indexOf(a),this._lastIndex)},_transformKey:function(a){return oe(a)?We:a},get:function(a){a=this._transformKey(a);var b=this._idx(a);if(-1!==b)return this._values[b]},set:function(a,b){a=this._transformKey(a);var c=this._idx(a);-1===c&&(c=this._lastIndex=this._keys.length),this._keys[c]=a,this._values[c]=b},delete:function(a){a=this._transformKey(a);var b=this._idx(a);return-1!==b&&(this._keys.splice(b,1),this._values.splice(b,1),this._lastKey=NaN,this._lastIndex=-1,!0)}};var Xe=eb,Ye=[function(){this.$get=[function(){return Xe}]}],Ze=/^([^(]+?)=>/,$e=/^[^(]*\(\s*([^)]*)\)/m,_e=/,/,af=/^\s*(_?)(\S+?)\1\s*$/,bf=/((\/\/.*$)|(\/\*[\s\S]*?\*\/))/gm,cf=d("$injector");jb.$$annotate=ib;var df=d("$animate"),ef=1,ff=function(){this.$get=p},gf=function(){var a=new Xe,b=[];this.$get=["$$AnimateRunner","$rootScope",function(c,d){function e(a,b,c){var d=!1;return b&&(b=x(b)?b.split(" "):pe(b)?b:[],f(b,function(b){b&&(d=!0,a[b]=c)})),d}function g(){f(b,function(b){var c=a.get(b);if(c){var d=nb(b.attr("class")),e="",g="";f(c,function(a,b){a!==!!d[b]&&(a?e+=(e.length?" ":"")+b:g+=(g.length?" ":"")+b)}),f(b,function(a){e&&Ra(a,e),g&&Qa(a,g)}),a.delete(b)}}),b.length=0}function h(c,f,h){var i=a.get(c)||{},j=e(i,f,!0),k=e(i,h,!1);(j||k)&&(a.set(c,i),b.push(c),1===b.length&&d.$$postDigest(g))}return{enabled:p,on:p,off:p,pin:p,push:function(a,b,d,e){e&&e(),d=d||{},d.from&&a.css(d.from),d.to&&a.css(d.to),(d.addClass||d.removeClass)&&h(a,d.addClass,d.removeClass);var f=new c;return f.complete(),f}}}]},hf=["$provide",function(a){var b=this,c=null,d=null;this.$$registeredAnimations=Object.create(null),this.register=function(c,d){if(c&&"."!==c.charAt(0))throw df("notcsel","Expecting class selector starting with '.' got '{0}'.",c);var e=c+"-animation";b.$$registeredAnimations[c.substr(1)]=e,a.factory(e,d)},this.customFilter=function(a){return 1===arguments.length&&(d=B(a)?a:null),d},this.classNameFilter=function(a){if(1===arguments.length&&(c=a instanceof RegExp?a:null)){if(new RegExp("[(\\s|\\/)]ng-animate[(\\s|\\/)]").test(c.toString()))throw c=null,df("nongcls",'$animateProvider.classNameFilter(regex) prohibits accepting a regex value which matches/contains the "{0}" CSS class.',"ng-animate")}return c},this.$get=["$$animateQueue",function(a){function b(a,b,c){if(c){var d=mb(c);!d||d.parentNode||d.previousElementSibling||(c=null)}c?c.after(a):b.prepend(a)}return{on:a.on,off:a.off,pin:a.pin,enabled:a.enabled,cancel:function(a){a.end&&a.end()},enter:function(c,d,e,f){return d=d&&de(d),e=e&&de(e),d=d||e.parent(),b(c,d,e),a.push(c,"enter",ob(f))},move:function(c,d,e,f){return d=d&&de(d),e=e&&de(e),d=d||e.parent(),b(c,d,e),a.push(c,"move",ob(f))},leave:function(b,c){return a.push(b,"leave",ob(c),function(){b.remove()})},addClass:function(b,c,d){return d=ob(d),d.addClass=lb(d.addclass,c),a.push(b,"addClass",d)},removeClass:function(b,c,d){return d=ob(d),d.removeClass=lb(d.removeClass,c),a.push(b,"removeClass",d)},setClass:function(b,c,d,e){return e=ob(e),e.addClass=lb(e.addClass,c),e.removeClass=lb(e.removeClass,d),a.push(b,"setClass",e)},animate:function(b,c,d,e,f){return f=ob(f),f.from=f.from?l(f.from,c):c,f.to=f.to?l(f.to,d):d,e=e||"ng-inline-animate",f.tempClasses=lb(f.tempClasses,e),a.push(b,"animate",f)}}}]}],jf=function(){this.$get=["$$rAF",function(a){function b(b){c.push(b),c.length>1||a(function(){for(var a=0;a<c.length;a++)c[a]();c=[]})}var c=[];return function(){var a=!1;return b(function(){a=!0}),function(c){a?c():b(c)}}}]},kf=function(){this.$get=["$q","$sniffer","$$animateAsyncRun","$$isDocumentHidden","$timeout",function(a,b,c,d,e){function g(a){this.setHost(a);var b=c(),f=function(a){e(a,0,!1)};this._doneCallbacks=[],this._tick=function(a){d()?f(a):b(a)},this._state=0}return g.chain=function(a,b){function c(){if(d===a.length)return void b(!0);a[d](function(a){if(!1===a)return void b(!1);d++,c()})}var d=0;c()},g.all=function(a,b){function c(c){e=e&&c,++d===a.length&&b(e)}var d=0,e=!0;f(a,function(a){a.done(c)})},g.prototype={setHost:function(a){this.host=a||{}},done:function(a){2===this._state?a():this._doneCallbacks.push(a)},progress:p,getPromise:function(){if(!this.promise){var b=this;this.promise=a(function(a,c){b.done(function(b){!1===b?c():a()})})}return this.promise},then:function(a,b){return this.getPromise().then(a,b)},catch:function(a){return this.getPromise().catch(a)},finally:function(a){return this.getPromise().finally(a)},pause:function(){this.host.pause&&this.host.pause()},resume:function(){this.host.resume&&this.host.resume()},end:function(){this.host.end&&this.host.end(),this._resolve(!0)},cancel:function(){this.host.cancel&&this.host.cancel(),this._resolve(!1)},complete:function(a){var b=this;0===b._state&&(b._state=1,b._tick(function(){b._resolve(a)}))},_resolve:function(a){2!==this._state&&(f(this._doneCallbacks,function(b){b(a)}),this._doneCallbacks.length=0,this._state=2)}},g}]},lf=function(){this.$get=["$$rAF","$q","$$AnimateRunner",function(a,b,c){return function(b,d){function e(){return a(function(){f(),h||i.complete(),h=!0}),i}function f(){g.addClass&&(b.addClass(g.addClass),g.addClass=null),g.removeClass&&(b.removeClass(g.removeClass),g.removeClass=null),g.to&&(b.css(g.to),g.to=null)}var g=d||{};g.$$prepared||(g=R(g)),g.cleanupStyles&&(g.from=g.to=null),g.from&&(b.css(g.from),g.from=null);var h,i=new c;return{start:e,end:e}}}]},mf=d("$compile"),nf=new tb;ub.$inject=["$provide","$$sanitizeUriProvider"],vb.prototype.isFirstChange=function(){return this.previousValue===nf};var of=/^((?:x|data)[:\-_])/i,pf=/[:\-_]+(.)/g,qf=d("$controller"),rf=/^(\S+)(\s+as\s+([\w$]+))?$/,sf=function(){this.$get=["$document",function(a){return function(b){return b?!b.nodeType&&b instanceof de&&(b=b[0]):b=a[0].body,b.offsetWidth+1}}]},tf="application/json",uf={"Content-Type":tf+";charset=utf-8"},vf=/^\[|^\{(?!\{)/,wf={"[":/]$/,"{":/}$/},xf=/^\)]\}',?\n/,yf=d("$http"),zf=me.$interpolateMinErr=d("$interpolate");zf.throwNoconcat=function(a){throw zf("noconcat","Error while interpolating: {0}\nStrict Contextual Escaping disallows interpolations that concatenate multiple expressions when a trusted value is required. See http://docs.angularjs.org/api/ng.$sce",a)},zf.interr=function(a,b){return zf("interr","Can't interpolate: {0}\n{1}",a,b.toString())};var Af=function(){this.$get=function(){function a(a){var b=function(a){b.data=a,b.called=!0};return b.id=a,b}var b=me.callbacks,c={};return{createCallback:function(d){var e="_"+(b.$$counter++).toString(36),f="angular.callbacks."+e,g=a(e);return c[f]=b[e]=g,f},wasCalled:function(a){return c[a].called},getResponse:function(a){return c[a].data},removeCallback:function(a){var d=c[a];delete b[d.id],delete c[a]}}}},Bf=/^([^?#]*)(\?([^#]*))?(#(.*))?$/,Cf={http:80,https:443,ftp:21},Df=d("$location"),Ef=/^\s*[\\/]{2,}/,Ff={$$absUrl:"",$$html5:!1,$$replace:!1,absUrl:dc("$$absUrl"),url:function(a){if(t(a))return this.$$url;var b=Bf.exec(a);return(b[1]||""===a)&&this.path(decodeURIComponent(b[1])),(b[2]||b[1]||""===a)&&this.search(b[3]||""),this.hash(b[5]||""),this},protocol:dc("$$protocol"),host:dc("$$host"),port:dc("$$port"),path:ec("$$path",function(a){return a=null!==a?a.toString():"","/"===a.charAt(0)?a:"/"+a}),search:function(a,b){switch(arguments.length){case 0:return this.$$search;case 1:if(x(a)||y(a))a=a.toString(),this.$$search=da(a);else{if(!v(a))throw Df("isrcharg","The first argument of the `$location#search()` call must be a string or an object.");a=R(a,{}),f(a,function(b,c){null==b&&delete a[c]}),this.$$search=a}break;default:t(b)||null===b?delete this.$$search[a]:this.$$search[a]=b}return this.$$compose(),this},hash:ec("$$hash",function(a){return null!==a?a.toString():""}),replace:function(){return this.$$replace=!0,this}};f([cc,bc,ac],function(a){a.prototype=Object.create(Ff),a.prototype.state=function(b){if(!arguments.length)return this.$$state;if(a!==ac||!this.$$html5)throw Df("nostate","History API state support is available only in HTML5 mode and only in browsers supporting HTML5 History API");return this.$$state=t(b)?null:b,this.$$urlUpdatedByLocation=!0,this}});var Gf=d("$parse"),Hf={}.constructor.prototype.valueOf,If=sa();f("+ - * / % === !== == != < > <= >= && || ! = |".split(" "),function(a){If[a]=!0});var Jf={n:"\n",f:"\f",r:"\r",t:"\t",v:"\v","'":"'",'"':'"'},Kf=function(a){this.options=a};Kf.prototype={constructor:Kf,lex:function(a){for(this.text=a,this.index=0,this.tokens=[];this.index<this.text.length;){var b=this.text.charAt(this.index);if('"'===b||"'"===b)this.readString(b);else if(this.isNumber(b)||"."===b&&this.isNumber(this.peek()))this.readNumber();else if(this.isIdentifierStart(this.peekMultichar()))this.readIdent();else if(this.is(b,"(){}[].,;:?"))this.tokens.push({index:this.index,text:b}),this.index++;else if(this.isWhitespace(b))this.index++;else{var c=b+this.peek(),d=c+this.peek(2),e=If[b],f=If[c],g=If[d];if(e||f||g){var h=g?d:f?c:b;this.tokens.push({index:this.index,text:h,operator:!0}),this.index+=h.length}else this.throwError("Unexpected next character ",this.index,this.index+1)}}return this.tokens},is:function(a,b){return-1!==b.indexOf(a)},peek:function(a){var b=a||1;return this.index+b<this.text.length&&this.text.charAt(this.index+b)},isNumber:function(a){return"0"<=a&&a<="9"&&"string"==typeof a},isWhitespace:function(a){return" "===a||"\r"===a||"\t"===a||"\n"===a||"\v"===a||" "===a},isIdentifierStart:function(a){return this.options.isIdentifierStart?this.options.isIdentifierStart(a,this.codePointAt(a)):this.isValidIdentifierStart(a)},isValidIdentifierStart:function(a){return"a"<=a&&a<="z"||"A"<=a&&a<="Z"||"_"===a||"$"===a},isIdentifierContinue:function(a){return this.options.isIdentifierContinue?this.options.isIdentifierContinue(a,this.codePointAt(a)):this.isValidIdentifierContinue(a)},isValidIdentifierContinue:function(a,b){return this.isValidIdentifierStart(a,b)||this.isNumber(a)},codePointAt:function(a){return 1===a.length?a.charCodeAt(0):(a.charCodeAt(0)<<10)+a.charCodeAt(1)-56613888},peekMultichar:function(){var a=this.text.charAt(this.index),b=this.peek();if(!b)return a;var c=a.charCodeAt(0),d=b.charCodeAt(0);return c>=55296&&c<=56319&&d>=56320&&d<=57343?a+b:a},isExpOperator:function(a){return"-"===a||"+"===a||this.isNumber(a)},throwError:function(a,b,c){c=c||this.index;var d=u(b)?"s "+b+"-"+this.index+" ["+this.text.substring(b,c)+"]":" "+c;throw Gf("lexerr","Lexer Error: {0} at column{1} in expression [{2}].",a,d,this.text)},readNumber:function(){for(var a="",b=this.index;this.index<this.text.length;){var c=$d(this.text.charAt(this.index));if("."===c||this.isNumber(c))a+=c;else{var d=this.peek();if("e"===c&&this.isExpOperator(d))a+=c;else if(this.isExpOperator(c)&&d&&this.isNumber(d)&&"e"===a.charAt(a.length-1))a+=c;else{if(!this.isExpOperator(c)||d&&this.isNumber(d)||"e"!==a.charAt(a.length-1))break;this.throwError("Invalid exponent")}}this.index++}this.tokens.push({index:b,text:a,constant:!0,value:Number(a)})},readIdent:function(){var a=this.index;for(this.index+=this.peekMultichar().length;this.index<this.text.length;){var b=this.peekMultichar();if(!this.isIdentifierContinue(b))break;this.index+=b.length}this.tokens.push({index:a,text:this.text.slice(a,this.index),identifier:!0})},readString:function(a){var b=this.index;this.index++;for(var c="",d=a,e=!1;this.index<this.text.length;){var f=this.text.charAt(this.index);if(d+=f,e){if("u"===f){var g=this.text.substring(this.index+1,this.index+5);g.match(/[\da-f]{4}/i)||this.throwError("Invalid unicode escape [\\u"+g+"]"),this.index+=4,c+=String.fromCharCode(parseInt(g,16))}else{c+=Jf[f]||f}e=!1}else if("\\"===f)e=!0;else{if(f===a)return this.index++,void this.tokens.push({index:b,text:d,constant:!0,value:c});c+=f}this.index++}this.throwError("Unterminated quote",b)}};var Lf=function(a,b){this.lexer=a,this.options=b};Lf.Program="Program",Lf.ExpressionStatement="ExpressionStatement",Lf.AssignmentExpression="AssignmentExpression",Lf.ConditionalExpression="ConditionalExpression",Lf.LogicalExpression="LogicalExpression",Lf.BinaryExpression="BinaryExpression",Lf.UnaryExpression="UnaryExpression",Lf.CallExpression="CallExpression",Lf.MemberExpression="MemberExpression",Lf.Identifier="Identifier",Lf.Literal="Literal",Lf.ArrayExpression="ArrayExpression",Lf.Property="Property",Lf.ObjectExpression="ObjectExpression",Lf.ThisExpression="ThisExpression",Lf.LocalsExpression="LocalsExpression",Lf.NGValueParameter="NGValueParameter",Lf.prototype={ast:function(a){this.text=a,this.tokens=this.lexer.lex(a);var b=this.program();return 0!==this.tokens.length&&this.throwError("is an unexpected token",this.tokens[0]),b},program:function(){for(var a=[];;)if(this.tokens.length>0&&!this.peek("}",")",";","]")&&a.push(this.expressionStatement()),!this.expect(";"))return{type:Lf.Program,body:a}},expressionStatement:function(){return{type:Lf.ExpressionStatement,expression:this.filterChain()}},filterChain:function(){for(var a=this.expression();this.expect("|");)a=this.filter(a);return a},expression:function(){return this.assignment()},assignment:function(){var a=this.ternary();if(this.expect("=")){if(!oc(a))throw Gf("lval","Trying to assign a value to a non l-value");a={type:Lf.AssignmentExpression,left:a,right:this.assignment(),operator:"="}}return a},ternary:function(){var a,b,c=this.logicalOR();return this.expect("?")&&(a=this.expression(),this.consume(":"))?(b=this.expression(),{type:Lf.ConditionalExpression,test:c,alternate:a,consequent:b}):c},logicalOR:function(){for(var a=this.logicalAND();this.expect("||");)a={type:Lf.LogicalExpression,operator:"||",left:a,right:this.logicalAND()};return a},logicalAND:function(){for(var a=this.equality();this.expect("&&");)a={type:Lf.LogicalExpression,operator:"&&",left:a,right:this.equality()};return a},equality:function(){for(var a,b=this.relational();a=this.expect("==","!=","===","!==");)b={type:Lf.BinaryExpression,operator:a.text,left:b,right:this.relational()};return b},relational:function(){for(var a,b=this.additive();a=this.expect("<",">","<=",">=");)b={type:Lf.BinaryExpression,operator:a.text,left:b,right:this.additive()};return b},additive:function(){for(var a,b=this.multiplicative();a=this.expect("+","-");)b={type:Lf.BinaryExpression,operator:a.text,left:b,right:this.multiplicative()};return b},multiplicative:function(){for(var a,b=this.unary();a=this.expect("*","/","%");)b={type:Lf.BinaryExpression,operator:a.text,left:b,right:this.unary()};return b},unary:function(){var a;return(a=this.expect("+","-","!"))?{type:Lf.UnaryExpression,operator:a.text,prefix:!0,argument:this.unary()}:this.primary()},primary:function(){var a;this.expect("(")?(a=this.filterChain(),this.consume(")")):this.expect("[")?a=this.arrayDeclaration():this.expect("{")?a=this.object():this.selfReferential.hasOwnProperty(this.peek().text)?a=R(this.selfReferential[this.consume().text]):this.options.literals.hasOwnProperty(this.peek().text)?a={type:Lf.Literal,value:this.options.literals[this.consume().text]}:this.peek().identifier?a=this.identifier():this.peek().constant?a=this.constant():this.throwError("not a primary expression",this.peek());for(var b;b=this.expect("(","[",".");)"("===b.text?(a={type:Lf.CallExpression,callee:a,arguments:this.parseArguments()},this.consume(")")):"["===b.text?(a={type:Lf.MemberExpression,object:a,property:this.expression(),computed:!0},this.consume("]")):"."===b.text?a={type:Lf.MemberExpression,object:a,property:this.identifier(),computed:!1}:this.throwError("IMPOSSIBLE");return a},filter:function(a){for(var b=[a],c={type:Lf.CallExpression,callee:this.identifier(),arguments:b,filter:!0};this.expect(":");)b.push(this.expression());return c},parseArguments:function(){var a=[];if(")"!==this.peekToken().text)do{a.push(this.filterChain())}while(this.expect(","));return a},identifier:function(){var a=this.consume();return a.identifier||this.throwError("is not a valid identifier",a),{type:Lf.Identifier,name:a.text}},constant:function(){return{type:Lf.Literal,value:this.consume().value}},arrayDeclaration:function(){var a=[];if("]"!==this.peekToken().text)do{if(this.peek("]"))break;a.push(this.expression())}while(this.expect(","));return this.consume("]"),{type:Lf.ArrayExpression,elements:a}},object:function(){var a,b=[];if("}"!==this.peekToken().text)do{if(this.peek("}"))break;a={type:Lf.Property,kind:"init"},this.peek().constant?(a.key=this.constant(),a.computed=!1,this.consume(":"),a.value=this.expression()):this.peek().identifier?(a.key=this.identifier(),a.computed=!1,this.peek(":")?(this.consume(":"),a.value=this.expression()):a.value=a.key):this.peek("[")?(this.consume("["),a.key=this.expression(),this.consume("]"),a.computed=!0,
|
5 |
this.consume(":"),a.value=this.expression()):this.throwError("invalid key",this.peek()),b.push(a)}while(this.expect(","));return this.consume("}"),{type:Lf.ObjectExpression,properties:b}},throwError:function(a,b){throw Gf("syntax","Syntax Error: Token '{0}' {1} at column {2} of the expression [{3}] starting at [{4}].",b.text,a,b.index+1,this.text,this.text.substring(b.index))},consume:function(a){if(0===this.tokens.length)throw Gf("ueoe","Unexpected end of expression: {0}",this.text);var b=this.expect(a);return b||this.throwError("is unexpected, expecting ["+a+"]",this.peek()),b},peekToken:function(){if(0===this.tokens.length)throw Gf("ueoe","Unexpected end of expression: {0}",this.text);return this.tokens[0]},peek:function(a,b,c,d){return this.peekAhead(0,a,b,c,d)},peekAhead:function(a,b,c,d,e){if(this.tokens.length>a){var f=this.tokens[a],g=f.text;if(g===b||g===c||g===d||g===e||!b&&!c&&!d&&!e)return f}return!1},expect:function(a,b,c,d){var e=this.peek(a,b,c,d);return!!e&&(this.tokens.shift(),e)},selfReferential:{this:{type:Lf.ThisExpression},$locals:{type:Lf.LocalsExpression}}};var Mf=1,Nf=2;sc.prototype={compile:function(a){var b=this;this.state={nextId:0,filters:{},fn:{vars:[],body:[],own:{}},assign:{vars:[],body:[],own:{}},inputs:[]},mc(a,b.$filter);var c,d="";if(this.stage="assign",c=pc(a)){this.state.computing="assign";var e=this.nextId();this.recurse(c,e),this.return_(e),d="fn.assign="+this.generateFunction("assign","s,v,l")}var g=nc(a.body);b.stage="inputs",f(g,function(a,c){var d="fn"+c;b.state[d]={vars:[],body:[],own:{}},b.state.computing=d;var e=b.nextId();b.recurse(a,e),b.return_(e),b.state.inputs.push({name:d,isPure:a.isPure}),a.watchId=c}),this.state.computing="fn",this.stage="main",this.recurse(a);var h='"'+this.USE+" "+this.STRICT+'";\n'+this.filterPrefix()+"var fn="+this.generateFunction("fn","s,l,a,i")+d+this.watchFns()+"return fn;",i=new Function("$filter","getStringValue","ifDefined","plus",h)(this.$filter,hc,ic,jc);return this.state=this.stage=void 0,i},USE:"use",STRICT:"strict",watchFns:function(){var a=[],b=this.state.inputs,c=this;return f(b,function(b){a.push("var "+b.name+"="+c.generateFunction(b.name,"s")),b.isPure&&a.push(b.name,".isPure="+JSON.stringify(b.isPure)+";")}),b.length&&a.push("fn.inputs=["+b.map(function(a){return a.name}).join(",")+"];"),a.join("")},generateFunction:function(a,b){return"function("+b+"){"+this.varsPrefix(a)+this.body(a)+"};"},filterPrefix:function(){var a=[],b=this;return f(this.state.filters,function(c,d){a.push(c+"=$filter("+b.escape(d)+")")}),a.length?"var "+a.join(",")+";":""},varsPrefix:function(a){return this.state[a].vars.length?"var "+this.state[a].vars.join(",")+";":""},body:function(a){return this.state[a].body.join("")},recurse:function(a,b,c,d,e,g){var h,i,j,k,l,m=this;if(d=d||p,!g&&u(a.watchId))return b=b||this.nextId(),void this.if_("i",this.lazyAssign(b,this.computedMember("i",a.watchId)),this.lazyRecurse(a,b,c,d,e,!0));switch(a.type){case Lf.Program:f(a.body,function(b,c){m.recurse(b.expression,void 0,void 0,function(a){i=a}),c!==a.body.length-1?m.current().body.push(i,";"):m.return_(i)});break;case Lf.Literal:k=this.escape(a.value),this.assign(b,k),d(b||k);break;case Lf.UnaryExpression:this.recurse(a.argument,void 0,void 0,function(a){i=a}),k=a.operator+"("+this.ifDefined(i,0)+")",this.assign(b,k),d(k);break;case Lf.BinaryExpression:this.recurse(a.left,void 0,void 0,function(a){h=a}),this.recurse(a.right,void 0,void 0,function(a){i=a}),k="+"===a.operator?this.plus(h,i):"-"===a.operator?this.ifDefined(h,0)+a.operator+this.ifDefined(i,0):"("+h+")"+a.operator+"("+i+")",this.assign(b,k),d(k);break;case Lf.LogicalExpression:b=b||this.nextId(),m.recurse(a.left,b),m.if_("&&"===a.operator?b:m.not(b),m.lazyRecurse(a.right,b)),d(b);break;case Lf.ConditionalExpression:b=b||this.nextId(),m.recurse(a.test,b),m.if_(b,m.lazyRecurse(a.alternate,b),m.lazyRecurse(a.consequent,b)),d(b);break;case Lf.Identifier:b=b||this.nextId(),c&&(c.context="inputs"===m.stage?"s":this.assign(this.nextId(),this.getHasOwnProperty("l",a.name)+"?l:s"),c.computed=!1,c.name=a.name),m.if_("inputs"===m.stage||m.not(m.getHasOwnProperty("l",a.name)),function(){m.if_("inputs"===m.stage||"s",function(){e&&1!==e&&m.if_(m.isNull(m.nonComputedMember("s",a.name)),m.lazyAssign(m.nonComputedMember("s",a.name),"{}")),m.assign(b,m.nonComputedMember("s",a.name))})},b&&m.lazyAssign(b,m.nonComputedMember("l",a.name))),d(b);break;case Lf.MemberExpression:h=c&&(c.context=this.nextId())||this.nextId(),b=b||this.nextId(),m.recurse(a.object,h,void 0,function(){m.if_(m.notNull(h),function(){a.computed?(i=m.nextId(),m.recurse(a.property,i),m.getStringValue(i),e&&1!==e&&m.if_(m.not(m.computedMember(h,i)),m.lazyAssign(m.computedMember(h,i),"{}")),k=m.computedMember(h,i),m.assign(b,k),c&&(c.computed=!0,c.name=i)):(e&&1!==e&&m.if_(m.isNull(m.nonComputedMember(h,a.property.name)),m.lazyAssign(m.nonComputedMember(h,a.property.name),"{}")),k=m.nonComputedMember(h,a.property.name),m.assign(b,k),c&&(c.computed=!1,c.name=a.property.name))},function(){m.assign(b,"undefined")}),d(b)},!!e);break;case Lf.CallExpression:b=b||this.nextId(),a.filter?(i=m.filter(a.callee.name),j=[],f(a.arguments,function(a){var b=m.nextId();m.recurse(a,b),j.push(b)}),k=i+"("+j.join(",")+")",m.assign(b,k),d(b)):(i=m.nextId(),h={},j=[],m.recurse(a.callee,i,h,function(){m.if_(m.notNull(i),function(){f(a.arguments,function(b){m.recurse(b,a.constant?void 0:m.nextId(),void 0,function(a){j.push(a)})}),k=h.name?m.member(h.context,h.name,h.computed)+"("+j.join(",")+")":i+"("+j.join(",")+")",m.assign(b,k)},function(){m.assign(b,"undefined")}),d(b)}));break;case Lf.AssignmentExpression:i=this.nextId(),h={},this.recurse(a.left,void 0,h,function(){m.if_(m.notNull(h.context),function(){m.recurse(a.right,i),k=m.member(h.context,h.name,h.computed)+a.operator+i,m.assign(b,k),d(b||k)})},1);break;case Lf.ArrayExpression:j=[],f(a.elements,function(b){m.recurse(b,a.constant?void 0:m.nextId(),void 0,function(a){j.push(a)})}),k="["+j.join(",")+"]",this.assign(b,k),d(b||k);break;case Lf.ObjectExpression:j=[],l=!1,f(a.properties,function(a){a.computed&&(l=!0)}),l?(b=b||this.nextId(),this.assign(b,"{}"),f(a.properties,function(a){a.computed?(h=m.nextId(),m.recurse(a.key,h)):h=a.key.type===Lf.Identifier?a.key.name:""+a.key.value,i=m.nextId(),m.recurse(a.value,i),m.assign(m.member(b,h,a.computed),i)})):(f(a.properties,function(b){m.recurse(b.value,a.constant?void 0:m.nextId(),void 0,function(a){j.push(m.escape(b.key.type===Lf.Identifier?b.key.name:""+b.key.value)+":"+a)})}),k="{"+j.join(",")+"}",this.assign(b,k)),d(b||k);break;case Lf.ThisExpression:this.assign(b,"s"),d(b||"s");break;case Lf.LocalsExpression:this.assign(b,"l"),d(b||"l");break;case Lf.NGValueParameter:this.assign(b,"v"),d(b||"v")}},getHasOwnProperty:function(a,b){var c=a+"."+b,d=this.current().own;return d.hasOwnProperty(c)||(d[c]=this.nextId(!1,a+"&&("+this.escape(b)+" in "+a+")")),d[c]},assign:function(a,b){if(a)return this.current().body.push(a,"=",b,";"),a},filter:function(a){return this.state.filters.hasOwnProperty(a)||(this.state.filters[a]=this.nextId(!0)),this.state.filters[a]},ifDefined:function(a,b){return"ifDefined("+a+","+this.escape(b)+")"},plus:function(a,b){return"plus("+a+","+b+")"},return_:function(a){this.current().body.push("return ",a,";")},if_:function(a,b,c){if(!0===a)b();else{var d=this.current().body;d.push("if(",a,"){"),b(),d.push("}"),c&&(d.push("else{"),c(),d.push("}"))}},not:function(a){return"!("+a+")"},isNull:function(a){return a+"==null"},notNull:function(a){return a+"!=null"},nonComputedMember:function(a,b){var c=/^[$_a-zA-Z][$_a-zA-Z0-9]*$/,d=/[^$_a-zA-Z0-9]/g;return c.test(b)?a+"."+b:a+'["'+b.replace(d,this.stringEscapeFn)+'"]'},computedMember:function(a,b){return a+"["+b+"]"},member:function(a,b,c){return c?this.computedMember(a,b):this.nonComputedMember(a,b)},getStringValue:function(a){this.assign(a,"getStringValue("+a+")")},lazyRecurse:function(a,b,c,d,e,f){var g=this;return function(){g.recurse(a,b,c,d,e,f)}},lazyAssign:function(a,b){var c=this;return function(){c.assign(a,b)}},stringEscapeRegex:/[^ a-zA-Z0-9]/g,stringEscapeFn:function(a){return"\\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)},escape:function(a){if(x(a))return"'"+a.replace(this.stringEscapeRegex,this.stringEscapeFn)+"'";if(y(a))return a.toString();if(!0===a)return"true";if(!1===a)return"false";if(null===a)return"null";if(void 0===a)return"undefined";throw Gf("esc","IMPOSSIBLE")},nextId:function(a,b){var c="v"+this.state.nextId++;return a||this.current().vars.push(c+(b?"="+b:"")),c},current:function(){return this.state[this.state.computing]}},tc.prototype={compile:function(a){var b=this;mc(a,b.$filter);var c,d;(c=pc(a))&&(d=this.recurse(c));var e,g=nc(a.body);g&&(e=[],f(g,function(a,c){var d=b.recurse(a);d.isPure=a.isPure,a.input=d,e.push(d),a.watchId=c}));var h=[];f(a.body,function(a){h.push(b.recurse(a.expression))});var i=0===a.body.length?p:1===a.body.length?h[0]:function(a,b){var c;return f(h,function(d){c=d(a,b)}),c};return d&&(i.assign=function(a,b,c){return d(a,c,b)}),e&&(i.inputs=e),i},recurse:function(a,b,c){var d,e,g,h=this;if(a.input)return this.inputs(a.input,a.watchId);switch(a.type){case Lf.Literal:return this.value(a.value,b);case Lf.UnaryExpression:return e=this.recurse(a.argument),this["unary"+a.operator](e,b);case Lf.BinaryExpression:case Lf.LogicalExpression:return d=this.recurse(a.left),e=this.recurse(a.right),this["binary"+a.operator](d,e,b);case Lf.ConditionalExpression:return this["ternary?:"](this.recurse(a.test),this.recurse(a.alternate),this.recurse(a.consequent),b);case Lf.Identifier:return h.identifier(a.name,b,c);case Lf.MemberExpression:return d=this.recurse(a.object,!1,!!c),a.computed||(e=a.property.name),a.computed&&(e=this.recurse(a.property)),a.computed?this.computedMember(d,e,b,c):this.nonComputedMember(d,e,b,c);case Lf.CallExpression:return g=[],f(a.arguments,function(a){g.push(h.recurse(a))}),a.filter&&(e=this.$filter(a.callee.name)),a.filter||(e=this.recurse(a.callee,!0)),a.filter?function(a,c,d,f){for(var h=[],i=0;i<g.length;++i)h.push(g[i](a,c,d,f));var j=e.apply(void 0,h,f);return b?{context:void 0,name:void 0,value:j}:j}:function(a,c,d,f){var h,i=e(a,c,d,f);if(null!=i.value){for(var j=[],k=0;k<g.length;++k)j.push(g[k](a,c,d,f));h=i.value.apply(i.context,j)}return b?{value:h}:h};case Lf.AssignmentExpression:return d=this.recurse(a.left,!0,1),e=this.recurse(a.right),function(a,c,f,g){var h=d(a,c,f,g),i=e(a,c,f,g);return h.context[h.name]=i,b?{value:i}:i};case Lf.ArrayExpression:return g=[],f(a.elements,function(a){g.push(h.recurse(a))}),function(a,c,d,e){for(var f=[],h=0;h<g.length;++h)f.push(g[h](a,c,d,e));return b?{value:f}:f};case Lf.ObjectExpression:return g=[],f(a.properties,function(a){a.computed?g.push({key:h.recurse(a.key),computed:!0,value:h.recurse(a.value)}):g.push({key:a.key.type===Lf.Identifier?a.key.name:""+a.key.value,computed:!1,value:h.recurse(a.value)})}),function(a,c,d,e){for(var f={},h=0;h<g.length;++h)g[h].computed?f[g[h].key(a,c,d,e)]=g[h].value(a,c,d,e):f[g[h].key]=g[h].value(a,c,d,e);return b?{value:f}:f};case Lf.ThisExpression:return function(a){return b?{value:a}:a};case Lf.LocalsExpression:return function(a,c){return b?{value:c}:c};case Lf.NGValueParameter:return function(a,c,d){return b?{value:d}:d}}},"unary+":function(a,b){return function(c,d,e,f){var g=a(c,d,e,f);return g=u(g)?+g:0,b?{value:g}:g}},"unary-":function(a,b){return function(c,d,e,f){var g=a(c,d,e,f);return g=u(g)?-g:-0,b?{value:g}:g}},"unary!":function(a,b){return function(c,d,e,f){var g=!a(c,d,e,f);return b?{value:g}:g}},"binary+":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g),i=b(d,e,f,g),j=jc(h,i);return c?{value:j}:j}},"binary-":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g),i=b(d,e,f,g),j=(u(h)?h:0)-(u(i)?i:0);return c?{value:j}:j}},"binary*":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)*b(d,e,f,g);return c?{value:h}:h}},"binary/":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)/b(d,e,f,g);return c?{value:h}:h}},"binary%":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)%b(d,e,f,g);return c?{value:h}:h}},"binary===":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)===b(d,e,f,g);return c?{value:h}:h}},"binary!==":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)!==b(d,e,f,g);return c?{value:h}:h}},"binary==":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)==b(d,e,f,g);return c?{value:h}:h}},"binary!=":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)!=b(d,e,f,g);return c?{value:h}:h}},"binary<":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)<b(d,e,f,g);return c?{value:h}:h}},"binary>":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)>b(d,e,f,g);return c?{value:h}:h}},"binary<=":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)<=b(d,e,f,g);return c?{value:h}:h}},"binary>=":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)>=b(d,e,f,g);return c?{value:h}:h}},"binary&&":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)&&b(d,e,f,g);return c?{value:h}:h}},"binary||":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)||b(d,e,f,g);return c?{value:h}:h}},"ternary?:":function(a,b,c,d){return function(e,f,g,h){var i=a(e,f,g,h)?b(e,f,g,h):c(e,f,g,h);return d?{value:i}:i}},value:function(a,b){return function(){return b?{context:void 0,name:void 0,value:a}:a}},identifier:function(a,b,c){return function(d,e,f,g){var h=e&&a in e?e:d;c&&1!==c&&h&&null==h[a]&&(h[a]={});var i=h?h[a]:void 0;return b?{context:h,name:a,value:i}:i}},computedMember:function(a,b,c,d){return function(e,f,g,h){var i,j,k=a(e,f,g,h);return null!=k&&(i=b(e,f,g,h),i=hc(i),d&&1!==d&&k&&!k[i]&&(k[i]={}),j=k[i]),c?{context:k,name:i,value:j}:j}},nonComputedMember:function(a,b,c,d){return function(e,f,g,h){var i=a(e,f,g,h);d&&1!==d&&i&&null==i[b]&&(i[b]={});var j=null!=i?i[b]:void 0;return c?{context:i,name:b,value:j}:j}},inputs:function(a,b){return function(c,d,e,f){return f?f[b]:a(c,d,e)}}},uc.prototype={constructor:uc,parse:function(a){var b=this.ast.ast(a),c=this.astCompiler.compile(b);return c.literal=qc(b),c.constant=rc(b),c}};var Of=d("$sce"),Pf={HTML:"html",CSS:"css",URL:"url",RESOURCE_URL:"resourceUrl",JS:"js"},Qf=/_([a-z])/g,Rf=d("$compile"),Sf=a.document.createElement("a"),Tf=Pc(a.location.href);Sc.$inject=["$document"],Uc.$inject=["$provide"];var Uf=22,Vf=".",Wf="0";Zc.$inject=["$locale"],$c.$inject=["$locale"];var Xf={yyyy:dd("FullYear",4,0,!1,!0),yy:dd("FullYear",2,0,!0,!0),y:dd("FullYear",1,0,!1,!0),MMMM:ed("Month"),MMM:ed("Month",!0),MM:dd("Month",2,1),M:dd("Month",1,1),LLLL:ed("Month",!1,!0),dd:dd("Date",2),d:dd("Date",1),HH:dd("Hours",2),H:dd("Hours",1),hh:dd("Hours",2,-12),h:dd("Hours",1,-12),mm:dd("Minutes",2),m:dd("Minutes",1),ss:dd("Seconds",2),s:dd("Seconds",1),sss:dd("Milliseconds",3),EEEE:ed("Day"),EEE:ed("Day",!0),a:jd,Z:fd,ww:id(2),w:id(1),G:kd,GG:kd,GGG:kd,GGGG:ld},Yf=/((?:[^yMLdHhmsaZEwG']+)|(?:'(?:[^']|'')*')|(?:E+|y+|M+|L+|d+|H+|h+|m+|s+|a|Z|G+|w+))([\s\S]*)/,Zf=/^-?\d+$/;md.$inject=["$locale"];var $f=r($d),_f=r(_d);qd.$inject=["$parse"];var ag=r({restrict:"E",compile:function(a,b){if(!b.href&&!b.xlinkHref)return function(a,b){if("a"===b[0].nodeName.toLowerCase()){var c="[object SVGAnimatedString]"===je.call(b.prop("href"))?"xlink:href":"href";b.on("click",function(a){b.attr(c)||a.preventDefault()})}}}}),bg={};f(Te,function(a,b){function c(a,c,e){a.$watch(e[d],function(a){e.$set(b,!!a)})}if("multiple"!==a){var d=wb("ng-"+b),e=c;"checked"===a&&(e=function(a,b,e){e.ngModel!==e[d]&&c(a,b,e)}),bg[d]=function(){return{restrict:"A",priority:100,link:e}}}}),f(Ve,function(a,b){bg[b]=function(){return{priority:100,link:function(a,c,d){if("ngPattern"===b&&"/"===d.ngPattern.charAt(0)){var e=d.ngPattern.match(Xd);if(e)return void d.$set("ngPattern",new RegExp(e[1],e[2]))}a.$watch(d[b],function(a){d.$set(b,a)})}}}}),f(["src","srcset","href"],function(a){var b=wb("ng-"+a);bg[b]=function(){return{priority:99,link:function(c,d,e){var f=a,g=a;"href"===a&&"[object SVGAnimatedString]"===je.call(d.prop("href"))&&(g="xlinkHref",e.$attr[g]="xlink:href",f=null),e.$observe(b,function(b){if(!b)return void("href"===a&&e.$set(g,null));e.$set(g,b),ce&&f&&d.prop(f,e[g])})}}}});var cg={$addControl:p,$$renameControl:sd,$removeControl:p,$setValidity:p,$setDirty:p,$setPristine:p,$setSubmitted:p},dg="ng-pending";td.$inject=["$element","$attrs","$scope","$animate","$interpolate"],td.prototype={$rollbackViewValue:function(){f(this.$$controls,function(a){a.$rollbackViewValue()})},$commitViewValue:function(){f(this.$$controls,function(a){a.$commitViewValue()})},$addControl:function(a){pa(a.$name,"input"),this.$$controls.push(a),a.$name&&(this[a.$name]=a),a.$$parentForm=this},$$renameControl:function(a,b){var c=a.$name;this[c]===a&&delete this[c],this[b]=a,a.$name=b},$removeControl:function(a){a.$name&&this[a.$name]===a&&delete this[a.$name],f(this.$pending,function(b,c){this.$setValidity(c,null,a)},this),f(this.$error,function(b,c){this.$setValidity(c,null,a)},this),f(this.$$success,function(b,c){this.$setValidity(c,null,a)},this),Q(this.$$controls,a),a.$$parentForm=cg},$setDirty:function(){this.$$animate.removeClass(this.$$element,Og),this.$$animate.addClass(this.$$element,Pg),this.$dirty=!0,this.$pristine=!1,this.$$parentForm.$setDirty()},$setPristine:function(){this.$$animate.setClass(this.$$element,Og,Pg+" ng-submitted"),this.$dirty=!1,this.$pristine=!0,this.$submitted=!1,f(this.$$controls,function(a){a.$setPristine()})},$setUntouched:function(){f(this.$$controls,function(a){a.$setUntouched()})},$setSubmitted:function(){this.$$animate.addClass(this.$$element,"ng-submitted"),this.$submitted=!0,this.$$parentForm.$setSubmitted()}},vd({clazz:td,set:function(a,b,c){var d=a[b];if(d){-1===d.indexOf(c)&&d.push(c)}else a[b]=[c]},unset:function(a,b,c){var d=a[b];d&&(Q(d,c),0===d.length&&delete a[b])}});var eg=function(a){return["$timeout","$parse",function(b,c){function d(a){return""===a?c('this[""]').assign:c(a).assign||p}return{name:"form",restrict:a?"EAC":"E",require:["form","^^?form"],controller:td,compile:function(c,e){c.addClass(Og).addClass(Mg);var f=e.name?"name":!(!a||!e.ngForm)&&"ngForm";return{pre:function(a,c,e,g){var h=g[0];if(!("action"in e)){var i=function(b){a.$apply(function(){h.$commitViewValue(),h.$setSubmitted()}),b.preventDefault()};c[0].addEventListener("submit",i),c.on("$destroy",function(){b(function(){c[0].removeEventListener("submit",i)},0,!1)})}(g[1]||h.$$parentForm).$addControl(h);var j=f?d(h.$name):p;f&&(j(a,h),e.$observe(f,function(b){h.$name!==b&&(j(a,void 0),h.$$parentForm.$$renameControl(h,b),(j=d(h.$name))(a,h))})),c.on("$destroy",function(){h.$$parentForm.$removeControl(h),j(a,void 0),l(h,cg)})}}}}}]},fg=eg(),gg=eg(!0),hg=/^\d{4,}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+(?:[+-][0-2]\d:[0-5]\d|Z)$/,ig=/^[a-z][a-z\d.+-]*:\/*(?:[^:@]+(?::[^@]+)?@)?(?:[^\s:\/?#]+|\[[a-f\d:]+])(?::\d+)?(?:\/[^?#]*)?(?:\?[^#]*)?(?:#.*)?$/i,jg=/^(?=.{1,254}$)(?=.{1,64}@)[-!#$%&'*+\/0-9=?A-Z^_`a-z{|}~]+(\.[-!#$%&'*+\/0-9=?A-Z^_`a-z{|}~]+)*@[A-Za-z0-9]([A-Za-z0-9-]{0,61}[A-Za-z0-9])?(\.[A-Za-z0-9]([A-Za-z0-9-]{0,61}[A-Za-z0-9])?)*$/,kg=/^\s*(-|\+)?(\d+|(\d*(\.\d*)))([eE][+-]?\d+)?\s*$/,lg=/^(\d{4,})-(\d{2})-(\d{2})$/,mg=/^(\d{4,})-(\d\d)-(\d\d)T(\d\d):(\d\d)(?::(\d\d)(\.\d{1,3})?)?$/,ng=/^(\d{4,})-W(\d\d)$/,og=/^(\d{4,})-(\d\d)$/,pg=/^(\d\d):(\d\d)(?::(\d\d)(\.\d{1,3})?)?$/,qg="keydown wheel mousedown",rg=sa();f("date,datetime-local,month,time,week".split(","),function(a){rg[a]=!0});var sg={text:yd,date:Cd("date",lg,Bd(lg,["yyyy","MM","dd"]),"yyyy-MM-dd"),"datetime-local":Cd("datetimelocal",mg,Bd(mg,["yyyy","MM","dd","HH","mm","ss","sss"]),"yyyy-MM-ddTHH:mm:ss.sss"),time:Cd("time",pg,Bd(pg,["HH","mm","ss","sss"]),"HH:mm:ss.sss"),week:Cd("week",ng,Ad,"yyyy-Www"),month:Cd("month",og,Bd(og,["yyyy","MM"]),"yyyy-MM"),number:Jd,url:Ld,email:Md,radio:Nd,range:Kd,checkbox:Pd,hidden:p,button:p,submit:p,reset:p,file:p},tg=["$browser","$sniffer","$filter","$parse",function(a,b,c,d){return{restrict:"E",require:["?ngModel"],link:{pre:function(e,f,g,h){h[0]&&(sg[$d(g.type)]||sg.text)(e,f,g,h[0],b,a,c,d)}}}}],ug=/^(true|false|\d+)$/,vg=function(){function a(a,b,c){var d=u(c)?c:9===ce?"":null;a.prop("value",d),b.$set("value",c)}return{restrict:"A",priority:100,compile:function(b,c){return ug.test(c.ngValue)?function(b,c,d){a(c,d,b.$eval(d.ngValue))}:function(b,c,d){b.$watch(d.ngValue,function(b){a(c,d,b)})}}}},wg=["$compile",function(a){return{restrict:"AC",compile:function(b){return a.$$addBindingClass(b),function(b,c,d){a.$$addBindingInfo(c,d.ngBind),c=c[0],b.$watch(d.ngBind,function(a){c.textContent=ta(a)})}}}}],xg=["$interpolate","$compile",function(a,b){return{compile:function(c){return b.$$addBindingClass(c),function(c,d,e){var f=a(d.attr(e.$attr.ngBindTemplate));b.$$addBindingInfo(d,f.expressions),d=d[0],e.$observe("ngBindTemplate",function(a){d.textContent=t(a)?"":a})}}}}],yg=["$sce","$parse","$compile",function(a,b,c){return{restrict:"A",compile:function(d,e){var f=b(e.ngBindHtml),g=b(e.ngBindHtml,function(b){return a.valueOf(b)});return c.$$addBindingClass(d),function(b,d,e){c.$$addBindingInfo(d,e.ngBindHtml),b.$watch(g,function(){var c=f(b);d.html(a.getTrustedHtml(c)||"")})}}}}],zg=r({restrict:"A",require:"ngModel",link:function(a,b,c,d){d.$viewChangeListeners.push(function(){a.$eval(c.ngChange)})}}),Ag=Qd("",!0),Bg=Qd("Odd",0),Cg=Qd("Even",1),Dg=rd({compile:function(a,b){b.$set("ngCloak",void 0),a.removeClass("ng-cloak")}}),Eg=[function(){return{restrict:"A",scope:!0,controller:"@",priority:500}}],Fg={},Gg={blur:!0,focus:!0};f("click dblclick mousedown mouseup mouseover mouseout mousemove mouseenter mouseleave keydown keyup keypress submit focus blur copy cut paste".split(" "),function(a){var b=wb("ng-"+a);Fg[b]=["$parse","$rootScope",function(c,d){return{restrict:"A",compile:function(e,f){var g=c(f[b]);return function(b,c){c.on(a,function(c){var e=function(){g(b,{$event:c})};Gg[a]&&d.$$phase?b.$evalAsync(e):b.$apply(e)})}}}}]});var Hg=["$animate","$compile",function(a,b){return{multiElement:!0,transclude:"element",priority:600,terminal:!0,restrict:"A",$$tlb:!0,link:function(c,d,e,f,g){var h,i,j;c.$watch(e.ngIf,function(c){c?i||g(function(c,f){i=f,c[c.length++]=b.$$createComment("end ngIf",e.ngIf),h={clone:c},a.enter(c,d.parent(),d)}):(j&&(j.remove(),j=null),i&&(i.$destroy(),i=null),h&&(j=ra(h.clone),a.leave(j).done(function(a){!1!==a&&(j=null)}),h=null))})}}}],Ig=["$templateRequest","$anchorScroll","$animate",function(a,b,c){return{restrict:"ECA",priority:400,terminal:!0,transclude:"element",controller:me.noop,compile:function(d,e){var f=e.ngInclude||e.src,g=e.onload||"",h=e.autoscroll;return function(d,e,i,j,k){var l,m,n,o=0,p=function(){m&&(m.remove(),m=null),l&&(l.$destroy(),l=null),n&&(c.leave(n).done(function(a){!1!==a&&(m=null)}),m=n,n=null)};d.$watch(f,function(f){var i=function(a){!1===a||!u(h)||h&&!d.$eval(h)||b()},m=++o;f?(a(f,!0).then(function(a){if(!d.$$destroyed&&m===o){var b=d.$new();j.template=a;var h=k(b,function(a){p(),c.enter(a,null,e).done(i)});l=b,n=h,l.$emit("$includeContentLoaded",f),d.$eval(g)}},function(){d.$$destroyed||m===o&&(p(),d.$emit("$includeContentError",f))}),d.$emit("$includeContentRequested",f)):(p(),j.template=null)})}}}}],Jg=["$compile",function(b){return{restrict:"ECA",priority:-400,require:"ngInclude",link:function(c,d,e,f){if(je.call(d[0]).match(/SVG/))return d.empty(),void b(Fa(f.template,a.document).childNodes)(c,function(a){d.append(a)},{futureParentElement:d});d.html(f.template),b(d.contents())(c)}}}],Kg=rd({priority:450,compile:function(){return{pre:function(a,b,c){a.$eval(c.ngInit)}}}}),Lg=function(){return{restrict:"A",priority:100,require:"ngModel",link:function(a,b,c,d){var e=c.ngList||", ",g="false"!==c.ngTrim,h=g?re(e):e,i=function(a){if(!t(a)){var b=[];return a&&f(a.split(h),function(a){a&&b.push(g?re(a):a)}),b}};d.$parsers.push(i),d.$formatters.push(function(a){if(pe(a))return a.join(e)}),d.$isEmpty=function(a){return!a||!a.length}}}},Mg="ng-valid",Ng="ng-invalid",Og="ng-pristine",Pg="ng-dirty",Qg=d("ngModel");Rd.$inject=["$scope","$exceptionHandler","$attrs","$element","$parse","$animate","$timeout","$q","$interpolate"],Rd.prototype={$$initGetterSetters:function(){if(this.$options.getOption("getterSetter")){var a=this.$$parse(this.$$attr.ngModel+"()"),b=this.$$parse(this.$$attr.ngModel+"($$$p)");this.$$ngModelGet=function(b){var c=this.$$parsedNgModel(b);return B(c)&&(c=a(b)),c},this.$$ngModelSet=function(a,c){B(this.$$parsedNgModel(a))?b(a,{$$$p:c}):this.$$parsedNgModelAssign(a,c)}}else if(!this.$$parsedNgModel.assign)throw Qg("nonassign","Expression '{0}' is non-assignable. Element: {1}",this.$$attr.ngModel,ba(this.$$element))},$render:p,$isEmpty:function(a){return t(a)||""===a||null===a||a!==a},$$updateEmptyClasses:function(a){this.$isEmpty(a)?(this.$$animate.removeClass(this.$$element,"ng-not-empty"),this.$$animate.addClass(this.$$element,"ng-empty")):(this.$$animate.removeClass(this.$$element,"ng-empty"),this.$$animate.addClass(this.$$element,"ng-not-empty"))},$setPristine:function(){this.$dirty=!1,this.$pristine=!0,this.$$animate.removeClass(this.$$element,Pg),this.$$animate.addClass(this.$$element,Og)},$setDirty:function(){this.$dirty=!0,this.$pristine=!1,this.$$animate.removeClass(this.$$element,Og),this.$$animate.addClass(this.$$element,Pg),this.$$parentForm.$setDirty()},$setUntouched:function(){this.$touched=!1,this.$untouched=!0,this.$$animate.setClass(this.$$element,"ng-untouched","ng-touched")},$setTouched:function(){this.$touched=!0,this.$untouched=!1,this.$$animate.setClass(this.$$element,"ng-touched","ng-untouched")},$rollbackViewValue:function(){this.$$timeout.cancel(this.$$pendingDebounce),this.$viewValue=this.$$lastCommittedViewValue,this.$render()},$validate:function(){if(!oe(this.$modelValue)){var a=this.$$lastCommittedViewValue,b=this.$$rawModelValue,c=this.$valid,d=this.$modelValue,e=this.$options.getOption("allowInvalid"),f=this;this.$$runValidators(b,a,function(a){e||c===a||(f.$modelValue=a?b:void 0,f.$modelValue!==d&&f.$$writeModelToScope())})}},$$runValidators:function(a,b,c){function d(a,b){g===h.$$currentValidationRunId&&h.$setValidity(a,b)}function e(a){g===h.$$currentValidationRunId&&c(a)}this.$$currentValidationRunId++;var g=this.$$currentValidationRunId,h=this;return function(){var a=h.$$parserName||"parse";return t(h.$$parserValid)?(d(a,null),!0):(h.$$parserValid||(f(h.$validators,function(a,b){d(b,null)}),f(h.$asyncValidators,function(a,b){d(b,null)})),d(a,h.$$parserValid),h.$$parserValid)}()&&function(){var c=!0;return f(h.$validators,function(e,f){var g=Boolean(e(a,b));c=c&&g,d(f,g)}),!!c||(f(h.$asyncValidators,function(a,b){d(b,null)}),!1)}()?void function(){var c=[],g=!0;f(h.$asyncValidators,function(e,f){var h=e(a,b);if(!J(h))throw Qg("nopromise","Expected asynchronous validator to return a promise but got '{0}' instead.",h);d(f,void 0),c.push(h.then(function(){d(f,!0)},function(){g=!1,d(f,!1)}))}),c.length?h.$$q.all(c).then(function(){e(g)},p):e(!0)}():void e(!1)},$commitViewValue:function(){var a=this.$viewValue;this.$$timeout.cancel(this.$$pendingDebounce),(this.$$lastCommittedViewValue!==a||""===a&&this.$$hasNativeValidators)&&(this.$$updateEmptyClasses(a),this.$$lastCommittedViewValue=a,this.$pristine&&this.$setDirty(),this.$$parseAndValidate())},$$parseAndValidate:function(){function a(){d.$modelValue!==f&&d.$$writeModelToScope()}var b=this.$$lastCommittedViewValue,c=b,d=this;if(this.$$parserValid=!t(c)||void 0,this.$$parserValid)for(var e=0;e<this.$parsers.length;e++)if(c=this.$parsers[e](c),t(c)){this.$$parserValid=!1;break}oe(this.$modelValue)&&(this.$modelValue=this.$$ngModelGet(this.$$scope));var f=this.$modelValue,g=this.$options.getOption("allowInvalid");this.$$rawModelValue=c,g&&(this.$modelValue=c,a()),this.$$runValidators(c,this.$$lastCommittedViewValue,function(b){g||(d.$modelValue=b?c:void 0,a())})},$$writeModelToScope:function(){this.$$ngModelSet(this.$$scope,this.$modelValue),f(this.$viewChangeListeners,function(a){try{a()}catch(a){this.$$exceptionHandler(a)}},this)},$setViewValue:function(a,b){this.$viewValue=a,this.$options.getOption("updateOnDefault")&&this.$$debounceViewValueCommit(b)},$$debounceViewValueCommit:function(a){var b=this.$options.getOption("debounce");y(b[a])?b=b[a]:y(b.default)&&(b=b.default),this.$$timeout.cancel(this.$$pendingDebounce);var c=this;b>0?this.$$pendingDebounce=this.$$timeout(function(){c.$commitViewValue()},b):this.$$scope.$root.$$phase?this.$commitViewValue():this.$$scope.$apply(function(){c.$commitViewValue()})},$overrideModelOptions:function(a){this.$options=this.$options.createChild(a)}},vd({clazz:Rd,set:function(a,b){a[b]=!0},unset:function(a,b){delete a[b]}});var Rg,Sg=["$rootScope",function(a){return{restrict:"A",require:["ngModel","^?form","^?ngModelOptions"],controller:Rd,priority:1,compile:function(b){return b.addClass(Og).addClass("ng-untouched").addClass(Mg),{pre:function(a,b,c,d){var e=d[0],f=d[1]||e.$$parentForm,g=d[2];g&&(e.$options=g.$options),e.$$initGetterSetters(),f.$addControl(e),c.$observe("name",function(a){e.$name!==a&&e.$$parentForm.$$renameControl(e,a)}),a.$on("$destroy",function(){e.$$parentForm.$removeControl(e)})},post:function(b,c,d,e){function f(){g.$setTouched()}var g=e[0];g.$options.getOption("updateOn")&&c.on(g.$options.getOption("updateOn"),function(a){g.$$debounceViewValueCommit(a&&a.type)}),c.on("blur",function(){g.$touched||(a.$$phase?b.$evalAsync(f):b.$apply(f))})}}}}}],Tg=/(\s+|^)default(\s+|$)/;Td.prototype={getOption:function(a){return this.$$options[a]},createChild:function(a){var b=!1;return a=l({},a),f(a,function(c,d){"$inherit"===c?"*"===d?b=!0:(a[d]=this.$$options[d],"updateOn"===d&&(a.updateOnDefault=this.$$options.updateOnDefault)):"updateOn"===d&&(a.updateOnDefault=!1,a[d]=re(c.replace(Tg,function(){return a.updateOnDefault=!0," "})))},this),b&&(delete a["*"],Ud(a,this.$$options)),Ud(a,Rg.$$options),new Td(a)}},Rg=new Td({updateOn:"",updateOnDefault:!0,debounce:0,getterSetter:!1,allowInvalid:!1,timezone:null});var Ug=function(){function a(a,b){this.$$attrs=a,this.$$scope=b}return a.$inject=["$attrs","$scope"],a.prototype={$onInit:function(){var a=this.parentCtrl?this.parentCtrl.$options:Rg,b=this.$$scope.$eval(this.$$attrs.ngModelOptions);this.$options=a.createChild(b)}},{restrict:"A",priority:10,require:{parentCtrl:"?^^ngModelOptions"},bindToController:!0,controller:a}},Vg=rd({terminal:!0,priority:1e3}),Wg=d("ngOptions"),Xg=/^\s*([\s\S]+?)(?:\s+as\s+([\s\S]+?))?(?:\s+group\s+by\s+([\s\S]+?))?(?:\s+disable\s+when\s+([\s\S]+?))?\s+for\s+(?:([$\w][$\w]*)|(?:\(\s*([$\w][$\w]*)\s*,\s*([$\w][$\w]*)\s*\)))\s+in\s+([\s\S]+?)(?:\s+track\s+by\s+([\s\S]+?))?$/,Yg=["$compile","$document","$parse",function(b,c,d){function g(a,b,c){function f(a,b,c,d,e){this.selectValue=a,this.viewValue=b,this.label=c,this.group=d,this.disabled=e}function g(a){var b;if(!j&&e(a))b=a;else{b=[];for(var c in a)a.hasOwnProperty(c)&&"$"!==c.charAt(0)&&b.push(c)}return b}var h=a.match(Xg);if(!h)throw Wg("iexp","Expected expression in form of '_select_ (as _label_)? for (_key_,)?_value_ in _collection_' but got '{0}'. Element: {1}",a,ba(b));var i=h[5]||h[7],j=h[6],k=/ as /.test(h[0])&&h[1],l=h[9],m=d(h[2]?h[1]:i),n=k&&d(k),o=n||m,p=l&&d(l),q=l?function(a,b){return p(c,b)}:function(a){return db(a)},r=function(a,b){return q(a,x(a,b))},s=d(h[2]||h[1]),t=d(h[3]||""),u=d(h[4]||""),v=d(h[8]),w={},x=j?function(a,b){return w[j]=b,w[i]=a,w}:function(a){return w[i]=a,w};return{trackBy:l,getTrackByValue:r,getWatchables:d(v,function(a){var b=[];a=a||[];for(var d=g(a),e=d.length,f=0;f<e;f++){var i=a===d?f:d[f],j=a[i],k=x(j,i),l=q(j,k);if(b.push(l),h[2]||h[1]){var m=s(c,k);b.push(m)}if(h[4]){var n=u(c,k);b.push(n)}}return b}),getOptions:function(){for(var a=[],b={},d=v(c)||[],e=g(d),h=e.length,i=0;i<h;i++){var j=d===e?i:e[i],k=d[j],m=x(k,j),n=o(c,m),p=q(n,m),w=s(c,m),y=t(c,m),z=u(c,m),A=new f(p,n,w,y,z);a.push(A),b[p]=A}return{items:a,selectValueMap:b,getOptionFromViewValue:function(a){return b[r(a)]},
|
6 |
getViewValueFromOption:function(a){return l?R(a.viewValue):a.viewValue}}}}}function h(a,d,e,h){function k(a,b){var c=i.cloneNode(!1);b.appendChild(c),m(a,c)}function l(a){var b=w.getOptionFromViewValue(a),c=b&&b.element;return c&&!c.selected&&(c.selected=!0),b}function m(a,b){a.element=b,b.disabled=a.disabled,a.label!==b.label&&(b.label=a.label,b.textContent=a.label),b.value=a.selectValue}function n(){var a=w&&o.readValue();if(w)for(var b=w.items.length-1;b>=0;b--){var c=w.items[b];Wa(u(c.group)?c.element.parentNode:c.element)}w=x.getOptions();var e={};if(w.items.forEach(function(a){var b;u(a.group)?(b=e[a.group],b||(b=j.cloneNode(!1),y.appendChild(b),b.label=null===a.group?"null":a.group,e[a.group]=b),k(a,b)):k(a,y)}),d[0].appendChild(y),p.$render(),!p.$isEmpty(a)){var f=o.readValue();(x.trackBy||q?T(a,f):a===f)||(p.$setViewValue(f),p.$render())}}for(var o=h[0],p=h[1],q=e.multiple,r=0,s=d.children(),t=s.length;r<t;r++)if(""===s[r].value){o.hasEmptyOption=!0,o.emptyOption=s.eq(r);break}d.empty();var v=!!o.emptyOption;de(i.cloneNode(!1)).val("?");var w,x=g(e.ngOptions,d,a),y=c[0].createDocumentFragment();o.generateUnknownOptionValue=function(a){return"?"},q?(o.writeValue=function(a){if(w){var b=a&&a.map(l)||[];w.items.forEach(function(a){a.element.selected&&!P(b,a)&&(a.element.selected=!1)})}},o.readValue=function(){var a=d.val()||[],b=[];return f(a,function(a){var c=w.selectValueMap[a];c&&!c.disabled&&b.push(w.getViewValueFromOption(c))}),b},x.trackBy&&a.$watchCollection(function(){if(pe(p.$viewValue))return p.$viewValue.map(function(a){return x.getTrackByValue(a)})},function(){p.$render()})):(o.writeValue=function(a){if(w){var b=d[0].options[d[0].selectedIndex],c=w.getOptionFromViewValue(a);b&&b.removeAttribute("selected"),c?(d[0].value!==c.selectValue&&(o.removeUnknownOption(),d[0].value=c.selectValue,c.element.selected=!0),c.element.setAttribute("selected","selected")):o.selectUnknownOrEmptyOption(a)}},o.readValue=function(){var a=w.selectValueMap[d.val()];return a&&!a.disabled?(o.unselectEmptyOption(),o.removeUnknownOption(),w.getViewValueFromOption(a)):null},x.trackBy&&a.$watch(function(){return x.getTrackByValue(p.$viewValue)},function(){p.$render()})),v&&(b(o.emptyOption)(a),d.prepend(o.emptyOption),o.emptyOption[0].nodeType===Ce?(o.hasEmptyOption=!1,o.registerOption=function(a,b){""===b.val()&&(o.hasEmptyOption=!0,o.emptyOption=b,o.emptyOption.removeClass("ng-scope"),p.$render(),b.on("$destroy",function(){var a=o.$isEmptyOptionSelected();o.hasEmptyOption=!1,o.emptyOption=void 0,a&&p.$render()}))}):o.emptyOption.removeClass("ng-scope")),a.$watchCollection(x.getWatchables,n)}var i=a.document.createElement("option"),j=a.document.createElement("optgroup");return{restrict:"A",terminal:!0,require:["select","ngModel"],link:{pre:function(a,b,c,d){d[0].registerOption=p},post:h}}}],Zg=["$locale","$interpolate","$log",function(a,b,c){var d=/{}/g,e=/^when(Minus)?(.+)$/;return{link:function(g,h,i){function j(a){h.text(a||"")}var k,l=i.count,m=i.$attr.when&&h.attr(i.$attr.when),n=i.offset||0,o=g.$eval(m)||{},q={},r=b.startSymbol(),s=b.endSymbol(),u=r+l+"-"+n+s,v=me.noop;f(i,function(a,b){var c=e.exec(b);if(c){var d=(c[1]?"-":"")+$d(c[2]);o[d]=h.attr(i.$attr[b])}}),f(o,function(a,c){q[c]=b(a.replace(d,u))}),g.$watch(l,function(b){var d=parseFloat(b),e=oe(d);if(e||d in o||(d=a.pluralCat(d-n)),!(d===k||e&&oe(k))){v();var f=q[d];t(f)?(null!=b&&c.debug("ngPluralize: no rule defined for '"+d+"' in "+m),v=p,j()):v=g.$watch(f,j),k=d}})}}}],$g=["$parse","$animate","$compile",function(a,b,c){var g=d("ngRepeat"),h=function(a,b,c,d,e,f,g){a[c]=d,e&&(a[e]=f),a.$index=b,a.$first=0===b,a.$last=b===g-1,a.$middle=!(a.$first||a.$last),a.$odd=!(a.$even=0==(1&b))},i=function(a){return a.clone[0]},j=function(a){return a.clone[a.clone.length-1]};return{restrict:"A",multiElement:!0,transclude:"element",priority:1e3,terminal:!0,$$tlb:!0,compile:function(d,k){var l=k.ngRepeat,m=c.$$createComment("end ngRepeat",l),n=l.match(/^\s*([\s\S]+?)\s+in\s+([\s\S]+?)(?:\s+as\s+([\s\S]+?))?(?:\s+track\s+by\s+([\s\S]+?))?\s*$/);if(!n)throw g("iexp","Expected expression in form of '_item_ in _collection_[ track by _id_]' but got '{0}'.",l);var o=n[1],p=n[2],q=n[3],r=n[4];if(!(n=o.match(/^(?:(\s*[$\w]+)|\(\s*([$\w]+)\s*,\s*([$\w]+)\s*\))$/)))throw g("iidexp","'_item_' in '_item_ in _collection_' should be an identifier or '(_key_, _value_)' expression, but got '{0}'.",o);var s=n[3]||n[1],t=n[2];if(q&&(!/^[$a-zA-Z_][$a-zA-Z0-9_]*$/.test(q)||/^(null|undefined|this|\$index|\$first|\$middle|\$last|\$even|\$odd|\$parent|\$root|\$id)$/.test(q)))throw g("badident","alias '{0}' is invalid --- must be a valid JS identifier which is not a reserved name.",q);var u,v,w,x,y={$id:db};return r?u=a(r):(w=function(a,b){return db(b)},x=function(a){return a}),function(a,c,d,k,n){u&&(v=function(b,c,d){return t&&(y[t]=b),y[s]=c,y.$index=d,u(a,y)});var o=sa();a.$watchCollection(p,function(d){var k,p,r,u,y,z,A,B,C,D,E,F,G=c[0],H=sa();if(q&&(a[q]=d),e(d))C=d,B=v||w;else{B=v||x,C=[];for(var I in d)Zd.call(d,I)&&"$"!==I.charAt(0)&&C.push(I)}for(u=C.length,E=new Array(u),k=0;k<u;k++)if(y=d===C?k:C[k],z=d[y],A=B(y,z,k),o[A])D=o[A],delete o[A],H[A]=D,E[k]=D;else{if(H[A])throw f(E,function(a){a&&a.scope&&(o[a.id]=a)}),g("dupes","Duplicates in a repeater are not allowed. Use 'track by' expression to specify unique keys. Repeater: {0}, Duplicate key: {1}, Duplicate value: {2}",l,A,z);E[k]={id:A,scope:void 0,clone:void 0},H[A]=!0}for(var J in o){if(D=o[J],F=ra(D.clone),b.leave(F),F[0].parentNode)for(k=0,p=F.length;k<p;k++)F[k].$$NG_REMOVED=!0;D.scope.$destroy()}for(k=0;k<u;k++)if(y=d===C?k:C[k],z=d[y],D=E[k],D.scope){r=G;do{r=r.nextSibling}while(r&&r.$$NG_REMOVED);i(D)!==r&&b.move(ra(D.clone),null,G),G=j(D),h(D.scope,k,s,z,t,y,u)}else n(function(a,c){D.scope=c;var d=m.cloneNode(!1);a[a.length++]=d,b.enter(a,null,G),G=d,D.clone=a,H[D.id]=D,h(D.scope,k,s,z,t,y,u)});o=H})}}}}],_g=["$animate",function(a){return{restrict:"A",multiElement:!0,link:function(b,c,d){b.$watch(d.ngShow,function(b){a[b?"removeClass":"addClass"](c,"ng-hide",{tempClasses:"ng-hide-animate"})})}}}],ah=["$animate",function(a){return{restrict:"A",multiElement:!0,link:function(b,c,d){b.$watch(d.ngHide,function(b){a[b?"addClass":"removeClass"](c,"ng-hide",{tempClasses:"ng-hide-animate"})})}}}],bh=rd(function(a,b,c){a.$watch(c.ngStyle,function(a,c){c&&a!==c&&f(c,function(a,c){b.css(c,"")}),a&&b.css(a)},!0)}),ch=["$animate","$compile",function(a,b){return{require:"ngSwitch",controller:["$scope",function(){this.cases={}}],link:function(c,d,e,g){var h=e.ngSwitch||e.on,i=[],j=[],k=[],l=[],m=function(a,b){return function(c){!1!==c&&a.splice(b,1)}};c.$watch(h,function(c){for(var d,e;k.length;)a.cancel(k.pop());for(d=0,e=l.length;d<e;++d){var h=ra(j[d].clone);l[d].$destroy();(k[d]=a.leave(h)).done(m(k,d))}j.length=0,l.length=0,(i=g.cases["!"+c]||g.cases["?"])&&f(i,function(c){c.transclude(function(d,e){l.push(e);var f=c.element;d[d.length++]=b.$$createComment("end ngSwitchWhen");var g={clone:d};j.push(g),a.enter(d,f.parent(),f)})})})}}}],dh=rd({transclude:"element",priority:1200,require:"^ngSwitch",multiElement:!0,link:function(a,b,c,d,e){f(c.ngSwitchWhen.split(c.ngSwitchWhenSeparator).sort().filter(function(a,b,c){return c[b-1]!==a}),function(a){d.cases["!"+a]=d.cases["!"+a]||[],d.cases["!"+a].push({transclude:e,element:b})})}}),eh=rd({transclude:"element",priority:1200,require:"^ngSwitch",multiElement:!0,link:function(a,b,c,d,e){d.cases["?"]=d.cases["?"]||[],d.cases["?"].push({transclude:e,element:b})}}),fh=d("ngTransclude"),gh=["$compile",function(a){return{restrict:"EAC",terminal:!0,compile:function(b){var c=a(b.contents());return b.empty(),function(a,b,d,e,f){function g(a,c){a.length&&i(a)?b.append(a):(h(),c.$destroy())}function h(){c(a,function(a){b.append(a)})}function i(a){for(var b=0,c=a.length;b<c;b++){var d=a[b];if(d.nodeType!==Be||d.nodeValue.trim())return!0}}if(!f)throw fh("orphan","Illegal use of ngTransclude directive in the template! No parent directive that requires a transclusion found. Element: {0}",ba(b));d.ngTransclude===d.$attr.ngTransclude&&(d.ngTransclude="");var j=d.ngTransclude||d.ngTranscludeSlot;f(g,null,j),j&&!f.isSlotFilled(j)&&h()}}}}],hh=["$templateCache",function(a){return{restrict:"E",terminal:!0,compile:function(b,c){if("text/ng-template"===c.type){var d=c.id,e=b[0].text;a.put(d,e)}}}}],ih={$setViewValue:p,$render:p},jh=["$element","$scope",function(b,c){function d(){h||(h=!0,c.$$postDigest(function(){h=!1,f.ngModelCtrl.$render()}))}function e(a){i||(i=!0,c.$$postDigest(function(){c.$$destroyed||(i=!1,f.ngModelCtrl.$setViewValue(f.readValue()),a&&f.ngModelCtrl.$render())}))}var f=this,g=new Xe;f.selectValueMap={},f.ngModelCtrl=ih,f.multiple=!1,f.unknownOption=de(a.document.createElement("option")),f.hasEmptyOption=!1,f.emptyOption=void 0,f.renderUnknownOption=function(a){var c=f.generateUnknownOptionValue(a);f.unknownOption.val(c),b.prepend(f.unknownOption),Vd(f.unknownOption,!0),b.val(c)},f.updateUnknownOption=function(a){var c=f.generateUnknownOptionValue(a);f.unknownOption.val(c),Vd(f.unknownOption,!0),b.val(c)},f.generateUnknownOptionValue=function(a){return"? "+db(a)+" ?"},f.removeUnknownOption=function(){f.unknownOption.parent()&&f.unknownOption.remove()},f.selectEmptyOption=function(){f.emptyOption&&(b.val(""),Vd(f.emptyOption,!0))},f.unselectEmptyOption=function(){f.hasEmptyOption&&Vd(f.emptyOption,!1)},c.$on("$destroy",function(){f.renderUnknownOption=p}),f.readValue=function(){var a=b.val(),c=a in f.selectValueMap?f.selectValueMap[a]:a;return f.hasOption(c)?c:null},f.writeValue=function(a){var c=b[0].options[b[0].selectedIndex];if(c&&Vd(de(c),!1),f.hasOption(a)){f.removeUnknownOption();var d=db(a);b.val(d in f.selectValueMap?d:a);var e=b[0].options[b[0].selectedIndex];Vd(de(e),!0)}else f.selectUnknownOrEmptyOption(a)},f.addOption=function(a,b){if(b[0].nodeType!==Ce){pa(a,'"option value"'),""===a&&(f.hasEmptyOption=!0,f.emptyOption=b);var c=g.get(a)||0;g.set(a,c+1),d()}},f.removeOption=function(a){var b=g.get(a);b&&(1===b?(g.delete(a),""===a&&(f.hasEmptyOption=!1,f.emptyOption=void 0)):g.set(a,b-1))},f.hasOption=function(a){return!!g.get(a)},f.$hasEmptyOption=function(){return f.hasEmptyOption},f.$isUnknownOptionSelected=function(){return b[0].options[0]===f.unknownOption[0]},f.$isEmptyOptionSelected=function(){return f.hasEmptyOption&&b[0].options[b[0].selectedIndex]===f.emptyOption[0]},f.selectUnknownOrEmptyOption=function(a){null==a&&f.emptyOption?(f.removeUnknownOption(),f.selectEmptyOption()):f.unknownOption.parent().length?f.updateUnknownOption(a):f.renderUnknownOption(a)};var h=!1,i=!1;f.registerOption=function(a,b,c,g,h){if(c.$attr.ngValue){var i,j=NaN;c.$observe("value",function(a){var c,d=b.prop("selected");u(j)&&(f.removeOption(i),delete f.selectValueMap[j],c=!0),j=db(a),i=a,f.selectValueMap[j]=a,f.addOption(a,b),b.attr("value",j),c&&d&&e()})}else g?c.$observe("value",function(a){f.readValue();var c,d=b.prop("selected");u(i)&&(f.removeOption(i),c=!0),i=a,f.addOption(a,b),c&&d&&e()}):h?a.$watch(h,function(a,d){c.$set("value",a);var g=b.prop("selected");d!==a&&f.removeOption(d),f.addOption(a,b),d&&g&&e()}):f.addOption(c.value,b);c.$observe("disabled",function(a){("true"===a||a&&b.prop("selected"))&&(f.multiple?e(!0):(f.ngModelCtrl.$setViewValue(null),f.ngModelCtrl.$render()))}),b.on("$destroy",function(){var a=f.readValue(),b=c.value;f.removeOption(b),d(),(f.multiple&&a&&-1!==a.indexOf(b)||a===b)&&e(!0)})}}],kh=function(){function a(a,b,c,d){var e=d[0],g=d[1];if(!g)return void(e.registerOption=p);if(e.ngModelCtrl=g,b.on("change",function(){e.removeUnknownOption(),a.$apply(function(){g.$setViewValue(e.readValue())})}),c.multiple){e.multiple=!0,e.readValue=function(){var a=[];return f(b.find("option"),function(b){if(b.selected&&!b.disabled){var c=b.value;a.push(c in e.selectValueMap?e.selectValueMap[c]:c)}}),a},e.writeValue=function(a){f(b.find("option"),function(b){var c=!!a&&(P(a,b.value)||P(a,e.selectValueMap[b.value]));c!==b.selected&&Vd(de(b),c)})};var h,i=NaN;a.$watch(function(){i!==g.$viewValue||T(h,g.$viewValue)||(h=va(g.$viewValue),g.$render()),i=g.$viewValue}),g.$isEmpty=function(a){return!a||0===a.length}}}function b(a,b,c,d){var e=d[1];if(e){var f=d[0];e.$render=function(){f.writeValue(e.$viewValue)}}}return{restrict:"E",require:["select","?ngModel"],controller:jh,priority:1,link:{pre:a,post:b}}},lh=["$interpolate",function(a){return{restrict:"E",priority:100,compile:function(b,c){var d,e;return u(c.ngValue)||(u(c.value)?d=a(c.value,!0):(e=a(b.text(),!0))||c.$set("value",b.text())),function(a,b,c){var f=b.parent(),g=f.data("$selectController")||f.parent().data("$selectController");g&&g.registerOption(a,b,c,d,e)}}}}],mh=function(){return{restrict:"A",require:"?ngModel",link:function(a,b,c,d){d&&(c.required=!0,d.$validators.required=function(a,b){return!c.required||!d.$isEmpty(b)},c.$observe("required",function(){d.$validate()}))}}},nh=function(){return{restrict:"A",require:"?ngModel",link:function(a,b,c,e){if(e){var f,g=c.ngPattern||c.pattern;c.$observe("pattern",function(a){if(x(a)&&a.length>0&&(a=new RegExp("^"+a+"$")),a&&!a.test)throw d("ngPattern")("noregexp","Expected {0} to be a RegExp but was {1}. Element: {2}",g,a,ba(b));f=a||void 0,e.$validate()}),e.$validators.pattern=function(a,b){return e.$isEmpty(b)||t(f)||f.test(b)}}}}},oh=function(){return{restrict:"A",require:"?ngModel",link:function(a,b,c,d){if(d){var e=-1;c.$observe("maxlength",function(a){var b=n(a);e=oe(b)?-1:b,d.$validate()}),d.$validators.maxlength=function(a,b){return e<0||d.$isEmpty(b)||b.length<=e}}}}},ph=function(){return{restrict:"A",require:"?ngModel",link:function(a,b,c,d){if(d){var e=0;c.$observe("minlength",function(a){e=n(a)||0,d.$validate()}),d.$validators.minlength=function(a,b){return d.$isEmpty(b)||b.length>=e}}}}};if(a.angular.bootstrap)return void(a.console&&console.log("WARNING: Tried to load angular more than once."));!function(){var b;if(!ze){var c=ue();ee=t(c)?a.jQuery:c?a[c]:void 0,ee&&ee.fn.on?(de=ee,l(ee.fn,{scope:Se.scope,isolateScope:Se.isolateScope,controller:Se.controller,injector:Se.injector,inheritedData:Se.inheritedData}),b=ee.cleanData,ee.cleanData=function(a){for(var c,d,e=0;null!=(d=a[e]);e++)(c=ee._data(d,"events"))&&c.$destroy&&ee(d).triggerHandler("$destroy");b(a)}):de=Ia,me.element=de,ze=!0}}(),function(c){l(c,{errorHandlingConfig:b,bootstrap:ja,copy:R,extend:l,merge:m,equals:T,element:de,forEach:f,injector:jb,noop:p,bind:W,toJson:Y,fromJson:Z,identity:q,isUndefined:t,isDefined:u,isString:x,isFunction:B,isObject:v,isNumber:y,isElement:M,isArray:pe,version:Fe,isDate:z,lowercase:$d,uppercase:_d,callbacks:{$$counter:0},getTestability:la,reloadWithDebugInfo:ka,$$minErr:d,$$csp:te,$$encodeUriSegment:fa,$$encodeUriQuery:ga,$$stringify:ta}),fe=ua(a),fe("ng",["ngLocale"],["$provide",function(a){a.provider({$$sanitizeUri:Fc}),a.provider("$compile",ub).directive({a:ag,input:tg,textarea:tg,form:fg,script:hh,select:kh,option:lh,ngBind:wg,ngBindHtml:yg,ngBindTemplate:xg,ngClass:Ag,ngClassEven:Cg,ngClassOdd:Bg,ngCloak:Dg,ngController:Eg,ngForm:gg,ngHide:ah,ngIf:Hg,ngInclude:Ig,ngInit:Kg,ngNonBindable:Vg,ngPluralize:Zg,ngRepeat:$g,ngShow:_g,ngStyle:bh,ngSwitch:ch,ngSwitchWhen:dh,ngSwitchDefault:eh,ngOptions:Yg,ngTransclude:gh,ngModel:Sg,ngList:Lg,ngChange:zg,pattern:nh,ngPattern:nh,required:mh,ngRequired:mh,minlength:ph,ngMinlength:ph,maxlength:oh,ngMaxlength:oh,ngValue:vg,ngModelOptions:Ug}).directive({ngInclude:Jg}).directive(bg).directive(Fg),a.provider({$anchorScroll:kb,$animate:hf,$animateCss:lf,$$animateJs:ff,$$animateQueue:gf,$$AnimateRunner:kf,$$animateAsyncRun:jf,$browser:qb,$cacheFactory:rb,$controller:Ab,$document:Bb,$$isDocumentHidden:Cb,$exceptionHandler:Db,$filter:Uc,$$forceReflow:sf,$interpolate:Rb,$interval:Sb,$http:Nb,$httpParamSerializer:Fb,$httpParamSerializerJQLike:Gb,$httpBackend:Pb,$xhrFactory:Ob,$jsonpCallbacks:Af,$location:fc,$log:gc,$parse:wc,$rootScope:Ec,$q:xc,$$q:yc,$sce:Kc,$sceDelegate:Jc,$sniffer:Lc,$templateCache:sb,$templateRequest:Mc,$$testability:Nc,$timeout:Oc,$window:Rc,$$rAF:Dc,$$jqLite:cb,$$Map:Ye,$$cookieReader:Tc})}]).info({angularVersion:"1.6.6"})}(me),me.module("ngLocale",[],["$provide",function(a){function b(a){a+="";var b=a.indexOf(".");return-1==b?0:a.length-b-1}function c(a,c){var d=c;void 0===d&&(d=Math.min(b(a),3));var e=Math.pow(10,d);return{v:d,f:(a*e|0)%e}}var d={ZERO:"zero",ONE:"one",TWO:"two",FEW:"few",MANY:"many",OTHER:"other"};a.value("$locale",{DATETIME_FORMATS:{AMPMS:["AM","PM"],DAY:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],ERANAMES:["Before Christ","Anno Domini"],ERAS:["BC","AD"],FIRSTDAYOFWEEK:6,MONTH:["January","February","March","April","May","June","July","August","September","October","November","December"],SHORTDAY:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],SHORTMONTH:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],STANDALONEMONTH:["January","February","March","April","May","June","July","August","September","October","November","December"],WEEKENDRANGE:[5,6],fullDate:"EEEE, MMMM d, y",longDate:"MMMM d, y",medium:"MMM d, y h:mm:ss a",mediumDate:"MMM d, y",mediumTime:"h:mm:ss a",short:"M/d/yy h:mm a",shortDate:"M/d/yy",shortTime:"h:mm a"},NUMBER_FORMATS:{CURRENCY_SYM:"$",DECIMAL_SEP:".",GROUP_SEP:",",PATTERNS:[{gSize:3,lgSize:3,maxFrac:3,minFrac:0,minInt:1,negPre:"-",negSuf:"",posPre:"",posSuf:""},{gSize:3,lgSize:3,maxFrac:2,minFrac:2,minInt:1,negPre:"-¤",negSuf:"",posPre:"¤",posSuf:""}]},id:"en-us",localeID:"en_US",pluralCat:function(a,b){var e=0|a,f=c(a,b);return 1==e&&0==f.v?d.ONE:d.OTHER}})}]),de(function(){ia(a.document,ja)})}(window),!window.angular.$$csp().noInlineStyle&&window.angular.element(document.head).prepend('<style type="text/css">@charset "UTF-8";[ng\\:cloak],[ng-cloak],[data-ng-cloak],[x-ng-cloak],.ng-cloak,.x-ng-cloak,.ng-hide:not(.ng-hide-animate){display:none !important;}ng\\:form{display:block;}.ng-animate-shim{visibility:hidden;}.ng-anchor{position:absolute;}</style>'),function(){"use strict";angular.module("ng-slide-down",[]).directive("ngSlideDown",["$timeout",function(a){var b,c;return b=function(a,b){return void 0!==b.lazyRender?"<div ng-if='lazyRender' ng-transclude></div>":"<div ng-transclude></div>"},c=function(b,c,d,e,f){var g,h,i,j,k,l,m,n,o,p,q;return h=d.duration||1,q=d.timingFunction||"ease-in-out",i=c.scope(),j=d.emitOnClose,n=d.onClose,m=void 0!==d.lazyRender,g=null,o=null,k=function(a){var b,d,e,f,g;for(e=0,d=c.children(),f=0,g=d.length;f<g;f++)b=d[f],e+=b.clientHeight;return e+"px"},p=function(){return g&&a.cancel(g),m&&(b.lazyRender=!0),a(function(){return o&&a.cancel(o),c.css({overflow:"hidden",transitionProperty:"height",transitionDuration:h+"s",transitionTimingFunction:q,height:k()}),o=a(function(){return c.css({overflow:"visible",transition:"none",height:"auto"})},1e3*h)})},l=function(){if(o&&a.cancel(o),c.css({overflow:"hidden",transitionProperty:"height",transitionDuration:h+"s",transitionTimingFunction:q,height:"0px"}),j||n||m)return g=a(function(){if(j&&b.$emit(j,{}),n&&i.$eval(n),m)return b.lazyRender=!1},1e3*h)},b.$watch("expanded",function(b,d){return b?a(p):(null!=b&&(c.css({height:k()}),c[0].clientHeight),a(l))})},{restrict:"A",scope:{expanded:"=ngSlideDown"},transclude:!0,link:c,template:function(a,c){return b(a,c)}}}])}.call(this),function(a,b){"use strict";function c(a,b,c){if(!a)throw ia("areq","Argument '{0}' is {1}",b||"?",c||"required");return a}function d(a,b){return a||b?a?b?(U(a)&&(a=a.join(" ")),U(b)&&(b=b.join(" ")),a+" "+b):a:b:""}function e(a){var b={};return a&&(a.to||a.from)&&(b.to=a.to,b.from=a.from),b}function f(a,b,c){var d="";return a=U(a)?a:a&&Z(a)&&a.length?a.split(/\s+/):[],T(a,function(a,e){a&&a.length>0&&(d+=e>0?" ":"",d+=c?b+a:a+b)}),d}function g(a,b){var c=a.indexOf(b);b>=0&&a.splice(c,1)}function h(a){if(a instanceof _)switch(a.length){case 0:return a;case 1:if(a[0].nodeType===L)return a;break;default:return _(i(a))}if(a.nodeType===L)return _(a)}function i(a){if(!a[0])return a;for(var b=0;b<a.length;b++){var c=a[b];if(c.nodeType===L)return c}}function j(a,b,c){T(b,function(b){a.addClass(b,c)})}function k(a,b,c){T(b,function(b){a.removeClass(b,c)})}function l(a){return function(b,c){c.addClass&&(j(a,b,c.addClass),c.addClass=null),c.removeClass&&(k(a,b,c.removeClass),c.removeClass=null)}}function m(a){if(a=a||{},!a.$$prepared){var b=a.domOperation||aa;a.domOperation=function(){a.$$domOperationFired=!0,b(),b=aa},a.$$prepared=!0}return a}function n(a,b){o(a,b),p(a,b)}function o(a,b){b.from&&(a.css(b.from),b.from=null)}function p(a,b){b.to&&(a.css(b.to),b.to=null)}function q(a,b,c){var d=b.options||{},e=c.options||{},f=(d.addClass||"")+" "+(e.addClass||""),g=(d.removeClass||"")+" "+(e.removeClass||""),h=r(a.attr("class"),f,g);e.preparationClasses&&(d.preparationClasses=y(e.preparationClasses,d.preparationClasses),delete e.preparationClasses);var i=d.domOperation!==aa?d.domOperation:null;return S(d,e),i&&(d.domOperation=i),h.addClass?d.addClass=h.addClass:d.addClass=null,h.removeClass?d.removeClass=h.removeClass:d.removeClass=null,b.addClass=d.addClass,b.removeClass=d.removeClass,d}function r(a,b,c){function d(a){Z(a)&&(a=a.split(" "));var b={};return T(a,function(a){a.length&&(b[a]=!0)}),b}var e={};a=d(a),b=d(b),T(b,function(a,b){e[b]=1}),c=d(c),T(c,function(a,b){e[b]=1===e[b]?null:-1});var f={addClass:"",removeClass:""};return T(e,function(b,c){var d,e;1===b?(d="addClass",e=!a[c]||a[c+N]):-1===b&&(d="removeClass",e=a[c]||a[c+M]),e&&(f[d].length&&(f[d]+=" "),f[d]+=c)}),f}function s(a){return a instanceof _?a[0]:a}function t(a,b,c){var d="";b&&(d=f(b,O,!0)),c.addClass&&(d=y(d,f(c.addClass,M))),c.removeClass&&(d=y(d,f(c.removeClass,N))),d.length&&(c.preparationClasses=d,a.addClass(d))}function u(a,b){b.preparationClasses&&(a.removeClass(b.preparationClasses),b.preparationClasses=null),b.activeClasses&&(a.removeClass(b.activeClasses),b.activeClasses=null)}function v(a,b){var c=b?"-"+b+"s":"";return x(a,[ga,c]),[ga,c]}function w(a,b){var c=b?"paused":"",d=J+da;return x(a,[d,c]),[d,c]}function x(a,b){var c=b[0],d=b[1];a.style[c]=d}function y(a,b){return a?b?a+" "+b:a:b}function z(a){return[fa,a+"s"]}function A(a,b){return[b?ea:ga,a+"s"]}function B(a,b,c){var d=Object.create(null),e=a.getComputedStyle(b)||{};return T(c,function(a,b){var c=e[a];if(c){var f=c.charAt(0);("-"===f||"+"===f||f>=0)&&(c=C(c)),0===c&&(c=null),d[b]=c}}),d}function C(a){var b=0,c=a.split(/\s*,\s*/);return T(c,function(a){"s"===a.charAt(a.length-1)&&(a=a.substring(0,a.length-1)),a=parseFloat(a)||0,b=b?Math.max(a,b):a}),b}function D(a){return 0===a||null!=a}function E(a,b){var c=H,d=a+"s";return b?c+=ba:d+=" linear all",[c,d]}function F(){var a=Object.create(null);return{flush:function(){a=Object.create(null)},count:function(b){var c=a[b];return c?c.total:0},get:function(b){var c=a[b];return c&&c.value},put:function(b,c){a[b]?a[b].total++:a[b]={total:1,value:c}}}}function G(a,b,c){T(c,function(c){a[c]=V(a[c])?a[c]:b.style.getPropertyValue(c)})}var H,I,J,K,L=1,M="-add",N="-remove",O="ng-",P="ng-animate",Q="$$ngAnimateChildren";void 0===a.ontransitionend&&void 0!==a.onwebkittransitionend?("-webkit-",H="WebkitTransition",I="webkitTransitionEnd transitionend"):(H="transition",I="transitionend"),void 0===a.onanimationend&&void 0!==a.onwebkitanimationend?("-webkit-",J="WebkitAnimation",K="webkitAnimationEnd animationend"):(J="animation",K="animationend");var R,S,T,U,V,W,X,Y,Z,$,_,aa,ba="Duration",ca="TimingFunction",da="PlayState",ea=J+"Delay",fa=J+ba,ga=H+"Delay",ha=H+ba,ia=b.$$minErr("ng"),ja=["$$rAF",function(a){function b(a){d=d.concat(a),c()}function c(){if(d.length){for(var b=d.shift(),f=0;f<b.length;f++)b[f]();e||a(function(){e||c()})}}var d,e;return d=b.queue=[],b.waitUntilQuiet=function(b){e&&e(),e=a(function(){e=null,b(),c()})},b}],ka=["$interpolate",function(a){return{link:function(b,c,d){function e(a){a="on"===a||"true"===a,c.data(Q,a)}var f=d.ngAnimateChildren;Z(f)&&0===f.length?c.data(Q,!0):(e(a(f)(b)),d.$observe("ngAnimateChildren",e))}}}],la="$$animateCss",ma=1e3,na=3,oa=1.5,pa={transitionDuration:ha,transitionDelay:ga,transitionProperty:H+"Property",animationDuration:fa,animationDelay:ea,animationIterationCount:J+"IterationCount"},qa={transitionDuration:ha,transitionDelay:ga,animationDuration:fa,animationDelay:ea},ra=["$animateProvider",function(a){var b=F(),c=F();this.$get=["$window","$$jqLite","$$AnimateRunner","$timeout","$$forceReflow","$sniffer","$$rAFScheduler","$$animateQueue",function(a,d,h,i,j,k,q,r){function t(a,b){var c="$$ngAnimateParentKey",d=a.parentNode;return(d[c]||(d[c]=++P))+"-"+a.getAttribute("class")+"-"+b}function u(c,d,e,f){var g=b.get(e);return g||(g=B(a,c,f),"infinite"===g.animationIterationCount&&(g.animationIterationCount=1)),b.put(e,g),g}function y(e,g,h,i){var j;if(b.count(h)>0&&!(j=c.get(h))){var k=f(g,"-stagger");d.addClass(e,k),j=B(a,e,i),j.animationDuration=Math.max(j.animationDuration,0),j.transitionDuration=Math.max(j.transitionDuration,0),d.removeClass(e,k),c.put(h,j)}return j||{}}function C(a){Q.push(a),q.waitUntilQuiet(function(){b.flush(),c.flush();for(var a=j(),d=0;d<Q.length;d++)Q[d](a);Q.length=0})}function F(a,b,c){var d=u(a,b,c,pa),e=d.animationDelay,f=d.transitionDelay;return d.maxDelay=e&&f?Math.max(e,f):e||f,d.maxDuration=Math.max(d.animationDuration*d.animationIterationCount,d.transitionDuration),d}var L=l(d),P=0,Q=[];return function(a,c){function j(){q()}function l(){q(!0)}function q(b){if(!(X||Z&&Y)){X=!0,Y=!1,S.$$skipPreparationClasses||d.removeClass(a,ua),d.removeClass(a,wa),w(W,!1),v(W,!1),T(ha,function(a){W.style[a[0]]=""}),L(a,S),n(a,S),Object.keys(V).length&&T(V,function(a,b){a?W.style.setProperty(b,a):W.style.removeProperty(b)}),S.onDone&&S.onDone(),ka&&ka.length&&a.off(ka.join(" "),P);var c=a.data(la);c&&(i.cancel(c[0].timer),a.removeData(la)),$&&$.complete(!b)}}function u(a){Ja.blockTransition&&v(W,a),Ja.blockKeyframeAnimation&&w(W,!!a)}function B(){return $=new h({end:j,cancel:l}),C(aa),q(),{$$willAnimate:!1,start:function(){return $},end:j}}function P(a){a.stopPropagation();var b=a.originalEvent||a,c=b.$manualTimeStamp||Date.now(),d=parseFloat(b.elapsedTime.toFixed(na));Math.max(c-ga,0)>=da&&d>=ea&&(Z=!0,q())}function Q(){function b(){if(!X){if(u(!1),T(ha,function(a){var b=a[0],c=a[1];W.style[b]=c}),L(a,S),d.addClass(a,wa),Ja.recalculateTimingStyles){if(va=W.getAttribute("class")+" "+ua,ya=t(W,va),Ha=F(W,va,ya),Ia=Ha.maxDelay,ba=Math.max(Ia,0),0===(ea=Ha.maxDuration))return void q();Ja.hasTransitions=Ha.transitionDuration>0,Ja.hasAnimations=Ha.animationDuration>0}if(Ja.applyAnimationDelay&&(Ia="boolean"!=typeof S.delay&&D(S.delay)?parseFloat(S.delay):Ia,ba=Math.max(Ia,0),Ha.animationDelay=Ia,Ka=A(Ia,!0),ha.push(Ka),W.style[Ka[0]]=Ka[1]),da=ba*ma,fa=ea*ma,S.easing){var b,e=S.easing;Ja.hasTransitions&&(b=H+ca,ha.push([b,e]),W.style[b]=e),Ja.hasAnimations&&(b=J+ca,ha.push([b,e]),W.style[b]=e)}Ha.transitionDuration&&ka.push(I),Ha.animationDuration&&ka.push(K),ga=Date.now();var f=da+oa*fa,g=ga+f,h=a.data(la)||[],j=!0;if(h.length){var k=h[0];j=g>k.expectedEndTime,j?i.cancel(k.timer):h.push(q)}if(j){var l=i(c,f,!1);h[0]={timer:l,expectedEndTime:g},h.push(q),a.data(la,h)}ka.length&&a.on(ka.join(" "),P),S.to&&(S.cleanupStyles&&G(V,W,Object.keys(S.to)),p(a,S))}}function c(){var b=a.data(la);if(b){for(var c=1;c<b.length;c++)b[c]();a.removeData(la)}}if(!X){if(!W.parentNode)return void q();var e=function(a){if(Z)Y&&a&&(Y=!1,q());else if(Y=!a,Ha.animationDuration){var b=w(W,Y);Y?ha.push(b):g(ha,b)}},f=Fa>0&&(Ha.transitionDuration&&0===za.transitionDuration||Ha.animationDuration&&0===za.animationDuration)&&Math.max(za.animationDelay,za.transitionDelay);f?i(b,Math.floor(f*Fa*ma),!1):b(),_.resume=function(){e(!0)},_.pause=function(){e(!1)}}}var S=c||{};S.$$prepared||(S=m(R(S)));var V={},W=s(a);if(!W||!W.parentNode||!r.enabled())return B();var X,Y,Z,$,_,ba,da,ea,fa,ga,ha=[],ia=a.attr("class"),ja=e(S),ka=[];if(0===S.duration||!k.animations&&!k.transitions)return B();var pa=S.event&&U(S.event)?S.event.join(" "):S.event,ra=pa&&S.structural,sa="",ta="";ra?sa=f(pa,O,!0):pa&&(sa=pa),S.addClass&&(ta+=f(S.addClass,M)),S.removeClass&&(ta.length&&(ta+=" "),ta+=f(S.removeClass,N)),S.applyClassesEarly&&ta.length&&L(a,S);var ua=[sa,ta].join(" ").trim(),va=ia+" "+ua,wa=f(ua,"-active"),xa=ja.to&&Object.keys(ja.to).length>0;if(!((S.keyframeStyle||"").length>0||xa||ua))return B();var ya,za;if(S.stagger>0){var Aa=parseFloat(S.stagger);za={transitionDelay:Aa,animationDelay:Aa,transitionDuration:0,animationDuration:0}}else ya=t(W,va),za=y(W,ua,ya,qa);S.$$skipPreparationClasses||d.addClass(a,ua);var Ba;if(S.transitionStyle){var Ca=[H,S.transitionStyle];x(W,Ca),ha.push(Ca)}if(S.duration>=0){Ba=W.style[H].length>0;var Da=E(S.duration,Ba);x(W,Da),ha.push(Da)}if(S.keyframeStyle){var Ea=[J,S.keyframeStyle];x(W,Ea),ha.push(Ea)}var Fa=za?S.staggerIndex>=0?S.staggerIndex:b.count(ya):0,Ga=0===Fa;Ga&&!S.skipBlocking&&v(W,9999);var Ha=F(W,va,ya),Ia=Ha.maxDelay;ba=Math.max(Ia,0),ea=Ha.maxDuration;var Ja={};if(Ja.hasTransitions=Ha.transitionDuration>0,Ja.hasAnimations=Ha.animationDuration>0,Ja.hasTransitionAll=Ja.hasTransitions&&"all"===Ha.transitionProperty,Ja.applyTransitionDuration=xa&&(Ja.hasTransitions&&!Ja.hasTransitionAll||Ja.hasAnimations&&!Ja.hasTransitions),Ja.applyAnimationDuration=S.duration&&Ja.hasAnimations,Ja.applyTransitionDelay=D(S.delay)&&(Ja.applyTransitionDuration||Ja.hasTransitions),Ja.applyAnimationDelay=D(S.delay)&&Ja.hasAnimations,Ja.recalculateTimingStyles=ta.length>0,(Ja.applyTransitionDuration||Ja.applyAnimationDuration)&&(ea=S.duration?parseFloat(S.duration):ea,Ja.applyTransitionDuration&&(Ja.hasTransitions=!0,Ha.transitionDuration=ea,Ba=W.style[H+"Property"].length>0,ha.push(E(ea,Ba))),Ja.applyAnimationDuration&&(Ja.hasAnimations=!0,Ha.animationDuration=ea,ha.push(z(ea)))),0===ea&&!Ja.recalculateTimingStyles)return B();if(null!=S.delay){var Ka;"boolean"!=typeof S.delay&&(Ka=parseFloat(S.delay),ba=Math.max(Ka,0)),Ja.applyTransitionDelay&&ha.push(A(Ka)),Ja.applyAnimationDelay&&ha.push(A(Ka,!0))}return null==S.duration&&Ha.transitionDuration>0&&(Ja.recalculateTimingStyles=Ja.recalculateTimingStyles||Ga),da=ba*ma,fa=ea*ma,S.skipBlocking||(Ja.blockTransition=Ha.transitionDuration>0,Ja.blockKeyframeAnimation=Ha.animationDuration>0&&za.animationDelay>0&&0===za.animationDuration),S.from&&(S.cleanupStyles&&G(V,W,Object.keys(S.from)),o(a,S)),Ja.blockTransition||Ja.blockKeyframeAnimation?u(ea):S.skipBlocking||v(W,!1),{$$willAnimate:!0,end:j,start:function(){if(!X)return _={end:j,cancel:l,resume:null,pause:null},$=new h(_),C(Q),$}}}}]}],sa=["$$animationProvider",function(a){function b(a){return a.parentNode&&11===a.parentNode.nodeType}a.drivers.push("$$animateCssDriver");var c="ng-animate-shim",d="ng-anchor-out";this.$get=["$animateCss","$rootScope","$$AnimateRunner","$rootElement","$sniffer","$$jqLite","$document",function(a,e,f,g,h,i,j){function k(a){return a.replace(/\bng-\S+\b/g,"")}function l(a,b){return Z(a)&&(a=a.split(" ")),Z(b)&&(b=b.split(" ")),a.filter(function(a){return-1===b.indexOf(a)}).join(" ")}function m(b,e,g){function h(a){var b={},c=s(a).getBoundingClientRect();return T(["width","height","top","left"],function(a){var d=c[a];switch(a){case"top":d+=p.scrollTop;break;case"left":d+=p.scrollLeft}b[a]=Math.floor(d)+"px"}),b}function i(a){return a.attr("class")||""}function j(){var b=k(i(g)),c=l(b,o),e=l(o,b),f=a(n,{to:h(g),addClass:"ng-anchor-in "+c,removeClass:d+" "+e,delay:!0});return f.$$willAnimate?f:null}function m(){n.remove(),e.removeClass(c),g.removeClass(c)}var n=_(s(e).cloneNode(!0)),o=k(i(n));e.addClass(c),g.addClass(c),n.addClass("ng-anchor"),r.append(n);var q,t=function(){var b=a(n,{addClass:d,delay:!0,from:h(e)});return b.$$willAnimate?b:null}();if(!t&&!(q=j()))return m();var u=t||q;return{start:function(){function a(){c&&c.end()}var b,c=u.start();return c.done(function(){if(c=null,!q&&(q=j()))return c=q.start(),c.done(function(){c=null,m(),b.complete()}),c;m(),b.complete()}),b=new f({end:a,cancel:a})}}}function n(a,b,c,d){
|
7 |
-
var e=o(a),g=o(b),h=[];if(T(d,function(a){var b=a.out,d=a.in,e=m(c,b,d);e&&h.push(e)}),e||g||0!==h.length)return{start:function(){function a(){T(b,function(a){a.end()})}var b=[];e&&b.push(e.start()),g&&b.push(g.start()),T(h,function(a){b.push(a.start())});var c=new f({end:a,cancel:a});return f.all(b,function(a){c.complete(a)}),c}}}function o(b){var c=b.element,d=b.options||{};b.structural&&(d.event=b.event,d.structural=!0,d.applyClassesEarly=!0,"leave"===b.event&&(d.onDone=d.domOperation)),d.preparationClasses&&(d.event=y(d.event,d.preparationClasses));var e=a(c,d);return e.$$willAnimate?e:null}if(!h.animations&&!h.transitions)return aa;var p=j[0].body,q=s(g),r=_(b(q)||p.contains(q)?q:p);return function(a){return a.from&&a.to?n(a.from,a.to,a.classes,a.anchors):o(a)}}]}],ta=["$animateProvider",function(a){this.$get=["$injector","$$AnimateRunner","$$jqLite",function(b,c,d){function e(c){c=U(c)?c:c.split(" ");for(var d=[],e={},f=0;f<c.length;f++){var g=c[f],h=a.$$registeredAnimations[g];h&&!e[g]&&(d.push(b.get(h)),e[g]=!0)}return d}var f=l(d);return function(a,b,d,g){function h(){g.domOperation(),f(a,g)}function i(){o=!0,h(),n(a,g)}function j(a,b,d,e,f){var g;switch(d){case"animate":g=[b,e.from,e.to,f];break;case"setClass":g=[b,r,s,f];break;case"addClass":g=[b,r,f];break;case"removeClass":g=[b,s,f];break;default:g=[b,f]}g.push(e);var h=a.apply(a,g);if(h)if(X(h.start)&&(h=h.start()),h instanceof c)h.done(f);else if(X(h))return h;return aa}function k(a,b,d,e,f){var g=[];return T(e,function(e){var h=e[f];h&&g.push(function(){var e,f,g=!1,i=function(a){g||(g=!0,(f||aa)(a),e.complete(!a))};return e=new c({end:function(){i()},cancel:function(){i(!0)}}),f=j(h,a,b,d,function(a){i(!1===a)}),e})}),g}function l(a,b,d,e,f){var g=k(a,b,d,e,f);if(0===g.length){var h,i;"beforeSetClass"===f?(h=k(a,"removeClass",d,e,"beforeRemoveClass"),i=k(a,"addClass",d,e,"beforeAddClass")):"setClass"===f&&(h=k(a,"removeClass",d,e,"removeClass"),i=k(a,"addClass",d,e,"addClass")),h&&(g=g.concat(h)),i&&(g=g.concat(i))}if(0!==g.length)return function(a){var b=[];return g.length&&T(g,function(a){b.push(a())}),b.length?c.all(b,a):a(),function(a){T(b,function(b){a?b.cancel():b.end()})}}}var o=!1;3===arguments.length&&Y(d)&&(g=d,d=null),g=m(g),d||(d=a.attr("class")||"",g.addClass&&(d+=" "+g.addClass),g.removeClass&&(d+=" "+g.removeClass));var p,q,r=g.addClass,s=g.removeClass,t=e(d);if(t.length){var u,v;"leave"===b?(v="leave",u="afterLeave"):(v="before"+b.charAt(0).toUpperCase()+b.substr(1),u=b),"enter"!==b&&"move"!==b&&(p=l(a,b,g,t,v)),q=l(a,b,g,t,u)}if(p||q){var w;return{$$willAnimate:!0,end:function(){return w?w.end():(i(),w=new c,w.complete(!0)),w},start:function(){function a(a){i(a),w.complete(a)}function b(b){o||((d||aa)(b),a(b))}if(w)return w;w=new c;var d,e=[];return p&&e.push(function(a){d=p(a)}),e.length?e.push(function(a){h(),a(!0)}):h(),q&&e.push(function(a){d=q(a)}),w.setHost({end:function(){b()},cancel:function(){b(!0)}}),c.chain(e,a),w}}}}}]}],ua=["$$animationProvider",function(a){a.drivers.push("$$animateJsDriver"),this.$get=["$$animateJs","$$AnimateRunner",function(a,b){function c(b){var c=b.element,d=b.event,e=b.options,f=b.classes;return a(c,d,f,e)}return function(a){if(a.from&&a.to){var d=c(a.from),e=c(a.to);if(!d&&!e)return;return{start:function(){function a(){return function(){T(f,function(a){a.end()})}}function c(a){g.complete(a)}var f=[];d&&f.push(d.start()),e&&f.push(e.start()),b.all(f,c);var g=new b({end:a(),cancel:a()});return g}}}return c(a)}}]}],va="data-ng-animate",wa="$ngAnimatePin",xa=["$animateProvider",function(b){function d(a){if(!a)return null;var b=a.split(o),c=Object.create(null);return T(b,function(a){c[a]=!0}),c}function e(a,b){if(a&&b){var c=d(b);return a.split(o).some(function(a){return c[a]})}}function f(a,b,c){return p[a].some(function(a){return a(b,c)})}function g(a,b){var c=(a.addClass||"").length>0,d=(a.removeClass||"").length>0;return b?c&&d:c||d}var j=1,k=2,o=" ",p=this.rules={skip:[],cancel:[],join:[]};p.join.push(function(a,b){return!a.structural&&g(a)}),p.skip.push(function(a,b){return!a.structural&&!g(a)}),p.skip.push(function(a,b){return"leave"===b.event&&a.structural}),p.skip.push(function(a,b){return b.structural&&b.state===k&&!a.structural}),p.cancel.push(function(a,b){return b.structural&&a.structural}),p.cancel.push(function(a,b){return b.state===k&&a.structural}),p.cancel.push(function(a,b){if(b.structural)return!1;var c=a.addClass,d=a.removeClass,f=b.addClass,g=b.removeClass;return!($(c)&&$(d)||$(f)&&$(g))&&(e(c,g)||e(d,f))}),this.$get=["$$rAF","$rootScope","$rootElement","$document","$$Map","$$animation","$$AnimateRunner","$templateRequest","$$jqLite","$$forceReflow","$$isDocumentHidden",function(d,e,o,p,r,v,w,x,y,z,A){function B(){var a=!1;return function(b){a?b():e.$$postDigest(function(){a=!0,b()})}}function C(a,b){return q(a,b,{})}function D(a,b,c){var d=[],e=X[c];return e&&T(e,function(e){ga.call(e.node,b)?d.push(e.callback):"leave"===c&&ga.call(e.node,a)&&d.push(e.callback)}),d}function E(a,b,c){var d=i(b);return a.filter(function(a){return!(a.node===d&&(!c||a.callback===c))})}function F(a,b){"close"!==a||b.parentNode||ha.off(b)}function G(a,b,c){function i(a,b,c,e){z(function(){var a=D(x,r,b);a.length?d(function(){T(a,function(a){a(p,c,e)}),F(c,r)}):F(c,r)}),a.progress(b,c,e)}function l(a){u(p,o),fa(p,o),n(p,o),o.domOperation(),y.complete(!a)}var o=R(c),p=h(a),r=s(p),x=r&&r.parentNode;o=m(o);var y=new w,z=B();if(U(o.addClass)&&(o.addClass=o.addClass.join(" ")),o.addClass&&!Z(o.addClass)&&(o.addClass=null),U(o.removeClass)&&(o.removeClass=o.removeClass.join(" ")),o.removeClass&&!Z(o.removeClass)&&(o.removeClass=null),o.from&&!Y(o.from)&&(o.from=null),o.to&&!Y(o.to)&&(o.to=null),!(O&&r&&da(r,b,c)&&ea(r,o)))return l(),y;var E=["enter","move","leave"].indexOf(b)>=0,G=A(),L=G||N.get(r),P=!L&&M.get(r)||{},Q=!!P.state;if(L||Q&&P.state===j||(L=!J(r,x,b)),L)return G&&i(y,b,"start"),l(),G&&i(y,b,"close"),y;E&&H(r);var S={structural:E,element:p,event:b,addClass:o.addClass,removeClass:o.removeClass,close:l,options:o,runner:y};if(Q){if(f("skip",S,P))return P.state===k?(l(),y):(q(p,P,S),P.runner);if(f("cancel",S,P))if(P.state===k)P.runner.end();else{if(!P.structural)return q(p,P,S),P.runner;P.close()}else{if(f("join",S,P)){if(P.state!==k)return t(p,E?b:null,o),b=S.event=P.event,o=q(p,P,S),P.runner;C(p,S)}}}else C(p,S);var V=S.structural;if(V||(V="animate"===S.event&&Object.keys(S.options.to||{}).length>0||g(S)),!V)return l(),I(r),y;var W=(P.counter||0)+1;return S.counter=W,K(r,j,S),e.$$postDigest(function(){p=h(a);var c=M.get(r),d=!c;c=c||{};var e=p.parent()||[],f=e.length>0&&("animate"===c.event||c.structural||g(c));if(d||c.counter!==W||!f)return d&&(fa(p,o),n(p,o)),(d||E&&c.event!==b)&&(o.domOperation(),y.end()),void(f||I(r));b=!c.structural&&g(c,!0)?"setClass":c.event,K(r,k);var j=v(p,b,c.options);y.setHost(j),i(y,b,"start",{}),j.done(function(a){l(!a);var c=M.get(r);c&&c.counter===W&&I(r),i(y,b,"close",{})})}),y}function H(a){var b=a.querySelectorAll("["+va+"]");T(b,function(a){var b=parseInt(a.getAttribute(va),10),c=M.get(a);if(c)switch(b){case k:c.runner.end();case j:M.delete(a)}})}function I(a){a.removeAttribute(va),M.delete(a)}function J(a,b,c){var d,e=p[0].body,f=s(o),g=a===e||"HTML"===a.nodeName,h=a===f,i=!1,j=N.get(a),k=_.data(a,wa);for(k&&(b=s(k));b&&(h||(h=b===f),b.nodeType===L);){var l=M.get(b)||{};if(!i){var m=N.get(b);if(!0===m&&!1!==j){j=!0;break}!1===m&&(j=!1),i=l.structural}if($(d)||!0===d){var n=_.data(b,Q);V(n)&&(d=n)}if(i&&!1===d)break;if(g||(g=b===e),g&&h)break;b=h||!(k=_.data(b,wa))?b.parentNode:s(k)}return(!i||d)&&!0!==j&&h&&g}function K(a,b,c){c=c||{},c.state=b,a.setAttribute(va,b);var d=M.get(a),e=d?S(d,c):c;M.set(a,e)}var M=new r,N=new r,O=null,P=e.$watch(function(){return 0===x.totalPendingRequests},function(a){a&&(P(),e.$$postDigest(function(){e.$$postDigest(function(){null===O&&(O=!0)})}))}),X=Object.create(null),aa=b.customFilter(),ba=b.classNameFilter(),ca=function(){return!0},da=aa||ca,ea=ba?function(a,b){var c=[a.getAttribute("class"),b.addClass,b.removeClass].join(" ");return ba.test(c)}:ca,fa=l(y),ga=a.Node.prototype.contains||function(a){return this===a||!!(16&this.compareDocumentPosition(a))},ha={on:function(a,b,c){var d=i(b);X[a]=X[a]||[],X[a].push({node:d,callback:c}),_(b).on("$destroy",function(){M.get(d)||ha.off(a,b,c)})},off:function(a,b,c){if(1!==arguments.length||Z(arguments[0])){var d=X[a];d&&(X[a]=1===arguments.length?null:E(d,b,c))}else{b=arguments[0];for(var e in X)X[e]=E(X[e],b)}},pin:function(a,b){c(W(a),"element","not an element"),c(W(b),"parentElement","not an element"),a.data(wa,b)},push:function(a,b,c,d){return c=c||{},c.domOperation=d,G(a,b,c)},enabled:function(a,b){var c=arguments.length;if(0===c)b=!!O;else{if(W(a)){var d=s(a);1===c?b=!N.get(d):N.set(d,!b)}else b=O=!!a}return b}};return ha}]}],ya=["$animateProvider",function(a){function b(a,b){a.data(h,b)}function c(a){a.removeData(h)}function e(a){return a.data(h)}var f="ng-animate-ref",g=this.drivers=[],h="$$animationRunner";this.$get=["$$jqLite","$rootScope","$injector","$$AnimateRunner","$$Map","$$rAFScheduler",function(a,h,i,j,k,o){function p(a){function b(a){if(a.processed)return a;a.processed=!0;var c=a.domNode,f=c.parentNode;e.set(c,a);for(var g;f;){if(g=e.get(f)){g.processed||(g=b(g));break}f=f.parentNode}return(g||d).children.push(a),a}var c,d={children:[]},e=new k;for(c=0;c<a.length;c++){var f=a[c];e.set(f.domNode,a[c]={domNode:f.domNode,fn:f.fn,children:[]})}for(c=0;c<a.length;c++)b(a[c]);return function(a){var b,c=[],d=[];for(b=0;b<a.children.length;b++)d.push(a.children[b]);var e=d.length,f=0,g=[];for(b=0;b<d.length;b++){var h=d[b];e<=0&&(e=f,f=0,c.push(g),g=[]),g.push(h.fn),h.children.forEach(function(a){f++,d.push(a)}),e--}return g.length&&c.push(g),c}(d)}var q=[],r=l(a);return function(k,l,t){function u(a){var b="["+f+"]",c=a.hasAttribute(f)?[a]:a.querySelectorAll(b),d=[];return T(c,function(a){var b=a.getAttribute(f);b&&b.length&&d.push(a)}),d}function v(a){var b=[],c={};T(a,function(a,d){var e=a.element,g=s(e),h=a.event,i=["enter","move"].indexOf(h)>=0,j=a.structural?u(g):[];if(j.length){var k=i?"to":"from";T(j,function(a){var b=a.getAttribute(f);c[b]=c[b]||{},c[b][k]={animationID:d,element:_(a)}})}else b.push(a)});var d={},e={};return T(c,function(c,f){var g=c.from,h=c.to;if(!g||!h){var i=g?g.animationID:h.animationID,j=i.toString();return void(d[j]||(d[j]=!0,b.push(a[i])))}var k=a[g.animationID],l=a[h.animationID],m=g.animationID.toString();if(!e[m]){var n=e[m]={structural:!0,beforeStart:function(){k.beforeStart(),l.beforeStart()},close:function(){k.close(),l.close()},classes:w(k.classes,l.classes),from:k,to:l,anchors:[]};n.classes.length?b.push(n):(b.push(k),b.push(l))}e[m].anchors.push({out:g.element,in:h.element})}),b}function w(a,b){a=a.split(" "),b=b.split(" ");for(var c=[],d=0;d<a.length;d++){var e=a[d];if("ng-"!==e.substring(0,3))for(var f=0;f<b.length;f++)if(e===b[f]){c.push(e);break}}return c.join(" ")}function x(a){for(var b=g.length-1;b>=0;b--){var c=g[b],d=i.get(c),e=d(a);if(e)return e}}function y(){k.addClass(P),F&&a.addClass(k,F),G&&(a.removeClass(k,G),G=null)}function z(a,b){function c(a){var c=e(a);c&&c.setHost(b)}a.from&&a.to?(c(a.from.element),c(a.to.element)):c(a.element)}function A(){var a=e(k);!a||"leave"===l&&t.$$domOperationFired||a.end()}function B(b){k.off("$destroy",A),c(k),r(k,t),n(k,t),t.domOperation(),F&&a.removeClass(k,F),k.removeClass(P),D.complete(!b)}t=m(t);var C=["enter","move","leave"].indexOf(l)>=0,D=new j({end:function(){B()},cancel:function(){B(!0)}});if(!g.length)return B(),D;b(k,D);var E=d(k.attr("class"),d(t.addClass,t.removeClass)),F=t.tempClasses;F&&(E+=" "+F,t.tempClasses=null);var G;return C&&(G="ng-"+l+"-prepare",a.addClass(k,G)),q.push({element:k,classes:E,event:l,structural:C,options:t,beforeStart:y,close:B}),k.on("$destroy",A),q.length>1?D:(h.$$postDigest(function(){var a=[];T(q,function(b){e(b.element)?a.push(b):b.close()}),q.length=0;var b=v(a),c=[];T(b,function(a){c.push({domNode:s(a.from?a.from.element:a.element),fn:function(){a.beforeStart();var b,c=a.close;if(e(a.anchors?a.from.element||a.to.element:a.element)){var d=x(a);d&&(b=d.start)}if(b){var f=b();f.done(function(a){c(!a)}),z(a,f)}else c()}})}),o(p(c))}),D)}}]}],za=["$animate","$rootScope",function(a,b){return{restrict:"A",transclude:"element",terminal:!0,priority:600,link:function(b,c,d,e,f){var g,h;b.$watchCollection(d.ngAnimateSwap||d.for,function(d){g&&a.leave(g),h&&(h.$destroy(),h=null),(d||0===d)&&(h=b.$new(),f(h,function(b){g=b,a.enter(b,null,c)}))})}}}];b.module("ngAnimate",[],function(){aa=b.noop,R=b.copy,S=b.extend,_=b.element,T=b.forEach,U=b.isArray,Z=b.isString,Y=b.isObject,$=b.isUndefined,V=b.isDefined,X=b.isFunction,W=b.isElement}).info({angularVersion:"1.6.6"}).directive("ngAnimateSwap",za).directive("ngAnimateChildren",ka).factory("$$rAFScheduler",ja).provider("$$animateQueue",xa).provider("$$animation",ya).provider("$animateCss",ra).provider("$$animateCssDriver",sa).provider("$$animateJs",ta).provider("$$animateJsDriver",ua)}(window,window.angular),function(a,b){"use strict";function c(){function c(a,b){var c,d={},e=a.split(",");for(c=0;c<e.length;c++)d[b?i(e[c]):e[c]]=!0;return d}function d(a,b){null===a||void 0===a?a="":"string"!=typeof a&&(a=""+a);var c=J(a);if(!c)return"";var d=5;do{if(0===d)throw n("uinput","Failed to sanitize html because the input is unstable");d--,a=c.innerHTML,c=J(a)}while(a!==c.innerHTML);for(var e=c.firstChild;e;){switch(e.nodeType){case 1:b.start(e.nodeName.toLowerCase(),o(e.attributes));break;case 3:b.chars(e.textContent)}var f;if(!((f=e.firstChild)||(1===e.nodeType&&b.end(e.nodeName.toLowerCase()),f=s("nextSibling",e))))for(;null==f&&(e=s("parentNode",e))!==c;)f=s("nextSibling",e),1===e.nodeType&&b.end(e.nodeName.toLowerCase());e=f}for(;e=c.firstChild;)c.removeChild(e)}function o(a){for(var b={},c=0,d=a.length;c<d;c++){var e=a[c];b[e.name]=e.value}return b}function p(a){return a.replace(/&/g,"&").replace(u,function(a){return"&#"+(1024*(a.charCodeAt(0)-55296)+(a.charCodeAt(1)-56320)+65536)+";"}).replace(v,function(a){return"&#"+a.charCodeAt(0)+";"}).replace(/</g,"<").replace(/>/g,">")}function q(a,b){var c=!1,d=e(a,a.push);return{start:function(a,e){a=i(a),!c&&D[a]&&(c=a),c||!0!==E[a]||(d("<"),d(a),g(e,function(c,e){var f=i(e),g="img"===a&&"src"===f||"background"===f;!0!==I[f]||!0===F[f]&&!b(c,g)||(d(" "),d(e),d('="'),d(p(c)),d('"'))}),d(">"))},end:function(a){a=i(a),c||!0!==E[a]||!0===w[a]||(d("</"),d(a),d(">")),a==c&&(c=!1)},chars:function(a){c||d(p(a))}}}function r(b){for(;b;){if(b.nodeType===a.Node.ELEMENT_NODE)for(var c=b.attributes,d=0,e=c.length;d<e;d++){var f=c[d],g=f.name.toLowerCase();"xmlns:ns1"!==g&&0!==g.lastIndexOf("ns1:",0)||(b.removeAttributeNode(f),d--,e--)}var h=b.firstChild;h&&r(h),b=s("nextSibling",b)}}function s(a,b){var c=b[a];if(c&&k.call(b,c))throw n("elclob","Failed to sanitize html because the element is clobbered: {0}",b.outerHTML||b.outerText);return c}var t=!1;this.$get=["$$sanitizeUri",function(a){return t&&f(E,C),function(b){var c=[];return l(b,m(c,function(b,c){return!/^unsafe:/.test(a(b,c))})),c.join("")}}],this.enableSvg=function(a){return h(a)?(t=a,this):t},e=b.bind,f=b.extend,g=b.forEach,h=b.isDefined,i=b.lowercase,j=b.noop,l=d,m=q,k=a.Node.prototype.contains||function(a){return!!(16&this.compareDocumentPosition(a))};var u=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,v=/([^#-~ |!])/g,w=c("area,br,col,hr,img,wbr"),x=c("colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr"),y=c("rp,rt"),z=f({},y,x),A=f({},x,c("address,article,aside,blockquote,caption,center,del,dir,div,dl,figure,figcaption,footer,h1,h2,h3,h4,h5,h6,header,hgroup,hr,ins,map,menu,nav,ol,pre,section,table,ul")),B=f({},y,c("a,abbr,acronym,b,bdi,bdo,big,br,cite,code,del,dfn,em,font,i,img,ins,kbd,label,map,mark,q,ruby,rp,rt,s,samp,small,span,strike,strong,sub,sup,time,tt,u,var")),C=c("circle,defs,desc,ellipse,font-face,font-face-name,font-face-src,g,glyph,hkern,image,linearGradient,line,marker,metadata,missing-glyph,mpath,path,polygon,polyline,radialGradient,rect,stop,svg,switch,text,title,tspan"),D=c("script,style"),E=f({},w,A,B,z),F=c("background,cite,href,longdesc,src,xlink:href"),G=c("abbr,align,alt,axis,bgcolor,border,cellpadding,cellspacing,class,clear,color,cols,colspan,compact,coords,dir,face,headers,height,hreflang,hspace,ismap,lang,language,nohref,nowrap,rel,rev,rows,rowspan,rules,scope,scrolling,shape,size,span,start,summary,tabindex,target,title,type,valign,value,vspace,width"),H=c("accent-height,accumulate,additive,alphabetic,arabic-form,ascent,baseProfile,bbox,begin,by,calcMode,cap-height,class,color,color-rendering,content,cx,cy,d,dx,dy,descent,display,dur,end,fill,fill-rule,font-family,font-size,font-stretch,font-style,font-variant,font-weight,from,fx,fy,g1,g2,glyph-name,gradientUnits,hanging,height,horiz-adv-x,horiz-origin-x,ideographic,k,keyPoints,keySplines,keyTimes,lang,marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,mathematical,max,min,offset,opacity,orient,origin,overline-position,overline-thickness,panose-1,path,pathLength,points,preserveAspectRatio,r,refX,refY,repeatCount,repeatDur,requiredExtensions,requiredFeatures,restart,rotate,rx,ry,slope,stemh,stemv,stop-color,stop-opacity,strikethrough-position,strikethrough-thickness,stroke,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke-width,systemLanguage,target,text-anchor,to,transform,type,u1,u2,underline-position,underline-thickness,unicode,unicode-range,units-per-em,values,version,viewBox,visibility,width,widths,x,x-height,x1,x2,xlink:actuate,xlink:arcrole,xlink:role,xlink:show,xlink:title,xlink:type,xml:base,xml:lang,xml:space,xmlns,xmlns:xlink,y,y1,y2,zoomAndPan",!0),I=f({},F,H,G),J=function(a,b){function c(b){b="<remove></remove>"+b;try{b=encodeURI(b)}catch(a){return}var c=new a.XMLHttpRequest;c.responseType="document",c.open("GET","data:text/html;charset=utf-8,"+b,!1),c.send(null);var d=c.response.body;return d.firstChild.remove(),d}function d(b){b="<remove></remove>"+b;try{var c=(new a.DOMParser).parseFromString(b,"text/html").body;return c.firstChild.remove(),c}catch(a){return}}function e(a){return g.innerHTML=a,b.documentMode&&r(g),g}var f;if(!b||!b.implementation)throw n("noinert","Can't create an inert html document");f=b.implementation.createHTMLDocument("inert");var g=(f.documentElement||f.getDocumentElement()).querySelector("body");return g.innerHTML='<svg><g onload="this.parentNode.remove()"></g></svg>',g.querySelector("svg")?(g.innerHTML='<svg><p><style><img src="</style><img src=x onerror=alert(1)//">',g.querySelector("svg img")?d:e):c}(a,a.document)}function d(a){var b=[];return m(b,j).chars(a),b.join("")}var e,f,g,h,i,j,k,l,m,n=b.$$minErr("$sanitize");b.module("ngSanitize",[]).provider("$sanitize",c).info({angularVersion:"1.6.6"}),b.module("ngSanitize").filter("linky",["$sanitize",function(a){var c=/((ftp|https?):\/\/|(www\.)|(mailto:)?[A-Za-z0-9._%+-]+@)\S*[^\s.;,(){}<>"\u201d\u2019]/i,e=/^mailto:/i,f=b.$$minErr("linky"),g=b.isDefined,h=b.isFunction,i=b.isObject,j=b.isString;return function(b,k,l){function m(a){a&&s.push(d(a))}if(null==b||""===b)return b;if(!j(b))throw f("notstring","Expected string but received: {0}",b);for(var n,o,p,q=h(l)?l:i(l)?function(){return l}:function(){return{}},r=b,s=[];n=r.match(c);)o=n[0],n[2]||n[4]||(o=(n[3]?"http://":"mailto:")+o),p=n.index,m(r.substr(0,p)),function(a,b){var c,d=q(a);s.push("<a ");for(c in d)s.push(c+'="'+d[c]+'" ');!g(k)||"target"in d||s.push('target="',k,'" '),s.push('href="',a.replace(/"/g,"""),'">'),m(b),s.push("</a>")}(o,n[0].replace(e,"")),r=r.substring(p+n[0].length);return m(r),a(s.join(""))}}])}(window,window.angular),function(){function a(){return{restrict:"AEC",require:"dxStartWith",controller:"dxStartWithCtrl",scope:!0,terminal:!0,transclude:!0,multiElement:!0,$$tlb:!0,compile:function(a,b){var c=b.dxStartWith||b.root,e=c.match(d),f=e[1],g=e[3]||"";return function(a,b,c,d,e){d.alias=g,d.transclude=e,d.transclude(a,function(a,c){function d(a){c.$dxPrior=a,""!==g&&(c[g]=a)}b.append(a),c.$dxLevel=0,c.$dxIsRoot=!0,c.$watch(f,d)})}}}}function b(){return{restrict:"AEC",require:"^dxStartWith",scope:!0,terminal:!0,multiElement:!0,compile:function(a,b){var c=b.dxConnect||b.connect;return function(a,b,d,e){alias=e.alias||"",e.transclude(a,function(a,d){function e(a){d.$dxPrior=a,""!==alias&&(d[alias]=a)}b.append(a),d.$dxLevel=d.$dxLevel+1,d.$dxIsRoot=!1,d.$watch(c,e)})}}}}var c=angular.module("dotjem.angular.tree",[]),d=/^(\S+)(\s+as\s+(\w+))?$/;c.controller("dxStartWithCtrl",[function(){}]),c.directive("dxStartWith",a),c.directive("dxConnect",b)}(),function(){"use strict";function a(a,b,c){return{restrict:"A",link:function(d,e,f){c(function(){function g(a){var g,h,k,l,m,n;if(!angular.element(e).hasClass("ng-hide")&&a&&a.target){for(h=a.target;h;h=h.parentNode){if(h===e[0])return;if(l=h.id,m=h.className,n=j.length,m&&void 0!==m.baseVal&&(m=m.baseVal),m||l)for(g=0;g<n;g++)if(k=new RegExp("\\b"+j[g]+"\\b"),void 0!==l&&l===j[g]||m&&k.test(m))return}c(function(){(i=b(f.clickOutside))(d,{event:a})})}}function h(){return"ontouchstart"in window||navigator.maxTouchPoints}var i,j=void 0!==f.outsideIfNot?f.outsideIfNot.split(/[ ,]+/):[];h()&&a.on("touchstart",g),a.on("click",g),d.$on("$destroy",function(){h()&&a.off("touchstart",g),a.off("click",g)})})}}}angular.module("angular-click-outside",[]).directive("clickOutside",["$document","$parse","$timeout",a])}();var GoogleMerchants=angular.module("GoogleMerchants",["templates-dist","dotjem.angular.tree","ngSanitize","ngAnimate","ng-slide-down","angular-click-outside"]);GoogleMerchants.constant("BACKEND",ajaxurl+"?action=wpae_api&q="),GoogleMerchants.filter("safe",["$sce",function(a){return a.trustAsHtml}]),GoogleMerchants.controller("advancedAttributesController",["$scope","$log","attributesService",function(a,b,c){a.attributes=[],a.cats=[],a.attributes=c.getAttributes()}]),GoogleMerchants.directive("advancedAttributes",function(){return{restrict:"E",scope:{advancedAttributes:"=information"},templateUrl:"advancedAttributes/advancedAttributes.tpl.html",controller:"advancedAttributesController"}}),GoogleMerchants.controller("availabilityPriceController",["$scope","currencyService",function(a,b){a.currency=b.getCurrency()}]),GoogleMerchants.directive("availabilityPrice",function(){return{restrict:"E",scope:{availabilityPrice:"=information"},templateUrl:"availabilityPrice/availabilityPrice.tpl.html",controller:"availabilityPriceController"}}),GoogleMerchants.controller("basicInformationController",["$scope",function(a){}]),GoogleMerchants.directive("basicInformation",function(){return{restrict:"E",scope:{basicInformation:"=information"},templateUrl:"basicInformation/basicInformation.tpl.html",controller:"basicInformationController"}}),GoogleMerchants.directive("chosen",["$timeout",chosen]),GoogleMerchants.factory("attributesService",["$rootScope","$q","$log","wpHttp",function(a,b,c,d){var e=!1;return{setAttributes:function(a){e=a},getAttributes:function(){return e}}}]),GoogleMerchants.directive("autodetect",["attributesService",function(a){return{restrict:"A",require:"^ngModel",link:{post:function(b,c,d,e){var f=d.autodetect;d=a.getAttributes(),angular.forEach(d,function(a){a.label.toLowerCase()!=f.toLowerCase()&&a.name.toLowerCase()!=f.toLowerCase()||(e.$setViewValue("{"+a.name+"}"),e.$render())})}}}}]),GoogleMerchants.directive("cascade",[function(){return{restrict:"A",controller:["$scope",function(a){function b(c,d){var e,f;for(e=0;e<d.children.length;e+=1)f=d.children[e],a.mappings[f.id]=c,b(c,f);return!1}a.select=function(){console.log("Changing to ",a.mappings[a.node.id]),b(a.mappings[a.node.id],a.node)}}]}}]),GoogleMerchants.directive("contenteditable",["$sce",function(a){return{restrict:"A",require:"?ngModel",link:function(b,c,d,e){function f(){var a=c.html();d.stripBr&&"<br>"===a&&(a=""),e.$setViewValue(a)}e&&(e.$render=function(){c.html(a.getTrustedHtml(e.$viewValue||""))},c.on("blur keyup change",function(){b.$evalAsync(f)}),f())}}}]),GoogleMerchants.factory("currencyService",[function(){var a=null,b=null;return{setCurrency:function(c,d){a=c,b=d},getCurrency:function(){return a},getCurrencyCode:function(){return b}}}]),GoogleMerchants.directive("droppable",[function(){return{restrict:"A",require:"^ngModel",link:function(a,b,c,d){function e(a,b){return-1!==a.find("input[name^=cc_type]").val().indexOf("image_")&&(b="Image "+b),-1!==a.find("input[name^=cc_type]").val().indexOf("attachment_")&&(b="Attachment "+b),b}var f;f=angular.element(b),f.addClass("google-merchants-droppable"),f.droppable({drop:function(a,b){var c=b.draggable.find(".custom_column"),g=c.find("input[name^=cc_name]").val();g=e(c,g),f.val(f.val()+"{"+g+"}"),d.$setViewValue(f.val()),d.$render()}})}}}]),GoogleMerchants.factory("exportService",["$q","$log","wpHttp",function(a,b,c){return{getExport:function(d){var e=a.defer(),f="export/get";return null!==d&&(f=f+"&id="+d),c.get(f).then(function(a){e.resolve(a)},function(a,c){e.reject(a,c),b.error("There was a problem getting the export")}),e.promise},saveExport:function(d){var e=a.defer();return c.post("export/save",d).then(function(a){e.resolve(a)},function(a,c){e.reject(a),b.error(a,c)}),e.promise}}}]),GoogleMerchants.directive("focusMeWhenEnabled",function(a){return{priority:-1,link:function(b,c){b.$watch(function(){return b.$eval(c.attr("ng-disabled"))},function(b){0==b&&a(function(){c[0].focus()})})}}}),GoogleMerchants.factory("googleCategoriesService",["$rootScope","$q","$log","wpHttp",function(a,b,c,d){return{searchCategories:function(a){return d.get("googleCategories/get&parent=0"+a)},getChildCategories:function(a){return d.get("googleCategories/get&parent="+a)},categorySelected:function(b){a.$broadcast("wpae.category.selected",b)}}}]),GoogleMerchants.controller("mainController",["$scope","$rootScope","$timeout","$window","$document","$location","$log","templateService","exportService","currencyService","attributesService","wpHttp",function(a,b,c,d,e,f,g,h,i,j,k,l){function m(a,b){b||(b=window.location.href),a=a.replace(/[\[\]]/g,"\\$&");var c=new RegExp("[?&]"+a+"(=([^&#]*)|&|#|$)"),d=c.exec(b);return d?d[2]?decodeURIComponent(d[2].replace(/\+/g," ")):"":null}function n(){b.cats.children.length||(a.merchantsFeedData.productCategories.productCategories="customValue")}var o=[{mapFrom:"",mapTo:""}];a.cats=[],a.templateId=!1,a.merchantsFeedData={basicInformation:{open:!0,itemTitle:"productTitle",hasVariations:!0,useParentTitleForVariableProducts:!0,additionalImageLink:"productImages",itemDescription:"productDescription",itemImageLink:"useProductFeaturedImage",itemLink:"productLink",condition:"new",conditionMappings:angular.copy(o),userVariationDescriptionForVariableProducts:!0,addVariationAttributesToProductUrl:!0,useVariationImage:!0,useFeaturedImageIfThereIsNoVariationImage:!0,useParentDescirptionIfThereIsNoVariationDescirption:!0,useVariationDescriptionForVariableProducts:!0},detailedInformation:{open:!1,color:"selectFromWooCommerceProductAttributes",size:"selectFromWooCommerceProductAttributes",gender:"selectFromWooCommerceProductAttributes",setTheGroupId:"automatically",mappings:angular.copy(o),ageGroup:"selectFromWooCommerceProductAttributes",material:"selectFromWooCommerceProductAttributes",pattern:"selectFromWooCommerceProductAttributes",genderAutodetect:"keepBlank",sizeSystem:"",adjustPrice:!1,adjustSalePrice:!1,genderCats:{},ageGroupCats:{},sizeTypeMappings:angular.copy(o)},availabilityPrice:{open:!1,price:"useProductPrice",salePrice:"useProductSalePrice",availability:"useWooCommerceStockValues",adjustPriceValue:"",adjustPriceType:"%",adjustSalePriceType:"%",adjustSalePriceValue:"",currency:null},productCategories:{open:!1,productType:"useWooCommerceProductCategories",productCategories:"mapProductCategories",catMappings:{}},uniqueIdentifiers:{open:!1,identifierExists:1},shipping:{dimensions:"useWooCommerceProductValues",convertTo:"cm",adjustPriceType:"%",weight:""},template:{save:!1,name:""},advancedAttributes:{adult:"no",unitPricingBaseMeasureUnit:"kg",excludedDestination:"no",customLabel0Mappings:angular.copy(o),customLabel1Mappings:angular.copy(o),customLabel2Mappings:angular.copy(o),customLabel3Mappings:angular.copy(o),customLabel4Mappings:angular.copy(o),energyEfficiencyClassMappings:angular.copy(o),promotionIdMappings:angular.copy(o)}},a.init=function(b,c,d){k.setAttributes(wpae_product_attributes),a.isGoogleMerchantExport=!1,j.setCurrency(b,c),a.templateId=d},a.selectGoogleMerchantsInitially=function(){a.selectGoogleMerchants()},a.selectGoogleMerchants=function(){jQuery(".wpallexport-element-label").parent().parent().slideUp(),a.isGoogleMerchantExport=!0;var c=m("id");i.getExport(c).then(function(b){angular.isObject(b)&&(b.template={save:!1,name:""},a.merchantsFeedData=b)}),a.templateId&&(console.log("Loading template with id "+a.templateId),h.getTemplate(a.templateId).then(function(b){a.merchantsFeedData=b.google_merchants_post_data})),l.get("categories/index").then(function(a){b.cats=a,console.log("Broadcasting loaded categories..."),b.$broadcast("categories.loaded"),n()},function(){g.error("There was a problem loading the WordPress categories")}),null==a.merchantsFeedData.availabilityPrice.currency&&(a.merchantsFeedData.availabilityPrice.currency=j.getCurrencyCode())},a.$on("googleMerchantsSelected",function(b,d){a.selectGoogleMerchants(),a.merchantsFeedData.basicInformation.hasVariations=d,jQuery(".wpallexport-element-label").parent().parent().slideUp(),c(function(){a.isGoogleMerchantExport=!0})}),a.$on("googleMerchantsDeselected",function(){jQuery(".wpallexport-element-label").parent().parent().slideDown(),c(function(){a.isGoogleMerchantExport=!1})}),a.$on("googleMerchantsSubmitted",function(b,c){a.merchantsFeedData.template.name=c.templateName,a.process()}),a.$on("templateShouldBeSaved",function(b,c){a.merchantsFeedData.template.save=!0,a.merchantsFeedData.template.name=c}),a.$on("templateShouldNotBeSaved",function(){a.merchantsFeedData.template.save=!1}),a.$on("selectedTemplate",function(b,c){h.getTemplate(c).then(function(b){a.merchantsFeedData=b.google_merchants_post_data})}),a.process=function(){a.merchantsFeedData.extraData=jQuery("#templateForm").serialize(),a.merchantsFeedData.filteringData=jQuery("input[name=filter_rules_hierarhy]").val(),a.merchantsFeedData.template.save=jQuery("#save_template_as").prop("checked");var b=m("id");b&&(a.merchantsFeedData.exportId=b,a.merchantsFeedData.update=!0),i.saveExport(a.merchantsFeedData).then(function(a){a.redirect?d.location.href=a.redirect:d.location.href="admin.php?page=pmxe-admin-export&action=options"})}}]),GoogleMerchants.controller("mappingController",["$scope",function(a){a.show=!1,a.mappingsBackup=null,a.removeMapping=function(b){a.mappings.length>1&&a.mappings.splice(a.mappings.indexOf(b),1)},a.$watch("show",function(b){b&&(a.mappingsBackup=a.mappings)}),a.addMapping=function(){a.mappings.push({})},a.close=function(){a.mappings=a.mappingsBackup,a.show=!1},a.saveMappings=function(){a.show=!1}}]),GoogleMerchants.directive("mapping",function(){return{restrict:"E",scope:{mappings:"=",show:"=",context:"=",tooltip:"@"},templateUrl:"common/mapping/mapping.tpl.html",controller:"mappingController"}}),GoogleMerchants.directive("styledInput",function(a){return{priority:-1,scope:{placeholder:"=",ngModel:"="},template:'<div class="editable" contenteditable="true" ng-model="ngModel" placeholder="{{placeholder}}"></div>',link:function(a,b){b.bind("keydown",function(a){return(!a.ctrlKey&&!a.metaKey||65==a.which||88==a.which||67==a.which||86==a.which)&&(13!=a.which&&void 0)})}}}),GoogleMerchants.factory("templateService",["$q","$log","wpHttp",function(a,b,c){return{getTemplate:function(d){var e=a.defer();return c.get("templates/get&templateId="+d).then(function(a){e.resolve(a)},function(a,c){e.reject(a,c),b.error("There was a problem getting the export")}),e.promise}}}]),GoogleMerchants.directive("tipsy",["$document",function(a){return{
|
8 |
-
restrict:"A",link:function(b,c,d){c.attr("original-title",d.tipsy),c.tipsy({gravity:function(){var b="n";a.scrollTop()<c.offset().top-angular.element(".tipsy").height()-2&&(b="s");var d="";return c.offset().left+angular.element(".tipsy").width()<a.width()+a.scrollLeft()?d="w":c.offset().left-angular.element(".tipsy").width()>a.scrollLeft()&&(d="e"),b+d},live:!0,html:!0,opacity:1})}}}]),GoogleMerchants.factory("wpHttp",["$http","$q","$log","BACKEND","NONCE",function(a,b,c,d,e){return{post:function(c,f){var g=b.defer();return a.post(d+c+"&security="+e,f).then(function(a){g.resolve(a.data)},function(a,b){g.reject(a,b)}),g.promise},get:function(c){var f=b.defer();return a.get(d+c+"&security="+e).then(function(a){f.resolve(a.data)},function(a,b){f.reject(a,b)}),f.promise}}}]),GoogleMerchants.controller("detailedInformationController",["$scope","$log","attributesService",function(a,b,c){a.attributes=[],a.cats=[],a.attributes=c.getAttributes()}]),GoogleMerchants.directive("detailedInformation",function(){return{restrict:"E",scope:{detailedInformation:"=information"},templateUrl:"detailedInformation/detailedInformation.tpl.html",controller:"detailedInformationController"}}),GoogleMerchants.controller("categoryMapperController",["$scope","$rootScope","$interval","$timeout",function(a,b,c,d){a.dialogVisible=!0,a.selectedCategory="",a.selectedCategoryId=0,a.parentWidth=!1,a.siteCats=[],a.initialized=!1,a.innerMapping=!1,a.limits=100,a.catMappings=[],b.$on("categories.loaded",function(){a.innerMapping=b.cats}),a.innerMapping=b.cats,a.initialize=function(){a.initialized||(d(function(){c(function(){a.limits<a.innerMapping.length&&(a.limits+=20)},10)},100),a.initialized=!0,a.afterInitialize())},a.afterInitialize=function(){angular.forEach(a.cats,function(a,b){})},angular.isUndefined(a.context)&&(a.context="categories"),a.expandNode=function(a){a.children.length&&(a.expanded=!a.expanded)},a.getTimes=function(a){return new Array(a)},a.toggleDialog=function(){a.dialogVisible=!a.dialogVisible},a.getPlaceholder=function(){return a.visible?"":"Select Google Product Category"}}]),GoogleMerchants.directive("categoryMapper",function(){return{restrict:"E",scope:{mappings:"=",grey:"=",context:"@?"},templateUrl:"productCategories/categoryMapper/categoryMapper.tpl.html",controller:"categoryMapperController"}}),GoogleMerchants.controller("googleCategorySelectorController",["$scope","$log","$window","googleCategoriesService",function(a,b,c,d){function e(b,c,d){var f,g;for(f=0;f<d.children.length;f+=1)g=d.children[f],angular.isDefined(a.mappings[g.id])?a.mappings[g.id].byUser||(a.mappings[g.id]={id:b,name:c,byUser:!1}):a.mappings[g.id]={id:b,name:c,byUser:!1},e(b,c,g);return!1}var f=[];a.categories=[],a.level=1,a.search="",a.loading=!1,a.hasResults=!0,a.byUser=!1,a.select=function(b){var c=b.name.replace("<strong>","").replace("</strong>","").replace("<b>","").replace("</b>","");a.visible=!1;b.id;a.selectedCategory=c,a.mappings[a.node.id]={id:b.id,name:c,byUser:!0},e(b.Id,c,a.node)},a.loadCategories=function(b){a.loading=!0;var c="";b&&(c="&search="+b),d.searchCategories(c).then(function(b){a.categories=b}).finally(function(){a.loading=!1})},a.expand=function(c){if(c.opened)return void(c.opened=!1);a.loading=!0,d.getChildCategories(c.id).then(function(a){"null"!=a&&(c.children=a,c.opened=!0)},function(){b.error("There was a problem loading the categories")}).finally(function(){a.loading=!1})},a.matchSearch=function(a){return function(b){return b.name===a.name}},a.$watch("search",function(b,c){if(""==c&&(f=a.categories),""==b)return void(a.categories=f);a.loadCategories(b)},!0),a.categoryChanged=function(){a.loadCategories(a.selectedCategory)},a.categoryClicked=function(){a.selectedCategory;a.visible||(a.visible=!0),a.byUser||(a.selectedCategory=""),a.search="",a.categoryChanged()},a.closeMe=function(){a.visible&&(a.visible=!1)}}]),GoogleMerchants.directive("googleCategorySelector",["$rootScope",function(a){return{restrict:"E",templateUrl:"productCategories/googleCategorySelector/googleCategorySelector.tpl.html",controller:"googleCategorySelectorController"}}]),GoogleMerchants.controller("productCategoriesController",["$scope",function(a){}]),GoogleMerchants.directive("productCategories",function(){return{restrict:"E",scope:{productCategories:"=information"},templateUrl:"productCategories/productCategories.tpl.html",controller:"productCategoriesController"}}),GoogleMerchants.controller("shippingController",["$scope","currencyService",function(a,b){a.currency=b.getCurrency()}]),GoogleMerchants.directive("shipping",function(){return{restrict:"E",scope:{shipping:"=information"},templateUrl:"shipping/shipping.tpl.html",controller:"shippingController"}}),GoogleMerchants.controller("uniqueIdentifiersController",["$scope",function(a){}]),GoogleMerchants.directive("uniqueIdentifiers",function(){return{restrict:"E",scope:{uniqueIdentifiers:"=information"},templateUrl:"uniqueIdentifiers/uniqueIdentifiers.tpl.html",controller:"uniqueIdentifiersController"}}),angular.module("templates-dist",["advancedAttributes/advancedAttributes.tpl.html","availabilityPrice/availabilityPrice.tpl.html","basicInformation/basicInformation.tpl.html","common/mapping/mapping.tpl.html","detailedInformation/detailedInformation.tpl.html","productCategories/categoryMapper/categoryMapper.tpl.html","productCategories/categoryMapper/noCategoriesNotice.tpl.html","productCategories/googleCategorySelector/googleCategorySelector.tpl.html","productCategories/productCategories.tpl.html","shipping/shipping.tpl.html","uniqueIdentifiers/uniqueIdentifiers.tpl.html"]),angular.module("advancedAttributes/advancedAttributes.tpl.html",[]).run(["$templateCache",function(a){a.put("advancedAttributes/advancedAttributes.tpl.html",'<div class="wpallexport-collapsed wpallexport-section" ng-class="{closed: !advancedAttributes.open }">\n <div class="wpallexport-content-section">\n <div class="wpallexport-collapsed-header disable-jquery"\n ng-click="advancedAttributes.open = !advancedAttributes.open">\n <h3>Advanced Attributes</h3>\n </div>\n <div class="wpallexport-collapsed-content" id="advanced-attributes"\n ng-slide-down="advancedAttributes.open" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <h3 class="inner-title">Product Type</h3>\n <h4>Multipack</h4>\n <p>\n Multipacks are packages that include several identical products to create a larger unit of sale,\n submitted as a single item.\n For example, if the product for sale is a 6-pack of soda, the multipack value would be 6.\n </p>\n <div class="input">\n <label><input type="text" ng-model="advancedAttributes.multipack" class="wpae-default-input" droppable/></label>\n </div>\n\n <h4>Adult</h4>\n <div class="input">\n <label><input type="radio" ng-model="advancedAttributes.adult" value="no"/>False</label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="advancedAttributes.adult" value="yes"/>True</label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="advancedAttributes.adult" value="customValue"/>Custom data</label>\n <div ng-slide-down="advancedAttributes.adult == \'customValue\'" duration="0.2" class="input inner">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.adultCV" droppable />\n </div>\n </div>\n\n <h3 class="inner-title">Adwords & Shopping Campaigns</h3>\n <h4>Adwords Redirect</h4>\n <p>If provided, make sure that the URL redirects to the same URL as given in the \'link\' attribute.</p>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.adwordsRedirect" droppable />\n </div>\n\n <h4>Custom Labels</h4>\n <p>\n You can use custom labels to subdivide products in your campaign using any values\n of your choosing. For example, you can use custom labels to indicate that products\n are seasonal, on clearance, best sellers, etc. (<a href="https://support.google.com/adwords/answer/6275295" target="_blank">Learn more about how to set up Shopping campaigns.</a>)\n </p>\n <div style="margin-top:10px;">Custom Label 0</div>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.customLabel0" droppable />\n <a href="" class="wpae-field-mapping" ng-click="showCustomLabel0Mappings=true">Data Mapping</a>\n <div style="position: relative">\n <mapping mappings="advancedAttributes.customLabel0Mappings" show="showCustomLabel0Mappings" context="text" tooltip="For example, if you have products tagged \'reduced price\' and \'on sale\' and you want both to be listed as \'clearance\' in your export:<br/><br/>Create two sets of data mappings, with \'Exported Data\' set to \'reduced price\' for one and \'on sale\' for the other. \'Translated To\' for both would be \'clearance\'." />\n </div>\n </div>\n <div style="margin-top:10px;">Custom Label 1</div>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.customLabel1" droppable />\n <a href="" class="wpae-field-mapping" ng-click="showCustomLabel1Mappings=true">Data Mapping</a>\n <div style="position: relative">\n <mapping mappings="advancedAttributes.customLabel1Mappings" show="showCustomLabel1Mappings" context="text" tooltip="For example, if you have products tagged \'reduced price\' and \'on sale\' and you want both to be listed as \'clearance\' in your export:<br/><br/>Create two sets of data mappings, with \'Exported Data\' set to \'reduced price\' for one and \'on sale\' for the other. \'Translated To\' for both would be \'clearance\'." />\n </div>\n </div>\n <div style="margin-top:10px;">Custom Label 2</div>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.customLabel2" droppable />\n <a href="" class="wpae-field-mapping" ng-click="showCustomLabel2Mappings=true">Data Mapping</a>\n <div style="position: relative">\n <mapping mappings="advancedAttributes.customLabel2Mappings" show="showCustomLabel2Mappings" context="text" tooltip="For example, if you have products tagged \'reduced price\' and \'on sale\' and you want both to be listed as \'clearance\' in your export:<br/><br/>Create two sets of data mappings, with \'Exported Data\' set to \'reduced price\' for one and \'on sale\' for the other. \'Translated To\' for both would be \'clearance\'." />\n </div>\n </div>\n <div style="margin-top:10px;">Custom Label 3</div>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.customLabel3" droppable />\n <a href="" class="wpae-field-mapping" ng-click="showCustomLabel3Mappings=true">Data Mapping</a>\n <div style="position: relative">\n <mapping mappings="advancedAttributes.customLabel3Mappings" show="showCustomLabel3Mappings" context="text" tooltip="For example, if you have products tagged \'reduced price\' and \'on sale\' and you want both to be listed as \'clearance\' in your export:<br/><br/>Create two sets of data mappings, with \'Exported Data\' set to \'reduced price\' for one and \'on sale\' for the other. \'Translated To\' for both would be \'clearance\'." />\n </div>\n </div>\n <div style="margin-top:10px;">Custom Label 4</div>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.customLabel4" droppable />\n <a href="" class="wpae-field-mapping" ng-click="showCustomLabel4Mappings=true">Data Mapping</a>\n <div style="position: relative">\n <mapping mappings="advancedAttributes.customLabel4Mappings" show="showCustomLabel4Mappings" context="text" tooltip="For example, if you have products tagged \'reduced price\' and \'on sale\' and you want both to be listed as \'clearance\' in your export:<br/><br/>Create two sets of data mappings, with \'Exported Data\' set to \'reduced price\' for one and \'on sale\' for the other. \'Translated To\' for both would be \'clearance\'." />\n </div>\n </div>\n\n <hr/>\n\n <h3 class="inner-title">Unit Prices</h3>\n <p>\n These attributes allow you to submit pricing for products that rely on unit pricing.\n The \'unit pricing measure\' attribute defines the measure and dimension of an item (e.g. 150g).\n The \'unit pricing base measure attribute specifies your preference of the denominator of the unit price (e.g. 100g).\n </p>\n <p>\n For example, if the \'price\' is 3 USD, \'unit pricing measure\' is 150g and \'unit pricing base measure\' is 100g, the unit price would be \'2 USD/200g\'.\n </p>\n\n <h4>Unit Pricing Measure</h4>\n <div class="input">\n <input type="text" ng-model="advancedAttributes.unitPricingMeasure" class="wpae-default-input" droppable />\n </div>\n <h4>Unit Pricing Base Measure</h4>\n <div class="input">\n <input type="text" ng-model="advancedAttributes.unitPricingBaseMeasure" class="wpae-default-input" droppable />\n <select style="width: 170px;" ng-model="advancedAttributes.unitPricingBaseMeasureUnit">\n <option value="kg">Kilograms (kg)</option>\n <option value="g">Ounces (oz)</option>\n <option value="lb">Pounds (lb)</option>\n <option value="mg">Milligrams (mg)</option>\n <option value="g">Grams (g)</option>\n </select>\n </div>\n <hr/>\n <h3 class="inner-title">Additional Attributes</h3>\n <h4>Expiration Date</h4>\n <p>\n This is the date that an item listing will expire. If you do not provide this attribute, items\n will expire and no longer appear in Google Shopping results after 30 days.\n <strong>You cannot use thi attribute to extend the expiration period to longer than 30 days.</strong>\n </p>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.expirationDate" droppable />\n </div>\n\n <h4>Energy Efficiency Class</h4>\n <p>\n This attribute allows you to submit the energy label for your applicable products in feeds targeting\n European Union countries and switzerland.\n </p>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.energyEfficiencyClass" droppable />\n <a href="" class="wpae-field-mapping" ng-click="showEnergyEfficiencyMappings=true">Data Mapping</a>\n <div style="position: relative">\n <mapping mappings="advancedAttributes.energyEfficiencyClassMappings" show="showEnergyEfficiencyMappings" tooltip="For example, if you have products tagged \'energy efficient\' and \'low power\' and you want both to be listed as \'A+++\' in your export:\n<br/><br/>\nCreate two sets of data mappings, with \'Exported Data\' set to \'energy efficient\' for one and \'low power\' for the other. \'Translated To\' for both would be \'A+++\'." />\n </div>\n </div>\n <h4>Promotion ID</h4>\n <p>\n If using Merchant Promotions, the \'promotion id\' attribute is used in both your products\n feed and your promotions feed to match products to promotions across the two feeds.\n </p>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.promotionId" droppable />\n <a href="" class="wpae-field-mapping" ng-click="showPromotionIdMappings=true">Data Mapping</a>\n <div style="position: relative">\n <mapping mappings="advancedAttributes.promotionIdMappings" show="showPromotionIdMappings" tooltip="For example, if your products are tagged \'reduced price\' and \'on sale\' and you want both to be listed with a specific promotion ID in your export:\n<br/><br/>\n'+"Create two sets of data mappings, with 'Exported Data' set to 'reduced price' for one and 'on sale' for the other. 'Translated To' for both would be the desired promotion ID.\" />\n </div>\n </div>\n\n </div>\n </div>\n </div>\n</div>")}]),angular.module("availabilityPrice/availabilityPrice.tpl.html",[]).run(["$templateCache",function(a){a.put("availabilityPrice/availabilityPrice.tpl.html",'<div class="wpallexport-collapsed wpallexport-section" ng-class="{closed: !availabilityPrice.open}">\n <div class="wpallexport-content-section">\n <div class="wpallexport-collapsed-header disable-jquery" ng-click="availabilityPrice.open = !availabilityPrice.open">\n <h3>Availability & Price</h3>\n </div>\n <div class="wpallexport-collapsed-content" id="availability-price" ng-slide-down="availabilityPrice.open" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <h4>Price</h4>\n <div class="input">\n <label><input type="radio" ng-model="availabilityPrice.price" value="useProductPrice" /> Use the product\'s price</label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="availabilityPrice.price" value="customValue" /> Custom data</label>\n\n <div class="input inner" ng-slide-down="availabilityPrice.price == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="availabilityPrice.priceCV" droppable />\n </div>\n </div>\n\n <div class="input inner">\n <a href="" ng-click="availabilityPrice.adjustPrice = !availabilityPrice.adjustPrice" class="adjust-price-link">\n <span class="open-indicator" ng-if="availabilityPrice.adjustPrice">-</span>\n <span class="open-indicator" ng-if="!availabilityPrice.adjustPrice">+</span> Adjust Price\n </a>\n <div ng-slide-down="availabilityPrice.adjustPrice" class="adjust-price" duration="0.2">\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="availabilityPrice.adjustPriceValue" droppable /><select ng-model="availabilityPrice.adjustPriceType">\n <option value="%">%</option>\n <option value="USD">{{currency}}</option>\n </select>\n\n <div ng-show="availabilityPrice.adjustPriceType == \'%\'" class="tooltip-container">\n <a href="#" ng-cloak="" class="wpallexport-help"\n tipsy="Leave blank or enter in 100% to keep the price as is. Enter in 110% to markup by 10%. Enter in 50% to cut prices in half.">?</a>\n </div>\n <div ng-show="availabilityPrice.adjustPriceType == \'USD\'" class="tooltip-container">\n <a href="#" ng-cloak="" class="wpallexport-help"\n tipsy="Enter a negative number to reduce prices.">?</a>\n </div>\n </div>\n </div>\n </div>\n <h4>Sale Price</h4>\n <div class="input">\n <label><input type="radio" ng-model="availabilityPrice.salePrice" value="useProductSalePrice"/>Use the product\'s sale price</label>\n </div>\n <div class="input">\n <div class="input">\n <label><input type="radio" ng-model="availabilityPrice.salePrice" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="availabilityPrice.salePrice == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="availabilityPrice.salePriceCV" droppable/>\n </div>\n </div>\n </div>\n <div class="input inner">\n <a href="" ng-click="availabilityPrice.adjustSalePrice = !availabilityPrice.adjustSalePrice" ng-init="availabilityPrice.adjustSalePrice= false" class="adjust-price-link">\n <span class="open-indicator" ng-if="availabilityPrice.adjustSalePrice">-</span>\n <span class="open-indicator" ng-if="!availabilityPrice.adjustSalePrice">+</span> Adjust Sale Price\n </a>\n <div ng-slide-down="availabilityPrice.adjustSalePrice" class="adjust-price" duration="0.2">\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="availabilityPrice.adjustSalePriceValue" droppable /><select ng-model="availabilityPrice.adjustSalePriceType">\n <option value="%">%</option>\n <option value="USD">{{currency}}</option>\n </select>\n <div ng-show="availabilityPrice.adjustSalePriceType == \'%\'" class="tooltip-container">\n <a href="#" ng-cloak="" class="wpallexport-help"\n tipsy="Leave blank or enter in 100% to keep the price as is. Enter in 110% to markup by 10%. Enter in 50% to cut prices in half.">?</a>\n </div>\n <div ng-show="availabilityPrice.adjustSalePriceType == \'USD\'" class="tooltip-container">\n <a href="#" ng-cloak="" class="wpallexport-help"\n tipsy="Enter a negative number to reduce prices.">?</a>\n </div>\n </div>\n </div>\n </div>\n <h4>Availability</h4>\n <div class="input">\n <label><input type="radio" ng-model="availabilityPrice.availability" value="useWooCommerceStockValues"/>Use WooCommerce stock values</label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="availabilityPrice.availability" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="availabilityPrice.availability == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="availabilityPrice.availabilityCV" droppable />\n </div>\n </div>\n </div>\n <div class="wpallexport-collapsed wpallexport-section wpallexport-google-merchants-advanced-options" ng-init="advancedOptionsOpen = false" ng-class="{closed: !advancedOptionsOpen} ">\n <div class="wpallexport-content-section rad0">\n <div class="wpallexport-collapsed-header wpallexport-advanced-options-header disable-jquery" ng-click="advancedOptionsOpen = !advancedOptionsOpen">\n <h3 class="advanced-options">Advanced Options</h3>\n </div>\n <div class="wpallexport-collapsed-content wpallexport-advanced-options-content" ng-slide-down="advancedOptionsOpen" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <div class="input">\n <h4>Currency</h4>\n <div class="input">\n <div class="select-container" style="padding-left: 0px;">\n <select class="custom-value" chosen ng-model="availabilityPrice.currency">\n <option value="AUD">Australian Dollars (AUD)</option>\n <option value="BRL">Brazilian Reals (BRL)</option>\n <option value="GBP">British Pounds (GBP)</option>\n <option value="CAD">Canadian Dollars (CAD)</option>\n <option value="CZK">Czech Crowns (CZK)</option>\n <option value="DKK">Danish Krone (DKK)</option>\n <option value="EUR">Euros (EUR)</option>\n <option value="INR">Indian Rupees (INR)</option>\n <option value="JPY">Japanese Yen (JPY)</option>\n <option value="MXN">Mexican Pesos (MXN)</option>\n <option value="NZD">New Zealand Dollars (NZD)</option>\n <option value="NOK">Norwegian Krone (NOK)</option>\n <option value="PLN">Polish Złoty (PLN)</option>\n <option value="RUB">Russian Rubles (RUB)</option>\n <option value="SGD">Singapore Dollars (SGD)</option>\n <option value="ZAR">South Africa Rand (ZAR)</option>\n <option value="SEK">Swedish Krona (SEK)</option>\n <option value="CHF">Swiss Franc (CHF)</option>\n <option value="TRY">Turkish Lira (TRY)</option>\n <option value="USD">United States Dollars (USD)</option>\n </select>\n </div>\n </div>\n <h4>Availability Date</h4>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="availabilityPrice.availabilityDate" droppable />\n </div>\n <h4>Sale Price Effective Date</h4>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="availabilityPrice.salePriceEffectiveDate" droppable />\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n</div>')}]),angular.module("basicInformation/basicInformation.tpl.html",[]).run(["$templateCache",function(a){
|
9 |
-
a.put("basicInformation/basicInformation.tpl.html",'<div class="wpallexport-collapsed wpallexport-section" ng-class="{closed: !basicInformation.open}">\n <div class="wpallexport-content-section">\n <div class="wpallexport-collapsed-header disable-jquery" ng-click="basicInformation.open = !basicInformation.open">\n <h3>Basic Product Information</h3>\n </div>\n <div class="wpallexport-collapsed-content" id="basic-product-information" ng-slide-down="basicInformation.open" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n\n <h4>Item Title</h4>\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.itemTitle" value="productTitle"/>Use the product title</label>\n </div>\n <div class="input">\n <label><input type="radio" id="title-custom-data-select" ng-model="basicInformation.itemTitle" value="customValue" />Custom data</label>\n <div class="input inner" id="title-custom-data-container" ng-slide-down="basicInformation.itemTitle == \'customValue\'" duration="0.2">\n <input type="text" id="title-custom-data-value" class="wpae-default-input" ng-model="basicInformation.itemTitleCV" droppable />\n </div>\n </div>\n\n <div class="input checkbox" ng-if="basicInformation.hasVariations">\n <label><input type="checkbox" ng-model="basicInformation.useParentTitleForVariableProducts" value="1" />For variable products, use the parent product title</label>\n </div>\n\n <h4>Item Description</h4>\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.itemDescription" id="use-product-description" value="productDescription"/>Use the product description</label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.itemDescription" id="use-product-short-description" value="productShortDescription"/>Use the product short description</label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.itemDescription" id="product-description-custom-data" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="basicInformation.itemDescription == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" id="description-custom-data-value" ng-model="basicInformation.itemDescriptionCV" droppable />\n </div>\n </div>\n\n <div class="input checkbox">\n <label><input type="checkbox" ng-model="basicInformation.useVariationDescriptionForVariableProducts" value="1" />Use the variation description for variable products</label>\n </div>\n <div class="input checkbox inner" ng-slide-down="basicInformation.useVariationDescriptionForVariableProducts" duration="0.2">\n <label><input type="checkbox" ng-model="basicInformation.useParentDescirptionIfThereIsNoVariationDescirption" value="1" />If there is no variation description, use the parent product description</label>\n </div>\n\n <h4>Link</h4>\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.itemLink" id="use-product-permalinks" value="productLink"/>Use the product permalink</label>\n </div>\n\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.itemLink" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="basicInformation.itemLink == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="basicInformation.itemLinkCV" droppable />\n </div>\n </div>\n\n <div class="input checkbox">\n <label><input type="checkbox" ng-model="basicInformation.addVariationAttributesToProductUrl" />For variable products, add variation attributes to product URL</label>\n </div>\n\n <h4>Main Image Link</h4>\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.itemImageLink" value="useProductFeaturedImage"/>Use product featured image</label>\n </div>\n\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.itemImageLink" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="basicInformation.itemImageLink == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="basicInformation.itemImageLinkCV" droppable />\n </div>\n </div>\n\n <div class="input checkbox">\n <label><input type="checkbox" ng-model="basicInformation.useVariationImage" />For variable products, use variation image</label>\n </div>\n\n <div class="input checkbox inner" ng-slide-down="basicInformation.useVariationImage" duration="0.2">\n <label><input type="checkbox" ng-model="basicInformation.useFeaturedImageIfThereIsNoVariationImage" value="1" />If there is no variation image, use the featured image</label>\n </div>\n\n <h4>Additional Image Link</h4>\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.additionalImageLink" value="productImages"/>Use images from product gallery</label>\n </div>\n\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.additionalImageLink" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="basicInformation.additionalImageLink == \'customValue\'" duration="0.2">\n <input type="text"class="wpae-default-input" ng-model="basicInformation.additionalImageLinkCV" droppable />\n </div>\n </div>\n </div>\n <div class="wpallexport-collapsed wpallexport-section wpallexport-google-merchants-advanced-options" ng-init="advancedOptionsOpen = false" ng-class="{closed: !advancedOptionsOpen}">\n <div class="wpallexport-content-section rad0">\n <div class="wpallexport-collapsed-header wpallexport-advanced-options-header disable-jquery" ng-click="advancedOptionsOpen = !advancedOptionsOpen">\n <h3>Advanced Options</h3>\n </div>\n <div class="wpallexport-collapsed-content wpallexport-advanced-options-content" ng-slide-down="advancedOptionsOpen" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <div class="input">\n <h4>Item ID</h4>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="basicInformation.itemId" droppable />\n </div>\n <h4>Item Condition</h4>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="basicInformation.condition" droppable />\n <a href="" class="wpae-field-mapping" ng-click="showConditionMappings=true">Data Mapping</a>\n <mapping mappings="basicInformation.conditionMappings" show="showConditionMappings" context="condition" />\n <a style="margin-top: 7px;" class="wpallexport-help" tipsy="The condition or state of the item. Google Shopping allows the promotion of quality second-hand items. There are only 3 accepted values: \'new\', \'refurbished\', and \'used\'">?</a>\n </div>\n <h4>Mobile Link</h4>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="basicInformation.mobileLink" droppable />\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n</div>')}]),angular.module("common/mapping/mapping.tpl.html",[]).run(["$templateCache",function(a){a.put("common/mapping/mapping.tpl.html",'<div class="wp-pointer wp-pointer-right" style="width: 450px; display: block; position: absolute; top: -70px; left: -23px;" ng-if="show">\n <div class="wp-pointer-content">\n <h4 style="padding-left:25px; margin-bottom:0; padding-bottom:0; margin-top:20px;">\n Data Mapping\n <a style="margin-top: 7px;" ng-if="tooltip" class="wpallexport-help"\n tipsy="{{ tooltip }}">?\n </a>\n </h4>\n\n <fieldset style="margin-top: 0; padding-top: 0; padding-bottom: 0;">\n <table cellpadding="0" cellspacing="0" class="cf-form-table" rel="cf_mapping_0" style="margin-left: 5px; margin-top: 15px;">\n <thead>\n <tr>\n <td><div style="padding-bottom:5px">Exported Data</div></td>\n <td><div style="padding-bottom:5px;">Translated To</div></td>\n <td> </td>\n </tr>\n </thead>\n <tbody>\n <tr class="form-field" ng-repeat="mapping in mappings">\n <td style="width: 50%;">\n <input type="text" ng-model="mapping.mapFrom" style="margin-left:0;"/>\n </td>\n <td style="width: 50%;">\n <div ng-if="context == \'sizeType\'">\n <select chosen ng-model="mapping.mapTo" >\n <option value="">Please select</option>\n <option value="regular">Regular</option>\n <option value="petite">Petite</option>\n <option value="plus">Plus</option>\n <option value="big and tall">Big and tall</option>\n <option value="maternity">Maternity</option>\n </select>\n </div>\n <div ng-if="context == \'condition\' ">\n <select chosen ng-model="mapping.mapTo">\n <option value="new">New</option>\n <option value="refurbished">Refurbished</option>\n <option value="used">Used</option>\n </select>\n </div>\n <div ng-if="context != \'sizeType\' && context != \'condition\'">\n <input type="text" ng-model="mapping.mapTo" />\n </div>\n </td>\n <td class="action remove">\n <a href="" ng-click="removeMapping(mapping)" ng-show="$index > 0"\n style="right:-10px;"></a>\n </td>\n </tr>\n <tr>\n <td colspan="3">\n <a href="" ng-click="addMapping()" title="Add Another" class="action add-new-key add-new-entry" style="margin-top: 15px; margin-bottom:15px; margin-left: 0;">\n Add Another\n </a>\n </td>\n </tr>\n </tbody>\n </table>\n <input type="hidden" name="custom_mapping_rules[]" value="">\n </fieldset>\n <div class="wp-pointer-buttons">\n <a class="close" href="" ng-click="close()">Close</a>\n <a class="save_popup save_mr" style="position:static; margin-right: 15px;" href="" ng-click="saveMappings()">Save Rules</a>\n </div>\n </div>\n <div class="wp-pointer-arrow">\n <div class="wp-pointer-arrow-inner"></div>\n </div>\n</div>')}]),angular.module("detailedInformation/detailedInformation.tpl.html",[]).run(["$templateCache",function(a){a.put("detailedInformation/detailedInformation.tpl.html",'<div class="wpallexport-collapsed wpallexport-section" ng-class="{closed: !detailedInformation.open }">\n <div class="wpallexport-content-section">\n <div class="wpallexport-collapsed-header disable-jquery" ng-click="detailedInformation.open = !detailedInformation.open ">\n <h3>Detailed Product Attributes & Item Grouping</h3>\n </div>\n <div class="wpallexport-collapsed-content" id="detailed-product-information" ng-slide-down="detailedInformation.open" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <h4>Item Group ID</h4>\n <p>\n For variable products, each variant is exported as a separate product.\n Variants that belong to the same group must all have the same Item Group ID\n so that Google knows they are related.\n </p>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.setTheGroupId" value="automatically" />Automatically set the item group ID</label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.setTheGroupId" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="detailedInformation.setTheGroupId == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="detailedInformation.setTheGroupIdCV" droppable />\n </div>\n </div>\n <h4>Color</h4>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.color" value="selectFromWooCommerceProductAttributes" />Select from WooCommerce product attributes</label>\n <div ng-slide-down="detailedInformation.color == \'selectFromWooCommerceProductAttributes\'" duration="0.2">\n <div class="select-container" ng-if="attributes.length">\n <select autodetect="Color" chosen ng-options="\'{\' + i.name + \'}\' as i.name for i in attributes" ng-model="detailedInformation.colorAttribute" class="inner">\n <option value="">Leave Blank</option>\n </select>\n </div>\n <div class="no-attributes" ng-if="!attributes.length">\n The products in this export have no product attributes. Add attributes to your products in order to map them to a color.\n </div>\n </div>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.color" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="detailedInformation.color == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="detailedInformation.colorCV" droppable />\n </div>\n </div>\n\n <h4>Size</h4>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.size" value="selectFromWooCommerceProductAttributes" />Select from WooCommerce product attributes</label>\n <div ng-slide-down="detailedInformation.size == \'selectFromWooCommerceProductAttributes\'" duration="0.2">\n <div class="select-container" ng-if="attributes.length">\n <select id="sizeAttribute" autodetect="Size" chosen ng-options="\'{\' + i.name + \'}\' as i.name for i in attributes" ng-model="detailedInformation.sizeAttribute" class="inner">\n <option value="">Leave Blank</option>\n </select>\n </div>\n <div class="no-attributes" ng-if="!attributes.length">\n The products in this export have no product attributes. Add attributes to your products in order to map them to a size.\n </div>\n </div>\n </div>\n <div class="input">\n <label>\n <input type="radio" ng-model="detailedInformation.size" value="customValue" />Custom data\n </label>\n <div class="input inner" ng-slide-down="detailedInformation.size== \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="detailedInformation.sizeCV" droppable />\n </div>\n </div>\n\n <h4>Gender</h4>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.gender" value="selectFromWooCommerceProductAttributes" />Select from WooCommerce product attributes</label>\n <div class="clear"></div>\n <div ng-slide-down="detailedInformation.gender == \'selectFromWooCommerceProductAttributes\'" duration="0.2">\n <div class="select-container" ng-if="attributes.length">\n <select autodetect="Gender" chosen ng-options="\'{\' + i.name + \'}\' as i.name for i in attributes" ng-model="detailedInformation.genderAttribute" class="inner">\n <option value="">Leave Blank</option>\n </select>\n </div>\n <div class="no-attributes" ng-if="!attributes.length">\n The products in this export have no product attributes. Add attributes to your products in order to map them to a gender.\n </div>\n </div>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.gender" value="autodetectBasedOnProductTaxonomies"/>Autodetect based on WooCommerce product categories</label>\n <div ng-slide-down="detailedInformation.gender == \'autodetectBasedOnProductTaxonomies\'" duration="0.2">\n <div class="inner">\n <div class="input">\n <label>\n <input type="radio" ng-model="detailedInformation.genderAutodetect" value="keepBlank"/>Leave gender blank if unable to detect gender\n </label>\n </div>\n <div class="input">\n <label>\n <input type="radio" ng-model="detailedInformation.genderAutodetect" value="setToUnisex" />Set gender to unisex if unable to detect gender\n </label>\n </div>\n </div>\n </div>\n </div>\n <div class="input">\n <label>\n <input type="radio" ng-model="detailedInformation.gender" value="selectProductTaxonomies" />Select from WooCommerce product categories\n </label>\n <div ng-slide-down="detailedInformation.gender == \'selectProductTaxonomies\'" duration="0.2">\n <category-mapper mappings="detailedInformation.genderCats" context="gender" />\n </div>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.gender" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="detailedInformation.gender == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="detailedInformation.genderCV" droppable />\n </div>\n </div>\n </div>\n\n <div class="wpallexport-collapsed wpallexport-section wpallexport-google-merchants-advanced-options" ng-class="{closed: !advancedOptionsOpen}">\n <div class="wpallexport-content-section rad0">\n <div class="wpallexport-collapsed-header wpallexport-advanced-options-header disable-jquery" ng-click="advancedOptionsOpen = !advancedOptionsOpen">\n <h3>Advanced Options</h3>\n </div>\n <div class="wpallexport-collapsed-content wpallexport-advanced-options-content" ng-slide-down="advancedOptionsOpen" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <h4>Size Type</h4>\n <div class="input">\n <div style="display: inline-block;">\n <input type="text" class="wpae-default-input" ng-model="detailedInformation.sizeType" droppable />\n </div>\n <a href="" class="wpae-field-mapping" ng-click="showMappings=true">Data Mapping</a>\n <div style="position: relative">\n <mapping mappings="detailedInformation.sizeTypeMappings" show="showMappings" context="sizeType" />\n </div>\n </div>\n <h4>Size System</h4>\n <div class="input">\n <div class="select-container" style="padding-left: 0;">\n <select chosen ng-model="detailedInformation.sizeSystem" class="inner">\n <option value="">Leave Blank</option>\n <option value="US">US</option>\n <option value="UK">UK</option>\n <option value="EU">EU</option>\n <option value="DE">DE</option>\n <option value="FR">FR</option>\n <option value="JP">JP</option>\n <option value="CN">CN (China)</option>\n <option value="IT">IT</option>\n <option value="BR">BR</option>\n <option value="MEX">MEX</option>\n <option value="AU">AU</option>\n </select>\n </div>\n </div>\n <h4>Age Group</h4>\n <div class="input">\n <label>\n <input type="radio" ng-model="detailedInformation.ageGroup" value="selectFromWooCommerceProductAttributes"/>Select from WooCommerce product attributes\n </label>\n <div ng-slide-down="detailedInformation.ageGroup == \'selectFromWooCommerceProductAttributes\'" duration="0.2">\n <div class="select-container" ng-if="attributes.length">\n <select chosen ng-options="\'{\' + i.name + \'}\' as i.name for i in attributes" ng-model="detailedInformation.ageGroupAttribute" class="inner">\n <option value="">Leave Blank</option>\n </select>\n </div>\n <div class="no-attributes" ng-if="!attributes.length">\n The products in this export have no product attributes. Add attributes to your products in order to map them to an age group.\n </div>\n </div>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.ageGroup" value="selectFromProductTaxonomies" />Select from WooCommerce product categories</label>\n <div ng-slide-down="detailedInformation.ageGroup == \'selectFromProductTaxonomies\' " duration="0.5" >\n <div ng-show="detailedInformation.ageGroup == \'selectFromProductTaxonomies\' ">\n <category-mapper mappings="detailedInformation.ageGroupCats" grey="1" context="ageGroup" />\n </div>\n </div>\n </div>\n <div class="input">\n <label>\n <input type="radio" ng-model="detailedInformation.ageGroup" value="customValue" />Custom data\n </label>\n <div class="input inner" ng-slide-down="detailedInformation.ageGroup== \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="detailedInformation.ageGroupCV" droppable />\n </div>\n </div>\n <h4>Material</h4>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.material" value="selectFromWooCommerceProductAttributes" />Select from WooCommerce product attributes</label>\n <div ng-slide-down="detailedInformation.material == \'selectFromWooCommerceProductAttributes\'" duration="0.2">\n <div class="select-container" ng-if="attributes.length">\n <select chosen ng-options="\'{\' + i.name + \'}\' as i.name for i in attributes" ng-model="detailedInformation.materialAttribute" class="inner">\n <option value="">Leave Blank</option>\n </select>\n </div>\n <div class="no-attributes outer" ng-if="!attributes.length">\n The products in this export have no product attributes. Add attributes to your products in order to map them to a material.\n </div>\n </div>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.material" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="detailedInformation.material == \'customValue\'" duration="0.2">\n <div class="input inner" ng-slide-down="detailedInformation.material == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="detailedInformation.materialCV" droppable />\n </div>\n </div>\n\n <h4>Pattern</h4>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.pattern" value="selectFromWooCommerceProductAttributes" />Select from WooCommerce product attributes</label>\n <div ng-slide-down="detailedInformation.pattern == \'selectFromWooCommerceProductAttributes\'" duration="0.2">\n <div class="select-container" ng-if="attributes.length">\n <select chosen ng-options="\'{\' + i.name + \'}\' as i.name for i in attributes" ng-model="detailedInformation.patternAttribute" class="inner">\n <option value="">Leave Blank</option>\n </select>\n </div>\n <div class="no-attributes outer" ng-if="!attributes.length">\n The products in this export have no product attributes. Add attributes to your products in order to map them to a pattern.\n </div>\n </div>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.pattern" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="detailedInformation.pattern == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="detailedInformation.patternCV" droppable />\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n</div>')}]),angular.module("productCategories/categoryMapper/categoryMapper.tpl.html",[]).run(["$templateCache",function(a){
|
10 |
-
a.put("productCategories/categoryMapper/categoryMapper.tpl.html",'<div class="category-mapper">\n <div>\n <div class="woocommerce-categories-title" style="float:left; padding: 13px 13px 13px 31px;">\n <h4 style="margin: 0; padding: 0; font-size:13px; color:#000;">WooCommerce Categories</h4>\n </div>\n\n <div class="google-categories-title" style="float:right; padding:13px; margin-right: 278px;" ng-if="::(context==\'categories\')">\n <h4 style="margin:0; padding:0; font-size:13px; color:#000; ">Google Categories</h4>\n </div>\n\n <div class="google-categories-title" style="float:right; padding:13px; margin-right: 288px;" ng-if="::(context==\'gender\')">\n <h4 style="margin:0; padding:0; font-size:13px; color:#000; ">Google Genders</h4>\n </div>\n\n <div class="google-categories-title" style="float:right; padding:13px; margin-right: 268px;" ng-if="::(context==\'ageGroup\')">\n <h4 style="margin:0; padding:0; font-size:13px; color:#000; ">Google Age Groups</h4>\n </div>\n </div>\n\n <ul dx-start-with="innerMapping" class="tree" ng-class="::{ \'root\' : $dxLevel == 0 }" ng-init="initialize()" style="width: 100%; float:left; margin-top: 0px;" ng-if="innerMapping">\n <li ng-repeat="node in $dxPrior.children | limitTo: limits" style="display: block;">\n <div class="category-container" style="position: relative;" ng-class="::{ \'with-children\' : node.children.length, \'without-children\' : (!node.children.length) }">\n <div class="hline"></div>\n <div class="category-icon-container" style="float:left;">\n <div class="vline" ng-if="::(($index > 0 && $dxLevel == 0) || $dxLevel > 0)"></div>\n <div class="vline noborder" ng-if="::(!(($index > 0 && $dxLevel == 0) || $dxLevel > 0))"></div>\n <span ng-if="node.expanded" class="minus" ng-click="expandNode(node)">\n <svg width="9" height="9" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg">\n <path d="M1600 736v192q0 40-28 68t-68 28h-1216q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h1216q40 0 68 28t28 68z"/>\n </svg>\n </span>\n <span ng-if="!node.expanded && node.children.length" class="plus" ng-click="expandNode(node)">\n <svg width="9" height="9" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg">\n <path d="M1600 736v192q0 40-28 68t-68 28h-416v416q0 40-28 68t-68 28h-192q-40 0-68-28t-28-68v-416h-416q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h416v-416q0-40 28-68t68-28h192q40 0 68 28t28 68v416h416q40 0 68 28t28 68z"/>\n </svg>\n </span>\n <span ng-if="::(!node.children.length)" class="plus blank" style="cursor: default;"></span>\n <div class="vline bottom"></div>\n </div>\n <div class="category-name-container">\n <span class="dot" ng-repeat="i in ::getTimes($dxLevel) track by $index"></span>\n <div class="category">\n <a class="category-title" href="" ng-click="expandNode(node)" ng-bind-html="::node.title | safe"></a>\n <br ng-if="::node.children.length"/>\n <span ng-if="::node.children.length" class="children-number">\n {{ ::node.children.length }} child <span ng-if="::node.children.length == 1">category</span><span ng-if="::node.children.length > 1">categories</span>\n </span>\n </div>\n </div>\n <div class="line" ></div>\n <div class="mapping" ng-if="::(context == \'categories\')" >\n <div style="position: relative" ng-init="visible=false">\n <input type="text" style="width: 402px; font-size:13px; padding-left: 8px;" placeholder="{{ getPlaceholder() }}"\n ng-class="{ \'selected-automatically\' : !mappings[node.id].byUser, \'opened\' : visible }"\n ng-model="selectedCategory"\n ng-value="mappings[node.id].name"\n ng-change="categoryChanged()"\n ng-click="categoryClicked()"\n class="wpae-google-category-input"\n ng-model-options="{ debounce: 200 }"\n />\n <google-category-selector />\n </div>\n </div>\n <div class="mapping gender" ng-if="::(context == \'gender\')" style="border: none;">\n <select chosen cascade ng-model="mappings[node.id]" ng-change="select()">\n <option value="male">Male</option>\n <option value="female">Female</option>\n <option value="unisex">Unisex</option>\n </select>\n </div>\n <div class="mapping" ng-if="::(context == \'ageGroup\')" style="border: none; background-color: #F1F1F1; padding:0; margin-top: 5px;" >\n <select chosen cascade ng-model="mappings[node.id]" ng-change="select()">\n <option value="newborn">Newborn</option>\n <option value="infant">Infant</option>\n <option value="toddler">Toddler</option>\n <option value="kids">Kids</option>\n <option value="adult">Adult</option>\n </select>\n </div>\n <div style="clear:both;"></div>\n </div>\n <ul dx-connect="node" ng-if="node.expanded==true"/>\n </li>\n </ul>\n <div class=\'catList\' style="clear:both;"></div>\n <div class="mask" ng-class="::{ grey : grey == 1}"></div>\n</div>\n<div ng-if="initialized && !innerMapping.children.length">\n <div ng-include="\'productCategories/categoryMapper/noCategoriesNotice.tpl.html\'"></div>\n</div>')}]),angular.module("productCategories/categoryMapper/noCategoriesNotice.tpl.html",[]).run(["$templateCache",function(a){a.put("productCategories/categoryMapper/noCategoriesNotice.tpl.html",'<div class="no-categories-notice" ng-if="context == \'categories\' ">\n The products in this export are uncategorized. Add WooCommerce Product Categories to your products in order to map them to Google Product Categories.\n</div>\n\n<div class="no-categories-notice" ng-if="context == \'gender\' ">\n The products in this export are uncategorized. Add WooCommerce Product Categories to your products in order to map them to a gender.\n</div>\n\n<div class="no-categories-notice" ng-if="context == \'ageGroup\' ">\n The products in this export are uncategorized. Add WooCommerce Product Categories to your products in order to map them to an age group.\n</div>\n')}]),angular.module("productCategories/googleCategorySelector/googleCategorySelector.tpl.html",[]).run(["$templateCache",function(a){a.put("productCategories/googleCategorySelector/googleCategorySelector.tpl.html",'<div class="google-category-selector" ng-init="loadCategories()" ng-if="visible" click-outside="closeMe()" outside-if-not="wpae-google-category-input">\n <ul class="categories" dx-start-with="categories">\n <li ng-repeat="category in $dxPrior.children" style="position: relative;">\n <div class="div-content">\n <div class="expand-button" ng-click="expand(category); $event.preventDefault();">\n <div ng-if="category.hasChildren > 0" class="chevron">\n <svg ng-if="!category.opened" width="10" height="10" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg">\n <path d="M1683 1331l-166 165q-19 19-45 19t-45-19l-531-531-531 531q-19 19-45 19t-45-19l-166-165q-19-19-19-45.5t19-45.5l742-741q19-19 45-19t45 19l742 741q19 19 19 45.5t-19 45.5z"/>\n </svg>\n <svg ng-if="category.opened" width="10" height="10" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg">\n <path d="M1683 808l-742 741q-19 19-45 19t-45-19l-742-741q-19-19-19-45.5t19-45.5l166-165q19-19 45-19t45 19l531 531 531-531q19-19 45-19t45 19l166 165q19 19 19 45.5t-19 45.5z"/>\n </svg>\n </div>\n </div>\n <div ng-bind-html="category.name | safe" ng-click="select(category)" class="google-category-name-container">\n </div>\n <div class="clear"></div>\n </div>\n <ul dx-connect="category" class="categories inner-categories" ng-if="category.opened" />\n </li>\n </ul>\n <div ng-if="!categories.children.length" class="google-no-results-found">\n No results found\n </div>\n</div>')}]),angular.module("productCategories/productCategories.tpl.html",[]).run(["$templateCache",function(a){a.put("productCategories/productCategories.tpl.html",'<div class="wpallexport-collapsed wpallexport-section" ng-class="{closed: !productCategories.open}">\n <div class="wpallexport-content-section">\n <div class="wpallexport-collapsed-header disable-jquery" ng-click="productCategories.open = !productCategories.open">\n <h3>Product Categories</h3>\n </div>\n <div class="wpallexport-collapsed-content" ng-slide-down="productCategories.open" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <h4>Product Type</h4>\n <p>Use this attribute to classify the product using your own categories. The categories here don\'t need to match Google\'s list of acceptable product categories.</p>\n <div class="input">\n <label>\n <input type="radio" ng-model="productCategories.productType" value="useWooCommerceProductCategories" />Use WooCommerce\'s product category\n </label>\n </div>\n <div class="input">\n <label>\n <input type="radio" ng-model="productCategories.productType" value="customValue" />Custom data\n </label>\n <div class="input inner" ng-slide-down="productCategories.productType == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="productCategories.productTypeCV" droppable />\n </div>\n </div>\n <h4>Product Category</h4>\n <p>\n Products added to Google Merchant Center must be categorized according to Google\'s list of product categories. Each product may only be assigned one Google product category. <a href="https://support.google.com/merchants/answer/160081" target="_blank">Read more about Google product categories.</a>\n </p>\n <div class="input">\n <label>\n <input type="radio" ng-model="productCategories.productCategories" value="mapProductCategories" />Map WooCommerce\'s product categories to Google\'s product categories\n <a href="#" class="wpallexport-help" style="margin-top:5px; margin-left: 2px;"\n tipsy="Products assigned more than one WooCommerce product category and mapped to more than one Google product category will be mapped to the most specific, deepest Google product category selected for that product.">?</a>\n </label>\n </div>\n <div ng-slide-down="productCategories.productCategories == \'mapProductCategories\'" duration="0.5">\n <category-mapper mappings="productCategories.catMappings" />\n </div>\n\n <div class="input">\n <label>\n <input type="radio" ng-model="productCategories.productCategories" value="useWooCommerceProductCategories" />Use WooCommerce\'s product categories\n <a href="#" class="wpallexport-help" style="margin-top:5px; margin-left: 2px;"\n tipsy="Products assigned to more than one WooCommerce product category will only have the most specific, deepest product category exported.">?</a>\n </label>\n <p class="no-categories-notice" ng-slide-down="productCategories.productCategories == \'useWooCommerceProductCategories\'" duration="0.2">\n If your WooCommerce product categories do not exactly match Google\'s, your feed will fail when uploaded to Google.\n </p>\n <div ng-slide-down="!$root.cats.children.length && productCategories.productCategories == \'useWooCommerceProductCategories\'" duration="0.2">\n <div ng-include="\'productCategories/categoryMapper/noCategoriesNotice.tpl.html\'" ng-init="context = \'categories\' "></div>\n </div>\n </div>\n\n <div class="input">\n <label>\n <input type="radio" ng-model="productCategories.productCategories" value="customValue" />Custom data\n </label>\n <div class="input inner" ng-slide-down="productCategories.productCategories == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="productCategories.productCategoriesCV" droppable />\n </div>\n </div>\n </div>\n\n </div>\n </div>\n</div>')}]),angular.module("shipping/shipping.tpl.html",[]).run(["$templateCache",function(a){a.put("shipping/shipping.tpl.html",'<div class="wpallexport-collapsed wpallexport-section" ng-class="{closed: !shipping.open }">\n <div class="wpallexport-content-section">\n <div class="wpallexport-collapsed-header disable-jquery"\n ng-click="shipping.open = !shipping.open ">\n <h3>Shipping</h3>\n </div>\n <div class="wpallexport-collapsed-content" id="shipping" ng-slide-down="shipping.open" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <h4>Shipping Price</h4>\n <p>\n This attribute allows Google to provide a shipping estimate for the product.\n This overrides the default shipping price configured in the Google Merchant Center.\n </p>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="shipping.shippingPrice" droppable />\n <a href="" ng-click="shipping.adjustShippingPrice = !shipping.adjustShippingPrice" class="adjust-price-link">\n <span ng-if="!shipping.adjustShippingPrice" style="width: 6px; display: inline-block;">+</span>\n <span ng-if="shipping.adjustShippingPrice" style="width: 6px; display: inline-block;">-</span>\n Adjust Shipping Price</a>\n <div ng-slide-down="shipping.adjustShippingPrice" class="adjust-price" duration="0.2" style="margin-top: 5px; ">\n <input type="text" style="margin-top: 0; margin-right: 0;" class="wpae-default-input" ng-model="shipping.adjustShippingPriceValue" droppable /><select style="margin-top:5px;" ng-model="shipping.adjustPriceType">\n <option value="%">%</option>\n <option value="USD">{{currency}}</option>\n </select>\n\n <div ng-show="shipping.adjustPriceType == \'%\'" class="tooltip-container">\n <a href="#" ng-cloak="" class="wpallexport-help" style="top:0;"\n tipsy="Leave blank or enter in 100% to keep the price as is. Enter in 110% to markup by 10%. Enter in 50% to cut prices in half.">?</a>\n </div>\n <div ng-show="shipping.adjustPriceType == \'USD\'" class="tooltip-container">\n <a href="#" style="top:0;" ng-cloak="" class="wpallexport-help" tipsy="Enter a negative number to reduce prices.">?</a>\n </div>\n </div>\n </div>\n\n <h4>Length, Width, Height</h4>\n <div class="input">\n <label>\n <input type="radio" ng-model="shipping.dimensions" value="useWooCommerceProductValues"/>Use WooCommerce\'s product values and convert them to\n <select ng-model="shipping.convertTo" style="width: 175px; height: 30px; padding: 0 0 0 8px; margin-left: 5px; margin-top: 5px; ">\n <option value="cm">Centimeters (cm)</option>\n <option value="inches">Inches (in)</option>\n </select>\n </label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="shipping.dimensions" value="customValue"/>Custom data</label>\n <div ng-slide-down="shipping.dimensions == \'customValue\'" duration="0.2" class="input inner">\n <input type="text" class="wpae-default-input" ng-model="shipping.dimensionsCV" droppable />\n </div>\n </div>\n\n <h4>Shipping Weight</h4>\n <div class="input">\n <label>\n <input type="radio" ng-model="shipping.weight" value=""/>Do not include in the feed\n </label>\n </div>\n <div class="input">\n <label>\n <input type="radio" ng-model="shipping.weight" value="useWooCommerceProductValues"/>Use WooCommerce\'s product values\n </label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="shipping.weight" value="customValue"/>Custom data</label>\n <div ng-slide-down="shipping.weight == \'customValue\'" duration="0.2" class="input inner">\n <input type="text" class="wpae-default-input" ng-model="shipping.weightCV" droppable />\n </div>\n </div>\n\n <h4>Shipping Label</h4>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="shipping.shippingLabel" droppable />\n </div>\n </div>\n </div>\n </div>\n</div>')}]),angular.module("uniqueIdentifiers/uniqueIdentifiers.tpl.html",[]).run(["$templateCache",function(a){a.put("uniqueIdentifiers/uniqueIdentifiers.tpl.html",'<div class="wpallexport-collapsed wpallexport-section" ng-class="{closed: !uniqueIdentifiers.open}">\n <div class="wpallexport-content-section">\n <div class="wpallexport-collapsed-header disable-jquery" ng-click="uniqueIdentifiers.open = !uniqueIdentifiers.open">\n <h3>Unique Identifiers</h3>\n </div>\n <div class="wpallexport-collapsed-content slide-toggle" id="unique-identifiers" ng-slide-down="uniqueIdentifiers.open" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <p>\n Unique product identifiers are product codes associated with your products.\n Products submitted without unique identifiers are difficult to classify and may not be able to take advantage of all Google shopping features.\n <a href="https://support.google.com/merchants/answer/7052112?hl=en&ref_topic=3404778#intro-product-identifiers" target="_blank">Read more about unique product identifiers</a>.\n </p>\n <h4>GTIN</h4>\n <p>\n Global Trade Item Numbers include UPC, EAN (in Europe), JAN (in Japan), and ISBN. <a href="https://support.google.com/merchants/answer/6219078" target="_blank">Read how to find your products\' GTIN</a>.\n </p>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="uniqueIdentifiers.gtin" droppable />\n </div>\n\n <h4>MPN</h4>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="uniqueIdentifiers.mpn" droppable />\n </div>\n\n <h4>Brand</h4>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="uniqueIdentifiers.brand" droppable />\n </div>\n\n <h4>Identifier Exists</h4>\n <div class="input">\n <label><input type="radio" ng-model="uniqueIdentifiers.identifierExists" value="1" />Set to false if product has no GTIN or MPN\n <a style="margin-top: 0; margin-bottom: 0; margin-left: 0; padding-bottom: 0;" class="wpallexport-help" tipsy="If your product has neither an MPN or GTIN, Google requires the attribute \'identifier_exists\' to be set to false. WP All Export will do this automatically if this option is enabled.">?</a>\n </label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="uniqueIdentifiers.identifierExists" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="uniqueIdentifiers.identifierExists == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="uniqueIdentifiers.identifierExistsCV" droppable />\n </div>\n </div>\n\n </div>\n </div>\n </div>\n</div>')}]);
|
4 |
h=b.getSeconds(),i=b.getMilliseconds()),new Date(d,0,j.getDate()+k,f,g,h,i)}}return NaN}function Bd(a,b){return function(c,d){var e,g;if(z(c))return c;if(x(c)){if('"'===c.charAt(0)&&'"'===c.charAt(c.length-1)&&(c=c.substring(1,c.length-1)),hg.test(c))return new Date(c);if(a.lastIndex=0,e=a.exec(c))return e.shift(),g=d?{yyyy:d.getFullYear(),MM:d.getMonth()+1,dd:d.getDate(),HH:d.getHours(),mm:d.getMinutes(),ss:d.getSeconds(),sss:d.getMilliseconds()/1e3}:{yyyy:1970,MM:1,dd:1,HH:0,mm:0,ss:0,sss:0},f(e,function(a,c){c<b.length&&(g[b[c]]=+a)}),new Date(g.yyyy,g.MM-1,g.dd,g.HH,g.mm,g.ss||0,1e3*g.sss||0)}return NaN}}function Cd(a,b,c,d){return function(e,f,g,h,i,j,k){function l(a){return a&&!(a.getTime&&a.getTime()!==a.getTime())}function m(a){return u(a)&&!z(a)?c(a)||void 0:a}Dd(e,f,g,h),zd(e,f,g,h,i,j);var n,o=h&&h.$options.getOption("timezone");if(h.$$parserName=a,h.$parsers.push(function(a){if(h.$isEmpty(a))return null;if(b.test(a)){var d=c(a,n);return o&&(d=aa(d,o)),d}}),h.$formatters.push(function(a){if(a&&!z(a))throw Qg("datefmt","Expected `{0}` to be a date",a);return l(a)?(n=a,n&&o&&(n=aa(n,o,!0)),k("date")(a,d,o)):(n=null,"")}),u(g.min)||g.ngMin){var p;h.$validators.min=function(a){return!l(a)||t(p)||c(a)>=p},g.$observe("min",function(a){p=m(a),h.$validate()})}if(u(g.max)||g.ngMax){var q;h.$validators.max=function(a){return!l(a)||t(q)||c(a)<=q},g.$observe("max",function(a){q=m(a),h.$validate()})}}}function Dd(a,b,c,d){var e=b[0];(d.$$hasNativeValidators=v(e.validity))&&d.$parsers.push(function(a){var c=b.prop(Yd)||{};return c.badInput||c.typeMismatch?void 0:a})}function Ed(a){a.$$parserName="number",a.$parsers.push(function(b){return a.$isEmpty(b)?null:kg.test(b)?parseFloat(b):void 0}),a.$formatters.push(function(b){if(!a.$isEmpty(b)){if(!y(b))throw Qg("numfmt","Expected `{0}` to be a number",b);b=b.toString()}return b})}function Fd(a){return u(a)&&!y(a)&&(a=parseFloat(a)),oe(a)?void 0:a}function Gd(a){return(0|a)===a}function Hd(a){var b=a.toString(),c=b.indexOf(".");if(-1===c){if(-1<a&&a<1){var d=/e-(\d+)$/.exec(b);if(d)return Number(d[1])}return 0}return b.length-c-1}function Id(a,b,c){var d=Number(a),e=!Gd(d),f=!Gd(b),g=!Gd(c);if(e||f||g){var h=e?Hd(d):0,i=f?Hd(b):0,j=g?Hd(c):0,k=Math.max(h,i,j),l=Math.pow(10,k);d*=l,b*=l,c*=l,e&&(d=Math.round(d)),f&&(b=Math.round(b)),g&&(c=Math.round(c))}return(d-b)%c==0}function Jd(a,b,c,d,e,f){Dd(a,b,c,d),Ed(d),zd(a,b,c,d,e,f);var g,h;if((u(c.min)||c.ngMin)&&(d.$validators.min=function(a){return d.$isEmpty(a)||t(g)||a>=g},c.$observe("min",function(a){g=Fd(a),d.$validate()})),(u(c.max)||c.ngMax)&&(d.$validators.max=function(a){return d.$isEmpty(a)||t(h)||a<=h},c.$observe("max",function(a){h=Fd(a),d.$validate()})),u(c.step)||c.ngStep){var i;d.$validators.step=function(a,b){return d.$isEmpty(b)||t(i)||Id(b,g||0,i)},c.$observe("step",function(a){i=Fd(a),d.$validate()})}}function Kd(a,b,c,d,e,f){function g(a,d){b.attr(a,c[a]),c.$observe(a,d)}function h(a){if(l=Fd(a),!oe(d.$modelValue))if(k){var c=b.val();l>c&&(c=l,b.val(c)),d.$setViewValue(c)}else d.$validate()}function i(a){if(m=Fd(a),!oe(d.$modelValue))if(k){var c=b.val();m<c&&(b.val(m),c=m<l?l:m),d.$setViewValue(c)}else d.$validate()}function j(a){n=Fd(a),oe(d.$modelValue)||(k&&d.$viewValue!==b.val()?d.$setViewValue(b.val()):d.$validate())}Dd(a,b,c,d),Ed(d),zd(a,b,c,d,e,f);var k=d.$$hasNativeValidators&&"range"===b[0].type,l=k?0:void 0,m=k?100:void 0,n=k?1:void 0,o=b[0].validity,p=u(c.min),q=u(c.max),r=u(c.step),s=d.$render;d.$render=k&&u(o.rangeUnderflow)&&u(o.rangeOverflow)?function(){s(),d.$setViewValue(b.val())}:s,p&&(d.$validators.min=k?function(){return!0}:function(a,b){return d.$isEmpty(b)||t(l)||b>=l},g("min",h)),q&&(d.$validators.max=k?function(){return!0}:function(a,b){return d.$isEmpty(b)||t(m)||b<=m},g("max",i)),r&&(d.$validators.step=k?function(){return!o.stepMismatch}:function(a,b){return d.$isEmpty(b)||t(n)||Id(b,l||0,n)},g("step",j))}function Ld(a,b,c,d,e,f){zd(a,b,c,d,e,f),xd(d),d.$$parserName="url",d.$validators.url=function(a,b){var c=a||b;return d.$isEmpty(c)||ig.test(c)}}function Md(a,b,c,d,e,f){zd(a,b,c,d,e,f),xd(d),d.$$parserName="email",d.$validators.email=function(a,b){var c=a||b;return d.$isEmpty(c)||jg.test(c)}}function Nd(a,b,c,d){var e=!c.ngTrim||"false"!==re(c.ngTrim);t(c.name)&&b.attr("name",i());var f=function(a){var f;b[0].checked&&(f=c.value,e&&(f=re(f)),d.$setViewValue(f,a&&a.type))};b.on("click",f),d.$render=function(){var a=c.value;e&&(a=re(a)),b[0].checked=a===d.$viewValue},c.$observe("value",d.$render)}function Od(a,b,c,d,e){var f;if(u(d)){if(f=a(d),!f.constant)throw Qg("constexpr","Expected constant expression for `{0}`, but saw `{1}`.",c,d);return f(b)}return e}function Pd(a,b,c,d,e,f,g,h){var i=Od(h,a,"ngTrueValue",c.ngTrueValue,!0),j=Od(h,a,"ngFalseValue",c.ngFalseValue,!1),k=function(a){d.$setViewValue(b[0].checked,a&&a.type)};b.on("click",k),d.$render=function(){b[0].checked=d.$viewValue},d.$isEmpty=function(a){return!1===a},d.$formatters.push(function(a){return T(a,i)}),d.$parsers.push(function(a){return a?i:j})}function Qd(a,b){function c(a,b){if(!a||!a.length)return[];if(!b||!b.length)return a;var c=[];a:for(var d=0;d<a.length;d++){for(var e=a[d],f=0;f<b.length;f++)if(e===b[f])continue a;c.push(e)}return c}function d(a){return a&&a.split(" ")}function e(a){var b=a;return pe(a)?b=a.map(e).join(" "):v(a)&&(b=Object.keys(a).filter(function(b){return a[b]}).join(" ")),b}function g(a){var b=a;if(pe(a))b=a.map(g);else if(v(a)){var c=!1;b=Object.keys(a).filter(function(b){var d=a[b];return!c&&t(d)&&(c=!0),d}),c&&b.push(void 0)}return b}a="ngClass"+a;var h;return["$parse",function(i){return{restrict:"AC",link:function(j,k,l){function m(a){a=p(d(a),1),l.$addClass(a)}function n(a){a=p(d(a),-1),l.$removeClass(a)}function o(a,b){var e=d(a),f=d(b),g=c(e,f),h=c(f,e),i=p(g,-1),j=p(h,1);l.$addClass(j),l.$removeClass(i)}function p(a,b){var c=[];return f(a,function(a){(b>0||z[a])&&(z[a]=(z[a]||0)+b,z[a]===+(b>0)&&c.push(a))}),c.join(" ")}function q(a){a===b?m(t):n(t),A=a}function r(a){var b=e(a);b!==t&&s(b)}function s(a){A===b&&o(t,a),t=a}var t,u=l[a].trim(),v=":"===u.charAt(0)&&":"===u.charAt(1),w=v?g:e,x=i(u,w),y=v?r:s,z=k.data("$classCounts"),A=!0;z||(z=sa(),k.data("$classCounts",z)),"ngClass"!==a&&(h||(h=i("$index",function(a){return 1&a})),j.$watch(h,q)),j.$watch(x,y,v)}}}]}function Rd(a,b,c,d,e,f,g,h,i){this.$viewValue=Number.NaN,this.$modelValue=Number.NaN,this.$$rawModelValue=void 0,this.$validators={},this.$asyncValidators={},this.$parsers=[],this.$formatters=[],this.$viewChangeListeners=[],this.$untouched=!0,this.$touched=!1,this.$pristine=!0,this.$dirty=!1,this.$valid=!0,this.$invalid=!1,this.$error={},this.$$success={},this.$pending=void 0,this.$name=i(c.name||"",!1)(a),this.$$parentForm=cg,this.$options=Rg,this.$$parsedNgModel=e(c.ngModel),this.$$parsedNgModelAssign=this.$$parsedNgModel.assign,this.$$ngModelGet=this.$$parsedNgModel,this.$$ngModelSet=this.$$parsedNgModelAssign,this.$$pendingDebounce=null,this.$$parserValid=void 0,this.$$currentValidationRunId=0,Object.defineProperty(this,"$$scope",{value:a}),this.$$attr=c,this.$$element=d,this.$$animate=f,this.$$timeout=g,this.$$parse=e,this.$$q=h,this.$$exceptionHandler=b,ud(this),Sd(this)}function Sd(a){a.$$scope.$watch(function(b){var c=a.$$ngModelGet(b);if(c!==a.$modelValue&&(a.$modelValue===a.$modelValue||c===c)){a.$modelValue=a.$$rawModelValue=c,a.$$parserValid=void 0;for(var d=a.$formatters,e=d.length,f=c;e--;)f=d[e](f);a.$viewValue!==f&&(a.$$updateEmptyClasses(f),a.$viewValue=a.$$lastCommittedViewValue=f,a.$render(),a.$$runValidators(a.$modelValue,a.$viewValue,p))}return c})}function Td(a){this.$$options=a}function Ud(a,b){f(b,function(b,c){u(a[c])||(a[c]=b)})}function Vd(a,b){a.prop("selected",b),a.attr("selected",b)}var Wd={objectMaxDepth:5},Xd=/^\/(.+)\/([a-z]*)$/,Yd="validity",Zd=Object.prototype.hasOwnProperty,$d=function(a){return x(a)?a.toLowerCase():a},_d=function(a){return x(a)?a.toUpperCase():a},ae=function(a){return x(a)?a.replace(/[A-Z]/g,function(a){return String.fromCharCode(32|a.charCodeAt(0))}):a},be=function(a){return x(a)?a.replace(/[a-z]/g,function(a){return String.fromCharCode(-33&a.charCodeAt(0))}):a};"i"!=="I".toLowerCase()&&($d=ae,_d=be);var ce,de,ee,fe,ge=[].slice,he=[].splice,ie=[].push,je=Object.prototype.toString,ke=Object.getPrototypeOf,le=d("ng"),me=a.angular||(a.angular={}),ne=0;ce=a.document.documentMode;var oe=Number.isNaN||function(a){return a!==a};p.$inject=[],q.$inject=[];var pe=Array.isArray,qe=/^\[object (?:Uint8|Uint8Clamped|Uint16|Uint32|Int8|Int16|Int32|Float32|Float64)Array]$/,re=function(a){return x(a)?a.trim():a},se=function(a){return a.replace(/([-()[\]{}+?*.$^|,:#<!\\])/g,"\\$1").replace(/\x08/g,"\\x08")},te=function(){if(!u(te.rules)){var b=a.document.querySelector("[ng-csp]")||a.document.querySelector("[data-ng-csp]");if(b){var c=b.getAttribute("ng-csp")||b.getAttribute("data-ng-csp");te.rules={noUnsafeEval:!c||-1!==c.indexOf("no-unsafe-eval"),noInlineStyle:!c||-1!==c.indexOf("no-inline-style")}}else te.rules={noUnsafeEval:function(){try{return new Function(""),!1}catch(a){return!0}}(),noInlineStyle:!1}}return te.rules},ue=function(){if(u(ue.name_))return ue.name_;var b,c,d,e,f=we.length;for(c=0;c<f;++c)if(d=we[c],b=a.document.querySelector("["+d.replace(":","\\:")+"jq]")){e=b.getAttribute(d+"jq");break}return ue.name_=e},ve=/:/g,we=["ng-","data-ng-","ng:","x-ng-"],xe=function(b){var c=b.currentScript;if(!c)return!0;if(!(c instanceof a.HTMLScriptElement||c instanceof a.SVGScriptElement))return!1;var d=c.attributes;return[d.getNamedItem("src"),d.getNamedItem("href"),d.getNamedItem("xlink:href")].every(function(a){if(!a)return!0;if(!a.value)return!1;var c=b.createElement("a");if(c.href=a.value,b.location.origin===c.origin)return!0;switch(c.protocol){case"http:":case"https:":case"ftp:":case"blob:":case"file:":case"data:":return!0;default:return!1}})}(a.document),ye=/[A-Z]/g,ze=!1,Ae=1,Be=3,Ce=8,De=9,Ee=11,Fe={full:"1.6.6",major:1,minor:6,dot:6,codeName:"interdimensional-cable"};Ia.expando="ng339";var Ge=Ia.cache={},He=1;Ia._data=function(a){return this.cache[a[this.expando]]||{}};var Ie=/-([a-z])/g,Je=/^-ms-/,Ke={mouseleave:"mouseout",mouseenter:"mouseover"},Le=d("jqLite"),Me=/^<([\w-]+)\s*\/?>(?:<\/\1>|)$/,Ne=/<|&#?\w+;/,Oe=/<([\w:-]+)/,Pe=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:-]+)[^>]*)\/>/gi,Qe={option:[1,'<select multiple="multiple">',"</select>"],thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};Qe.optgroup=Qe.option,Qe.tbody=Qe.tfoot=Qe.colgroup=Qe.caption=Qe.thead,Qe.th=Qe.td;var Re=a.Node.prototype.contains||function(a){return!!(16&this.compareDocumentPosition(a))},Se=Ia.prototype={ready:Ya,toString:function(){var a=[];return f(this,function(b){a.push(""+b)}),"["+a.join(", ")+"]"},eq:function(a){return de(a>=0?this[a]:this[this.length+a])},length:0,push:ie,sort:[].sort,splice:[].splice},Te={};f("multiple,selected,checked,disabled,readOnly,required,open".split(","),function(a){Te[$d(a)]=a});var Ue={};f("input,select,option,textarea,button,form,details".split(","),function(a){Ue[a]=!0});var Ve={ngMinlength:"minlength",ngMaxlength:"maxlength",ngMin:"min",ngMax:"max",ngPattern:"pattern",ngStep:"step"};f({data:Oa,removeData:Ma,hasData:Ea,cleanData:function(a){for(var b=0,c=a.length;b<c;b++)Ma(a[b])}},function(a,b){Ia[b]=a}),f({data:Oa,inheritedData:Ua,scope:function(a){return de.data(a,"$scope")||Ua(a.parentNode||a,["$isolateScope","$scope"])},isolateScope:function(a){return de.data(a,"$isolateScope")||de.data(a,"$isolateScopeNoTemplate")},controller:Ta,injector:function(a){return Ua(a,"$injector")},removeAttr:function(a,b){a.removeAttribute(b)},hasClass:Pa,css:function(a,b,c){if(b=za(b),!u(c))return a.style[b];a.style[b]=c},attr:function(a,b,c){var d,e=a.nodeType;if(e!==Be&&2!==e&&e!==Ce&&a.getAttribute){var f=$d(b),g=Te[f];if(!u(c))return d=a.getAttribute(b),g&&null!==d&&(d=f),null===d?void 0:d;null===c||!1===c&&g?a.removeAttribute(b):a.setAttribute(b,g?f:c)}},prop:function(a,b,c){if(!u(c))return a[b];a[b]=c},text:function(){function a(a,b){if(t(b)){var c=a.nodeType;return c===Ae||c===Be?a.textContent:""}a.textContent=b}return a.$dv="",a}(),val:function(a,b){if(t(b)){if(a.multiple&&"select"===O(a)){var c=[];return f(a.options,function(a){a.selected&&c.push(a.value||a.text)}),c}return a.value}a.value=b},html:function(a,b){if(t(b))return a.innerHTML;Ka(a,!0),a.innerHTML=b},empty:Va},function(a,b){Ia.prototype[b]=function(b,c){var d,e,f=this.length;if(a!==Va&&t(2===a.length&&a!==Pa&&a!==Ta?b:c)){if(v(b)){for(d=0;d<f;d++)if(a===Oa)a(this[d],b);else for(e in b)a(this[d],e,b[e]);return this}for(var g=a.$dv,h=t(g)?Math.min(f,1):f,i=0;i<h;i++){var j=a(this[i],b,c);g=g?g+j:j}return g}for(d=0;d<f;d++)a(this[d],b,c);return this}}),f({removeData:Ma,on:function(a,b,c,d){if(u(d))throw Le("onargs","jqLite#on() does not support the `selector` or `eventData` parameters");if(Da(a)){var e=Na(a,!0),f=e.events,g=e.handle;g||(g=e.handle=_a(a,f));for(var h=b.indexOf(" ")>=0?b.split(" "):[b],i=h.length,j=function(b,d,e){var h=f[b];h||(h=f[b]=[],h.specialHandlerWrapper=d,"$destroy"===b||e||a.addEventListener(b,g)),h.push(c)};i--;)b=h[i],Ke[b]?(j(Ke[b],bb),j(b,void 0,!0)):j(b)}},off:La,one:function(a,b,c){a=de(a),a.on(b,function d(){a.off(b,c),a.off(b,d)}),a.on(b,c)},replaceWith:function(a,b){var c,d=a.parentNode;Ka(a),f(new Ia(b),function(b){c?d.insertBefore(b,c.nextSibling):d.replaceChild(b,a),c=b})},children:function(a){var b=[];return f(a.childNodes,function(a){a.nodeType===Ae&&b.push(a)}),b},contents:function(a){return a.contentDocument||a.childNodes||[]},append:function(a,b){var c=a.nodeType;if(c===Ae||c===Ee){b=new Ia(b);for(var d=0,e=b.length;d<e;d++){var f=b[d];a.appendChild(f)}}},prepend:function(a,b){if(a.nodeType===Ae){var c=a.firstChild;f(new Ia(b),function(b){a.insertBefore(b,c)})}},wrap:function(a,b){Ha(a,de(b).eq(0).clone()[0])},remove:Wa,detach:function(a){Wa(a,!0)},after:function(a,b){var c=a,d=a.parentNode;if(d){b=new Ia(b);for(var e=0,f=b.length;e<f;e++){var g=b[e];d.insertBefore(g,c.nextSibling),c=g}}},addClass:Ra,removeClass:Qa,toggleClass:function(a,b,c){b&&f(b.split(" "),function(b){var d=c;t(d)&&(d=!Pa(a,b)),(d?Ra:Qa)(a,b)})},parent:function(a){var b=a.parentNode;return b&&b.nodeType!==Ee?b:null},next:function(a){return a.nextElementSibling},find:function(a,b){return a.getElementsByTagName?a.getElementsByTagName(b):[]},clone:Ja,triggerHandler:function(a,b,c){var d,e,g,h=b.type||b,i=Na(a),j=i&&i.events,k=j&&j[h];k&&(d={preventDefault:function(){this.defaultPrevented=!0},isDefaultPrevented:function(){return!0===this.defaultPrevented},stopImmediatePropagation:function(){this.immediatePropagationStopped=!0},isImmediatePropagationStopped:function(){return!0===this.immediatePropagationStopped},stopPropagation:p,type:h,target:a},b.type&&(d=l(d,b)),e=va(k),g=c?[d].concat(c):[d],f(e,function(b){d.isImmediatePropagationStopped()||b.apply(a,g)}))}},function(a,b){Ia.prototype[b]=function(b,c,d){for(var e,f=0,g=this.length;f<g;f++)t(e)?(e=a(this[f],b,c,d),u(e)&&(e=de(e))):Sa(e,a(this[f],b,c,d));return u(e)?e:this}}),Ia.prototype.bind=Ia.prototype.on,Ia.prototype.unbind=Ia.prototype.off;var We=Object.create(null);eb.prototype={_idx:function(a){return a===this._lastKey?this._lastIndex:(this._lastKey=a,this._lastIndex=this._keys.indexOf(a),this._lastIndex)},_transformKey:function(a){return oe(a)?We:a},get:function(a){a=this._transformKey(a);var b=this._idx(a);if(-1!==b)return this._values[b]},set:function(a,b){a=this._transformKey(a);var c=this._idx(a);-1===c&&(c=this._lastIndex=this._keys.length),this._keys[c]=a,this._values[c]=b},delete:function(a){a=this._transformKey(a);var b=this._idx(a);return-1!==b&&(this._keys.splice(b,1),this._values.splice(b,1),this._lastKey=NaN,this._lastIndex=-1,!0)}};var Xe=eb,Ye=[function(){this.$get=[function(){return Xe}]}],Ze=/^([^(]+?)=>/,$e=/^[^(]*\(\s*([^)]*)\)/m,_e=/,/,af=/^\s*(_?)(\S+?)\1\s*$/,bf=/((\/\/.*$)|(\/\*[\s\S]*?\*\/))/gm,cf=d("$injector");jb.$$annotate=ib;var df=d("$animate"),ef=1,ff=function(){this.$get=p},gf=function(){var a=new Xe,b=[];this.$get=["$$AnimateRunner","$rootScope",function(c,d){function e(a,b,c){var d=!1;return b&&(b=x(b)?b.split(" "):pe(b)?b:[],f(b,function(b){b&&(d=!0,a[b]=c)})),d}function g(){f(b,function(b){var c=a.get(b);if(c){var d=nb(b.attr("class")),e="",g="";f(c,function(a,b){a!==!!d[b]&&(a?e+=(e.length?" ":"")+b:g+=(g.length?" ":"")+b)}),f(b,function(a){e&&Ra(a,e),g&&Qa(a,g)}),a.delete(b)}}),b.length=0}function h(c,f,h){var i=a.get(c)||{},j=e(i,f,!0),k=e(i,h,!1);(j||k)&&(a.set(c,i),b.push(c),1===b.length&&d.$$postDigest(g))}return{enabled:p,on:p,off:p,pin:p,push:function(a,b,d,e){e&&e(),d=d||{},d.from&&a.css(d.from),d.to&&a.css(d.to),(d.addClass||d.removeClass)&&h(a,d.addClass,d.removeClass);var f=new c;return f.complete(),f}}}]},hf=["$provide",function(a){var b=this,c=null,d=null;this.$$registeredAnimations=Object.create(null),this.register=function(c,d){if(c&&"."!==c.charAt(0))throw df("notcsel","Expecting class selector starting with '.' got '{0}'.",c);var e=c+"-animation";b.$$registeredAnimations[c.substr(1)]=e,a.factory(e,d)},this.customFilter=function(a){return 1===arguments.length&&(d=B(a)?a:null),d},this.classNameFilter=function(a){if(1===arguments.length&&(c=a instanceof RegExp?a:null)){if(new RegExp("[(\\s|\\/)]ng-animate[(\\s|\\/)]").test(c.toString()))throw c=null,df("nongcls",'$animateProvider.classNameFilter(regex) prohibits accepting a regex value which matches/contains the "{0}" CSS class.',"ng-animate")}return c},this.$get=["$$animateQueue",function(a){function b(a,b,c){if(c){var d=mb(c);!d||d.parentNode||d.previousElementSibling||(c=null)}c?c.after(a):b.prepend(a)}return{on:a.on,off:a.off,pin:a.pin,enabled:a.enabled,cancel:function(a){a.end&&a.end()},enter:function(c,d,e,f){return d=d&&de(d),e=e&&de(e),d=d||e.parent(),b(c,d,e),a.push(c,"enter",ob(f))},move:function(c,d,e,f){return d=d&&de(d),e=e&&de(e),d=d||e.parent(),b(c,d,e),a.push(c,"move",ob(f))},leave:function(b,c){return a.push(b,"leave",ob(c),function(){b.remove()})},addClass:function(b,c,d){return d=ob(d),d.addClass=lb(d.addclass,c),a.push(b,"addClass",d)},removeClass:function(b,c,d){return d=ob(d),d.removeClass=lb(d.removeClass,c),a.push(b,"removeClass",d)},setClass:function(b,c,d,e){return e=ob(e),e.addClass=lb(e.addClass,c),e.removeClass=lb(e.removeClass,d),a.push(b,"setClass",e)},animate:function(b,c,d,e,f){return f=ob(f),f.from=f.from?l(f.from,c):c,f.to=f.to?l(f.to,d):d,e=e||"ng-inline-animate",f.tempClasses=lb(f.tempClasses,e),a.push(b,"animate",f)}}}]}],jf=function(){this.$get=["$$rAF",function(a){function b(b){c.push(b),c.length>1||a(function(){for(var a=0;a<c.length;a++)c[a]();c=[]})}var c=[];return function(){var a=!1;return b(function(){a=!0}),function(c){a?c():b(c)}}}]},kf=function(){this.$get=["$q","$sniffer","$$animateAsyncRun","$$isDocumentHidden","$timeout",function(a,b,c,d,e){function g(a){this.setHost(a);var b=c(),f=function(a){e(a,0,!1)};this._doneCallbacks=[],this._tick=function(a){d()?f(a):b(a)},this._state=0}return g.chain=function(a,b){function c(){if(d===a.length)return void b(!0);a[d](function(a){if(!1===a)return void b(!1);d++,c()})}var d=0;c()},g.all=function(a,b){function c(c){e=e&&c,++d===a.length&&b(e)}var d=0,e=!0;f(a,function(a){a.done(c)})},g.prototype={setHost:function(a){this.host=a||{}},done:function(a){2===this._state?a():this._doneCallbacks.push(a)},progress:p,getPromise:function(){if(!this.promise){var b=this;this.promise=a(function(a,c){b.done(function(b){!1===b?c():a()})})}return this.promise},then:function(a,b){return this.getPromise().then(a,b)},catch:function(a){return this.getPromise().catch(a)},finally:function(a){return this.getPromise().finally(a)},pause:function(){this.host.pause&&this.host.pause()},resume:function(){this.host.resume&&this.host.resume()},end:function(){this.host.end&&this.host.end(),this._resolve(!0)},cancel:function(){this.host.cancel&&this.host.cancel(),this._resolve(!1)},complete:function(a){var b=this;0===b._state&&(b._state=1,b._tick(function(){b._resolve(a)}))},_resolve:function(a){2!==this._state&&(f(this._doneCallbacks,function(b){b(a)}),this._doneCallbacks.length=0,this._state=2)}},g}]},lf=function(){this.$get=["$$rAF","$q","$$AnimateRunner",function(a,b,c){return function(b,d){function e(){return a(function(){f(),h||i.complete(),h=!0}),i}function f(){g.addClass&&(b.addClass(g.addClass),g.addClass=null),g.removeClass&&(b.removeClass(g.removeClass),g.removeClass=null),g.to&&(b.css(g.to),g.to=null)}var g=d||{};g.$$prepared||(g=R(g)),g.cleanupStyles&&(g.from=g.to=null),g.from&&(b.css(g.from),g.from=null);var h,i=new c;return{start:e,end:e}}}]},mf=d("$compile"),nf=new tb;ub.$inject=["$provide","$$sanitizeUriProvider"],vb.prototype.isFirstChange=function(){return this.previousValue===nf};var of=/^((?:x|data)[:\-_])/i,pf=/[:\-_]+(.)/g,qf=d("$controller"),rf=/^(\S+)(\s+as\s+([\w$]+))?$/,sf=function(){this.$get=["$document",function(a){return function(b){return b?!b.nodeType&&b instanceof de&&(b=b[0]):b=a[0].body,b.offsetWidth+1}}]},tf="application/json",uf={"Content-Type":tf+";charset=utf-8"},vf=/^\[|^\{(?!\{)/,wf={"[":/]$/,"{":/}$/},xf=/^\)]\}',?\n/,yf=d("$http"),zf=me.$interpolateMinErr=d("$interpolate");zf.throwNoconcat=function(a){throw zf("noconcat","Error while interpolating: {0}\nStrict Contextual Escaping disallows interpolations that concatenate multiple expressions when a trusted value is required. See http://docs.angularjs.org/api/ng.$sce",a)},zf.interr=function(a,b){return zf("interr","Can't interpolate: {0}\n{1}",a,b.toString())};var Af=function(){this.$get=function(){function a(a){var b=function(a){b.data=a,b.called=!0};return b.id=a,b}var b=me.callbacks,c={};return{createCallback:function(d){var e="_"+(b.$$counter++).toString(36),f="angular.callbacks."+e,g=a(e);return c[f]=b[e]=g,f},wasCalled:function(a){return c[a].called},getResponse:function(a){return c[a].data},removeCallback:function(a){var d=c[a];delete b[d.id],delete c[a]}}}},Bf=/^([^?#]*)(\?([^#]*))?(#(.*))?$/,Cf={http:80,https:443,ftp:21},Df=d("$location"),Ef=/^\s*[\\/]{2,}/,Ff={$$absUrl:"",$$html5:!1,$$replace:!1,absUrl:dc("$$absUrl"),url:function(a){if(t(a))return this.$$url;var b=Bf.exec(a);return(b[1]||""===a)&&this.path(decodeURIComponent(b[1])),(b[2]||b[1]||""===a)&&this.search(b[3]||""),this.hash(b[5]||""),this},protocol:dc("$$protocol"),host:dc("$$host"),port:dc("$$port"),path:ec("$$path",function(a){return a=null!==a?a.toString():"","/"===a.charAt(0)?a:"/"+a}),search:function(a,b){switch(arguments.length){case 0:return this.$$search;case 1:if(x(a)||y(a))a=a.toString(),this.$$search=da(a);else{if(!v(a))throw Df("isrcharg","The first argument of the `$location#search()` call must be a string or an object.");a=R(a,{}),f(a,function(b,c){null==b&&delete a[c]}),this.$$search=a}break;default:t(b)||null===b?delete this.$$search[a]:this.$$search[a]=b}return this.$$compose(),this},hash:ec("$$hash",function(a){return null!==a?a.toString():""}),replace:function(){return this.$$replace=!0,this}};f([cc,bc,ac],function(a){a.prototype=Object.create(Ff),a.prototype.state=function(b){if(!arguments.length)return this.$$state;if(a!==ac||!this.$$html5)throw Df("nostate","History API state support is available only in HTML5 mode and only in browsers supporting HTML5 History API");return this.$$state=t(b)?null:b,this.$$urlUpdatedByLocation=!0,this}});var Gf=d("$parse"),Hf={}.constructor.prototype.valueOf,If=sa();f("+ - * / % === !== == != < > <= >= && || ! = |".split(" "),function(a){If[a]=!0});var Jf={n:"\n",f:"\f",r:"\r",t:"\t",v:"\v","'":"'",'"':'"'},Kf=function(a){this.options=a};Kf.prototype={constructor:Kf,lex:function(a){for(this.text=a,this.index=0,this.tokens=[];this.index<this.text.length;){var b=this.text.charAt(this.index);if('"'===b||"'"===b)this.readString(b);else if(this.isNumber(b)||"."===b&&this.isNumber(this.peek()))this.readNumber();else if(this.isIdentifierStart(this.peekMultichar()))this.readIdent();else if(this.is(b,"(){}[].,;:?"))this.tokens.push({index:this.index,text:b}),this.index++;else if(this.isWhitespace(b))this.index++;else{var c=b+this.peek(),d=c+this.peek(2),e=If[b],f=If[c],g=If[d];if(e||f||g){var h=g?d:f?c:b;this.tokens.push({index:this.index,text:h,operator:!0}),this.index+=h.length}else this.throwError("Unexpected next character ",this.index,this.index+1)}}return this.tokens},is:function(a,b){return-1!==b.indexOf(a)},peek:function(a){var b=a||1;return this.index+b<this.text.length&&this.text.charAt(this.index+b)},isNumber:function(a){return"0"<=a&&a<="9"&&"string"==typeof a},isWhitespace:function(a){return" "===a||"\r"===a||"\t"===a||"\n"===a||"\v"===a||" "===a},isIdentifierStart:function(a){return this.options.isIdentifierStart?this.options.isIdentifierStart(a,this.codePointAt(a)):this.isValidIdentifierStart(a)},isValidIdentifierStart:function(a){return"a"<=a&&a<="z"||"A"<=a&&a<="Z"||"_"===a||"$"===a},isIdentifierContinue:function(a){return this.options.isIdentifierContinue?this.options.isIdentifierContinue(a,this.codePointAt(a)):this.isValidIdentifierContinue(a)},isValidIdentifierContinue:function(a,b){return this.isValidIdentifierStart(a,b)||this.isNumber(a)},codePointAt:function(a){return 1===a.length?a.charCodeAt(0):(a.charCodeAt(0)<<10)+a.charCodeAt(1)-56613888},peekMultichar:function(){var a=this.text.charAt(this.index),b=this.peek();if(!b)return a;var c=a.charCodeAt(0),d=b.charCodeAt(0);return c>=55296&&c<=56319&&d>=56320&&d<=57343?a+b:a},isExpOperator:function(a){return"-"===a||"+"===a||this.isNumber(a)},throwError:function(a,b,c){c=c||this.index;var d=u(b)?"s "+b+"-"+this.index+" ["+this.text.substring(b,c)+"]":" "+c;throw Gf("lexerr","Lexer Error: {0} at column{1} in expression [{2}].",a,d,this.text)},readNumber:function(){for(var a="",b=this.index;this.index<this.text.length;){var c=$d(this.text.charAt(this.index));if("."===c||this.isNumber(c))a+=c;else{var d=this.peek();if("e"===c&&this.isExpOperator(d))a+=c;else if(this.isExpOperator(c)&&d&&this.isNumber(d)&&"e"===a.charAt(a.length-1))a+=c;else{if(!this.isExpOperator(c)||d&&this.isNumber(d)||"e"!==a.charAt(a.length-1))break;this.throwError("Invalid exponent")}}this.index++}this.tokens.push({index:b,text:a,constant:!0,value:Number(a)})},readIdent:function(){var a=this.index;for(this.index+=this.peekMultichar().length;this.index<this.text.length;){var b=this.peekMultichar();if(!this.isIdentifierContinue(b))break;this.index+=b.length}this.tokens.push({index:a,text:this.text.slice(a,this.index),identifier:!0})},readString:function(a){var b=this.index;this.index++;for(var c="",d=a,e=!1;this.index<this.text.length;){var f=this.text.charAt(this.index);if(d+=f,e){if("u"===f){var g=this.text.substring(this.index+1,this.index+5);g.match(/[\da-f]{4}/i)||this.throwError("Invalid unicode escape [\\u"+g+"]"),this.index+=4,c+=String.fromCharCode(parseInt(g,16))}else{c+=Jf[f]||f}e=!1}else if("\\"===f)e=!0;else{if(f===a)return this.index++,void this.tokens.push({index:b,text:d,constant:!0,value:c});c+=f}this.index++}this.throwError("Unterminated quote",b)}};var Lf=function(a,b){this.lexer=a,this.options=b};Lf.Program="Program",Lf.ExpressionStatement="ExpressionStatement",Lf.AssignmentExpression="AssignmentExpression",Lf.ConditionalExpression="ConditionalExpression",Lf.LogicalExpression="LogicalExpression",Lf.BinaryExpression="BinaryExpression",Lf.UnaryExpression="UnaryExpression",Lf.CallExpression="CallExpression",Lf.MemberExpression="MemberExpression",Lf.Identifier="Identifier",Lf.Literal="Literal",Lf.ArrayExpression="ArrayExpression",Lf.Property="Property",Lf.ObjectExpression="ObjectExpression",Lf.ThisExpression="ThisExpression",Lf.LocalsExpression="LocalsExpression",Lf.NGValueParameter="NGValueParameter",Lf.prototype={ast:function(a){this.text=a,this.tokens=this.lexer.lex(a);var b=this.program();return 0!==this.tokens.length&&this.throwError("is an unexpected token",this.tokens[0]),b},program:function(){for(var a=[];;)if(this.tokens.length>0&&!this.peek("}",")",";","]")&&a.push(this.expressionStatement()),!this.expect(";"))return{type:Lf.Program,body:a}},expressionStatement:function(){return{type:Lf.ExpressionStatement,expression:this.filterChain()}},filterChain:function(){for(var a=this.expression();this.expect("|");)a=this.filter(a);return a},expression:function(){return this.assignment()},assignment:function(){var a=this.ternary();if(this.expect("=")){if(!oc(a))throw Gf("lval","Trying to assign a value to a non l-value");a={type:Lf.AssignmentExpression,left:a,right:this.assignment(),operator:"="}}return a},ternary:function(){var a,b,c=this.logicalOR();return this.expect("?")&&(a=this.expression(),this.consume(":"))?(b=this.expression(),{type:Lf.ConditionalExpression,test:c,alternate:a,consequent:b}):c},logicalOR:function(){for(var a=this.logicalAND();this.expect("||");)a={type:Lf.LogicalExpression,operator:"||",left:a,right:this.logicalAND()};return a},logicalAND:function(){for(var a=this.equality();this.expect("&&");)a={type:Lf.LogicalExpression,operator:"&&",left:a,right:this.equality()};return a},equality:function(){for(var a,b=this.relational();a=this.expect("==","!=","===","!==");)b={type:Lf.BinaryExpression,operator:a.text,left:b,right:this.relational()};return b},relational:function(){for(var a,b=this.additive();a=this.expect("<",">","<=",">=");)b={type:Lf.BinaryExpression,operator:a.text,left:b,right:this.additive()};return b},additive:function(){for(var a,b=this.multiplicative();a=this.expect("+","-");)b={type:Lf.BinaryExpression,operator:a.text,left:b,right:this.multiplicative()};return b},multiplicative:function(){for(var a,b=this.unary();a=this.expect("*","/","%");)b={type:Lf.BinaryExpression,operator:a.text,left:b,right:this.unary()};return b},unary:function(){var a;return(a=this.expect("+","-","!"))?{type:Lf.UnaryExpression,operator:a.text,prefix:!0,argument:this.unary()}:this.primary()},primary:function(){var a;this.expect("(")?(a=this.filterChain(),this.consume(")")):this.expect("[")?a=this.arrayDeclaration():this.expect("{")?a=this.object():this.selfReferential.hasOwnProperty(this.peek().text)?a=R(this.selfReferential[this.consume().text]):this.options.literals.hasOwnProperty(this.peek().text)?a={type:Lf.Literal,value:this.options.literals[this.consume().text]}:this.peek().identifier?a=this.identifier():this.peek().constant?a=this.constant():this.throwError("not a primary expression",this.peek());for(var b;b=this.expect("(","[",".");)"("===b.text?(a={type:Lf.CallExpression,callee:a,arguments:this.parseArguments()},this.consume(")")):"["===b.text?(a={type:Lf.MemberExpression,object:a,property:this.expression(),computed:!0},this.consume("]")):"."===b.text?a={type:Lf.MemberExpression,object:a,property:this.identifier(),computed:!1}:this.throwError("IMPOSSIBLE");return a},filter:function(a){for(var b=[a],c={type:Lf.CallExpression,callee:this.identifier(),arguments:b,filter:!0};this.expect(":");)b.push(this.expression());return c},parseArguments:function(){var a=[];if(")"!==this.peekToken().text)do{a.push(this.filterChain())}while(this.expect(","));return a},identifier:function(){var a=this.consume();return a.identifier||this.throwError("is not a valid identifier",a),{type:Lf.Identifier,name:a.text}},constant:function(){return{type:Lf.Literal,value:this.consume().value}},arrayDeclaration:function(){var a=[];if("]"!==this.peekToken().text)do{if(this.peek("]"))break;a.push(this.expression())}while(this.expect(","));return this.consume("]"),{type:Lf.ArrayExpression,elements:a}},object:function(){var a,b=[];if("}"!==this.peekToken().text)do{if(this.peek("}"))break;a={type:Lf.Property,kind:"init"},this.peek().constant?(a.key=this.constant(),a.computed=!1,this.consume(":"),a.value=this.expression()):this.peek().identifier?(a.key=this.identifier(),a.computed=!1,this.peek(":")?(this.consume(":"),a.value=this.expression()):a.value=a.key):this.peek("[")?(this.consume("["),a.key=this.expression(),this.consume("]"),a.computed=!0,
|
5 |
this.consume(":"),a.value=this.expression()):this.throwError("invalid key",this.peek()),b.push(a)}while(this.expect(","));return this.consume("}"),{type:Lf.ObjectExpression,properties:b}},throwError:function(a,b){throw Gf("syntax","Syntax Error: Token '{0}' {1} at column {2} of the expression [{3}] starting at [{4}].",b.text,a,b.index+1,this.text,this.text.substring(b.index))},consume:function(a){if(0===this.tokens.length)throw Gf("ueoe","Unexpected end of expression: {0}",this.text);var b=this.expect(a);return b||this.throwError("is unexpected, expecting ["+a+"]",this.peek()),b},peekToken:function(){if(0===this.tokens.length)throw Gf("ueoe","Unexpected end of expression: {0}",this.text);return this.tokens[0]},peek:function(a,b,c,d){return this.peekAhead(0,a,b,c,d)},peekAhead:function(a,b,c,d,e){if(this.tokens.length>a){var f=this.tokens[a],g=f.text;if(g===b||g===c||g===d||g===e||!b&&!c&&!d&&!e)return f}return!1},expect:function(a,b,c,d){var e=this.peek(a,b,c,d);return!!e&&(this.tokens.shift(),e)},selfReferential:{this:{type:Lf.ThisExpression},$locals:{type:Lf.LocalsExpression}}};var Mf=1,Nf=2;sc.prototype={compile:function(a){var b=this;this.state={nextId:0,filters:{},fn:{vars:[],body:[],own:{}},assign:{vars:[],body:[],own:{}},inputs:[]},mc(a,b.$filter);var c,d="";if(this.stage="assign",c=pc(a)){this.state.computing="assign";var e=this.nextId();this.recurse(c,e),this.return_(e),d="fn.assign="+this.generateFunction("assign","s,v,l")}var g=nc(a.body);b.stage="inputs",f(g,function(a,c){var d="fn"+c;b.state[d]={vars:[],body:[],own:{}},b.state.computing=d;var e=b.nextId();b.recurse(a,e),b.return_(e),b.state.inputs.push({name:d,isPure:a.isPure}),a.watchId=c}),this.state.computing="fn",this.stage="main",this.recurse(a);var h='"'+this.USE+" "+this.STRICT+'";\n'+this.filterPrefix()+"var fn="+this.generateFunction("fn","s,l,a,i")+d+this.watchFns()+"return fn;",i=new Function("$filter","getStringValue","ifDefined","plus",h)(this.$filter,hc,ic,jc);return this.state=this.stage=void 0,i},USE:"use",STRICT:"strict",watchFns:function(){var a=[],b=this.state.inputs,c=this;return f(b,function(b){a.push("var "+b.name+"="+c.generateFunction(b.name,"s")),b.isPure&&a.push(b.name,".isPure="+JSON.stringify(b.isPure)+";")}),b.length&&a.push("fn.inputs=["+b.map(function(a){return a.name}).join(",")+"];"),a.join("")},generateFunction:function(a,b){return"function("+b+"){"+this.varsPrefix(a)+this.body(a)+"};"},filterPrefix:function(){var a=[],b=this;return f(this.state.filters,function(c,d){a.push(c+"=$filter("+b.escape(d)+")")}),a.length?"var "+a.join(",")+";":""},varsPrefix:function(a){return this.state[a].vars.length?"var "+this.state[a].vars.join(",")+";":""},body:function(a){return this.state[a].body.join("")},recurse:function(a,b,c,d,e,g){var h,i,j,k,l,m=this;if(d=d||p,!g&&u(a.watchId))return b=b||this.nextId(),void this.if_("i",this.lazyAssign(b,this.computedMember("i",a.watchId)),this.lazyRecurse(a,b,c,d,e,!0));switch(a.type){case Lf.Program:f(a.body,function(b,c){m.recurse(b.expression,void 0,void 0,function(a){i=a}),c!==a.body.length-1?m.current().body.push(i,";"):m.return_(i)});break;case Lf.Literal:k=this.escape(a.value),this.assign(b,k),d(b||k);break;case Lf.UnaryExpression:this.recurse(a.argument,void 0,void 0,function(a){i=a}),k=a.operator+"("+this.ifDefined(i,0)+")",this.assign(b,k),d(k);break;case Lf.BinaryExpression:this.recurse(a.left,void 0,void 0,function(a){h=a}),this.recurse(a.right,void 0,void 0,function(a){i=a}),k="+"===a.operator?this.plus(h,i):"-"===a.operator?this.ifDefined(h,0)+a.operator+this.ifDefined(i,0):"("+h+")"+a.operator+"("+i+")",this.assign(b,k),d(k);break;case Lf.LogicalExpression:b=b||this.nextId(),m.recurse(a.left,b),m.if_("&&"===a.operator?b:m.not(b),m.lazyRecurse(a.right,b)),d(b);break;case Lf.ConditionalExpression:b=b||this.nextId(),m.recurse(a.test,b),m.if_(b,m.lazyRecurse(a.alternate,b),m.lazyRecurse(a.consequent,b)),d(b);break;case Lf.Identifier:b=b||this.nextId(),c&&(c.context="inputs"===m.stage?"s":this.assign(this.nextId(),this.getHasOwnProperty("l",a.name)+"?l:s"),c.computed=!1,c.name=a.name),m.if_("inputs"===m.stage||m.not(m.getHasOwnProperty("l",a.name)),function(){m.if_("inputs"===m.stage||"s",function(){e&&1!==e&&m.if_(m.isNull(m.nonComputedMember("s",a.name)),m.lazyAssign(m.nonComputedMember("s",a.name),"{}")),m.assign(b,m.nonComputedMember("s",a.name))})},b&&m.lazyAssign(b,m.nonComputedMember("l",a.name))),d(b);break;case Lf.MemberExpression:h=c&&(c.context=this.nextId())||this.nextId(),b=b||this.nextId(),m.recurse(a.object,h,void 0,function(){m.if_(m.notNull(h),function(){a.computed?(i=m.nextId(),m.recurse(a.property,i),m.getStringValue(i),e&&1!==e&&m.if_(m.not(m.computedMember(h,i)),m.lazyAssign(m.computedMember(h,i),"{}")),k=m.computedMember(h,i),m.assign(b,k),c&&(c.computed=!0,c.name=i)):(e&&1!==e&&m.if_(m.isNull(m.nonComputedMember(h,a.property.name)),m.lazyAssign(m.nonComputedMember(h,a.property.name),"{}")),k=m.nonComputedMember(h,a.property.name),m.assign(b,k),c&&(c.computed=!1,c.name=a.property.name))},function(){m.assign(b,"undefined")}),d(b)},!!e);break;case Lf.CallExpression:b=b||this.nextId(),a.filter?(i=m.filter(a.callee.name),j=[],f(a.arguments,function(a){var b=m.nextId();m.recurse(a,b),j.push(b)}),k=i+"("+j.join(",")+")",m.assign(b,k),d(b)):(i=m.nextId(),h={},j=[],m.recurse(a.callee,i,h,function(){m.if_(m.notNull(i),function(){f(a.arguments,function(b){m.recurse(b,a.constant?void 0:m.nextId(),void 0,function(a){j.push(a)})}),k=h.name?m.member(h.context,h.name,h.computed)+"("+j.join(",")+")":i+"("+j.join(",")+")",m.assign(b,k)},function(){m.assign(b,"undefined")}),d(b)}));break;case Lf.AssignmentExpression:i=this.nextId(),h={},this.recurse(a.left,void 0,h,function(){m.if_(m.notNull(h.context),function(){m.recurse(a.right,i),k=m.member(h.context,h.name,h.computed)+a.operator+i,m.assign(b,k),d(b||k)})},1);break;case Lf.ArrayExpression:j=[],f(a.elements,function(b){m.recurse(b,a.constant?void 0:m.nextId(),void 0,function(a){j.push(a)})}),k="["+j.join(",")+"]",this.assign(b,k),d(b||k);break;case Lf.ObjectExpression:j=[],l=!1,f(a.properties,function(a){a.computed&&(l=!0)}),l?(b=b||this.nextId(),this.assign(b,"{}"),f(a.properties,function(a){a.computed?(h=m.nextId(),m.recurse(a.key,h)):h=a.key.type===Lf.Identifier?a.key.name:""+a.key.value,i=m.nextId(),m.recurse(a.value,i),m.assign(m.member(b,h,a.computed),i)})):(f(a.properties,function(b){m.recurse(b.value,a.constant?void 0:m.nextId(),void 0,function(a){j.push(m.escape(b.key.type===Lf.Identifier?b.key.name:""+b.key.value)+":"+a)})}),k="{"+j.join(",")+"}",this.assign(b,k)),d(b||k);break;case Lf.ThisExpression:this.assign(b,"s"),d(b||"s");break;case Lf.LocalsExpression:this.assign(b,"l"),d(b||"l");break;case Lf.NGValueParameter:this.assign(b,"v"),d(b||"v")}},getHasOwnProperty:function(a,b){var c=a+"."+b,d=this.current().own;return d.hasOwnProperty(c)||(d[c]=this.nextId(!1,a+"&&("+this.escape(b)+" in "+a+")")),d[c]},assign:function(a,b){if(a)return this.current().body.push(a,"=",b,";"),a},filter:function(a){return this.state.filters.hasOwnProperty(a)||(this.state.filters[a]=this.nextId(!0)),this.state.filters[a]},ifDefined:function(a,b){return"ifDefined("+a+","+this.escape(b)+")"},plus:function(a,b){return"plus("+a+","+b+")"},return_:function(a){this.current().body.push("return ",a,";")},if_:function(a,b,c){if(!0===a)b();else{var d=this.current().body;d.push("if(",a,"){"),b(),d.push("}"),c&&(d.push("else{"),c(),d.push("}"))}},not:function(a){return"!("+a+")"},isNull:function(a){return a+"==null"},notNull:function(a){return a+"!=null"},nonComputedMember:function(a,b){var c=/^[$_a-zA-Z][$_a-zA-Z0-9]*$/,d=/[^$_a-zA-Z0-9]/g;return c.test(b)?a+"."+b:a+'["'+b.replace(d,this.stringEscapeFn)+'"]'},computedMember:function(a,b){return a+"["+b+"]"},member:function(a,b,c){return c?this.computedMember(a,b):this.nonComputedMember(a,b)},getStringValue:function(a){this.assign(a,"getStringValue("+a+")")},lazyRecurse:function(a,b,c,d,e,f){var g=this;return function(){g.recurse(a,b,c,d,e,f)}},lazyAssign:function(a,b){var c=this;return function(){c.assign(a,b)}},stringEscapeRegex:/[^ a-zA-Z0-9]/g,stringEscapeFn:function(a){return"\\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)},escape:function(a){if(x(a))return"'"+a.replace(this.stringEscapeRegex,this.stringEscapeFn)+"'";if(y(a))return a.toString();if(!0===a)return"true";if(!1===a)return"false";if(null===a)return"null";if(void 0===a)return"undefined";throw Gf("esc","IMPOSSIBLE")},nextId:function(a,b){var c="v"+this.state.nextId++;return a||this.current().vars.push(c+(b?"="+b:"")),c},current:function(){return this.state[this.state.computing]}},tc.prototype={compile:function(a){var b=this;mc(a,b.$filter);var c,d;(c=pc(a))&&(d=this.recurse(c));var e,g=nc(a.body);g&&(e=[],f(g,function(a,c){var d=b.recurse(a);d.isPure=a.isPure,a.input=d,e.push(d),a.watchId=c}));var h=[];f(a.body,function(a){h.push(b.recurse(a.expression))});var i=0===a.body.length?p:1===a.body.length?h[0]:function(a,b){var c;return f(h,function(d){c=d(a,b)}),c};return d&&(i.assign=function(a,b,c){return d(a,c,b)}),e&&(i.inputs=e),i},recurse:function(a,b,c){var d,e,g,h=this;if(a.input)return this.inputs(a.input,a.watchId);switch(a.type){case Lf.Literal:return this.value(a.value,b);case Lf.UnaryExpression:return e=this.recurse(a.argument),this["unary"+a.operator](e,b);case Lf.BinaryExpression:case Lf.LogicalExpression:return d=this.recurse(a.left),e=this.recurse(a.right),this["binary"+a.operator](d,e,b);case Lf.ConditionalExpression:return this["ternary?:"](this.recurse(a.test),this.recurse(a.alternate),this.recurse(a.consequent),b);case Lf.Identifier:return h.identifier(a.name,b,c);case Lf.MemberExpression:return d=this.recurse(a.object,!1,!!c),a.computed||(e=a.property.name),a.computed&&(e=this.recurse(a.property)),a.computed?this.computedMember(d,e,b,c):this.nonComputedMember(d,e,b,c);case Lf.CallExpression:return g=[],f(a.arguments,function(a){g.push(h.recurse(a))}),a.filter&&(e=this.$filter(a.callee.name)),a.filter||(e=this.recurse(a.callee,!0)),a.filter?function(a,c,d,f){for(var h=[],i=0;i<g.length;++i)h.push(g[i](a,c,d,f));var j=e.apply(void 0,h,f);return b?{context:void 0,name:void 0,value:j}:j}:function(a,c,d,f){var h,i=e(a,c,d,f);if(null!=i.value){for(var j=[],k=0;k<g.length;++k)j.push(g[k](a,c,d,f));h=i.value.apply(i.context,j)}return b?{value:h}:h};case Lf.AssignmentExpression:return d=this.recurse(a.left,!0,1),e=this.recurse(a.right),function(a,c,f,g){var h=d(a,c,f,g),i=e(a,c,f,g);return h.context[h.name]=i,b?{value:i}:i};case Lf.ArrayExpression:return g=[],f(a.elements,function(a){g.push(h.recurse(a))}),function(a,c,d,e){for(var f=[],h=0;h<g.length;++h)f.push(g[h](a,c,d,e));return b?{value:f}:f};case Lf.ObjectExpression:return g=[],f(a.properties,function(a){a.computed?g.push({key:h.recurse(a.key),computed:!0,value:h.recurse(a.value)}):g.push({key:a.key.type===Lf.Identifier?a.key.name:""+a.key.value,computed:!1,value:h.recurse(a.value)})}),function(a,c,d,e){for(var f={},h=0;h<g.length;++h)g[h].computed?f[g[h].key(a,c,d,e)]=g[h].value(a,c,d,e):f[g[h].key]=g[h].value(a,c,d,e);return b?{value:f}:f};case Lf.ThisExpression:return function(a){return b?{value:a}:a};case Lf.LocalsExpression:return function(a,c){return b?{value:c}:c};case Lf.NGValueParameter:return function(a,c,d){return b?{value:d}:d}}},"unary+":function(a,b){return function(c,d,e,f){var g=a(c,d,e,f);return g=u(g)?+g:0,b?{value:g}:g}},"unary-":function(a,b){return function(c,d,e,f){var g=a(c,d,e,f);return g=u(g)?-g:-0,b?{value:g}:g}},"unary!":function(a,b){return function(c,d,e,f){var g=!a(c,d,e,f);return b?{value:g}:g}},"binary+":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g),i=b(d,e,f,g),j=jc(h,i);return c?{value:j}:j}},"binary-":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g),i=b(d,e,f,g),j=(u(h)?h:0)-(u(i)?i:0);return c?{value:j}:j}},"binary*":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)*b(d,e,f,g);return c?{value:h}:h}},"binary/":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)/b(d,e,f,g);return c?{value:h}:h}},"binary%":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)%b(d,e,f,g);return c?{value:h}:h}},"binary===":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)===b(d,e,f,g);return c?{value:h}:h}},"binary!==":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)!==b(d,e,f,g);return c?{value:h}:h}},"binary==":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)==b(d,e,f,g);return c?{value:h}:h}},"binary!=":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)!=b(d,e,f,g);return c?{value:h}:h}},"binary<":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)<b(d,e,f,g);return c?{value:h}:h}},"binary>":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)>b(d,e,f,g);return c?{value:h}:h}},"binary<=":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)<=b(d,e,f,g);return c?{value:h}:h}},"binary>=":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)>=b(d,e,f,g);return c?{value:h}:h}},"binary&&":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)&&b(d,e,f,g);return c?{value:h}:h}},"binary||":function(a,b,c){return function(d,e,f,g){var h=a(d,e,f,g)||b(d,e,f,g);return c?{value:h}:h}},"ternary?:":function(a,b,c,d){return function(e,f,g,h){var i=a(e,f,g,h)?b(e,f,g,h):c(e,f,g,h);return d?{value:i}:i}},value:function(a,b){return function(){return b?{context:void 0,name:void 0,value:a}:a}},identifier:function(a,b,c){return function(d,e,f,g){var h=e&&a in e?e:d;c&&1!==c&&h&&null==h[a]&&(h[a]={});var i=h?h[a]:void 0;return b?{context:h,name:a,value:i}:i}},computedMember:function(a,b,c,d){return function(e,f,g,h){var i,j,k=a(e,f,g,h);return null!=k&&(i=b(e,f,g,h),i=hc(i),d&&1!==d&&k&&!k[i]&&(k[i]={}),j=k[i]),c?{context:k,name:i,value:j}:j}},nonComputedMember:function(a,b,c,d){return function(e,f,g,h){var i=a(e,f,g,h);d&&1!==d&&i&&null==i[b]&&(i[b]={});var j=null!=i?i[b]:void 0;return c?{context:i,name:b,value:j}:j}},inputs:function(a,b){return function(c,d,e,f){return f?f[b]:a(c,d,e)}}},uc.prototype={constructor:uc,parse:function(a){var b=this.ast.ast(a),c=this.astCompiler.compile(b);return c.literal=qc(b),c.constant=rc(b),c}};var Of=d("$sce"),Pf={HTML:"html",CSS:"css",URL:"url",RESOURCE_URL:"resourceUrl",JS:"js"},Qf=/_([a-z])/g,Rf=d("$compile"),Sf=a.document.createElement("a"),Tf=Pc(a.location.href);Sc.$inject=["$document"],Uc.$inject=["$provide"];var Uf=22,Vf=".",Wf="0";Zc.$inject=["$locale"],$c.$inject=["$locale"];var Xf={yyyy:dd("FullYear",4,0,!1,!0),yy:dd("FullYear",2,0,!0,!0),y:dd("FullYear",1,0,!1,!0),MMMM:ed("Month"),MMM:ed("Month",!0),MM:dd("Month",2,1),M:dd("Month",1,1),LLLL:ed("Month",!1,!0),dd:dd("Date",2),d:dd("Date",1),HH:dd("Hours",2),H:dd("Hours",1),hh:dd("Hours",2,-12),h:dd("Hours",1,-12),mm:dd("Minutes",2),m:dd("Minutes",1),ss:dd("Seconds",2),s:dd("Seconds",1),sss:dd("Milliseconds",3),EEEE:ed("Day"),EEE:ed("Day",!0),a:jd,Z:fd,ww:id(2),w:id(1),G:kd,GG:kd,GGG:kd,GGGG:ld},Yf=/((?:[^yMLdHhmsaZEwG']+)|(?:'(?:[^']|'')*')|(?:E+|y+|M+|L+|d+|H+|h+|m+|s+|a|Z|G+|w+))([\s\S]*)/,Zf=/^-?\d+$/;md.$inject=["$locale"];var $f=r($d),_f=r(_d);qd.$inject=["$parse"];var ag=r({restrict:"E",compile:function(a,b){if(!b.href&&!b.xlinkHref)return function(a,b){if("a"===b[0].nodeName.toLowerCase()){var c="[object SVGAnimatedString]"===je.call(b.prop("href"))?"xlink:href":"href";b.on("click",function(a){b.attr(c)||a.preventDefault()})}}}}),bg={};f(Te,function(a,b){function c(a,c,e){a.$watch(e[d],function(a){e.$set(b,!!a)})}if("multiple"!==a){var d=wb("ng-"+b),e=c;"checked"===a&&(e=function(a,b,e){e.ngModel!==e[d]&&c(a,b,e)}),bg[d]=function(){return{restrict:"A",priority:100,link:e}}}}),f(Ve,function(a,b){bg[b]=function(){return{priority:100,link:function(a,c,d){if("ngPattern"===b&&"/"===d.ngPattern.charAt(0)){var e=d.ngPattern.match(Xd);if(e)return void d.$set("ngPattern",new RegExp(e[1],e[2]))}a.$watch(d[b],function(a){d.$set(b,a)})}}}}),f(["src","srcset","href"],function(a){var b=wb("ng-"+a);bg[b]=function(){return{priority:99,link:function(c,d,e){var f=a,g=a;"href"===a&&"[object SVGAnimatedString]"===je.call(d.prop("href"))&&(g="xlinkHref",e.$attr[g]="xlink:href",f=null),e.$observe(b,function(b){if(!b)return void("href"===a&&e.$set(g,null));e.$set(g,b),ce&&f&&d.prop(f,e[g])})}}}});var cg={$addControl:p,$$renameControl:sd,$removeControl:p,$setValidity:p,$setDirty:p,$setPristine:p,$setSubmitted:p},dg="ng-pending";td.$inject=["$element","$attrs","$scope","$animate","$interpolate"],td.prototype={$rollbackViewValue:function(){f(this.$$controls,function(a){a.$rollbackViewValue()})},$commitViewValue:function(){f(this.$$controls,function(a){a.$commitViewValue()})},$addControl:function(a){pa(a.$name,"input"),this.$$controls.push(a),a.$name&&(this[a.$name]=a),a.$$parentForm=this},$$renameControl:function(a,b){var c=a.$name;this[c]===a&&delete this[c],this[b]=a,a.$name=b},$removeControl:function(a){a.$name&&this[a.$name]===a&&delete this[a.$name],f(this.$pending,function(b,c){this.$setValidity(c,null,a)},this),f(this.$error,function(b,c){this.$setValidity(c,null,a)},this),f(this.$$success,function(b,c){this.$setValidity(c,null,a)},this),Q(this.$$controls,a),a.$$parentForm=cg},$setDirty:function(){this.$$animate.removeClass(this.$$element,Og),this.$$animate.addClass(this.$$element,Pg),this.$dirty=!0,this.$pristine=!1,this.$$parentForm.$setDirty()},$setPristine:function(){this.$$animate.setClass(this.$$element,Og,Pg+" ng-submitted"),this.$dirty=!1,this.$pristine=!0,this.$submitted=!1,f(this.$$controls,function(a){a.$setPristine()})},$setUntouched:function(){f(this.$$controls,function(a){a.$setUntouched()})},$setSubmitted:function(){this.$$animate.addClass(this.$$element,"ng-submitted"),this.$submitted=!0,this.$$parentForm.$setSubmitted()}},vd({clazz:td,set:function(a,b,c){var d=a[b];if(d){-1===d.indexOf(c)&&d.push(c)}else a[b]=[c]},unset:function(a,b,c){var d=a[b];d&&(Q(d,c),0===d.length&&delete a[b])}});var eg=function(a){return["$timeout","$parse",function(b,c){function d(a){return""===a?c('this[""]').assign:c(a).assign||p}return{name:"form",restrict:a?"EAC":"E",require:["form","^^?form"],controller:td,compile:function(c,e){c.addClass(Og).addClass(Mg);var f=e.name?"name":!(!a||!e.ngForm)&&"ngForm";return{pre:function(a,c,e,g){var h=g[0];if(!("action"in e)){var i=function(b){a.$apply(function(){h.$commitViewValue(),h.$setSubmitted()}),b.preventDefault()};c[0].addEventListener("submit",i),c.on("$destroy",function(){b(function(){c[0].removeEventListener("submit",i)},0,!1)})}(g[1]||h.$$parentForm).$addControl(h);var j=f?d(h.$name):p;f&&(j(a,h),e.$observe(f,function(b){h.$name!==b&&(j(a,void 0),h.$$parentForm.$$renameControl(h,b),(j=d(h.$name))(a,h))})),c.on("$destroy",function(){h.$$parentForm.$removeControl(h),j(a,void 0),l(h,cg)})}}}}}]},fg=eg(),gg=eg(!0),hg=/^\d{4,}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+(?:[+-][0-2]\d:[0-5]\d|Z)$/,ig=/^[a-z][a-z\d.+-]*:\/*(?:[^:@]+(?::[^@]+)?@)?(?:[^\s:\/?#]+|\[[a-f\d:]+])(?::\d+)?(?:\/[^?#]*)?(?:\?[^#]*)?(?:#.*)?$/i,jg=/^(?=.{1,254}$)(?=.{1,64}@)[-!#$%&'*+\/0-9=?A-Z^_`a-z{|}~]+(\.[-!#$%&'*+\/0-9=?A-Z^_`a-z{|}~]+)*@[A-Za-z0-9]([A-Za-z0-9-]{0,61}[A-Za-z0-9])?(\.[A-Za-z0-9]([A-Za-z0-9-]{0,61}[A-Za-z0-9])?)*$/,kg=/^\s*(-|\+)?(\d+|(\d*(\.\d*)))([eE][+-]?\d+)?\s*$/,lg=/^(\d{4,})-(\d{2})-(\d{2})$/,mg=/^(\d{4,})-(\d\d)-(\d\d)T(\d\d):(\d\d)(?::(\d\d)(\.\d{1,3})?)?$/,ng=/^(\d{4,})-W(\d\d)$/,og=/^(\d{4,})-(\d\d)$/,pg=/^(\d\d):(\d\d)(?::(\d\d)(\.\d{1,3})?)?$/,qg="keydown wheel mousedown",rg=sa();f("date,datetime-local,month,time,week".split(","),function(a){rg[a]=!0});var sg={text:yd,date:Cd("date",lg,Bd(lg,["yyyy","MM","dd"]),"yyyy-MM-dd"),"datetime-local":Cd("datetimelocal",mg,Bd(mg,["yyyy","MM","dd","HH","mm","ss","sss"]),"yyyy-MM-ddTHH:mm:ss.sss"),time:Cd("time",pg,Bd(pg,["HH","mm","ss","sss"]),"HH:mm:ss.sss"),week:Cd("week",ng,Ad,"yyyy-Www"),month:Cd("month",og,Bd(og,["yyyy","MM"]),"yyyy-MM"),number:Jd,url:Ld,email:Md,radio:Nd,range:Kd,checkbox:Pd,hidden:p,button:p,submit:p,reset:p,file:p},tg=["$browser","$sniffer","$filter","$parse",function(a,b,c,d){return{restrict:"E",require:["?ngModel"],link:{pre:function(e,f,g,h){h[0]&&(sg[$d(g.type)]||sg.text)(e,f,g,h[0],b,a,c,d)}}}}],ug=/^(true|false|\d+)$/,vg=function(){function a(a,b,c){var d=u(c)?c:9===ce?"":null;a.prop("value",d),b.$set("value",c)}return{restrict:"A",priority:100,compile:function(b,c){return ug.test(c.ngValue)?function(b,c,d){a(c,d,b.$eval(d.ngValue))}:function(b,c,d){b.$watch(d.ngValue,function(b){a(c,d,b)})}}}},wg=["$compile",function(a){return{restrict:"AC",compile:function(b){return a.$$addBindingClass(b),function(b,c,d){a.$$addBindingInfo(c,d.ngBind),c=c[0],b.$watch(d.ngBind,function(a){c.textContent=ta(a)})}}}}],xg=["$interpolate","$compile",function(a,b){return{compile:function(c){return b.$$addBindingClass(c),function(c,d,e){var f=a(d.attr(e.$attr.ngBindTemplate));b.$$addBindingInfo(d,f.expressions),d=d[0],e.$observe("ngBindTemplate",function(a){d.textContent=t(a)?"":a})}}}}],yg=["$sce","$parse","$compile",function(a,b,c){return{restrict:"A",compile:function(d,e){var f=b(e.ngBindHtml),g=b(e.ngBindHtml,function(b){return a.valueOf(b)});return c.$$addBindingClass(d),function(b,d,e){c.$$addBindingInfo(d,e.ngBindHtml),b.$watch(g,function(){var c=f(b);d.html(a.getTrustedHtml(c)||"")})}}}}],zg=r({restrict:"A",require:"ngModel",link:function(a,b,c,d){d.$viewChangeListeners.push(function(){a.$eval(c.ngChange)})}}),Ag=Qd("",!0),Bg=Qd("Odd",0),Cg=Qd("Even",1),Dg=rd({compile:function(a,b){b.$set("ngCloak",void 0),a.removeClass("ng-cloak")}}),Eg=[function(){return{restrict:"A",scope:!0,controller:"@",priority:500}}],Fg={},Gg={blur:!0,focus:!0};f("click dblclick mousedown mouseup mouseover mouseout mousemove mouseenter mouseleave keydown keyup keypress submit focus blur copy cut paste".split(" "),function(a){var b=wb("ng-"+a);Fg[b]=["$parse","$rootScope",function(c,d){return{restrict:"A",compile:function(e,f){var g=c(f[b]);return function(b,c){c.on(a,function(c){var e=function(){g(b,{$event:c})};Gg[a]&&d.$$phase?b.$evalAsync(e):b.$apply(e)})}}}}]});var Hg=["$animate","$compile",function(a,b){return{multiElement:!0,transclude:"element",priority:600,terminal:!0,restrict:"A",$$tlb:!0,link:function(c,d,e,f,g){var h,i,j;c.$watch(e.ngIf,function(c){c?i||g(function(c,f){i=f,c[c.length++]=b.$$createComment("end ngIf",e.ngIf),h={clone:c},a.enter(c,d.parent(),d)}):(j&&(j.remove(),j=null),i&&(i.$destroy(),i=null),h&&(j=ra(h.clone),a.leave(j).done(function(a){!1!==a&&(j=null)}),h=null))})}}}],Ig=["$templateRequest","$anchorScroll","$animate",function(a,b,c){return{restrict:"ECA",priority:400,terminal:!0,transclude:"element",controller:me.noop,compile:function(d,e){var f=e.ngInclude||e.src,g=e.onload||"",h=e.autoscroll;return function(d,e,i,j,k){var l,m,n,o=0,p=function(){m&&(m.remove(),m=null),l&&(l.$destroy(),l=null),n&&(c.leave(n).done(function(a){!1!==a&&(m=null)}),m=n,n=null)};d.$watch(f,function(f){var i=function(a){!1===a||!u(h)||h&&!d.$eval(h)||b()},m=++o;f?(a(f,!0).then(function(a){if(!d.$$destroyed&&m===o){var b=d.$new();j.template=a;var h=k(b,function(a){p(),c.enter(a,null,e).done(i)});l=b,n=h,l.$emit("$includeContentLoaded",f),d.$eval(g)}},function(){d.$$destroyed||m===o&&(p(),d.$emit("$includeContentError",f))}),d.$emit("$includeContentRequested",f)):(p(),j.template=null)})}}}}],Jg=["$compile",function(b){return{restrict:"ECA",priority:-400,require:"ngInclude",link:function(c,d,e,f){if(je.call(d[0]).match(/SVG/))return d.empty(),void b(Fa(f.template,a.document).childNodes)(c,function(a){d.append(a)},{futureParentElement:d});d.html(f.template),b(d.contents())(c)}}}],Kg=rd({priority:450,compile:function(){return{pre:function(a,b,c){a.$eval(c.ngInit)}}}}),Lg=function(){return{restrict:"A",priority:100,require:"ngModel",link:function(a,b,c,d){var e=c.ngList||", ",g="false"!==c.ngTrim,h=g?re(e):e,i=function(a){if(!t(a)){var b=[];return a&&f(a.split(h),function(a){a&&b.push(g?re(a):a)}),b}};d.$parsers.push(i),d.$formatters.push(function(a){if(pe(a))return a.join(e)}),d.$isEmpty=function(a){return!a||!a.length}}}},Mg="ng-valid",Ng="ng-invalid",Og="ng-pristine",Pg="ng-dirty",Qg=d("ngModel");Rd.$inject=["$scope","$exceptionHandler","$attrs","$element","$parse","$animate","$timeout","$q","$interpolate"],Rd.prototype={$$initGetterSetters:function(){if(this.$options.getOption("getterSetter")){var a=this.$$parse(this.$$attr.ngModel+"()"),b=this.$$parse(this.$$attr.ngModel+"($$$p)");this.$$ngModelGet=function(b){var c=this.$$parsedNgModel(b);return B(c)&&(c=a(b)),c},this.$$ngModelSet=function(a,c){B(this.$$parsedNgModel(a))?b(a,{$$$p:c}):this.$$parsedNgModelAssign(a,c)}}else if(!this.$$parsedNgModel.assign)throw Qg("nonassign","Expression '{0}' is non-assignable. Element: {1}",this.$$attr.ngModel,ba(this.$$element))},$render:p,$isEmpty:function(a){return t(a)||""===a||null===a||a!==a},$$updateEmptyClasses:function(a){this.$isEmpty(a)?(this.$$animate.removeClass(this.$$element,"ng-not-empty"),this.$$animate.addClass(this.$$element,"ng-empty")):(this.$$animate.removeClass(this.$$element,"ng-empty"),this.$$animate.addClass(this.$$element,"ng-not-empty"))},$setPristine:function(){this.$dirty=!1,this.$pristine=!0,this.$$animate.removeClass(this.$$element,Pg),this.$$animate.addClass(this.$$element,Og)},$setDirty:function(){this.$dirty=!0,this.$pristine=!1,this.$$animate.removeClass(this.$$element,Og),this.$$animate.addClass(this.$$element,Pg),this.$$parentForm.$setDirty()},$setUntouched:function(){this.$touched=!1,this.$untouched=!0,this.$$animate.setClass(this.$$element,"ng-untouched","ng-touched")},$setTouched:function(){this.$touched=!0,this.$untouched=!1,this.$$animate.setClass(this.$$element,"ng-touched","ng-untouched")},$rollbackViewValue:function(){this.$$timeout.cancel(this.$$pendingDebounce),this.$viewValue=this.$$lastCommittedViewValue,this.$render()},$validate:function(){if(!oe(this.$modelValue)){var a=this.$$lastCommittedViewValue,b=this.$$rawModelValue,c=this.$valid,d=this.$modelValue,e=this.$options.getOption("allowInvalid"),f=this;this.$$runValidators(b,a,function(a){e||c===a||(f.$modelValue=a?b:void 0,f.$modelValue!==d&&f.$$writeModelToScope())})}},$$runValidators:function(a,b,c){function d(a,b){g===h.$$currentValidationRunId&&h.$setValidity(a,b)}function e(a){g===h.$$currentValidationRunId&&c(a)}this.$$currentValidationRunId++;var g=this.$$currentValidationRunId,h=this;return function(){var a=h.$$parserName||"parse";return t(h.$$parserValid)?(d(a,null),!0):(h.$$parserValid||(f(h.$validators,function(a,b){d(b,null)}),f(h.$asyncValidators,function(a,b){d(b,null)})),d(a,h.$$parserValid),h.$$parserValid)}()&&function(){var c=!0;return f(h.$validators,function(e,f){var g=Boolean(e(a,b));c=c&&g,d(f,g)}),!!c||(f(h.$asyncValidators,function(a,b){d(b,null)}),!1)}()?void function(){var c=[],g=!0;f(h.$asyncValidators,function(e,f){var h=e(a,b);if(!J(h))throw Qg("nopromise","Expected asynchronous validator to return a promise but got '{0}' instead.",h);d(f,void 0),c.push(h.then(function(){d(f,!0)},function(){g=!1,d(f,!1)}))}),c.length?h.$$q.all(c).then(function(){e(g)},p):e(!0)}():void e(!1)},$commitViewValue:function(){var a=this.$viewValue;this.$$timeout.cancel(this.$$pendingDebounce),(this.$$lastCommittedViewValue!==a||""===a&&this.$$hasNativeValidators)&&(this.$$updateEmptyClasses(a),this.$$lastCommittedViewValue=a,this.$pristine&&this.$setDirty(),this.$$parseAndValidate())},$$parseAndValidate:function(){function a(){d.$modelValue!==f&&d.$$writeModelToScope()}var b=this.$$lastCommittedViewValue,c=b,d=this;if(this.$$parserValid=!t(c)||void 0,this.$$parserValid)for(var e=0;e<this.$parsers.length;e++)if(c=this.$parsers[e](c),t(c)){this.$$parserValid=!1;break}oe(this.$modelValue)&&(this.$modelValue=this.$$ngModelGet(this.$$scope));var f=this.$modelValue,g=this.$options.getOption("allowInvalid");this.$$rawModelValue=c,g&&(this.$modelValue=c,a()),this.$$runValidators(c,this.$$lastCommittedViewValue,function(b){g||(d.$modelValue=b?c:void 0,a())})},$$writeModelToScope:function(){this.$$ngModelSet(this.$$scope,this.$modelValue),f(this.$viewChangeListeners,function(a){try{a()}catch(a){this.$$exceptionHandler(a)}},this)},$setViewValue:function(a,b){this.$viewValue=a,this.$options.getOption("updateOnDefault")&&this.$$debounceViewValueCommit(b)},$$debounceViewValueCommit:function(a){var b=this.$options.getOption("debounce");y(b[a])?b=b[a]:y(b.default)&&(b=b.default),this.$$timeout.cancel(this.$$pendingDebounce);var c=this;b>0?this.$$pendingDebounce=this.$$timeout(function(){c.$commitViewValue()},b):this.$$scope.$root.$$phase?this.$commitViewValue():this.$$scope.$apply(function(){c.$commitViewValue()})},$overrideModelOptions:function(a){this.$options=this.$options.createChild(a)}},vd({clazz:Rd,set:function(a,b){a[b]=!0},unset:function(a,b){delete a[b]}});var Rg,Sg=["$rootScope",function(a){return{restrict:"A",require:["ngModel","^?form","^?ngModelOptions"],controller:Rd,priority:1,compile:function(b){return b.addClass(Og).addClass("ng-untouched").addClass(Mg),{pre:function(a,b,c,d){var e=d[0],f=d[1]||e.$$parentForm,g=d[2];g&&(e.$options=g.$options),e.$$initGetterSetters(),f.$addControl(e),c.$observe("name",function(a){e.$name!==a&&e.$$parentForm.$$renameControl(e,a)}),a.$on("$destroy",function(){e.$$parentForm.$removeControl(e)})},post:function(b,c,d,e){function f(){g.$setTouched()}var g=e[0];g.$options.getOption("updateOn")&&c.on(g.$options.getOption("updateOn"),function(a){g.$$debounceViewValueCommit(a&&a.type)}),c.on("blur",function(){g.$touched||(a.$$phase?b.$evalAsync(f):b.$apply(f))})}}}}}],Tg=/(\s+|^)default(\s+|$)/;Td.prototype={getOption:function(a){return this.$$options[a]},createChild:function(a){var b=!1;return a=l({},a),f(a,function(c,d){"$inherit"===c?"*"===d?b=!0:(a[d]=this.$$options[d],"updateOn"===d&&(a.updateOnDefault=this.$$options.updateOnDefault)):"updateOn"===d&&(a.updateOnDefault=!1,a[d]=re(c.replace(Tg,function(){return a.updateOnDefault=!0," "})))},this),b&&(delete a["*"],Ud(a,this.$$options)),Ud(a,Rg.$$options),new Td(a)}},Rg=new Td({updateOn:"",updateOnDefault:!0,debounce:0,getterSetter:!1,allowInvalid:!1,timezone:null});var Ug=function(){function a(a,b){this.$$attrs=a,this.$$scope=b}return a.$inject=["$attrs","$scope"],a.prototype={$onInit:function(){var a=this.parentCtrl?this.parentCtrl.$options:Rg,b=this.$$scope.$eval(this.$$attrs.ngModelOptions);this.$options=a.createChild(b)}},{restrict:"A",priority:10,require:{parentCtrl:"?^^ngModelOptions"},bindToController:!0,controller:a}},Vg=rd({terminal:!0,priority:1e3}),Wg=d("ngOptions"),Xg=/^\s*([\s\S]+?)(?:\s+as\s+([\s\S]+?))?(?:\s+group\s+by\s+([\s\S]+?))?(?:\s+disable\s+when\s+([\s\S]+?))?\s+for\s+(?:([$\w][$\w]*)|(?:\(\s*([$\w][$\w]*)\s*,\s*([$\w][$\w]*)\s*\)))\s+in\s+([\s\S]+?)(?:\s+track\s+by\s+([\s\S]+?))?$/,Yg=["$compile","$document","$parse",function(b,c,d){function g(a,b,c){function f(a,b,c,d,e){this.selectValue=a,this.viewValue=b,this.label=c,this.group=d,this.disabled=e}function g(a){var b;if(!j&&e(a))b=a;else{b=[];for(var c in a)a.hasOwnProperty(c)&&"$"!==c.charAt(0)&&b.push(c)}return b}var h=a.match(Xg);if(!h)throw Wg("iexp","Expected expression in form of '_select_ (as _label_)? for (_key_,)?_value_ in _collection_' but got '{0}'. Element: {1}",a,ba(b));var i=h[5]||h[7],j=h[6],k=/ as /.test(h[0])&&h[1],l=h[9],m=d(h[2]?h[1]:i),n=k&&d(k),o=n||m,p=l&&d(l),q=l?function(a,b){return p(c,b)}:function(a){return db(a)},r=function(a,b){return q(a,x(a,b))},s=d(h[2]||h[1]),t=d(h[3]||""),u=d(h[4]||""),v=d(h[8]),w={},x=j?function(a,b){return w[j]=b,w[i]=a,w}:function(a){return w[i]=a,w};return{trackBy:l,getTrackByValue:r,getWatchables:d(v,function(a){var b=[];a=a||[];for(var d=g(a),e=d.length,f=0;f<e;f++){var i=a===d?f:d[f],j=a[i],k=x(j,i),l=q(j,k);if(b.push(l),h[2]||h[1]){var m=s(c,k);b.push(m)}if(h[4]){var n=u(c,k);b.push(n)}}return b}),getOptions:function(){for(var a=[],b={},d=v(c)||[],e=g(d),h=e.length,i=0;i<h;i++){var j=d===e?i:e[i],k=d[j],m=x(k,j),n=o(c,m),p=q(n,m),w=s(c,m),y=t(c,m),z=u(c,m),A=new f(p,n,w,y,z);a.push(A),b[p]=A}return{items:a,selectValueMap:b,getOptionFromViewValue:function(a){return b[r(a)]},
|
6 |
getViewValueFromOption:function(a){return l?R(a.viewValue):a.viewValue}}}}}function h(a,d,e,h){function k(a,b){var c=i.cloneNode(!1);b.appendChild(c),m(a,c)}function l(a){var b=w.getOptionFromViewValue(a),c=b&&b.element;return c&&!c.selected&&(c.selected=!0),b}function m(a,b){a.element=b,b.disabled=a.disabled,a.label!==b.label&&(b.label=a.label,b.textContent=a.label),b.value=a.selectValue}function n(){var a=w&&o.readValue();if(w)for(var b=w.items.length-1;b>=0;b--){var c=w.items[b];Wa(u(c.group)?c.element.parentNode:c.element)}w=x.getOptions();var e={};if(w.items.forEach(function(a){var b;u(a.group)?(b=e[a.group],b||(b=j.cloneNode(!1),y.appendChild(b),b.label=null===a.group?"null":a.group,e[a.group]=b),k(a,b)):k(a,y)}),d[0].appendChild(y),p.$render(),!p.$isEmpty(a)){var f=o.readValue();(x.trackBy||q?T(a,f):a===f)||(p.$setViewValue(f),p.$render())}}for(var o=h[0],p=h[1],q=e.multiple,r=0,s=d.children(),t=s.length;r<t;r++)if(""===s[r].value){o.hasEmptyOption=!0,o.emptyOption=s.eq(r);break}d.empty();var v=!!o.emptyOption;de(i.cloneNode(!1)).val("?");var w,x=g(e.ngOptions,d,a),y=c[0].createDocumentFragment();o.generateUnknownOptionValue=function(a){return"?"},q?(o.writeValue=function(a){if(w){var b=a&&a.map(l)||[];w.items.forEach(function(a){a.element.selected&&!P(b,a)&&(a.element.selected=!1)})}},o.readValue=function(){var a=d.val()||[],b=[];return f(a,function(a){var c=w.selectValueMap[a];c&&!c.disabled&&b.push(w.getViewValueFromOption(c))}),b},x.trackBy&&a.$watchCollection(function(){if(pe(p.$viewValue))return p.$viewValue.map(function(a){return x.getTrackByValue(a)})},function(){p.$render()})):(o.writeValue=function(a){if(w){var b=d[0].options[d[0].selectedIndex],c=w.getOptionFromViewValue(a);b&&b.removeAttribute("selected"),c?(d[0].value!==c.selectValue&&(o.removeUnknownOption(),d[0].value=c.selectValue,c.element.selected=!0),c.element.setAttribute("selected","selected")):o.selectUnknownOrEmptyOption(a)}},o.readValue=function(){var a=w.selectValueMap[d.val()];return a&&!a.disabled?(o.unselectEmptyOption(),o.removeUnknownOption(),w.getViewValueFromOption(a)):null},x.trackBy&&a.$watch(function(){return x.getTrackByValue(p.$viewValue)},function(){p.$render()})),v&&(b(o.emptyOption)(a),d.prepend(o.emptyOption),o.emptyOption[0].nodeType===Ce?(o.hasEmptyOption=!1,o.registerOption=function(a,b){""===b.val()&&(o.hasEmptyOption=!0,o.emptyOption=b,o.emptyOption.removeClass("ng-scope"),p.$render(),b.on("$destroy",function(){var a=o.$isEmptyOptionSelected();o.hasEmptyOption=!1,o.emptyOption=void 0,a&&p.$render()}))}):o.emptyOption.removeClass("ng-scope")),a.$watchCollection(x.getWatchables,n)}var i=a.document.createElement("option"),j=a.document.createElement("optgroup");return{restrict:"A",terminal:!0,require:["select","ngModel"],link:{pre:function(a,b,c,d){d[0].registerOption=p},post:h}}}],Zg=["$locale","$interpolate","$log",function(a,b,c){var d=/{}/g,e=/^when(Minus)?(.+)$/;return{link:function(g,h,i){function j(a){h.text(a||"")}var k,l=i.count,m=i.$attr.when&&h.attr(i.$attr.when),n=i.offset||0,o=g.$eval(m)||{},q={},r=b.startSymbol(),s=b.endSymbol(),u=r+l+"-"+n+s,v=me.noop;f(i,function(a,b){var c=e.exec(b);if(c){var d=(c[1]?"-":"")+$d(c[2]);o[d]=h.attr(i.$attr[b])}}),f(o,function(a,c){q[c]=b(a.replace(d,u))}),g.$watch(l,function(b){var d=parseFloat(b),e=oe(d);if(e||d in o||(d=a.pluralCat(d-n)),!(d===k||e&&oe(k))){v();var f=q[d];t(f)?(null!=b&&c.debug("ngPluralize: no rule defined for '"+d+"' in "+m),v=p,j()):v=g.$watch(f,j),k=d}})}}}],$g=["$parse","$animate","$compile",function(a,b,c){var g=d("ngRepeat"),h=function(a,b,c,d,e,f,g){a[c]=d,e&&(a[e]=f),a.$index=b,a.$first=0===b,a.$last=b===g-1,a.$middle=!(a.$first||a.$last),a.$odd=!(a.$even=0==(1&b))},i=function(a){return a.clone[0]},j=function(a){return a.clone[a.clone.length-1]};return{restrict:"A",multiElement:!0,transclude:"element",priority:1e3,terminal:!0,$$tlb:!0,compile:function(d,k){var l=k.ngRepeat,m=c.$$createComment("end ngRepeat",l),n=l.match(/^\s*([\s\S]+?)\s+in\s+([\s\S]+?)(?:\s+as\s+([\s\S]+?))?(?:\s+track\s+by\s+([\s\S]+?))?\s*$/);if(!n)throw g("iexp","Expected expression in form of '_item_ in _collection_[ track by _id_]' but got '{0}'.",l);var o=n[1],p=n[2],q=n[3],r=n[4];if(!(n=o.match(/^(?:(\s*[$\w]+)|\(\s*([$\w]+)\s*,\s*([$\w]+)\s*\))$/)))throw g("iidexp","'_item_' in '_item_ in _collection_' should be an identifier or '(_key_, _value_)' expression, but got '{0}'.",o);var s=n[3]||n[1],t=n[2];if(q&&(!/^[$a-zA-Z_][$a-zA-Z0-9_]*$/.test(q)||/^(null|undefined|this|\$index|\$first|\$middle|\$last|\$even|\$odd|\$parent|\$root|\$id)$/.test(q)))throw g("badident","alias '{0}' is invalid --- must be a valid JS identifier which is not a reserved name.",q);var u,v,w,x,y={$id:db};return r?u=a(r):(w=function(a,b){return db(b)},x=function(a){return a}),function(a,c,d,k,n){u&&(v=function(b,c,d){return t&&(y[t]=b),y[s]=c,y.$index=d,u(a,y)});var o=sa();a.$watchCollection(p,function(d){var k,p,r,u,y,z,A,B,C,D,E,F,G=c[0],H=sa();if(q&&(a[q]=d),e(d))C=d,B=v||w;else{B=v||x,C=[];for(var I in d)Zd.call(d,I)&&"$"!==I.charAt(0)&&C.push(I)}for(u=C.length,E=new Array(u),k=0;k<u;k++)if(y=d===C?k:C[k],z=d[y],A=B(y,z,k),o[A])D=o[A],delete o[A],H[A]=D,E[k]=D;else{if(H[A])throw f(E,function(a){a&&a.scope&&(o[a.id]=a)}),g("dupes","Duplicates in a repeater are not allowed. Use 'track by' expression to specify unique keys. Repeater: {0}, Duplicate key: {1}, Duplicate value: {2}",l,A,z);E[k]={id:A,scope:void 0,clone:void 0},H[A]=!0}for(var J in o){if(D=o[J],F=ra(D.clone),b.leave(F),F[0].parentNode)for(k=0,p=F.length;k<p;k++)F[k].$$NG_REMOVED=!0;D.scope.$destroy()}for(k=0;k<u;k++)if(y=d===C?k:C[k],z=d[y],D=E[k],D.scope){r=G;do{r=r.nextSibling}while(r&&r.$$NG_REMOVED);i(D)!==r&&b.move(ra(D.clone),null,G),G=j(D),h(D.scope,k,s,z,t,y,u)}else n(function(a,c){D.scope=c;var d=m.cloneNode(!1);a[a.length++]=d,b.enter(a,null,G),G=d,D.clone=a,H[D.id]=D,h(D.scope,k,s,z,t,y,u)});o=H})}}}}],_g=["$animate",function(a){return{restrict:"A",multiElement:!0,link:function(b,c,d){b.$watch(d.ngShow,function(b){a[b?"removeClass":"addClass"](c,"ng-hide",{tempClasses:"ng-hide-animate"})})}}}],ah=["$animate",function(a){return{restrict:"A",multiElement:!0,link:function(b,c,d){b.$watch(d.ngHide,function(b){a[b?"addClass":"removeClass"](c,"ng-hide",{tempClasses:"ng-hide-animate"})})}}}],bh=rd(function(a,b,c){a.$watch(c.ngStyle,function(a,c){c&&a!==c&&f(c,function(a,c){b.css(c,"")}),a&&b.css(a)},!0)}),ch=["$animate","$compile",function(a,b){return{require:"ngSwitch",controller:["$scope",function(){this.cases={}}],link:function(c,d,e,g){var h=e.ngSwitch||e.on,i=[],j=[],k=[],l=[],m=function(a,b){return function(c){!1!==c&&a.splice(b,1)}};c.$watch(h,function(c){for(var d,e;k.length;)a.cancel(k.pop());for(d=0,e=l.length;d<e;++d){var h=ra(j[d].clone);l[d].$destroy();(k[d]=a.leave(h)).done(m(k,d))}j.length=0,l.length=0,(i=g.cases["!"+c]||g.cases["?"])&&f(i,function(c){c.transclude(function(d,e){l.push(e);var f=c.element;d[d.length++]=b.$$createComment("end ngSwitchWhen");var g={clone:d};j.push(g),a.enter(d,f.parent(),f)})})})}}}],dh=rd({transclude:"element",priority:1200,require:"^ngSwitch",multiElement:!0,link:function(a,b,c,d,e){f(c.ngSwitchWhen.split(c.ngSwitchWhenSeparator).sort().filter(function(a,b,c){return c[b-1]!==a}),function(a){d.cases["!"+a]=d.cases["!"+a]||[],d.cases["!"+a].push({transclude:e,element:b})})}}),eh=rd({transclude:"element",priority:1200,require:"^ngSwitch",multiElement:!0,link:function(a,b,c,d,e){d.cases["?"]=d.cases["?"]||[],d.cases["?"].push({transclude:e,element:b})}}),fh=d("ngTransclude"),gh=["$compile",function(a){return{restrict:"EAC",terminal:!0,compile:function(b){var c=a(b.contents());return b.empty(),function(a,b,d,e,f){function g(a,c){a.length&&i(a)?b.append(a):(h(),c.$destroy())}function h(){c(a,function(a){b.append(a)})}function i(a){for(var b=0,c=a.length;b<c;b++){var d=a[b];if(d.nodeType!==Be||d.nodeValue.trim())return!0}}if(!f)throw fh("orphan","Illegal use of ngTransclude directive in the template! No parent directive that requires a transclusion found. Element: {0}",ba(b));d.ngTransclude===d.$attr.ngTransclude&&(d.ngTransclude="");var j=d.ngTransclude||d.ngTranscludeSlot;f(g,null,j),j&&!f.isSlotFilled(j)&&h()}}}}],hh=["$templateCache",function(a){return{restrict:"E",terminal:!0,compile:function(b,c){if("text/ng-template"===c.type){var d=c.id,e=b[0].text;a.put(d,e)}}}}],ih={$setViewValue:p,$render:p},jh=["$element","$scope",function(b,c){function d(){h||(h=!0,c.$$postDigest(function(){h=!1,f.ngModelCtrl.$render()}))}function e(a){i||(i=!0,c.$$postDigest(function(){c.$$destroyed||(i=!1,f.ngModelCtrl.$setViewValue(f.readValue()),a&&f.ngModelCtrl.$render())}))}var f=this,g=new Xe;f.selectValueMap={},f.ngModelCtrl=ih,f.multiple=!1,f.unknownOption=de(a.document.createElement("option")),f.hasEmptyOption=!1,f.emptyOption=void 0,f.renderUnknownOption=function(a){var c=f.generateUnknownOptionValue(a);f.unknownOption.val(c),b.prepend(f.unknownOption),Vd(f.unknownOption,!0),b.val(c)},f.updateUnknownOption=function(a){var c=f.generateUnknownOptionValue(a);f.unknownOption.val(c),Vd(f.unknownOption,!0),b.val(c)},f.generateUnknownOptionValue=function(a){return"? "+db(a)+" ?"},f.removeUnknownOption=function(){f.unknownOption.parent()&&f.unknownOption.remove()},f.selectEmptyOption=function(){f.emptyOption&&(b.val(""),Vd(f.emptyOption,!0))},f.unselectEmptyOption=function(){f.hasEmptyOption&&Vd(f.emptyOption,!1)},c.$on("$destroy",function(){f.renderUnknownOption=p}),f.readValue=function(){var a=b.val(),c=a in f.selectValueMap?f.selectValueMap[a]:a;return f.hasOption(c)?c:null},f.writeValue=function(a){var c=b[0].options[b[0].selectedIndex];if(c&&Vd(de(c),!1),f.hasOption(a)){f.removeUnknownOption();var d=db(a);b.val(d in f.selectValueMap?d:a);var e=b[0].options[b[0].selectedIndex];Vd(de(e),!0)}else f.selectUnknownOrEmptyOption(a)},f.addOption=function(a,b){if(b[0].nodeType!==Ce){pa(a,'"option value"'),""===a&&(f.hasEmptyOption=!0,f.emptyOption=b);var c=g.get(a)||0;g.set(a,c+1),d()}},f.removeOption=function(a){var b=g.get(a);b&&(1===b?(g.delete(a),""===a&&(f.hasEmptyOption=!1,f.emptyOption=void 0)):g.set(a,b-1))},f.hasOption=function(a){return!!g.get(a)},f.$hasEmptyOption=function(){return f.hasEmptyOption},f.$isUnknownOptionSelected=function(){return b[0].options[0]===f.unknownOption[0]},f.$isEmptyOptionSelected=function(){return f.hasEmptyOption&&b[0].options[b[0].selectedIndex]===f.emptyOption[0]},f.selectUnknownOrEmptyOption=function(a){null==a&&f.emptyOption?(f.removeUnknownOption(),f.selectEmptyOption()):f.unknownOption.parent().length?f.updateUnknownOption(a):f.renderUnknownOption(a)};var h=!1,i=!1;f.registerOption=function(a,b,c,g,h){if(c.$attr.ngValue){var i,j=NaN;c.$observe("value",function(a){var c,d=b.prop("selected");u(j)&&(f.removeOption(i),delete f.selectValueMap[j],c=!0),j=db(a),i=a,f.selectValueMap[j]=a,f.addOption(a,b),b.attr("value",j),c&&d&&e()})}else g?c.$observe("value",function(a){f.readValue();var c,d=b.prop("selected");u(i)&&(f.removeOption(i),c=!0),i=a,f.addOption(a,b),c&&d&&e()}):h?a.$watch(h,function(a,d){c.$set("value",a);var g=b.prop("selected");d!==a&&f.removeOption(d),f.addOption(a,b),d&&g&&e()}):f.addOption(c.value,b);c.$observe("disabled",function(a){("true"===a||a&&b.prop("selected"))&&(f.multiple?e(!0):(f.ngModelCtrl.$setViewValue(null),f.ngModelCtrl.$render()))}),b.on("$destroy",function(){var a=f.readValue(),b=c.value;f.removeOption(b),d(),(f.multiple&&a&&-1!==a.indexOf(b)||a===b)&&e(!0)})}}],kh=function(){function a(a,b,c,d){var e=d[0],g=d[1];if(!g)return void(e.registerOption=p);if(e.ngModelCtrl=g,b.on("change",function(){e.removeUnknownOption(),a.$apply(function(){g.$setViewValue(e.readValue())})}),c.multiple){e.multiple=!0,e.readValue=function(){var a=[];return f(b.find("option"),function(b){if(b.selected&&!b.disabled){var c=b.value;a.push(c in e.selectValueMap?e.selectValueMap[c]:c)}}),a},e.writeValue=function(a){f(b.find("option"),function(b){var c=!!a&&(P(a,b.value)||P(a,e.selectValueMap[b.value]));c!==b.selected&&Vd(de(b),c)})};var h,i=NaN;a.$watch(function(){i!==g.$viewValue||T(h,g.$viewValue)||(h=va(g.$viewValue),g.$render()),i=g.$viewValue}),g.$isEmpty=function(a){return!a||0===a.length}}}function b(a,b,c,d){var e=d[1];if(e){var f=d[0];e.$render=function(){f.writeValue(e.$viewValue)}}}return{restrict:"E",require:["select","?ngModel"],controller:jh,priority:1,link:{pre:a,post:b}}},lh=["$interpolate",function(a){return{restrict:"E",priority:100,compile:function(b,c){var d,e;return u(c.ngValue)||(u(c.value)?d=a(c.value,!0):(e=a(b.text(),!0))||c.$set("value",b.text())),function(a,b,c){var f=b.parent(),g=f.data("$selectController")||f.parent().data("$selectController");g&&g.registerOption(a,b,c,d,e)}}}}],mh=function(){return{restrict:"A",require:"?ngModel",link:function(a,b,c,d){d&&(c.required=!0,d.$validators.required=function(a,b){return!c.required||!d.$isEmpty(b)},c.$observe("required",function(){d.$validate()}))}}},nh=function(){return{restrict:"A",require:"?ngModel",link:function(a,b,c,e){if(e){var f,g=c.ngPattern||c.pattern;c.$observe("pattern",function(a){if(x(a)&&a.length>0&&(a=new RegExp("^"+a+"$")),a&&!a.test)throw d("ngPattern")("noregexp","Expected {0} to be a RegExp but was {1}. Element: {2}",g,a,ba(b));f=a||void 0,e.$validate()}),e.$validators.pattern=function(a,b){return e.$isEmpty(b)||t(f)||f.test(b)}}}}},oh=function(){return{restrict:"A",require:"?ngModel",link:function(a,b,c,d){if(d){var e=-1;c.$observe("maxlength",function(a){var b=n(a);e=oe(b)?-1:b,d.$validate()}),d.$validators.maxlength=function(a,b){return e<0||d.$isEmpty(b)||b.length<=e}}}}},ph=function(){return{restrict:"A",require:"?ngModel",link:function(a,b,c,d){if(d){var e=0;c.$observe("minlength",function(a){e=n(a)||0,d.$validate()}),d.$validators.minlength=function(a,b){return d.$isEmpty(b)||b.length>=e}}}}};if(a.angular.bootstrap)return void(a.console&&console.log("WARNING: Tried to load angular more than once."));!function(){var b;if(!ze){var c=ue();ee=t(c)?a.jQuery:c?a[c]:void 0,ee&&ee.fn.on?(de=ee,l(ee.fn,{scope:Se.scope,isolateScope:Se.isolateScope,controller:Se.controller,injector:Se.injector,inheritedData:Se.inheritedData}),b=ee.cleanData,ee.cleanData=function(a){for(var c,d,e=0;null!=(d=a[e]);e++)(c=ee._data(d,"events"))&&c.$destroy&&ee(d).triggerHandler("$destroy");b(a)}):de=Ia,me.element=de,ze=!0}}(),function(c){l(c,{errorHandlingConfig:b,bootstrap:ja,copy:R,extend:l,merge:m,equals:T,element:de,forEach:f,injector:jb,noop:p,bind:W,toJson:Y,fromJson:Z,identity:q,isUndefined:t,isDefined:u,isString:x,isFunction:B,isObject:v,isNumber:y,isElement:M,isArray:pe,version:Fe,isDate:z,lowercase:$d,uppercase:_d,callbacks:{$$counter:0},getTestability:la,reloadWithDebugInfo:ka,$$minErr:d,$$csp:te,$$encodeUriSegment:fa,$$encodeUriQuery:ga,$$stringify:ta}),fe=ua(a),fe("ng",["ngLocale"],["$provide",function(a){a.provider({$$sanitizeUri:Fc}),a.provider("$compile",ub).directive({a:ag,input:tg,textarea:tg,form:fg,script:hh,select:kh,option:lh,ngBind:wg,ngBindHtml:yg,ngBindTemplate:xg,ngClass:Ag,ngClassEven:Cg,ngClassOdd:Bg,ngCloak:Dg,ngController:Eg,ngForm:gg,ngHide:ah,ngIf:Hg,ngInclude:Ig,ngInit:Kg,ngNonBindable:Vg,ngPluralize:Zg,ngRepeat:$g,ngShow:_g,ngStyle:bh,ngSwitch:ch,ngSwitchWhen:dh,ngSwitchDefault:eh,ngOptions:Yg,ngTransclude:gh,ngModel:Sg,ngList:Lg,ngChange:zg,pattern:nh,ngPattern:nh,required:mh,ngRequired:mh,minlength:ph,ngMinlength:ph,maxlength:oh,ngMaxlength:oh,ngValue:vg,ngModelOptions:Ug}).directive({ngInclude:Jg}).directive(bg).directive(Fg),a.provider({$anchorScroll:kb,$animate:hf,$animateCss:lf,$$animateJs:ff,$$animateQueue:gf,$$AnimateRunner:kf,$$animateAsyncRun:jf,$browser:qb,$cacheFactory:rb,$controller:Ab,$document:Bb,$$isDocumentHidden:Cb,$exceptionHandler:Db,$filter:Uc,$$forceReflow:sf,$interpolate:Rb,$interval:Sb,$http:Nb,$httpParamSerializer:Fb,$httpParamSerializerJQLike:Gb,$httpBackend:Pb,$xhrFactory:Ob,$jsonpCallbacks:Af,$location:fc,$log:gc,$parse:wc,$rootScope:Ec,$q:xc,$$q:yc,$sce:Kc,$sceDelegate:Jc,$sniffer:Lc,$templateCache:sb,$templateRequest:Mc,$$testability:Nc,$timeout:Oc,$window:Rc,$$rAF:Dc,$$jqLite:cb,$$Map:Ye,$$cookieReader:Tc})}]).info({angularVersion:"1.6.6"})}(me),me.module("ngLocale",[],["$provide",function(a){function b(a){a+="";var b=a.indexOf(".");return-1==b?0:a.length-b-1}function c(a,c){var d=c;void 0===d&&(d=Math.min(b(a),3));var e=Math.pow(10,d);return{v:d,f:(a*e|0)%e}}var d={ZERO:"zero",ONE:"one",TWO:"two",FEW:"few",MANY:"many",OTHER:"other"};a.value("$locale",{DATETIME_FORMATS:{AMPMS:["AM","PM"],DAY:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],ERANAMES:["Before Christ","Anno Domini"],ERAS:["BC","AD"],FIRSTDAYOFWEEK:6,MONTH:["January","February","March","April","May","June","July","August","September","October","November","December"],SHORTDAY:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],SHORTMONTH:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],STANDALONEMONTH:["January","February","March","April","May","June","July","August","September","October","November","December"],WEEKENDRANGE:[5,6],fullDate:"EEEE, MMMM d, y",longDate:"MMMM d, y",medium:"MMM d, y h:mm:ss a",mediumDate:"MMM d, y",mediumTime:"h:mm:ss a",short:"M/d/yy h:mm a",shortDate:"M/d/yy",shortTime:"h:mm a"},NUMBER_FORMATS:{CURRENCY_SYM:"$",DECIMAL_SEP:".",GROUP_SEP:",",PATTERNS:[{gSize:3,lgSize:3,maxFrac:3,minFrac:0,minInt:1,negPre:"-",negSuf:"",posPre:"",posSuf:""},{gSize:3,lgSize:3,maxFrac:2,minFrac:2,minInt:1,negPre:"-¤",negSuf:"",posPre:"¤",posSuf:""}]},id:"en-us",localeID:"en_US",pluralCat:function(a,b){var e=0|a,f=c(a,b);return 1==e&&0==f.v?d.ONE:d.OTHER}})}]),de(function(){ia(a.document,ja)})}(window),!window.angular.$$csp().noInlineStyle&&window.angular.element(document.head).prepend('<style type="text/css">@charset "UTF-8";[ng\\:cloak],[ng-cloak],[data-ng-cloak],[x-ng-cloak],.ng-cloak,.x-ng-cloak,.ng-hide:not(.ng-hide-animate){display:none !important;}ng\\:form{display:block;}.ng-animate-shim{visibility:hidden;}.ng-anchor{position:absolute;}</style>'),function(){"use strict";angular.module("ng-slide-down",[]).directive("ngSlideDown",["$timeout",function(a){var b,c;return b=function(a,b){return void 0!==b.lazyRender?"<div ng-if='lazyRender' ng-transclude></div>":"<div ng-transclude></div>"},c=function(b,c,d,e,f){var g,h,i,j,k,l,m,n,o,p,q;return h=d.duration||1,q=d.timingFunction||"ease-in-out",i=c.scope(),j=d.emitOnClose,n=d.onClose,m=void 0!==d.lazyRender,g=null,o=null,k=function(a){var b,d,e,f,g;for(e=0,d=c.children(),f=0,g=d.length;f<g;f++)b=d[f],e+=b.clientHeight;return e+"px"},p=function(){return g&&a.cancel(g),m&&(b.lazyRender=!0),a(function(){return o&&a.cancel(o),c.css({overflow:"hidden",transitionProperty:"height",transitionDuration:h+"s",transitionTimingFunction:q,height:k()}),o=a(function(){return c.css({overflow:"visible",transition:"none",height:"auto"})},1e3*h)})},l=function(){if(o&&a.cancel(o),c.css({overflow:"hidden",transitionProperty:"height",transitionDuration:h+"s",transitionTimingFunction:q,height:"0px"}),j||n||m)return g=a(function(){if(j&&b.$emit(j,{}),n&&i.$eval(n),m)return b.lazyRender=!1},1e3*h)},b.$watch("expanded",function(b,d){return b?a(p):(null!=b&&(c.css({height:k()}),c[0].clientHeight),a(l))})},{restrict:"A",scope:{expanded:"=ngSlideDown"},transclude:!0,link:c,template:function(a,c){return b(a,c)}}}])}.call(this),function(a,b){"use strict";function c(a,b,c){if(!a)throw ia("areq","Argument '{0}' is {1}",b||"?",c||"required");return a}function d(a,b){return a||b?a?b?(U(a)&&(a=a.join(" ")),U(b)&&(b=b.join(" ")),a+" "+b):a:b:""}function e(a){var b={};return a&&(a.to||a.from)&&(b.to=a.to,b.from=a.from),b}function f(a,b,c){var d="";return a=U(a)?a:a&&Z(a)&&a.length?a.split(/\s+/):[],T(a,function(a,e){a&&a.length>0&&(d+=e>0?" ":"",d+=c?b+a:a+b)}),d}function g(a,b){var c=a.indexOf(b);b>=0&&a.splice(c,1)}function h(a){if(a instanceof _)switch(a.length){case 0:return a;case 1:if(a[0].nodeType===L)return a;break;default:return _(i(a))}if(a.nodeType===L)return _(a)}function i(a){if(!a[0])return a;for(var b=0;b<a.length;b++){var c=a[b];if(c.nodeType===L)return c}}function j(a,b,c){T(b,function(b){a.addClass(b,c)})}function k(a,b,c){T(b,function(b){a.removeClass(b,c)})}function l(a){return function(b,c){c.addClass&&(j(a,b,c.addClass),c.addClass=null),c.removeClass&&(k(a,b,c.removeClass),c.removeClass=null)}}function m(a){if(a=a||{},!a.$$prepared){var b=a.domOperation||aa;a.domOperation=function(){a.$$domOperationFired=!0,b(),b=aa},a.$$prepared=!0}return a}function n(a,b){o(a,b),p(a,b)}function o(a,b){b.from&&(a.css(b.from),b.from=null)}function p(a,b){b.to&&(a.css(b.to),b.to=null)}function q(a,b,c){var d=b.options||{},e=c.options||{},f=(d.addClass||"")+" "+(e.addClass||""),g=(d.removeClass||"")+" "+(e.removeClass||""),h=r(a.attr("class"),f,g);e.preparationClasses&&(d.preparationClasses=y(e.preparationClasses,d.preparationClasses),delete e.preparationClasses);var i=d.domOperation!==aa?d.domOperation:null;return S(d,e),i&&(d.domOperation=i),h.addClass?d.addClass=h.addClass:d.addClass=null,h.removeClass?d.removeClass=h.removeClass:d.removeClass=null,b.addClass=d.addClass,b.removeClass=d.removeClass,d}function r(a,b,c){function d(a){Z(a)&&(a=a.split(" "));var b={};return T(a,function(a){a.length&&(b[a]=!0)}),b}var e={};a=d(a),b=d(b),T(b,function(a,b){e[b]=1}),c=d(c),T(c,function(a,b){e[b]=1===e[b]?null:-1});var f={addClass:"",removeClass:""};return T(e,function(b,c){var d,e;1===b?(d="addClass",e=!a[c]||a[c+N]):-1===b&&(d="removeClass",e=a[c]||a[c+M]),e&&(f[d].length&&(f[d]+=" "),f[d]+=c)}),f}function s(a){return a instanceof _?a[0]:a}function t(a,b,c){var d="";b&&(d=f(b,O,!0)),c.addClass&&(d=y(d,f(c.addClass,M))),c.removeClass&&(d=y(d,f(c.removeClass,N))),d.length&&(c.preparationClasses=d,a.addClass(d))}function u(a,b){b.preparationClasses&&(a.removeClass(b.preparationClasses),b.preparationClasses=null),b.activeClasses&&(a.removeClass(b.activeClasses),b.activeClasses=null)}function v(a,b){var c=b?"-"+b+"s":"";return x(a,[ga,c]),[ga,c]}function w(a,b){var c=b?"paused":"",d=J+da;return x(a,[d,c]),[d,c]}function x(a,b){var c=b[0],d=b[1];a.style[c]=d}function y(a,b){return a?b?a+" "+b:a:b}function z(a){return[fa,a+"s"]}function A(a,b){return[b?ea:ga,a+"s"]}function B(a,b,c){var d=Object.create(null),e=a.getComputedStyle(b)||{};return T(c,function(a,b){var c=e[a];if(c){var f=c.charAt(0);("-"===f||"+"===f||f>=0)&&(c=C(c)),0===c&&(c=null),d[b]=c}}),d}function C(a){var b=0,c=a.split(/\s*,\s*/);return T(c,function(a){"s"===a.charAt(a.length-1)&&(a=a.substring(0,a.length-1)),a=parseFloat(a)||0,b=b?Math.max(a,b):a}),b}function D(a){return 0===a||null!=a}function E(a,b){var c=H,d=a+"s";return b?c+=ba:d+=" linear all",[c,d]}function F(){var a=Object.create(null);return{flush:function(){a=Object.create(null)},count:function(b){var c=a[b];return c?c.total:0},get:function(b){var c=a[b];return c&&c.value},put:function(b,c){a[b]?a[b].total++:a[b]={total:1,value:c}}}}function G(a,b,c){T(c,function(c){a[c]=V(a[c])?a[c]:b.style.getPropertyValue(c)})}var H,I,J,K,L=1,M="-add",N="-remove",O="ng-",P="ng-animate",Q="$$ngAnimateChildren";void 0===a.ontransitionend&&void 0!==a.onwebkittransitionend?("-webkit-",H="WebkitTransition",I="webkitTransitionEnd transitionend"):(H="transition",I="transitionend"),void 0===a.onanimationend&&void 0!==a.onwebkitanimationend?("-webkit-",J="WebkitAnimation",K="webkitAnimationEnd animationend"):(J="animation",K="animationend");var R,S,T,U,V,W,X,Y,Z,$,_,aa,ba="Duration",ca="TimingFunction",da="PlayState",ea=J+"Delay",fa=J+ba,ga=H+"Delay",ha=H+ba,ia=b.$$minErr("ng"),ja=["$$rAF",function(a){function b(a){d=d.concat(a),c()}function c(){if(d.length){for(var b=d.shift(),f=0;f<b.length;f++)b[f]();e||a(function(){e||c()})}}var d,e;return d=b.queue=[],b.waitUntilQuiet=function(b){e&&e(),e=a(function(){e=null,b(),c()})},b}],ka=["$interpolate",function(a){return{link:function(b,c,d){function e(a){a="on"===a||"true"===a,c.data(Q,a)}var f=d.ngAnimateChildren;Z(f)&&0===f.length?c.data(Q,!0):(e(a(f)(b)),d.$observe("ngAnimateChildren",e))}}}],la="$$animateCss",ma=1e3,na=3,oa=1.5,pa={transitionDuration:ha,transitionDelay:ga,transitionProperty:H+"Property",animationDuration:fa,animationDelay:ea,animationIterationCount:J+"IterationCount"},qa={transitionDuration:ha,transitionDelay:ga,animationDuration:fa,animationDelay:ea},ra=["$animateProvider",function(a){var b=F(),c=F();this.$get=["$window","$$jqLite","$$AnimateRunner","$timeout","$$forceReflow","$sniffer","$$rAFScheduler","$$animateQueue",function(a,d,h,i,j,k,q,r){function t(a,b){var c="$$ngAnimateParentKey",d=a.parentNode;return(d[c]||(d[c]=++P))+"-"+a.getAttribute("class")+"-"+b}function u(c,d,e,f){var g=b.get(e);return g||(g=B(a,c,f),"infinite"===g.animationIterationCount&&(g.animationIterationCount=1)),b.put(e,g),g}function y(e,g,h,i){var j;if(b.count(h)>0&&!(j=c.get(h))){var k=f(g,"-stagger");d.addClass(e,k),j=B(a,e,i),j.animationDuration=Math.max(j.animationDuration,0),j.transitionDuration=Math.max(j.transitionDuration,0),d.removeClass(e,k),c.put(h,j)}return j||{}}function C(a){Q.push(a),q.waitUntilQuiet(function(){b.flush(),c.flush();for(var a=j(),d=0;d<Q.length;d++)Q[d](a);Q.length=0})}function F(a,b,c){var d=u(a,b,c,pa),e=d.animationDelay,f=d.transitionDelay;return d.maxDelay=e&&f?Math.max(e,f):e||f,d.maxDuration=Math.max(d.animationDuration*d.animationIterationCount,d.transitionDuration),d}var L=l(d),P=0,Q=[];return function(a,c){function j(){q()}function l(){q(!0)}function q(b){if(!(X||Z&&Y)){X=!0,Y=!1,S.$$skipPreparationClasses||d.removeClass(a,ua),d.removeClass(a,wa),w(W,!1),v(W,!1),T(ha,function(a){W.style[a[0]]=""}),L(a,S),n(a,S),Object.keys(V).length&&T(V,function(a,b){a?W.style.setProperty(b,a):W.style.removeProperty(b)}),S.onDone&&S.onDone(),ka&&ka.length&&a.off(ka.join(" "),P);var c=a.data(la);c&&(i.cancel(c[0].timer),a.removeData(la)),$&&$.complete(!b)}}function u(a){Ja.blockTransition&&v(W,a),Ja.blockKeyframeAnimation&&w(W,!!a)}function B(){return $=new h({end:j,cancel:l}),C(aa),q(),{$$willAnimate:!1,start:function(){return $},end:j}}function P(a){a.stopPropagation();var b=a.originalEvent||a,c=b.$manualTimeStamp||Date.now(),d=parseFloat(b.elapsedTime.toFixed(na));Math.max(c-ga,0)>=da&&d>=ea&&(Z=!0,q())}function Q(){function b(){if(!X){if(u(!1),T(ha,function(a){var b=a[0],c=a[1];W.style[b]=c}),L(a,S),d.addClass(a,wa),Ja.recalculateTimingStyles){if(va=W.getAttribute("class")+" "+ua,ya=t(W,va),Ha=F(W,va,ya),Ia=Ha.maxDelay,ba=Math.max(Ia,0),0===(ea=Ha.maxDuration))return void q();Ja.hasTransitions=Ha.transitionDuration>0,Ja.hasAnimations=Ha.animationDuration>0}if(Ja.applyAnimationDelay&&(Ia="boolean"!=typeof S.delay&&D(S.delay)?parseFloat(S.delay):Ia,ba=Math.max(Ia,0),Ha.animationDelay=Ia,Ka=A(Ia,!0),ha.push(Ka),W.style[Ka[0]]=Ka[1]),da=ba*ma,fa=ea*ma,S.easing){var b,e=S.easing;Ja.hasTransitions&&(b=H+ca,ha.push([b,e]),W.style[b]=e),Ja.hasAnimations&&(b=J+ca,ha.push([b,e]),W.style[b]=e)}Ha.transitionDuration&&ka.push(I),Ha.animationDuration&&ka.push(K),ga=Date.now();var f=da+oa*fa,g=ga+f,h=a.data(la)||[],j=!0;if(h.length){var k=h[0];j=g>k.expectedEndTime,j?i.cancel(k.timer):h.push(q)}if(j){var l=i(c,f,!1);h[0]={timer:l,expectedEndTime:g},h.push(q),a.data(la,h)}ka.length&&a.on(ka.join(" "),P),S.to&&(S.cleanupStyles&&G(V,W,Object.keys(S.to)),p(a,S))}}function c(){var b=a.data(la);if(b){for(var c=1;c<b.length;c++)b[c]();a.removeData(la)}}if(!X){if(!W.parentNode)return void q();var e=function(a){if(Z)Y&&a&&(Y=!1,q());else if(Y=!a,Ha.animationDuration){var b=w(W,Y);Y?ha.push(b):g(ha,b)}},f=Fa>0&&(Ha.transitionDuration&&0===za.transitionDuration||Ha.animationDuration&&0===za.animationDuration)&&Math.max(za.animationDelay,za.transitionDelay);f?i(b,Math.floor(f*Fa*ma),!1):b(),_.resume=function(){e(!0)},_.pause=function(){e(!1)}}}var S=c||{};S.$$prepared||(S=m(R(S)));var V={},W=s(a);if(!W||!W.parentNode||!r.enabled())return B();var X,Y,Z,$,_,ba,da,ea,fa,ga,ha=[],ia=a.attr("class"),ja=e(S),ka=[];if(0===S.duration||!k.animations&&!k.transitions)return B();var pa=S.event&&U(S.event)?S.event.join(" "):S.event,ra=pa&&S.structural,sa="",ta="";ra?sa=f(pa,O,!0):pa&&(sa=pa),S.addClass&&(ta+=f(S.addClass,M)),S.removeClass&&(ta.length&&(ta+=" "),ta+=f(S.removeClass,N)),S.applyClassesEarly&&ta.length&&L(a,S);var ua=[sa,ta].join(" ").trim(),va=ia+" "+ua,wa=f(ua,"-active"),xa=ja.to&&Object.keys(ja.to).length>0;if(!((S.keyframeStyle||"").length>0||xa||ua))return B();var ya,za;if(S.stagger>0){var Aa=parseFloat(S.stagger);za={transitionDelay:Aa,animationDelay:Aa,transitionDuration:0,animationDuration:0}}else ya=t(W,va),za=y(W,ua,ya,qa);S.$$skipPreparationClasses||d.addClass(a,ua);var Ba;if(S.transitionStyle){var Ca=[H,S.transitionStyle];x(W,Ca),ha.push(Ca)}if(S.duration>=0){Ba=W.style[H].length>0;var Da=E(S.duration,Ba);x(W,Da),ha.push(Da)}if(S.keyframeStyle){var Ea=[J,S.keyframeStyle];x(W,Ea),ha.push(Ea)}var Fa=za?S.staggerIndex>=0?S.staggerIndex:b.count(ya):0,Ga=0===Fa;Ga&&!S.skipBlocking&&v(W,9999);var Ha=F(W,va,ya),Ia=Ha.maxDelay;ba=Math.max(Ia,0),ea=Ha.maxDuration;var Ja={};if(Ja.hasTransitions=Ha.transitionDuration>0,Ja.hasAnimations=Ha.animationDuration>0,Ja.hasTransitionAll=Ja.hasTransitions&&"all"===Ha.transitionProperty,Ja.applyTransitionDuration=xa&&(Ja.hasTransitions&&!Ja.hasTransitionAll||Ja.hasAnimations&&!Ja.hasTransitions),Ja.applyAnimationDuration=S.duration&&Ja.hasAnimations,Ja.applyTransitionDelay=D(S.delay)&&(Ja.applyTransitionDuration||Ja.hasTransitions),Ja.applyAnimationDelay=D(S.delay)&&Ja.hasAnimations,Ja.recalculateTimingStyles=ta.length>0,(Ja.applyTransitionDuration||Ja.applyAnimationDuration)&&(ea=S.duration?parseFloat(S.duration):ea,Ja.applyTransitionDuration&&(Ja.hasTransitions=!0,Ha.transitionDuration=ea,Ba=W.style[H+"Property"].length>0,ha.push(E(ea,Ba))),Ja.applyAnimationDuration&&(Ja.hasAnimations=!0,Ha.animationDuration=ea,ha.push(z(ea)))),0===ea&&!Ja.recalculateTimingStyles)return B();if(null!=S.delay){var Ka;"boolean"!=typeof S.delay&&(Ka=parseFloat(S.delay),ba=Math.max(Ka,0)),Ja.applyTransitionDelay&&ha.push(A(Ka)),Ja.applyAnimationDelay&&ha.push(A(Ka,!0))}return null==S.duration&&Ha.transitionDuration>0&&(Ja.recalculateTimingStyles=Ja.recalculateTimingStyles||Ga),da=ba*ma,fa=ea*ma,S.skipBlocking||(Ja.blockTransition=Ha.transitionDuration>0,Ja.blockKeyframeAnimation=Ha.animationDuration>0&&za.animationDelay>0&&0===za.animationDuration),S.from&&(S.cleanupStyles&&G(V,W,Object.keys(S.from)),o(a,S)),Ja.blockTransition||Ja.blockKeyframeAnimation?u(ea):S.skipBlocking||v(W,!1),{$$willAnimate:!0,end:j,start:function(){if(!X)return _={end:j,cancel:l,resume:null,pause:null},$=new h(_),C(Q),$}}}}]}],sa=["$$animationProvider",function(a){function b(a){return a.parentNode&&11===a.parentNode.nodeType}a.drivers.push("$$animateCssDriver");var c="ng-animate-shim",d="ng-anchor-out";this.$get=["$animateCss","$rootScope","$$AnimateRunner","$rootElement","$sniffer","$$jqLite","$document",function(a,e,f,g,h,i,j){function k(a){return a.replace(/\bng-\S+\b/g,"")}function l(a,b){return Z(a)&&(a=a.split(" ")),Z(b)&&(b=b.split(" ")),a.filter(function(a){return-1===b.indexOf(a)}).join(" ")}function m(b,e,g){function h(a){var b={},c=s(a).getBoundingClientRect();return T(["width","height","top","left"],function(a){var d=c[a];switch(a){case"top":d+=p.scrollTop;break;case"left":d+=p.scrollLeft}b[a]=Math.floor(d)+"px"}),b}function i(a){return a.attr("class")||""}function j(){var b=k(i(g)),c=l(b,o),e=l(o,b),f=a(n,{to:h(g),addClass:"ng-anchor-in "+c,removeClass:d+" "+e,delay:!0});return f.$$willAnimate?f:null}function m(){n.remove(),e.removeClass(c),g.removeClass(c)}var n=_(s(e).cloneNode(!0)),o=k(i(n));e.addClass(c),g.addClass(c),n.addClass("ng-anchor"),r.append(n);var q,t=function(){var b=a(n,{addClass:d,delay:!0,from:h(e)});return b.$$willAnimate?b:null}();if(!t&&!(q=j()))return m();var u=t||q;return{start:function(){function a(){c&&c.end()}var b,c=u.start();return c.done(function(){if(c=null,!q&&(q=j()))return c=q.start(),c.done(function(){c=null,m(),b.complete()}),c;m(),b.complete()}),b=new f({end:a,cancel:a})}}}function n(a,b,c,d){
|
7 |
+
var e=o(a),g=o(b),h=[];if(T(d,function(a){var b=a.out,d=a.in,e=m(c,b,d);e&&h.push(e)}),e||g||0!==h.length)return{start:function(){function a(){T(b,function(a){a.end()})}var b=[];e&&b.push(e.start()),g&&b.push(g.start()),T(h,function(a){b.push(a.start())});var c=new f({end:a,cancel:a});return f.all(b,function(a){c.complete(a)}),c}}}function o(b){var c=b.element,d=b.options||{};b.structural&&(d.event=b.event,d.structural=!0,d.applyClassesEarly=!0,"leave"===b.event&&(d.onDone=d.domOperation)),d.preparationClasses&&(d.event=y(d.event,d.preparationClasses));var e=a(c,d);return e.$$willAnimate?e:null}if(!h.animations&&!h.transitions)return aa;var p=j[0].body,q=s(g),r=_(b(q)||p.contains(q)?q:p);return function(a){return a.from&&a.to?n(a.from,a.to,a.classes,a.anchors):o(a)}}]}],ta=["$animateProvider",function(a){this.$get=["$injector","$$AnimateRunner","$$jqLite",function(b,c,d){function e(c){c=U(c)?c:c.split(" ");for(var d=[],e={},f=0;f<c.length;f++){var g=c[f],h=a.$$registeredAnimations[g];h&&!e[g]&&(d.push(b.get(h)),e[g]=!0)}return d}var f=l(d);return function(a,b,d,g){function h(){g.domOperation(),f(a,g)}function i(){o=!0,h(),n(a,g)}function j(a,b,d,e,f){var g;switch(d){case"animate":g=[b,e.from,e.to,f];break;case"setClass":g=[b,r,s,f];break;case"addClass":g=[b,r,f];break;case"removeClass":g=[b,s,f];break;default:g=[b,f]}g.push(e);var h=a.apply(a,g);if(h)if(X(h.start)&&(h=h.start()),h instanceof c)h.done(f);else if(X(h))return h;return aa}function k(a,b,d,e,f){var g=[];return T(e,function(e){var h=e[f];h&&g.push(function(){var e,f,g=!1,i=function(a){g||(g=!0,(f||aa)(a),e.complete(!a))};return e=new c({end:function(){i()},cancel:function(){i(!0)}}),f=j(h,a,b,d,function(a){i(!1===a)}),e})}),g}function l(a,b,d,e,f){var g=k(a,b,d,e,f);if(0===g.length){var h,i;"beforeSetClass"===f?(h=k(a,"removeClass",d,e,"beforeRemoveClass"),i=k(a,"addClass",d,e,"beforeAddClass")):"setClass"===f&&(h=k(a,"removeClass",d,e,"removeClass"),i=k(a,"addClass",d,e,"addClass")),h&&(g=g.concat(h)),i&&(g=g.concat(i))}if(0!==g.length)return function(a){var b=[];return g.length&&T(g,function(a){b.push(a())}),b.length?c.all(b,a):a(),function(a){T(b,function(b){a?b.cancel():b.end()})}}}var o=!1;3===arguments.length&&Y(d)&&(g=d,d=null),g=m(g),d||(d=a.attr("class")||"",g.addClass&&(d+=" "+g.addClass),g.removeClass&&(d+=" "+g.removeClass));var p,q,r=g.addClass,s=g.removeClass,t=e(d);if(t.length){var u,v;"leave"===b?(v="leave",u="afterLeave"):(v="before"+b.charAt(0).toUpperCase()+b.substr(1),u=b),"enter"!==b&&"move"!==b&&(p=l(a,b,g,t,v)),q=l(a,b,g,t,u)}if(p||q){var w;return{$$willAnimate:!0,end:function(){return w?w.end():(i(),w=new c,w.complete(!0)),w},start:function(){function a(a){i(a),w.complete(a)}function b(b){o||((d||aa)(b),a(b))}if(w)return w;w=new c;var d,e=[];return p&&e.push(function(a){d=p(a)}),e.length?e.push(function(a){h(),a(!0)}):h(),q&&e.push(function(a){d=q(a)}),w.setHost({end:function(){b()},cancel:function(){b(!0)}}),c.chain(e,a),w}}}}}]}],ua=["$$animationProvider",function(a){a.drivers.push("$$animateJsDriver"),this.$get=["$$animateJs","$$AnimateRunner",function(a,b){function c(b){var c=b.element,d=b.event,e=b.options,f=b.classes;return a(c,d,f,e)}return function(a){if(a.from&&a.to){var d=c(a.from),e=c(a.to);if(!d&&!e)return;return{start:function(){function a(){return function(){T(f,function(a){a.end()})}}function c(a){g.complete(a)}var f=[];d&&f.push(d.start()),e&&f.push(e.start()),b.all(f,c);var g=new b({end:a(),cancel:a()});return g}}}return c(a)}}]}],va="data-ng-animate",wa="$ngAnimatePin",xa=["$animateProvider",function(b){function d(a){if(!a)return null;var b=a.split(o),c=Object.create(null);return T(b,function(a){c[a]=!0}),c}function e(a,b){if(a&&b){var c=d(b);return a.split(o).some(function(a){return c[a]})}}function f(a,b,c){return p[a].some(function(a){return a(b,c)})}function g(a,b){var c=(a.addClass||"").length>0,d=(a.removeClass||"").length>0;return b?c&&d:c||d}var j=1,k=2,o=" ",p=this.rules={skip:[],cancel:[],join:[]};p.join.push(function(a,b){return!a.structural&&g(a)}),p.skip.push(function(a,b){return!a.structural&&!g(a)}),p.skip.push(function(a,b){return"leave"===b.event&&a.structural}),p.skip.push(function(a,b){return b.structural&&b.state===k&&!a.structural}),p.cancel.push(function(a,b){return b.structural&&a.structural}),p.cancel.push(function(a,b){return b.state===k&&a.structural}),p.cancel.push(function(a,b){if(b.structural)return!1;var c=a.addClass,d=a.removeClass,f=b.addClass,g=b.removeClass;return!($(c)&&$(d)||$(f)&&$(g))&&(e(c,g)||e(d,f))}),this.$get=["$$rAF","$rootScope","$rootElement","$document","$$Map","$$animation","$$AnimateRunner","$templateRequest","$$jqLite","$$forceReflow","$$isDocumentHidden",function(d,e,o,p,r,v,w,x,y,z,A){function B(){var a=!1;return function(b){a?b():e.$$postDigest(function(){a=!0,b()})}}function C(a,b){return q(a,b,{})}function D(a,b,c){var d=[],e=X[c];return e&&T(e,function(e){ga.call(e.node,b)?d.push(e.callback):"leave"===c&&ga.call(e.node,a)&&d.push(e.callback)}),d}function E(a,b,c){var d=i(b);return a.filter(function(a){return!(a.node===d&&(!c||a.callback===c))})}function F(a,b){"close"!==a||b.parentNode||ha.off(b)}function G(a,b,c){function i(a,b,c,e){z(function(){var a=D(x,r,b);a.length?d(function(){T(a,function(a){a(p,c,e)}),F(c,r)}):F(c,r)}),a.progress(b,c,e)}function l(a){u(p,o),fa(p,o),n(p,o),o.domOperation(),y.complete(!a)}var o=R(c),p=h(a),r=s(p),x=r&&r.parentNode;o=m(o);var y=new w,z=B();if(U(o.addClass)&&(o.addClass=o.addClass.join(" ")),o.addClass&&!Z(o.addClass)&&(o.addClass=null),U(o.removeClass)&&(o.removeClass=o.removeClass.join(" ")),o.removeClass&&!Z(o.removeClass)&&(o.removeClass=null),o.from&&!Y(o.from)&&(o.from=null),o.to&&!Y(o.to)&&(o.to=null),!(O&&r&&da(r,b,c)&&ea(r,o)))return l(),y;var E=["enter","move","leave"].indexOf(b)>=0,G=A(),L=G||N.get(r),P=!L&&M.get(r)||{},Q=!!P.state;if(L||Q&&P.state===j||(L=!J(r,x,b)),L)return G&&i(y,b,"start"),l(),G&&i(y,b,"close"),y;E&&H(r);var S={structural:E,element:p,event:b,addClass:o.addClass,removeClass:o.removeClass,close:l,options:o,runner:y};if(Q){if(f("skip",S,P))return P.state===k?(l(),y):(q(p,P,S),P.runner);if(f("cancel",S,P))if(P.state===k)P.runner.end();else{if(!P.structural)return q(p,P,S),P.runner;P.close()}else{if(f("join",S,P)){if(P.state!==k)return t(p,E?b:null,o),b=S.event=P.event,o=q(p,P,S),P.runner;C(p,S)}}}else C(p,S);var V=S.structural;if(V||(V="animate"===S.event&&Object.keys(S.options.to||{}).length>0||g(S)),!V)return l(),I(r),y;var W=(P.counter||0)+1;return S.counter=W,K(r,j,S),e.$$postDigest(function(){p=h(a);var c=M.get(r),d=!c;c=c||{};var e=p.parent()||[],f=e.length>0&&("animate"===c.event||c.structural||g(c));if(d||c.counter!==W||!f)return d&&(fa(p,o),n(p,o)),(d||E&&c.event!==b)&&(o.domOperation(),y.end()),void(f||I(r));b=!c.structural&&g(c,!0)?"setClass":c.event,K(r,k);var j=v(p,b,c.options);y.setHost(j),i(y,b,"start",{}),j.done(function(a){l(!a);var c=M.get(r);c&&c.counter===W&&I(r),i(y,b,"close",{})})}),y}function H(a){var b=a.querySelectorAll("["+va+"]");T(b,function(a){var b=parseInt(a.getAttribute(va),10),c=M.get(a);if(c)switch(b){case k:c.runner.end();case j:M.delete(a)}})}function I(a){a.removeAttribute(va),M.delete(a)}function J(a,b,c){var d,e=p[0].body,f=s(o),g=a===e||"HTML"===a.nodeName,h=a===f,i=!1,j=N.get(a),k=_.data(a,wa);for(k&&(b=s(k));b&&(h||(h=b===f),b.nodeType===L);){var l=M.get(b)||{};if(!i){var m=N.get(b);if(!0===m&&!1!==j){j=!0;break}!1===m&&(j=!1),i=l.structural}if($(d)||!0===d){var n=_.data(b,Q);V(n)&&(d=n)}if(i&&!1===d)break;if(g||(g=b===e),g&&h)break;b=h||!(k=_.data(b,wa))?b.parentNode:s(k)}return(!i||d)&&!0!==j&&h&&g}function K(a,b,c){c=c||{},c.state=b,a.setAttribute(va,b);var d=M.get(a),e=d?S(d,c):c;M.set(a,e)}var M=new r,N=new r,O=null,P=e.$watch(function(){return 0===x.totalPendingRequests},function(a){a&&(P(),e.$$postDigest(function(){e.$$postDigest(function(){null===O&&(O=!0)})}))}),X=Object.create(null),aa=b.customFilter(),ba=b.classNameFilter(),ca=function(){return!0},da=aa||ca,ea=ba?function(a,b){var c=[a.getAttribute("class"),b.addClass,b.removeClass].join(" ");return ba.test(c)}:ca,fa=l(y),ga=a.Node.prototype.contains||function(a){return this===a||!!(16&this.compareDocumentPosition(a))},ha={on:function(a,b,c){var d=i(b);X[a]=X[a]||[],X[a].push({node:d,callback:c}),_(b).on("$destroy",function(){M.get(d)||ha.off(a,b,c)})},off:function(a,b,c){if(1!==arguments.length||Z(arguments[0])){var d=X[a];d&&(X[a]=1===arguments.length?null:E(d,b,c))}else{b=arguments[0];for(var e in X)X[e]=E(X[e],b)}},pin:function(a,b){c(W(a),"element","not an element"),c(W(b),"parentElement","not an element"),a.data(wa,b)},push:function(a,b,c,d){return c=c||{},c.domOperation=d,G(a,b,c)},enabled:function(a,b){var c=arguments.length;if(0===c)b=!!O;else{if(W(a)){var d=s(a);1===c?b=!N.get(d):N.set(d,!b)}else b=O=!!a}return b}};return ha}]}],ya=["$animateProvider",function(a){function b(a,b){a.data(h,b)}function c(a){a.removeData(h)}function e(a){return a.data(h)}var f="ng-animate-ref",g=this.drivers=[],h="$$animationRunner";this.$get=["$$jqLite","$rootScope","$injector","$$AnimateRunner","$$Map","$$rAFScheduler",function(a,h,i,j,k,o){function p(a){function b(a){if(a.processed)return a;a.processed=!0;var c=a.domNode,f=c.parentNode;e.set(c,a);for(var g;f;){if(g=e.get(f)){g.processed||(g=b(g));break}f=f.parentNode}return(g||d).children.push(a),a}var c,d={children:[]},e=new k;for(c=0;c<a.length;c++){var f=a[c];e.set(f.domNode,a[c]={domNode:f.domNode,fn:f.fn,children:[]})}for(c=0;c<a.length;c++)b(a[c]);return function(a){var b,c=[],d=[];for(b=0;b<a.children.length;b++)d.push(a.children[b]);var e=d.length,f=0,g=[];for(b=0;b<d.length;b++){var h=d[b];e<=0&&(e=f,f=0,c.push(g),g=[]),g.push(h.fn),h.children.forEach(function(a){f++,d.push(a)}),e--}return g.length&&c.push(g),c}(d)}var q=[],r=l(a);return function(k,l,t){function u(a){var b="["+f+"]",c=a.hasAttribute(f)?[a]:a.querySelectorAll(b),d=[];return T(c,function(a){var b=a.getAttribute(f);b&&b.length&&d.push(a)}),d}function v(a){var b=[],c={};T(a,function(a,d){var e=a.element,g=s(e),h=a.event,i=["enter","move"].indexOf(h)>=0,j=a.structural?u(g):[];if(j.length){var k=i?"to":"from";T(j,function(a){var b=a.getAttribute(f);c[b]=c[b]||{},c[b][k]={animationID:d,element:_(a)}})}else b.push(a)});var d={},e={};return T(c,function(c,f){var g=c.from,h=c.to;if(!g||!h){var i=g?g.animationID:h.animationID,j=i.toString();return void(d[j]||(d[j]=!0,b.push(a[i])))}var k=a[g.animationID],l=a[h.animationID],m=g.animationID.toString();if(!e[m]){var n=e[m]={structural:!0,beforeStart:function(){k.beforeStart(),l.beforeStart()},close:function(){k.close(),l.close()},classes:w(k.classes,l.classes),from:k,to:l,anchors:[]};n.classes.length?b.push(n):(b.push(k),b.push(l))}e[m].anchors.push({out:g.element,in:h.element})}),b}function w(a,b){a=a.split(" "),b=b.split(" ");for(var c=[],d=0;d<a.length;d++){var e=a[d];if("ng-"!==e.substring(0,3))for(var f=0;f<b.length;f++)if(e===b[f]){c.push(e);break}}return c.join(" ")}function x(a){for(var b=g.length-1;b>=0;b--){var c=g[b],d=i.get(c),e=d(a);if(e)return e}}function y(){k.addClass(P),F&&a.addClass(k,F),G&&(a.removeClass(k,G),G=null)}function z(a,b){function c(a){var c=e(a);c&&c.setHost(b)}a.from&&a.to?(c(a.from.element),c(a.to.element)):c(a.element)}function A(){var a=e(k);!a||"leave"===l&&t.$$domOperationFired||a.end()}function B(b){k.off("$destroy",A),c(k),r(k,t),n(k,t),t.domOperation(),F&&a.removeClass(k,F),k.removeClass(P),D.complete(!b)}t=m(t);var C=["enter","move","leave"].indexOf(l)>=0,D=new j({end:function(){B()},cancel:function(){B(!0)}});if(!g.length)return B(),D;b(k,D);var E=d(k.attr("class"),d(t.addClass,t.removeClass)),F=t.tempClasses;F&&(E+=" "+F,t.tempClasses=null);var G;return C&&(G="ng-"+l+"-prepare",a.addClass(k,G)),q.push({element:k,classes:E,event:l,structural:C,options:t,beforeStart:y,close:B}),k.on("$destroy",A),q.length>1?D:(h.$$postDigest(function(){var a=[];T(q,function(b){e(b.element)?a.push(b):b.close()}),q.length=0;var b=v(a),c=[];T(b,function(a){c.push({domNode:s(a.from?a.from.element:a.element),fn:function(){a.beforeStart();var b,c=a.close;if(e(a.anchors?a.from.element||a.to.element:a.element)){var d=x(a);d&&(b=d.start)}if(b){var f=b();f.done(function(a){c(!a)}),z(a,f)}else c()}})}),o(p(c))}),D)}}]}],za=["$animate","$rootScope",function(a,b){return{restrict:"A",transclude:"element",terminal:!0,priority:600,link:function(b,c,d,e,f){var g,h;b.$watchCollection(d.ngAnimateSwap||d.for,function(d){g&&a.leave(g),h&&(h.$destroy(),h=null),(d||0===d)&&(h=b.$new(),f(h,function(b){g=b,a.enter(b,null,c)}))})}}}];b.module("ngAnimate",[],function(){aa=b.noop,R=b.copy,S=b.extend,_=b.element,T=b.forEach,U=b.isArray,Z=b.isString,Y=b.isObject,$=b.isUndefined,V=b.isDefined,X=b.isFunction,W=b.isElement}).info({angularVersion:"1.6.6"}).directive("ngAnimateSwap",za).directive("ngAnimateChildren",ka).factory("$$rAFScheduler",ja).provider("$$animateQueue",xa).provider("$$animation",ya).provider("$animateCss",ra).provider("$$animateCssDriver",sa).provider("$$animateJs",ta).provider("$$animateJsDriver",ua)}(window,window.angular),function(a,b){"use strict";function c(){function c(a,b){var c,d={},e=a.split(",");for(c=0;c<e.length;c++)d[b?i(e[c]):e[c]]=!0;return d}function d(a,b){null===a||void 0===a?a="":"string"!=typeof a&&(a=""+a);var c=J(a);if(!c)return"";var d=5;do{if(0===d)throw n("uinput","Failed to sanitize html because the input is unstable");d--,a=c.innerHTML,c=J(a)}while(a!==c.innerHTML);for(var e=c.firstChild;e;){switch(e.nodeType){case 1:b.start(e.nodeName.toLowerCase(),o(e.attributes));break;case 3:b.chars(e.textContent)}var f;if(!((f=e.firstChild)||(1===e.nodeType&&b.end(e.nodeName.toLowerCase()),f=s("nextSibling",e))))for(;null==f&&(e=s("parentNode",e))!==c;)f=s("nextSibling",e),1===e.nodeType&&b.end(e.nodeName.toLowerCase());e=f}for(;e=c.firstChild;)c.removeChild(e)}function o(a){for(var b={},c=0,d=a.length;c<d;c++){var e=a[c];b[e.name]=e.value}return b}function p(a){return a.replace(/&/g,"&").replace(u,function(a){return"&#"+(1024*(a.charCodeAt(0)-55296)+(a.charCodeAt(1)-56320)+65536)+";"}).replace(v,function(a){return"&#"+a.charCodeAt(0)+";"}).replace(/</g,"<").replace(/>/g,">")}function q(a,b){var c=!1,d=e(a,a.push);return{start:function(a,e){a=i(a),!c&&D[a]&&(c=a),c||!0!==E[a]||(d("<"),d(a),g(e,function(c,e){var f=i(e),g="img"===a&&"src"===f||"background"===f;!0!==I[f]||!0===F[f]&&!b(c,g)||(d(" "),d(e),d('="'),d(p(c)),d('"'))}),d(">"))},end:function(a){a=i(a),c||!0!==E[a]||!0===w[a]||(d("</"),d(a),d(">")),a==c&&(c=!1)},chars:function(a){c||d(p(a))}}}function r(b){for(;b;){if(b.nodeType===a.Node.ELEMENT_NODE)for(var c=b.attributes,d=0,e=c.length;d<e;d++){var f=c[d],g=f.name.toLowerCase();"xmlns:ns1"!==g&&0!==g.lastIndexOf("ns1:",0)||(b.removeAttributeNode(f),d--,e--)}var h=b.firstChild;h&&r(h),b=s("nextSibling",b)}}function s(a,b){var c=b[a];if(c&&k.call(b,c))throw n("elclob","Failed to sanitize html because the element is clobbered: {0}",b.outerHTML||b.outerText);return c}var t=!1;this.$get=["$$sanitizeUri",function(a){return t&&f(E,C),function(b){var c=[];return l(b,m(c,function(b,c){return!/^unsafe:/.test(a(b,c))})),c.join("")}}],this.enableSvg=function(a){return h(a)?(t=a,this):t},e=b.bind,f=b.extend,g=b.forEach,h=b.isDefined,i=b.lowercase,j=b.noop,l=d,m=q,k=a.Node.prototype.contains||function(a){return!!(16&this.compareDocumentPosition(a))};var u=/[\uD800-\uDBFF][\uDC00-\uDFFF]/g,v=/([^#-~ |!])/g,w=c("area,br,col,hr,img,wbr"),x=c("colgroup,dd,dt,li,p,tbody,td,tfoot,th,thead,tr"),y=c("rp,rt"),z=f({},y,x),A=f({},x,c("address,article,aside,blockquote,caption,center,del,dir,div,dl,figure,figcaption,footer,h1,h2,h3,h4,h5,h6,header,hgroup,hr,ins,map,menu,nav,ol,pre,section,table,ul")),B=f({},y,c("a,abbr,acronym,b,bdi,bdo,big,br,cite,code,del,dfn,em,font,i,img,ins,kbd,label,map,mark,q,ruby,rp,rt,s,samp,small,span,strike,strong,sub,sup,time,tt,u,var")),C=c("circle,defs,desc,ellipse,font-face,font-face-name,font-face-src,g,glyph,hkern,image,linearGradient,line,marker,metadata,missing-glyph,mpath,path,polygon,polyline,radialGradient,rect,stop,svg,switch,text,title,tspan"),D=c("script,style"),E=f({},w,A,B,z),F=c("background,cite,href,longdesc,src,xlink:href"),G=c("abbr,align,alt,axis,bgcolor,border,cellpadding,cellspacing,class,clear,color,cols,colspan,compact,coords,dir,face,headers,height,hreflang,hspace,ismap,lang,language,nohref,nowrap,rel,rev,rows,rowspan,rules,scope,scrolling,shape,size,span,start,summary,tabindex,target,title,type,valign,value,vspace,width"),H=c("accent-height,accumulate,additive,alphabetic,arabic-form,ascent,baseProfile,bbox,begin,by,calcMode,cap-height,class,color,color-rendering,content,cx,cy,d,dx,dy,descent,display,dur,end,fill,fill-rule,font-family,font-size,font-stretch,font-style,font-variant,font-weight,from,fx,fy,g1,g2,glyph-name,gradientUnits,hanging,height,horiz-adv-x,horiz-origin-x,ideographic,k,keyPoints,keySplines,keyTimes,lang,marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,mathematical,max,min,offset,opacity,orient,origin,overline-position,overline-thickness,panose-1,path,pathLength,points,preserveAspectRatio,r,refX,refY,repeatCount,repeatDur,requiredExtensions,requiredFeatures,restart,rotate,rx,ry,slope,stemh,stemv,stop-color,stop-opacity,strikethrough-position,strikethrough-thickness,stroke,stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,stroke-miterlimit,stroke-opacity,stroke-width,systemLanguage,target,text-anchor,to,transform,type,u1,u2,underline-position,underline-thickness,unicode,unicode-range,units-per-em,values,version,viewBox,visibility,width,widths,x,x-height,x1,x2,xlink:actuate,xlink:arcrole,xlink:role,xlink:show,xlink:title,xlink:type,xml:base,xml:lang,xml:space,xmlns,xmlns:xlink,y,y1,y2,zoomAndPan",!0),I=f({},F,H,G),J=function(a,b){function c(b){b="<remove></remove>"+b;try{b=encodeURI(b)}catch(a){return}var c=new a.XMLHttpRequest;c.responseType="document",c.open("GET","data:text/html;charset=utf-8,"+b,!1),c.send(null);var d=c.response.body;return d.firstChild.remove(),d}function d(b){b="<remove></remove>"+b;try{var c=(new a.DOMParser).parseFromString(b,"text/html").body;return c.firstChild.remove(),c}catch(a){return}}function e(a){return g.innerHTML=a,b.documentMode&&r(g),g}var f;if(!b||!b.implementation)throw n("noinert","Can't create an inert html document");f=b.implementation.createHTMLDocument("inert");var g=(f.documentElement||f.getDocumentElement()).querySelector("body");return g.innerHTML='<svg><g onload="this.parentNode.remove()"></g></svg>',g.querySelector("svg")?(g.innerHTML='<svg><p><style><img src="</style><img src=x onerror=alert(1)//">',g.querySelector("svg img")?d:e):c}(a,a.document)}function d(a){var b=[];return m(b,j).chars(a),b.join("")}var e,f,g,h,i,j,k,l,m,n=b.$$minErr("$sanitize");b.module("ngSanitize",[]).provider("$sanitize",c).info({angularVersion:"1.6.6"}),b.module("ngSanitize").filter("linky",["$sanitize",function(a){var c=/((ftp|https?):\/\/|(www\.)|(mailto:)?[A-Za-z0-9._%+-]+@)\S*[^\s.;,(){}<>"\u201d\u2019]/i,e=/^mailto:/i,f=b.$$minErr("linky"),g=b.isDefined,h=b.isFunction,i=b.isObject,j=b.isString;return function(b,k,l){function m(a){a&&s.push(d(a))}if(null==b||""===b)return b;if(!j(b))throw f("notstring","Expected string but received: {0}",b);for(var n,o,p,q=h(l)?l:i(l)?function(){return l}:function(){return{}},r=b,s=[];n=r.match(c);)o=n[0],n[2]||n[4]||(o=(n[3]?"http://":"mailto:")+o),p=n.index,m(r.substr(0,p)),function(a,b){var c,d=q(a);s.push("<a ");for(c in d)s.push(c+'="'+d[c]+'" ');!g(k)||"target"in d||s.push('target="',k,'" '),s.push('href="',a.replace(/"/g,"""),'">'),m(b),s.push("</a>")}(o,n[0].replace(e,"")),r=r.substring(p+n[0].length);return m(r),a(s.join(""))}}])}(window,window.angular),function(){function a(){return{restrict:"AEC",require:"dxStartWith",controller:"dxStartWithCtrl",scope:!0,terminal:!0,transclude:!0,multiElement:!0,$$tlb:!0,compile:function(a,b){var c=b.dxStartWith||b.root,e=c.match(d),f=e[1],g=e[3]||"";return function(a,b,c,d,e){d.alias=g,d.transclude=e,d.transclude(a,function(a,c){function d(a){c.$dxPrior=a,""!==g&&(c[g]=a)}b.append(a),c.$dxLevel=0,c.$dxIsRoot=!0,c.$watch(f,d)})}}}}function b(){return{restrict:"AEC",require:"^dxStartWith",scope:!0,terminal:!0,multiElement:!0,compile:function(a,b){var c=b.dxConnect||b.connect;return function(a,b,d,e){alias=e.alias||"",e.transclude(a,function(a,d){function e(a){d.$dxPrior=a,""!==alias&&(d[alias]=a)}b.append(a),d.$dxLevel=d.$dxLevel+1,d.$dxIsRoot=!1,d.$watch(c,e)})}}}}var c=angular.module("dotjem.angular.tree",[]),d=/^(\S+)(\s+as\s+(\w+))?$/;c.controller("dxStartWithCtrl",[function(){}]),c.directive("dxStartWith",a),c.directive("dxConnect",b)}(),function(){"use strict";function a(a,b,c){return{restrict:"A",link:function(d,e,f){c(function(){function g(a){var g,h,k,l,m,n;if(!angular.element(e).hasClass("ng-hide")&&a&&a.target){for(h=a.target;h;h=h.parentNode){if(h===e[0])return;if(l=h.id,m=h.className,n=j.length,m&&void 0!==m.baseVal&&(m=m.baseVal),m||l)for(g=0;g<n;g++)if(k=new RegExp("\\b"+j[g]+"\\b"),void 0!==l&&l===j[g]||m&&k.test(m))return}c(function(){(i=b(f.clickOutside))(d,{event:a})})}}function h(){return"ontouchstart"in window||navigator.maxTouchPoints}var i,j=void 0!==f.outsideIfNot?f.outsideIfNot.split(/[ ,]+/):[];h()&&a.on("touchstart",g),a.on("click",g),d.$on("$destroy",function(){h()&&a.off("touchstart",g),a.off("click",g)})})}}}angular.module("angular-click-outside",[]).directive("clickOutside",["$document","$parse","$timeout",a])}();var GoogleMerchants=angular.module("GoogleMerchants",["templates-dist","dotjem.angular.tree","ngSanitize","ngAnimate","ng-slide-down","angular-click-outside"]);GoogleMerchants.constant("BACKEND",ajaxurl+"?action=wpae_api&q="),GoogleMerchants.filter("safe",["$sce",function(a){return a.trustAsHtml}]),GoogleMerchants.controller("advancedAttributesController",["$scope","$log","attributesService",function(a,b,c){a.attributes=[],a.cats=[],a.attributes=c.getAttributes()}]),GoogleMerchants.directive("advancedAttributes",function(){return{restrict:"E",scope:{advancedAttributes:"=information"},templateUrl:"advancedAttributes/advancedAttributes.tpl.html",controller:"advancedAttributesController"}}),GoogleMerchants.controller("availabilityPriceController",["$scope","currencyService",function(a,b){a.currency=b.getCurrency()}]),GoogleMerchants.directive("availabilityPrice",function(){return{restrict:"E",scope:{availabilityPrice:"=information"},templateUrl:"availabilityPrice/availabilityPrice.tpl.html",controller:"availabilityPriceController"}}),GoogleMerchants.controller("basicInformationController",["$scope",function(a){}]),GoogleMerchants.directive("basicInformation",function(){return{restrict:"E",scope:{basicInformation:"=information"},templateUrl:"basicInformation/basicInformation.tpl.html",controller:"basicInformationController"}}),GoogleMerchants.directive("chosen",["$timeout",chosen]),GoogleMerchants.factory("attributesService",["$rootScope","$q","$log","wpHttp",function(a,b,c,d){var e=!1;return{setAttributes:function(a){e=a},getAttributes:function(){return e}}}]),GoogleMerchants.directive("autodetect",["attributesService",function(a){return{restrict:"A",require:"^ngModel",link:{post:function(b,c,d,e){var f=d.autodetect;d=a.getAttributes(),angular.forEach(d,function(a){a.label.toLowerCase()!=f.toLowerCase()&&a.name.toLowerCase()!=f.toLowerCase()||(e.$setViewValue("{"+a.name+"}"),e.$render())})}}}}]),GoogleMerchants.directive("cascade",[function(){return{restrict:"A",controller:["$scope",function(a){function b(c,d){var e,f;for(e=0;e<d.children.length;e+=1)f=d.children[e],a.mappings[f.id]=c,b(c,f);return!1}a.select=function(){console.log("Changing to ",a.mappings[a.node.id]),b(a.mappings[a.node.id],a.node)}}]}}]),GoogleMerchants.directive("contenteditable",["$sce",function(a){return{restrict:"A",require:"?ngModel",link:function(b,c,d,e){function f(){var a=c.html();d.stripBr&&"<br>"===a&&(a=""),e.$setViewValue(a)}e&&(e.$render=function(){c.html(a.getTrustedHtml(e.$viewValue||""))},c.on("blur keyup change",function(){b.$evalAsync(f)}),f())}}}]),GoogleMerchants.factory("currencyService",[function(){var a=null,b=null;return{setCurrency:function(c,d){a=c,b=d},getCurrency:function(){return a},getCurrencyCode:function(){return b}}}]),GoogleMerchants.directive("droppable",[function(){return{restrict:"A",require:"^ngModel",link:function(a,b,c,d){function e(a,b){return-1!==a.find("input[name^=cc_type]").val().indexOf("image_")&&(b="Image "+b),-1!==a.find("input[name^=cc_type]").val().indexOf("attachment_")&&(b="Attachment "+b),b}var f;f=angular.element(b),f.addClass("google-merchants-droppable"),f.droppable({drop:function(a,b){var c=b.draggable.find(".custom_column"),g=c.find("input[name^=cc_name]").val();g=e(c,g),f.val(f.val()+"{"+g+"}"),d.$setViewValue(f.val()),d.$render()}})}}}]),GoogleMerchants.factory("exportService",["$q","$log","wpHttp",function(a,b,c){return{getExport:function(d){var e=a.defer(),f="export/get";return null!==d&&(f=f+"&id="+d),c.get(f).then(function(a){e.resolve(a)},function(a,c){e.reject(a,c),b.error("There was a problem getting the export")}),e.promise},saveExport:function(d){var e=a.defer();return c.post("export/save",d).then(function(a){e.resolve(a)},function(a,c){e.reject(a),b.error(a,c)}),e.promise}}}]),GoogleMerchants.directive("focusMeWhenEnabled",function(a){return{priority:-1,link:function(b,c){b.$watch(function(){return b.$eval(c.attr("ng-disabled"))},function(b){0==b&&a(function(){c[0].focus()})})}}}),GoogleMerchants.factory("googleCategoriesService",["$rootScope","$q","$log","wpHttp",function(a,b,c,d){return{searchCategories:function(a){return d.get("googleCategories/get&parent=0"+a)},getChildCategories:function(a){return d.get("googleCategories/get&parent="+a)},categorySelected:function(b){a.$broadcast("wpae.category.selected",b)}}}]),GoogleMerchants.controller("mainController",["$scope","$rootScope","$timeout","$window","$document","$location","$log","templateService","exportService","currencyService","attributesService","wpHttp",function(a,b,c,d,e,f,g,h,i,j,k,l){function m(a,b){b||(b=window.location.href),a=a.replace(/[\[\]]/g,"\\$&");var c=new RegExp("[?&]"+a+"(=([^&#]*)|&|#|$)"),d=c.exec(b);return d?d[2]?decodeURIComponent(d[2].replace(/\+/g," ")):"":null}function n(){b.cats.children.length||(a.merchantsFeedData.productCategories.productCategories="customValue")}var o=[{mapFrom:"",mapTo:""}];a.cats=[],a.templateId=!1,a.merchantsFeedData={basicInformation:{open:!0,itemTitle:"productTitle",hasVariations:!0,useParentTitleForVariableProducts:!0,additionalImageLink:"productImages",itemDescription:"productDescription",itemImageLink:"useProductFeaturedImage",itemLink:"productLink",condition:"new",conditionMappings:angular.copy(o),userVariationDescriptionForVariableProducts:!0,addVariationAttributesToProductUrl:!0,useVariationImage:!0,useFeaturedImageIfThereIsNoVariationImage:!0,useParentDescirptionIfThereIsNoVariationDescirption:!0,useVariationDescriptionForVariableProducts:!0},detailedInformation:{open:!1,color:"selectFromWooCommerceProductAttributes",size:"selectFromWooCommerceProductAttributes",gender:"selectFromWooCommerceProductAttributes",setTheGroupId:"automatically",mappings:angular.copy(o),ageGroup:"selectFromWooCommerceProductAttributes",material:"selectFromWooCommerceProductAttributes",pattern:"selectFromWooCommerceProductAttributes",genderAutodetect:"keepBlank",sizeSystem:"",adjustPrice:!1,adjustSalePrice:!1,genderCats:{},ageGroupCats:{},sizeTypeMappings:angular.copy(o)},availabilityPrice:{open:!1,price:"useProductPrice",salePrice:"useProductSalePrice",availability:"useWooCommerceStockValues",adjustPriceValue:"",adjustPriceType:"%",adjustSalePriceType:"%",adjustSalePriceValue:"",currency:null},productCategories:{open:!1,productType:"useWooCommerceProductCategories",productCategories:"mapProductCategories",catMappings:{}},uniqueIdentifiers:{open:!1,identifierExists:1},shipping:{dimensions:"useWooCommerceProductValues",convertTo:"cm",adjustPriceType:"%",weight:"",shippingHeight:"",shippingLength:"",shippingWidth:""},template:{save:!1,name:""},advancedAttributes:{adult:"no",unitPricingBaseMeasureUnit:"kg",excludedDestination:"no",customLabel0Mappings:angular.copy(o),customLabel1Mappings:angular.copy(o),customLabel2Mappings:angular.copy(o),customLabel3Mappings:angular.copy(o),customLabel4Mappings:angular.copy(o),energyEfficiencyClassMappings:angular.copy(o),promotionIdMappings:angular.copy(o)}},a.init=function(b,c,d){k.setAttributes(wpae_product_attributes),a.isGoogleMerchantExport=!1,j.setCurrency(b,c),a.templateId=d},a.selectGoogleMerchantsInitially=function(){a.selectGoogleMerchants()},a.selectGoogleMerchants=function(){jQuery(".wpallexport-element-label").parent().parent().slideUp(),a.isGoogleMerchantExport=!0;var c=m("id");i.getExport(c).then(function(b){angular.isObject(b)&&(b.template={save:!1,name:""},a.merchantsFeedData=b)}),a.templateId&&(console.log("Loading template with id "+a.templateId),h.getTemplate(a.templateId).then(function(b){a.merchantsFeedData=b.google_merchants_post_data})),l.get("categories/index").then(function(a){b.cats=a,console.log("Broadcasting loaded categories..."),b.$broadcast("categories.loaded"),n()},function(){g.error("There was a problem loading the WordPress categories")}),null==a.merchantsFeedData.availabilityPrice.currency&&(a.merchantsFeedData.availabilityPrice.currency=j.getCurrencyCode())},a.$on("googleMerchantsSelected",function(b,d){a.selectGoogleMerchants(),a.merchantsFeedData.basicInformation.hasVariations=d,jQuery(".wpallexport-element-label").parent().parent().slideUp(),c(function(){a.isGoogleMerchantExport=!0})}),a.$on("googleMerchantsDeselected",function(){jQuery(".wpallexport-element-label").parent().parent().slideDown(),c(function(){a.isGoogleMerchantExport=!1})}),a.$on("googleMerchantsSubmitted",function(b,c){a.merchantsFeedData.template.name=c.templateName,a.process()}),a.$on("templateShouldBeSaved",function(b,c){a.merchantsFeedData.template.save=!0,a.merchantsFeedData.template.name=c}),a.$on("templateShouldNotBeSaved",function(){a.merchantsFeedData.template.save=!1}),a.$on("selectedTemplate",function(b,c){h.getTemplate(c).then(function(b){a.merchantsFeedData=b.google_merchants_post_data})}),a.process=function(){a.merchantsFeedData.extraData=jQuery("#templateForm").serialize(),a.merchantsFeedData.filteringData=jQuery("input[name=filter_rules_hierarhy]").val(),a.merchantsFeedData.template.save=jQuery("#save_template_as").prop("checked");var b=m("id");b&&(a.merchantsFeedData.exportId=b,a.merchantsFeedData.update=!0),i.saveExport(a.merchantsFeedData).then(function(a){a.redirect?d.location.href=a.redirect:d.location.href="admin.php?page=pmxe-admin-export&action=options"})}}]),GoogleMerchants.controller("mappingController",["$scope",function(a){a.show=!1,a.mappingsBackup=null,a.removeMapping=function(b){a.mappings.length>1&&a.mappings.splice(a.mappings.indexOf(b),1)},a.$watch("show",function(b){b&&(a.mappingsBackup=a.mappings)}),a.addMapping=function(){a.mappings.push({})},a.close=function(){a.mappings=a.mappingsBackup,a.show=!1},a.saveMappings=function(){a.show=!1}}]),GoogleMerchants.directive("mapping",function(){return{restrict:"E",scope:{mappings:"=",show:"=",context:"=",tooltip:"@"},templateUrl:"common/mapping/mapping.tpl.html",controller:"mappingController"}}),GoogleMerchants.directive("styledInput",function(a){return{priority:-1,scope:{placeholder:"=",ngModel:"="},template:'<div class="editable" contenteditable="true" ng-model="ngModel" placeholder="{{placeholder}}"></div>',link:function(a,b){b.bind("keydown",function(a){return(!a.ctrlKey&&!a.metaKey||65==a.which||88==a.which||67==a.which||86==a.which)&&(13!=a.which&&void 0)})}}}),GoogleMerchants.factory("templateService",["$q","$log","wpHttp",function(a,b,c){return{getTemplate:function(d){var e=a.defer();return c.get("templates/get&templateId="+d).then(function(a){e.resolve(a)},function(a,c){e.reject(a,c),b.error("There was a problem getting the export")}),e.promise}}}]),
|
8 |
+
GoogleMerchants.directive("tipsy",["$document",function(a){return{restrict:"A",link:function(b,c,d){c.attr("original-title",d.tipsy),c.tipsy({gravity:function(){var b="n";a.scrollTop()<c.offset().top-angular.element(".tipsy").height()-2&&(b="s");var d="";return c.offset().left+angular.element(".tipsy").width()<a.width()+a.scrollLeft()?d="w":c.offset().left-angular.element(".tipsy").width()>a.scrollLeft()&&(d="e"),b+d},live:!0,html:!0,opacity:1})}}}]),GoogleMerchants.factory("wpHttp",["$http","$q","$log","BACKEND","NONCE",function(a,b,c,d,e){return{post:function(c,f){var g=b.defer();return a.post(d+c+"&security="+e,f).then(function(a){g.resolve(a.data)},function(a,b){g.reject(a,b)}),g.promise},get:function(c){var f=b.defer();return a.get(d+c+"&security="+e).then(function(a){f.resolve(a.data)},function(a,b){f.reject(a,b)}),f.promise}}}]),GoogleMerchants.controller("detailedInformationController",["$scope","$log","attributesService",function(a,b,c){a.attributes=[],a.cats=[],a.attributes=c.getAttributes()}]),GoogleMerchants.directive("detailedInformation",function(){return{restrict:"E",scope:{detailedInformation:"=information"},templateUrl:"detailedInformation/detailedInformation.tpl.html",controller:"detailedInformationController"}}),GoogleMerchants.controller("categoryMapperController",["$scope","$rootScope","$interval","$timeout",function(a,b,c,d){a.dialogVisible=!0,a.selectedCategory="",a.selectedCategoryId=0,a.parentWidth=!1,a.siteCats=[],a.initialized=!1,a.innerMapping=!1,a.limits=100,a.catMappings=[],b.$on("categories.loaded",function(){a.innerMapping=b.cats}),a.innerMapping=b.cats,a.initialize=function(){a.initialized||(d(function(){c(function(){a.limits<a.innerMapping.length&&(a.limits+=20)},10)},100),a.initialized=!0,a.afterInitialize())},a.afterInitialize=function(){angular.forEach(a.cats,function(a,b){})},angular.isUndefined(a.context)&&(a.context="categories"),a.expandNode=function(a){a.children.length&&(a.expanded=!a.expanded)},a.getTimes=function(a){return new Array(a)},a.toggleDialog=function(){a.dialogVisible=!a.dialogVisible},a.getPlaceholder=function(){return a.visible?"":"Select Google Product Category"}}]),GoogleMerchants.directive("categoryMapper",function(){return{restrict:"E",scope:{mappings:"=",grey:"=",context:"@?"},templateUrl:"productCategories/categoryMapper/categoryMapper.tpl.html",controller:"categoryMapperController"}}),GoogleMerchants.controller("googleCategorySelectorController",["$scope","$log","$window","googleCategoriesService",function(a,b,c,d){function e(b,c,d){var f,g;for(f=0;f<d.children.length;f+=1){if(g=d.children[f],angular.isDefined(a.mappings[g.id])){if(!a.mappings[g.id].byUser){var h={id:b,name:c,byUser:!1};a.mappings[g.id]=h}}else a.mappings[g.id]={id:b,name:c,byUser:!1};e(b,c,g)}return!1}var f=[];a.categories=[],a.level=1,a.search="",a.loading=!1,a.hasResults=!0,a.byUser=!1,a.select=function(b){var c=b.name.replace("<strong>","").replace("</strong>","").replace("<b>","").replace("</b>","");a.visible=!1,a.selectedCategory=c,a.mappings[a.node.id]={id:b.id,name:c,byUser:!0},e(b.id,c,a.node)},a.loadCategories=function(b){a.loading=!0;var c="";b&&(c="&search="+b),d.searchCategories(c).then(function(b){a.categories=b}).finally(function(){a.loading=!1})},a.expand=function(c){if(c.opened)return void(c.opened=!1);a.loading=!0,d.getChildCategories(c.id).then(function(a){"null"!=a&&(c.children=a,c.opened=!0)},function(){b.error("There was a problem loading the categories")}).finally(function(){a.loading=!1})},a.matchSearch=function(a){return function(b){return b.name===a.name}},a.$watch("search",function(b,c){if(""==c&&(f=a.categories),""==b)return void(a.categories=f);a.loadCategories(b)},!0),a.categoryChanged=function(){a.loadCategories(a.selectedCategory)},a.categoryClicked=function(){a.selectedCategory;a.visible||(a.visible=!0),a.byUser||(a.selectedCategory=""),a.search="",a.categoryChanged()},a.closeMe=function(){a.visible&&(a.visible=!1)}}]),GoogleMerchants.directive("googleCategorySelector",["$rootScope",function(a){return{restrict:"E",templateUrl:"productCategories/googleCategorySelector/googleCategorySelector.tpl.html",controller:"googleCategorySelectorController"}}]),GoogleMerchants.controller("productCategoriesController",["$scope",function(a){}]),GoogleMerchants.directive("productCategories",function(){return{restrict:"E",scope:{productCategories:"=information"},templateUrl:"productCategories/productCategories.tpl.html",controller:"productCategoriesController"}}),GoogleMerchants.controller("shippingController",["$scope","currencyService",function(a,b){a.currency=b.getCurrency()}]),GoogleMerchants.directive("shipping",function(){return{restrict:"E",scope:{shipping:"=information"},templateUrl:"shipping/shipping.tpl.html",controller:"shippingController"}}),GoogleMerchants.controller("uniqueIdentifiersController",["$scope",function(a){}]),GoogleMerchants.directive("uniqueIdentifiers",function(){return{restrict:"E",scope:{uniqueIdentifiers:"=information"},templateUrl:"uniqueIdentifiers/uniqueIdentifiers.tpl.html",controller:"uniqueIdentifiersController"}}),angular.module("templates-dist",["advancedAttributes/advancedAttributes.tpl.html","availabilityPrice/availabilityPrice.tpl.html","basicInformation/basicInformation.tpl.html","common/mapping/mapping.tpl.html","detailedInformation/detailedInformation.tpl.html","productCategories/categoryMapper/categoryMapper.tpl.html","productCategories/categoryMapper/noCategoriesNotice.tpl.html","productCategories/googleCategorySelector/googleCategorySelector.tpl.html","productCategories/productCategories.tpl.html","shipping/shipping.tpl.html","uniqueIdentifiers/uniqueIdentifiers.tpl.html"]),angular.module("advancedAttributes/advancedAttributes.tpl.html",[]).run(["$templateCache",function(a){a.put("advancedAttributes/advancedAttributes.tpl.html",'<div class="wpallexport-collapsed wpallexport-section" ng-class="{closed: !advancedAttributes.open }">\n <div class="wpallexport-content-section">\n <div class="wpallexport-collapsed-header disable-jquery"\n ng-click="advancedAttributes.open = !advancedAttributes.open">\n <h3>Advanced Attributes</h3>\n </div>\n <div class="wpallexport-collapsed-content" id="advanced-attributes"\n ng-slide-down="advancedAttributes.open" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <h3 class="inner-title">Product Type</h3>\n <h4>Multipack</h4>\n <p>\n Multipacks are packages that include several identical products to create a larger unit of sale,\n submitted as a single item.\n For example, if the product for sale is a 6-pack of soda, the multipack value would be 6.\n </p>\n <div class="input">\n <label><input type="text" ng-model="advancedAttributes.multipack" class="wpae-default-input" droppable/></label>\n </div>\n\n <h4>Adult</h4>\n <div class="input">\n <label><input type="radio" ng-model="advancedAttributes.adult" value="no"/>False</label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="advancedAttributes.adult" value="yes"/>True</label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="advancedAttributes.adult" value="customValue"/>Custom data</label>\n <div ng-slide-down="advancedAttributes.adult == \'customValue\'" duration="0.2" class="input inner">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.adultCV" droppable />\n </div>\n </div>\n\n <h3 class="inner-title">Adwords & Shopping Campaigns</h3>\n <h4>Adwords Redirect</h4>\n <p>If provided, make sure that the URL redirects to the same URL as given in the \'link\' attribute.</p>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.adwordsRedirect" droppable />\n </div>\n\n <h4>Custom Labels</h4>\n <p>\n You can use custom labels to subdivide products in your campaign using any values\n of your choosing. For example, you can use custom labels to indicate that products\n are seasonal, on clearance, best sellers, etc. (<a href="https://support.google.com/adwords/answer/6275295" target="_blank">Learn more about how to set up Shopping campaigns.</a>)\n </p>\n <div style="margin-top:10px;">Custom Label 0</div>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.customLabel0" droppable />\n <a href="" class="wpae-field-mapping" ng-click="showCustomLabel0Mappings=true">Data Mapping</a>\n <div style="position: relative">\n <mapping mappings="advancedAttributes.customLabel0Mappings" show="showCustomLabel0Mappings" context="text" tooltip="For example, if you have products tagged \'reduced price\' and \'on sale\' and you want both to be listed as \'clearance\' in your export:<br/><br/>Create two sets of data mappings, with \'Exported Data\' set to \'reduced price\' for one and \'on sale\' for the other. \'Translated To\' for both would be \'clearance\'." />\n </div>\n </div>\n <div style="margin-top:10px;">Custom Label 1</div>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.customLabel1" droppable />\n <a href="" class="wpae-field-mapping" ng-click="showCustomLabel1Mappings=true">Data Mapping</a>\n <div style="position: relative">\n <mapping mappings="advancedAttributes.customLabel1Mappings" show="showCustomLabel1Mappings" context="text" tooltip="For example, if you have products tagged \'reduced price\' and \'on sale\' and you want both to be listed as \'clearance\' in your export:<br/><br/>Create two sets of data mappings, with \'Exported Data\' set to \'reduced price\' for one and \'on sale\' for the other. \'Translated To\' for both would be \'clearance\'." />\n </div>\n </div>\n <div style="margin-top:10px;">Custom Label 2</div>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.customLabel2" droppable />\n <a href="" class="wpae-field-mapping" ng-click="showCustomLabel2Mappings=true">Data Mapping</a>\n <div style="position: relative">\n <mapping mappings="advancedAttributes.customLabel2Mappings" show="showCustomLabel2Mappings" context="text" tooltip="For example, if you have products tagged \'reduced price\' and \'on sale\' and you want both to be listed as \'clearance\' in your export:<br/><br/>Create two sets of data mappings, with \'Exported Data\' set to \'reduced price\' for one and \'on sale\' for the other. \'Translated To\' for both would be \'clearance\'." />\n </div>\n </div>\n <div style="margin-top:10px;">Custom Label 3</div>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.customLabel3" droppable />\n <a href="" class="wpae-field-mapping" ng-click="showCustomLabel3Mappings=true">Data Mapping</a>\n <div style="position: relative">\n <mapping mappings="advancedAttributes.customLabel3Mappings" show="showCustomLabel3Mappings" context="text" tooltip="For example, if you have products tagged \'reduced price\' and \'on sale\' and you want both to be listed as \'clearance\' in your export:<br/><br/>Create two sets of data mappings, with \'Exported Data\' set to \'reduced price\' for one and \'on sale\' for the other. \'Translated To\' for both would be \'clearance\'." />\n </div>\n </div>\n <div style="margin-top:10px;">Custom Label 4</div>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.customLabel4" droppable />\n <a href="" class="wpae-field-mapping" ng-click="showCustomLabel4Mappings=true">Data Mapping</a>\n <div style="position: relative">\n <mapping mappings="advancedAttributes.customLabel4Mappings" show="showCustomLabel4Mappings" context="text" tooltip="For example, if you have products tagged \'reduced price\' and \'on sale\' and you want both to be listed as \'clearance\' in your export:<br/><br/>Create two sets of data mappings, with \'Exported Data\' set to \'reduced price\' for one and \'on sale\' for the other. \'Translated To\' for both would be \'clearance\'." />\n </div>\n </div>\n\n <hr/>\n\n <h3 class="inner-title">Unit Prices</h3>\n <p>\n These attributes allow you to submit pricing for products that rely on unit pricing.\n The \'unit pricing measure\' attribute defines the measure and dimension of an item (e.g. 150g).\n The \'unit pricing base measure attribute specifies your preference of the denominator of the unit price (e.g. 100g).\n </p>\n <p>\n For example, if the \'price\' is 3 USD, \'unit pricing measure\' is 150g and \'unit pricing base measure\' is 100g, the unit price would be \'2 USD/200g\'.\n </p>\n\n <h4>Unit Pricing Measure</h4>\n <div class="input">\n <input type="text" ng-model="advancedAttributes.unitPricingMeasure" class="wpae-default-input" droppable />\n </div>\n <h4>Unit Pricing Base Measure</h4>\n <div class="input">\n <input type="text" ng-model="advancedAttributes.unitPricingBaseMeasure" class="wpae-default-input" droppable />\n <select style="width: 170px;" ng-model="advancedAttributes.unitPricingBaseMeasureUnit">\n <option value="kg">Kilograms (kg)</option>\n <option value="g">Ounces (oz)</option>\n <option value="lb">Pounds (lb)</option>\n <option value="mg">Milligrams (mg)</option>\n <option value="g">Grams (g)</option>\n </select>\n </div>\n <hr/>\n <h3 class="inner-title">Additional Attributes</h3>\n <h4>Expiration Date</h4>\n <p>\n This is the date that an item listing will expire. If you do not provide this attribute, items\n will expire and no longer appear in Google Shopping results after 30 days.\n <strong>You cannot use thi attribute to extend the expiration period to longer than 30 days.</strong>\n </p>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.expirationDate" droppable />\n </div>\n\n <h4>Energy Efficiency Class</h4>\n <p>\n This attribute allows you to submit the energy label for your applicable products in feeds targeting\n European Union countries and switzerland.\n </p>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.energyEfficiencyClass" droppable />\n <a href="" class="wpae-field-mapping" ng-click="showEnergyEfficiencyMappings=true">Data Mapping</a>\n <div style="position: relative">\n <mapping mappings="advancedAttributes.energyEfficiencyClassMappings" show="showEnergyEfficiencyMappings" tooltip="For example, if you have products tagged \'energy efficient\' and \'low power\' and you want both to be listed as \'A+++\' in your export:\n<br/><br/>\nCreate two sets of data mappings, with \'Exported Data\' set to \'energy efficient\' for one and \'low power\' for the other. \'Translated To\' for both would be \'A+++\'." />\n </div>\n </div>\n <h4>Promotion ID</h4>\n <p>\n If using Merchant Promotions, the \'promotion id\' attribute is used in both your products\n feed and your promotions feed to match products to promotions across the two feeds.\n </p>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="advancedAttributes.promotionId" droppable />\n <a href="" class="wpae-field-mapping" ng-click="showPromotionIdMappings=true">Data Mapping</a>\n <div style="position: relative">\n <mapping mappings="advancedAttributes.promotionIdMappings" show="showPromotionIdMappings" tooltip="For example, if your products are tagged \'reduced price\' and \'on sale\' and you want both to be listed with a specific promotion ID in your export:\n<br/><br/>\n'+"Create two sets of data mappings, with 'Exported Data' set to 'reduced price' for one and 'on sale' for the other. 'Translated To' for both would be the desired promotion ID.\" />\n </div>\n </div>\n\n </div>\n </div>\n </div>\n</div>")}]),angular.module("availabilityPrice/availabilityPrice.tpl.html",[]).run(["$templateCache",function(a){a.put("availabilityPrice/availabilityPrice.tpl.html",'<div class="wpallexport-collapsed wpallexport-section" ng-class="{closed: !availabilityPrice.open}">\n <div class="wpallexport-content-section">\n <div class="wpallexport-collapsed-header disable-jquery" ng-click="availabilityPrice.open = !availabilityPrice.open">\n <h3>Availability & Price</h3>\n </div>\n <div class="wpallexport-collapsed-content" id="availability-price" ng-slide-down="availabilityPrice.open" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <h4>Price</h4>\n <div class="input">\n <label><input type="radio" ng-model="availabilityPrice.price" value="useProductPrice" /> Use the product\'s price</label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="availabilityPrice.price" value="customValue" /> Custom data</label>\n\n <div class="input inner" ng-slide-down="availabilityPrice.price == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="availabilityPrice.priceCV" droppable />\n </div>\n </div>\n\n <div class="input inner">\n <a href="" ng-click="availabilityPrice.adjustPrice = !availabilityPrice.adjustPrice" class="adjust-price-link">\n <span class="open-indicator" ng-if="availabilityPrice.adjustPrice">-</span>\n <span class="open-indicator" ng-if="!availabilityPrice.adjustPrice">+</span> Adjust Price\n </a>\n <div ng-slide-down="availabilityPrice.adjustPrice" class="adjust-price" duration="0.2">\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="availabilityPrice.adjustPriceValue" droppable /><select ng-model="availabilityPrice.adjustPriceType">\n <option value="%">%</option>\n <option value="USD">{{currency}}</option>\n </select>\n\n <div ng-show="availabilityPrice.adjustPriceType == \'%\'" class="tooltip-container">\n <a href="#" ng-cloak="" class="wpallexport-help"\n tipsy="Leave blank or enter in 100% to keep the price as is. Enter in 110% to markup by 10%. Enter in 50% to cut prices in half.">?</a>\n </div>\n <div ng-show="availabilityPrice.adjustPriceType == \'USD\'" class="tooltip-container">\n <a href="#" ng-cloak="" class="wpallexport-help"\n tipsy="Enter a negative number to reduce prices.">?</a>\n </div>\n </div>\n </div>\n </div>\n <h4>Sale Price</h4>\n <div class="input">\n <label><input type="radio" ng-model="availabilityPrice.salePrice" value="useProductSalePrice"/>Use the product\'s sale price</label>\n </div>\n <div class="input">\n <div class="input">\n <label><input type="radio" ng-model="availabilityPrice.salePrice" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="availabilityPrice.salePrice == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="availabilityPrice.salePriceCV" droppable/>\n </div>\n </div>\n </div>\n <div class="input inner">\n <a href="" ng-click="availabilityPrice.adjustSalePrice = !availabilityPrice.adjustSalePrice" ng-init="availabilityPrice.adjustSalePrice= false" class="adjust-price-link">\n <span class="open-indicator" ng-if="availabilityPrice.adjustSalePrice">-</span>\n <span class="open-indicator" ng-if="!availabilityPrice.adjustSalePrice">+</span> Adjust Sale Price\n </a>\n <div ng-slide-down="availabilityPrice.adjustSalePrice" class="adjust-price" duration="0.2">\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="availabilityPrice.adjustSalePriceValue" droppable /><select ng-model="availabilityPrice.adjustSalePriceType">\n <option value="%">%</option>\n <option value="USD">{{currency}}</option>\n </select>\n <div ng-show="availabilityPrice.adjustSalePriceType == \'%\'" class="tooltip-container">\n <a href="#" ng-cloak="" class="wpallexport-help"\n tipsy="Leave blank or enter in 100% to keep the price as is. Enter in 110% to markup by 10%. Enter in 50% to cut prices in half.">?</a>\n </div>\n <div ng-show="availabilityPrice.adjustSalePriceType == \'USD\'" class="tooltip-container">\n <a href="#" ng-cloak="" class="wpallexport-help"\n tipsy="Enter a negative number to reduce prices.">?</a>\n </div>\n </div>\n </div>\n </div>\n <h4>Availability</h4>\n <div class="input">\n <label><input type="radio" ng-model="availabilityPrice.availability" value="useWooCommerceStockValues"/>Use WooCommerce stock values</label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="availabilityPrice.availability" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="availabilityPrice.availability == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="availabilityPrice.availabilityCV" droppable />\n </div>\n </div>\n </div>\n <div class="wpallexport-collapsed wpallexport-section wpallexport-google-merchants-advanced-options" ng-init="advancedOptionsOpen = false" ng-class="{closed: !advancedOptionsOpen} ">\n <div class="wpallexport-content-section rad0">\n <div class="wpallexport-collapsed-header wpallexport-advanced-options-header disable-jquery" ng-click="advancedOptionsOpen = !advancedOptionsOpen">\n <h3 class="advanced-options">Advanced Options</h3>\n </div>\n <div class="wpallexport-collapsed-content wpallexport-advanced-options-content" ng-slide-down="advancedOptionsOpen" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <div class="input">\n <h4>Currency</h4>\n <div class="input">\n <div class="select-container" style="padding-left: 0px;">\n <select class="custom-value" chosen ng-model="availabilityPrice.currency">\n <option value="AUD">Australian Dollars (AUD)</option>\n <option value="BRL">Brazilian Reals (BRL)</option>\n <option value="GBP">British Pounds (GBP)</option>\n <option value="CAD">Canadian Dollars (CAD)</option>\n <option value="CZK">Czech Crowns (CZK)</option>\n <option value="DKK">Danish Krone (DKK)</option>\n <option value="EUR">Euros (EUR)</option>\n <option value="INR">Indian Rupees (INR)</option>\n <option value="JPY">Japanese Yen (JPY)</option>\n <option value="MXN">Mexican Pesos (MXN)</option>\n <option value="NZD">New Zealand Dollars (NZD)</option>\n <option value="NOK">Norwegian Krone (NOK)</option>\n <option value="PLN">Polish Złoty (PLN)</option>\n <option value="RUB">Russian Rubles (RUB)</option>\n <option value="SGD">Singapore Dollars (SGD)</option>\n <option value="ZAR">South Africa Rand (ZAR)</option>\n <option value="SEK">Swedish Krona (SEK)</option>\n <option value="CHF">Swiss Franc (CHF)</option>\n <option value="TRY">Turkish Lira (TRY)</option>\n <option value="USD">United States Dollars (USD)</option>\n </select>\n </div>\n </div>\n <h4>Availability Date</h4>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="availabilityPrice.availabilityDate" droppable />\n </div>\n <h4>Sale Price Effective Date</h4>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="availabilityPrice.salePriceEffectiveDate" droppable />\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n</div>')}]),angular.module("basicInformation/basicInformation.tpl.html",[]).run(["$templateCache",function(a){
|
9 |
+
a.put("basicInformation/basicInformation.tpl.html",'<div class="wpallexport-collapsed wpallexport-section" ng-class="{closed: !basicInformation.open}">\n <div class="wpallexport-content-section">\n <div class="wpallexport-collapsed-header disable-jquery" ng-click="basicInformation.open = !basicInformation.open">\n <h3>Basic Product Information</h3>\n </div>\n <div class="wpallexport-collapsed-content" id="basic-product-information" ng-slide-down="basicInformation.open" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n\n <h4>Item Title <a style="margin-top: 7px;" class="wpallexport-help" tipsy="Google Merchant Center only shows the first 70 characters of titles and crops everything over 150 characters.">?</a></h4>\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.itemTitle" value="productTitle"/>Use the product title</label>\n </div>\n <div class="input">\n <label><input type="radio" id="title-custom-data-select" ng-model="basicInformation.itemTitle" value="customValue" />Custom data</label>\n <div class="input inner" id="title-custom-data-container" ng-slide-down="basicInformation.itemTitle == \'customValue\'" duration="0.2">\n <input type="text" id="title-custom-data-value" class="wpae-default-input" ng-model="basicInformation.itemTitleCV" droppable />\n </div>\n </div>\n\n <div class="input checkbox" ng-if="basicInformation.hasVariations">\n <label><input type="checkbox" ng-model="basicInformation.useParentTitleForVariableProducts" value="1" />For variable products, use the parent product title</label>\n </div>\n\n <h4>Item Description</h4>\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.itemDescription" id="use-product-description" value="productDescription"/>Use the product description</label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.itemDescription" id="use-product-short-description" value="productShortDescription"/>Use the product short description</label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.itemDescription" id="product-description-custom-data" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="basicInformation.itemDescription == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" id="description-custom-data-value" ng-model="basicInformation.itemDescriptionCV" droppable />\n </div>\n </div>\n\n <div class="input checkbox">\n <label><input type="checkbox" ng-model="basicInformation.useVariationDescriptionForVariableProducts" value="1" />Use the variation description for variable products</label>\n </div>\n <div class="input checkbox inner" ng-slide-down="basicInformation.useVariationDescriptionForVariableProducts" duration="0.2">\n <label><input type="checkbox" ng-model="basicInformation.useParentDescirptionIfThereIsNoVariationDescirption" value="1" />If there is no variation description, use the parent product description</label>\n </div>\n\n <h4>Link</h4>\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.itemLink" id="use-product-permalinks" value="productLink"/>Use the product permalink</label>\n </div>\n\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.itemLink" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="basicInformation.itemLink == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="basicInformation.itemLinkCV" droppable />\n </div>\n </div>\n\n <div class="input checkbox">\n <label><input type="checkbox" ng-model="basicInformation.addVariationAttributesToProductUrl" />For variable products, add variation attributes to product URL</label>\n </div>\n\n <h4>Main Image Link</h4>\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.itemImageLink" value="useProductFeaturedImage"/>Use product featured image</label>\n </div>\n\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.itemImageLink" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="basicInformation.itemImageLink == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="basicInformation.itemImageLinkCV" droppable />\n </div>\n </div>\n\n <div class="input checkbox">\n <label><input type="checkbox" ng-model="basicInformation.useVariationImage" />For variable products, use variation image</label>\n </div>\n\n <div class="input checkbox inner" ng-slide-down="basicInformation.useVariationImage" duration="0.2">\n <label><input type="checkbox" ng-model="basicInformation.useFeaturedImageIfThereIsNoVariationImage" value="1" />If there is no variation image, use the featured image</label>\n </div>\n\n <h4>Additional Image Link</h4>\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.additionalImageLink" value="productImages"/>Use images from product gallery</label>\n </div>\n\n <div class="input">\n <label><input type="radio" ng-model="basicInformation.additionalImageLink" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="basicInformation.additionalImageLink == \'customValue\'" duration="0.2">\n <input type="text"class="wpae-default-input" ng-model="basicInformation.additionalImageLinkCV" droppable />\n </div>\n </div>\n </div>\n <div class="wpallexport-collapsed wpallexport-section wpallexport-google-merchants-advanced-options" ng-init="advancedOptionsOpen = false" ng-class="{closed: !advancedOptionsOpen}">\n <div class="wpallexport-content-section rad0">\n <div class="wpallexport-collapsed-header wpallexport-advanced-options-header disable-jquery" ng-click="advancedOptionsOpen = !advancedOptionsOpen">\n <h3>Advanced Options</h3>\n </div>\n <div class="wpallexport-collapsed-content wpallexport-advanced-options-content" ng-slide-down="advancedOptionsOpen" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <div class="input">\n <h4>Item ID</h4>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="basicInformation.itemId" droppable />\n </div>\n <h4>Item Condition</h4>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="basicInformation.condition" droppable />\n <a href="" class="wpae-field-mapping" ng-click="showConditionMappings=true">Data Mapping</a>\n <mapping mappings="basicInformation.conditionMappings" show="showConditionMappings" context="condition" />\n <a style="margin-top: 7px;" class="wpallexport-help" tipsy="The condition or state of the item. Google Shopping allows the promotion of quality second-hand items. There are only 3 accepted values: \'new\', \'refurbished\', and \'used\'">?</a>\n </div>\n <h4>Mobile Link</h4>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="basicInformation.mobileLink" droppable />\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n</div>')}]),angular.module("common/mapping/mapping.tpl.html",[]).run(["$templateCache",function(a){a.put("common/mapping/mapping.tpl.html",'<div class="wp-pointer wp-pointer-right" style="width: 450px; display: block; position: absolute; top: -70px; left: -23px;" ng-if="show">\n <div class="wp-pointer-content">\n <h4 style="padding-left:25px; margin-bottom:0; padding-bottom:0; margin-top:20px;">\n Data Mapping\n <a style="margin-top: 7px;" ng-if="tooltip" class="wpallexport-help"\n tipsy="{{ tooltip }}">?\n </a>\n </h4>\n\n <fieldset style="margin-top: 0; padding-top: 0; padding-bottom: 0;">\n <table cellpadding="0" cellspacing="0" class="cf-form-table" rel="cf_mapping_0" style="margin-left: 5px; margin-top: 15px;">\n <thead>\n <tr>\n <td><div style="padding-bottom:5px">Exported Data</div></td>\n <td><div style="padding-bottom:5px;">Translated To</div></td>\n <td> </td>\n </tr>\n </thead>\n <tbody>\n <tr class="form-field" ng-repeat="mapping in mappings">\n <td style="width: 50%;">\n <input type="text" ng-model="mapping.mapFrom" style="margin-left:0;"/>\n </td>\n <td style="width: 50%;">\n <div ng-if="context == \'sizeType\'">\n <select chosen ng-model="mapping.mapTo" >\n <option value="">Please select</option>\n <option value="regular">Regular</option>\n <option value="petite">Petite</option>\n <option value="plus">Plus</option>\n <option value="big and tall">Big and tall</option>\n <option value="maternity">Maternity</option>\n </select>\n </div>\n <div ng-if="context == \'condition\' ">\n <select chosen ng-model="mapping.mapTo">\n <option value="new">New</option>\n <option value="refurbished">Refurbished</option>\n <option value="used">Used</option>\n </select>\n </div>\n <div ng-if="context != \'sizeType\' && context != \'condition\'">\n <input type="text" ng-model="mapping.mapTo" />\n </div>\n </td>\n <td class="action remove">\n <a href="" ng-click="removeMapping(mapping)" ng-show="$index > 0"\n style="right:-10px;"></a>\n </td>\n </tr>\n <tr>\n <td colspan="3">\n <a href="" ng-click="addMapping()" title="Add Another" class="action add-new-key add-new-entry" style="margin-top: 15px; margin-bottom:15px; margin-left: 0;">\n Add Another\n </a>\n </td>\n </tr>\n </tbody>\n </table>\n <input type="hidden" name="custom_mapping_rules[]" value="">\n </fieldset>\n <div class="wp-pointer-buttons">\n <a class="close" href="" ng-click="close()">Close</a>\n <a class="save_popup save_mr" style="position:static; margin-right: 15px;" href="" ng-click="saveMappings()">Save Rules</a>\n </div>\n </div>\n <div class="wp-pointer-arrow">\n <div class="wp-pointer-arrow-inner"></div>\n </div>\n</div>')}]),angular.module("detailedInformation/detailedInformation.tpl.html",[]).run(["$templateCache",function(a){a.put("detailedInformation/detailedInformation.tpl.html",'<div class="wpallexport-collapsed wpallexport-section" ng-class="{closed: !detailedInformation.open }">\n <div class="wpallexport-content-section">\n <div class="wpallexport-collapsed-header disable-jquery" ng-click="detailedInformation.open = !detailedInformation.open ">\n <h3>Detailed Product Attributes & Item Grouping</h3>\n </div>\n <div class="wpallexport-collapsed-content" id="detailed-product-information" ng-slide-down="detailedInformation.open" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <h4>Item Group ID</h4>\n <p>\n For variable products, each variant is exported as a separate product.\n Variants that belong to the same group must all have the same Item Group ID\n so that Google knows they are related.\n </p>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.setTheGroupId" value="automatically" />Automatically set the item group ID</label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.setTheGroupId" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="detailedInformation.setTheGroupId == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="detailedInformation.setTheGroupIdCV" droppable />\n </div>\n </div>\n <h4>Color</h4>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.color" value="selectFromWooCommerceProductAttributes" />Select from WooCommerce product attributes</label>\n <div ng-slide-down="detailedInformation.color == \'selectFromWooCommerceProductAttributes\'" duration="0.2">\n <div class="select-container" ng-if="attributes.length">\n <select autodetect="Color" chosen ng-options="\'{\' + i.name + \'}\' as i.name for i in attributes" ng-model="detailedInformation.colorAttribute" class="inner">\n <option value="">Leave Blank</option>\n </select>\n </div>\n <div class="no-attributes" ng-if="!attributes.length">\n The products in this export have no product attributes. Add attributes to your products in order to map them to a color.\n </div>\n </div>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.color" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="detailedInformation.color == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="detailedInformation.colorCV" droppable />\n </div>\n </div>\n\n <h4>Size</h4>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.size" value="selectFromWooCommerceProductAttributes" />Select from WooCommerce product attributes</label>\n <div ng-slide-down="detailedInformation.size == \'selectFromWooCommerceProductAttributes\'" duration="0.2">\n <div class="select-container" ng-if="attributes.length">\n <select id="sizeAttribute" autodetect="Size" chosen ng-options="\'{\' + i.name + \'}\' as i.name for i in attributes" ng-model="detailedInformation.sizeAttribute" class="inner">\n <option value="">Leave Blank</option>\n </select>\n </div>\n <div class="no-attributes" ng-if="!attributes.length">\n The products in this export have no product attributes. Add attributes to your products in order to map them to a size.\n </div>\n </div>\n </div>\n <div class="input">\n <label>\n <input type="radio" ng-model="detailedInformation.size" value="customValue" />Custom data\n </label>\n <div class="input inner" ng-slide-down="detailedInformation.size== \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="detailedInformation.sizeCV" droppable />\n </div>\n </div>\n\n <h4>Gender</h4>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.gender" value="selectFromWooCommerceProductAttributes" />Select from WooCommerce product attributes</label>\n <div class="clear"></div>\n <div ng-slide-down="detailedInformation.gender == \'selectFromWooCommerceProductAttributes\'" duration="0.2">\n <div class="select-container" ng-if="attributes.length">\n <select autodetect="Gender" chosen ng-options="\'{\' + i.name + \'}\' as i.name for i in attributes" ng-model="detailedInformation.genderAttribute" class="inner">\n <option value="">Leave Blank</option>\n </select>\n </div>\n <div class="no-attributes" ng-if="!attributes.length">\n The products in this export have no product attributes. Add attributes to your products in order to map them to a gender.\n </div>\n </div>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.gender" value="autodetectBasedOnProductTaxonomies"/>Autodetect based on WooCommerce product categories</label>\n <div ng-slide-down="detailedInformation.gender == \'autodetectBasedOnProductTaxonomies\'" duration="0.2">\n <div class="inner">\n <div class="input">\n <label>\n <input type="radio" ng-model="detailedInformation.genderAutodetect" value="keepBlank"/>Leave gender blank if unable to detect gender\n </label>\n </div>\n <div class="input">\n <label>\n <input type="radio" ng-model="detailedInformation.genderAutodetect" value="setToUnisex" />Set gender to unisex if unable to detect gender\n </label>\n </div>\n </div>\n </div>\n </div>\n <div class="input">\n <label>\n <input type="radio" ng-model="detailedInformation.gender" value="selectProductTaxonomies" />Select from WooCommerce product categories\n </label>\n <div ng-slide-down="detailedInformation.gender == \'selectProductTaxonomies\'" duration="0.2">\n <category-mapper mappings="detailedInformation.genderCats" context="gender" />\n </div>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.gender" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="detailedInformation.gender == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="detailedInformation.genderCV" droppable />\n </div>\n </div>\n </div>\n\n <div class="wpallexport-collapsed wpallexport-section wpallexport-google-merchants-advanced-options" ng-class="{closed: !advancedOptionsOpen}">\n <div class="wpallexport-content-section rad0">\n <div class="wpallexport-collapsed-header wpallexport-advanced-options-header disable-jquery" ng-click="advancedOptionsOpen = !advancedOptionsOpen">\n <h3>Advanced Options</h3>\n </div>\n <div class="wpallexport-collapsed-content wpallexport-advanced-options-content" ng-slide-down="advancedOptionsOpen" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <h4>Size Type</h4>\n <div class="input">\n <div style="display: inline-block;">\n <input type="text" class="wpae-default-input" ng-model="detailedInformation.sizeType" droppable />\n </div>\n <a href="" class="wpae-field-mapping" ng-click="showMappings=true">Data Mapping</a>\n <div style="position: relative">\n <mapping mappings="detailedInformation.sizeTypeMappings" show="showMappings" context="sizeType" />\n </div>\n </div>\n <h4>Size System</h4>\n <div class="input">\n <div class="select-container" style="padding-left: 0;">\n <select chosen ng-model="detailedInformation.sizeSystem" class="inner">\n <option value="">Leave Blank</option>\n <option value="US">US</option>\n <option value="UK">UK</option>\n <option value="EU">EU</option>\n <option value="DE">DE</option>\n <option value="FR">FR</option>\n <option value="JP">JP</option>\n <option value="CN">CN (China)</option>\n <option value="IT">IT</option>\n <option value="BR">BR</option>\n <option value="MEX">MEX</option>\n <option value="AU">AU</option>\n </select>\n </div>\n </div>\n <h4>Age Group</h4>\n <div class="input">\n <label>\n <input type="radio" ng-model="detailedInformation.ageGroup" value="selectFromWooCommerceProductAttributes"/>Select from WooCommerce product attributes\n </label>\n <div ng-slide-down="detailedInformation.ageGroup == \'selectFromWooCommerceProductAttributes\'" duration="0.2">\n <div class="select-container" ng-if="attributes.length">\n <select chosen ng-options="\'{\' + i.name + \'}\' as i.name for i in attributes" ng-model="detailedInformation.ageGroupAttribute" class="inner">\n <option value="">Leave Blank</option>\n </select>\n </div>\n <div class="no-attributes" ng-if="!attributes.length">\n The products in this export have no product attributes. Add attributes to your products in order to map them to an age group.\n </div>\n </div>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.ageGroup" value="selectFromProductTaxonomies" />Select from WooCommerce product categories</label>\n <div ng-slide-down="detailedInformation.ageGroup == \'selectFromProductTaxonomies\' " duration="0.5" >\n <div ng-show="detailedInformation.ageGroup == \'selectFromProductTaxonomies\' ">\n <category-mapper mappings="detailedInformation.ageGroupCats" grey="1" context="ageGroup" />\n </div>\n </div>\n </div>\n <div class="input">\n <label>\n <input type="radio" ng-model="detailedInformation.ageGroup" value="customValue" />Custom data\n </label>\n <div class="input inner" ng-slide-down="detailedInformation.ageGroup== \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="detailedInformation.ageGroupCV" droppable />\n </div>\n </div>\n <h4>Material</h4>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.material" value="selectFromWooCommerceProductAttributes" />Select from WooCommerce product attributes</label>\n <div ng-slide-down="detailedInformation.material == \'selectFromWooCommerceProductAttributes\'" duration="0.2">\n <div class="select-container" ng-if="attributes.length">\n <select chosen ng-options="\'{\' + i.name + \'}\' as i.name for i in attributes" ng-model="detailedInformation.materialAttribute" class="inner">\n <option value="">Leave Blank</option>\n </select>\n </div>\n <div class="no-attributes outer" ng-if="!attributes.length">\n The products in this export have no product attributes. Add attributes to your products in order to map them to a material.\n </div>\n </div>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.material" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="detailedInformation.material == \'customValue\'" duration="0.2">\n <div class="input inner" ng-slide-down="detailedInformation.material == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="detailedInformation.materialCV" droppable />\n </div>\n </div>\n\n <h4>Pattern</h4>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.pattern" value="selectFromWooCommerceProductAttributes" />Select from WooCommerce product attributes</label>\n <div ng-slide-down="detailedInformation.pattern == \'selectFromWooCommerceProductAttributes\'" duration="0.2">\n <div class="select-container" ng-if="attributes.length">\n <select chosen ng-options="\'{\' + i.name + \'}\' as i.name for i in attributes" ng-model="detailedInformation.patternAttribute" class="inner">\n <option value="">Leave Blank</option>\n </select>\n </div>\n <div class="no-attributes outer" ng-if="!attributes.length">\n The products in this export have no product attributes. Add attributes to your products in order to map them to a pattern.\n </div>\n </div>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="detailedInformation.pattern" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="detailedInformation.pattern == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="detailedInformation.patternCV" droppable />\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n</div>')}]),angular.module("productCategories/categoryMapper/categoryMapper.tpl.html",[]).run(["$templateCache",function(a){
|
10 |
+
a.put("productCategories/categoryMapper/categoryMapper.tpl.html",'<div class="category-mapper">\n <div>\n <div class="woocommerce-categories-title" style="float:left; padding: 13px 13px 13px 31px;">\n <h4 style="margin: 0; padding: 0; font-size:13px; color:#000;">WooCommerce Categories</h4>\n </div>\n\n <div class="google-categories-title" style="float:right; padding:13px; margin-right: 278px;" ng-if="::(context==\'categories\')">\n <h4 style="margin:0; padding:0; font-size:13px; color:#000; ">Google Categories</h4>\n </div>\n\n <div class="google-categories-title" style="float:right; padding:13px; margin-right: 288px;" ng-if="::(context==\'gender\')">\n <h4 style="margin:0; padding:0; font-size:13px; color:#000; ">Google Genders</h4>\n </div>\n\n <div class="google-categories-title" style="float:right; padding:13px; margin-right: 268px;" ng-if="::(context==\'ageGroup\')">\n <h4 style="margin:0; padding:0; font-size:13px; color:#000; ">Google Age Groups</h4>\n </div>\n </div>\n\n <ul dx-start-with="innerMapping" class="tree" ng-class="::{ \'root\' : $dxLevel == 0 }" ng-init="initialize()" style="width: 100%; float:left; margin-top: 0px;" ng-if="innerMapping">\n <li ng-repeat="node in $dxPrior.children | limitTo: limits" style="display: block;">\n <div class="category-container" style="position: relative;" ng-class="::{ \'with-children\' : node.children.length, \'without-children\' : (!node.children.length) }">\n <div class="hline"></div>\n <div class="category-icon-container" style="float:left;">\n <div class="vline" ng-if="::(($index > 0 && $dxLevel == 0) || $dxLevel > 0)"></div>\n <div class="vline noborder" ng-if="::(!(($index > 0 && $dxLevel == 0) || $dxLevel > 0))"></div>\n <span ng-if="node.expanded" class="minus" ng-click="expandNode(node)">\n <svg width="9" height="9" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg">\n <path d="M1600 736v192q0 40-28 68t-68 28h-1216q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h1216q40 0 68 28t28 68z"/>\n </svg>\n </span>\n <span ng-if="!node.expanded && node.children.length" class="plus" ng-click="expandNode(node)">\n <svg width="9" height="9" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg">\n <path d="M1600 736v192q0 40-28 68t-68 28h-416v416q0 40-28 68t-68 28h-192q-40 0-68-28t-28-68v-416h-416q-40 0-68-28t-28-68v-192q0-40 28-68t68-28h416v-416q0-40 28-68t68-28h192q40 0 68 28t28 68v416h416q40 0 68 28t28 68z"/>\n </svg>\n </span>\n <span ng-if="::(!node.children.length)" class="plus blank" style="cursor: default;"></span>\n <div class="vline bottom"></div>\n </div>\n <div class="category-name-container">\n <span class="dot" ng-repeat="i in ::getTimes($dxLevel) track by $index"></span>\n <div class="category">\n <a class="category-title" href="" ng-click="expandNode(node)" ng-bind-html="::node.title | safe"></a>\n <br ng-if="::node.children.length"/>\n <span ng-if="::node.children.length" class="children-number">\n {{ ::node.children.length }} child <span ng-if="::node.children.length == 1">category</span><span ng-if="::node.children.length > 1">categories</span>\n </span>\n </div>\n </div>\n <div class="line" ></div>\n <div class="mapping" ng-if="::(context == \'categories\')" >\n <div style="position: relative" ng-init="visible=false">\n <input type="text" style="width: 402px; font-size:13px; padding-left: 8px;" placeholder="{{ getPlaceholder() }}"\n ng-class="{ \'selected-automatically\' : !mappings[node.id].byUser, \'opened\' : visible }"\n ng-model="selectedCategory"\n ng-value="mappings[node.id].name"\n ng-change="categoryChanged()"\n ng-click="categoryClicked()"\n class="wpae-google-category-input"\n ng-model-options="{ debounce: 200 }"\n />\n <google-category-selector />\n </div>\n </div>\n <div class="mapping gender" ng-if="::(context == \'gender\')" style="border: none;">\n <select chosen cascade ng-model="mappings[node.id]" ng-change="select()">\n <option value="male">Male</option>\n <option value="female">Female</option>\n <option value="unisex">Unisex</option>\n </select>\n </div>\n <div class="mapping" ng-if="::(context == \'ageGroup\')" style="border: none; background-color: #F1F1F1; padding:0; margin-top: 5px;" >\n <select chosen cascade ng-model="mappings[node.id]" ng-change="select()">\n <option value="newborn">Newborn</option>\n <option value="infant">Infant</option>\n <option value="toddler">Toddler</option>\n <option value="kids">Kids</option>\n <option value="adult">Adult</option>\n </select>\n </div>\n <div style="clear:both;"></div>\n </div>\n <ul dx-connect="node" ng-if="node.expanded==true"/>\n </li>\n </ul>\n <div class=\'catList\' style="clear:both;"></div>\n <div class="mask" ng-class="::{ grey : grey == 1}"></div>\n</div>\n<div ng-if="initialized && !innerMapping.children.length">\n <div ng-include="\'productCategories/categoryMapper/noCategoriesNotice.tpl.html\'"></div>\n</div>')}]),angular.module("productCategories/categoryMapper/noCategoriesNotice.tpl.html",[]).run(["$templateCache",function(a){a.put("productCategories/categoryMapper/noCategoriesNotice.tpl.html",'<div class="no-categories-notice" ng-if="context == \'categories\' ">\n The products in this export are uncategorized. Add WooCommerce Product Categories to your products in order to map them to Google Product Categories.\n</div>\n\n<div class="no-categories-notice" ng-if="context == \'gender\' ">\n The products in this export are uncategorized. Add WooCommerce Product Categories to your products in order to map them to a gender.\n</div>\n\n<div class="no-categories-notice" ng-if="context == \'ageGroup\' ">\n The products in this export are uncategorized. Add WooCommerce Product Categories to your products in order to map them to an age group.\n</div>\n')}]),angular.module("productCategories/googleCategorySelector/googleCategorySelector.tpl.html",[]).run(["$templateCache",function(a){a.put("productCategories/googleCategorySelector/googleCategorySelector.tpl.html",'<div class="google-category-selector" ng-init="loadCategories()" ng-if="visible" click-outside="closeMe()" outside-if-not="wpae-google-category-input">\n <ul class="categories" dx-start-with="categories">\n <li ng-repeat="category in $dxPrior.children" style="position: relative;">\n <div class="div-content">\n <div class="expand-button" ng-click="expand(category); $event.preventDefault();">\n <div ng-if="category.hasChildren > 0" class="chevron">\n <svg ng-if="!category.opened" width="10" height="10" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg">\n <path d="M1683 1331l-166 165q-19 19-45 19t-45-19l-531-531-531 531q-19 19-45 19t-45-19l-166-165q-19-19-19-45.5t19-45.5l742-741q19-19 45-19t45 19l742 741q19 19 19 45.5t-19 45.5z"/>\n </svg>\n <svg ng-if="category.opened" width="10" height="10" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg">\n <path d="M1683 808l-742 741q-19 19-45 19t-45-19l-742-741q-19-19-19-45.5t19-45.5l166-165q19-19 45-19t45 19l531 531 531-531q19-19 45-19t45 19l166 165q19 19 19 45.5t-19 45.5z"/>\n </svg>\n </div>\n </div>\n <div ng-bind-html="category.name | safe" ng-click="select(category)" class="google-category-name-container">\n </div>\n <div class="clear"></div>\n </div>\n <ul dx-connect="category" class="categories inner-categories" ng-if="category.opened" />\n </li>\n </ul>\n <div ng-if="!categories.children.length" class="google-no-results-found">\n No results found\n </div>\n</div>')}]),angular.module("productCategories/productCategories.tpl.html",[]).run(["$templateCache",function(a){a.put("productCategories/productCategories.tpl.html",'<div class="wpallexport-collapsed wpallexport-section" ng-class="{closed: !productCategories.open}">\n <div class="wpallexport-content-section">\n <div class="wpallexport-collapsed-header disable-jquery" ng-click="productCategories.open = !productCategories.open">\n <h3>Product Categories</h3>\n </div>\n <div class="wpallexport-collapsed-content" ng-slide-down="productCategories.open" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <h4>Product Type</h4>\n <p>Use this attribute to classify the product using your own categories. The categories here don\'t need to match Google\'s list of acceptable product categories.</p>\n <div class="input">\n <label>\n <input type="radio" ng-model="productCategories.productType" value="useWooCommerceProductCategories" />Use WooCommerce\'s product category\n </label>\n </div>\n <div class="input">\n <label>\n <input type="radio" ng-model="productCategories.productType" value="customValue" />Custom data\n </label>\n <div class="input inner" ng-slide-down="productCategories.productType == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="productCategories.productTypeCV" droppable />\n </div>\n </div>\n <h4>Product Category</h4>\n <p>\n Products added to Google Merchant Center must be categorized according to Google\'s list of product categories. Each product may only be assigned one Google product category. <a href="https://support.google.com/merchants/answer/160081" target="_blank">Read more about Google product categories.</a>\n </p>\n <div class="input">\n <label>\n <input type="radio" ng-model="productCategories.productCategories" value="mapProductCategories" />Map WooCommerce\'s product categories to Google\'s product categories\n <a href="#" class="wpallexport-help" style="margin-top:5px; margin-left: 2px;"\n tipsy="Products assigned more than one WooCommerce product category and mapped to more than one Google product category will be mapped to the most specific, deepest Google product category selected for that product.">?</a>\n </label>\n </div>\n <div ng-slide-down="productCategories.productCategories == \'mapProductCategories\'" duration="0.5">\n <category-mapper mappings="productCategories.catMappings" />\n </div>\n\n <div class="input">\n <label>\n <input type="radio" ng-model="productCategories.productCategories" value="useWooCommerceProductCategories" />Use WooCommerce\'s product categories\n <a href="#" class="wpallexport-help" style="margin-top:5px; margin-left: 2px;"\n tipsy="Products assigned to more than one WooCommerce product category will only have the most specific, deepest product category exported.">?</a>\n </label>\n <p class="no-categories-notice" ng-slide-down="productCategories.productCategories == \'useWooCommerceProductCategories\'" duration="0.2">\n If your WooCommerce product categories do not exactly match Google\'s, your feed will fail when uploaded to Google.\n </p>\n <div ng-slide-down="!$root.cats.children.length && productCategories.productCategories == \'useWooCommerceProductCategories\'" duration="0.2">\n <div ng-include="\'productCategories/categoryMapper/noCategoriesNotice.tpl.html\'" ng-init="context = \'categories\' "></div>\n </div>\n </div>\n\n <div class="input">\n <label>\n <input type="radio" ng-model="productCategories.productCategories" value="customValue" />Custom data\n </label>\n <div class="input inner" ng-slide-down="productCategories.productCategories == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="productCategories.productCategoriesCV" droppable />\n </div>\n </div>\n </div>\n\n </div>\n </div>\n</div>')}]),angular.module("shipping/shipping.tpl.html",[]).run(["$templateCache",function(a){a.put("shipping/shipping.tpl.html",'<div class="wpallexport-collapsed wpallexport-section" ng-class="{closed: !shipping.open }">\n <div class="wpallexport-content-section">\n <div class="wpallexport-collapsed-header disable-jquery"\n ng-click="shipping.open = !shipping.open ">\n <h3>Shipping</h3>\n </div>\n <div class="wpallexport-collapsed-content" id="shipping" ng-slide-down="shipping.open" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <h4>Shipping Price</h4>\n <p>\n This attribute allows Google to provide a shipping estimate for the product.\n This overrides the default shipping price configured in the Google Merchant Center.\n </p>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="shipping.shippingPrice" droppable />\n <a href="" ng-click="shipping.adjustShippingPrice = !shipping.adjustShippingPrice" class="adjust-price-link">\n <span ng-if="!shipping.adjustShippingPrice" style="width: 6px; display: inline-block;">+</span>\n <span ng-if="shipping.adjustShippingPrice" style="width: 6px; display: inline-block;">-</span>\n Adjust Shipping Price</a>\n <input type="hidden" ng-model="shipping.shippingHeight"/>\n <input type="hidden" ng-model="shipping.shippingLength"/>\n <input type="hidden" ng-model="shipping.shippingWidth"/>\n <div ng-slide-down="shipping.adjustShippingPrice" class="adjust-price" duration="0.2" style="margin-top: 5px; ">\n <input type="text" style="margin-top: 0; margin-right: 0;" class="wpae-default-input" ng-model="shipping.adjustShippingPriceValue" droppable /><select style="margin-top:5px;" ng-model="shipping.adjustPriceType">\n <option value="%">%</option>\n <option value="USD">{{currency}}</option>\n </select>\n\n <div ng-show="shipping.adjustPriceType == \'%\'" class="tooltip-container">\n <a href="#" ng-cloak="" class="wpallexport-help" style="top:0;"\n tipsy="Leave blank or enter in 100% to keep the price as is. Enter in 110% to markup by 10%. Enter in 50% to cut prices in half.">?</a>\n </div>\n <div ng-show="shipping.adjustPriceType == \'USD\'" class="tooltip-container">\n <a href="#" style="top:0;" ng-cloak="" class="wpallexport-help" tipsy="Enter a negative number to reduce prices.">?</a>\n </div>\n </div>\n </div>\n\n <h4>Length, Width, Height</h4>\n <div class="input">\n <label>\n <input type="radio" ng-model="shipping.dimensions" value="useWooCommerceProductValues"/>Use WooCommerce\'s product values and convert them to\n <select ng-model="shipping.convertTo" style="width: 175px; height: 30px; padding: 0 0 0 8px; margin-left: 5px; margin-top: 5px; ">\n <option value="cm">Centimeters (cm)</option>\n <option value="in">Inches (in)</option>\n </select>\n </label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="shipping.dimensions" value="customValue"/>Custom data</label>\n <div ng-slide-down="shipping.dimensions == \'customValue\'" duration="0.2" class="input inner">\n <input type="text" class="wpae-default-input" ng-model="shipping.dimensionsCV" droppable />\n </div>\n </div>\n\n <h4>Shipping Weight</h4>\n <div class="input">\n <label>\n <input type="radio" ng-model="shipping.weight" value=""/>Do not include in the feed\n </label>\n </div>\n <div class="input">\n <label>\n <input type="radio" ng-model="shipping.weight" value="useWooCommerceProductValues"/>Use WooCommerce\'s product values\n </label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="shipping.weight" value="customValue"/>Custom data</label>\n <div ng-slide-down="shipping.weight == \'customValue\'" duration="0.2" class="input inner">\n <input type="text" class="wpae-default-input" ng-model="shipping.weightCV" droppable />\n </div>\n </div>\n\n <h4>Shipping Label</h4>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="shipping.shippingLabel" droppable />\n </div>\n </div>\n </div>\n </div>\n</div>')}]),angular.module("uniqueIdentifiers/uniqueIdentifiers.tpl.html",[]).run(["$templateCache",function(a){a.put("uniqueIdentifiers/uniqueIdentifiers.tpl.html",'<div class="wpallexport-collapsed wpallexport-section" ng-class="{closed: !uniqueIdentifiers.open}">\n <div class="wpallexport-content-section">\n <div class="wpallexport-collapsed-header disable-jquery" ng-click="uniqueIdentifiers.open = !uniqueIdentifiers.open">\n <h3>Unique Identifiers</h3>\n </div>\n <div class="wpallexport-collapsed-content slide-toggle" id="unique-identifiers" ng-slide-down="uniqueIdentifiers.open" duration="0.5">\n <div class="wpallexport-collapsed-content-inner">\n <p>\n Unique product identifiers are product codes associated with your products.\n Products submitted without unique identifiers are difficult to classify and may not be able to take advantage of all Google shopping features.\n <a href="https://support.google.com/merchants/answer/7052112?hl=en&ref_topic=3404778#intro-product-identifiers" target="_blank">Read more about unique product identifiers</a>.\n </p>\n <h4>GTIN</h4>\n <p>\n Global Trade Item Numbers include UPC, EAN (in Europe), JAN (in Japan), and ISBN. <a href="https://support.google.com/merchants/answer/6219078" target="_blank">Read how to find your products\' GTIN</a>.\n </p>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="uniqueIdentifiers.gtin" droppable />\n </div>\n\n <h4>MPN</h4>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="uniqueIdentifiers.mpn" droppable />\n </div>\n\n <h4>Brand</h4>\n <div class="input">\n <input type="text" class="wpae-default-input" ng-model="uniqueIdentifiers.brand" droppable />\n </div>\n\n <h4>Identifier Exists</h4>\n <div class="input">\n <label><input type="radio" ng-model="uniqueIdentifiers.identifierExists" value="1" />Set to false if product has no GTIN or MPN\n <a style="margin-top: 0; margin-bottom: 0; margin-left: 0; padding-bottom: 0;" class="wpallexport-help" tipsy="If your product has neither an MPN or GTIN, Google requires the attribute \'identifier_exists\' to be set to false. WP All Export will do this automatically if this option is enabled.">?</a>\n </label>\n </div>\n <div class="input">\n <label><input type="radio" ng-model="uniqueIdentifiers.identifierExists" value="customValue" />Custom data</label>\n <div class="input inner" ng-slide-down="uniqueIdentifiers.identifierExists == \'customValue\'" duration="0.2">\n <input type="text" class="wpae-default-input" ng-model="uniqueIdentifiers.identifierExistsCV" droppable />\n </div>\n </div>\n\n </div>\n </div>\n </div>\n</div>')}]);
|
filters/pmxe_url_filter.php
ADDED
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
function pmxe_url_filter($str) {
|
4 |
+
return "http://" == $str || "ftp://" == $str ? "" : $str;
|
5 |
+
}
|
libraries/WpaeXmlProcessor.php
CHANGED
@@ -161,8 +161,9 @@ class WpaeXmlProcessor
|
|
161 |
$f = $this->dom->createDocumentFragment();
|
162 |
$f->appendXML($nodeXML);
|
163 |
$this->parseElement($f);
|
164 |
-
$element->parentNode->parentNode
|
165 |
-
|
|
|
166 |
} else {
|
167 |
foreach ($snippetValues as $snippetValue) {
|
168 |
$newValueNode = $element->parentNode->cloneNode(true);
|
@@ -628,9 +629,10 @@ class WpaeXmlProcessor
|
|
628 |
{
|
629 |
$xml = str_replace('<!--', '<commentTempNode>', $xml);
|
630 |
$xml = str_replace('-->', '</commentTempNode>', $xml);
|
631 |
-
|
632 |
$xml = str_replace("\"{}\"", '""', $xml);
|
633 |
-
|
|
|
|
|
634 |
$xml = str_replace(">\"\"<", '><', $xml);
|
635 |
$xml = str_replace("[implode(',',{})]", "", $xml);
|
636 |
return $xml;
|
161 |
$f = $this->dom->createDocumentFragment();
|
162 |
$f->appendXML($nodeXML);
|
163 |
$this->parseElement($f);
|
164 |
+
if($element->parentNode->parentNode) {
|
165 |
+
$element->parentNode->parentNode->replaceChild($f, $element->parentNode);
|
166 |
+
}
|
167 |
} else {
|
168 |
foreach ($snippetValues as $snippetValue) {
|
169 |
$newValueNode = $element->parentNode->cloneNode(true);
|
629 |
{
|
630 |
$xml = str_replace('<!--', '<commentTempNode>', $xml);
|
631 |
$xml = str_replace('-->', '</commentTempNode>', $xml);
|
|
|
632 |
$xml = str_replace("\"{}\"", '""', $xml);
|
633 |
+
|
634 |
+
preg_replace('%(\[.*)({})(.*\])%', "$1\"\"$2", $xml);
|
635 |
+
|
636 |
$xml = str_replace(">\"\"<", '><', $xml);
|
637 |
$xml = str_replace("[implode(',',{})]", "", $xml);
|
638 |
return $xml;
|
libraries/XmlCsvExport.php
CHANGED
@@ -764,7 +764,7 @@ final Class XmlCsvExport
|
|
764 |
{
|
765 |
foreach ($available_data[$section['content']] as $field)
|
766 |
{
|
767 |
-
if ( is_array($field) and (isset($field['auto']) or ! in_array('product', $post['cpt']) ))
|
768 |
{
|
769 |
$auto_generate['ids'][] = 1;
|
770 |
$auto_generate['cc_label'][] = is_array($field) ? $field['label'] : $field;
|
764 |
{
|
765 |
foreach ($available_data[$section['content']] as $field)
|
766 |
{
|
767 |
+
if ( is_array($field) and (isset($field['auto']) or (is_array($post['cpt']) && ! in_array('product', $post['cpt']) )))
|
768 |
{
|
769 |
$auto_generate['ids'][] = 1;
|
770 |
$auto_generate['cc_label'][] = is_array($field) ? $field['label'] : $field;
|
libraries/XmlExportACF.php
CHANGED
@@ -172,8 +172,9 @@ if ( ! class_exists('XmlExportACF') )
|
|
172 |
|
173 |
$orderby = "order_no";
|
174 |
|
175 |
-
|
176 |
-
|
|
|
177 |
foreach ($fields as $field){
|
178 |
if (in_array($field['type'], array('tab'))) continue;
|
179 |
$this->_acf_groups[$key]['fields'][] = $field;
|
@@ -226,7 +227,7 @@ if ( ! class_exists('XmlExportACF') )
|
|
226 |
}
|
227 |
|
228 |
|
229 |
-
if ( ! empty($field_value)
|
230 |
{
|
231 |
$field_value = maybe_unserialize($field_value);
|
232 |
|
@@ -1074,6 +1075,9 @@ if ( ! class_exists('XmlExportACF') )
|
|
1074 |
}
|
1075 |
else
|
1076 |
{
|
|
|
|
|
|
|
1077 |
|
1078 |
// $article[$element_name] = ($preview) ? trim(preg_replace('~[\r\n]+~', ' ', htmlspecialchars($val))) : $val;
|
1079 |
wp_all_export_write_article( $article, $element_name, ($preview) ? trim(preg_replace('~[\r\n]+~', ' ', htmlspecialchars($val))) : $val);
|
172 |
|
173 |
$orderby = "order_no";
|
174 |
|
175 |
+
if(is_array($sortArray[$orderby])) {
|
176 |
+
@array_multisort($sortArray[$orderby], SORT_ASC, $fields);
|
177 |
+
}
|
178 |
foreach ($fields as $field){
|
179 |
if (in_array($field['type'], array('tab'))) continue;
|
180 |
$this->_acf_groups[$key]['fields'][] = $field;
|
227 |
}
|
228 |
|
229 |
|
230 |
+
if ( ! empty($field_value))
|
231 |
{
|
232 |
$field_value = maybe_unserialize($field_value);
|
233 |
|
1075 |
}
|
1076 |
else
|
1077 |
{
|
1078 |
+
if($field_value === 0 || $field_value === "0") {
|
1079 |
+
$val = 0;
|
1080 |
+
}
|
1081 |
|
1082 |
// $article[$element_name] = ($preview) ? trim(preg_replace('~[\r\n]+~', ' ', htmlspecialchars($val))) : $val;
|
1083 |
wp_all_export_write_article( $article, $element_name, ($preview) ? trim(preg_replace('~[\r\n]+~', ' ', htmlspecialchars($val))) : $val);
|
libraries/XmlExportCpt.php
CHANGED
@@ -612,6 +612,10 @@ final class XmlExportCpt
|
|
612 |
$templateOptions['status_xpath'] = '{' . $element_name . '[1]}';
|
613 |
$templateOptions['is_update_status'] = 1;
|
614 |
break;
|
|
|
|
|
|
|
|
|
615 |
case 'date':
|
616 |
$templateOptions[$element_type] = '{' . $element_name . '[1]}';
|
617 |
$templateOptions['is_update_dates'] = 1;
|
612 |
$templateOptions['status_xpath'] = '{' . $element_name . '[1]}';
|
613 |
$templateOptions['is_update_status'] = 1;
|
614 |
break;
|
615 |
+
case 'comment_status':
|
616 |
+
$templateOptions['comment_status_xpath'] = '{'.$element_name.'[1]}';
|
617 |
+
$templateOptions['is_update_comment_status'] = 1;
|
618 |
+
break;
|
619 |
case 'date':
|
620 |
$templateOptions[$element_type] = '{' . $element_name . '[1]}';
|
621 |
$templateOptions['is_update_dates'] = 1;
|
libraries/XmlExportEngine.php
CHANGED
@@ -285,12 +285,12 @@ if ( ! class_exists('XmlExportEngine') ){
|
|
285 |
'type' => 'image_alt',
|
286 |
'auto' => 1
|
287 |
),
|
288 |
-
|
289 |
-
|
290 |
-
|
291 |
-
|
292 |
-
|
293 |
-
|
294 |
)
|
295 |
),
|
296 |
'attachments' => array(
|
@@ -519,7 +519,7 @@ if ( ! class_exists('XmlExportEngine') ){
|
|
519 |
}
|
520 |
if ( 'advanced' == $this->post['export_type'] and ! self::$is_user_export and ! self::$is_comment_export and ! self::$is_taxonomy_export )
|
521 |
{
|
522 |
-
$meta_keys = $wpdb->get_results("SELECT DISTINCT meta_key FROM {$table_prefix}postmeta WHERE {$table_prefix}postmeta.meta_key NOT LIKE '_edit%' LIMIT
|
523 |
if ( ! empty($meta_keys)){
|
524 |
$exclude_keys = array('_first_variation_attributes', '_is_first_variation_created');
|
525 |
foreach ($meta_keys as $meta_key) {
|
285 |
'type' => 'image_alt',
|
286 |
'auto' => 1
|
287 |
),
|
288 |
+
array(
|
289 |
+
'name' => 'Featured',
|
290 |
+
'label' => 'featured',
|
291 |
+
'type' => 'image_featured',
|
292 |
+
'auto' => 1
|
293 |
+
),
|
294 |
)
|
295 |
),
|
296 |
'attachments' => array(
|
519 |
}
|
520 |
if ( 'advanced' == $this->post['export_type'] and ! self::$is_user_export and ! self::$is_comment_export and ! self::$is_taxonomy_export )
|
521 |
{
|
522 |
+
$meta_keys = $wpdb->get_results("SELECT DISTINCT meta_key FROM {$table_prefix}postmeta WHERE {$table_prefix}postmeta.meta_key NOT LIKE '_edit%' LIMIT 1000");
|
523 |
if ( ! empty($meta_keys)){
|
524 |
$exclude_keys = array('_first_variation_attributes', '_is_first_variation_created');
|
525 |
foreach ($meta_keys as $meta_key) {
|
libraries/XmlExportMediaGallery.php
CHANGED
@@ -47,6 +47,8 @@ final class XmlExportMediaGallery
|
|
47 |
'post_type' => 'attachment',
|
48 |
'posts_per_page' => -1,
|
49 |
'post_parent' => self::$pid,
|
|
|
|
|
50 |
) );
|
51 |
|
52 |
if ( ! empty($attachments)):
|
@@ -122,6 +124,8 @@ final class XmlExportMediaGallery
|
|
122 |
'post_type' => 'attachment',
|
123 |
'posts_per_page' => -1,
|
124 |
'post_parent' => self::$pid,
|
|
|
|
|
125 |
) );
|
126 |
|
127 |
if ( ! empty($images)):
|
@@ -165,11 +169,11 @@ final class XmlExportMediaGallery
|
|
165 |
return $data;
|
166 |
}
|
167 |
|
168 |
-
|
169 |
-
|
170 |
-
|
171 |
|
172 |
-
|
173 |
|
174 |
switch ($field){
|
175 |
|
@@ -190,8 +194,8 @@ final class XmlExportMediaGallery
|
|
190 |
|
191 |
}
|
192 |
|
193 |
-
|
194 |
-
|
195 |
|
196 |
private static function get_media( $field = 'url', $attachment = false )
|
197 |
{
|
47 |
'post_type' => 'attachment',
|
48 |
'posts_per_page' => -1,
|
49 |
'post_parent' => self::$pid,
|
50 |
+
'orderby' => 'ID',
|
51 |
+
'order' => 'ASC'
|
52 |
) );
|
53 |
|
54 |
if ( ! empty($attachments)):
|
124 |
'post_type' => 'attachment',
|
125 |
'posts_per_page' => -1,
|
126 |
'post_parent' => self::$pid,
|
127 |
+
'orderby' => 'ID',
|
128 |
+
'order' => 'ASC'
|
129 |
) );
|
130 |
|
131 |
if ( ! empty($images)):
|
169 |
return $data;
|
170 |
}
|
171 |
|
172 |
+
public static function get_images( $field = 'image_url', $options = false )
|
173 |
+
{
|
174 |
+
self::init('images', $options);
|
175 |
|
176 |
+
$data = array();
|
177 |
|
178 |
switch ($field){
|
179 |
|
194 |
|
195 |
}
|
196 |
|
197 |
+
return $data;
|
198 |
+
}
|
199 |
|
200 |
private static function get_media( $field = 'url', $attachment = false )
|
201 |
{
|
libraries/XmlExportWooCommerce.php
CHANGED
@@ -345,10 +345,10 @@ if ( ! class_exists('XmlExportWooCommerce') )
|
|
345 |
}
|
346 |
|
347 |
if(\Wpae\App\Service\WooCommerceVersion::isWooCommerceNewerThan('3.0')) {
|
348 |
-
$available_data['
|
349 |
'name' => 'Product Visibility',
|
350 |
'label' => 'product_visibility',
|
351 |
-
'type' => '
|
352 |
'auto' => true
|
353 |
);
|
354 |
}
|
@@ -665,11 +665,6 @@ if ( ! class_exists('XmlExportWooCommerce') )
|
|
665 |
|
666 |
break;
|
667 |
|
668 |
-
case 'product_visibility':
|
669 |
-
$product = wc_get_product( $record->ID );
|
670 |
-
$data[$element_name] = apply_filters('pmxe_woo_field', pmxe_filter($product->get_catalog_visibility(), $fieldSnipped), $element_value, $record->ID);
|
671 |
-
break;
|
672 |
-
|
673 |
default:
|
674 |
|
675 |
$cur_meta_values = get_post_meta($record->ID, $element_value);
|
@@ -812,7 +807,7 @@ if ( ! class_exists('XmlExportWooCommerce') )
|
|
812 |
|
813 |
foreach ($data_to_export as $key => $data) {
|
814 |
if ($key == 'Price' || $key == 'Regular Price' || $key == 'Sale Price') {
|
815 |
-
|
816 |
}
|
817 |
wp_all_export_write_article($article, $key, $data);
|
818 |
}
|
@@ -901,7 +896,7 @@ if ( ! class_exists('XmlExportWooCommerce') )
|
|
901 |
$data_to_export = $this->prepare_export_data( $record, $options, $elId );
|
902 |
|
903 |
foreach ($data_to_export as $key => $data)
|
904 |
-
{
|
905 |
$element_name_ns = '';
|
906 |
$element_name = str_replace("-", "_", preg_replace('/[^a-z0-9:_]/i', '', $key));
|
907 |
if (strpos($element_name, ":") !== false)
|
@@ -915,7 +910,7 @@ if ( ! class_exists('XmlExportWooCommerce') )
|
|
915 |
$rawPrices = apply_filters('wp_all_export_raw_prices', $rawPrices);
|
916 |
|
917 |
if ($key == 'Price' || $key == 'Regular Price' || $key == 'Sale Price') {
|
918 |
-
|
919 |
}
|
920 |
|
921 |
$xmlWriter = apply_filters('wp_all_export_add_before_element', $xmlWriter, $element_name, XmlExportEngine::$exportID, $record->ID);
|
345 |
}
|
346 |
|
347 |
if(\Wpae\App\Service\WooCommerceVersion::isWooCommerceNewerThan('3.0')) {
|
348 |
+
$available_data['existing_taxonomies'][] = array(
|
349 |
'name' => 'Product Visibility',
|
350 |
'label' => 'product_visibility',
|
351 |
+
'type' => 'cats',
|
352 |
'auto' => true
|
353 |
);
|
354 |
}
|
665 |
|
666 |
break;
|
667 |
|
|
|
|
|
|
|
|
|
|
|
668 |
default:
|
669 |
|
670 |
$cur_meta_values = get_post_meta($record->ID, $element_value);
|
807 |
|
808 |
foreach ($data_to_export as $key => $data) {
|
809 |
if ($key == 'Price' || $key == 'Regular Price' || $key == 'Sale Price') {
|
810 |
+
//$data = $rawPrices ? $data :pmxe_prepare_price($data, true, true, true);
|
811 |
}
|
812 |
wp_all_export_write_article($article, $key, $data);
|
813 |
}
|
896 |
$data_to_export = $this->prepare_export_data( $record, $options, $elId );
|
897 |
|
898 |
foreach ($data_to_export as $key => $data)
|
899 |
+
{
|
900 |
$element_name_ns = '';
|
901 |
$element_name = str_replace("-", "_", preg_replace('/[^a-z0-9:_]/i', '', $key));
|
902 |
if (strpos($element_name, ":") !== false)
|
910 |
$rawPrices = apply_filters('wp_all_export_raw_prices', $rawPrices);
|
911 |
|
912 |
if ($key == 'Price' || $key == 'Regular Price' || $key == 'Sale Price') {
|
913 |
+
//$data = $rawPrices? $data :pmxe_prepare_price($data, false, true, true);
|
914 |
}
|
915 |
|
916 |
$xmlWriter = apply_filters('wp_all_export_add_before_element', $xmlWriter, $element_name, XmlExportEngine::$exportID, $record->ID);
|
libraries/XmlExportWooCommerceOrder.php
CHANGED
@@ -555,6 +555,10 @@ if ( ! class_exists('XmlExportWooCommerceOrder') )
|
|
555 |
if ( ! in_array($friendly_name, $headers)) $headers[] = $friendly_name;
|
556 |
}
|
557 |
}
|
|
|
|
|
|
|
|
|
558 |
|
559 |
break;
|
560 |
// Discount Amount (per coupon)
|
@@ -569,6 +573,11 @@ if ( ! class_exists('XmlExportWooCommerceOrder') )
|
|
569 |
if ( ! in_array("Coupon Code", $headers)) $headers[] = "Coupon Code";
|
570 |
}
|
571 |
}
|
|
|
|
|
|
|
|
|
|
|
572 |
|
573 |
break;
|
574 |
// Fee Amount (per surcharge)
|
@@ -583,6 +592,11 @@ if ( ! class_exists('XmlExportWooCommerceOrder') )
|
|
583 |
if ( ! in_array("Fee Name", $headers)) $headers[] = "Fee Name";
|
584 |
}
|
585 |
}
|
|
|
|
|
|
|
|
|
|
|
586 |
|
587 |
break;
|
588 |
|
@@ -1294,8 +1308,10 @@ if ( ! class_exists('XmlExportWooCommerceOrder') )
|
|
1294 |
'_line_total' => __('Item Total', 'wp_all_export_plugin'),
|
1295 |
'_line_subtotal_tax' => __('Item Tax', 'wp_all_export_plugin'),
|
1296 |
'_line_tax' => __('Item Tax Total', 'wp_all_export_plugin'),
|
1297 |
-
'_line_tax_data' => __('Item Tax Data', 'wp_all_export_plugin')
|
1298 |
-
|
|
|
|
|
1299 |
|
1300 |
return apply_filters('wp_all_export_available_order_default_product_data_filter', $data);
|
1301 |
}
|
555 |
if ( ! in_array($friendly_name, $headers)) $headers[] = $friendly_name;
|
556 |
}
|
557 |
}
|
558 |
+
else{
|
559 |
+
$friendly_name = str_replace(" (per tax)", "", $options['cc_name'][$element_key]);
|
560 |
+
if ( ! in_array($friendly_name, $headers)) $headers[] = $friendly_name;
|
561 |
+
}
|
562 |
|
563 |
break;
|
564 |
// Discount Amount (per coupon)
|
573 |
if ( ! in_array("Coupon Code", $headers)) $headers[] = "Coupon Code";
|
574 |
}
|
575 |
}
|
576 |
+
else{
|
577 |
+
$friendly_name = str_replace("(per coupon)", "", $options['cc_name'][$element_key]);
|
578 |
+
if ( ! in_array($friendly_name, $headers)) $headers[] = $friendly_name;
|
579 |
+
if ( ! in_array("Coupon Code", $headers)) $headers[] = "Coupon Code";
|
580 |
+
}
|
581 |
|
582 |
break;
|
583 |
// Fee Amount (per surcharge)
|
592 |
if ( ! in_array("Fee Name", $headers)) $headers[] = "Fee Name";
|
593 |
}
|
594 |
}
|
595 |
+
else{
|
596 |
+
$friendly_name = str_replace(" (per surcharge)", "", $options['cc_name'][$element_key]);
|
597 |
+
if ( ! in_array($friendly_name, $headers)) $headers[] = $friendly_name;
|
598 |
+
if ( ! in_array("Fee Name", $headers)) $headers[] = "Fee Name";
|
599 |
+
}
|
600 |
|
601 |
break;
|
602 |
|
1308 |
'_line_total' => __('Item Total', 'wp_all_export_plugin'),
|
1309 |
'_line_subtotal_tax' => __('Item Tax', 'wp_all_export_plugin'),
|
1310 |
'_line_tax' => __('Item Tax Total', 'wp_all_export_plugin'),
|
1311 |
+
'_line_tax_data' => __('Item Tax Data', 'wp_all_export_plugin'),
|
1312 |
+
'__line_item_id' => __('Order Line ID', 'wp_all_export_plugin'),
|
1313 |
+
'__line_item_title' => __('Order Line Title', 'wp_all_export_plugin'),
|
1314 |
+
);
|
1315 |
|
1316 |
return apply_filters('wp_all_export_available_order_default_product_data_filter', $data);
|
1317 |
}
|
models/export/record.php
CHANGED
@@ -340,7 +340,7 @@ class PMXE_Export_Record extends PMXE_Model_Record {
|
|
340 |
case 'XmlGoogleMerchants':
|
341 |
case 'custom':
|
342 |
require_once PMXE_ROOT_DIR . '/classes/XMLWriter.php';
|
343 |
-
file_put_contents($file_path, PMXE_XMLWriter::preprocess_xml(XmlExportEngine::$exportOptions['custom_xml_template_footer']), FILE_APPEND);
|
344 |
break;
|
345 |
}
|
346 |
|
@@ -382,7 +382,9 @@ class PMXE_Export_Record extends PMXE_Model_Record {
|
|
382 |
))->update();
|
383 |
|
384 |
do_action('pmxe_after_export', $this->id, $this);
|
385 |
-
}
|
|
|
|
|
386 |
|
387 |
$this->set('registered_on', date('Y-m-d H:i:s'))->save(); // update registered_on to indicated that job has been exectured even if no files are going to be imported by the rest of the method
|
388 |
|
@@ -664,9 +666,7 @@ class PMXE_Export_Record extends PMXE_Model_Record {
|
|
664 |
}
|
665 |
|
666 |
public static function is_bundle_supported( $options )
|
667 |
-
{
|
668 |
-
$options += PMXE_Plugin::get_default_import_options();
|
669 |
-
|
670 |
// custom XML template do not support import bundle
|
671 |
if ( $options['export_to'] == 'xml' && ! empty($options['xml_template_type']) && in_array($options['xml_template_type'], array('custom', 'XmlGoogleMerchants')) ) return false;
|
672 |
|
340 |
case 'XmlGoogleMerchants':
|
341 |
case 'custom':
|
342 |
require_once PMXE_ROOT_DIR . '/classes/XMLWriter.php';
|
343 |
+
file_put_contents($file_path, PMXE_XMLWriter::preprocess_xml("\n".XmlExportEngine::$exportOptions['custom_xml_template_footer']), FILE_APPEND);
|
344 |
break;
|
345 |
}
|
346 |
|
382 |
))->update();
|
383 |
|
384 |
do_action('pmxe_after_export', $this->id, $this);
|
385 |
+
} else {
|
386 |
+
do_action('pmxe_after_iteration', $this->id, $this);
|
387 |
+
}
|
388 |
|
389 |
$this->set('registered_on', date('Y-m-d H:i:s'))->save(); // update registered_on to indicated that job has been exectured even if no files are going to be imported by the rest of the method
|
390 |
|
666 |
}
|
667 |
|
668 |
public static function is_bundle_supported( $options )
|
669 |
+
{
|
|
|
|
|
670 |
// custom XML template do not support import bundle
|
671 |
if ( $options['export_to'] == 'xml' && ! empty($options['xml_template_type']) && in_array($options['xml_template_type'], array('custom', 'XmlGoogleMerchants')) ) return false;
|
672 |
|
readme.txt
CHANGED
@@ -1,8 +1,8 @@
|
|
1 |
=== Export WordPress data to XML/CSV ===
|
2 |
Contributors: soflyy, wpallimport
|
3 |
Requires at least: 4.1
|
4 |
-
Tested up to: 4.9.
|
5 |
-
Stable tag: 1.2.
|
6 |
Tags: wordpress csv export, wordpress xml export, xml, csv, datafeed, export, migrate, export csv from wordpress, export xml from wordpress, advanced xml export, advanced csv export, export data, bulk csv export, export custom post type, export woocommerce products, export woocommerce orders, migrate woocommerce, csv export, export csv, xml export, export xml, csv exporter, datafeed
|
7 |
|
8 |
WP All Export is an extremely powerful exporter that makes it easy to export any XML, CSV, or Excel file from WordPress.
|
@@ -86,6 +86,22 @@ Either: -
|
|
86 |
|
87 |
== Changelog ==
|
88 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
89 |
= 1.2.0 =
|
90 |
* new feature: Automatic Scheduling - A new, optional service from Soflyy that makes scheduling exports incredibly easy.
|
91 |
* improvement: Support migrating users & keeping passwords
|
1 |
=== Export WordPress data to XML/CSV ===
|
2 |
Contributors: soflyy, wpallimport
|
3 |
Requires at least: 4.1
|
4 |
+
Tested up to: 4.9.8
|
5 |
+
Stable tag: 1.2.1
|
6 |
Tags: wordpress csv export, wordpress xml export, xml, csv, datafeed, export, migrate, export csv from wordpress, export xml from wordpress, advanced xml export, advanced csv export, export data, bulk csv export, export custom post type, export woocommerce products, export woocommerce orders, migrate woocommerce, csv export, export csv, xml export, export xml, csv exporter, datafeed
|
7 |
|
8 |
WP All Export is an extremely powerful exporter that makes it easy to export any XML, CSV, or Excel file from WordPress.
|
86 |
|
87 |
== Changelog ==
|
88 |
|
89 |
+
= 1.2.1 =
|
90 |
+
* new filter: added pmxe_after_iteration action
|
91 |
+
* bugfix: increase custom query meta limit
|
92 |
+
* bugfix: remove deprecated function calls for PHP 7.2 compatibility
|
93 |
+
* bugfix: address various PHP warnings and notices
|
94 |
+
* bugfix: graceful failure for non:writable uploads folder
|
95 |
+
* bugfix: warning when exporting WooCommerce orders using Automatic Scheduling
|
96 |
+
* bugfix: WooCommerce product variations exported as separate products when adding product attributes to custom export fields
|
97 |
+
* bugfix: small UI and spacing issues
|
98 |
+
* bugfix: prices with more than two decimal places are not exported correctly
|
99 |
+
* bugfix: exporting empty ACF values shifts rows in CSV exports
|
100 |
+
* bugfix: Australia missing from scheduling timezones
|
101 |
+
* bugfix: unable to filter or export WooCommerce product visibility data
|
102 |
+
* bugfix: Automatic scheduling UI spacing issues
|
103 |
+
* bugfix: unrelated errors are reported in functions.php file
|
104 |
+
|
105 |
= 1.2.0 =
|
106 |
* new feature: Automatic Scheduling - A new, optional service from Soflyy that makes scheduling exports incredibly easy.
|
107 |
* improvement: Support migrating users & keeping passwords
|
src/App/Controller/SchedulingLicenseController.php
CHANGED
@@ -62,6 +62,13 @@ class SchedulingLicenseController
|
|
62 |
{
|
63 |
global $wpdb;
|
64 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
65 |
// retrieve the license from the database
|
66 |
return $this->licensingActivator->activateLicense(PMXE_Plugin::getSchedulingName(),\Wpae\App\Service\License\LicenseActivator::CONTEXT_SCHEDULING);
|
67 |
}
|
@@ -70,6 +77,13 @@ class SchedulingLicenseController
|
|
70 |
{
|
71 |
$options = PMXE_Plugin::getInstance()->getOption();
|
72 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
73 |
return $this->licensingActivator->checkLicense(PMXE_Plugin::getSchedulingName(), $options, LicenseActivator::CONTEXT_SCHEDULING);
|
74 |
}
|
75 |
}
|
62 |
{
|
63 |
global $wpdb;
|
64 |
|
65 |
+
delete_transient(PMXE_Plugin::$cache_key);
|
66 |
+
|
67 |
+
$wpdb->query( $wpdb->prepare("DELETE FROM $wpdb->options WHERE option_name = %s", $this->slug . '_' . PMXE_Plugin::$cache_key) );
|
68 |
+
$wpdb->query( $wpdb->prepare("DELETE FROM $wpdb->options WHERE option_name = %s", $this->slug . '_timeout_' . PMXE_Plugin::$cache_key) );
|
69 |
+
|
70 |
+
delete_site_transient('update_plugins');
|
71 |
+
|
72 |
// retrieve the license from the database
|
73 |
return $this->licensingActivator->activateLicense(PMXE_Plugin::getSchedulingName(),\Wpae\App\Service\License\LicenseActivator::CONTEXT_SCHEDULING);
|
74 |
}
|
77 |
{
|
78 |
$options = PMXE_Plugin::getInstance()->getOption();
|
79 |
|
80 |
+
global $wpdb;
|
81 |
+
|
82 |
+
delete_transient(PMXE_Plugin::$cache_key);
|
83 |
+
|
84 |
+
$wpdb->query( $wpdb->prepare("DELETE FROM $wpdb->options WHERE option_name = %s", $this->slug . '_' . PMXE_Plugin::$cache_key) );
|
85 |
+
$wpdb->query( $wpdb->prepare("DELETE FROM $wpdb->options WHERE option_name = %s", $this->slug . '_timeout_' . PMXE_Plugin::$cache_key) );
|
86 |
+
|
87 |
return $this->licensingActivator->checkLicense(PMXE_Plugin::getSchedulingName(), $options, LicenseActivator::CONTEXT_SCHEDULING);
|
88 |
}
|
89 |
}
|
src/App/Service/Pro/VariationOptions/VariationOptions.php
CHANGED
@@ -58,11 +58,15 @@ class VariationOptions extends BasicVariationOptions implements VariationOptions
|
|
58 |
LEFT OUTER JOIN $wpdb->posts r
|
59 |
ON o.post_parent = r.ID
|
60 |
WHERE r.post_status = 'trash' AND o.post_type = 'product_variation')
|
61 |
-
OR ($wpdb->posts.post_type = 'product_variation' AND $wpdb->posts.post_status <> 'trash'
|
|
|
|
|
62 |
SELECT DISTINCT $wpdb->posts.ID
|
63 |
FROM $wpdb->posts $join
|
64 |
WHERE $where
|
65 |
-
)
|
|
|
|
|
66 |
} else {
|
67 |
return $this->defaultQuery($wpdb, $where, $join, $closeBracket);
|
68 |
}
|
58 |
LEFT OUTER JOIN $wpdb->posts r
|
59 |
ON o.post_parent = r.ID
|
60 |
WHERE r.post_status = 'trash' AND o.post_type = 'product_variation')
|
61 |
+
OR ($wpdb->posts.post_type = 'product_variation' AND $wpdb->posts.post_status <> 'trash'
|
62 |
+
|
63 |
+
AND $wpdb->posts.post_parent IN (
|
64 |
SELECT DISTINCT $wpdb->posts.ID
|
65 |
FROM $wpdb->posts $join
|
66 |
WHERE $where
|
67 |
+
)
|
68 |
+
".$this->getVariationsWhere($where, $join)."
|
69 |
+
)";
|
70 |
} else {
|
71 |
return $this->defaultQuery($wpdb, $where, $join, $closeBracket);
|
72 |
}
|
src/App/Service/VariationOptions/VariationOptions.php
CHANGED
@@ -3,6 +3,8 @@
|
|
3 |
namespace Wpae\App\Service\VariationOptions;
|
4 |
|
5 |
|
|
|
|
|
6 |
class VariationOptions implements VariationOptionsInterface
|
7 |
{
|
8 |
public function getQueryWhere($wpdb, $where, $join, $closeBracket = false)
|
@@ -33,27 +35,42 @@ class VariationOptions implements VariationOptionsInterface
|
|
33 |
}
|
34 |
|
35 |
if($closeBracket) {
|
36 |
-
|
37 |
LEFT OUTER JOIN $wpdb->posts r
|
38 |
ON o.post_parent = r.ID
|
39 |
WHERE r.post_status = 'trash' AND o.post_type = 'product_variation'))
|
40 |
-
OR ($wpdb->posts.post_type = 'product_variation' AND $wpdb->posts.post_status <> 'trash'
|
|
|
|
|
41 |
SELECT DISTINCT $wpdb->posts.ID
|
42 |
FROM $wpdb->posts $join
|
43 |
WHERE $where
|
44 |
-
)
|
|
|
|
|
|
|
45 |
} else {
|
46 |
-
|
47 |
LEFT OUTER JOIN $wpdb->posts r
|
48 |
ON o.post_parent = r.ID
|
49 |
WHERE r.post_status = 'trash' AND o.post_type = 'product_variation')
|
50 |
-
OR ($wpdb->posts.post_type = 'product_variation' AND $wpdb->posts.post_status <> 'trash'
|
|
|
|
|
|
|
51 |
SELECT DISTINCT $wpdb->posts.ID
|
52 |
FROM $wpdb->posts $join
|
53 |
WHERE $where
|
54 |
-
)
|
|
|
|
|
|
|
|
|
|
|
55 |
}
|
56 |
|
|
|
|
|
57 |
}
|
58 |
|
59 |
/**
|
3 |
namespace Wpae\App\Service\VariationOptions;
|
4 |
|
5 |
|
6 |
+
use Wpae\Pro\Filtering\FilteringCPT;
|
7 |
+
|
8 |
class VariationOptions implements VariationOptionsInterface
|
9 |
{
|
10 |
public function getQueryWhere($wpdb, $where, $join, $closeBracket = false)
|
35 |
}
|
36 |
|
37 |
if($closeBracket) {
|
38 |
+
$sql = " AND $wpdb->posts.post_type = 'product' " . $langQuery . " AND $wpdb->posts.ID NOT IN (SELECT o.ID FROM $wpdb->posts o
|
39 |
LEFT OUTER JOIN $wpdb->posts r
|
40 |
ON o.post_parent = r.ID
|
41 |
WHERE r.post_status = 'trash' AND o.post_type = 'product_variation'))
|
42 |
+
OR ($wpdb->posts.post_type = 'product_variation' AND $wpdb->posts.post_status <> 'trash'
|
43 |
+
|
44 |
+
AND $wpdb->posts.post_parent IN (
|
45 |
SELECT DISTINCT $wpdb->posts.ID
|
46 |
FROM $wpdb->posts $join
|
47 |
WHERE $where
|
48 |
+
)
|
49 |
+
".$this->getVariationsWhere($where, $join)."
|
50 |
+
|
51 |
+
)";
|
52 |
} else {
|
53 |
+
$sql = " AND $wpdb->posts.post_type = 'product' " . $langQuery . " AND $wpdb->posts.ID NOT IN (SELECT o.ID FROM $wpdb->posts o
|
54 |
LEFT OUTER JOIN $wpdb->posts r
|
55 |
ON o.post_parent = r.ID
|
56 |
WHERE r.post_status = 'trash' AND o.post_type = 'product_variation')
|
57 |
+
OR ($wpdb->posts.post_type = 'product_variation' AND $wpdb->posts.post_status <> 'trash'
|
58 |
+
|
59 |
+
|
60 |
+
AND $wpdb->posts.post_parent IN (
|
61 |
SELECT DISTINCT $wpdb->posts.ID
|
62 |
FROM $wpdb->posts $join
|
63 |
WHERE $where
|
64 |
+
)
|
65 |
+
|
66 |
+
".$this->getVariationsWhere($where, $join)."
|
67 |
+
|
68 |
+
|
69 |
+
)";
|
70 |
}
|
71 |
|
72 |
+
return $sql;
|
73 |
+
|
74 |
}
|
75 |
|
76 |
/**
|
src/App/Specification/IsImportAllowed.php
ADDED
@@ -0,0 +1,53 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
|
3 |
+
namespace Wpae\App\Specification;
|
4 |
+
|
5 |
+
|
6 |
+
class IsImportAllowed
|
7 |
+
{
|
8 |
+
public function isSatisfied($item)
|
9 |
+
{
|
10 |
+
$is_re_import_allowed = true;
|
11 |
+
if ( ! empty($item['options']['ids']) )
|
12 |
+
{
|
13 |
+
if (in_array('shop_order', $item['options']['cpt']) and class_exists('WooCommerce')) {
|
14 |
+
$required_fields = array('woo_order' => 'id');
|
15 |
+
}
|
16 |
+
else {
|
17 |
+
$required_fields = array('id' => 'id');
|
18 |
+
}
|
19 |
+
// re-import products
|
20 |
+
if ((in_array('product', $item['options']['cpt']) or $item['options']['export_type'] == 'advanced') and class_exists('WooCommerce') and (empty($item['options']['wp_query_selector']) or $item['options']['wp_query_selector'] == 'wp_query')) {
|
21 |
+
$required_fields['woo'] = '_sku';
|
22 |
+
$required_fields['cats'] = 'product_type';
|
23 |
+
$required_fields['parent'] = 'parent';
|
24 |
+
}
|
25 |
+
if ((in_array('users', $item['options']['cpt']) or $item['options']['export_type'] == 'advanced') and (!empty($item['options']['wp_query_selector']) and $item['options']['wp_query_selector'] == 'wp_user_query')) {
|
26 |
+
$required_fields['user_email'] = 'user_email';
|
27 |
+
$required_fields['user_login'] = 'user_login';
|
28 |
+
}
|
29 |
+
if ($item['options']['export_type'] == 'advanced' and (empty($item['options']['wp_query_selector']) or $item['options']['wp_query_selector'] == 'wp_query')){
|
30 |
+
$required_fields['post_type'] = 'post_type';
|
31 |
+
}
|
32 |
+
$defined_fields = array();
|
33 |
+
foreach ($item['options']['ids'] as $ID => $value)
|
34 |
+
{
|
35 |
+
foreach ($required_fields as $type => $field)
|
36 |
+
{
|
37 |
+
if (strtolower($item['options']['cc_type'][$ID]) == $type && strtolower($item['options']['cc_label'][$ID]) == strtolower($field)){
|
38 |
+
$defined_fields[] = $field;
|
39 |
+
}
|
40 |
+
}
|
41 |
+
}
|
42 |
+
|
43 |
+
foreach ($required_fields as $type => $field) {
|
44 |
+
if ( ! in_array($field, $defined_fields) ){
|
45 |
+
$is_re_import_allowed = false;
|
46 |
+
break;
|
47 |
+
}
|
48 |
+
}
|
49 |
+
}
|
50 |
+
|
51 |
+
return $is_re_import_allowed;
|
52 |
+
}
|
53 |
+
}
|
src/App/UnsecuredController/SchedulingController.php
CHANGED
@@ -72,7 +72,9 @@ class SchedulingController extends BaseController
|
|
72 |
return new JsonResponse(array('message' => 'Export not found'), 404);
|
73 |
}
|
74 |
|
75 |
-
$logger =
|
|
|
|
|
76 |
|
77 |
if ($export->processing == 1 and (time() - strtotime($export->registered_on)) > 120) {
|
78 |
// it means processor crashed, so it will reset processing to false, and terminate. Then next run it will work normally.
|
72 |
return new JsonResponse(array('message' => 'Export not found'), 404);
|
73 |
}
|
74 |
|
75 |
+
$logger = function($m) {
|
76 |
+
echo "<p>$m</p>\\n";
|
77 |
+
};
|
78 |
|
79 |
if ($export->processing == 1 and (time() - strtotime($export->registered_on)) > 120) {
|
80 |
// it means processor crashed, so it will reset processing to false, and terminate. Then next run it will work normally.
|
src/Pro/Filtering/FilteringBase.php
CHANGED
@@ -126,7 +126,7 @@ abstract class FilteringBase implements FilteringInterface
|
|
126 |
$rule->value = "-" . trim(str_replace("ago", "", $rule->value));
|
127 |
}
|
128 |
|
129 |
-
$rule->value = strpos($rule->value, ":") !== false ? date("Y-m-d H:i:s", strtotime($rule->value)) : ( in_array($rule->condition, array('greater'
|
130 |
|
131 |
}
|
132 |
|
126 |
$rule->value = "-" . trim(str_replace("ago", "", $rule->value));
|
127 |
}
|
128 |
|
129 |
+
$rule->value = strpos($rule->value, ":") !== false ? date("Y-m-d H:i:s", strtotime($rule->value)) : ( in_array($rule->condition, array('greater')) ? date("Y-m-d", strtotime('+1 day', strtotime($rule->value))) : date("Y-m-d", strtotime($rule->value)));
|
130 |
|
131 |
}
|
132 |
|
src/Scheduling/Export.php
CHANGED
@@ -23,7 +23,7 @@ class Export
|
|
23 |
{
|
24 |
// trigger update child exports with correct WHERE & JOIN filters
|
25 |
if (!empty($export->options['cpt']) and class_exists('WooCommerce') and in_array('shop_order', $export->options['cpt']) and empty($export->parent_id)) {
|
26 |
-
$queue_exports = XmlExportWooCommerceOrder::prepare_child_exports($export, true);
|
27 |
|
28 |
if (empty($queue_exports)) {
|
29 |
delete_option('wp_all_export_queue_' . $export->id);
|
23 |
{
|
24 |
// trigger update child exports with correct WHERE & JOIN filters
|
25 |
if (!empty($export->options['cpt']) and class_exists('WooCommerce') and in_array('shop_order', $export->options['cpt']) and empty($export->parent_id)) {
|
26 |
+
$queue_exports = \XmlExportWooCommerceOrder::prepare_child_exports($export, true);
|
27 |
|
28 |
if (empty($queue_exports)) {
|
29 |
delete_option('wp_all_export_queue_' . $export->id);
|
src/Scheduling/Timezone/TimezoneSelect.php
CHANGED
@@ -10,8 +10,10 @@ class TimezoneSelect
|
|
10 |
'Africa' => \DateTimeZone::AFRICA,
|
11 |
'America' => \DateTimeZone::AMERICA,
|
12 |
'Antarctica' => \DateTimeZone::ANTARCTICA,
|
|
|
13 |
'Asia' => \DateTimeZone::ASIA,
|
14 |
'Atlantic' => \DateTimeZone::ATLANTIC,
|
|
|
15 |
'Europe' => \DateTimeZone::EUROPE,
|
16 |
'Indian' => \DateTimeZone::INDIAN,
|
17 |
'Pacific' => \DateTimeZone::PACIFIC
|
10 |
'Africa' => \DateTimeZone::AFRICA,
|
11 |
'America' => \DateTimeZone::AMERICA,
|
12 |
'Antarctica' => \DateTimeZone::ANTARCTICA,
|
13 |
+
'Arctic' => \DateTimeZone::ARCTIC,
|
14 |
'Asia' => \DateTimeZone::ASIA,
|
15 |
'Atlantic' => \DateTimeZone::ATLANTIC,
|
16 |
+
'Australia' => \DateTimeZone::AUSTRALIA,
|
17 |
'Europe' => \DateTimeZone::EUROPE,
|
18 |
'Indian' => \DateTimeZone::INDIAN,
|
19 |
'Pacific' => \DateTimeZone::PACIFIC
|
src/Scheduling/views/ConnectionIcon.php
CHANGED
@@ -1,16 +1,28 @@
|
|
1 |
<?php
|
2 |
$scheduling = \Wpae\Scheduling\Scheduling::create();
|
3 |
?>
|
4 |
-
<?php if ($scheduling->
|
5 |
-
|
6 |
-
<
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
-
|
11 |
-
|
12 |
-
|
13 |
-
|
14 |
-
|
|
|
|
|
|
|
|
|
|
|
15 |
</a>
|
16 |
-
<?php
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
<?php
|
2 |
$scheduling = \Wpae\Scheduling\Scheduling::create();
|
3 |
?>
|
4 |
+
<span class="wpai-no-license" <?php if ($scheduling->checkLicense()) { ?> style="display: none;" <?php } ?> >
|
5 |
+
|
6 |
+
<a href="#" style="z-index: 1000; position: absolute; top: 1px; left: 155px; padding: 0;" class="help_scheduling tipsy"
|
7 |
+
title="Automatic Scheduling is a paid service from Soflyy. Click for more info.">
|
8 |
+
<img style="width: 16px; "
|
9 |
+
src="<?php echo PMXE_ROOT_URL; ?>/static/img/s-question.png"/>
|
10 |
+
</a>
|
11 |
+
</span>
|
12 |
+
|
13 |
+
|
14 |
+
<span class="wpai-license" <?php if (!$scheduling->checkLicense()) { ?> style="display: none;" <?php } ?> >
|
15 |
+
<?php if ( $scheduling->checkConnection() ) {
|
16 |
+
?>
|
17 |
+
<a href="#" class="help_scheduling" title="Connection to WP All Export servers is stable and confirmed"
|
18 |
+
style="z-index: 1000; position: absolute; top: 1px; left: 155px; padding: 0; width: 16px;">
|
19 |
+
<img src="<?php echo PMXE_ROOT_URL; ?>/static/img/s-check.png" style="width: 16px;"/>
|
20 |
</a>
|
21 |
+
<?php
|
22 |
+
} else { ?>
|
23 |
+
<img src="<?php echo PMXE_ROOT_URL; ?>/static/img/s-exclamation.png" style="width: 16px;"/>
|
24 |
+
|
25 |
+
<?php
|
26 |
+
}
|
27 |
+
?>
|
28 |
+
</span>
|
src/Scheduling/views/SchedulingHelp.php
CHANGED
@@ -19,7 +19,7 @@
|
|
19 |
<h3 id="wpae_help_repeating_fields_tab"><span>+</span> <?php _e('What do I get for $9 a month?', 'wp_all_export_plugin'); ?></h3>
|
20 |
|
21 |
<div rel="wpae_help_repeating_fields_tab" class="wp_all_export_help_tab" style="padding-left:8px;">
|
22 |
-
<?php _e('You\'ll receive a license key for Automatic Scheduling that you can use in WP All Export and WP All Import
|
23 |
</div>
|
24 |
|
25 |
<h3 id="wpae_help_example_template_tab">
|
19 |
<h3 id="wpae_help_repeating_fields_tab"><span>+</span> <?php _e('What do I get for $9 a month?', 'wp_all_export_plugin'); ?></h3>
|
20 |
|
21 |
<div rel="wpae_help_repeating_fields_tab" class="wp_all_export_help_tab" style="padding-left:8px;">
|
22 |
+
<?php _e('You\'ll receive a license key for Automatic Scheduling that you can use in WP All Export and WP All Import. You can set up as many imports and exports on as many sites as you like. We do ask, however, that you not share your license with anyone else.'); ?>
|
23 |
</div>
|
24 |
|
25 |
<h3 id="wpae_help_example_template_tab">
|
src/Scheduling/views/SchedulingOptions.php
CHANGED
@@ -153,7 +153,7 @@ $options = \PMXE_Plugin::getInstance()->getOption();
|
|
153 |
|
154 |
#add-subscription-field {
|
155 |
position: absolute;
|
156 |
-
left: -
|
157 |
top: -2px;
|
158 |
height: 46px;
|
159 |
border-radius: 5px;
|
@@ -188,7 +188,7 @@ $options = \PMXE_Plugin::getInstance()->getOption();
|
|
188 |
}
|
189 |
|
190 |
.chosen-container.chosen-with-drop .chosen-drop {
|
191 |
-
margin-top:
|
192 |
}
|
193 |
|
194 |
.wpallexport-preview-content h4{
|
@@ -579,6 +579,9 @@ $options = \PMXE_Plugin::getInstance()->getOption();
|
|
579 |
$('.subscribe').hide({queue: false});
|
580 |
$('#subscribe-filler').show({queue: false});
|
581 |
});
|
|
|
|
|
|
|
582 |
} else {
|
583 |
$('#subscribe-button .easing-spinner').hide();
|
584 |
$('#subscribe-button svg.error').show();
|
@@ -596,7 +599,7 @@ $options = \PMXE_Plugin::getInstance()->getOption();
|
|
596 |
|
597 |
setTimeout(function () {
|
598 |
$('#add-subscription-field').animate({width:'140px'}, 225);
|
599 |
-
$('#add-subscription-field').animate({left:'-
|
600 |
}, 300);
|
601 |
|
602 |
$('#add-subscription-field').val('');
|
@@ -656,24 +659,19 @@ $options = \PMXE_Plugin::getInstance()->getOption();
|
|
656 |
<div style="margin-bottom: 20px;">
|
657 |
<label>
|
658 |
<input type="radio" name="scheduling_enable" value="0" <?php if(!$post['scheduling_enable']) { ?> checked="checked" <?php } ?>/>
|
659 |
-
<h4 style="display: inline-block;"><?php _e('Do Not Schedule'); ?></h4>
|
660 |
</label>
|
661 |
</div>
|
662 |
<div>
|
663 |
<label>
|
664 |
<input type="radio" name="scheduling_enable" value="1" <?php if($post['scheduling_enable'] == 1) {?> checked="checked" <?php }?>/>
|
665 |
-
|
666 |
-
|
667 |
-
|
668 |
-
|
669 |
-
|
670 |
-
|
671 |
-
|
672 |
-
<span <?php if(!$scheduling->checkConnection() && $scheduling->checkLicense() ) { ?> style="color: #f2b03d;" <?php } ?>>Unable to connect to the scheduling Service. Please contact support at</span>
|
673 |
-
<a style="text-decoration: underline; color: #0073aa;"
|
674 |
-
href="http://wpallimport.com/support"
|
675 |
-
target="_blank">http://wpallimport.com/support</a>
|
676 |
-
</span>
|
677 |
<?php } ?>
|
678 |
</h4>
|
679 |
</label>
|
153 |
|
154 |
#add-subscription-field {
|
155 |
position: absolute;
|
156 |
+
left: -155px;
|
157 |
top: -2px;
|
158 |
height: 46px;
|
159 |
border-radius: 5px;
|
188 |
}
|
189 |
|
190 |
.chosen-container.chosen-with-drop .chosen-drop {
|
191 |
+
margin-top: 0 !important;
|
192 |
}
|
193 |
|
194 |
.wpallexport-preview-content h4{
|
579 |
$('.subscribe').hide({queue: false});
|
580 |
$('#subscribe-filler').show({queue: false});
|
581 |
});
|
582 |
+
|
583 |
+
$('.wpai-no-license').hide();
|
584 |
+
$('.wpai-license').show();
|
585 |
} else {
|
586 |
$('#subscribe-button .easing-spinner').hide();
|
587 |
$('#subscribe-button svg.error').show();
|
599 |
|
600 |
setTimeout(function () {
|
601 |
$('#add-subscription-field').animate({width:'140px'}, 225);
|
602 |
+
$('#add-subscription-field').animate({left:'-155px'}, 225);
|
603 |
}, 300);
|
604 |
|
605 |
$('#add-subscription-field').val('');
|
659 |
<div style="margin-bottom: 20px;">
|
660 |
<label>
|
661 |
<input type="radio" name="scheduling_enable" value="0" <?php if(!$post['scheduling_enable']) { ?> checked="checked" <?php } ?>/>
|
662 |
+
<h4 style="display: inline-block; margin-top:3px; margin-bottom:-2px;"><?php _e('Do Not Schedule'); ?></h4>
|
663 |
</label>
|
664 |
</div>
|
665 |
<div>
|
666 |
<label>
|
667 |
<input type="radio" name="scheduling_enable" value="1" <?php if($post['scheduling_enable'] == 1) {?> checked="checked" <?php }?>/>
|
668 |
+
|
669 |
+
<h4 style="margin: 0; position: relative; display: inline-block;"><?php _e('Automatic Scheduling', PMXE_Plugin::LANGUAGE_DOMAIN); ?>
|
670 |
+
<span class="connection-icon">
|
671 |
+
<?php include_once('ConnectionIcon.php'); ?>
|
672 |
+
</span>
|
673 |
+
<?php if (!$scheduling->checkConnection()) { ?>
|
674 |
+
<span class="wpai-license wpai-license-text" style="display: inline-block; font-weight: normal; <?php if(!$hasActiveLicense) { ?> display: none; <?php }?> color: #f2b03d; ">Unable to connect - <a target="_blank" style="text-decoration: underline;" href="http://wpallimport.com/support">please contact support</a>.</span>
|
|
|
|
|
|
|
|
|
|
|
675 |
<?php } ?>
|
676 |
</h4>
|
677 |
</label>
|
src/Scheduling/views/SchedulingUI.php
CHANGED
@@ -463,13 +463,16 @@ $export_id = $export->id;
|
|
463 |
$('#subscribe-button .button-subscribe').css('background-color','#425f9a');
|
464 |
if(response.success) {
|
465 |
hasActiveLicense = true;
|
466 |
-
$('.wpae-save-button').
|
467 |
$('#subscribe-button .easing-spinner').hide();
|
468 |
$('#subscribe-button svg.success').show();
|
469 |
$('#subscribe-button svg.success').fadeOut(3000, function () {
|
470 |
$('.subscribe').hide({queue: false});
|
471 |
$('#subscribe-filler').show({queue: false});
|
472 |
});
|
|
|
|
|
|
|
473 |
} else {
|
474 |
$('#subscribe-button .easing-spinner').hide();
|
475 |
$('#subscribe-button svg.error').show();
|
@@ -486,7 +489,7 @@ $export_id = $export->id;
|
|
486 |
|
487 |
setTimeout(function () {
|
488 |
$('#add-subscription-field').animate({width:'140px'}, 225);
|
489 |
-
$('#add-subscription-field').animate({left:'-
|
490 |
}, 300);
|
491 |
|
492 |
$('#add-subscription-field').val('');
|
@@ -544,17 +547,12 @@ $export_id = $export->id;
|
|
544 |
<div>
|
545 |
<label>
|
546 |
<input type="radio" name="scheduling_enable" value="1" <?php if($post['scheduling_enable'] == 1) {?> checked="checked" <?php }?>/>
|
547 |
-
<h4 style="margin
|
548 |
-
<span class="connection-icon" style="
|
549 |
-
|
550 |
-
|
551 |
-
<?php if (!$scheduling->checkConnection()
|
552 |
-
<span
|
553 |
-
<span <?php if(!$scheduling->checkConnection() && $scheduling->checkLicense() ) { ?> style="color: #f2b03d;" <?php } ?>>Unable to connect -</span>
|
554 |
-
<a style="text-decoration: underline; color: #0073aa;"
|
555 |
-
href="http://wpallimport.com/support"
|
556 |
-
target="_blank">please contact support</a>.
|
557 |
-
</span>
|
558 |
<?php } ?>
|
559 |
</h4>
|
560 |
</label>
|
@@ -738,8 +736,8 @@ $export_id = $export->id;
|
|
738 |
<div style="clear: both;"></div>
|
739 |
</div>
|
740 |
|
741 |
-
<div class="wpae-save-button button button-primary button-hero wpallexport-large-button wpae-export-complete-save-button
|
742 |
-
style="position: relative; width: 285px; display: block; margin:auto; background-image: none; margin-top: 25px;">
|
743 |
<svg width="30" height="30" viewBox="0 0 1792 1792"
|
744 |
xmlns="http://www.w3.org/2000/svg"
|
745 |
style="fill: white;">
|
463 |
$('#subscribe-button .button-subscribe').css('background-color','#425f9a');
|
464 |
if(response.success) {
|
465 |
hasActiveLicense = true;
|
466 |
+
$('.wpae-save-button').slideDown().css('display','block');
|
467 |
$('#subscribe-button .easing-spinner').hide();
|
468 |
$('#subscribe-button svg.success').show();
|
469 |
$('#subscribe-button svg.success').fadeOut(3000, function () {
|
470 |
$('.subscribe').hide({queue: false});
|
471 |
$('#subscribe-filler').show({queue: false});
|
472 |
});
|
473 |
+
|
474 |
+
$('.wpai-no-license').hide();
|
475 |
+
$('.wpai-license').show();
|
476 |
} else {
|
477 |
$('#subscribe-button .easing-spinner').hide();
|
478 |
$('#subscribe-button svg.error').show();
|
489 |
|
490 |
setTimeout(function () {
|
491 |
$('#add-subscription-field').animate({width:'140px'}, 225);
|
492 |
+
$('#add-subscription-field').animate({left:'-155px'}, 225);
|
493 |
}, 300);
|
494 |
|
495 |
$('#add-subscription-field').val('');
|
547 |
<div>
|
548 |
<label>
|
549 |
<input type="radio" name="scheduling_enable" value="1" <?php if($post['scheduling_enable'] == 1) {?> checked="checked" <?php }?>/>
|
550 |
+
<h4 style="margin: 0; position: relative; display: inline-block;"><?php _e('Automatic Scheduling', PMXE_Plugin::LANGUAGE_DOMAIN); ?>
|
551 |
+
<span class="connection-icon" style="">
|
552 |
+
<?php include_once('ConnectionIcon.php'); ?>
|
553 |
+
</span>
|
554 |
+
<?php if (!$scheduling->checkConnection()) { ?>
|
555 |
+
<span class="wpai-license wpai-license-text" style="display: inline-block; font-weight: normal; <?php if(!$hasActiveLicense) { ?> display: none; <?php }?> color: #f2b03d; ">Unable to connect - <a target="_blank" style="text-decoration: underline;" href="http://wpallimport.com/support">please contact support</a>.</span>
|
|
|
|
|
|
|
|
|
|
|
556 |
<?php } ?>
|
557 |
</h4>
|
558 |
</label>
|
736 |
<div style="clear: both;"></div>
|
737 |
</div>
|
738 |
|
739 |
+
<div class="wpae-save-button button button-primary button-hero wpallexport-large-button wpae-export-complete-save-button" id="save-scheduling-button"
|
740 |
+
style="position: relative; width: 285px; <?php if($hasActiveLicense) { echo 'display: block;';} else { echo "display: none;";}?> margin:auto; background-image: none; margin-top: 25px;">
|
741 |
<svg width="30" height="30" viewBox="0 0 1792 1792"
|
742 |
xmlns="http://www.w3.org/2000/svg"
|
743 |
style="fill: white;">
|
static/css/admin.css
CHANGED
@@ -298,6 +298,15 @@
|
|
298 |
.wpallexport-plugin #available_data ul li .pmxe_remove_column{
|
299 |
display: none;
|
300 |
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
301 |
.wpallexport-plugin .wpae-available-fields-group{
|
302 |
background: none repeat scroll 0 0 white;
|
303 |
border: 1px dotted #ccc;
|
@@ -2801,7 +2810,7 @@ a.wpallexport-import-to-format span.wpallexport-import-to-title {
|
|
2801 |
}
|
2802 |
.wpallexport-plugin form.options{
|
2803 |
position: relative;
|
2804 |
-
margin-top:
|
2805 |
overflow: hidden;
|
2806 |
}
|
2807 |
.wpallexport-plugin form.edit{
|
@@ -3493,7 +3502,7 @@ a.wpallexport-import-to-format span.wpallexport-import-to-title {
|
|
3493 |
}
|
3494 |
|
3495 |
.wpallexport-plugin .delete_action{
|
3496 |
-
left:
|
3497 |
bottom: 14px;
|
3498 |
background: #e14d43;
|
3499 |
margin-left: 5px;
|
298 |
.wpallexport-plugin #available_data ul li .pmxe_remove_column{
|
299 |
display: none;
|
300 |
}
|
301 |
+
|
302 |
+
.wpallexport-plugin span.wpai-license-text {
|
303 |
+
margin-left: 20px;
|
304 |
+
}
|
305 |
+
|
306 |
+
.wpallexport-plugin .wpai-license img {
|
307 |
+
position: absolute;
|
308 |
+
}
|
309 |
+
|
310 |
.wpallexport-plugin .wpae-available-fields-group{
|
311 |
background: none repeat scroll 0 0 white;
|
312 |
border: 1px dotted #ccc;
|
2810 |
}
|
2811 |
.wpallexport-plugin form.options{
|
2812 |
position: relative;
|
2813 |
+
margin-top: 0 !important;
|
2814 |
overflow: hidden;
|
2815 |
}
|
2816 |
.wpallexport-plugin form.edit{
|
3502 |
}
|
3503 |
|
3504 |
.wpallexport-plugin .delete_action{
|
3505 |
+
left: 113px;
|
3506 |
bottom: 14px;
|
3507 |
background: #e14d43;
|
3508 |
margin-left: 5px;
|
static/js/admin.js
CHANGED
@@ -36,6 +36,9 @@
|
|
36 |
function selectSpreadsheet()
|
37 |
{
|
38 |
vm.isGoogleMerchantsExport = false;
|
|
|
|
|
|
|
39 |
resetDraggable();
|
40 |
angular.element(document.getElementById('googleMerchants')).injector().get('$rootScope').$broadcast('googleMerchantsDeselected');
|
41 |
$('.wpallexport-custom-xml-template').slideUp();
|
@@ -200,6 +203,7 @@
|
|
200 |
|
201 |
$('.export_variations').change(function(){
|
202 |
setTimeout(liveFiltering, 200);
|
|
|
203 |
if ($(this).val() == 3){
|
204 |
$('.warning-only-export-parent-products').show();
|
205 |
}
|
@@ -228,7 +232,7 @@
|
|
228 |
}, 10);
|
229 |
|
230 |
// help icons
|
231 |
-
|
232 |
gravity: function() {
|
233 |
var ver = 'n';
|
234 |
if ($(document).scrollTop() < $(this).offset().top - $('.tipsy').height() - 2) {
|
@@ -259,8 +263,7 @@
|
|
259 |
mode: "application/x-httpd-php",
|
260 |
indentUnit: 4,
|
261 |
indentWithTabs: true,
|
262 |
-
lineWrapping: true
|
263 |
-
autoRefresh: true
|
264 |
});
|
265 |
editor.setCursor(1);
|
266 |
|
@@ -671,7 +674,9 @@
|
|
671 |
data: request,
|
672 |
success: function(response) {
|
673 |
|
674 |
-
|
|
|
|
|
675 |
if(vm.hasVariations) {
|
676 |
|
677 |
if($('#export_to_sheet').val() == 'xls' || $('#export_to_sheet').val() == 'xlsx') {
|
@@ -942,6 +947,14 @@
|
|
942 |
});
|
943 |
|
944 |
$('a.auto-generate-template').live('click', function(){
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
945 |
$('input[name^=auto_generate]').val('1');
|
946 |
|
947 |
$('.hierarhy-output').each(function(){
|
@@ -1348,6 +1361,11 @@
|
|
1348 |
// set up additional element settings by element type
|
1349 |
switch ( $fieldType )
|
1350 |
{
|
|
|
|
|
|
|
|
|
|
|
1351 |
// save post date field format
|
1352 |
case 'date':
|
1353 |
case 'comment_date':
|
@@ -1495,6 +1513,18 @@
|
|
1495 |
if ($elementLabel.val() == '_sale_price_dates_from' || $elementLabel.val() == '_sale_price_dates_to') $fieldType = 'date';
|
1496 |
|
1497 |
switch ( $fieldType ){
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1498 |
case 'sql':
|
1499 |
$addAnotherForm.find('textarea.column_value').val($(this).find('input[name^=cc_sql]').val());
|
1500 |
$addAnotherForm.find('.sql_field_type').show();
|
@@ -2136,6 +2166,18 @@
|
|
2136 |
});
|
2137 |
// [ \Step 3 ( export options ) ]
|
2138 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2139 |
|
2140 |
// [ Step 4 ( export completed ) ]
|
2141 |
$('.download_data').click(function(){
|
@@ -2697,4 +2739,7 @@
|
|
2697 |
isValid: true
|
2698 |
};
|
2699 |
};
|
|
|
|
|
|
|
2700 |
});})(jQuery, window.EventService);
|
36 |
function selectSpreadsheet()
|
37 |
{
|
38 |
vm.isGoogleMerchantsExport = false;
|
39 |
+
if(vm.availableDataSelector.css('position') == 'fixed') {
|
40 |
+
$('.template-sidebar').find('.wpae_available_data').css({'position': 'static', 'top': '50px'});
|
41 |
+
}
|
42 |
resetDraggable();
|
43 |
angular.element(document.getElementById('googleMerchants')).injector().get('$rootScope').$broadcast('googleMerchantsDeselected');
|
44 |
$('.wpallexport-custom-xml-template').slideUp();
|
203 |
|
204 |
$('.export_variations').change(function(){
|
205 |
setTimeout(liveFiltering, 200);
|
206 |
+
$('.wp-all-export-product-bundle-warning').hide();
|
207 |
if ($(this).val() == 3){
|
208 |
$('.warning-only-export-parent-products').show();
|
209 |
}
|
232 |
}, 10);
|
233 |
|
234 |
// help icons
|
235 |
+
$('.wpallexport-help, .help_scheduling').tipsy({
|
236 |
gravity: function() {
|
237 |
var ver = 'n';
|
238 |
if ($(document).scrollTop() < $(this).offset().top - $('.tipsy').height() - 2) {
|
263 |
mode: "application/x-httpd-php",
|
264 |
indentUnit: 4,
|
265 |
indentWithTabs: true,
|
266 |
+
lineWrapping: true
|
|
|
267 |
});
|
268 |
editor.setCursor(1);
|
269 |
|
674 |
data: request,
|
675 |
success: function(response) {
|
676 |
|
677 |
+
$('.wpae-record-count').val(response.found_records);
|
678 |
+
|
679 |
+
vm.hasVariations = response.hasVariations;
|
680 |
if(vm.hasVariations) {
|
681 |
|
682 |
if($('#export_to_sheet').val() == 'xls' || $('#export_to_sheet').val() == 'xlsx') {
|
947 |
});
|
948 |
|
949 |
$('a.auto-generate-template').live('click', function(){
|
950 |
+
|
951 |
+
var export_type = $('input[name="cpt"]').val();
|
952 |
+
|
953 |
+
if(export_type == 'shop_order') {
|
954 |
+
$('#migrate-orders-notice').slideDown();
|
955 |
+
return;
|
956 |
+
}
|
957 |
+
|
958 |
$('input[name^=auto_generate]').val('1');
|
959 |
|
960 |
$('.hierarhy-output').each(function(){
|
1361 |
// set up additional element settings by element type
|
1362 |
switch ( $fieldType )
|
1363 |
{
|
1364 |
+
case 'content':
|
1365 |
+
var obj = {};
|
1366 |
+
obj['export_images_from_gallery'] = $addAnotherForm.find('#export_images_from_gallery').is(':checked');
|
1367 |
+
$clone.find('input[name^=cc_settings]').val(window.JSON.stringify(obj));
|
1368 |
+
break;
|
1369 |
// save post date field format
|
1370 |
case 'date':
|
1371 |
case 'comment_date':
|
1513 |
if ($elementLabel.val() == '_sale_price_dates_from' || $elementLabel.val() == '_sale_price_dates_to') $fieldType = 'date';
|
1514 |
|
1515 |
switch ( $fieldType ){
|
1516 |
+
case 'content':
|
1517 |
+
$addAnotherForm.find('.content_field_type').show();
|
1518 |
+
if ($settings != "" && $settings != 0)
|
1519 |
+
{
|
1520 |
+
var $field_options = window.JSON.parse($settings);
|
1521 |
+
if ($field_options.export_images_from_gallery) $addAnotherForm.find('#export_images_from_gallery').attr('checked','checked');
|
1522 |
+
}
|
1523 |
+
else{
|
1524 |
+
// this option should be enabled by default
|
1525 |
+
$addAnotherForm.find('#export_images_from_gallery').attr('checked','checked');
|
1526 |
+
}
|
1527 |
+
break;
|
1528 |
case 'sql':
|
1529 |
$addAnotherForm.find('textarea.column_value').val($(this).find('input[name^=cc_sql]').val());
|
1530 |
$addAnotherForm.find('.sql_field_type').show();
|
2166 |
});
|
2167 |
// [ \Step 3 ( export options ) ]
|
2168 |
|
2169 |
+
$('#download-bundle').click(function(e){
|
2170 |
+
|
2171 |
+
var exportCpt = $('#export-cpt').val();
|
2172 |
+
|
2173 |
+
if(exportCpt == 'shop_order') {
|
2174 |
+
|
2175 |
+
$('#migrate-orders-notice').slideDown();
|
2176 |
+
e.preventDefault();
|
2177 |
+
e.stopImmediatePropagation();
|
2178 |
+
return false;
|
2179 |
+
}
|
2180 |
+
});
|
2181 |
|
2182 |
// [ Step 4 ( export completed ) ]
|
2183 |
$('.download_data').click(function(){
|
2739 |
isValid: true
|
2740 |
};
|
2741 |
};
|
2742 |
+
|
2743 |
+
|
2744 |
+
|
2745 |
});})(jQuery, window.EventService);
|
views/admin/export/options.php
CHANGED
@@ -46,14 +46,29 @@ $l10n = array(
|
|
46 |
<h3> </h3>
|
47 |
<div class="wp_all_export_preloader"></div>
|
48 |
</div>
|
49 |
-
<?php if ($this->isWizard): ?>
|
50 |
-
<form class="confirm <?php echo ! $this->isWizard ? 'edit' : '' ?>" method="post" style="float:right;">
|
51 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
52 |
<?php wp_nonce_field('options', '_wpnonce_options') ?>
|
53 |
-
<input type="hidden" name="is_submitted" value="1" />
|
|
|
54 |
|
55 |
-
|
56 |
-
|
57 |
<?php endif; ?>
|
58 |
</div>
|
59 |
|
@@ -63,7 +78,7 @@ $l10n = array(
|
|
63 |
|
64 |
<input type="hidden" class="hierarhy-output" name="filter_rules_hierarhy" value="<?php echo esc_html($post['filter_rules_hierarhy']);?>"/>
|
65 |
|
66 |
-
<?php
|
67 |
$selected_post_type = '';
|
68 |
if (XmlExportUser::$is_active):
|
69 |
$selected_post_type = empty($post['cpt'][0]) ? 'users' : $post['cpt'][0];
|
@@ -82,6 +97,7 @@ $l10n = array(
|
|
82 |
<input type="hidden" name="taxonomy_to_export" value="<?php echo $post['taxonomy_to_export'];?>">
|
83 |
<input type="hidden" name="wpml_lang" value="<?php echo empty(PMXE_Plugin::$session->wpml_lang) ? $post['wpml_lang'] : PMXE_Plugin::$session->wpml_lang;?>" />
|
84 |
<input type="hidden" id="export_variations" name="export_variations" value="<?php echo XmlExportEngine::getProductVariationMode();?>" />
|
|
|
85 |
|
86 |
<?php //\Wpae\Pro\Filtering\FilteringFactory::render_filtering_block( $engine, $this->isWizard, $post ); ?>
|
87 |
|
@@ -92,7 +108,12 @@ $l10n = array(
|
|
92 |
|
93 |
<?php wp_nonce_field('options', '_wpnonce_options') ?>
|
94 |
<input type="hidden" name="is_submitted" value="1" />
|
95 |
-
|
|
|
|
|
|
|
|
|
|
|
96 |
<div class="wpallexport-submit-buttons" style="text-align: center; <?php if ($this->isWizard) { ?> height: 60px; <?php } ?> ">
|
97 |
|
98 |
<?php if ($this->isWizard): ?>
|
46 |
<h3> </h3>
|
47 |
<div class="wp_all_export_preloader"></div>
|
48 |
</div>
|
49 |
+
<?php if ($this->isWizard): ?>
|
50 |
+
<form class="confirm <?php echo ! $this->isWizard ? 'edit' : '' ?>" method="post" style="float:right;">
|
51 |
+
<div style="position: relative;" class="wpae-scheduling-status">
|
52 |
+
|
53 |
+
<div class="easing-spinner" style="position: absolute; top: 7px; left: 35px; display: none;">
|
54 |
+
<div class="double-bounce1"></div>
|
55 |
+
<div class="double-bounce2"></div>
|
56 |
+
</div>
|
57 |
+
|
58 |
+
<svg width="30" height="30" viewBox="0 0 1792 1792"
|
59 |
+
xmlns="http://www.w3.org/2000/svg"
|
60 |
+
style="fill: white; position: absolute; top: 14px; left: 15px; display: none;">
|
61 |
+
<path
|
62 |
+
d="M1671 566q0 40-28 68l-724 724-136 136q-28 28-68 28t-68-28l-136-136-362-362q-28-28-28-68t28-68l136-136q28-28 68-28t68 28l294 295 656-657q28-28 68-28t68 28l136 136q28 28 28 68z"
|
63 |
+
fill="white"/>
|
64 |
+
</svg>
|
65 |
+
</div>
|
66 |
<?php wp_nonce_field('options', '_wpnonce_options') ?>
|
67 |
+
<input type="hidden" name="is_submitted" value="1" />
|
68 |
+
<input type="hidden" name="record-count" class="wpae-record-count" value="0" />
|
69 |
|
70 |
+
<input style="padding:20px 50px 20px 50px;" type="submit" class="rad10 wp_all_export_confirm_and_run" value="<?php _e('Confirm & Run Export', 'wp_all_export_plugin') ?>" />
|
71 |
+
</form>
|
72 |
<?php endif; ?>
|
73 |
</div>
|
74 |
|
78 |
|
79 |
<input type="hidden" class="hierarhy-output" name="filter_rules_hierarhy" value="<?php echo esc_html($post['filter_rules_hierarhy']);?>"/>
|
80 |
|
81 |
+
<?php
|
82 |
$selected_post_type = '';
|
83 |
if (XmlExportUser::$is_active):
|
84 |
$selected_post_type = empty($post['cpt'][0]) ? 'users' : $post['cpt'][0];
|
97 |
<input type="hidden" name="taxonomy_to_export" value="<?php echo $post['taxonomy_to_export'];?>">
|
98 |
<input type="hidden" name="wpml_lang" value="<?php echo empty(PMXE_Plugin::$session->wpml_lang) ? $post['wpml_lang'] : PMXE_Plugin::$session->wpml_lang;?>" />
|
99 |
<input type="hidden" id="export_variations" name="export_variations" value="<?php echo XmlExportEngine::getProductVariationMode();?>" />
|
100 |
+
<input type="hidden" name="record-count" class="wpae-record-count" value="0" />
|
101 |
|
102 |
<?php //\Wpae\Pro\Filtering\FilteringFactory::render_filtering_block( $engine, $this->isWizard, $post ); ?>
|
103 |
|
108 |
|
109 |
<?php wp_nonce_field('options', '_wpnonce_options') ?>
|
110 |
<input type="hidden" name="is_submitted" value="1" />
|
111 |
+
<div style="color: #425F9A; font-size: 14px; font-weight: bold; margin: 0 0 15px; line-height: 25px; text-align: center;">
|
112 |
+
<div id="no-subscription" style="display: none;">
|
113 |
+
<?php echo _e("Looks like you're trying out Automatic Scheduling!");?><br/>
|
114 |
+
<?php echo _e("Your Automatic Scheduling settings won't be saved without a subscription.");?>
|
115 |
+
</div>
|
116 |
+
</div>
|
117 |
<div class="wpallexport-submit-buttons" style="text-align: center; <?php if ($this->isWizard) { ?> height: 60px; <?php } ?> ">
|
118 |
|
119 |
<?php if ($this->isWizard): ?>
|
views/admin/export/process.php
CHANGED
@@ -37,7 +37,7 @@
|
|
37 |
</div>
|
38 |
</div>
|
39 |
<?php
|
40 |
-
if (XmlExportWooCommerceOrder::$is_active && $update_previous->options['export_type'] == 'specific')
|
41 |
|
42 |
$exportList = new PMXE_Export_List();
|
43 |
foreach ($exportList->getBy('parent_id', $update_previous->id)->convertRecords() as $child_export) {
|
@@ -59,7 +59,7 @@
|
|
59 |
?>
|
60 |
<div class="clear"></div>
|
61 |
<div
|
62 |
-
|
63 |
<div class="wpallexport_processbar rad14">
|
64 |
<div class="rad14"></div>
|
65 |
</div>
|
@@ -67,44 +67,29 @@
|
|
67 |
<span class="left_progress">
|
68 |
<span class="center_progress">
|
69 |
<span
|
70 |
-
|
71 |
<span class="right_progress"><?php _e('Exported', 'wp_all_export_plugin'); ?> <span
|
72 |
-
|
73 |
</div>
|
74 |
</div>
|
75 |
<?php
|
76 |
}
|
77 |
|
78 |
-
|
79 |
-
?>
|
80 |
</div>
|
81 |
|
82 |
-
<
|
83 |
-
|
84 |
-
|
85 |
-
|
86 |
-
|
87 |
-
|
88 |
-
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
</div>
|
95 |
-
<?php endif; ?>
|
96 |
-
<?php if (PMXE_Export_Record::is_bundle_supported($update_previous->options)): ?>
|
97 |
-
<div class="input" style="margin-left: 10px;">
|
98 |
-
<button class="button button-primary button-hero wpallexport-large-button download_data"
|
99 |
-
rel="<?php echo add_query_arg(array('page' => 'pmxe-admin-manage', 'id' => $update_previous->id, 'action' => 'bundle', '_wpnonce' => wp_create_nonce('_wpnonce-download_bundle')), $this->baseUrl); ?>"><?php _e('Bundle', 'wp_all_export_plugin'); ?></button>
|
100 |
-
<span><?php _e('Settings & Data for WP All Import', 'wp_all_export_plugin'); ?></span>
|
101 |
-
</div>
|
102 |
-
<?php endif; ?>
|
103 |
-
</div>
|
104 |
-
<hr>
|
105 |
-
<a href="<?php echo add_query_arg(array('page' => 'pmxe-admin-manage'), remove_query_arg(array('id', 'page'), $this->baseUrl)); ?>"
|
106 |
-
id="manage_imports"><?php _e('Manage Exports', 'wp_all_export_plugin') ?></a>
|
107 |
-
</div>
|
108 |
|
109 |
</div>
|
110 |
|
@@ -252,6 +237,4 @@
|
|
252 |
|
253 |
});
|
254 |
})(jQuery);
|
255 |
-
|
256 |
-
//]]>
|
257 |
</script>
|
37 |
</div>
|
38 |
</div>
|
39 |
<?php
|
40 |
+
if (XmlExportWooCommerceOrder::$is_active && $update_previous->options['export_type'] == 'specific') {
|
41 |
|
42 |
$exportList = new PMXE_Export_List();
|
43 |
foreach ($exportList->getBy('parent_id', $update_previous->id)->convertRecords() as $child_export) {
|
59 |
?>
|
60 |
<div class="clear"></div>
|
61 |
<div
|
62 |
+
class="wpallexport_process_wrapper_<?php echo $child_export->id; ?> wpallexport_process_child_wrapper">
|
63 |
<div class="wpallexport_processbar rad14">
|
64 |
<div class="rad14"></div>
|
65 |
</div>
|
67 |
<span class="left_progress">
|
68 |
<span class="center_progress">
|
69 |
<span
|
70 |
+
class="percents_count">0</span>%</span> <?php printf(__("Export %ss", "wp_all_export_plugin"), ucwords(str_replace("_", " ", str_replace("shop", "", $child_export->export_post_type)))); ?></span>
|
71 |
<span class="right_progress"><?php _e('Exported', 'wp_all_export_plugin'); ?> <span
|
72 |
+
class="created_count">0</span></span>
|
73 |
</div>
|
74 |
</div>
|
75 |
<?php
|
76 |
}
|
77 |
|
78 |
+
} ?>
|
|
|
79 |
</div>
|
80 |
|
81 |
+
<span id="wpallexport-error-terminated" style="display: none;">
|
82 |
+
<div class="wpallexport-content-section" style="display:block; position: relative;">
|
83 |
+
<div class="wpallexport-notify-wrapper">
|
84 |
+
<div class="found_records terminated" style="background-position: 0 50% !important;">
|
85 |
+
<h3><?php _e('Your server terminated the export process', 'wp_all_export_plugin'); ?></h3>
|
86 |
+
<h4 style="width: 78%; line-height: 25px;"><?php _e("Ask your host to check your server's error log. They will be able to determine why your server is terminating the export process.", "wp_all_export_plugin"); ?></h4>
|
87 |
+
</div>
|
88 |
+
</div>
|
89 |
+
</div>
|
90 |
+
</span>
|
91 |
+
<?php include ('success_page.php'); ?>
|
92 |
+
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
93 |
|
94 |
</div>
|
95 |
|
237 |
|
238 |
});
|
239 |
})(jQuery);
|
|
|
|
|
240 |
</script>
|
views/admin/export/success_page.php
ADDED
@@ -0,0 +1,132 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
$cron_job_key = PMXE_Plugin::getInstance()->getOption('cron_job_key');
|
3 |
+
$urlToExport = site_url() . '/wp-cron.php?security_token=' . substr(md5($cron_job_key . $update_previous->id), 0, 16) . '&export_id=' . $update_previous->id . '&action=get_data';
|
4 |
+
$uploads = wp_upload_dir();
|
5 |
+
|
6 |
+
$bundle_path = wp_all_export_get_absolute_path($update_previous->options['bundlepath']);
|
7 |
+
|
8 |
+
if (!empty($bundle_path)) {
|
9 |
+
$bundle_url = site_url() . '/wp-cron.php?security_token=' . substr(md5($cron_job_key . $update_previous->id), 0, 16) . '&export_id=' . $update_previous->id . '&action=get_bundle&t=zip';
|
10 |
+
}
|
11 |
+
|
12 |
+
$isImportAllowedSpecification = new \Wpae\App\Specification\IsImportAllowed();
|
13 |
+
$isGoogleFeed = false;
|
14 |
+
?>
|
15 |
+
<div id="export_finished" style="padding-top: 10px;">
|
16 |
+
<?php
|
17 |
+
if ($isGoogleFeed) {
|
18 |
+
?>
|
19 |
+
<h3><?php _e('WP All Export successfully exported your data!', 'wp_all_export_plugin'); ?></h3>
|
20 |
+
<?php
|
21 |
+
$cronJobKey = PMXE_Plugin::getInstance()->getOption('cron_job_key');
|
22 |
+
include_once('google_merchants_success.php');
|
23 |
+
} else {
|
24 |
+
?>
|
25 |
+
<h2 style="color:#425f9a; font-size:24px; margin-bottom: 36px;">What's next?</h2>
|
26 |
+
|
27 |
+
<script type="text/javascript">
|
28 |
+
jQuery(document).ready(function () {
|
29 |
+
jQuery('.success-tabs .tab').click(function () {
|
30 |
+
jQuery('.success-tabs .tab').removeClass('selected');
|
31 |
+
jQuery(this).addClass('selected');
|
32 |
+
var rel = jQuery(this).attr('rel');
|
33 |
+
jQuery('.tab-content').removeClass('selected');
|
34 |
+
jQuery('.tab-content-container').find('#' + rel).addClass('selected');
|
35 |
+
});
|
36 |
+
});
|
37 |
+
</script>
|
38 |
+
<ul class="success-tabs">
|
39 |
+
<li rel="tab1-content" class="tab selected"><?php _e("Download", 'wp_all_export_plugin'); ?></li>
|
40 |
+
<li rel="tab2-content" class="tab"><?php _e("Scheduling", 'wp_all_export_plugin'); ?></li>
|
41 |
+
<li rel="tab3-content" class="tab"><?php _e("External Apps", 'wp_all_export_plugin'); ?></li>
|
42 |
+
<?php if ($isImportAllowedSpecification->isSatisfied($update_previous)): ?>
|
43 |
+
<li rel="tab4-content" class="tab"><?php _e("Export, Edit, Import", 'wp_all_export_plugin'); ?></li>
|
44 |
+
<?php endif; ?>
|
45 |
+
</ul>
|
46 |
+
<hr style="margin-top:0;"/>
|
47 |
+
<div class="tab-content-container">
|
48 |
+
<div class="tab-content selected normal-tab" id="tab1-content">
|
49 |
+
<h3 style="margin-top: 30px; margin-bottom: 30px;"><?php _e("Click to Download", 'wp_all_export_plugin'); ?></h3>
|
50 |
+
|
51 |
+
<div class="wpallexport-free-edition-notice" id="migrate-orders-notice" style="padding: 20px; margin-bottom: 35px; display: none;">
|
52 |
+
<a class="upgrade_link" target="_blank" href="https://www.wpallimport.com/checkout/?edd_action=add_to_cart&download_id=118611&edd_options%5Bprice_id%5D=1&utm_source=wordpress.org&utm_medium=migrate+orders&utm_campaign=free+wp+all+export+plugin"><?php _e('Upgrade to the Pro edition of WP All Export to Migrate Orders', PMXE_Plugin::LANGUAGE_DOMAIN);?></a>
|
53 |
+
<p><?php _e('If you already own it, remove the free edition and install the Pro edition.', PMXE_Plugin::LANGUAGE_DOMAIN);?></p>
|
54 |
+
</div>
|
55 |
+
|
56 |
+
<div class="input">
|
57 |
+
<button class="button button-primary button-hero wpallexport-large-button download_data"
|
58 |
+
rel="<?php echo add_query_arg(array('action' => 'download', 'id' => $update_previous->id, '_wpnonce' => wp_create_nonce('_wpnonce-download_feed')), $this->baseUrl); ?>"><?php echo strtoupper(wp_all_export_get_export_format($update_previous->options)); ?></button>
|
59 |
+
<?php if (!empty($update_previous->options['split_large_exports'])): ?>
|
60 |
+
<button class="button button-primary button-hero wpallexport-large-button download_data"
|
61 |
+
rel="<?php echo add_query_arg(array('page' => 'pmxe-admin-manage', 'id' => $update_previous->id, 'action' => 'split_bundle', '_wpnonce' => wp_create_nonce('_wpnonce-download_split_bundle')), $this->baseUrl); ?>"><?php printf(__('Split %ss', 'wp_all_export_plugin'), strtoupper(wp_all_export_get_export_format($update_previous->options))); ?></button>
|
62 |
+
<?php endif; ?>
|
63 |
+
<?php if (PMXE_Export_Record::is_bundle_supported($update_previous->options)): ?>
|
64 |
+
<button class="button button-primary button-hero wpallexport-large-button download_data"
|
65 |
+
id="download-bundle" rel="<?php echo add_query_arg(array('page' => 'pmxe-admin-manage', 'id' => $update_previous->id, 'action' => 'bundle', '_wpnonce' => wp_create_nonce('_wpnonce-download_bundle')), $this->baseUrl); ?>"><?php _e('Bundle', 'wp_all_export_plugin'); ?></button>
|
66 |
+
<?php endif; ?>
|
67 |
+
</div>
|
68 |
+
|
69 |
+
<?php if (PMXE_Export_Record::is_bundle_supported($update_previous->options)): ?>
|
70 |
+
<div id="download-details">
|
71 |
+
<p style="margin-top:30px;">
|
72 |
+
<?php _e("The bundle contains your exported data and a settings file for WP All Import.", 'wp_all_export_plugin'); ?><br/>
|
73 |
+
<?php _e("Upload the Bundle to WP All Import on another site to quickly import this data.", 'wp_all_export_plugin');?>
|
74 |
+
</p>
|
75 |
+
</div>
|
76 |
+
<?php endif; ?>
|
77 |
+
<div style="margin-top:30px;">
|
78 |
+
<h3 style="margin-bottom: 0; margin-top: -10px;"><?php echo _e("Public URL", 'wp_all_export_plugin'); ?></h3>
|
79 |
+
<a href="<?php echo $urlToExport; ?>" <?php if (php_sapi_name() != 'cli-server') { ?> target="_blank" <?php } ?>
|
80 |
+
class="feed-url" style="margin-bottom: 0; font-size: 16px;"><?php echo $urlToExport; ?></a>
|
81 |
+
<p style="margin-top: 0;">
|
82 |
+
<?php _e("This URL will always provide the export file from this export, even if the file name changes.", 'wp_all_export_plugin'); ?>
|
83 |
+
</p>
|
84 |
+
</div>
|
85 |
+
</div>
|
86 |
+
<div class="tab-content scheduling" id="tab2-content">
|
87 |
+
<div class="wrap" style="text-align: left; padding-top: 10px;">
|
88 |
+
|
89 |
+
<?php
|
90 |
+
$export = $update_previous;
|
91 |
+
require __DIR__.'/../../../src/Scheduling/views/SchedulingUI.php'; ?>
|
92 |
+
|
93 |
+
</div>
|
94 |
+
</div>
|
95 |
+
<div class="tab-content normal-tab" id="tab3-content">
|
96 |
+
<p>
|
97 |
+
<?php _e("Automatically send your data to over 500 apps with Zapier.", 'wp_all_export_plugin'); ?>
|
98 |
+
<br/>
|
99 |
+
<a href="https://www.wpallimport.com/checkout/?edd_action=add_to_cart&download_id=118611&edd_options%5Bprice_id%5D=1&utm_source=wordpress.org&utm_medium=zapier&utm_campaign=free+wp+all+export+plugin" target="_blank">
|
100 |
+
<?php _e("Upgrade to the Pro edition of WP All Export for Zapier integration", 'wp_all_export_plugin'); ?>
|
101 |
+
</a>
|
102 |
+
<br/>
|
103 |
+
<a href="https://zapier.com/zapbook/wp-all-export-pro/" target="_blank"><?php _e("Click here to read more about WP All Export's Zapier Integration.", 'wp_all_export_plugin'); ?></a>
|
104 |
+
</p>
|
105 |
+
<iframe width="560" height="315" src="https://www.youtube.com/embed/6tBacBmiHsQ" frameborder="0" allowfullscreen></iframe>
|
106 |
+
</div>
|
107 |
+
<?php if ($isImportAllowedSpecification->isSatisfied($update_previous)): ?>
|
108 |
+
|
109 |
+
<div class="tab-content normal-tab" id="tab4-content">
|
110 |
+
<p>
|
111 |
+
<?php _e("After you've downloaded your data, edit it however you like.", 'wp_all_export_plugin'); ?><br/>
|
112 |
+
<?php _e("Then, click below to import the data with WP All Import without having to set anything up.", 'wp_all_export_plugin'); ?>
|
113 |
+
</p>
|
114 |
+
<p>
|
115 |
+
<button class="button button-primary button-hero wpallexport-large-button download_data"
|
116 |
+
rel="<?php echo add_query_arg(array('action' => 'download', 'id' => $update_previous->id, '_wpnonce' => wp_create_nonce('_wpnonce-download_feed')), $this->baseUrl); ?>"><?php _e('Download', 'wp_all_export_plugin'); ?> <?php echo strtoupper(wp_all_export_get_export_format($update_previous->options)); ?></button>
|
117 |
+
|
118 |
+
<button class="button button-primary button-hero wpallexport-large-button download_data"
|
119 |
+
rel="<?php echo add_query_arg(array('page' => 'pmxi-admin-import', 'id' => $update_previous->options['import_id'], 'deligate' => 'wpallexport'), remove_query_arg('page', $this->baseUrl)); ?>"><?php _e('Import with WP All Import', 'wp_all_export_plugin'); ?></button>
|
120 |
+
</p>
|
121 |
+
<p>
|
122 |
+
<?php _e("You can also start the import by clicking 'Import with WP All Import' on the Manage Exports page.", 'wp_all_export_plugin');?>
|
123 |
+
</p>
|
124 |
+
</div>
|
125 |
+
<?php endif; ?>
|
126 |
+
</div>
|
127 |
+
<hr>
|
128 |
+
<?php
|
129 |
+
}
|
130 |
+
?>
|
131 |
+
<input type="hidden" value="<?php echo $export['options']['cpt'][0]; ?>" id="export-cpt">
|
132 |
+
</div>
|
views/admin/export/template.php
CHANGED
@@ -96,7 +96,7 @@
|
|
96 |
<input type="hidden" name="cc_type[]" value="<?php echo $field_type; ?>"/>
|
97 |
<input type="hidden" name="cc_options[]" value="<?php echo (!empty($field_options)) ? $field_options : 0; ?>"/>
|
98 |
<input type="hidden" name="cc_value[]" value="<?php echo esc_attr($post['cc_value'][$ID]); ?>"/>
|
99 |
-
<input type="hidden" name="cc_name[]" value="<?php echo esc_attr($field_name); ?>"/>
|
100 |
<input type="hidden" name="cc_settings[]" value="<?php echo (!empty($post['cc_settings'][$ID])) ? esc_attr($post['cc_settings'][$ID]) : 0; ?>"/>
|
101 |
</div>
|
102 |
</li>
|
@@ -120,7 +120,7 @@
|
|
120 |
?>
|
121 |
<li>
|
122 |
<div class="custom_column" rel="<?php echo ($i + 1);?>">
|
123 |
-
<label class="wpallexport-xml-element"><?php echo $field['name']; ?></label>
|
124 |
<input type="hidden" name="ids[]" value="1"/>
|
125 |
<input type="hidden" name="cc_label[]" value="<?php echo $field['label']; ?>"/>
|
126 |
<input type="hidden" name="cc_php[]" value="0"/>
|
@@ -582,37 +582,37 @@
|
|
582 |
<a href="http://soflyy.com/" target="_blank"
|
583 |
class="wpallexport-created-by"><?php _e('Created by', 'wp_all_export_plugin'); ?> <span></span></a>
|
584 |
|
585 |
-
|
586 |
-
|
587 |
-
</td>
|
588 |
-
|
589 |
-
<td class="right template-sidebar" style="position: relative; width: 18%; right: 0px; padding: 0;">
|
590 |
|
591 |
-
|
592 |
|
593 |
-
|
594 |
|
595 |
-
|
596 |
|
597 |
-
|
598 |
|
599 |
-
|
600 |
|
601 |
-
|
602 |
-
|
603 |
-
|
|
|
|
|
|
|
|
|
604 |
|
605 |
-
|
606 |
-
|
607 |
-
|
608 |
|
609 |
-
</table>
|
610 |
|
611 |
<fieldset class="optionsset column rad4 wp-all-export-edit-column">
|
612 |
-
|
613 |
<div class="title"><span
|
614 |
-
class="wpallexport-add-row-title"><?php _e('Add Field To Export', 'wp_all_export_plugin'); ?></span><span
|
615 |
-
class="wpallexport-edit-row-title"><?php _e('Edit Export Field', 'wp_all_export_plugin'); ?></span></div>
|
616 |
|
617 |
<?php include_once 'template/add_new_field.php'; ?>
|
618 |
|
96 |
<input type="hidden" name="cc_type[]" value="<?php echo $field_type; ?>"/>
|
97 |
<input type="hidden" name="cc_options[]" value="<?php echo (!empty($field_options)) ? $field_options : 0; ?>"/>
|
98 |
<input type="hidden" name="cc_value[]" value="<?php echo esc_attr($post['cc_value'][$ID]); ?>"/>
|
99 |
+
<input type="hidden" name="cc_name[]" value="<?php echo XmlExportEngine::sanitizeFieldName(esc_attr($field_name)); ?>"/>
|
100 |
<input type="hidden" name="cc_settings[]" value="<?php echo (!empty($post['cc_settings'][$ID])) ? esc_attr($post['cc_settings'][$ID]) : 0; ?>"/>
|
101 |
</div>
|
102 |
</li>
|
120 |
?>
|
121 |
<li>
|
122 |
<div class="custom_column" rel="<?php echo ($i + 1);?>">
|
123 |
+
<label class="wpallexport-xml-element"><?php echo XmlExportEngine::sanitizeFieldName($field['name']); ?></label>
|
124 |
<input type="hidden" name="ids[]" value="1"/>
|
125 |
<input type="hidden" name="cc_label[]" value="<?php echo $field['label']; ?>"/>
|
126 |
<input type="hidden" name="cc_php[]" value="0"/>
|
582 |
<a href="http://soflyy.com/" target="_blank"
|
583 |
class="wpallexport-created-by"><?php _e('Created by', 'wp_all_export_plugin'); ?> <span></span></a>
|
584 |
|
585 |
+
</form>
|
|
|
|
|
|
|
|
|
586 |
|
587 |
+
</td>
|
588 |
|
589 |
+
<td class="right template-sidebar" style="position: relative; width: 18%; right: 0px; padding: 0;">
|
590 |
|
591 |
+
<fieldset id="available_data" class="optionsset rad4 wpae_available_data">
|
592 |
|
593 |
+
<div class="title"><?php _e('Available Data', 'wp_all_export_plugin'); ?></div>
|
594 |
|
595 |
+
<div class="wpallexport-xml resetable">
|
596 |
|
597 |
+
<ul>
|
598 |
+
|
599 |
+
<?php echo $available_data_view; ?>
|
600 |
+
|
601 |
+
</ul>
|
602 |
+
|
603 |
+
</div>
|
604 |
|
605 |
+
</fieldset>
|
606 |
+
</td>
|
607 |
+
</tr>
|
608 |
|
609 |
+
</table>
|
610 |
|
611 |
<fieldset class="optionsset column rad4 wp-all-export-edit-column">
|
612 |
+
|
613 |
<div class="title"><span
|
614 |
+
class="wpallexport-add-row-title" style="font-size: 14px;"><?php _e('Add Field To Export', 'wp_all_export_plugin'); ?></span><span
|
615 |
+
class="wpallexport-edit-row-title" style="font-size: 14px;"><?php _e('Edit Export Field', 'wp_all_export_plugin'); ?></span></div>
|
616 |
|
617 |
<?php include_once 'template/add_new_field.php'; ?>
|
618 |
|
views/admin/manage/update.php
CHANGED
@@ -50,9 +50,11 @@ $l10n = array(
|
|
50 |
<form class="confirm <?php echo ! $isWizard ? 'edit' : '' ?>" method="post" style="float:right;">
|
51 |
|
52 |
<?php wp_nonce_field('update-export', '_wpnonce_update-export') ?>
|
53 |
-
<input type="hidden" name="is_confirmed" value="1" />
|
|
|
54 |
|
55 |
-
|
|
|
56 |
</form>
|
57 |
|
58 |
</div>
|
@@ -80,6 +82,7 @@ $l10n = array(
|
|
80 |
<input type="hidden" name="taxonomy_to_export" value="<?php echo $post['taxonomy_to_export'];?>">
|
81 |
<input type="hidden" name="wpml_lang" value="<?php echo $post['wpml_lang'];?>" />
|
82 |
<input type="hidden" id="export_variations" name="export_variations" value="<?php echo XmlExportEngine::getProductVariationMode();?>" />
|
|
|
83 |
|
84 |
<?php XmlExportFiltering::render_filtering_block( $engine, $isWizard, $post ); ?>
|
85 |
|
50 |
<form class="confirm <?php echo ! $isWizard ? 'edit' : '' ?>" method="post" style="float:right;">
|
51 |
|
52 |
<?php wp_nonce_field('update-export', '_wpnonce_update-export') ?>
|
53 |
+
<input type="hidden" name="is_confirmed" value="1" />
|
54 |
+
<input type="hidden" name="record-count" class="wpae-record-count" value="0" />
|
55 |
|
56 |
+
|
57 |
+
<input type="submit" class="rad10 wp_all_export_confirm_and_run" value="<?php _e('Confirm & Run Export', 'wp_all_export_plugin') ?>" <?php if (empty(PMXE_Plugin::$session->found_posts)):?>style="display:none;"<?php endif;?>/>
|
58 |
</form>
|
59 |
|
60 |
</div>
|
82 |
<input type="hidden" name="taxonomy_to_export" value="<?php echo $post['taxonomy_to_export'];?>">
|
83 |
<input type="hidden" name="wpml_lang" value="<?php echo $post['wpml_lang'];?>" />
|
84 |
<input type="hidden" id="export_variations" name="export_variations" value="<?php echo XmlExportEngine::getProductVariationMode();?>" />
|
85 |
+
<input type="hidden" name="record-count" class="wpae-record-count" value="0" />
|
86 |
|
87 |
<?php XmlExportFiltering::render_filtering_block( $engine, $isWizard, $post ); ?>
|
88 |
|
wp-all-export.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
Plugin Name: WP All Export
|
4 |
Plugin URI: http://www.wpallimport.com/export/
|
5 |
Description: Export any post type to a CSV or XML file. Edit the exported data, and then re-import it later using WP All Import.
|
6 |
-
Version: 1.2.
|
7 |
Author: Soflyy
|
8 |
*/
|
9 |
|
@@ -12,6 +12,13 @@ require_once(__DIR__.'/classes/CdataStrategyFactory.php');
|
|
12 |
if( ! defined( 'PMXE_SESSION_COOKIE' ) )
|
13 |
define( 'PMXE_SESSION_COOKIE', '_pmxe_session' );
|
14 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
15 |
/**
|
16 |
* Plugin root dir with forward slashes as directory separator regardless of actuall DIRECTORY_SEPARATOR value
|
17 |
* @var string
|
@@ -52,7 +59,7 @@ else {
|
|
52 |
*/
|
53 |
define('PMXE_PREFIX', 'pmxe_');
|
54 |
|
55 |
-
define('PMXE_VERSION', '1.2.
|
56 |
|
57 |
define('PMXE_EDITION', 'free');
|
58 |
|
@@ -148,6 +155,84 @@ else {
|
|
148 |
|
149 |
private static $hasActiveSchedulingLicense = null;
|
150 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
151 |
/**
|
152 |
* Return singletone instance
|
153 |
* @return PMXE_Plugin
|
@@ -242,78 +327,6 @@ else {
|
|
242 |
return ($this->isNetwork()) ? $wpdb->base_prefix : $wpdb->prefix;
|
243 |
}
|
244 |
|
245 |
-
/**
|
246 |
-
* Class constructor containing dispatching logic
|
247 |
-
* @param string $rootDir Plugin root dir
|
248 |
-
* @param string $pluginFilePath Plugin main file
|
249 |
-
*/
|
250 |
-
protected function __construct() {
|
251 |
-
|
252 |
-
require_once (self::ROOT_DIR . '/classes/installer.php');
|
253 |
-
|
254 |
-
$installer = new PMXE_Installer();
|
255 |
-
$installer->checkActivationConditions();
|
256 |
-
|
257 |
-
// uncaught exception doesn't prevent plugin from being activated, therefore replace it with fatal error so it does
|
258 |
-
//set_exception_handler(create_function('$e', 'trigger_error($e->getMessage(), E_USER_ERROR);'));
|
259 |
-
|
260 |
-
// register autoloading method
|
261 |
-
spl_autoload_register(array($this, 'autoload'));
|
262 |
-
|
263 |
-
// register helpers
|
264 |
-
if (is_dir(self::ROOT_DIR . '/helpers')) foreach (PMXE_Helper::safe_glob(self::ROOT_DIR . '/helpers/*.php', PMXE_Helper::GLOB_RECURSE | PMXE_Helper::GLOB_PATH) as $filePath) {
|
265 |
-
require_once $filePath;
|
266 |
-
}
|
267 |
-
|
268 |
-
// init plugin options
|
269 |
-
$option_name = get_class($this) . '_Options';
|
270 |
-
$options_default = PMXE_Config::createFromFile(self::ROOT_DIR . '/config/options.php')->toArray();
|
271 |
-
$this->options = array_intersect_key(get_option($option_name, array()), $options_default) + $options_default;
|
272 |
-
$this->options = array_intersect_key($options_default, array_flip(array('info_api_url'))) + $this->options; // make sure hidden options apply upon plugin reactivation
|
273 |
-
if ('' == $this->options['cron_job_key']) $this->options['cron_job_key'] = wp_all_export_url_title(wp_all_export_rand_char(12));
|
274 |
-
|
275 |
-
update_option($option_name, $this->options);
|
276 |
-
$this->options = get_option(get_class($this) . '_Options');
|
277 |
-
register_activation_hook(self::FILE, array($this, 'activation'));
|
278 |
-
|
279 |
-
// register action handlers
|
280 |
-
if (is_dir(self::ROOT_DIR . '/actions')) if (is_dir(self::ROOT_DIR . '/actions')) foreach (PMXE_Helper::safe_glob(self::ROOT_DIR . '/actions/*.php', PMXE_Helper::GLOB_RECURSE | PMXE_Helper::GLOB_PATH) as $filePath) {
|
281 |
-
require_once $filePath;
|
282 |
-
$function = $actionName = basename($filePath, '.php');
|
283 |
-
if (preg_match('%^(.+?)[_-](\d+)$%', $actionName, $m)) {
|
284 |
-
$actionName = $m[1];
|
285 |
-
$priority = intval($m[2]);
|
286 |
-
} else {
|
287 |
-
$priority = 10;
|
288 |
-
}
|
289 |
-
add_action($actionName, self::PREFIX . str_replace('-', '_', $function), $priority, 99); // since we don't know at this point how many parameters each plugin expects, we make sure they will be provided with all of them (it's unlikely any developer will specify more than 99 parameters in a function)
|
290 |
-
}
|
291 |
-
|
292 |
-
// register filter handlers
|
293 |
-
if (is_dir(self::ROOT_DIR . '/filters')) foreach (PMXE_Helper::safe_glob(self::ROOT_DIR . '/filters/*.php', PMXE_Helper::GLOB_RECURSE | PMXE_Helper::GLOB_PATH) as $filePath) {
|
294 |
-
require_once $filePath;
|
295 |
-
$function = $actionName = basename($filePath, '.php');
|
296 |
-
if (preg_match('%^(.+?)[_-](\d+)$%', $actionName, $m)) {
|
297 |
-
$actionName = $m[1];
|
298 |
-
$priority = intval($m[2]);
|
299 |
-
} else {
|
300 |
-
$priority = 10;
|
301 |
-
}
|
302 |
-
add_filter($actionName, self::PREFIX . str_replace('-', '_', $function), $priority, 99); // since we don't know at this point how many parameters each plugin expects, we make sure they will be provided with all of them (it's unlikely any developer will specify more than 99 parameters in a function)
|
303 |
-
}
|
304 |
-
|
305 |
-
// register shortcodes handlers
|
306 |
-
if (is_dir(self::ROOT_DIR . '/shortcodes')) foreach (PMXE_Helper::safe_glob(self::ROOT_DIR . '/shortcodes/*.php', PMXE_Helper::GLOB_RECURSE | PMXE_Helper::GLOB_PATH) as $filePath) {
|
307 |
-
$tag = strtolower(str_replace('/', '_', preg_replace('%^' . preg_quote(self::ROOT_DIR . '/shortcodes/', '%') . '|\.php$%', '', $filePath)));
|
308 |
-
add_shortcode($tag, array($this, 'shortcodeDispatcher'));
|
309 |
-
}
|
310 |
-
|
311 |
-
// register admin page pre-dispatcher
|
312 |
-
add_action('admin_init', array($this, 'adminInit'));
|
313 |
-
add_action('admin_init', array($this, 'fix_db_schema'));
|
314 |
-
add_action('init', array($this, 'init'));
|
315 |
-
}
|
316 |
-
|
317 |
public function init(){
|
318 |
$this->load_plugin_textdomain();
|
319 |
}
|
@@ -376,7 +389,11 @@ else {
|
|
376 |
'is_user' => is_user_admin(),
|
377 |
);
|
378 |
add_filter('current_screen', array($this, 'getAdminCurrentScreen'));
|
379 |
-
|
|
|
|
|
|
|
|
|
380 |
|
381 |
$controller = new $controllerName();
|
382 |
if ( ! $controller instanceof PMXE_Controller_Admin) {
|
@@ -575,7 +592,7 @@ else {
|
|
575 |
*/
|
576 |
public function activation() {
|
577 |
// uncaught exception doesn't prevent plugin from being activated, therefore replace it with fatal error so it does
|
578 |
-
|
579 |
|
580 |
// create plugin options
|
581 |
$option_name = get_class($this) . '_Options';
|
3 |
Plugin Name: WP All Export
|
4 |
Plugin URI: http://www.wpallimport.com/export/
|
5 |
Description: Export any post type to a CSV or XML file. Edit the exported data, and then re-import it later using WP All Import.
|
6 |
+
Version: 1.2.1
|
7 |
Author: Soflyy
|
8 |
*/
|
9 |
|
12 |
if( ! defined( 'PMXE_SESSION_COOKIE' ) )
|
13 |
define( 'PMXE_SESSION_COOKIE', '_pmxe_session' );
|
14 |
|
15 |
+
// Enable error reporting in development
|
16 |
+
if(getenv('WPAE_DEV')) {
|
17 |
+
error_reporting(E_ALL ^ E_DEPRECATED );
|
18 |
+
ini_set('display_errors', 1);
|
19 |
+
// xdebug_disable();
|
20 |
+
}
|
21 |
+
|
22 |
/**
|
23 |
* Plugin root dir with forward slashes as directory separator regardless of actuall DIRECTORY_SEPARATOR value
|
24 |
* @var string
|
59 |
*/
|
60 |
define('PMXE_PREFIX', 'pmxe_');
|
61 |
|
62 |
+
define('PMXE_VERSION', '1.2.1');
|
63 |
|
64 |
define('PMXE_EDITION', 'free');
|
65 |
|
155 |
|
156 |
private static $hasActiveSchedulingLicense = null;
|
157 |
|
158 |
+
public static $cache_key = '';
|
159 |
+
|
160 |
+
/**
|
161 |
+
* Class constructor containing dispatching logic
|
162 |
+
* @param string $rootDir Plugin root dir
|
163 |
+
* @param string $pluginFilePath Plugin main file
|
164 |
+
*/
|
165 |
+
protected function __construct() {
|
166 |
+
|
167 |
+
require_once (self::ROOT_DIR . '/classes/installer.php');
|
168 |
+
|
169 |
+
$installer = new PMXE_Installer();
|
170 |
+
$installer->checkActivationConditions();
|
171 |
+
|
172 |
+
$plugin_basename = plugin_basename( __FILE__ );
|
173 |
+
|
174 |
+
self::$cache_key = md5( 'edd_plugin_' . sanitize_key( $plugin_basename ) . '_version_info' );
|
175 |
+
|
176 |
+
// uncaught exception doesn't prevent plugin from being activated, therefore replace it with fatal error so it does
|
177 |
+
//set_exception_handler(create_function('$e', 'trigger_error($e->getMessage(), E_USER_ERROR);'));
|
178 |
+
|
179 |
+
// register autoloading method
|
180 |
+
spl_autoload_register(array($this, 'autoload'));
|
181 |
+
|
182 |
+
// register helpers
|
183 |
+
if (is_dir(self::ROOT_DIR . '/helpers')) foreach (PMXE_Helper::safe_glob(self::ROOT_DIR . '/helpers/*.php', PMXE_Helper::GLOB_RECURSE | PMXE_Helper::GLOB_PATH) as $filePath) {
|
184 |
+
require_once $filePath;
|
185 |
+
}
|
186 |
+
|
187 |
+
// init plugin options
|
188 |
+
$option_name = get_class($this) . '_Options';
|
189 |
+
$options_default = PMXE_Config::createFromFile(self::ROOT_DIR . '/config/options.php')->toArray();
|
190 |
+
$this->options = array_intersect_key(get_option($option_name, array()), $options_default) + $options_default;
|
191 |
+
$this->options = array_intersect_key($options_default, array_flip(array('info_api_url'))) + $this->options; // make sure hidden options apply upon plugin reactivation
|
192 |
+
if ('' == $this->options['cron_job_key']) $this->options['cron_job_key'] = wp_all_export_url_title(wp_all_export_rand_char(12));
|
193 |
+
|
194 |
+
update_option($option_name, $this->options);
|
195 |
+
$this->options = get_option(get_class($this) . '_Options');
|
196 |
+
register_activation_hook(self::FILE, array($this, 'activation'));
|
197 |
+
|
198 |
+
// register action handlers
|
199 |
+
if (is_dir(self::ROOT_DIR . '/actions')) if (is_dir(self::ROOT_DIR . '/actions')) foreach (PMXE_Helper::safe_glob(self::ROOT_DIR . '/actions/*.php', PMXE_Helper::GLOB_RECURSE | PMXE_Helper::GLOB_PATH) as $filePath) {
|
200 |
+
require_once $filePath;
|
201 |
+
$function = $actionName = basename($filePath, '.php');
|
202 |
+
if (preg_match('%^(.+?)[_-](\d+)$%', $actionName, $m)) {
|
203 |
+
$actionName = $m[1];
|
204 |
+
$priority = intval($m[2]);
|
205 |
+
} else {
|
206 |
+
$priority = 10;
|
207 |
+
}
|
208 |
+
add_action($actionName, self::PREFIX . str_replace('-', '_', $function), $priority, 99); // since we don't know at this point how many parameters each plugin expects, we make sure they will be provided with all of them (it's unlikely any developer will specify more than 99 parameters in a function)
|
209 |
+
}
|
210 |
+
|
211 |
+
// register filter handlers
|
212 |
+
if (is_dir(self::ROOT_DIR . '/filters')) foreach (PMXE_Helper::safe_glob(self::ROOT_DIR . '/filters/*.php', PMXE_Helper::GLOB_RECURSE | PMXE_Helper::GLOB_PATH) as $filePath) {
|
213 |
+
require_once $filePath;
|
214 |
+
$function = $actionName = basename($filePath, '.php');
|
215 |
+
if (preg_match('%^(.+?)[_-](\d+)$%', $actionName, $m)) {
|
216 |
+
$actionName = $m[1];
|
217 |
+
$priority = intval($m[2]);
|
218 |
+
} else {
|
219 |
+
$priority = 10;
|
220 |
+
}
|
221 |
+
add_filter($actionName, self::PREFIX . str_replace('-', '_', $function), $priority, 99); // since we don't know at this point how many parameters each plugin expects, we make sure they will be provided with all of them (it's unlikely any developer will specify more than 99 parameters in a function)
|
222 |
+
}
|
223 |
+
|
224 |
+
// register shortcodes handlers
|
225 |
+
if (is_dir(self::ROOT_DIR . '/shortcodes')) foreach (PMXE_Helper::safe_glob(self::ROOT_DIR . '/shortcodes/*.php', PMXE_Helper::GLOB_RECURSE | PMXE_Helper::GLOB_PATH) as $filePath) {
|
226 |
+
$tag = strtolower(str_replace('/', '_', preg_replace('%^' . preg_quote(self::ROOT_DIR . '/shortcodes/', '%') . '|\.php$%', '', $filePath)));
|
227 |
+
add_shortcode($tag, array($this, 'shortcodeDispatcher'));
|
228 |
+
}
|
229 |
+
|
230 |
+
// register admin page pre-dispatcher
|
231 |
+
add_action('admin_init', array($this, 'adminInit'));
|
232 |
+
add_action('admin_init', array($this, 'fix_db_schema'));
|
233 |
+
add_action('init', array($this, 'init'));
|
234 |
+
}
|
235 |
+
|
236 |
/**
|
237 |
* Return singletone instance
|
238 |
* @return PMXE_Plugin
|
327 |
return ($this->isNetwork()) ? $wpdb->base_prefix : $wpdb->prefix;
|
328 |
}
|
329 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
330 |
public function init(){
|
331 |
$this->load_plugin_textdomain();
|
332 |
}
|
389 |
'is_user' => is_user_admin(),
|
390 |
);
|
391 |
add_filter('current_screen', array($this, 'getAdminCurrentScreen'));
|
392 |
+
add_filter('admin_body_class',
|
393 |
+
function() {
|
394 |
+
return 'wpallexport-plugin';
|
395 |
+
}
|
396 |
+
);
|
397 |
|
398 |
$controller = new $controllerName();
|
399 |
if ( ! $controller instanceof PMXE_Controller_Admin) {
|
592 |
*/
|
593 |
public function activation() {
|
594 |
// uncaught exception doesn't prevent plugin from being activated, therefore replace it with fatal error so it does
|
595 |
+
set_exception_handler(function($e) {trigger_error($e->getMessage(), E_USER_ERROR); });
|
596 |
|
597 |
// create plugin options
|
598 |
$option_name = get_class($this) . '_Options';
|