With helps of ngRoute a template can be loaded which is containing a script tag which includes the js file contains javascript codes that we wanted to run.
Please take a look the below example for usage:
This is the place where I store the words when I surfing. Share with u.
这里放着我在网上看到的文章,和你一起分享。
$accounts = AccountQuery::create()
->joinWith('Account.AdditionalData')
->addJoin(AdditionalDataPeer::VAL, CountryPeer::ID)
->withColumn('country.name', 'CountryName')
->find();
->joinWith('Account.AdditionalData')
->addJoin(AdditionalDataPeer::VAL, CountryPeer::ID)
->withColumn('country.name', 'CountryName')
foreach ($accounts as $account) {
print $account->getVirtualColumn('CountryName') . PHP_EOL;
}$qand override its defer function.defer() it runs your own version which also increments a counter. Before handing out the defer object, you register a finally callback (Angular 1.2.0 only but always may fit, too) to decrement the counter.$rootScope to monitor when this counter is greater than 0 (faster than having pendingPromisses in $rootScope and bind like ng-show="pendingPromisses > 0").app.config(function($provide) {
$provide.decorator('$q', ['$delegate', '$rootScope', function($delegate, $rootScope) {
var pendingPromisses = 0;
$rootScope.$watch(
function() { return pendingPromisses > 0; },
function(loading) { $rootScope.loading = loading; }
);
var $q = $delegate;
var origDefer = $q.defer;
$q.defer = function() {
var defer = origDefer();
pendingPromisses++;
defer.promise.finally(function() {
pendingPromisses--;
});
return defer;
};
return $q;
}]);
});$rootScope can have:<span ng-show="loading">Loading, please wait</span><?php namespace Cordova\CrownBundle\Command; use Symfony\Bundle\FrameworkBundle\Command\Command; use Symfony\Component\Console\Input\InputArgument; use Symfony\Component\Console\Input\InputInterface; use Symfony\Component\Console\Input\InputOption; use Symfony\Component\Console\Output\OutputInterface; use Symfony\Component\Console\Input\ArrayInput; class SetupCommand extends Command { protected function configure() { $this ->setName('crown:setup') ->setDescription('Crown Setup') ->addArgument('yesno', InputArgument::REQUIRED, 'Do you want to fire up setup? (y/n)') //->addOption('yell', null, InputOption::VALUE_NONE, 'If set, the task will yell in uppercase letters') ; } protected function execute(InputInterface $input, OutputInterface $output) { $yesno = $input->getArgument('yesno'); if ($yesno == 'y') { $text = 'Running setup ... '; $command = $this->getApplication()->find('doctrine:fixtures:load'); $arguments = array( //'--force' => true '' ); $input = new ArrayInput($arguments); $returnCode = $command->run($input, $output); if($returnCode == 0) { $text .= 'fixtures successfully loaded ...'; } } else { $text = 'Exiting ...'; } /*if ($input->getOption('yell')) { $text = strtoupper($text); }*/ $output->writeln($text); } } |
$results = OneQuery::create()
->useTwoQuery(null, Criteria::LEFT_JOIN)
->filterByText('aaa')
->useThreeQuery(null, Criteria::LEFT_JOIN)
->filterByText('bbb')
->endUse()
->endUse()
->find();