is quite simple. pollName is quite self-explanatory. options will have the possible vote options for that poll. In votes it'll have the userID and in votes which vote that user took.
it will be necessary create a new collection. the name for that collection is very open, but polls or codding_buddies_polls are the most obvious to me.
the calling of the function is a bit more complex because it has the requirement to pass 2 info:
poll name. ex: "cats or dogs"
options:
1 - cats;
2 - dogs;
there are many ways of doing such a thing. right now i'm thinking in something like !poll "poll name" [options], where the poll name should be sent in quotes and the options in an array separated by a , (comma). so the example above would become !poll "cats or dogs" [cats, dogs], but i'm open to suggestions
this issue is to discuss a possible new command
!poll
, the structure in the db and how it should be called.the structure on the db should be this one:
is quite simple.
pollName
is quite self-explanatory. options will have the possible vote options for that poll. In votes it'll have the userID and in votes which vote that user took. it will be necessary create a new collection. the name for that collection is very open, butpolls
orcodding_buddies_polls
are the most obvious to me.the calling of the function is a bit more complex because it has the requirement to pass 2 info:
!poll "poll name" [options]
, where the poll name should be sent in quotes and the options in an array separated by a,
(comma). so the example above would become!poll "cats or dogs" [cats, dogs]
, but i'm open to suggestions