|
575 | 575 | </processing>
|
576 | 576 | </action>
|
577 | 577 | <action name="share_react" forbidOverride="true"></action>
|
| 578 | + <action name="display_enterprise"> |
| 579 | + <gui text="ajxp_conf.120" title="ajxp_conf.121" iconClass="icon-lightbulb" src="download_manager.png" hasAccessKey="false"> |
| 580 | + <context selection="false" dir="false" recycle="hidden" behaviour="hidden" |
| 581 | + actionBar="false" contextMenu="false" infoPanel="false" inZip="false"> |
| 582 | + </context> |
| 583 | + </gui> |
| 584 | + <processing> |
| 585 | + <clientCallback prepareModal="false" dialogOpenForm="enterprise_advertise_block" dialogOkButtonOnly="true" dialogSkipButtons="false"> |
| 586 | + <dialogOnOpen><![CDATA[ |
| 587 | + var lang = "en"; |
| 588 | + if(pydio && pydio.currentLanguage === "fr") lang = "fr"; |
| 589 | + else if(pydio && pydio.currentLanguage === "de") lang = "de"; |
| 590 | + $(oForm).down("iframe").src = "https://pydio.com/"+lang+"/switch-pydio-enterprise"; |
| 591 | + pydio.Controller.DISPLAY_ENTERPRISE_PING = true; |
| 592 | + ]]></dialogOnOpen> |
| 593 | + <dialogOnComplete hideDialog="true"><![CDATA[]]></dialogOnComplete> |
| 594 | + </clientCallback> |
| 595 | + <clientForm id="enterprise_advertise_block"><![CDATA[ |
| 596 | + <div id="enterprise_advertise_block" box_width="70%" box_padding="0" box_height="80%" box_resize="true" style="height:100%;" class="vertical_layout"> |
| 597 | + <iframe style="width: 100%; height: 90%; border: 0px solid #ddd;" class="vertical_fit"></iframe> |
| 598 | + <div style="padding:20px;"> </div> |
| 599 | + </div> |
| 600 | + ]]></clientForm> |
| 601 | + <clientListener name="init"><![CDATA[ |
| 602 | + var conn = new Connexion(); |
| 603 | + conn.addParameter("get_action", "display_enterprise"); |
| 604 | + conn.onComplete = function(transport){ |
| 605 | + var response = transport.responseJSON; |
| 606 | + if(response && response.display){ |
| 607 | + pydio.Controller.fireAction("display_enterprise"); |
| 608 | + }else if(response && !response.display){ |
| 609 | + pydio.Controller.DISPLAY_ENTERPRISE_PING = true; |
| 610 | + } |
| 611 | + }; |
| 612 | + window.setTimeout(function(){ |
| 613 | + if(!pydio.Controller.DISPLAY_ENTERPRISE_PING){ |
| 614 | + conn.sendAsync(); |
| 615 | + } |
| 616 | + }, 5000); |
| 617 | + ]]></clientListener> |
| 618 | + <serverCallback methodName="displayEnterprise"/> |
| 619 | + </processing> |
| 620 | + </action> |
578 | 621 | </actions>
|
579 | 622 | <client_configs>
|
580 | 623 | <component_config className="InfoPanel">
|
|
0 commit comments