Exemplo n.º 1
0
 public function index()
 {
     $result = Test::first();
     echo "<pre>";
     // var_dump($result);
     $first = Article::find(1);
     var_dump($first->content);
     echo '<h1>this is index</h1>';
     $this->view = View::make('home')->with('article', Article::first())->withTitle('MFFC :-D')->withFuck('Ok!');
 }
 public function testViewDetailsView()
 {
     $url = URL::route('test.viewDetails', array(Test::first()->id));
     // Set the current user to admin
     $this->be(User::first());
     $crawler = $this->client->request('GET', $url);
     $this->assertCount(4, $crawler->filter('div.panel'));
 }
Exemplo n.º 3
0
 public function details($title, $id = '')
 {
     $medicaltest = Test::first(array("id = ?" => $id));
     $services = Service::all(array("property = ?" => "test", "property_id = ?" => $id), array("centre_id", "charge"), "charge", "desc", 10, 1);
     $this->seo(array("title" => $medicaltest->title, "keywords" => $medicaltest->title, "description" => substr(strip_tags($medicaltest->details), 0, 150), "view" => $this->getLayoutView()));
     $view = $this->getActionView();
     $view->set("medicaltest", $medicaltest);
     $view->set("services", $services);
 }