public function trackView()
    {
        if ($this->ID > 0) {
            $count = $this->ViewCount + 1;

            $this->ViewCount = $count;

            DB::query("UPDATE \"DMSDocument\" SET \"ViewCount\"='$count' WHERE \"ID\"={$this->ID}");

            $this->extend('trackView');
        }

        return $this;
    }
public function trackView()
    {
        if ($this->ID > 0) {
            $count = $this->ViewCount + 1;

            $this->ViewCount = $count;

            DB::query("UPDATE \"DMSDocument\" SET \"ViewCount\"='$count' WHERE \"ID\"={$this->ID}");

            $this->extend('trackView');
        }

        return $this;
    }
public function trackView ( ) { if ( $ this -> ID > 0 ) { $ count = $ this -> ViewCount + 1 ; $ this -> ViewCount = $ count ; DB :: query ( "UPDATE \"DMSDocument\" SET \"ViewCount\"='$count' WHERE \"ID\"={$this->ID}" ) ; $ this -> extend ( 'trackView' ) ; } return $ this ; }
Increase ViewCount by 1, without update any other record fields such as
LastEdited.

@return DMSDocument
Increase ViewCount by 1 without update any other record fields such as LastEdited .