Client-side changes don't apply after deployment the AMP

cancel
Showing results for 
Search instead for 
Did you mean: 
anon26949
Established Member

Client-side changes don't apply after deployment the AMP

Jump to solution

I made changes to the people-finder.js script to change the sort order, and locally everything works well.
To override the functionality, I used the following directory structure and Maven-based SDK to generate AMP file:

As I expected, locally everything works fine and I can see my changes:

Next, I deploy the file on the remote server, as described here: Install the AMP file

And here I do not see my changes:

Directory /opt/alfresco-community/tomcat/webapps/share/components/people-finder also contains the scripts without changes.

And thus, sorting does not work as I need.

Additional information: I unpacked the AMP file and not found there branch /web/components/... Of course, people-finder.js and people-finder-min.js is not present there also. In the AMP file, there are my other changes and they have successfully applied (labels and other small things).

What could be the reason?

I would be very grateful for the information. Thanks to all.

1 Solution

Accepted Solutions
jpotts
Professional

Re: Client-side changes don't apply after deployment the AMP

Jump to solution

When you run "mvn clean package" does your JS file get added to the AMP or not?

If it does get added to the AMP, that's good. If it does not, check to make sure your file-mapping.properties has "/web=/" in it.

Assuming your AMP is okay, when you install the AMP are there any errors reported? You may have to scroll up through the AMP listing if you have several AMPs. I believe you are replacing an out-of-the-box file so you may have to specify "-force" when you run apply_amps.sh.

Also, just a side-note, it looks like you've added a "min" file to your project. You shouldn't need to do that because Maven should be minifying your JS for you.

View solution in original post

1 Reply
jpotts
Professional

Re: Client-side changes don't apply after deployment the AMP

Jump to solution

When you run "mvn clean package" does your JS file get added to the AMP or not?

If it does get added to the AMP, that's good. If it does not, check to make sure your file-mapping.properties has "/web=/" in it.

Assuming your AMP is okay, when you install the AMP are there any errors reported? You may have to scroll up through the AMP listing if you have several AMPs. I believe you are replacing an out-of-the-box file so you may have to specify "-force" when you run apply_amps.sh.

Also, just a side-note, it looks like you've added a "min" file to your project. You shouldn't need to do that because Maven should be minifying your JS for you.