dever 6 years ago
parent
commit
bcc1e08b08
2 changed files with 15 additions and 0 deletions
  1. 13 0
      tm/lib/Controller/UserHelp.class.php
  2. 2 0
      tm/lib/Dao/LotteryUserHelp.class.php

+ 13 - 0
tm/lib/Controller/UserHelp.class.php

@@ -11,6 +11,19 @@ use KIF\Core\Request;
 
 class UserHelp  extends EventsController {
 
+	public function doTest() {
+
+		$this->LotteryUserHelp = new LotteryUserHelp ();
+
+		$condition = array();
+		$helpData = $this->objLotteryUserHelp->fetchAll ($condition, 1000000, 'id desc');
+
+		foreach ($helpData as $k => $v) {
+			$this->LotteryUserHelp->modify(array('nums' => $v['num']), array('id' => $v['id']));
+		}
+
+		echo 'yes';die;
+	}
 	public function doApply() {
 		
 		# 1.必要参数验证

+ 2 - 0
tm/lib/Dao/LotteryUserHelp.class.php

@@ -23,5 +23,7 @@ class LotteryUserHelp extends DBAgileDev {
 	protected $other_field = array (
 			'events_id',
 			'uid',
+			'nums',
+			//'num',
 	);
 }