Re: Advice on choosing Django modules?

2018-11-25 Thread Mike Dewhirst

Dean

You have an interesting scenario.

For me, the first task would be figuring out the best use of my time. 
I'm perfectly capable of semi-permanent research and indecision followed 
by throwing up my hands in frustration and rolling my own.


I think if I was in your shoes with your apparent experience I would 
search out the most simple membership system I could find and try to 
make that work.


That process would teach me in a very short time exactly what I have to 
look for further afield or persuade me to think in a different direction.


I suggest "simple" because if I chose to fork a simple system it would 
be easier than trying to take a more complex package in my chosen direction.


Simple is better than complex.

The relationships you list below are all people who each can have none, 
one or more links to any other person and each can be a member of none, 
one or more groups. That part does sound complex but it isn't really 
when you have a tool like Django.


The e-Commerce part of your project does require bullet-proof software 
and payment gateways so I would focus on that first. Again I would look 
for the simplest. It is easier to secure something simple.


By the time I had found the packages with the fewest models, fewest 
lines of code and somewhat understandable after poking around under the 
covers I would be somewhat better educated and therefore better placed 
to make strategic decisions.


Good luck

Mike

On 24/11/2018 8:46 AM, Dean Karres wrote:

Hi,

I have been teaching myself python at the same time I am starting with 
Django.  I have made a great deal of progress with both but am at a 
place where I could really use some advice.  I am trying to build a 
specialized "Membership" application for a US based non-profit.  The 
non-profit works with adults, children and families -- sometimes 
rather complex family structures.  A Membership Application for this 
entity needs to handle some peculiar situations.


I have looked at some of the Django e-commerce plugins but there are a 
lot of them and some seem to take a lot of configuration.  I get lost 
reading the setup/config docs while trying to see how a particular 
module can be configured for my needs.  This is where I need advice.


Because this org does not have money for hardware they will use 
Squareup for on-site dues, fees and product sales. Squareup and/or 
Stripe for on-line purchases.


The on-line part of the application needs to:

@ allow "Adults", 18 years old or older, to sign-up/register (take profile
data).  Let's call this Adult with a login account an "Account Holder".
@ allow Account Holders to:
* purchase a personal "Adult" membership (one-time or recurring /
subscription) or signal that they will pay in person via with cash or
check.
* purchase one or more memberships for other related Adults or Youth
(under 18 years old).  The "other" membership purchases must take
"non-login" profile data.
* when creating additional memberships be aware of special billing
rates; for example: multiple memberships "belonging" to the Account
Holder are considered to be a "Family Membership".  No Family pays
more than a fixed amount per month.  Also, if multiple Youth
memberships are created then there is special pricing: the first Youth
is at the regular Youth rate and each additional Youth is at a reduced
rate -- keeping in mind that maximum Family Membership rate.
* cancel Membership(s).
* modify Membership Profile data and payment methods for all Members
belonging to the Account Holder.
@ more than one Account Holder may have financial responsibility for a
"Family Membership".  This can get complex.  The non-profit does not
currently have any complex Family payment situations but in the past there
have been situations where a non-"member" parent/guardian will pay for
one or more members one month and one or more other parent/guardians
will pay for some sub-set of members.  Sometimes these non-members are
also non-Account-Holders.  All of the payments need to be tracked and
applied to the correct member(s).
@ the "Profile Data" associated with each member needs to include the
obvious: name, birth-date, address, phone number(s) for contact,
SMS-allowed number(s), emergency contact number(s), email address(es).
Emergency contact information, especially for Youth, might need multiple
contacts and an order of contact.
@ the non-profit is educational in nature.  The member information 
needs to
carry information about test dates, pass/fail status, current level, 
class

attendance dates. This information should be viewable by the Account
Holder but can oly be added/modified by an Teachers.
@ Teachers is a group that is made of select Account Holders who are
Members.  Membership in the Teachers group is managed by Administrators.
@ Administrators is a group that is made of select Teachers.
@ report generation features should be available to Administrators and 
offer

