CSLA 2.1 Templates - Hardcoded StoredProcedure names

CSLA 2.1 Templates - Hardcoded StoredProcedure names

Old forum URL: forums.lhotka.net/forums/t/1405.aspx


jorgembravo posted on Thursday, October 05, 2006

I’m new to CSLA and CodeSmith, but I want to suggest that the CSLA 2.1 templates provide some way to override the standard StoreProcedure names generated.

 

Maybe this could be done generating the standard names and storing them in variables in the ‘Generated Split Partial Class’ and provide a way to override them in the ‘User Split Partial Class’.

 

This way we could use existing databases.

 

Thanks

Jorge

 

mikeclimbs replied on Thursday, October 05, 2006

You can accomplish this by changing templatebase.

Search for FetchCommandFormat and just change this area to the desired names.

Mike

david.wendelken replied on Wednesday, October 11, 2006

I'm new to using CodeSmith.   I just made a change to TemplateBase.cs.

But the fixed text I changed didn't show up when I executed the template.

Is there something special I need to do to get it to recognize the change to TemplateBase?

I'm slogging thru the CodeSmith help text online but haven't unlocked the secret yet.

Crestline replied on Friday, October 13, 2006

You may already know this but I thought I would throw it out there just in case.  We thought we were having the same problem, couldn't see any of our changes but what it turned out to be was that when generating the files, it wouldn't overwrite them by default.  We were deleting the files manually before generating until we figured out where to turn the overwrite to true setting.  I don't have the templates on hand at the moment but it was either in the CSLA.cst or templatebase.cs file.


Copyright (c) Marimer LLC