HTML上做表單頁面上的開啟和凍結切換以及功能實現

來源:互聯網
上載者:User
新手獻上的
  1. 證照資訊
  2. ?>
  3. 唯一標識
  4. 卡的類型
  5. 持卡人姓名
  6. 卡的餘額
  7. 銀行卡號
  8. 電話
  9. 卡的狀態
  10. 操作
  11. 啟動設定
  12. {$c.id}
  13. if($c['type']==1)
  14. {
  15. echo '企業卡';
  16. }
  17. ?>
  18. {$c.name}

  19. {$c.account}
  20. {$c.idcard}
  21. {$c.phone}
  22. if($c['status']==0)
  23. echo '凍結';
  24. if($c['status']==1)
  25. echo '啟用';
  26. ?>
  27. 修改 刪除
  28. 啟用/凍結
複製代碼
  1. /**
  2. * 聯名卡管理
  3. * @author shendoudou
  4. *
  5. */
  6. import ( '@.Model.Platform.CommonModel' );
  7. class IcbccardModel extends CommonModel {
  8. public function findAllCard(){
  9. $result = $this->select();
  10. if ($result === false)
  11. throw new DBException ( $this->getModelName (), $this->getDbError (), $this->getLastSql () );
  12. return $result;
  13. }
  14. public function findOneCard($id){
  15. $map['id']=$id;
  16. $result = $this->where ($map)->find();
  17. if ($result === false)
  18. throw new DBException ( $this->getModelName (), $this->getDbError (), $this->getLastSql () );
  19. return $result;
  20. }
  21. public function updateCard($id,$data){
  22. $map['id']=$id;
  23. $result = $this->where($map)->save($data);
  24. if ($result === false)
  25. throw new DBException ( $this->getModelName (), $this->getDbError (), $this->getLastSql () );
  26. return $result;
  27. }
  28. public function deleteCard($id){
  29. $map['id']=$id;
  30. $result = $this->where($map)->delete();
  31. if ($result === false)
  32. throw new DBException ( $this->getModelName (), $this->getDbError (), $this->getLastSql () );
  33. return $result;
  34. }
  35. public function findStatusId($status){
  36. $map['status']=$status;
  37. $result = $this->where($map)->field('id')->select();
  38. if ($result === false)
  39. throw new DBException ( $this->getModelName (), $this->getDbError (), $this->getLastSql () );
  40. return $result;
  41. }
  42. public function changeCardStatus($id,$status){
  43. $map['id']=$id;
  44. $map['status']=$status;
  45. $result = $this->save($map);
  46. if ($result === false)
  47. throw new DBException ( $this->getModelName (), $this->getDbError (), $this->getLastSql () );
  48. return $result;
  49. }
  50. }
  51. ?>
複製代碼
  • 聯繫我們

    該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

    如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.