Beispiel #1
0
 function get(Direct $direct, Service $service)
 {
     header('Content-type: text/javascript');
     echo 'Ext.Direct.addProvider({
         type: "remoting",
         url: "' . $direct->getUrl() . '",
         actions: ' . json_encode($service->getActions()) . '
     });';
 }
Beispiel #2
0
 function testServiceArguments()
 {
     $service = new Service('Common\\Api', 'Common\\Sys');
     $anotherService = new Service(array('Common\\Api', 'Common\\Sys'));
     $this->assertSame(json_encode($service->getActions()), json_encode($anotherService->getActions()));
 }