Changeset 3332502
- Timestamp:
- 07/22/2025 08:23:27 PM (4 months ago)
- Location:
- wine-cellar-manager
- Files:
-
- 8 edited
- 1 copied
- tags/3.1.3 (copied) (copied from wine-cellar-manager/trunk)
- tags/3.1.3/class/idealconsumptionalert/wineCellarManager_consumption-notifier_Class.php (modified) (3 diffs)
- tags/3.1.3/readme.txt (modified) (1 diff)
- tags/3.1.3/templates/admin/admin-sidebar.php (modified) (1 diff)
- tags/3.1.3/wine-cellar-manager.php (modified) (1 diff)
- trunk/class/idealconsumptionalert/wineCellarManager_consumption-notifier_Class.php (modified) (3 diffs)
- trunk/readme.txt (modified) (1 diff)
- trunk/templates/admin/admin-sidebar.php (modified) (1 diff)
- trunk/wine-cellar-manager.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
wine-cellar-manager/tags/3.1.3/class/idealconsumptionalert/wineCellarManager_consumption-notifier_Class.php
r3331698 r3332502 104 104 continue; 105 105 } 106 106 $qty = get_post_meta( get_the_ID(), 'quantity', true ) ?? ''; 107 if(!$qty) continue; 107 108 list( $month, $year ) = explode( '/', $value ); 108 109 $alert_date = DateTime::createFromFormat( 'Y-m-d', "$year-$month-01" ); … … 135 136 } 136 137 137 $to = get_option( 'admin_email' ); 138 $to = get_option( 'winecm_notification_email' ); 139 if ( ! is_email( $to ) ) { 140 $to = get_option( 'admin_email' ); 141 } 142 138 143 $subject = __( 'Wine Cellar – Ideal Consumption Alerts', 'wine-cellar-manager' ); 139 144 140 $body = __( "These are the wines requiring your attention:\n", 'wine-cellar-manager' ); 145 $body = __( "Hello,\n\n", 'wine-cellar-manager' ); 146 $body .= __( "These are the wines requiring your attention:\n", 'wine-cellar-manager' ); 141 147 142 148 if ( $expired ) { … … 154 160 } 155 161 162 // Footer 163 $site_name = get_bloginfo( 'name' ); 164 $site_url = home_url(); 165 166 $body .= "\n\n—\n"; 167 $body .= sprintf( 168 __( "This is an automatic notification from the plugin Wine Cellar Manager, running on the site %s (%s).", 'wine-cellar-manager' ), 169 $site_name, 170 $site_url 171 ); 172 $body .= "\n" . __( "You're receiving this message because ideal consumption alerts are enabled. You can configure this in the plugin settings.", 'wine-cellar-manager' ); 173 156 174 $headers = ['Content-Type: text/plain; charset=UTF-8']; 157 175 wp_mail( $to, $subject, $body, $headers ); 176 158 177 } 159 178 } -
wine-cellar-manager/tags/3.1.3/readme.txt
r3331698 r3332502 5 5 Requires PHP: 7.2.5 6 6 Tested up to: 6.8 7 Stable tag: 3.1. 27 Stable tag: 3.1.3 8 8 License: GPLv2 or later 9 9 License URI: https://www.gnu.org/licenses/gpl-2.0.html -
wine-cellar-manager/tags/3.1.3/templates/admin/admin-sidebar.php
r3331698 r3332502 13 13 <div style="width: 300px; background: #f9f9f9; border: 1px solid #ddd; padding: 15px; border-radius: 4px;"> 14 14 <h2><?php esc_html_e( 'Plugin Info', 'wine-cellar-manager' ); ?></h2> 15 <p><?php esc_html_e( 'Version 3.1. 2', 'wine-cellar-manager' ); ?> — <a href="https://profiles.wordpress.org/matteoenna/" target="_blank"><?php esc_html_e( 'by Matteo Enna', 'wine-cellar-manager' ); ?></a></p>15 <p><?php esc_html_e( 'Version 3.1.3', 'wine-cellar-manager' ); ?> — <a href="https://profiles.wordpress.org/matteoenna/" target="_blank"><?php esc_html_e( 'by Matteo Enna', 'wine-cellar-manager' ); ?></a></p> 16 16 </div> 17 17 </div> -
wine-cellar-manager/tags/3.1.3/wine-cellar-manager.php
r3331698 r3332502 3 3 Plugin Name: Wine Cellar Manager 4 4 Description: A plugin to manage your wine inventory. 5 Version: 3.1. 25 Version: 3.1.3 6 6 Author: Matteo Enna 7 7 Author URI: https://matteoenna.it/it/wordpress-work/ -
wine-cellar-manager/trunk/class/idealconsumptionalert/wineCellarManager_consumption-notifier_Class.php
r3331698 r3332502 104 104 continue; 105 105 } 106 106 $qty = get_post_meta( get_the_ID(), 'quantity', true ) ?? ''; 107 if(!$qty) continue; 107 108 list( $month, $year ) = explode( '/', $value ); 108 109 $alert_date = DateTime::createFromFormat( 'Y-m-d', "$year-$month-01" ); … … 135 136 } 136 137 137 $to = get_option( 'admin_email' ); 138 $to = get_option( 'winecm_notification_email' ); 139 if ( ! is_email( $to ) ) { 140 $to = get_option( 'admin_email' ); 141 } 142 138 143 $subject = __( 'Wine Cellar – Ideal Consumption Alerts', 'wine-cellar-manager' ); 139 144 140 $body = __( "These are the wines requiring your attention:\n", 'wine-cellar-manager' ); 145 $body = __( "Hello,\n\n", 'wine-cellar-manager' ); 146 $body .= __( "These are the wines requiring your attention:\n", 'wine-cellar-manager' ); 141 147 142 148 if ( $expired ) { … … 154 160 } 155 161 162 // Footer 163 $site_name = get_bloginfo( 'name' ); 164 $site_url = home_url(); 165 166 $body .= "\n\n—\n"; 167 $body .= sprintf( 168 __( "This is an automatic notification from the plugin Wine Cellar Manager, running on the site %s (%s).", 'wine-cellar-manager' ), 169 $site_name, 170 $site_url 171 ); 172 $body .= "\n" . __( "You're receiving this message because ideal consumption alerts are enabled. You can configure this in the plugin settings.", 'wine-cellar-manager' ); 173 156 174 $headers = ['Content-Type: text/plain; charset=UTF-8']; 157 175 wp_mail( $to, $subject, $body, $headers ); 176 158 177 } 159 178 } -
wine-cellar-manager/trunk/readme.txt
r3331698 r3332502 5 5 Requires PHP: 7.2.5 6 6 Tested up to: 6.8 7 Stable tag: 3.1. 27 Stable tag: 3.1.3 8 8 License: GPLv2 or later 9 9 License URI: https://www.gnu.org/licenses/gpl-2.0.html -
wine-cellar-manager/trunk/templates/admin/admin-sidebar.php
r3331698 r3332502 13 13 <div style="width: 300px; background: #f9f9f9; border: 1px solid #ddd; padding: 15px; border-radius: 4px;"> 14 14 <h2><?php esc_html_e( 'Plugin Info', 'wine-cellar-manager' ); ?></h2> 15 <p><?php esc_html_e( 'Version 3.1. 2', 'wine-cellar-manager' ); ?> — <a href="https://profiles.wordpress.org/matteoenna/" target="_blank"><?php esc_html_e( 'by Matteo Enna', 'wine-cellar-manager' ); ?></a></p>15 <p><?php esc_html_e( 'Version 3.1.3', 'wine-cellar-manager' ); ?> — <a href="https://profiles.wordpress.org/matteoenna/" target="_blank"><?php esc_html_e( 'by Matteo Enna', 'wine-cellar-manager' ); ?></a></p> 16 16 </div> 17 17 </div> -
wine-cellar-manager/trunk/wine-cellar-manager.php
r3331698 r3332502 3 3 Plugin Name: Wine Cellar Manager 4 4 Description: A plugin to manage your wine inventory. 5 Version: 3.1. 25 Version: 3.1.3 6 6 Author: Matteo Enna 7 7 Author URI: https://matteoenna.it/it/wordpress-work/
Note: See TracChangeset for help on using the changeset viewer.