Changeset 3263304
- Timestamp:
- 03/28/2025 08:56:21 AM (10 months ago)
- Location:
- flywp-migrator
- Files:
-
- 4 deleted
- 8 edited
- 1 copied
-
assets/banner-1544x500.png (deleted)
-
assets/banner-772x250.png (deleted)
-
assets/icon-128x128.png (deleted)
-
assets/icon-256x256.png (deleted)
-
tags/1.2.0 (copied) (copied from flywp-migrator/trunk)
-
tags/1.2.0/flywp-migrator.php (modified) (1 diff)
-
tags/1.2.0/includes/Api/Database.php (modified) (2 diffs)
-
tags/1.2.0/readme.txt (modified) (2 diffs)
-
tags/1.2.0/vendor/composer/installed.php (modified) (2 diffs)
-
trunk/flywp-migrator.php (modified) (1 diff)
-
trunk/includes/Api/Database.php (modified) (2 diffs)
-
trunk/readme.txt (modified) (2 diffs)
-
trunk/vendor/composer/installed.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
flywp-migrator/tags/1.2.0/flywp-migrator.php
r3259238 r3263304 4 4 * Plugin URI: https://flywp.com 5 5 * Description: Helps migrate WordPress sites to FlyWP platform 6 * Version: 1. 1.06 * Version: 1.2.0 7 7 * Author: FlyWP 8 8 * Text Domain: flywp-migrator -
flywp-migrator/tags/1.2.0/includes/Api/Database.php
r3256652 r3263304 65 65 ] 66 66 ); 67 68 register_rest_route( 69 $namespace, 70 '/tables/structure', 71 [ 72 'methods' => WP_REST_Server::READABLE, 73 'callback' => [$this, 'get_all_tables_structure'], 74 'permission_callback' => [Api::class, 'check_permission'], 75 ] 76 ); 67 77 } 68 78 … … 303 313 return $this->recursively_fix_serialized_string( $fixed_string, $key + 1 ); 304 314 } 315 316 /** 317 * Get structure of all tables 318 * 319 * @return WP_REST_Response 320 */ 321 public function get_all_tables_structure() { 322 global $wpdb; 323 324 $tables = $wpdb->get_col( 'SHOW TABLES' ); 325 $structures = []; 326 327 foreach ( $tables as $table ) { 328 $structure = $wpdb->get_results( 'SHOW CREATE TABLE `' . esc_sql( $table ) . '`', ARRAY_A ); 329 330 if ( !empty( $structure ) ) { 331 $create_table = $structure[0]['Create Table']; 332 $create_table = str_replace( "CREATE TABLE `$table`", "DROP TABLE IF EXISTS `$table`; CREATE TABLE `$table`", $create_table ); 333 $structures[$table] = $create_table; 334 } 335 } 336 337 return rest_ensure_response( [ 338 'success' => true, 339 'structures' => $structures, 340 ] ); 341 } 305 342 } -
flywp-migrator/tags/1.2.0/readme.txt
r3259238 r3263304 4 4 Requires at least: 6.0 5 5 Tested up to: 6.7 6 Stable tag: 1. 1.06 Stable tag: 1.2.0 7 7 Requires PHP: 7.4 8 8 License: GPL-2.0+ … … 83 83 == Changelog == 84 84 85 = v1.2.0 (28 March, 2025) = 86 87 * **New:** Added REST API endpoint to retrieve the structure of all database tables. 88 85 89 = v1.1.0 (20 March, 2025) = 86 90 -
flywp-migrator/tags/1.2.0/vendor/composer/installed.php
r3259238 r3263304 2 2 'root' => array( 3 3 'name' => 'flywp/flywp-migrator', 4 'pretty_version' => '1. 1.0',5 'version' => '1. 1.0.0',6 'reference' => ' 3ed9ff492a7200fe3461a69ebe649695b7263943',4 'pretty_version' => '1.2.0', 5 'version' => '1.2.0.0', 6 'reference' => '81a78ff3bac67cf38892fcdcdcc9d45baf445cdc', 7 7 'type' => 'wordpress-plugin', 8 8 'install_path' => __DIR__ . '/../../', … … 12 12 'versions' => array( 13 13 'flywp/flywp-migrator' => array( 14 'pretty_version' => '1. 1.0',15 'version' => '1. 1.0.0',16 'reference' => ' 3ed9ff492a7200fe3461a69ebe649695b7263943',14 'pretty_version' => '1.2.0', 15 'version' => '1.2.0.0', 16 'reference' => '81a78ff3bac67cf38892fcdcdcc9d45baf445cdc', 17 17 'type' => 'wordpress-plugin', 18 18 'install_path' => __DIR__ . '/../../', -
flywp-migrator/trunk/flywp-migrator.php
r3259238 r3263304 4 4 * Plugin URI: https://flywp.com 5 5 * Description: Helps migrate WordPress sites to FlyWP platform 6 * Version: 1. 1.06 * Version: 1.2.0 7 7 * Author: FlyWP 8 8 * Text Domain: flywp-migrator -
flywp-migrator/trunk/includes/Api/Database.php
r3256652 r3263304 65 65 ] 66 66 ); 67 68 register_rest_route( 69 $namespace, 70 '/tables/structure', 71 [ 72 'methods' => WP_REST_Server::READABLE, 73 'callback' => [$this, 'get_all_tables_structure'], 74 'permission_callback' => [Api::class, 'check_permission'], 75 ] 76 ); 67 77 } 68 78 … … 303 313 return $this->recursively_fix_serialized_string( $fixed_string, $key + 1 ); 304 314 } 315 316 /** 317 * Get structure of all tables 318 * 319 * @return WP_REST_Response 320 */ 321 public function get_all_tables_structure() { 322 global $wpdb; 323 324 $tables = $wpdb->get_col( 'SHOW TABLES' ); 325 $structures = []; 326 327 foreach ( $tables as $table ) { 328 $structure = $wpdb->get_results( 'SHOW CREATE TABLE `' . esc_sql( $table ) . '`', ARRAY_A ); 329 330 if ( !empty( $structure ) ) { 331 $create_table = $structure[0]['Create Table']; 332 $create_table = str_replace( "CREATE TABLE `$table`", "DROP TABLE IF EXISTS `$table`; CREATE TABLE `$table`", $create_table ); 333 $structures[$table] = $create_table; 334 } 335 } 336 337 return rest_ensure_response( [ 338 'success' => true, 339 'structures' => $structures, 340 ] ); 341 } 305 342 } -
flywp-migrator/trunk/readme.txt
r3259238 r3263304 4 4 Requires at least: 6.0 5 5 Tested up to: 6.7 6 Stable tag: 1. 1.06 Stable tag: 1.2.0 7 7 Requires PHP: 7.4 8 8 License: GPL-2.0+ … … 83 83 == Changelog == 84 84 85 = v1.2.0 (28 March, 2025) = 86 87 * **New:** Added REST API endpoint to retrieve the structure of all database tables. 88 85 89 = v1.1.0 (20 March, 2025) = 86 90 -
flywp-migrator/trunk/vendor/composer/installed.php
r3259238 r3263304 2 2 'root' => array( 3 3 'name' => 'flywp/flywp-migrator', 4 'pretty_version' => '1. 1.0',5 'version' => '1. 1.0.0',6 'reference' => ' 3ed9ff492a7200fe3461a69ebe649695b7263943',4 'pretty_version' => '1.2.0', 5 'version' => '1.2.0.0', 6 'reference' => '81a78ff3bac67cf38892fcdcdcc9d45baf445cdc', 7 7 'type' => 'wordpress-plugin', 8 8 'install_path' => __DIR__ . '/../../', … … 12 12 'versions' => array( 13 13 'flywp/flywp-migrator' => array( 14 'pretty_version' => '1. 1.0',15 'version' => '1. 1.0.0',16 'reference' => ' 3ed9ff492a7200fe3461a69ebe649695b7263943',14 'pretty_version' => '1.2.0', 15 'version' => '1.2.0.0', 16 'reference' => '81a78ff3bac67cf38892fcdcdcc9d45baf445cdc', 17 17 'type' => 'wordpress-plugin', 18 18 'install_path' => __DIR__ . '/../../',
Note: See TracChangeset
for help on using the changeset viewer.