作者 景琛

绑定学生问题

@@ -45,9 +45,9 @@ class Bind extends Api @@ -45,9 +45,9 @@ class Bind extends Api
45 } 45 }
46 $users = db('user')->where('id', $user['id'])->find(); 46 $users = db('user')->where('id', $user['id'])->find();
47 //halt($users); 47 //halt($users);
48 - if ($users['bind_study'] == 1) {  
49 - $this->error('您当前已经绑定过学生了,请勿重复操作');  
50 - } 48 +// if ($users['bind_study'] == 1) {
  49 +// $this->error('您当前已经绑定过学生了,请勿重复操作');
  50 +// }
51 Db::startTrans(); 51 Db::startTrans();
52 try { 52 try {
53 db('study') 53 db('study')
@@ -97,9 +97,9 @@ class Bind extends Api @@ -97,9 +97,9 @@ class Bind extends Api
97 $this->error('当前学生已经被绑定了'); 97 $this->error('当前学生已经被绑定了');
98 } 98 }
99 $users = db('user')->where('id', $user['id'])->find(); 99 $users = db('user')->where('id', $user['id'])->find();
100 - if ($users['bind_study'] == 1) {  
101 - $this->error('您当前已经绑定过学生了,请勿重复操作');  
102 - } 100 +// if ($users['bind_study'] == 1) {
  101 +// $this->error('您当前已经绑定过学生了,请勿重复操作');
  102 +// }
103 Db::startTrans(); 103 Db::startTrans();
104 try { 104 try {
105 db('study') 105 db('study')