mantis:cloudapp:issue:186
POST /ocs/v2.php/apps/polls/api/v1.0/poll
Add new poll
States: 201, 403, 404
Response:
{
"type": "datePoll",
"title": "Poll Title"
}
public function deserializeArray(array $pollConfiguration): self {
$this->setTitle($pollConfiguration['title'] ?? $this->getTitle());
$this->setDescription($pollConfiguration['description'] ?? $this->getDescription());
$this->setAccess($pollConfiguration['access'] ?? $this->getAccess());
$this->setAllowComment($pollConfiguration['allowComment'] ?? $this->getAllowComment());
$this->setAllowMaybe($pollConfiguration['allowMaybe'] ?? $this->getAllowMaybe());
$this->setAllowProposals($pollConfiguration['allowProposals'] ?? $this->getAllowProposals());
$this->setAnonymousSafe($pollConfiguration['anonymous'] ?? $this->getAnonymous());
$this->setAutoReminder($pollConfiguration['autoReminder'] ?? $this->getAutoReminder());
$this->setCollapseDescription($pollConfiguration['collapseDescription'] ?? $this->getCollapseDescription());
$this->setExpire($pollConfiguration['expire'] ?? $this->getExpire());
$this->setForceConfidentialComments($pollConfiguration['forceConfidentialComments'] ?? $this->getForceConfidentialComments());
$this->setHideBookedUp($pollConfiguration['hideBookedUp'] ?? $this->getHideBookedUp());
$this->setProposalsExpire($pollConfiguration['proposalsExpire'] ?? $this->getProposalsExpire());
$this->setShowResults($pollConfiguration['showResults'] ?? $this->getShowResults());
$this->setForcedDisplayMode($pollConfiguration['forcedDisplayMode'] ?? $this->getForcedDisplayMode());
$this->setUseNo($pollConfiguration['useNo'] ?? $this->getUseNo());
$this->setOptionLimit($pollConfiguration['maxVotesPerOption'] ?? $this->getOptionLimit());
$this->setVoteLimit($pollConfiguration['maxVotesPerUser'] ?? $this->getVoteLimit());
return $this;
}
mantis/cloudapp/issue/186.txt · Last modified: by domjos
