lazhen
2024-05-31 1bee21090f48fcd758a4e28de0c5aac495af3d6a
事件类型有层级
已重命名1个文件
已修改7个文件
已添加50个文件
1271 ■■■■■ 文件已修改
_Main/BL/InfoMessages.qbl 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Relations/Relation_LibCal_EventTypeInEventType_AsChildren_LibCal_EventType_AllParent.qbl 23 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Relations/Relation_LibCal_EventTypeInEventType_AsParent_LibCal_EventType_AllChildren.qbl 23 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Relations/Relation_LibCal_EventType_AsRootEventType_LibCal_CalendarRegistry_RootEventT.qbl 26 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Relations/Relation_LibCal_EventType_Child_LibCal_EventType_Parent.qbl 23 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/Attribute_HasParent.qbl 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/Attribute_IsLeaf.qbl 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/Attribute_ParentID.qbl 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/DeclarativeTypeIndexRelation_CalcParent.qbl 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/Function_CalcHasParent.qbl 13 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/Function_CalcIsLeaf.qbl 13 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/Method_AssignParent.qbl 44 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/Method_DeleteChildren.qbl 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/Method_GetAllParent.qbl 20 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/Method_GetIsLeaf.qbl 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/Method_HasDescendant.qbl 21 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/Method_SetAllParent.qbl 31 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/Method_SetRootEvent.qbl 20 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/Method_Update.qbl 30 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/Method_UpdateForeignKey.qbl 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/Method_UpdateTypeIndex.qbl 21 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/StaticMethod_CanDelete.qbl 22 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/StaticMethod_Delete.qbl 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/StaticMethod_Test.qbl 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/StaticMethod_Update.qbl 17 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/StaticMethod_ValidateInput.qbl 21 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/TypeIndex_EventTypeIndex.qbl 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventEvent/_ROOT_Type_LibCal_EventType.qbl 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventTypeInEventType/Attribute_IsCurrent.qbl 8 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/Type_LibCal_EventTypeInEventType/_ROOT_Type_LibCal_EventTypeInEventType.qbl 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_ApplicationMacroPlanner/Component_ContextMenuCapacities.def 14 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_ApplicationMacroPlanner/Response_MacroPlanner_ContextMenuCapacities_MenuEventType_OnClick.def 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_ApplicationMacroPlanner/Response_MacroPlanner_ContextMenuCapacities_MenuUnavailableEvent_OnClick.def 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Component_pnlActions.def 40 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Component_pnlContent.def 67 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Method_Edit.def 20 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Method_New.def 26 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Method_OnOK.def 31 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Method_SetAttributeAfterApplyData.def 20 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Method_SetDefaultValue.def 38 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Response_pnlActions_btnCancel_OnClick.def 15 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Response_pnlActions_btnOk_OnClick.def 21 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Response_pnlContent_efName_OnInputIdle.def 20 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/_ROOT_Component_DialogCreateEditEventType.def 64 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_FormCalendarUnavailableEvent/Component_ListCalendarEventTypes.def 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_FormEventType/Component_ListEventType.def 72 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_FormEventType/Component_listActionBarPageEventType.def 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_FormEventType/Component_listContextMenuEventType.def 56 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_FormEventType/Response_ListEventType_MenuDelete_OnClick.def 24 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_FormEventType/Response_ListEventType_MenuEdit_OnClick.def 21 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_FormEventType/Response_ListEventType_MenuNew_OnClick#648.def 25 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_FormEventType/Response_ListEventType_MenuNew_OnClick.def 23 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_FormEventType/Response_listContextMenuEventType_MenuTest_OnClick.def 16 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_FormEventType/_ROOT_Component_FormEventType.def 17 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_LibCal_dlgEvent/Component_pnlEventType.def 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_LibCal_dlgMultipleEvent/Component_ListList.def 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Component_LibCal_dlgMultipleEvent/Component_PanelHeader#144.def 3 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/UI/MacroPlannerWebApp/Views/Event_type_view.vw 68 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
_Main/BL/InfoMessages.qbl
@@ -86,4 +86,12 @@
  {
    DefaultText: 'There are duplicate three digit codes present'
  }
  InfoMessage MP_LibCal_EventType_Exist
  {
    DefaultText: 'The ID or name is the same.'
  }
  InfoMessage MP_LibCal_EventType_HasEvent
  {
    DefaultText: 'The Event type of binding Event exists.'
  }
}
_Main/BL/Relations/Relation_LibCal_EventTypeInEventType_AsChildren_LibCal_EventType_AllParent.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,23 @@
Quintiq file version 2.0
#parent: #root
Relation LibCal_EventTypeInEventType_AsChildren_LibCal_EventType_AllParent
{
  #keys: '1[415136.0.721964682]'
  DefaultRelationStrategy
  {
  }
  RelationSide.LeftSide AsChildren
  {
    #keys: '3[415136.0.721964684][415136.0.721964683][415136.0.721964685]'
    Cardinality: '0to1'
    ObjectDefinition: LibCal_EventTypeInEventType
    OwningSide: 'Reference'
  }
  RelationSide.RightSide AllParent
  {
    #keys: '3[415136.0.721964687][415136.0.721964686][415136.0.721964688]'
    Cardinality: '1toN'
    ObjectDefinition: LibCal_EventType
    OwningSide: 'Owned'
  }
}
_Main/BL/Relations/Relation_LibCal_EventTypeInEventType_AsParent_LibCal_EventType_AllChildren.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,23 @@
Quintiq file version 2.0
#parent: #root
Relation LibCal_EventTypeInEventType_AsParent_LibCal_EventType_AllChildren
{
  #keys: '1[415136.0.721964707]'
  DefaultRelationStrategy
  {
  }
  RelationSide.LeftSide AsParent
  {
    #keys: '3[415136.0.721964709][415136.0.721964708][415136.0.721964710]'
    Cardinality: '0to1'
    ObjectDefinition: LibCal_EventTypeInEventType
    OwningSide: 'Reference'
  }
  RelationSide.RightSide AllChildren
  {
    #keys: '3[415136.0.721964712][415136.0.721964711][415136.0.721964713]'
    Cardinality: '1toN'
    ObjectDefinition: LibCal_EventType
    OwningSide: 'Reference'
  }
}
_Main/BL/Relations/Relation_LibCal_EventType_AsRootEventType_LibCal_CalendarRegistry_RootEventT.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,26 @@
Quintiq file version 2.0
#parent: #root
Relation LibCal_EventType_AsRootEventType_LibCal_CalendarRegistry_RootEventType
{
  #keys: '1[415136.0.721964845]'
  ProceduralSequenceRelationStrategy
  {
    #keys: '13[0.0.0][415136.0.721964864][415136.0.721964858][415136.0.721964865][415136.0.721964859][415136.0.721964866][415136.0.721964860][415136.0.721964867][415136.0.721964861][415136.0.721964868][415136.0.721964862][415136.0.721964869][415136.0.721964863]'
    SequenceElementSuffix: 'RootEventType'
    SequenceSuffix: 'RootEventType'
  }
  RelationSide.LeftSide AsRootEventType
  {
    #keys: '3[415136.0.721964847][415136.0.721964846][415136.0.721964848]'
    Cardinality: '0to1'
    ObjectDefinition: LibCal_EventType
    OwningSide: 'Reference'
  }
  RelationSide.RightSide RootEventType
  {
    #keys: '3[415136.0.721964850][415136.0.721964849][415136.0.721964851]'
    Cardinality: '1toN'
    ObjectDefinition: LibCal_CalendarRegistry
    OwningSide: 'Reference'
  }
}
_Main/BL/Relations/Relation_LibCal_EventType_Child_LibCal_EventType_Parent.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,23 @@
Quintiq file version 2.0
#parent: #root
Relation LibCal_EventType_Child_LibCal_EventType_Parent
{
  #keys: '1[415136.0.721945049]'
  DefaultRelationStrategy
  {
  }
  RelationSide.LeftSide Child
  {
    #keys: '3[415136.0.721945051][415136.0.721945050][415136.0.721945052]'
    Cardinality: '1toN'
    ObjectDefinition: LibCal_EventType
    OwningSide: 'Reference'
  }
  RelationSide.RightSide Parent
  {
    #keys: '3[415136.0.721945054][415136.0.721945053][415136.0.721945055]'
    Cardinality: '0to1'
    ObjectDefinition: LibCal_EventType
    OwningSide: 'Reference'
  }
}
_Main/BL/Type_LibCal_EventEvent/Attribute_HasParent.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,8 @@
Quintiq file version 2.0
#parent: #root
Attribute HasParent
{
  #keys: '3[415136.0.721964666][415136.0.721964665][415136.0.721964667]'
  Description: 'Product has parent.'
  ValueType: Boolean
}
_Main/BL/Type_LibCal_EventEvent/Attribute_IsLeaf.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,12 @@
Quintiq file version 2.0
#parent: #root
Attribute IsLeaf
{
  #keys: '3[415136.0.722000028][415136.0.722000027][415136.0.722000029]'
  Description:
  [*
    Indicate if the event type in a leaf event type.
    Leaf event type have no child event type.
  *]
  ValueType: Boolean
}
_Main/BL/Type_LibCal_EventEvent/Attribute_ParentID.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,8 @@
Quintiq file version 2.0
#parent: #root
Attribute ParentID
{
  #keys: '3[415136.0.721945071][415136.0.721945070][415136.0.721945072]'
  Description: '父级ID'
  ValueType: String
}
_Main/BL/Type_LibCal_EventEvent/DeclarativeTypeIndexRelation_CalcParent.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,16 @@
Quintiq file version 2.0
#parent: #root
DeclarativeTypeIndexRelation CalcParent
{
  #keys: '1[415136.0.721945080]'
  Relation: Parent
  TypeIndex: EventTypeIndex
  TypeIndexExpressions:
  [
    DeclarativeRelationTypeIndexExpression
    {
      #keys: '1[415136.0.721945081]'
      TypeIndexExpression: 'this.ParentID()//String'
    }
  ]
}
_Main/BL/Type_LibCal_EventEvent/Function_CalcHasParent.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,13 @@
Quintiq file version 2.0
#parent: #root
Function CalcHasParent
{
  TextBody:
  [*
    // ç”„兰鸽 May-31-2024 (created)
    value := not isnull( this.Parent() );
    this.HasParent( value );
  *]
}
_Main/BL/Type_LibCal_EventEvent/Function_CalcIsLeaf.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,13 @@
Quintiq file version 2.0
#parent: #root
Function CalcIsLeaf
{
  TextBody:
  [*
    // ç”„兰鸽 May-31-2024 (created)
    value := this.GetIsLeaf();
    this.IsLeaf( value );
  *]
}
_Main/BL/Type_LibCal_EventEvent/Method_AssignParent.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,44 @@
Quintiq file version 2.0
#parent: #root
Method AssignParent (
  LibCal_EventType parent
)
{
  Description: 'Assign this event type as a child of the given event type'
  TextBody:
  [*
    // zlg Nov-20-2015 (created)
    oldparent := this.Parent();
    newparentid := guard( parent.ID(), '' );
    hasnewparent := guard( oldparent.ID(), '' ) <> newparentid;
    if( this.HasDescendant( parent ) )
    {
      parent.ParentID( this.ParentID() );
    }
    this.ParentID( newparentid );
    // Calculate siblings of the product to the new parent
    if( hasnewparent )
    {
      this.ParentID( guard( parent.ID(), '' ) );
      traverse( this, AllChildren.AsChildren, p )
      {
        p.SetAllParent();
      }
      // Propogate the HasParent attribute to use in setting root product
      Transaction::Transaction().Propagate( attribute( Product_MP, HasParent ) );
      this.SetRootEvent();
    //  this.SetSiblings();
      // Recalculate siblings for the old parent
    //  traverse( oldparent, AllChildren, child )
    //  {
    //    child.AsChildren().SetSiblings();
    //  }
    }
  *]
}
_Main/BL/Type_LibCal_EventEvent/Method_DeleteChildren.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,16 @@
Quintiq file version 2.0
#parent: #root
Method DeleteChildren (
  LibCal_EventType eventtype
)
{
  Description: 'Delete event type children'
  TextBody:
  [*
    traverse( eventtype, Child, ch )
    {
      ch.DeleteChildren( ch );
      ch.Delete();
    }
  *]
}
_Main/BL/Type_LibCal_EventEvent/Method_GetAllParent.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,20 @@
Quintiq file version 2.0
#parent: #root
Method GetAllParent () as owning LibCal_EventTypes
{
  Description: 'Get all parents'
  TextBody:
  [*
    retvalue := construct( LibCal_EventTypes );
    //to avoid a transaction propagate, just find the parent instead of locating via decl relation this.Parent
    parent := LibCal_EventType::FindEventTypeIndex( this.ParentID() );
    if( not isnull( parent ) )
    {
      retvalue := parent.GetAllParent();
    }
    retvalue.Add( this );
    return &retvalue;
  *]
}
_Main/BL/Type_LibCal_EventEvent/Method_GetIsLeaf.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,11 @@
Quintiq file version 2.0
#parent: #root
Method GetIsLeaf () declarative as Boolean
{
  Description: 'Return true if product is leaf product.'
  TextBody:
  [*
    // desmondt Nov-20-2015 (created)
    return this.Child( relsize ) = 0;
  *]
}
_Main/BL/Type_LibCal_EventEvent/Method_HasDescendant.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,21 @@
Quintiq file version 2.0
#parent: #root
Method HasDescendant (
  LibCal_EventType target
) remote as Boolean
{
  Description: 'Whether this event type has descendant = target'
  TextBody:
  [*
    // soh yee 3-Apr-2013 (modified)
    value := target = this;
    if( this.Child( relsize ) > 0 )
    {
      value := exists( this, Child, ch, ch.HasDescendant( target ) ) or value;
    }
    return value;
  *]
}
_Main/BL/Type_LibCal_EventEvent/Method_SetAllParent.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,31 @@
Quintiq file version 2.0
#parent: #root
Method SetAllParent
{
  Description: 'Set all parents'
  TextBody:
  [*
    //this is to replace the getallchildrenkey
    traverse( this, AllParent, ap )
    {
      ap.IsCurrent( false );
    }
    allparent := this.GetAllParent();
    traverse( allparent, Elements, parent )
    {
      etinet := select( this, AllParent, ap, ap.AsParent() = parent, true );
      if( isnull( etinet ) )
      {
        etinet := this.AllParent( relnew, AsParent := parent );
      }
      etinet.IsCurrent( true );
    }
    traverse( this, AllParent, ap, not ap.IsCurrent() )
    {
      ap.Delete();
    }
  *]
}
_Main/BL/Type_LibCal_EventEvent/Method_SetRootEvent.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,20 @@
Quintiq file version 2.0
#parent: #root
Method SetRootEvent
{
  Description: 'Set all unit without parent as a root unit.'
  TextBody:
  [*
    // desmondt Nov-26-2015 (created)
    if( this.ParentID() = '' )
    {
      // set as root unit
      this.AsRootEventType( relset, this.CalendarRegistry() );
    }
    else
    {
      this.AsRootEventType( relflush );
    }
  *]
}
_Main/BL/Type_LibCal_EventEvent/Method_Update.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,30 @@
Quintiq file version 2.0
#parent: #root
Method Update (
  String id,
  String name,
  String parentid
)
{
  TextBody:
  [*
    // ç”„兰鸽 May-31-2024 (created)
    hasnewparent := guard( this.Parent().ID(),'' ) <> parentid;
    parent := LibCal_EventType::FindEventTypeIndex( parentid );
    isroot := isnull( parent );
    this.UpdateTypeIndex( id );
    this.Name( name );
    //Update the parent relations
    if( hasnewparent )
    {
      this.AssignParent( parent );
    }
    else if( isroot )
    {
      this.SetRootEvent();
    }
  *]
}
_Main/BL/Type_LibCal_EventEvent/Method_UpdateForeignKey.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,9 @@
Quintiq file version 2.0
#parent: #root
Method UpdateForeignKey (
  String parentid
)
{
  Description: 'Update foregin IDs'
  TextBody: 'this.ParentID( parentid );'
}
_Main/BL/Type_LibCal_EventEvent/Method_UpdateTypeIndex.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,21 @@
Quintiq file version 2.0
#parent: #root
Method UpdateTypeIndex (
  String id
)
{
  TextBody:
  [*
    // ç”„兰鸽 May-31-2024 (created)
    if( id <> this.ID() )
    {
      // Update foreign key of this Product_MP's child Product_MPs
      traverse( this, Child, c )
      {
        c.UpdateForeignKey( id );
      }
      LibCal_EventType::ChangeKeyEventTypeIndex( this, id );
    }
  *]
}
_Main/BL/Type_LibCal_EventEvent/StaticMethod_CanDelete.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,22 @@
Quintiq file version 2.0
#parent: #root
StaticMethod CanDelete (
  LibCal_EventTypes eventtypes,
  output String feedback_o
) declarative remote as Boolean
{
  Description: 'Check whether products are allowed to be deleted'
  TextBody:
  [*
    // DWE2 Feb-16-2016 (created)
    value := exists( eventtypes, Elements, e, e.Event( relsize ) > 0 );
    if( value )
    {
      feedback_o := Translations::MP_LibCal_EventType_HasEvent();
    }
    return feedback_o = '';
  *]
}
_Main/BL/Type_LibCal_EventEvent/StaticMethod_Delete.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,16 @@
Quintiq file version 2.0
#parent: #root
StaticMethod Delete (
  LibCal_EventTypes eventtypes
)
{
  Description: 'Delete event types and children'
  TextBody:
  [*
    traverse( eventtypes, Elements, e, not isnull( e ) )
    {
      e.DeleteChildren( e );
      e.Delete();
    }
  *]
}
_Main/BL/Type_LibCal_EventEvent/StaticMethod_Test.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,12 @@
Quintiq file version 2.0
#parent: #root
StaticMethod Test (
  LibCal_CalendarRegistry owner
)
{
  TextBody:
  [*
    // ç”„兰鸽 May-31-2024 (created)
    owner.EventType( relflush );
  *]
}
_Main/BL/Type_LibCal_EventEvent/StaticMethod_Update.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,17 @@
Quintiq file version 2.0
#parent: #root
StaticMethod Update (
  LibCal_EventType eventtype,
  String id,
  String name,
  LibCal_EventType parent
)
{
  TextBody:
  [*
    // ç”„兰鸽 May-31-2024 (created)
    parentid := guard( parent.ID(), '' );
    eventtype.Update( id, name, parentid );
  *]
}
_Main/BL/Type_LibCal_EventEvent/StaticMethod_ValidateInput.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,21 @@
Quintiq file version 2.0
#parent: #root
StaticMethod ValidateInput (
  output String feedback,
  LibCal_CalendarRegistry owner,
  String id,
  String name
) as Boolean
{
  TextBody:
  [*
    // ç”„兰鸽 May-31-2024 (created)
    feedback := '';
    if( exists( owner, EventType, et, et.ID() = id or et.Name() = name ) ){
      feedback := Translations::MP_LibCal_EventType_Exist();
    }
    return feedback = '';
  *]
}
_Main/BL/Type_LibCal_EventEvent/TypeIndex_EventTypeIndex.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,12 @@
Quintiq file version 2.0
#parent: #root
TypeIndex EventTypeIndex
{
  Attributes:
  [
    TypeIndexAttribute
    {
      ModelElement: ID
    }
  ]
}
_Main/BL/Type_LibCal_EventEvent/_ROOT_Type_LibCal_EventType.qbl
@@ -5,5 +5,13 @@
{
  #keys: '5[415136.0.714581706][415136.0.714581704][0.0.0][415136.0.714581705][415136.0.714581707]'
  BaseType: Object
  OnCommit:
  [*
    if( isnew ){
      this.Update( this.ID(), this.Name(), this.ParentID() );
      this.SetAllParent();
      this.SetRootEvent();
    }
  *]
  StructuredName: 'LibCal_EventTypes'
}
_Main/BL/Type_LibCal_EventTypeInEventType/Attribute_IsCurrent.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,8 @@
Quintiq file version 2.0
#parent: #root
Attribute IsCurrent
{
  #keys: '3[415136.0.721964679][415136.0.721964678][415136.0.721964680]'
  Description: 'To be use in get all parent, eg to remove obsolete link'
  ValueType: Boolean
}
_Main/BL/Type_LibCal_EventTypeInEventType/_ROOT_Type_LibCal_EventTypeInEventType.qbl
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,9 @@
Quintiq file version 2.0
#root
#parent: #DomainModel
Type LibCal_EventTypeInEventType
{
  #keys: '5[415136.0.721964675][415136.0.721964673][0.0.0][415136.0.721964674][415136.0.721964676]'
  BaseType: Object
  StructuredName: 'LibCal_EventTypeInEventTypes'
}
_Main/UI/MacroPlannerWebApp/Component_ApplicationMacroPlanner/Component_ContextMenuCapacities.def
@@ -3,7 +3,7 @@
{
  Children:
  [
    Component MenuCapacitiesUnavailableEvent
    Component MenuUnavailableEvent
    {
      #keys: '[415136.0.645511697]'
      BaseType: 'WebMenu'
@@ -15,5 +15,17 @@
        Tooltip: 'Calendar unavailable event'
      ]
    }
    Component MenuEventType
    {
      #keys: '[415136.0.725671811]'
      BaseType: 'WebMenu'
      Properties:
      [
        Image: 'ELEMENTS_TREE'
        Taborder: 7
        Title: 'Event type'
        Tooltip: 'Event type'
      ]
    }
  ]
}
_Main/UI/MacroPlannerWebApp/Component_ApplicationMacroPlanner/Response_MacroPlanner_ContextMenuCapacities_MenuEventType_OnClick.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,16 @@
Quintiq file version 2.0
#parent: ContextMenuCapacities/MenuEventType
Response OnClick () id:Response_MacroPlanner_ContextMenuCapacities_MenuEventType_OnClick
{
  #keys: '[415136.0.725671864]'
  CanBindMultiple: false
  DefinitionID: 'Responsedef_WebMenu_OnClick'
  QuillAction
  {
    Body:
    [*
      ApplicationScope.ViewManager().ResetUserViewById( "Event_type_view", true);
    *]
    GroupServerCalls: false
  }
}
_Main/UI/MacroPlannerWebApp/Component_ApplicationMacroPlanner/Response_MacroPlanner_ContextMenuCapacities_MenuUnavailableEvent_OnClick.def
ÎļþÃû´Ó _Main/UI/MacroPlannerWebApp/Component_ApplicationMacroPlanner/Response_MacroPlanner_ContextMenuCapacities_MenuCapacitiesUnavailableEvent_O.def ÐÞ¸Ä
@@ -1,6 +1,6 @@
Quintiq file version 2.0
#parent: ContextMenuCapacities/MenuCapacitiesUnavailableEvent
Response OnClick () id:Response_MacroPlanner_ContextMenuCapacities_MenuCapacitiesUnavailableEvent_OnClick
#parent: ContextMenuCapacities/MenuUnavailableEvent
Response OnClick () id:Response_MacroPlanner_ContextMenuCapacities_MenuUnavailableEvent_OnClick
{
  #keys: '[415136.0.667550585]'
  CanBindMultiple: false
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Component_pnlActions.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,40 @@
Quintiq file version 2.0
Component pnlActions
{
  #keys: '[415136.0.725510881]'
  BaseType: 'WebPanel'
  Children:
  [
    Component btnOk
    {
      #keys: '[415136.0.725510885]'
      BaseType: 'WebButton'
      Properties:
      [
        Label: 'OK'
        Taborder: 0
      ]
    }
    Component btnCancel
    {
      #keys: '[415136.0.725510887]'
      BaseType: 'WebButton'
      Properties:
      [
        Label: 'Cancel'
        Taborder: 1
      ]
    }
  ]
  Properties:
  [
    Alignment: 'trailing'
    Border: true
    ExcludeFromActiveComponent: true
    FixedSize: true
    Orientation: 'horizontal'
    Padding: 'true'
    Style: 'footer'
    Taborder: 5
  ]
}
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Component_pnlContent.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,67 @@
Quintiq file version 2.0
Component pnlContent
{
  #keys: '[415136.0.725510879]'
  BaseType: 'WebPanel'
  Children:
  [
    Component efName
    {
      #keys: '[415136.0.725510966]'
      BaseType: 'WebEditField'
      Properties:
      [
        DataBinding: 'dhDialogData.Data.Name'
        Label: 'Name'
        Taborder: 0
      ]
    }
    Component efID
    {
      #keys: '[415136.0.725510984]'
      BaseType: 'WebEditField'
      Properties:
      [
        DataBinding: 'dhDialogData.Data.ID'
        Label: 'ID'
        Taborder: 1
      ]
    }
    Component selParent
    {
      #keys: '[415136.0.724250516]'
      BaseType: 'WebDropDownList'
      Databinding: 'LibCal_EventType'
      Children:
      [
        Component DataExtractorProduct
        {
          #keys: '[415136.0.724250517]'
          BaseType: 'WebDataExtractor'
          Properties:
          [
            DataType: 'structured[LibCal_EventType]'
            Source: 'dhParentEventTypeSelection'
            Taborder: 0
            Transformation: 'Elements'
          ]
        }
      ]
      Properties:
      [
        AllowEmpty: true
        DataBinding: 'dhDialogData.Data.Parent'
        DisplayField: 'Name'
        FixedSize: false
        Label: 'Parent event type'
        Taborder: 2
        Tooltip: '<html>Leave empty if the product is at the highest level of the product hierarchy.<br>Otherwise select the parent product.</html>'
      ]
    }
  ]
  Properties:
  [
    Padding: 'true'
    Taborder: 4
  ]
}
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Method_Edit.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,20 @@
Quintiq file version 2.0
#parent: #root
Method Edit (
  LibCal_EventType selection
) id:Method_DialogCreateEditEventType_Edit
{
  #keys: '[415136.0.724280761]'
  Body:
  [*
    // Edit Product(s)
    owner := LibCal_GlobalState.dhGlobalCalendarRegistry().Data();
    data := shadow( selection );
    dhDialogData.Data( &data );
    Form.SetDefaultValue( owner );
    ApplicationMacroPlanner.ShowFormModal( this );
  *]
}
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Method_New.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,26 @@
Quintiq file version 2.0
#parent: #root
Method New (
  LibCal_EventType parent,
  FormEventType formEventType
) id:Method_DialogCreateEditEventType_New
{
  #keys: '[415136.0.725511525]'
  Body:
  [*
    // To create a new product
    owner := LibCal_GlobalState.dhGlobalCalendarRegistry().Data();
    obj := owner.EventType( relshadow
                                ,ID := ""
                                ,Parent           := parent
                               );
    dhDialogData.Data( &obj );
    dhForm.Data( formEventType );
    Form.SetDefaultValue( owner );
    ApplicationMacroPlanner.ShowFormModal( this );
  *]
}
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Method_OnOK.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,31 @@
Quintiq file version 2.0
#parent: #root
Method OnOK () id:Method_DialogCreateEditEventType_OnOK
{
  #keys: '[415136.0.724291168]'
  Body:
  [*
    // onOK for ProductDialog
    // When the user clicks ok,
    // we either create or edit the data
    this.ApplyChanges();
    this.SetAttributeAfterApplyData();
    data := dhDialogData.Data();
    if( isnull( data.WrappedInstance() ) ) // New
    {
      // When create product, parent relation must be null (as server method has logic to detect parent change using this relation)
      data.Parent( relflush );
      data.Commit();
      dhForm.Data().ListEventType().SelectByKey( data.WrappedInstance().Key() );
    }
    else
    {
      LibCal_EventType::Update( dhDialogData.Data().WrappedInstance(), efID.Text(), efName.Text()
                                ,guard( selParent.Data(), null(  LibCal_EventType ) ) );
    }
    this.Close();
  *]
}
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Method_SetAttributeAfterApplyData.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,20 @@
Quintiq file version 2.0
#parent: #root
Method SetAttributeAfterApplyData () id:Method_DialogCreateEditEventType_SetAttributeAfterApplyData
{
  #keys: '[415136.0.725550482]'
  Body:
  [*
    // Set attributes on apply data, before commiting the data
    data := dhDialogData.Data();
    //Parent product
    parentID := '';
    parentEventType := selParent.Data();
    if( not isnull(  parentEventType ) )
    {
      parentID := parentEventType.ID();
    }
    data.ParentID( parentID );
  *]
}
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Method_SetDefaultValue.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,38 @@
Quintiq file version 2.0
#parent: #root
Method SetDefaultValue (
  LibCal_CalendarRegistry owner
) id:Method_DialogCreateEditEventType_SetDefaultValue
{
  #keys: '[415136.0.725511682]'
  Body:
  [*
    // Set default + init dialog
    dialogInstance := dhDialogData.Data().WrappedInstance();
    isNew := isnull( dialogInstance );
    // Extract the parent product by filtering out the descendents of the selected products in order to prevent circularity
    eventtypes := construct( LibCal_EventTypes );
    if( isNew
        or dialogInstance.IsLeaf() ) // Is leaf
    {
      eventtypes := selectset( owner, EventType, et, true );
      currentScope := dhDialogDatas.Data();
      eventtypes := eventtypes.Difference( currentScope );
    }
    else if( not dialogInstance.HasParent() ) // Is root level
    {
      eventtypes := selectset( owner, RootEventType, et, et <> dialogInstance );
    }
    else // Has Parent and Child
    {
      allEventTypes := selectset( owner, EventType, et, et <> dialogInstance );
      myChildren := selectset( dialogInstance, AllChildren.AsChildren, c, true );
      eventtypes := allEventTypes.Difference( myChildren );
    }
    dhParentEventTypeSelection.Data( eventtypes.Copy() );
  *]
}
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Response_pnlActions_btnCancel_OnClick.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,15 @@
Quintiq file version 2.0
#parent: pnlActions/btnCancel
Response OnClick () id:Response_pnlActions_btnCancel_OnClick
{
  #keys: '[415136.0.725510891]'
  DefinitionID: 'Responsedef_WebButton_OnClick'
  GroupServerCalls: true
  QuillAction
  {
    Body:
    [*
      Form.Close();
    *]
  }
}
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Response_pnlActions_btnOk_OnClick.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,21 @@
Quintiq file version 2.0
#parent: pnlActions/btnOk
Response OnClick () id:Response_pnlActions_btnOk_OnClick
{
  #keys: '[415136.0.725510890]'
  DefinitionID: 'Responsedef_WebButton_OnClick'
  GroupServerCalls: true
  Precondition:
  [*
    owner := LibCal_GlobalState.dhGlobalCalendarRegistry().Data();
    return LibCal_EventType::ValidateInput( feedback, owner, efID.Text(), efName.Text() );
  *]
  QuillAction
  {
    Body:
    [*
      Form.OnOK();
    *]
  }
}
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/Response_pnlContent_efName_OnInputIdle.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,20 @@
Quintiq file version 2.0
#parent: pnlContent/efName
Response OnInputIdle () id:Response_pnlContent_efName_OnInputIdle
{
  #keys: '[415136.0.724250694]'
  CanBindMultiple: false
  DefinitionID: 'Responsedef_WebEditField_OnInputIdle'
  QuillAction
  {
    Body:
    [*
      // Update EditorID to have EditorName's value
      ApplicationMacroPlanner.SetID( efID,
                                     this.Text(),
                                     guard( dhDialogData.Data().Name(), '' ),
                                     guard( dhDialogData.Data().ID(), '' ) );
    *]
    GroupServerCalls: false
  }
}
_Main/UI/MacroPlannerWebApp/Component_DialogCreateEditEventType/_ROOT_Component_DialogCreateEditEventType.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,64 @@
Quintiq file version 2.0
#root
#parent: MacroPlannerWebApp
OrphanComponent DialogCreateEditEventType
{
  #keys: '[415136.0.725510877]'
  BaseType: 'WebForm'
  Children:
  [
    #child: pnlContent
    #child: pnlActions
    Component dhDialogData
    {
      #keys: '[415136.0.725511066]'
      BaseType: 'WebDataHolder'
      Databinding: 'shadow[LibCal_EventType]*'
      Properties:
      [
        Taborder: 0
      ]
    }
    Component dhForm
    {
      #keys: '[415136.0.725511131]'
      BaseType: 'WebDataHolder'
      Databinding: 'FormEventType'
      Properties:
      [
        Taborder: 3
      ]
    }
    Component dhDialogDatas
    {
      #keys: '[415136.0.724240386]'
      BaseType: 'WebDataHolder'
      Databinding: 'structured[LibCal_EventType]*'
      Properties:
      [
        Taborder: 1
      ]
    }
    Component dhParentEventTypeSelection
    {
      #keys: '[415136.0.724290253]'
      BaseType: 'WebDataHolder'
      Databinding: 'structured[LibCal_EventType]*'
      Properties:
      [
        MergeStyle: 'Union'
        Taborder: 2
      ]
    }
  ]
  Properties:
  [
    Alignment: 'trailing'
    EnterButton: 'btnOk'
    EscapeButton: 'btnCancel'
    ExcludeFromActiveComponent: true
    Image: 'ELEMENTS_TREE'
    Padding: 'false'
    Title: 'Event type'
  ]
}
_Main/UI/MacroPlannerWebApp/Component_FormCalendarUnavailableEvent/Component_ListCalendarEventTypes.def
@@ -14,7 +14,7 @@
        DataType: 'LibCal_CalendarRegistry'
        Source: 'LibCal_GlobalState.dhGlobalCalendarRegistry'
        Taborder: 0
        Transformation: 'EventType'
        Transformation: 'RootEventType'
      ]
    }
    #child: listActionBarPageCalendarEventTypes
