public function cadastrarClientePlano($idCliente, $idPlano) { $obj = new ClientePlano(); $obj->idCliente = $idCliente; $obj->idPlano = $idPlano; $obj->dataCadastro = DATAHORAMYSQL; if (!$obj->inserir()) { return false; } return true; }
public function atualizaVencimento($id, $dataVencimento) { $obj = new ClientePlano(); $obj->id = $id; $obj->carregar(); $_POST['clientePlano']['dataVencimento'] = $dataVencimento; $obj->carga($_POST['clientePlano']); if ($obj->alterar()) { return true; } else { return false; } }