Multiple user profiles in django 2.1









up vote
0
down vote

favorite
1












I'm currently designing a CRM-Software, which enables the user to save information about his jobs. The idea is that the user can have different Useraccounts for different Workfields he's working in. For example, if someone works as a freelance CS-engineer and as a Dj at the same time.



My problem is that i don't know how to model the Userprofile into my system. My first idea was to put an active_userprofile FK on my User model, which my User sets via the App. This attribute would be used to always fetch the related data for the needed user profile.
This sounded good at first, but the more i thought about it it felt like a hack.
Because what i think will happen, when i use the App simultaneously on PC & Mobile(Android/iOS) is, that the users won't be able to use seperate user profiles on both (or more) devices.



So my question is:



  • What is the best way to implement a System where the User can have multiple Userprofiles and user them on different devices simultaneously?









share|improve this question























  • You should probably set Profile model, and let the user choose which profile to use after login. You will then have a unique user in all your platform, and N profiles for each user.
    – Cheche
    Nov 14 at 17:29














up vote
0
down vote

favorite
1












I'm currently designing a CRM-Software, which enables the user to save information about his jobs. The idea is that the user can have different Useraccounts for different Workfields he's working in. For example, if someone works as a freelance CS-engineer and as a Dj at the same time.



My problem is that i don't know how to model the Userprofile into my system. My first idea was to put an active_userprofile FK on my User model, which my User sets via the App. This attribute would be used to always fetch the related data for the needed user profile.
This sounded good at first, but the more i thought about it it felt like a hack.
Because what i think will happen, when i use the App simultaneously on PC & Mobile(Android/iOS) is, that the users won't be able to use seperate user profiles on both (or more) devices.



So my question is:



  • What is the best way to implement a System where the User can have multiple Userprofiles and user them on different devices simultaneously?









share|improve this question























  • You should probably set Profile model, and let the user choose which profile to use after login. You will then have a unique user in all your platform, and N profiles for each user.
    – Cheche
    Nov 14 at 17:29












up vote
0
down vote

favorite
1









up vote
0
down vote

favorite
1






1





I'm currently designing a CRM-Software, which enables the user to save information about his jobs. The idea is that the user can have different Useraccounts for different Workfields he's working in. For example, if someone works as a freelance CS-engineer and as a Dj at the same time.



My problem is that i don't know how to model the Userprofile into my system. My first idea was to put an active_userprofile FK on my User model, which my User sets via the App. This attribute would be used to always fetch the related data for the needed user profile.
This sounded good at first, but the more i thought about it it felt like a hack.
Because what i think will happen, when i use the App simultaneously on PC & Mobile(Android/iOS) is, that the users won't be able to use seperate user profiles on both (or more) devices.



So my question is:



  • What is the best way to implement a System where the User can have multiple Userprofiles and user them on different devices simultaneously?









share|improve this question















I'm currently designing a CRM-Software, which enables the user to save information about his jobs. The idea is that the user can have different Useraccounts for different Workfields he's working in. For example, if someone works as a freelance CS-engineer and as a Dj at the same time.



My problem is that i don't know how to model the Userprofile into my system. My first idea was to put an active_userprofile FK on my User model, which my User sets via the App. This attribute would be used to always fetch the related data for the needed user profile.
This sounded good at first, but the more i thought about it it felt like a hack.
Because what i think will happen, when i use the App simultaneously on PC & Mobile(Android/iOS) is, that the users won't be able to use seperate user profiles on both (or more) devices.



So my question is:



  • What is the best way to implement a System where the User can have multiple Userprofiles and user them on different devices simultaneously?






django python-3.x django-2.1






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Nov 14 at 17:59









Cheche

751118




751118










asked Nov 10 at 19:32









Buja

12




12











  • You should probably set Profile model, and let the user choose which profile to use after login. You will then have a unique user in all your platform, and N profiles for each user.
    – Cheche
    Nov 14 at 17:29
















  • You should probably set Profile model, and let the user choose which profile to use after login. You will then have a unique user in all your platform, and N profiles for each user.
    – Cheche
    Nov 14 at 17:29















You should probably set Profile model, and let the user choose which profile to use after login. You will then have a unique user in all your platform, and N profiles for each user.
– Cheche
Nov 14 at 17:29




You should probably set Profile model, and let the user choose which profile to use after login. You will then have a unique user in all your platform, and N profiles for each user.
– Cheche
Nov 14 at 17:29

















active

oldest

votes











Your Answer






StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");

StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);













 

draft saved


draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53242679%2fmultiple-user-profiles-in-django-2-1%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown






























active

oldest

votes













active

oldest

votes









active

oldest

votes






active

oldest

votes















 

draft saved


draft discarded















































 


draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53242679%2fmultiple-user-profiles-in-django-2-1%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Top Tejano songwriter Luis Silva dead of heart attack at 64

政党

天津地下鉄3号線