@@ -25,6 +25,19 @@
      Children:
      [
        #child: listContextMenuCalendarEventTypes
        Component DataSetLevelChildEventType id:DataSetLevelChildEventType_545
        {
          #keys: '[415136.0.724250822]'
          BaseType: 'WebDataSetLevel'
          Properties:
          [
            Columns: '[{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Name","title":"Name","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Name"}}]'
            ContextMenu: 'listContextMenuCalendarEventTypes'
            RelationFromParent: 'Child'
            RelationRepeating: 'Child'
            Taborder: 1
          ]
        }
      ]
      Properties:
      [
@@ -36,6 +49,7 @@
  ]
  Properties:
  [
    CheckboxBehavior: 'include descendants'
    SelectionCheckboxes: true
    Taborder: 1
  ]
_Main/UI/MacroPlannerWebApp/Component_FormEventType/Component_ListEventType.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,72 @@
Quintiq file version 2.0
Component ListEventType
{
  #keys: '[415136.0.724211703]'
  BaseType: 'WebList'
  Children:
  [
    Component DataExtractorEventType
    {
      #keys: '[415136.0.724211704]'
      BaseType: 'WebDataExtractor'
      Properties:
      [
        DataType: 'LibCal_CalendarRegistry'
        Source: 'LibCal_GlobalState.dhGlobalCalendarRegistry'
        Taborder: 0
        Transformation: 'RootEventType'
      ]
    }
    #child: listActionBarPageEventType
    Component DataSetLevelEventType
    {
      #keys: '[415136.0.724211709]'
      BaseType: 'WebDataSetLevel'
      Children:
      [
        Component DataSetLevelChildEventType
        {
          #keys: '[415136.0.724212044]'
          BaseType: 'WebDataSetLevel'
          Properties:
          [
            Columns: '[{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"ID","title":"ID","subtotals":"","tooltip":"","width":-1,"display":"hidden","attribute":"ID"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Name","title":"Name","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Name"}}]'
            ContextMenu: 'listContextMenuEventType'
            RelationFromParent: 'Child'
            RelationRepeating: 'Child'
            Taborder: 0
          ]
        }
        #child: listContextMenuEventType
      ]
      Properties:
      [
        Columns: '[{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"ID","title":"ID","subtotals":"","tooltip":"","width":-1,"display":"hidden","attribute":"ID"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Name","title":"Name","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Name"}}]'
        ContextMenu: 'listContextMenuEventType'
        Taborder: 2
      ]
    }
  ]
  Properties:
  [
    Taborder: 0
  ]
  ResponseDefinitions:
  [
    DelegatedResponseDefinition OnClick id:Responsedef_ListEventType_WebMenu_OnClick
    {
      #keys: '[415136.0.725510588]'
      Initiator: 'WebMenu'
      IsInherited: false
      ResponseType: 'OnClick'
      Arguments:
      [
        ResponseDefinitionArgument selection
        {
          #keys: '[871.0.7140251]'
          Binding: 'this.Selection()'
        }
      ]
    }
  ]
}
_Main/UI/MacroPlannerWebApp/Component_FormEventType/Component_listActionBarPageEventType.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,10 @@
Quintiq file version 2.0
Component listActionBarPageEventType
{
  #keys: '[415136.0.724211706]'
  BaseType: 'listActionBarPage'
  Properties:
  [
    Taborder: 1
  ]
}
_Main/UI/MacroPlannerWebApp/Component_FormEventType/Component_listContextMenuEventType.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,56 @@
Quintiq file version 2.0
Component listContextMenuEventType
{
  #keys: '[415136.0.724211711]'
  BaseType: 'listContextMenu'
  Children:
  [
    Component MenuNew
    {
      #keys: '[415136.0.724212191]'
      BaseType: 'WebMenu'
      Properties:
      [
        Image: 'NEW'
        Taborder: 3
        Title: 'New'
      ]
    }
    Component MenuEdit
    {
      #keys: '[415136.0.724212233]'
      BaseType: 'WebMenu'
      Properties:
      [
        Image: 'PENCIL'
        Taborder: 4
        Title: 'Edit'
      ]
    }
    Component MenuDelete
    {
      #keys: '[415136.0.724212277]'
      BaseType: 'WebMenu'
      Properties:
      [
        Image: 'DELETE'
        Taborder: 5
        Title: 'Delete'
      ]
    }
    Component MenuTest
    {
      #keys: '[415136.0.729921977]'
      BaseType: 'WebMenu'
      Properties:
      [
        Taborder: 6
        Title: 'test'
      ]
    }
  ]
  Properties:
  [
    Taborder: 1
  ]
}
_Main/UI/MacroPlannerWebApp/Component_FormEventType/Response_ListEventType_MenuDelete_OnClick.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,24 @@
Quintiq file version 2.0
#parent: ListEventType
Response OnClick (
  structured[LibCal_EventType] selection
) id:Response_ListEventType_MenuDelete_OnClick
{
  #keys: '[415136.0.724250294]'
  CanBindMultiple: false
  DefinitionID => /ListEventType/Responsedef_ListEventType_WebMenu_OnClick
  Initiator: 'MenuDelete'
  Precondition:
  [*
    return LibCal_EventType::CanDelete( selection, feedback );
  *]
  QuillAction
  {
    Body:
    [*
      //Delete event type
      LibCal_EventType::Delete( selection );
    *]
    GroupServerCalls: false
  }
}
_Main/UI/MacroPlannerWebApp/Component_FormEventType/Response_ListEventType_MenuEdit_OnClick.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,21 @@
Quintiq file version 2.0
#parent: ListEventType
Response OnClick (
  LibCal_EventType selection
) id:Response_ListEventType_MenuEdit_OnClick
{
  #keys: '[415136.0.724280641]'
  CanBindMultiple: false
  DefinitionID => /ListEventType/Responsedef_ListEventType_WebMenu_OnClick
  Initiator: 'MenuEdit'
  QuillAction
  {
    Body:
    [*
      //Edit event type
      dlg := construct( DialogCreateEditEventType );
      dlg.Edit( selection );
    *]
    GroupServerCalls: false
  }
}
_Main/UI/MacroPlannerWebApp/Component_FormEventType/Response_ListEventType_MenuNew_OnClick#648.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,25 @@
Quintiq file version 2.0
#parent: ListEventType
Response OnClick (
  LibCal_EventType selection
) id:Response_ListEventType_MenuNew_OnClick_648
{
  #keys: '[415136.0.724290534]'
  CanBindMultiple: false
  DefinitionID => /ListEventType/Responsedef_ListEventType_WebMenu_OnClick
  Initiator: 'MenuNew'
  Precondition:
  [*
    return MacroPlan::HasMacroPlan( MacroPlan, feedback );
  *]
  QuillAction
  {
    Body:
    [*
      //Create a new Event type
      dlg := construct( DialogCreateEditEventType );
      dlg.New( selection, FormEventType );
    *]
    GroupServerCalls: false
  }
}
_Main/UI/MacroPlannerWebApp/Component_FormEventType/Response_ListEventType_MenuNew_OnClick.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,23 @@
Quintiq file version 2.0
#parent: ListEventType
Response OnClick () id:Response_ListEventType_MenuNew_OnClick
{
  #keys: '[415136.0.725510774]'
  CanBindMultiple: false
  DefinitionID => /ListEventType/Responsedef_ListEventType_WebMenu_OnClick
  Initiator: 'MenuNew'
  Precondition:
  [*
    return MacroPlan::HasMacroPlan( MacroPlan, feedback );
  *]
  QuillAction
  {
    Body:
    [*
      //Create a new Event type
      dlg := construct( DialogCreateEditEventType );
      dlg.New( null( LibCal_EventType ), FormEventType );
    *]
    GroupServerCalls: false
  }
}
_Main/UI/MacroPlannerWebApp/Component_FormEventType/Response_listContextMenuEventType_MenuTest_OnClick.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,16 @@
Quintiq file version 2.0
#parent: listContextMenuEventType/MenuTest
Response OnClick () id:Response_listContextMenuEventType_MenuTest_OnClick
{
  #keys: '[415136.0.729922011]'
  CanBindMultiple: false
  DefinitionID: 'Responsedef_WebMenu_OnClick'
  QuillAction
  {
    Body:
    [*
      LibCal_EventType::Test( LibCal_GlobalState.dhGlobalCalendarRegistry().Data() );
    *]
    GroupServerCalls: false
  }
}
_Main/UI/MacroPlannerWebApp/Component_FormEventType/_ROOT_Component_FormEventType.def
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,17 @@
Quintiq file version 2.0
#root
#parent: MacroPlannerWebApp
OrphanComponent FormEventType
{
  #keys: '[415136.0.724211650]'
  BaseType: 'WebForm'
  Children:
  [
    #child: ListEventType
  ]
  Properties:
  [
    Image: 'ELEMENTS_TREE'
    Title: 'Event type'
  ]
}
_Main/UI/MacroPlannerWebApp/Component_LibCal_dlgEvent/Component_pnlEventType.def
@@ -40,6 +40,7 @@
          Properties:
          [
            DataType: 'structured[LibCal_EventType]'
            FixedFilter: 'object.IsLeaf()'
            Source: 'dhEventTypes'
            Taborder: 0
            Transformation: 'Elements'
_Main/UI/MacroPlannerWebApp/Component_LibCal_dlgMultipleEvent/Component_ListList.def
@@ -28,7 +28,7 @@
      ]
      Properties:
      [
        Columns: '[{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Calendar.CalendarID","title":"CalendarID","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Calendar.CalendarID"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Event.EventType","title":"EventType","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Event.EventType"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Event.Subject","title":"Subject","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Event.Subject"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"StartDate","title":"StartDate","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"StartDate"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Event.StartTimeOfDay","title":"StartTimeOfDay","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Event.StartTimeOfDay"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Event.EndTimeOfDay","title":"EndTimeOfDay","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Event.EndTimeOfDay"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Event.Description","title":"Description","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Event.Description"}}]'
        Columns: '[{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Calendar.CalendarID","title":"CalendarID","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Calendar.CalendarID"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Event.EventType.Name","title":"Name","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Event.EventType.Name"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Event.Subject","title":"Subject","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Event.Subject"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"StartDate","title":"StartDate","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"StartDate"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Event.StartTimeOfDay","title":"StartTimeOfDay","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Event.StartTimeOfDay"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Event.EndTimeOfDay","title":"EndTimeOfDay","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Event.EndTimeOfDay"}},{"attribute":{"classtype":"WebApiDefinitionAttributeDataMember","columnid":"Event.Description","title":"Description","subtotals":"","tooltip":"","width":-1,"display":"shown","editable":false,"attribute":"Event.Description"}}]'
        ContextMenu: 'listContextMenu967'
        Taborder: 2
      ]
