precisely / curious2

0 stars 0 forks source link

Promo code feature #867

Open syntheticzero opened 8 years ago

syntheticzero commented 8 years ago

Here's what we want the Promo Code feature to have. Rich will implement on web first, then @visheshd can do for mobile.

1) New "Promo Code" field added to registration screen

2) New admin-editable database tables that allow specifying the following:

For now let's not bother writing an involved editor for this stuff, we'll just manually edit the DB. Maybe make these things strings which are parsed, to make it easier to edit the DB. I.e. the list of interest tags could be "headache severity, caffeine, sleep quality -". Later, we will add an admin editor.

RichBCurious commented 8 years ago

Do we need to take into consideration localization? Have we globalized the app and localized it to American market for now? Or is it just American? Trying to figure out from code, but thought it might be quicker to ask.

On Thu, Feb 25, 2016 at 5:20 PM, syntheticzero notifications@github.com wrote:

Assigned #867 https://github.com/syntheticzero/curious2/issues/867 to @RichBCurious https://github.com/RichBCurious.

— Reply to this email directly or view it on GitHub https://github.com/syntheticzero/curious2/issues/867#event-566459517.

RichBCurious commented 8 years ago

Regarding the tutorial text, right now that's a little vague to me. Currently, we have a 6 step tutorial with a 7th finish page. Are we talking about customizing bits and pieces of those pages? Or are we talking about replacing the entire text for each page?

Example. Page 1 of the tutorial:

Welcome to We Are Curious! We Are Curious helps you investigate questions about yourself. For example, Does caffeine affect my sleep? Does exercise really affect my mood? Presumably, the first two sentences would be the same for everyone but we would customize "Does caffeine affect my sleep?" and "Does exercise really affect my mood?" based on promo code. Is that the idea? Or would you replace the entire page? If entire page, what would be the best way to handle formatting? Obviously, we don't want to embed html in the data, but how else would line breaks be communicated? Maybe each file would also need an html template? What about page 2: Track bits of your life for a few days or weeks using tags based on your questions. For instance, you could track your mood, how much sleep you get, the coffee you drink, and the steps you take. You can track automatically using devices such as the Oura ring (via your user profile). I could see leaving the first sentence and then customizing everything from "For instance, you could..." on. Or could just customize the entire page. What do you think? Finally, page 4, shows another variation: Let's get started with three painless questions. These will help illustrate the Curious tracking feature. How many hours did you sleep last night? e.g. 8 hours 10 minutes or 8hrs 10 mins Again, first sentence could stay the same for everyone (Of course, I could see having different number of questions based on promo code) but then I would think we would want to customize "How many hours did you sleep last night?" and then also, obviously, the default example "e.g. 8 hours..." in the text box. What do you think? The other stuff seems straight forward, but what we want to do here needs some clarification. Rich On Thu, Feb 25, 2016 at 7:43 PM, Rich Devine rich.b.devine@gmail.com wrote: > Do we need to take into consideration localization? Have we globalized the > app and localized it to American market for now? Or is it just American? > Trying to figure out from code, but thought it might be quicker to ask. > > On Thu, Feb 25, 2016 at 5:20 PM, syntheticzero notifications@github.com > wrote: > > > Assigned #867 https://github.com/syntheticzero/curious2/issues/867 to > > @RichBCurious https://github.com/RichBCurious. > > > > — > > Reply to this email directly or view it on GitHub > > https://github.com/syntheticzero/curious2/issues/867#event-566459517.
syntheticzero commented 8 years ago

We are American-only for now. Some parts of the code are internationalized, but we're putting off full internationalization for a while.

The idea is to customize just things like those questions. I think we could do it with some sort of template format, i.e,

$questions1A=Does caffeine affect my sleep?\nDoes exercise really affect my mood?

Or something of that kind.

RichBCurious commented 8 years ago

Ouch. Okay, that's too bad. I know from experience that internationalizing an application after the fact is practically impossible. At least doing it well. But alas, deadlines and limited resources, so what can you do?

Yeah, template is what I was thinking. Certainly this won't be perfect and may take a few iterations to get right.

On Fri, Feb 26, 2016 at 2:26 AM, syntheticzero notifications@github.com wrote:

We are American-only for now. Some parts of the code are internationalized, but we're putting off full internationalization for a while.

The idea is to customize just things like those questions. I think we could do it with some sort of template format, i.e,

$questions1A=Does caffeine affect my sleep?\nDoes exercise really affect my mood?

