Ejemplo n.º 1
0
        /// <summary>
        /// Update logic
        /// </summary>
        public override void update()
        {
            CswNbtMetaDataNodeType TimeNT = _CswNbtSchemaModTrnsctn.MetaData.getNodeType( "Unit (Time)" );
            if( null != TimeNT )
            {
                foreach( CswNbtObjClassUnitOfMeasure TimeNode in TimeNT.getNodes( false, false ) )
                {
                    if( "Months" == TimeNode.Name.Text )
                    {
                        //According to Google, 1 month = 30.4368 days (based on averages, I'm assuming)
                        TimeNode.ConversionFactor.Base = 3.285496;
                        TimeNode.ConversionFactor.Exponent = -2;
                        TimeNode.postChanges( false );
                    }
                }
            }

            CswNbtMetaDataObjectClass MaterialOc = _CswNbtSchemaModTrnsctn.MetaData.getObjectClass( NbtObjectClass.MaterialClass );
            foreach( CswNbtMetaDataNodeType MaterialNt in MaterialOc.getNodeTypes() )
            {
                CswNbtMetaDataNodeTypeProp SpecificGravityNtp = MaterialNt.getNodeTypePropByObjectClassProp( CswNbtObjClassMaterial.PropertyName.SpecificGravity );
                if( null != SpecificGravityNtp )
                {
                    SpecificGravityNtp.Attribute1 = CswConvert.ToDbVal( true ).ToString();
                }
            }
        }
Ejemplo n.º 2
0
 /// <summary>
 /// Update logic
 /// </summary>
 public override void update()
 {
     CswNbtMetaDataObjectClass MaterialOc = _CswNbtSchemaModTrnsctn.MetaData.getObjectClass( CswNbtMetaDataObjectClass.NbtObjectClass.MaterialClass );
     foreach( CswNbtMetaDataNodeType MaterialNt in MaterialOc.getNodeTypes() )
     {
         MaterialNt.setNameTemplateText(
             CswNbtMetaData.MakeTemplateEntry( MaterialNt.getNodeTypePropByObjectClassProp( CswNbtObjClassMaterial.PropertyName.Tradename ).PropName ) + " " +
             CswNbtMetaData.MakeTemplateEntry( CswNbtObjClassMaterial.PropertyName.Supplier ) + " " +
             CswNbtMetaData.MakeTemplateEntry( CswNbtObjClassMaterial.PropertyName.PartNumber )
             );
     }
 }//Update()
Ejemplo n.º 3
0
        public override void update()
        {
            CswNbtMetaDataObjectClass ContainerOc = _CswNbtSchemaModTrnsctn.MetaData.getObjectClass( CswNbtMetaDataObjectClass.NbtObjectClass.ContainerClass );
            _CswNbtSchemaModTrnsctn.createObjectClassProp(
                ContainerOc, new CswNbtWcfMetaDataModel.ObjectClassProp
                {
                    FieldType = CswNbtMetaDataFieldType.NbtFieldType.Button,
                    PropName = CswNbtObjClassContainer.RequestPropertyName,
                    Extended = CswNbtNodePropButton.ButtonMode.menu,
                    ListOptions = CswNbtObjClassContainer.RequestMenu.Options.ToString(),
                    StaticText = CswNbtObjClassContainer.RequestMenu.Dispense
                } );

            foreach( CswNbtMetaDataNodeType ContainerNt in ContainerOc.getNodeTypes() )
            {
                CswNbtMetaDataNodeTypeTab RequestsTab = ContainerNt.getNodeTypeTab( "Requests" );
                if( null == RequestsTab )
                {
                    RequestsTab = _CswNbtSchemaModTrnsctn.MetaData.makeNewTab( ContainerNt, "Requests", ContainerNt.getNodeTypeTabIds().Count );
                }
                CswNbtMetaDataNodeTypeProp DispenseNtp = ContainerNt.getNodeTypePropByObjectClassProp( CswNbtObjClassContainer.RequestPropertyName );
                DispenseNtp.updateLayout( CswNbtMetaDataNodeTypeLayoutMgr.LayoutType.Edit, true, RequestsTab.TabId, 1, 1 );
                DispenseNtp.updateLayout( CswNbtMetaDataNodeTypeLayoutMgr.LayoutType.Table, true, RequestsTab.TabId, 1, 1 );

                CswNbtMetaDataNodeTypeProp RequestsGridNtp = _CswNbtSchemaModTrnsctn.MetaData.makeNewProp( ContainerNt, CswNbtMetaDataFieldType.NbtFieldType.Grid, "Submitted Requests", RequestsTab.TabId );
                CswNbtView GridView = _CswNbtSchemaModTrnsctn.ViewSelect.restoreView( RequestsGridNtp.ViewId );
                makeRequestGridView( GridView, ContainerNt );
            }

            CswNbtMetaDataObjectClass MaterialOc = _CswNbtSchemaModTrnsctn.MetaData.getObjectClass( CswNbtMetaDataObjectClass.NbtObjectClass.MaterialClass );
            CswNbtMetaDataObjectClassProp MaterialRequestOcp = _CswNbtSchemaModTrnsctn.createObjectClassProp(
                MaterialOc, new CswNbtWcfMetaDataModel.ObjectClassProp
                {
                    FieldType = CswNbtMetaDataFieldType.NbtFieldType.Button,
                    PropName = CswNbtObjClassMaterial.RequestPropertyName
                } );
            foreach( CswNbtMetaDataNodeType MaterialNt in MaterialOc.getNodeTypes() )
            {
                CswNbtMetaDataNodeTypeTab IdentityTab = MaterialNt.getNodeTypeTab( "Identity" );
                if( null == IdentityTab )
                {
                    IdentityTab = _CswNbtSchemaModTrnsctn.MetaData.makeNewTab(MaterialNt, "Identity", MaterialNt.getNodeTypeTabIds().Count);
                }
                CswNbtMetaDataNodeTypeProp RequestBtnNtp = MaterialNt.getNodeTypePropByObjectClassProp( CswNbtObjClassMaterial.RequestPropertyName );
                RequestBtnNtp.updateLayout( CswNbtMetaDataNodeTypeLayoutMgr.LayoutType.Edit, true, IdentityTab.TabId );
            }

        }//Update()
