mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-09-08 10:41:25 +02:00
svn://svn.silverstripe.com/silverstripe/modules/sapphire/branches/2.2.0-mesq ........ r46622 | ischommer | 2007-12-12 10:54:32 +1300 (Wed, 12 Dec 2007) | 1 line added Double dbfield for extended precision (e.g. when saving map-coordinates) ........ git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@52154 467b73ca-7a2a-4603-9d3b-597d59a354a9
15 lines
212 B
PHP
15 lines
212 B
PHP
<?php
|
|
/**
|
|
*
|
|
*/
|
|
class Double extends DBField {
|
|
|
|
function requireField() {
|
|
DB::requireField($this->tableName, $this->name, "double");
|
|
}
|
|
|
|
function Nice() {
|
|
return number_format($this->value, 2);
|
|
}
|
|
}
|
|
?>
|