Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3356584
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 18, 20262026-05-18T02:31:50+00:00 2026-05-18T02:31:50+00:00

I have a web app that lets users create groups. On the front page

  • 0

I have a web app that lets users create groups.
On the front page of the app any user can – without registering – create a group and add other users to the group by entering names into a list of text inputs. The user that created the group is then supposed to be able to invite the people on the list by adding an email to each of the names. The reason I want the user to provide just names initially and ivitations by email later is that I want the user to be able to try out the app and its functionality before registration.

So I have two models Group and User with a many-to-many relationship. The user model requires a unique email address so obviously I can’t create new user objects for each user in the group. So how would one make sure that the temporary users added to the groups will be mapped to the users that are created through the invitation or if the invited person already has a user in the app?

I was thinking about creating a Profile model that would have a name and belong to a group and a user but that way each user would have a profile for each of the groups he/she belongs to. I can’t think of another alternative but there must be one…

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-18T02:31:50+00:00Added an answer on May 18, 2026 at 2:31 am

    You need tools to dump dat info from your brain to a database model 🙂

    http://wb.mysql.com/ or http://www.sequelpro.com/

    Then you need to abstract that into your application.

    http://datamapper.org/

    After install all datamapper gems

    gem install dm-core dm-do-adapter dm-migrations dm-sqlite-adapter dm-timestamps do_sqlite3

    And finally you can start playing. In your Sinatra app.

    require 'rubygems'
    require 'dm-core' # http://datamapper.org/getting-started
    
    configure :development do
    
      DataMapper::setup(:default, "sqlite3://#{Dir.pwd}/hohohodb.db")
    
    end
    
    #...
    
    class User
    
      include DataMapper::Resource
    
      property :id,          Serial   # http://datamapper.org/docs/properties
      property :username,    String
      property :email,       String
      property :created_at,  DateTime
      property :updated_at,  DateTime
    
      validates_uniqueness_of, :email # http://datamapper.org/docs/validations
      has n, :groups
    
    end
    # Create or Upgrade all tables at once
    DataMapper.auto_upgrade!
    
    get '/'
        erb :index
    end
    
    __END__
    
    @@index
    ...
    

    Hope this can be a good starting point # http://datamapper.org/docs/

    have fun

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a web app that only registered users can use, therefore I should
I have an existing web app that allows users to rate items based on
I have been support a web app that is used by a user base
I have a web app that is heavily loaded in javascript and css. First
Problem: We have a web app that calls some web services asynchronously (from the
I have a huge web app that is having issues with memory leak in
I have this .NET web app that draws a table in Page_Load. Then after
This a bit of strange one.... We have an internal web app that runs
We are currently storing plain text passwords for a web app that we have.
I have a web app for commercial property management that needs spreadsheet-like functionality for

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.