Ejemplo n.º 4
0
 public override void update()
 {
     CswNbtMetaDataObjectClass MaterialOc = _CswNbtSchemaModTrnsctn.MetaData.getObjectClass( CswNbtMetaDataObjectClass.NbtObjectClass.MaterialClass );
     foreach( CswNbtMetaDataNodeType MaterialNt in MaterialOc.getNodeTypes() )
     {
         CswNbtMetaDataNodeTypeTab IdentityTab = MaterialNt.getNodeTypeTab( "Identity" );
         if( null == IdentityTab )
         {
             IdentityTab = _CswNbtSchemaModTrnsctn.MetaData.makeNewTab( MaterialNt, "Identity", MaterialNt.getNodeTypeTabIds().Count );
         }
         CswNbtMetaDataNodeTypeProp RequestBtnNtp = MaterialNt.getNodeTypePropByObjectClassProp( CswNbtObjClassMaterial.RequestPropertyName );
         RequestBtnNtp.updateLayout( CswNbtMetaDataNodeTypeLayoutMgr.LayoutType.Edit, true, IdentityTab.TabId );
         CswNbtMetaDataNodeTypeProp ReceiveBtnNtp = MaterialNt.getNodeTypePropByObjectClassProp( CswNbtObjClassMaterial.ReceivePropertyName );
         ReceiveBtnNtp.updateLayout( CswNbtMetaDataNodeTypeLayoutMgr.LayoutType.Edit, true, IdentityTab.TabId );
     }
 }//Update()
