コード例 #1
0
 public function getStateAction()
 {
     $frontendButtonDisabled = false;
     if (SearchPhp_Plugin::frontendCrawlerRunning() or SearchPhp_Plugin::frontendCrawlerScheduledForStart() or !SearchPhp_Plugin::frontendConfigComplete()) {
         $frontendButtonDisabled = true;
     }
     $message = str_replace("------------------------------------------- ", "<br/>", SearchPhp_Plugin::getPluginState());
     $frontendStopButtonDIsabled = false;
     if (!SearchPhp_Plugin::frontendConfigComplete() or !SearchPhp_Plugin::frontendCrawlerRunning() or SearchPhp_Plugin::frontendCrawlerStopLocked()) {
         $frontendStopButtonDIsabled = true;
     }
     $this->_helper->json(array("message" => $message, "frontendButtonDisabled" => $frontendButtonDisabled, "frontendStopButtonDisabled" => $frontendStopButtonDIsabled));
 }
コード例 #2
0
                            });

                        }
                    }

                },{
                    xtype:'button',
                    style: 'margin: 0 0 0 5px',  
                    hideLabel: true,
                    text: '<?php 
echo $this->translate->_("searchphp_stop_crawler");
?>
',
                    id: 'stopFrontendCrawler',
                    disabled: <?php 
if (!SearchPhp_Plugin::frontendCrawlerRunning()) {
    echo 'true';
} else {
    echo 'false';
}
?>
,
                    listeners: {
                        click: function(button, event) {

                            searchPhpCrawlerLoadingMask = new Ext.LoadMask(Ext.get("f1Form"), {
                                id:"crawler-stop-mask",
                                msg:"<?php 
echo $this->translate->_("searchphp_please_wait");
?>
"