Re: [xwiki-users] Integrate bpmn-js into xWiki

2016-10-15 Thread felix
Hi there,

does anybody know about any progress on integrating bpmn-js into xWiki?

Thanks a lot for your support,

Best
Felix


Marius Dumitru Florea wrote
> Btw, I'm pushing for webjars because I would love to see a bpmn
> integration
> extension published on extensions.xwiki.org
> 
> Thanks,
> Marius





--
View this message in context: 
http://xwiki.475771.n2.nabble.com/Integrate-bpmn-js-into-xWiki-tp7593969p7601591.html
Sent from the XWiki- Users mailing list archive at Nabble.com.
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Integrate bpmn-js into xWiki

2015-02-15 Thread Marius Dumitru Florea
First of all see
http://platform.xwiki.org/xwiki/bin/view/DevGuide/JavaScriptAPI#HRequireJSandjQueryAPIs
. You should use jQuery through RequireJS or otherwise use the
'jQuery' variable as '$' is taken by Prototype.js .

I advise you to use RequireJS for the rest of your JavaScript
resources too. You can configure RequrieJS to specify where each
resource is. See [1] and [2] for instance. You should also take into
account using WebJars [3] as this will allow you to create an
extension that can be installed on any XWiki instance easily through
the Extension Manager (all dependencies being resolved and installed
automatically). Most of the well known JavaScript libraries are
available as a WebJar [4].

Hope this helps,
Marius

[1] 
https://github.com/xwiki/xwiki-platform/blob/master/xwiki-platform-core/xwiki-platform-panels/xwiki-platform-panels-ui/src/main/resources/PanelsCode/ApplicationsPanelConfigurationSheet.xml#L126
[2] 
https://github.com/xwiki-contrib/application-filemanager/blob/master/ui/src/main/resources/FileManagerCode/DriveSheet.xml#L571
[3] http://extensions.xwiki.org/xwiki/bin/view/Extension/WebJars+Integration
[4] http://www.webjars.org/

On Sat, Feb 14, 2015 at 10:53 AM, carlez senzacquaca...@gmail.com wrote:
 Hello! I'm trying to integrate bpmn-js into my xWiki application.

 I istalled bpmn-js via bower into xWiki resource folder and then i created a
 page with this content:


 When the page loads (and the javascript libs are imported) I get some errors
 about prototype.js and requirejs (http://pastie.org/9946255). How can I fix
 this problem??




 --
 View this message in context: 
 http://xwiki.475771.n2.nabble.com/Integrate-bpmn-js-into-xWiki-tp7593969.html
 Sent from the XWiki- Users mailing list archive at Nabble.com.
 ___
 users mailing list
 users@xwiki.org
 http://lists.xwiki.org/mailman/listinfo/users
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Integrate bpmn-js into xWiki

2015-02-15 Thread carlez
Thanks for the reply Marius!
I find webjars project of bpmn-js lib
(https://github.com/bpmn-io/webjar-bpmn-js) and I read the documentation
about xwiki and webjars but i don't understand what I have to do!

Do I have to write a component? Can you explain me how to proceed to use
this webjar? Thanks for your patience!



--
View this message in context: 
http://xwiki.475771.n2.nabble.com/Integrate-bpmn-js-into-xWiki-tp7593969p7593978.html
Sent from the XWiki- Users mailing list archive at Nabble.com.
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Integrate bpmn-js into xWiki

2015-02-15 Thread Marius Dumitru Florea
On Feb 15, 2015 1:30 PM, carlez senzacquaca...@gmail.com wrote:

 Thanks for the reply Marius!
 I find webjars project of bpmn-js lib
 (https://github.com/bpmn-io/webjar-bpmn-js) and I read the documentation
 about xwiki and webjars but i don't understand what I have to do!


 Do I have to write a component? Can you explain me how to proceed to use
 this webjar? Thanks for your patience!

No, you don't have to ceate any component. For developmemnt you start by
downloading all the webjars you need and copy them to WEB-INF/lib (like you
would do with any jar) and restart the server. Then you obtain the URL to
the resources from the webjars using the webjar script service as indicated
on the documentation page. You configure Require.js with these URLs and it
will take care of loading them (as in the examples I linked).

So far this is not different from puting the JavaScript files in the
resources folder and using $xwiki.getSkinFile() with Require.js . The
advantage of using webjars is the fact that after you develop the bpmn
integration you can create an extension that declares its webjar
dependencies and the Extension Manager will be able to install them
automatically. That is because EM knows how to install jars (so webjars
too) but it cannot install JavaScript files in the resources folder.

Hope this helps,
Marius




 --
 View this message in context:
http://xwiki.475771.n2.nabble.com/Integrate-bpmn-js-into-xWiki-tp7593969p7593978.html
 Sent from the XWiki- Users mailing list archive at Nabble.com.
 ___
 users mailing list
 users@xwiki.org
 http://lists.xwiki.org/mailman/listinfo/users
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Integrate bpmn-js into xWiki

2015-02-15 Thread Marius Dumitru Florea
Btw, I'm pushing for webjars because I would love to see a bpmn integration
extension published on extensions.xwiki.org

Thanks,
Marius

On Feb 15, 2015 3:14 PM, Marius Dumitru Florea 
mariusdumitru.flo...@xwiki.com wrote:

 On Feb 15, 2015 1:30 PM, carlez senzacquaca...@gmail.com wrote:
 
  Thanks for the reply Marius!
  I find webjars project of bpmn-js lib
  (https://github.com/bpmn-io/webjar-bpmn-js) and I read the documentation
  about xwiki and webjars but i don't understand what I have to do!
 

  Do I have to write a component? Can you explain me how to proceed to use
  this webjar? Thanks for your patience!

 No, you don't have to ceate any component. For developmemnt you start by
downloading all the webjars you need and copy them to WEB-INF/lib (like you
would do with any jar) and restart the server. Then you obtain the URL to
the resources from the webjars using the webjar script service as indicated
on the documentation page. You configure Require.js with these URLs and it
will take care of loading them (as in the examples I linked).

 So far this is not different from puting the JavaScript files in the
resources folder and using $xwiki.getSkinFile() with Require.js . The
advantage of using webjars is the fact that after you develop the bpmn
integration you can create an extension that declares its webjar
dependencies and the Extension Manager will be able to install them
automatically. That is because EM knows how to install jars (so webjars
too) but it cannot install JavaScript files in the resources folder.

 Hope this helps,
 Marius

 
 
 
  --
  View this message in context:
http://xwiki.475771.n2.nabble.com/Integrate-bpmn-js-into-xWiki-tp7593969p7593978.html
  Sent from the XWiki- Users mailing list archive at Nabble.com.
  ___
  users mailing list
  users@xwiki.org
  http://lists.xwiki.org/mailman/listinfo/users
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users