SubjectStat.php 456 B

12345678910111213141516171819202122232425262728
  1. <?php
  2. /**
  3. * Created by PhpStorm.
  4. * User: qisse
  5. * Date: 2017/6/27
  6. * Time: 20:02
  7. */
  8. namespace app\core\model;
  9. use think\Model;
  10. use tool\Common;
  11. class SubjectStat extends Model
  12. {
  13. protected $resultSetType = 'collection';
  14. protected $pk = 'subjectStatID';
  15. public function setMoneyTotalInvestAttr($value) {
  16. return $value * 100;
  17. }
  18. public function getMoneyTotalInvestAttr($value) {
  19. return (int)($value / 100);
  20. }
  21. }