case "creat": $cardName = $_POST["name"]; $remark = $_POST["dec"]; $cardStr = $_POST["str"]; echo json_encode(CardApplyProvider::getInstance()->CreatCardApplyInfo($cardName, $remark, $cardStr, '')); break; case "applyList": $pageSize = intval($_POST['pagesize']) ? intval($_POST['pagesize']) : 20; $curPage = intval($_POST['curpage']) ? intval($_POST['curpage']) : 1; $offer = ($curPage - 1) * $pageSize; $state = $_POST['s']; echo json_encode(CardApplyProvider::getInstance()->GetCardFormListByState($state, $offer, $pageSize)); break; //已申请卡的信息 //已申请卡的信息 case "cardInfo": //CardForm CardTypeInfo $cardFormID = $_POST['ID']; echo json_encode(CardApplyProvider::getInstance()->GetCardTypeInfoByCardFormID($cardFormID)); break; case "Tlist": $cardFormID = $_POST['ID']; echo json_encode(CardApplyProvider::getInstance()->getCardListByFormID($cardFormID)); break; //提取卡,更新订单状态 //提取卡,更新订单状态 case "updateapply": $cardFormID = $_POST['ID']; echo json_encode(CardApplyProvider::getInstance()->UpdateCardFormState($cardFormID)); break; }
<?php include_once "../../common.php"; require_once DATACONTROL . '/BMAccount/IsLogin.php'; require_once DATACONTROL . '/BMAccount/CardApplyProvider.php'; require_once DATAMODEL . '/BMAccount/CardApplyFormMDL.php'; if (!isset($_POST["method"])) { exit; } $methods = $_POST["method"]; switch ($methods) { case "List": $pageSize = intval($_POST['pagesize']) ? intval($_POST['pagesize']) : 20; $curPage = intval($_POST['curpage']) ? intval($_POST['curpage']) : 1; $offer = ($curPage - 1) * $pageSize; echo json_encode(CardApplyProvider::getInstance()->GetCardFormListByState(0, $offer, $pageSize)); break; case "Undone": $cardFormID = $_POST['ID']; $remark = $_POST['dec']; echo json_encode(CardApplyProvider::getInstance()->UnPassCardForm($cardFormID, $remark)); break; case "done": $cardFormID = $_POST['ID']; $remark = $_POST['dec']; echo json_encode(CardApplyProvider::getInstance()->DoPassCardInfo($cardFormID, $remark)); break; }