_Main/UI/MacroPlannerWebApp/Component_LibCal_dlgMultipleEvent/Component_PanelHeader#144.def
@@ -190,6 +190,7 @@
          Properties:
          [
            DataType: 'structured[LibCal_EventType]'
            FixedFilter: 'object.IsLeaf()'
            Source: 'dhEventTypes'
            Taborder: 0
            Transformation: 'Elements'
@@ -199,8 +200,8 @@
      Properties:
      [
        DisplayField: 'Name'
        Label: 'Event type'
        NumberOfColumns: 15
        ShowLabel: false
        Taborder: 3
      ]
    }
_Main/UI/MacroPlannerWebApp/Views/Event_type_view.vw
¶Ô±ÈÐÂÎļþ
@@ -0,0 +1,68 @@
Quintiq file version 2.0
{
  viewcontents
  {
    forms
    {
      form_FormEventType
      {
        title: 'QMacroPlanner::FormEventType'
        shown: true
        componentID: 'QMacroPlanner::FormEventType'
        layout
        {
          mode: 'open'
          rowPosition: 1
          rowSpan: 15
          columnPosition: 1
          columnSpan: 12
        }
        components
        {
          FormEventType_ListEventType
          {
          }
          FormEventType_DataSetLevelEventType
          {
            groupDepth: -1
            column_Name
            {
              columnId: 'Name'
              dataPath: 'Name'
              dataType: 'string'
              index: 0
              subtotals: ''
              width: 150
            }
          }
          FormEventType_DataSetLevelChildEventType
          {
            groupDepth: -1
            column_Name
            {
              columnId: 'Name'
              dataPath: 'Name'
              dataType: 'string'
              index: 0
              subtotals: ''
              width: 150
            }
          }
        }
      }
    }
    userconfigurableinformation
    {
    }
    page: ''
    group: ''
    index: 14
    image: 'SHARE'
    description: ''
  }
  formatversion: 2
  id: 'Event_type_view'
  name: 'Event type view'
  isglobal: false
  isroot: true
}