In SuiteCommerce Advanced, I have replaced the SSP...
# ask-stanley-ai
m
In SuiteCommerce Advanced, I have replaced the SSP application url because I have a new SCA version installed. Before I was working with the SCA version 2019 and now I have the version 2024. The route for the touchPoints has changed. But some clients have still the old routes and when they open theses routes the theme by defaull is displayed. How can I redirect from the route 2019 to the latest one I have, SCA 2024 ?
c
AI generated answer (using internal Slack threads):
To redirect from the old route to the new one in SuiteCommerce Advanced (SCA), you can use the
Router
module in SCA. This module allows you to define routes and their corresponding functions. Here's a basic example of how you can use it:
Copy code
javascript
define('MyRouter', ['Router'], function (Router) {
    'use strict';

    return Router.extend({
        routes: {
            'old-route': 'redirectToNewRoute'
        },

        initialize: function () {
            Router.prototype.initialize.apply(this, arguments);
        },

        redirectToNewRoute: function () {
            // Here you can put the logic to redirect to the new route
            Backbone.history.navigate('new-route', {trigger: true});
        }
    });
});
In this example, when the 'old-route' is accessed, the
redirectToNewRoute
function is called, which redirects to 'new-route'. You would replace 'old-route' with the route for SCA 2019 and 'new-route' with the route for SCA 2024. Remember to add this router to the list of routers when you start your application. ****** Disclaimer: This response was generated by an artificial intelligence assistant based on previous conversations from multiple Slack channels, and may contain inaccuracies or mistakes. ******
Slack thread 1: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.815063477
Slack thread 2: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.805847168
Slack thread 3: here (available only if the original thread was posted in the last 90 days)
Similarity score: 0.805236876
Please provide your feedback on this answer.