CodeSmith Community
Your Code. Your Way. Faster!

Foreign Key not showing up on Admin Page Add New

Latest post 02-19-2007 8:59 PM by chitrader. 7 replies.
  • 02-15-2007 9:31 AM

    • Zedekiah
    • Top 50 Contributor
    • Joined on 08-08-2006
    • Posts 74
    • Points 1,690

    Foreign Key not showing up on Admin Page Add New

    I had a table that has a foreign key.  It is displayed on the EntityGridView page but there is no way to enter it on the "ADD NEW" page.   The trouble is, the Database.DataBaseProvider.Insert(MyOjbect)

    fails because there is no @myforeignkey 

     

     I am sure there is a logical explanation.

    Quis neget actum esse praeclare?
    Filed under:
    • Post Points: 35
  • 02-15-2007 11:26 AM In reply to

    • mike123
    • Top 10 Contributor
    • Joined on 02-25-2005
    • Toronto, Ontario
    • Posts 726
    • Points 16,880

    Re: Foreign Key not showing up on Admin Page Add New

    Zedekiah,

    What's the myforeignkey datatype?

    Mike Shatny
    --------------------------------------------------------------
    Member of the .netTiers team http://www.nettiers.com
    --------------------------------------------------------------

    • Post Points: 35
  • 02-15-2007 12:11 PM In reply to

    • Zedekiah
    • Top 50 Contributor
    • Joined on 08-08-2006
    • Posts 74
    • Points 1,690

    Re: Foreign Key not showing up on Admin Page Add New

    integer
    Quis neget actum esse praeclare?
    • Post Points: 35
  • 02-15-2007 1:57 PM In reply to

    • mike123
    • Top 10 Contributor
    • Joined on 02-25-2005
    • Toronto, Ontario
    • Posts 726
    • Points 16,880

    Re: Foreign Key not showing up on Admin Page Add New

    Zedekiah,

    That is good. So what expected is to see the dropdown listbox on the add new page, right? Do you at least see a label for that missing listbox? If that the case, then you probably didn't include the ForeignTable into the generation process. Could you verify that?

    Mike Shatny
    --------------------------------------------------------------
    Member of the .netTiers team http://www.nettiers.com
    --------------------------------------------------------------

    • Post Points: 65
  • 02-16-2007 4:49 AM In reply to

    • Zedekiah
    • Top 50 Contributor
    • Joined on 08-08-2006
    • Posts 74
    • Points 1,690

    Re: Foreign Key not showing up on Admin Page Add New

    You are correct Sir. I gather if I do that my problems will be solved
    Quis neget actum esse praeclare?
    • Post Points: 5
  • 02-18-2007 3:48 PM In reply to

    Re: Foreign Key not showing up on Admin Page Add New

    I also have a question on the foreign key field on the generated website. Using northwind database as an example, in the "Products List" page, if you click "edit" for a record, you can't edit the "supplierID" and "CategoryID". Is this intended or I missed something? If it is intended, could I get back the admin control like in version 0.95? I like the old one.

     

    Another question for the foreign key field, right now it is using dropdown box, but if the foreign key has thousands of value, it is very slow to populate the dropdown box. Since AJAX is already included in the project, how about use textbox like google suggestion to replace foreign key dropdown box? How hard/easy is it?

    Thanks. 


     

    • Post Points: 35
  • 02-18-2007 4:52 PM In reply to

    • mike123
    • Top 10 Contributor
    • Joined on 02-25-2005
    • Toronto, Ontario
    • Posts 726
    • Points 16,880

    Re: Foreign Key not showing up on Admin Page Add New

    You're right, probably that is something we could add support for.

    Previous version of the admin controls are still distributed, you'd have to run them manually though

    Mike Shatny
    --------------------------------------------------------------
    Member of the .netTiers team http://www.nettiers.com
    --------------------------------------------------------------

    • Post Points: 35
  • 02-19-2007 8:59 PM In reply to

    Re: Foreign Key not showing up on Admin Page Add New

    Could you say more detail on how to "run them manually"?

    Thanks! 

    • Post Points: 5
Page 1 of 1 (8 items) | RSS
Copyright © 2008 CodeSmith Tools, LLC
Powered by Community Server (Commercial Edition), by Telligent Systems