Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- (function ($) {
- $(document).ready(function () {
- if (typeof window.wffnBuilderCommons !== "undefined") {
- window.wffnBuilderCommons.addFilter('wffn_js_optin_vue_data', function (e) {
- let custom_settings_valid_fields = [
- {
- type: "radios",
- label: "<?php _e( 'Enable Integration', 'wp-fusion' ); ?>",
- model: "op_wpfusion_enable",
- values: () => {
- return wfop_action.op_wpfusion_optin_radio_vals
- },
- hint: "<?php printf( __( 'Select Yes to sync optins with %s.', 'wp-fusion' ), wp_fusion()->crm->name ); ?>",
- },
- {
- type: "vueMultiSelect",
- label: "<?php _e( 'Apply Tags - Optin Submitted', 'wp-fusion' ); ?>",
- placeholder: "<?php _e( 'Select tags', 'wp-fusion' ); ?>",
- model: "op_wpfusion_optin_tags",
- selectOptions: {hideNoneSelectedText: true},
- hint: "<?php printf( __( 'Select tags to be applied in %s when this form is submitted.', 'wp-fusion' ), wp_fusion()->crm->name ); ?>",
- values: () => {
- return wfop_action.op_wpfusion_optin_tags_vals
- },
- selectOptions: {
- multiple: true,
- key: "id",
- label: "name",
- },
- visible: function (model) {
- return (model.op_wpfusion_enable === 'true');
- },
- },
- ];
- e.schemaFusion = {
- groups: [{
- legend: '<?php _e( 'WP Fusion', 'wp-fusion' ); ?>',
- fields: custom_settings_valid_fields
- }]
- };
- e.modelFusion = wfop_action.action_options;
- return e;
- });
- }
- });
- })(jQuery);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement