includes/api/class-wc-api-coupons.php 1 location
|
@@ 416-418 (lines=3) @@
|
413 |
|
update_post_meta( $id, 'usage_count', absint( $data['usage_count'] ) ); |
414 |
|
} |
415 |
|
|
416 |
|
if ( isset( $data['expiry_date'] ) ) { |
417 |
|
update_post_meta( $id, 'expiry_date', $this->get_coupon_expiry_date( wc_clean( $data['expiry_date'] ) ) ); |
418 |
|
} |
419 |
|
|
420 |
|
if ( isset( $data['enable_free_shipping'] ) ) { |
421 |
|
update_post_meta( $id, 'free_shipping', ( true === $data['enable_free_shipping'] ) ? 'yes' : 'no' ); |
includes/cli/class-wc-cli-coupon.php 1 location
|
@@ 506-508 (lines=3) @@
|
503 |
|
update_post_meta( $id, 'usage_count', absint( $data['usage_count'] ) ); |
504 |
|
} |
505 |
|
|
506 |
|
if ( isset( $data['expiry_date'] ) ) { |
507 |
|
update_post_meta( $id, 'expiry_date', $this->get_coupon_expiry_date( wc_clean( $data['expiry_date'] ) ) ); |
508 |
|
} |
509 |
|
|
510 |
|
if ( isset( $data['enable_free_shipping'] ) ) { |
511 |
|
update_post_meta( $id, 'free_shipping', ( true === $data['enable_free_shipping'] ) ? 'yes' : 'no' ); |