apart from that you can use google forms and use google api script to call
your app webservice and send the json to your table.
This way you can let users create rapidly forms to question users.Then in
web2py you can just show the json as a table.


Em qua, 16 de out de 2019 às 08:54, NGNZONE <ngnz...@gmail.com> escreveu:

> Thanks Val K, I appreciate the elaborate explanation.
> I will try the suggestions ASAP
> Regards
>
> On Saturday, October 12, 2019 at 10:11:12 PM UTC+1, Val K wrote:
>>
>> If you want to create/edit survey using one page you have to use
>> JavaScript (I don't see another non-horrible way).
>> If you want only web2py/python implementation you have to organize your
>> application to edit one entity per page/request,  i.e. you can do something
>> as follows:
>> /surveys - returns grid of surveys with references to
>>    /surveys/<survey> (per row) that returns  grid of  sections +
>> references to
>>         /surveys/<survey>/<section> that returns grid of questions +
>> references to
>>               /surveys/<survey>/<section>/<question> that returns grid
>> (or form with `select multiple` ) of answers with scores
>>
>>
>>
>>
>>
>> On Saturday, October 12, 2019 at 7:54:05 PM UTC+3, NGNZONE wrote:
>>>
>>> Situation Description
>>>
>>> First things first, I am not a very experience web2py developer but I
>>> have learned the basics of the framework, so please pardon me if my
>>> questions are not so constructive. I started working on a survey
>>> application which will enable users to create multiple choice questions. A
>>> question will have a number of choices, and when the user selects a
>>> particular choice, a corresponding score will be added to a sub total. That
>>> is if the survey is about Fruits for instance, if a user selects oranges, 5
>>> will be added to the sub total for that section, if another user selects
>>> Mangoes, 10 will be added to the sub total and so on. The attached
>>> screenshot survey_layout will better explain what I am talking about. It
>>> has three columns, the first column is the question, the second, the
>>> corresponding choices and the third column the score linked to each choice.
>>> [Survey layout][1] There are six sections in the survey, and each section
>>> has a sub_total which is generated from the score value of each choice the
>>> user chooses on each of the questions. Finally the sub_totals will be added
>>> up to give a grand total for the entire survey and it can then be
>>> interpreted. What I have done so far is as seen on the follow screenshots
>>>
>>>
>>>
>>> Questions:
>>>
>>> 1.How do I create my models in such a way that the user can dynamically
>>> create questions for the survey for each section on the page and when the
>>> user takes the survey, each choice the user selects, will correspond to a
>>> score value which can be tracked and summed up to give the section totals?
>>>
>>> 2.How will my form be defined to output all the questions for each
>>> section one after the other on the screen? I have tried using SQLFORMS but
>>> don't know exactly how to achieve this.
>>>
>>>    1. Thinking of using pagination to separate the sections so the page
>>>    will not be too long. any better option?
>>>
>>> References: I have watched the web2py survey by MASSIMO DI PIERRO where
>>> I learn how to do what I have done so far.
>>>
>>> Thanks in advance
>>>
>>> --
> Resources:
> - http://web2py.com
> - http://web2py.com/book (Documentation)
> - http://github.com/web2py/web2py (Source code)
> - https://code.google.com/p/web2py/issues/list (Report Issues)
> ---
> You received this message because you are subscribed to the Google Groups
> "web2py-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to web2py+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/web2py/576ef875-3e96-4477-bb24-fd03170b6ec2%40googlegroups.com
> <https://groups.google.com/d/msgid/web2py/576ef875-3e96-4477-bb24-fd03170b6ec2%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/CAEM0BxM%3D-8Nhm7r-DFXLLUJeR653%3Df2OmH20EpY_H7%3DPoTLR%2BQ%40mail.gmail.com.

Reply via email to