本文整理汇总了C#中DotNetNuke.Entities.Portals.PortalController.ParsePanes方法的典型用法代码示例。如果您正苦于以下问题:C# PortalController.ParsePanes方法的具体用法?C# PortalController.ParsePanes怎么用?C# PortalController.ParsePanes使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类DotNetNuke.Entities.Portals.PortalController
的用法示例。
在下文中一共展示了PortalController.ParsePanes方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: SaveTabData
//.........这里部分代码省略.........
objTab.PageHeadText = txtPageHeadText.Text;
if( action == "edit" )
{
// trap circular tab reference
if( objTab.TabID != int.Parse( cboTab.SelectedItem.Value ) && ! IsCircularReference( int.Parse( cboTab.SelectedItem.Value ) ) )
{
objTabs.UpdateTab( objTab );
objEventLog.AddLog( objTab, PortalSettings, UserId, "", EventLogController.EventLogType.TAB_UPDATED );
}
}
else // add or copy
{
objTab.TabID = objTabs.AddTab( objTab );
objEventLog.AddLog( objTab, PortalSettings, UserId, "", EventLogController.EventLogType.TAB_CREATED );
if( int.Parse( cboCopyPage.SelectedItem.Value ) != - 1 )
{
ModuleController objModules = new ModuleController();
foreach( DataGridItem objDataGridItem in grdModules.Items )
{
CheckBox chkModule = (CheckBox)objDataGridItem.FindControl( "chkModule" );
if( chkModule.Checked )
{
int intModuleID = Convert.ToInt32( grdModules.DataKeys[ objDataGridItem.ItemIndex ] );
//RadioButton optNew = (RadioButton)objDataGridItem.FindControl( "optNew" );
RadioButton optCopy = (RadioButton)objDataGridItem.FindControl( "optCopy" );
RadioButton optReference = (RadioButton)objDataGridItem.FindControl( "optReference" );
TextBox txtCopyTitle = (TextBox)objDataGridItem.FindControl( "txtCopyTitle" );
ModuleInfo objModule = objModules.GetModule( intModuleID, Int32.Parse( cboCopyPage.SelectedItem.Value ), false );
if( objModule != null )
{
if( ! optReference.Checked )
{
objModule.ModuleID = Null.NullInteger;
}
objModule.TabID = objTab.TabID;
objModule.ModuleTitle = txtCopyTitle.Text;
objModule.ModuleID = objModules.AddModule( objModule );
if( optCopy.Checked )
{
if( !String.IsNullOrEmpty(objModule.BusinessControllerClass) )
{
object objObject = Reflection.CreateObject( objModule.BusinessControllerClass, objModule.BusinessControllerClass );
if( objObject is IPortable )
{
try
{
string Content = Convert.ToString( ( (IPortable)objObject ).ExportModule( intModuleID ) );
if( !String.IsNullOrEmpty(Content) )
{
( (IPortable)objObject ).ImportModule( objModule.ModuleID, Content, objModule.Version, UserInfo.UserID );
}
}
catch( Exception exc )
{
// the export/import operation failed
Exceptions.ProcessModuleLoadException( this, exc );
}
}
}
}
}
}
}
}
else
{
// create the page from a template
if( cboTemplate.SelectedItem != null )
{
if( !String.IsNullOrEmpty(cboTemplate.SelectedItem.Value) )
{
// open the XML file
try
{
XmlDocument xmlDoc = new XmlDocument();
xmlDoc.Load( cboTemplate.SelectedItem.Value );
PortalController objPortals = new PortalController();
objPortals.ParsePanes( xmlDoc.SelectSingleNode( "//portal/tabs/tab/panes" ), objTab.PortalID, objTab.TabID, PortalTemplateModuleAction.Ignore, new Hashtable() );
}
catch
{
// error opening page template
}
}
}
}
}
// url tracking
UrlController objUrls = new UrlController();
objUrls.UpdateUrl( PortalId, ctlURL.Url, ctlURL.UrlType, 0, Null.NullDate, Null.NullDate, ctlURL.Log, ctlURL.Track, Null.NullInteger, ctlURL.NewWindow );
return objTab.TabID;
}