Ejemplo n.º 5
0
 public override void update()
 {
     CswNbtMetaDataObjectClass MaterialOc = _CswNbtSchemaModTrnsctn.MetaData.getObjectClass( NbtObjectClass.MaterialClass );
     foreach( CswNbtMetaDataNodeType MaterialNt in MaterialOc.getLatestVersionNodeTypes() )
     {
         CswNbtMetaDataNodeTypeTab IdentityTab = MaterialNt.getIdentityTab();
         if( null != IdentityTab )
         {
             CswNbtMetaDataNodeTypeProp ReceiveNtp = MaterialNt.getNodeTypePropByObjectClassProp( CswNbtObjClassMaterial.PropertyName.Receive );
             ReceiveNtp.updateLayout( CswNbtMetaDataNodeTypeLayoutMgr.LayoutType.Edit, DoMove : false, DisplayColumn : 2, DisplayRow : 1, TabId : IdentityTab.TabId );
             CswNbtMetaDataNodeTypeProp RequestNtp = MaterialNt.getNodeTypePropByObjectClassProp( CswNbtObjClassMaterial.PropertyName.Request );
             RequestNtp.updateLayout( CswNbtMetaDataNodeTypeLayoutMgr.LayoutType.Edit, DoMove : false, DisplayColumn : 2, DisplayRow : 2, TabId : IdentityTab.TabId );
             CswNbtMetaDataNodeTypeProp PartNoNtp = MaterialNt.getNodeTypePropByObjectClassProp( CswNbtObjClassMaterial.PropertyName.PartNumber );
             PartNoNtp.updateLayout( CswNbtMetaDataNodeTypeLayoutMgr.LayoutType.Edit, DoMove : false, DisplayColumn : 1, DisplayRow : 1, TabId : IdentityTab.TabId );
             CswNbtMetaDataNodeTypeProp TradenameNtp = MaterialNt.getNodeTypePropByObjectClassProp( CswNbtObjClassMaterial.PropertyName.Tradename );
             TradenameNtp.updateLayout( CswNbtMetaDataNodeTypeLayoutMgr.LayoutType.Edit, DoMove : false, DisplayColumn : 1, DisplayRow : 2, TabId : IdentityTab.TabId );
             CswNbtMetaDataNodeTypeProp SupplierNtp = MaterialNt.getNodeTypePropByObjectClassProp( CswNbtObjClassMaterial.PropertyName.Supplier );
             SupplierNtp.updateLayout( CswNbtMetaDataNodeTypeLayoutMgr.LayoutType.Edit, DoMove : false, DisplayColumn : 1, DisplayRow : 3, TabId : IdentityTab.TabId );
         }
     }
 } //Update()
Ejemplo n.º 6
0
        public override void update()
        {
            CswNbtMetaDataObjectClass MaterialOc = _CswNbtSchemaModTrnsctn.MetaData.getObjectClass( CswNbtMetaDataObjectClass.NbtObjectClass.MaterialClass );

            foreach( CswNbtMetaDataNodeType MaterialNt in MaterialOc.getNodeTypes() )
            {
                CswNbtMetaDataNodeTypeProp RequestsGridNtp = MaterialNt.getNodeTypeProp( "Submitted Requests" );
                if( null != RequestsGridNtp )
                {
                    _CswNbtSchemaModTrnsctn.MetaData.DeleteNodeTypeProp( RequestsGridNtp );
                }
                CswNbtMetaDataNodeTypeTab RequestsTab = MaterialNt.getNodeTypeTab( "Requests" );
                if( null != RequestsTab )
                {
                    _CswNbtSchemaModTrnsctn.MetaData.DeleteNodeTypeTab( RequestsTab );
                }
                //CswNbtMetaDataNodeTypeProp RequestBtnNtp = MaterialNt.getNodeTypePropByObjectClassProp( CswNbtObjClassMaterial.RequestPropertyName );
                //bool Moved = false;
                //foreach( CswNbtMetaDataNodeTypeTab Tab in MaterialNt.getNodeTypeTabs() )
                //{
                //    if( Tab.TabName == MaterialNt.NodeTypeName )
                //    {
                //        RequestBtnNtp.updateLayout( CswNbtMetaDataNodeTypeLayoutMgr.LayoutType.Edit, true, Tab.TabId );
                //        RequestBtnNtp.updateLayout( CswNbtMetaDataNodeTypeLayoutMgr.LayoutType.Table, true, Tab.TabId );
                //        Moved = true;
                //    }
                //}
                //if( false == Moved )
                //{
                //    CswNbtMetaDataNodeTypeTab Tab = MaterialNt.getNodeTypeTabs().FirstOrDefault();
                //    if( null != Tab )
                //    {
                //        RequestBtnNtp.updateLayout( CswNbtMetaDataNodeTypeLayoutMgr.LayoutType.Edit, true, Tab.TabId );
                //        RequestBtnNtp.updateLayout( CswNbtMetaDataNodeTypeLayoutMgr.LayoutType.Table, true, Tab.TabId );
                //    }
                //}
            }

        }//Update()
