Greetings,
There is a bug on line 45 of the EditableSwitchable template. The following line:
<% string cPars = GetFactoryNewCallArguments(objInfo); %>
Should be replaced with:
<% string cPars = GetFactoryDeclarationArguments(objInfo); %>
The original line will result in erroneous output in the case where an object has an int key (uniqueidentifier works fine), but is not an identity. The result of the FactoryNewCallArguments will result in a constructor being declared with parameters that have no declaring type:
private <objectName>(id)
{
this._id = id;
}
The desired result is achieved when using the second (or replacement) method:
private <objectName>(int id)
{
this._id = id;
}
Cheers.