This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
use lithium\net\http\Media; | |
/** | |
* This re-maps your template paths so you can have stuff like `pages/users_{username}.php` | |
* instead of the Lithium default. | |
*/ | |
Media::type('html', 'text/html', array( | |
'view' => 'lithium\template\View', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace app\tests\cases\controllers; | |
use app\tests\mocks\MockArticlesController; | |
use app\tests\mocks\action\MockControllerRequest as Request; //Mocking the Request | |
class ArticlesControllerTest extends \lithium\test\Unit { | |
protected $_controller; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace my_app\models; | |
use MongoId; | |
use lithium\data\collection\DocumentSet; | |
use lithium\data\entity\Document; | |
use lithium\util\Inflector; | |
use lithium\core\Libraries; | |
use lithium\util\Set; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class BaseModel extends \lithium\data\Model { | |
public function save($entity, $data = null, array $options = []) { | |
$now = new \MongoDate(); | |
if (!$entity->exists()) { | |
$entity->created = $now; | |
} | |
$entity->updated = $now; | |
return parent::save($entity, $data, $options); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var FormView = Backbone.View.extend({ | |
el: '#form', | |
events: { | |
// Fired automatically when a file-type input is detected with a | |
// non-blank value. You can use this hook to implement a handler that | |
// will deal with those non-blank file inputs. Returning false will | |
// disallow standard form submission. | |
'ajax:aborted:file' : 'ajaxAbortedFile', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"repositories": [{ | |
"type": "package", | |
"package": { | |
"name": "unionofrad/lithium/lithium", | |
"version": "dev-master", | |
"type": "lithium-library", | |
"source": { | |
"url": "https://github.com/UnionOfRAD/lithium", | |
"type": "git", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "http-server", | |
"preferGlobal": true, | |
"version": "0.3.0", | |
"author": "Nodejitsu <[email protected]>", | |
"description": "a simple zero-configuration command-line http server", | |
"contributors": [ | |
{ | |
"name": "Marak Squires", | |
"email": "[email protected]" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | |
// for details. All rights reserved. Use of this source code is governed by a | |
// BSD-style license that can be found in the LICENSE file. | |
library model; | |
import 'package:polymer/polymer.dart'; | |
final appModel = new AppModel._(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace app\models; | |
class BaseModel extends \lithium\data\Model { | |
public function save($entity, $data = null, array $options = []) { | |
$now = new DateTime(); | |
if (!$entity->exists()) { | |
$entity->created = $now; | |
} | |
$entity->updated = $now; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace jojo\tests\cases\extensions\util; | |
use lithium\util\Validator; | |
class ValidatorTest extends \lithium\test\Unit { | |
public function setUp() { | |
} |
OlderNewer