Change all remaining URLs from #/style to ?path=style

This commit is contained in:
Daniel Rey López 2019-07-01 09:15:46 +01:00
parent 4032c09e67
commit eef988239e
9 changed files with 11 additions and 10 deletions

View File

@ -49,9 +49,9 @@ class ChartBlock extends Component {
<a
className="screen-reader-text"
href={ getAdminLink(
'admin.php?page=wc-admin#/analytics/' +
'admin.php?page=wc-admin&path=/analytics/' +
charts[ 0 ].endpoint +
'?chart=' +
'&chart=' +
charts[ 0 ].key
) }
>

View File

@ -189,7 +189,7 @@ class OrdersPanel extends Component {
'woocommerce-admin'
) }
actionLabel={ __( 'Settings', 'woocommerce-admin' ) }
actionURL={ getAdminLink( 'admin.php?page=wc-admin#/analytics/settings' ) }
actionURL={ getAdminLink( 'admin.php?page=wc-admin&path=/analytics/settings' ) }
/>
);
}

View File

@ -28,6 +28,6 @@ There are also some helper scripts:
## Dev Docs
There is a "devdocs" page which is useful for displaying components individually outside of the application. It can be viewed via a normal `npm start` build at `http://<your-wp-site>/wp-admin/admin.php?page=wc-admin#/devdocs`.
There is a "devdocs" page which is useful for displaying components individually outside of the application. It can be viewed via a normal `npm start` build at `http://<your-wp-site>/wp-admin/admin.php?page=wc-admin&path=/devdocs`.
This is useful for viewing of [WooCommerce components](https://woocommerce.github.io/woocommerce-admin/#/components/) components and ad-hoc testing.

View File

@ -20,4 +20,4 @@ You can use [`card/example.md`](https://raw.githubusercontent.com/woocommerce/wo
Keep these alphabetized. Optional properties here are `render`, `filePath`, and `docPath`. `render` defaults to `My{ComponentName}`, and `filePath` defaults to `/docs/component/packages/{component-name-as-slug}`. `docPath` designates the origin of the component and efaults to `packages` for components from `/packages/components`.
Now you can visit `/wp-admin/admin.php?page=wc-admin#/devdocs` to see your component in action.
Now you can visit `/wp-admin/admin.php?page=wc-admin&path=/devdocs` to see your component in action.

View File

@ -211,9 +211,10 @@ class WC_Admin_REST_Onboarding_Plugins_Controller extends WC_REST_Data_Controlle
add_query_arg(
array(
'page' => 'wc-admin',
'step' => $next_step_slug,
),
admin_url( 'admin.php' )
) . '#/?step=' . $next_step_slug
)
);
$connect_url = Jetpack::init()->build_connect_url( true, $redirect_url, 'woocommerce-setup-wizard' );

View File

@ -384,7 +384,7 @@ class WC_Admin_Loader {
<div class="woocommerce-layout__header is-embed-loading">
<h1 class="woocommerce-layout__header-breadcrumbs">
<span>
<a href="<?php echo esc_url( admin_url( 'admin.php?page=wc-admin#/' ) ); ?>"><?php esc_html_e( 'WooCommerce', 'woocommerce-admin' ); ?></a>
<a href="<?php echo esc_url( admin_url( 'admin.php?page=wc-admin' ) ); ?>"><?php esc_html_e( 'WooCommerce', 'woocommerce-admin' ); ?></a>
</span>
<?php foreach ( $sections as $section ) : ?>
<?php self::output_breadcrumbs( $section ); ?>

View File

@ -48,7 +48,7 @@ class WC_Admin_Notes_Historical_Data {
$note->add_action(
'get-started',
__( 'Get Started', 'woocommerce-admin' ),
'?page=wc-admin#/analytics/settings',
'?page=wc-admin&path=/analytics/settings',
'actioned',
true
);

View File

@ -99,7 +99,7 @@ class WC_Admin_Notes_New_Sales_Record {
// We only want one sales record note at any time in the inbox, so we delete any other first.
WC_Admin_Notes::delete_notes_with_name( self::NOTE_NAME );
$report_url = '?page=wc-admin#/analytics/revenue?period=custom&compare=previous_year&after=' . $yesterday . '&before=' . $yesterday;
$report_url = '?page=wc-admin&path=/analytics/revenue&period=custom&compare=previous_year&after=' . $yesterday . '&before=' . $yesterday;
// And now, create our new note.
$note = new WC_Admin_Note();

View File

@ -256,7 +256,7 @@ class WC_Admin_Notes_Order_Milestones {
return array(
'name' => 'review-orders',
'label' => __( 'Review your orders', 'woocommerce-admin' ),
'query' => '?page=wc-admin#/analytics/orders',
'query' => '?page=wc-admin&path=/analytics/orders',
);
default:
return array(