things like:
* list of login accounts with no members with o

How to autosave Foreignkey value inside my second Model with the id of my first model object.??

2018-11-25 Thread Anoop Sharma


I have two models . Appname and Adspace ,I have a Foreignkey object 
in second model which connects to my first model. Here is the Code


models.py

 class Appname(models.Model):
  
name=models.CharField(max_length=150,blank=False,null=False,help_text='Add your 
new App')

  def __str__(self):
  return self.name

  def get_absolute_url(self):
  return reverse("dashapp:space",kwargs={'pk':self.pk})


class Adspace(models.Model):
  ad_space=models.CharField(max_length=150,blank=False,null=False) 
  app=models.ForeignKey('Appname', related_name='appnames',default=None, 
on_delete=models.CASCADE)
  PID_TYPE = (
('FN','FORMAT_NATIVE'),
('FNB','FORMAT_NATIVE_BANNER'),
('FI','FORMAT_INTERSTITIAL'),
('FB','FORMAT_BANNER'),
('FMR','FORMAT_MEDIUM,RECT'),
('FRV','FORMAT_REWARDED_VIDEO'),
)
 
format_type=models.CharField(max_length=3,choices=PID_TYPE,default='FN',blank=False,
 null=False)

 def __str__(self):
  return self.ad_space

 def get_absolute_url(self):
  return reverse("dashapp:view")



modelForm

class AdspaceForm(forms.ModelForm):
class Meta:
   model=Adspace
   fields=('ad_space',)



Views.py

class space(LoginRequiredMixin,CreateView):

   form_class=forms.AdspaceForm
   model=Adspace



Now I.m unable to fill my form as it says it app_id cannot be null 
and i'm allowing user to input it. I want that the app which got clicked
 has its ID in the url (As I'm passing it through there).
What should i do that it gets autosave with the same id number by itself
 that is being passed in the url. 




-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/4a23635c-1d6c-4dba-b011-778c1548f938%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: How to autosave Foreignkey value inside my second Model with the id of my first model object.??

2018-11-25 Thread Yavin Aalto Arba
The whole point of a foreign key is that it's external\independent the
related model - and you are going against that by giving the user the
ability to enter it willy-nilly in one form. If you want to have a 2 key
combo as primary key you can use unique_together without the second model
as a FK   (
https://docs.djangoproject.com/en/2.1/ref/models/options/#unique-together)

If you really insist on this design...You could make two forms (one for the
appname and one for the other model without the appname) and set the saving
of the second form with a save(commit=False). then, set the FK according to
the first saved form input. It's pretty ugly imho but it can be done, cf.
https://stackoverflow.com/questions/569468/django-multiple-models-in-one-template-using-forms/575133#575133

On Sun, 25 Nov 2018 at 15:49, Anoop Sharma  wrote:

>
> I have two models . Appname and Adspace ,I have a Foreignkey object
> in second model which connects to my first model. Here is the Code
>
>
> models.py
>
>  class Appname(models.Model):
>   
> name=models.CharField(max_length=150,blank=False,null=False,help_text='Add 
> your new App')
>
>   def __str__(self):
>   return self.name
>
>   def get_absolute_url(self):
>   return reverse("dashapp:space",kwargs={'pk':self.pk})
>
>
> class Adspace(models.Model):
>   ad_space=models.CharField(max_length=150,blank=False,null=False)
>   app=models.ForeignKey('Appname', related_name='appnames',default=None, 
> on_delete=models.CASCADE)
>   PID_TYPE = (
> ('FN','FORMAT_NATIVE'),
> ('FNB','FORMAT_NATIVE_BANNER'),
> ('FI','FORMAT_INTERSTITIAL'),
> ('FB','FORMAT_BANNER'),
> ('FMR','FORMAT_MEDIUM,RECT'),
> ('FRV','FORMAT_REWARDED_VIDEO'),
> )
>  
> format_type=models.CharField(max_length=3,choices=PID_TYPE,default='FN',blank=False,
>  null=False)
>
>  def __str__(self):
>   return self.ad_space
>
>  def get_absolute_url(self):
>   return reverse("dashapp:view")
>
>
>
> modelForm
>
> class AdspaceForm(forms.ModelForm):
> class Meta:
>model=Adspace
>fields=('ad_space',)
>
>
>
> Views.py
>
> class space(LoginRequiredMixin,CreateView):
>
>form_class=forms.AdspaceForm
>model=Adspace
>
>
>
> Now I.m unable to fill my form as it says it app_id cannot be null
> and i'm allowing user to input it. I want that the app which got clicked
>  has its ID in the url (As I'm passing it through there).
> What should i do that it gets autosave with the same id number by itself
>  that is being passed in the url.
>
>
>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/4a23635c-1d6c-4dba-b011-778c1548f938%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/CA%2B%2Be-ZU%3DkLUBGPrZQQ9hoXDemM1RJtB8aorj%2B_GhXhDNwEiaLw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: Looking for a Django Co-Founder.

2018-11-25 Thread Shashank Singh
I am also interested. Is there is anything I can do now?

On Mon, 19 Nov, 2018, 7:04 PM Idowu Tunde  Helo you can do public found raising
> In term of ICO which help to get more fund from the puplic
>
> On Sunday, November 18, 2018, Zack Amaral  wrote:
>
>> What time are you available today?
>>
>> On Sun, Nov 18, 2018 at 12:03 PM Erol DEMİRHAN 
>> wrote:
>>
>>> Hi Zack,
>>>
>>> I'm interested in setting up a video conference whenever you and other
>>> people are available. We'd better set an hour for the meeting.
>>> By the way can we use Slack app for the communication? If everybody okay
>>> with that?
>>>
>>> Sincerely
>>>
>>> Erol DEMİRHAN
>>>
>>> On Sun, 18 Nov 2018 at 06:17, Zack Amaral 
>>> wrote:
>>>
 Let me know if you guys are interested in setting up a video
 conference. I'd love to tell you more about it. I can show you the UI/UX
 I've been working on.

 Thank you for your consideration,

 Zack Amaral

 On Sat, Nov 17, 2018 at 8:10 PM Zack Amaral 
 wrote:

> Erol,
>
> Here's a link to the plan:
> https://app.liveplan.com/accept-invitation?ic=107ef0ab-8bc5-4b9d-aeea-bf72324a0261
>
> Cheers,
>
> Zack Amaral
>
> On Sat, Nov 17, 2018 at 8:04 PM Erol DEMİRHAN 
> wrote:
>
>> Hi Zack,
>>
>> My name is Erol DEMIRHAN,
>>
>> I received your email. It sounds interesting. I'm waiting for
>> your reply about the details of the project.
>>
>> Sincerely
>>
>> On Sun, 18 Nov 2018 at 05:32, Lucas G. Navarro <
>> lucasgnava...@gmail.com> wrote:
>>
>>> Hi! How are you? Can you tell us more about this?
>>>
>>> Regards!
>>>
>>> El sáb., 17 nov. 2018 7:29 PM, Zack Amaral 
>>> escribió:
>>>
 Hi,

 I have an idea for a next generation PaaS. I was wondering if there
 are any Django developers that would be interested in being a 
 co-founder
 with my company. I'm an AWS Architect but sadly a really bad 
 developer. If
 there's anybody on this forum that would be interested please let me 
 know
 and we can setup a time to talk about the details of the project.

 Thanks,

 Zack

 --
 You received this message because you are subscribed to the Google
 Groups "Django users" group.
 To unsubscribe from this group and stop receiving emails from it,
 send an email to django-users+unsubscr...@googlegroups.com.
 To post to this group, send email to django-users@googlegroups.com.
 Visit this group at https://groups.google.com/group/django-users.
 To view this discussion on the web visit
 https://groups.google.com/d/msgid/django-users/987d359b-263b-4ecf-957c-f2537f2d4ad1%40googlegroups.com
 
 .
 For more options, visit https://groups.google.com/d/optout.

>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "Django users" group.
>>> To unsubscribe from this group and stop receiving emails from it,
>>> send an email to django-users+unsubscr...@googlegroups.com.
>>> To post to this group, send email to django-users@googlegroups.com.
>>> Visit this group at https://groups.google.com/group/django-users.
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/django-users/CABomRVVygn%3DNqk1b%2BLkvA5Ktn7PmGYz3W226QQucwWhfx0OwEQ%40mail.gmail.com
>>> 
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>> --
>> You received this message because you are subscribed to the Google
>> Groups "Django users" group.
>> To unsubscribe from this group and stop receiving emails from it,
>> send an email to django-users+unsubscr...@googlegroups.com.
>> To post to this group, send email to django-users@googlegroups.com.
>> Visit this group at https://groups.google.com/group/django-users.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/django-users/CAJBVZ3xqfv_3sgkg8foJb-g5kbpmrTZXJ6hqNHVbbAvYZLJrvA%40mail.gmail.com
>> 
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
> --
 You received this message because you are subscribed to the Google
 Groups "Django users" group.
 To unsubscribe from this group and stop receiving emails from it, send
 an email to django-users+unsubs

Re: Looking for a Django Co-Founder.

2018-11-25 Thread TimT Vogt
Hi Zack do I need an account for liveplan?

Tim

Verstuurd vanaf mijn iPhone

> Op 18 nov. 2018 om 00:53 heeft Lucas G. Navarro  het 
> volgende geschreven:
> 
> Hi! How are you? Can you tell us more about this?
> 
> Regards!
> 
> El sáb., 17 nov. 2018 7:29 PM, Zack Amaral  escribió:
>> Hi,
>> 
>> I have an idea for a next generation PaaS. I was wondering if there are any 
>> Django developers that would be interested in being a co-founder with my 
>> company. I'm an AWS Architect but sadly a really bad developer. If there's 
>> anybody on this forum that would be interested please let me know and we can 
>> setup a time to talk about the details of the project.
>> 
>> Thanks,
>> 
>> Zack
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Django users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to django-users+unsubscr...@googlegroups.com.
>> To post to this group, send email to django-users@googlegroups.com.
>> Visit this group at https://groups.google.com/group/django-users.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/django-users/987d359b-263b-4ecf-957c-f2537f2d4ad1%40googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/django-users/CABomRVVygn%3DNqk1b%2BLkvA5Ktn7PmGYz3W226QQucwWhfx0OwEQ%40mail.gmail.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/E31B5A56-2D28-4A14-BD85-D6E4D206E8A8%40gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: Looking for a Django Co-Founder.

2018-11-25 Thread Gear Crew
I am here i am interested i am 20 years old and not Pro in django but i'm 
still learning until die if you have any ideas I will be with you  

On Sunday, 18 November 2018 00:29:14 UTC+2, Zack Amaral wrote:
>
> Hi,
>
> I have an idea for a next generation PaaS. I was wondering if there are 
> any Django developers that would be interested in being a co-founder with 
> my company. I'm an AWS Architect but sadly a really bad developer. If 
> there's anybody on this forum that would be interested please let me know 
> and we can setup a time to talk about the details of the project.
>
> Thanks,
>
> Zack
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/a110b508-5f68-4085-bdeb-e76531f6673b%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


making sign up and login

2018-11-25 Thread Gear Crew
I want to know sign up and login or generally registration in Django if I 
build up in Django I have to associate that with admin page or that 
possible and when creating a new user from registration this data where 
will go in admin and create user automatic in admin or what ?

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/04e90199-e0ef-4e66-b992-ecd40a0dcae4%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Custom attributes in django forms

2018-11-25 Thread gordon nchy
hello everyone
i'm facing a challenge on how to add custom attributes to django login 
form. i used the LoginView from django.contrib.auth.views to generate a 
login form, but i really need help on how to add custom attributes maybe 
like using widgets but i dont know how to do it..i'll appreciate any help 
from you guys!!

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/1b463fa5-ab80-4182-8022-5fe33b695444%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.