Or something of that kind.

— Reply to this email directly or view it on GitHub https://github.com/syntheticzero/curious2/issues/867#issuecomment-189145949 .

syntheticzero commented 8 years ago

We've already internationalized most of the error messages. There aren't really that many places where we're using language --- just a few tutorials, some buttons, and a few UI templates. It will be work to internationalize, but certainly not impossible. I'd guess we would have to replace maybe 100 places in the code and templates. But, we don't have close the resources we would need to translate anything, and the app is very culture-specific, so English it is for now.

syntheticzero commented 8 years ago

Note that Grails already has a template language and there are some Javascript template libraries we're also using. You might wish to leverage those somehow. Maybe the strings get pulled into a Mustache template or an underscore.js template.

RichBCurious commented 8 years ago

Yeah, makes sense. I hear what you're saying. It is pretty American focused at the moment. That's the target. And I can see that sort of thing being a low priority. But yeah, will definitely be some pain if you really want to do it right. It potentially involves all kinds of UI considerations, beyond simple text.

On Fri, Feb 26, 2016 at 3:19 PM, syntheticzero notifications@github.com wrote:

We've already internationalized most of the error messages. There aren't really that many places where we're using language --- just a few tutorials, some buttons, and a few UI templates. It will be work to internationalize, but certainly not impossible. I'd guess we would have to replace maybe 100 places in the code and templates. But, we don't have close the resources we would need to translate anything, and the app is very culture-specific, so English it is for now.

— Reply to this email directly or view it on GitHub https://github.com/syntheticzero/curious2/issues/867#issuecomment-189465684 .

RichBCurious commented 8 years ago

Yeah, I knew about grails templates, but it didn't look like we were using that feature. I didn't dig too deep though. Just did a couple of searches.

On Fri, Feb 26, 2016 at 3:20 PM, syntheticzero notifications@github.com wrote:

Note that Grails already has a template language and there are some Javascript template libraries we're also using. You might wish to leverage those somehow. Maybe the strings get pulled into a Mustache template or an underscore.js template.

— Reply to this email directly or view it on GitHub https://github.com/syntheticzero/curious2/issues/867#issuecomment-189466320 .

syntheticzero commented 8 years ago

We are using GSP which is a template language. However, we are also using mustache and underscore.js

syntheticzero commented 8 years ago

The next big target might be Chinese --- that is going to be a lot of work beyond messages, I agree. On the other hand, Chinese is at least left-to-right these days, so that's less of a problem.

RichBCurious commented 8 years ago

know about gsp, but mustache and underscore are new to me. Will take a look.

On Fri, Feb 26, 2016 at 3:24 PM, syntheticzero notifications@github.com wrote:

We are using GSP which is a template language. However, we are also using mustache and underscore.js

— Reply to this email directly or view it on GitHub https://github.com/syntheticzero/curious2/issues/867#issuecomment-189468530 .

RichBCurious commented 8 years ago

Yeah, that's good. But yeah, Chinese that is definitely one of the tougher ones. I actually worked on a search engine for the Chinese market and learned a lot about UTF and Chinese. Most of which I've forgotten, of course. Ha.

On Fri, Feb 26, 2016 at 3:25 PM, syntheticzero notifications@github.com wrote:

The next big target might be Chinese --- that is going to be a lot of work beyond messages, I agree. On the other hand, Chinese is at least left-to-right these days, so that's less of a problem.

— Reply to this email directly or view it on GitHub https://github.com/syntheticzero/curious2/issues/867#issuecomment-189468929 .

RichBCurious commented 8 years ago

Direction of text is one thing, but then there are weird little things like where certain cultures expect certain buttons to be. We may have a button at the bottom, for example, while they have the same one at the top.

On Fri, Feb 26, 2016 at 3:26 PM, Rich Devine rich.b.devine@gmail.com wrote:

Yeah, that's good. But yeah, Chinese that is definitely one of the tougher ones. I actually worked on a search engine for the Chinese market and learned a lot about UTF and Chinese. Most of which I've forgotten, of course. Ha.

On Fri, Feb 26, 2016 at 3:25 PM, syntheticzero notifications@github.com wrote:

The next big target might be Chinese --- that is going to be a lot of work beyond messages, I agree. On the other hand, Chinese is at least left-to-right these days, so that's less of a problem.

— Reply to this email directly or view it on GitHub https://github.com/syntheticzero/curious2/issues/867#issuecomment-189468929 .