Changeset 2747151
- Timestamp:
- 06/23/2022 03:00:14 PM (4 years ago)
- Location:
- linet-erp-woocommerce-integration/trunk
- Files:
-
- 16 edited
-
classes/class-wc-li-autoloader.php (modified) (1 diff)
-
classes/class-wc-li-inventory.php (modified) (1 diff)
-
classes/class-wc-li-invoice.php (modified) (1 diff)
-
classes/class-wc-li-line-item-manager.php (modified) (1 diff)
-
classes/class-wc-li-logger.php (modified) (1 diff)
-
classes/class-wc-li-order-actions.php (modified) (1 diff)
-
classes/class-wc-li-payment-manager.php (modified) (1 diff)
-
classes/class-wc-li-payment.php (modified) (1 diff)
-
classes/class-wc-li-settings-map.php (modified) (1 diff)
-
classes/class-wc-li-settings-yith-map.php (modified) (1 diff)
-
classes/class-wc-li-settings.php (modified) (9 diffs)
-
classes/class-wc-li-sns.php (modified) (1 diff)
-
readme.txt (modified) (1 diff)
-
woo-includes/class-wc-dependencies.php (modified) (1 diff)
-
woo-includes/woo-functions.php (modified) (1 diff)
-
woocommerce-linet.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
linet-erp-woocommerce-integration/trunk/classes/class-wc-li-autoloader.php
r2747055 r2747151 6 6 Author: Speedcomp 7 7 Author URI: http://www.linet.org.il 8 Version: 3.1. 28 Version: 3.1.3 9 9 Text Domain: wc-linet 10 10 Domain Path: /languages/ -
linet-erp-woocommerce-integration/trunk/classes/class-wc-li-inventory.php
r2747055 r2747151 6 6 Author: Speedcomp 7 7 Author URI: http://www.linet.org.il 8 Version: 3.1. 28 Version: 3.1.3 9 9 Text Domain: wc-linet 10 10 Domain Path: /languages/ -
linet-erp-woocommerce-integration/trunk/classes/class-wc-li-invoice.php
r2747055 r2747151 6 6 Author: Speedcomp 7 7 Author URI: http://www.linet.org.il 8 Version: 3.1. 28 Version: 3.1.3 9 9 Text Domain: wc-linet 10 10 Domain Path: /languages/ -
linet-erp-woocommerce-integration/trunk/classes/class-wc-li-line-item-manager.php
r2747055 r2747151 6 6 Author: Speedcomp 7 7 Author URI: http://www.linet.org.il 8 Version: 3.1. 28 Version: 3.1.3 9 9 Text Domain: wc-linet 10 10 Domain Path: /languages/ -
linet-erp-woocommerce-integration/trunk/classes/class-wc-li-logger.php
r2747055 r2747151 6 6 Author: Speedcomp 7 7 Author URI: http://www.linet.org.il 8 Version: 3.1. 28 Version: 3.1.3 9 9 Text Domain: wc-linet 10 10 Domain Path: /languages/ -
linet-erp-woocommerce-integration/trunk/classes/class-wc-li-order-actions.php
r2747055 r2747151 6 6 Author: Speedcomp 7 7 Author URI: http://www.linet.org.il 8 Version: 3.1. 28 Version: 3.1.3 9 9 Text Domain: wc-linet 10 10 Domain Path: /languages/ -
linet-erp-woocommerce-integration/trunk/classes/class-wc-li-payment-manager.php
r2747055 r2747151 6 6 Author: Speedcomp 7 7 Author URI: http://www.linet.org.il 8 Version: 3.1. 28 Version: 3.1.3 9 9 Text Domain: wc-linet 10 10 Domain Path: /languages/ -
linet-erp-woocommerce-integration/trunk/classes/class-wc-li-payment.php
r2747055 r2747151 6 6 Author: Speedcomp 7 7 Author URI: http://www.linet.org.il 8 Version: 3.1. 28 Version: 3.1.3 9 9 Text Domain: wc-linet 10 10 Domain Path: /languages/ -
linet-erp-woocommerce-integration/trunk/classes/class-wc-li-settings-map.php
r2747055 r2747151 6 6 Author: Speedcomp 7 7 Author URI: http://www.linet.org.il 8 Version: 3.1. 28 Version: 3.1.3 9 9 Text Domain: wc-linet 10 10 Domain Path: /languages/ -
linet-erp-woocommerce-integration/trunk/classes/class-wc-li-settings-yith-map.php
r2747055 r2747151 6 6 Author: Speedcomp 7 7 Author URI: http://www.linet.org.il 8 Version: 3.1. 28 Version: 3.1.3 9 9 Text Domain: wc-linet 10 10 Domain Path: /languages/ -
linet-erp-woocommerce-integration/trunk/classes/class-wc-li-settings.php
r2747055 r2747151 6 6 Author: Speedcomp 7 7 Author URI: http://www.linet.org.il 8 Version: 3.1. 28 Version: 3.1.3 9 9 Text Domain: wc-linet 10 10 Domain Path: /languages/ … … 456 456 $value = $_POST['value']; 457 457 458 if($key ==="id"){ 459 $post_id = $value; 460 $product=wc_get_product($post_id); 461 462 if(!empty($product)) 463 echo $product->delete(true); 464 465 echo delete_post_meta($post_id,"_linet_id"); 466 echo delete_post_meta($post_id,"_sku"); 467 echo wc_delete_product_transients($post_id); 468 469 return true; 470 471 } 472 458 473 $query = "SELECT post_id FROM $wpdb->postmeta where meta_key=%s AND meta_value=%s"; 459 474 $posts = $wpdb->get_col($wpdb->prepare($query,$key,$value)); … … 547 562 foreach($products as $index=>$product){ 548 563 $arr['sku'.$index]= array( 549 'title' => __('duplicate sku', 'wc-linet')." <br /><a data-key='_sku' data-value='$product->meta_value' onclick=\"linet.deleteProd( this);\" href='#'>Delete</a>",564 'title' => __('duplicate sku', 'wc-linet')." <br /><a data-key='_sku' data-value='$product->meta_value' onclick=\"linet.deleteProd(event,this);\" href=''>Delete</a>", 550 565 'default' => '', 551 566 'type' => 'none', … … 558 573 foreach($products as $index => $product){ 559 574 $arr['linet_id'.$index] = array( 560 'title' => __('duplicate linet_id', 'wc-linet')." <br /><a data-key='_linet_id' data-value='$product->meta_value' onclick=\"linet.deleteProd( this);\" href='#'>Delete</a>",575 'title' => __('duplicate linet_id', 'wc-linet')." <br /><a data-key='_linet_id' data-value='$product->meta_value' onclick=\"linet.deleteProd(event,this);\" href=''>Delete</a>", 561 576 'default' => '', 562 577 'type' => 'none', … … 564 579 ); 565 580 } 581 566 582 567 583 $query = "SELECT ID,post_title,meta_value FROM $wpdb->posts LEFT JOIN $wpdb->postmeta ON post_id=ID AND meta_key = '_wp_attachment_metadata' where post_type='attachment' AND meta_value is null"; … … 569 585 foreach($attachments as $index=>$attachment){ 570 586 $arr['attachment'.$index]= array( 571 'title' => __('attachment metadata missing', 'wc-linet')." <br /><a data-id='$attachment->ID' onclick=\"linet.deleteAttachment(this);\" href=' #'>Delete</a>",587 'title' => __('attachment metadata missing', 'wc-linet')." <br /><a data-id='$attachment->ID' onclick=\"linet.deleteAttachment(this);\" href=''>Delete</a>", 572 588 'default' => '', 573 589 'type' => 'none', 574 'description' => "<a data-id='$attachment->ID' data-file='$attachment->post_title' onclick=\"linet.calcAttachment(this);\" href=' #'>$attachment->post_title</a>",590 'description' => "<a data-id='$attachment->ID' data-file='$attachment->post_title' onclick=\"linet.calcAttachment(this);\" href=''>$attachment->post_title</a>", 575 591 ); 576 592 } 593 594 595 596 597 598 599 600 601 $query = "select a.* ,meta_id.`meta_value` as meta_id,meta_sku.`meta_value` as meta_sku 602 603 FROM 604 ( 605 SELECT count(`id`) as inst,max(`id`) as lasty,`post_type`,`post_title`,`post_excerpt`,`post_parent` 606 FROM $wpdb->posts 607 608 609 where 610 `post_parent` in (SELECT DISTINCT `post_parent` FROM $wpdb->posts WHERE `post_type`='product_variation') and `post_parent`!=0 611 and post_type='product_variation' 612 GROUP by `post_parent`,`post_excerpt` 613 HAVING inst>1 614 ORDER BY $wpdb->posts.`post_parent` ASC 615 616 ) a 617 618 LEFT JOIN $wpdb->postmeta meta_sku on meta_sku.`meta_key`='_sku' AND meta_sku.`post_id`=a.lasty 619 LEFT JOIN $wpdb->postmeta meta_id on meta_id.`meta_key`='_linet_id' AND meta_id.`post_id`=a.lasty"; 620 621 $products = $wpdb->get_results($query); 622 foreach($products as $index => $product){ 623 $arr['vari'.$index] = array( 624 'title' => __('duplicate product_variation', 'wc-linet')." <br /><a data-key='id' data-value='$product->lasty' onclick=\"linet.deleteProd(event,this);\" href=''>Delete</a>", 625 'default' => '', 626 'type' => 'none', 627 'description' => "post_id: ".$product->lasty." post_parent: ".$product->post_parent." linet_id:".$product->meta_id." sku:".$product->meta_sku." count: ".$product->inst, 628 ); 629 } 630 631 632 577 633 $scanned_directory = array(); 578 634 if(is_dir(WC_LOG_DIR)){ … … 585 641 if(strpos($file,'linet')===0 ||strpos($file,'fatal-errors')===0 ) 586 642 $arr['file'.$index]= array( 587 'title' => __('Log File', 'wc-linet')."<br /><a data-name='$file' onclick=\"linet.deleteFile( this);\" href='#'>Delete</a>",643 'title' => __('Log File', 'wc-linet')."<br /><a data-name='$file' onclick=\"linet.deleteFile(event,this);\" href='#'>Delete</a>", 588 644 'default' => '', 589 645 'type' => 'none', … … 1019 1075 }, 1020 1076 1021 deleteProd: function (obj) { 1077 deleteProd: function (e,obj) { 1078 console.log(obj);console.log(jQuery(obj).data()); 1079 e.preventDefault(); 1080 1081 1022 1082 var key = jQuery(obj).data('key'); 1023 1083 var value = jQuery(obj).data('value'); … … 1035 1095 return false; 1036 1096 }, 1037 deleteFile: function (obj) { 1097 deleteFile: function (e,obj) { 1098 e.preventDefault(); 1099 1038 1100 var name = jQuery(obj).data('name'); 1039 1101 jQuery(obj).parent().parent().hide(); -
linet-erp-woocommerce-integration/trunk/classes/class-wc-li-sns.php
r2747055 r2747151 6 6 Author: Speedcomp 7 7 Author URI: http://www.linet.org.il 8 Version: 3.1. 28 Version: 3.1.3 9 9 Text Domain: wc-linet 10 10 Domain Path: /languages/ -
linet-erp-woocommerce-integration/trunk/readme.txt
r2747055 r2747151 47 47 == Changelog == 48 48 49 = 2022.06.23 - version 3.1.3 = 50 51 * better delete handler 52 * product vartion duplcate finder 53 49 54 = 2022.06.23 - version 3.1.2 = 50 55 -
linet-erp-woocommerce-integration/trunk/woo-includes/class-wc-dependencies.php
r2747055 r2747151 6 6 Author: Speedcomp 7 7 Author URI: http://www.linet.org.il 8 Version: 3.1. 28 Version: 3.1.3 9 9 Text Domain: wc-linet 10 10 Domain Path: /languages/ -
linet-erp-woocommerce-integration/trunk/woo-includes/woo-functions.php
r2747055 r2747151 6 6 Author: Speedcomp 7 7 Author URI: http://www.linet.org.il 8 Version: 3.1. 28 Version: 3.1.3 9 9 Text Domain: wc-linet 10 10 Domain Path: /languages/ -
linet-erp-woocommerce-integration/trunk/woocommerce-linet.php
r2747055 r2747151 6 6 Author: Speedcomp 7 7 Author URI: http://www.linet.org.il 8 Version: 3.1. 28 Version: 3.1.3 9 9 Text Domain: wc-linet 10 10 Domain Path: /languages/ … … 44 44 */ 45 45 class WC_Linet { 46 const VERSION = '3.1. 2';46 const VERSION = '3.1.3'; 47 47 /** 48 48 * The constructor
Note: See TracChangeset
for help on using the changeset viewer.