barcode should map to GTIN, part_number should map to MPN, _backorder_availability_date should map to the Availability Date field.
I’ve used the filter in your guide above (woocommerce_gla_attribute_mapping_sources_custom_attributes) to add the field keys to the mapping sources, so they do now appear in the dropdown list & I’ve created the mapping rules.
However, I’m not sure the mapping is working as expected. If i update one of my Barcode values, it doesn’t seem to correctly update the GTIN field. Same for the part_number field, it doesn’t update the MPN field.
i was expecting the target attribute to be updated in line with the data source but this doesn’t happen. do you have any ideas why? Am i missing something or misunderstanding how the mapping should work?
Also, why i can’t select Availability Date as a target attribute? It means i can’t add my mapping rule from the data source _backorder_availability_date.
Finally, does the mapping also work for variable products? My field keys for simple / variable products are the same but i don’t see any documentation about mapping variable products.
Thanks
I am using the free version, and I followed the steps in the forum to create a custom template, but the additional code is not showing up in my invoices.
First, i created the path: …/themes/DiviChild/woocommerce/pdf/yourtemplate
here I copied the files from the plugin directory ( invoice.php, style.css… )
I uploaded the image sign_invoice_mk.jpg to the same folder.
I added this code in the invoice.php ( with no additional css)
<?php do_action( 'wpo_wcpdf_after_order_details', $this->get_type(), $this->order ); ?>
<img src="<?php echo $this->get_template_path(); ?>/sign_invoice_mk.jpg"/> /* this is my code */
<div class="bottom-spacer"></div>
<?php if ( $this->get_footer() ) : ?>
I tried to disable and reenable the plugin, clear cache, but still the image does not show up in the invoice. I also make some changes to the css file, but those are not rendering also.
What am I doing wrong, am I missing something ?
]]>How can we make UM profile fields / user meta (e.g. for the field “profile image” or others we define in the UM profile form) available for this task in EM? That would mean, for example, that when an artist changes their image, it automatically appears in the corresponding event post(s).
Any help would be gratefully appreciated.
]]>One thing that would be really helpful is a Group Repeater field—something that lets us create repeatable groups of fields (like a group with text, image, and link fields that can be duplicated multiple times).
This would be useful for things like:
Is this something that might be added in the future? Or is there a workaround for now?
Thanks!
]]>add_action( 'init', 'create_post_type', 0 );
function create_post_type() {
register_post_type( 'codingblog',
// CPT Options
array(
'labels' => array(
'name' => __( 'CodingBlogs' ),
'singular_name' => __( 'CodingBlog' ),
'menu_name' => __( 'My Coding Blog', 'blogus'),
'all_items' => __( 'All Coding Blogs', 'blogus'),
'view_item' => __( 'View Coding Blog', 'blogus'),
'add_new_item' => __( 'Add New Coding Blog', 'blogus'),
'add_new' => __( 'Add New', 'blogus'),
'edit_item' => __( 'Edit Coding Blog', 'blogus'),
'update_item' => __( 'Update Coding Blog', 'blogus'),
'search_items' => __( 'Search Coding Blog', 'blogus'),
'not_found' => __( 'Not Found', 'blogus'),
'not_found_in_trash' => __( 'Not found in Trash', 'blogus'),
),
'label' => __( 'codingblogs', 'blogus' ),
'description' => __( 'Coding Blog Posts', 'blogus'),
'supports' => array( 'title', 'editor', 'excerpt',
'author', 'thumbnail', 'comments',
'revisions', 'custom-fields', ),
'taxonomies' => array( 'post_tag', 'category', ),
'hierarchical' => false,
'public' => true,
'show_ui' => true,
'show_in_menu' => true,
'show_in_nav_menus' => true,
'show_in_admin_bar' => true,
'menu_position' => 5,
'can_export' => true,
'has_archive' => true,
'exclude_from_search' => false,
'publicly_queryable' => true,
'capability_type' => 'post',
'rewrite' => array('slug' => 'codingblogs'),
'show_in_rest' => true,
)
);
}
I was expecting (from what I read) that if I register a custom field with this custom type it will be visible in the editor when I edit an instance of this post type.
function create_post_type_fields() {
register_post_meta( 'codingblog', 'themeslug_github_repo', [
// Add to the REST response
'show_in_rest' => true,
'single' => true,
'type' => 'string',
'sanitize_callback' => 'esc_url_raw',
] );
}
add_action( 'init', 'create_post_type_fields' );
But this has not worked. As I went to measure of including the ‘custom-fields’ in the supports list for the custom post type I would have expected this to work.
That said, when I have used a plugin for this purpose (CPTUI for example, with Advanced Custom Fields) I was forced to create a field group, and then add my custom field in the field group and then associate this with the custom post type. This is somehow divergent from the developer code examples I have found which don’t mention field groups at all.
So my questions are, why is the above not working? As I quite like field groups for the editor display, how can I create a custom post type, with one field group and one custom post type like the one above? I genuinely cannot find a code example for this use case after much searching.
]]>pa_book_author
beneath each product title on the Wishlist page (in this case a book’s author beneath each book title). Any guidance you could give on how best to achieve this would be much appreciated, cheers!
]]>Configuring an optional unit for custom fields e.g. ‘km’ for the field mileage would be a nice feature. The unit should then be displayed in the form and the ad details. This way the users input could be configured and validated as number.
]]>Thanks for the great plugin.
Somehow in feed config I can’t see all custom fields created for my products. Basically, I can’t see many of them.
Here’s what i mean: https://prnt.sc/eRPRc0JEGhwY
This list doesn’t display custom fields I need, fields that are used for dozens of products.
Tried to clear all the caches of the plugin, but still no luck.
]]>