Ejemplo n.º 7
0
        public override void update()
        {
            CswNbtMetaDataObjectClass InventoryLevelOc = _CswNbtSchemaModTrnsctn.createObjectClass( CswNbtMetaDataObjectClass.NbtObjectClass.InventoryLevelClass, "docs.gif", true, false );
            CswNbtMetaDataObjectClass MaterialOc = _CswNbtSchemaModTrnsctn.MetaData.getObjectClass( CswNbtMetaDataObjectClass.NbtObjectClass.MaterialClass );
            CswNbtMetaDataObjectClassProp IlMaterialOcp = _CswNbtSchemaModTrnsctn.createObjectClassProp( InventoryLevelOc, new CswNbtWcfMetaDataModel.ObjectClassProp
            {
                PropName = CswNbtObjClassInventoryLevel.PropertyName.Material,
                FieldType = CswNbtMetaDataFieldType.NbtFieldType.Relationship,
                IsFk = true,
                FkType = NbtViewRelatedIdType.ObjectClassId.ToString(),
                FkValue = MaterialOc.ObjectClassId,
                IsRequired = true,
                IsCompoundUnique = true
            } );

            CswNbtMetaDataObjectClassProp IlLocationOcp = _CswNbtSchemaModTrnsctn.createObjectClassProp( InventoryLevelOc, new CswNbtWcfMetaDataModel.ObjectClassProp
            {
                PropName = CswNbtObjClassInventoryLevel.PropertyName.Location,
                FieldType = CswNbtMetaDataFieldType.NbtFieldType.Location,
                IsRequired = true,
                IsCompoundUnique = true
            } );

            CswNbtMetaDataObjectClassProp IlTypeOcp = _CswNbtSchemaModTrnsctn.createObjectClassProp( InventoryLevelOc, new CswNbtWcfMetaDataModel.ObjectClassProp
            {
                PropName = CswNbtObjClassInventoryLevel.PropertyName.Type,
                FieldType = CswNbtMetaDataFieldType.NbtFieldType.List,
                ListOptions = CswNbtObjClassInventoryLevel.Types.Options.ToString(),
                IsRequired = true,
                IsCompoundUnique = true
            } );

            CswNbtMetaDataObjectClassProp IlLevelOcp = _CswNbtSchemaModTrnsctn.createObjectClassProp( InventoryLevelOc, new CswNbtWcfMetaDataModel.ObjectClassProp
            {
                PropName = CswNbtObjClassInventoryLevel.PropertyName.Level,
                FieldType = CswNbtMetaDataFieldType.NbtFieldType.Quantity,
                IsRequired = true
            } );

            _CswNbtSchemaModTrnsctn.createObjectClassProp( InventoryLevelOc, new CswNbtWcfMetaDataModel.ObjectClassProp
            {
                PropName = CswNbtObjClassInventoryLevel.PropertyName.Subscribe,
                FieldType = CswNbtMetaDataFieldType.NbtFieldType.UserSelect,
                SetValOnAdd = true
            } );

            _CswNbtSchemaModTrnsctn.createObjectClassProp( InventoryLevelOc, new CswNbtWcfMetaDataModel.ObjectClassProp
            {
                PropName = CswNbtObjClassInventoryLevel.PropertyName.LastNotified,
                FieldType = CswNbtMetaDataFieldType.NbtFieldType.DateTime,
                ServerManaged = true
            } );

            CswNbtMetaDataObjectClassProp IlStatusOcp = _CswNbtSchemaModTrnsctn.createObjectClassProp( InventoryLevelOc, new CswNbtWcfMetaDataModel.ObjectClassProp
            {
                PropName = CswNbtObjClassInventoryLevel.PropertyName.Status,
                FieldType = CswNbtMetaDataFieldType.NbtFieldType.List,
                ListOptions = CswNbtObjClassInventoryLevel.Statuses.Options.ToString(),
                ServerManaged = true
            } );
            _CswNbtSchemaModTrnsctn.MetaData.SetObjectClassPropDefaultValue( IlStatusOcp, IlStatusOcp.getFieldTypeRule().SubFields.Default.Name, CswNbtObjClassInventoryLevel.Statuses.Ok );

            _CswNbtSchemaModTrnsctn.createModuleObjectClassJunction( CswNbtResources.CswNbtModule.CISPro, InventoryLevelOc.ObjectClassId );

            CswNbtMetaDataNodeType InventoryLevelNt = _CswNbtSchemaModTrnsctn.MetaData.getNodeType( "Inventory Level" );
            if( null != InventoryLevelNt && InventoryLevelNt.ObjectClassId != InventoryLevelOc.ObjectClassId )
            {
                InventoryLevelNt = _CswNbtSchemaModTrnsctn.MetaData.getNodeType( "CISPro Inventory Level" );
            }
            if( null != InventoryLevelNt && InventoryLevelNt.ObjectClassId != InventoryLevelOc.ObjectClassId )
            {
                CswStatusMessage Msg = new CswStatusMessage
                                            {
                                                AppType = AppType.SchemUpdt,
                                                ContentType = ContentType.Error
                                            };
                Msg.Attributes.Add( ChemSW.Log.LegalAttribute.exoteric_message, "Nodetypes 'Inventory Level' and 'CISPro Inventory Level' already exist and are not of the InventoryLevel Object Class." );
                _CswNbtSchemaModTrnsctn.CswLogger.send( Msg );
            }
            if( null == InventoryLevelNt )
            {
                InventoryLevelNt = _CswNbtSchemaModTrnsctn.MetaData.makeNewNodeType( new CswNbtWcfMetaDataModel.NodeType( InventoryLevelOc )
                                                                         {
                                                                             NodeTypeName = "Inventory Level",
                                                                             Category = "Materials",
                                                                         } );
                CswNbtMetaDataNodeTypeProp Material = InventoryLevelNt.getNodeTypePropByObjectClassProp( CswNbtObjClassInventoryLevel.PropertyName.Material );
                CswNbtMetaDataNodeTypeProp Level = InventoryLevelNt.getNodeTypePropByObjectClassProp( CswNbtObjClassInventoryLevel.PropertyName.Level );
                CswNbtMetaDataNodeTypeProp Type = InventoryLevelNt.getNodeTypePropByObjectClassProp( CswNbtObjClassInventoryLevel.PropertyName.Type );
                InventoryLevelNt.addNameTemplateText( Material.PropName );
                InventoryLevelNt.addNameTemplateText( Type.PropName );
                InventoryLevelNt.addNameTemplateText( Level.PropName );
            }

            foreach( CswNbtMetaDataNodeType MaterialNt in MaterialOc.getLatestVersionNodeTypes() )
            {
                CswNbtMetaDataNodeTypeTab PhysicalTab = MaterialNt.getNodeTypeTab( "Physical Tab" );
                if( null != PhysicalTab )
                {
                    PhysicalTab.TabName = "Physical";
                }
                else
                {
                    PhysicalTab = MaterialNt.getNodeTypeTab( "Physical" );
                    if( null == PhysicalTab )
                    {
                        PhysicalTab = _CswNbtSchemaModTrnsctn.MetaData.makeNewTab( MaterialNt, "Physical", MaterialNt.getNodeTypeTabIds().Count );
                    }
                }
                CswNbtMetaDataNodeTypeProp LevelsNtp = _CswNbtSchemaModTrnsctn.MetaData.makeNewProp( new CswNbtWcfMetaDataModel.NodeTypeProp( MaterialNt, _CswNbtSchemaModTrnsctn.MetaData.getFieldType( CswNbtMetaDataFieldType.NbtFieldType.Grid ), "Inventory Levels" )
                {
                    TabId = PhysicalTab.TabId
                } );
                LevelsNtp.Extended = CswNbtNodePropGrid.GridPropMode.Link.ToString();

                CswNbtView LevelsView = _CswNbtSchemaModTrnsctn.restoreView( LevelsNtp.ViewId );
                if( null == LevelsView )
                {
                    LevelsView = _CswNbtSchemaModTrnsctn.makeView();
                    LevelsNtp.ViewId = LevelsView.ViewId;
                }

                LevelsView.Root.ChildRelationships.Clear();
                LevelsView.ViewMode = NbtViewRenderingMode.Grid;
                LevelsView.Visibility = NbtViewVisibility.Property;

                CswNbtViewRelationship RootRel = LevelsView.AddViewRelationship( MaterialNt, true );
                CswNbtViewRelationship LevelRel = LevelsView.AddViewRelationship( RootRel, NbtViewPropOwnerType.Second, IlMaterialOcp, true );
                LevelsView.AddViewProperty( LevelRel, IlTypeOcp );
                LevelsView.AddViewProperty( LevelRel, IlLevelOcp );
                LevelsView.AddViewProperty( LevelRel, IlLocationOcp );
                LevelsView.AddViewProperty( LevelRel, IlStatusOcp );
                LevelsView.save();
            }

        }//Update()
        public override void update()
        {
            #region Init

            CswNbtLandingPageTable LandingPageObj = _CswNbtSchemaModTrnsctn.getLandingPageTable();
            string CreateMaterialActionId = _CswNbtSchemaModTrnsctn.Actions[CswNbtActionName.Create_Material].ActionId.ToString();
            string RoleId = "nodes_1";
            CswNbtObjClassRole AdminRole = _CswNbtSchemaModTrnsctn.Nodes.makeRoleNodeFromRoleName( "Administrator" );
            if( null != AdminRole )
            {
                RoleId = AdminRole.NodeId.ToString();
            }

            CswNbtMetaDataObjectClass MaterialOc = _CswNbtSchemaModTrnsctn.MetaData.getObjectClass( NbtObjectClass.MaterialClass );

            #endregion Init

            #region Create Another Material

            LandingPageData.Request Request = new LandingPageData.Request
            {
                Type = CswNbtLandingPageItemType.Link,
                ViewType = "Action",
                PkValue = CreateMaterialActionId,
                NodeTypeId = String.Empty,
                Text = "Create Another Material",
                RoleId = RoleId,
                ActionId = CreateMaterialActionId,
                NewRow = 1,
                NewColumn = 3
            };
            LandingPageObj.addLandingPageItem( Request );

            #endregion Create Another Material

            #region Receive this Material

            CswNbtMetaDataObjectClassProp ReceiveProp =
                _CswNbtSchemaModTrnsctn.MetaData.getObjectClassProp( MaterialOc.ObjectClassId,
                                                                    CswNbtObjClassMaterial.PropertyName.Receive );
            if( null != ReceiveProp )
            {
                Request = new LandingPageData.Request
                {
                    Type = CswNbtLandingPageItemType.Button,
                    ViewType = String.Empty,
                    PkValue = ReceiveProp.PropId.ToString(),
                    NodeTypeId = String.Empty,
                    Text = "Receive this Material",
                    RoleId = RoleId,
                    ActionId = CreateMaterialActionId,
                    NewRow = 1,
                    NewColumn = 1
                };
                LandingPageObj.addLandingPageItem( Request );
            }

            #endregion Receive this Material

            #region Request this Material

            CswNbtMetaDataObjectClassProp RequestProp =
                _CswNbtSchemaModTrnsctn.MetaData.getObjectClassProp(MaterialOc.ObjectClassId,
                                                                    CswNbtObjClassMaterial.PropertyName.Request);
            if( null != RequestProp )
            {
                Request = new LandingPageData.Request
                {
                    Type = CswNbtLandingPageItemType.Button,
                    ViewType = String.Empty,
                    PkValue = RequestProp.PropId.ToString(),
                    NodeTypeId = String.Empty,
                    Text = "Request this Material",
                    RoleId = RoleId,
                    ActionId = CreateMaterialActionId,
                    NewRow = 1,
                    NewColumn = 2
                };
                LandingPageObj.addLandingPageItem( Request );
            }

            #endregion Request this Material

            #region Define Sizes for this Material

            CswNbtMetaDataObjectClass SizeOc = _CswNbtSchemaModTrnsctn.MetaData.getObjectClass( NbtObjectClass.SizeClass );
            CswNbtMetaDataNodeType SizeNt = SizeOc.FirstNodeType;
            if( null != SizeNt )
            {
                Request = new LandingPageData.Request
                {
                    Type = CswNbtLandingPageItemType.Add,
                    ViewType = String.Empty,
                    PkValue = String.Empty,
                    NodeTypeId = SizeNt.NodeTypeId.ToString(),
                    Text = "Define Sizes for this Material",
                    RoleId = RoleId,
                    ActionId = CreateMaterialActionId,
                    NewRow = 2,
                    NewColumn = 1
                };
                LandingPageObj.addLandingPageItem(Request);
            }

            #endregion Define Sizes for this Material

            #region Enter GHS Data for this Material
            
            foreach( CswNbtMetaDataNodeType MaterialNt in MaterialOc.getNodeTypes() )
            {
                if( MaterialNt.NodeTypeName == "Chemical" )
                {
                    CswNbtMetaDataNodeTypeTab GHSTab = MaterialNt.getNodeTypeTab( "GHS" );
                    if( null != GHSTab )
                    {
                        Request = new LandingPageData.Request
                        {
                            Type = CswNbtLandingPageItemType.Tab,
                            ViewType = "View",
                            PkValue = GHSTab.TabId.ToString(),
                            NodeTypeId = MaterialNt.NodeTypeId.ToString(),
                            Text = "Enter GHS Data for this Material",
                            RoleId = RoleId,
                            ActionId = CreateMaterialActionId,
                            NewRow = 2,
                            NewColumn = 2
                        };
                        LandingPageObj.addLandingPageItem( Request );
                    }
                }
            }

            #endregion Enter GHS Data for this Material

        } //Update()