3

In alfresco share, having a page, is there any way to figure out which .js file is associated with it ?

Cœur
  • 37,241
  • 25
  • 195
  • 267

2 Answers2

4

In Alfresco Share a Page aggregates a whole lot of Surf components, each of which have typically a Javascript controller. There's a great tool to debug your Share pages which is called SurfBug. It will tell you the associated controllers and view for all the Surf components on a page.

skuro
  • 13,414
  • 1
  • 48
  • 67
0

Do you mean javascript file for java script controller or for event trigger java script file?

  1. For java script controller,

You can see directly using SurfBug for viewing surf components files according to previous answer. For example, workflow-list component in workflow listing page, workflow-list.get.js is javascript controller file.

  1. For event trigger javascript file,

Usually this file is indicated by XXXXX.head.ftl file. For example, workflow-list.get.head.ftl file

<#include "../component.head.inc">
<!-- Common Workflow Actions -->
<@script type="text/javascript" src="${page.url.context}/res/components/workflow/workflow-actions.js"></@script>
<!-- Workflow List -->
<@link rel="stylesheet" type="text/css" href="${page.url.context}/res/components/workflow/workflow-list.css" />
<@script type="text/javascript" src="${page.url.context}/res/components/workflow/workflow-list.js"></@script>

In this example, workflow-list.js is the javascript event handler file.

swemon
  • 5,840
  • 4
  • 32
  • 54