_Main/BL/Relations/Relation_ShippingActualCell_ShippingActualColumn_ShippingActualColumn_Shippi.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,23 @@ Quintiq file version 2.0 #parent: #root Relation ShippingActualCell_ShippingActualColumn_ShippingActualColumn_ShippingActualCell { #keys: '1[415136.0.904040097]' DefaultRelationStrategy { } RelationSide.LeftSide ShippingActualColumn { #keys: '3[415136.0.904040099][415136.0.904040098][415136.0.904040100]' Cardinality: '0to1' ObjectDefinition: ShippingActualCell OwningSide: 'Reference' } RelationSide.RightSide ShippingActualCell { #keys: '3[415136.0.904040102][415136.0.904040101][415136.0.904040103]' Cardinality: '1toN' ObjectDefinition: ShippingActualColumn OwningSide: 'Reference' } } _Main/BL/Relations/Relation_ShippingActualCell_ShippingActualRow_ShippingActualRow_ShippingActu.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,23 @@ Quintiq file version 2.0 #parent: #root Relation ShippingActualCell_ShippingActualRow_ShippingActualRow_ShippingActualCell { #keys: '1[415136.0.904040084]' DefaultRelationStrategy { } RelationSide.LeftSide ShippingActualRow { #keys: '3[415136.0.904040086][415136.0.904040085][415136.0.904040087]' Cardinality: '0to1' ObjectDefinition: ShippingActualCell OwningSide: 'Reference' } RelationSide.RightSide ShippingActualCell { #keys: '3[415136.0.904040089][415136.0.904040088][415136.0.904040090]' Cardinality: '1toN' ObjectDefinition: ShippingActualRow OwningSide: 'Owned' } } _Main/BL/Relations/Relation_ShippingActualColumn_InterfaceDataset_InterfaceDataset_ShippingActu.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,23 @@ Quintiq file version 2.0 #parent: #root Relation ShippingActualColumn_InterfaceDataset_InterfaceDataset_ShippingActualColumn { #keys: '1[415136.0.904040009]' DefaultRelationStrategy { } RelationSide.LeftSide InterfaceDataset { #keys: '3[415136.0.904040011][415136.0.904040010][415136.0.904040012]' Cardinality: '0to1' ObjectDefinition: ShippingActualColumn OwningSide: 'Reference' } RelationSide.RightSide ShippingActualColumn { #keys: '3[415136.0.904040014][415136.0.904040013][415136.0.904040015]' Cardinality: '1toN' ObjectDefinition: InterfaceDataset OwningSide: 'Owned' } } _Main/BL/Relations/Relation_ShippingActualData_InterfaceDataset_InterfaceDataset_ShippingActual.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,23 @@ Quintiq file version 2.0 #parent: #root Relation ShippingActualData_InterfaceDataset_InterfaceDataset_ShippingActualData { #keys: '1[415136.0.904000041]' DefaultRelationStrategy { } RelationSide.LeftSide InterfaceDataset { #keys: '3[415136.0.904000043][415136.0.904000042][415136.0.904000044]' Cardinality: '0to1' ObjectDefinition: ShippingActualData OwningSide: 'Reference' } RelationSide.RightSide ShippingActualData { #keys: '3[415136.0.904000046][415136.0.904000045][415136.0.904000047]' Cardinality: '1toN' ObjectDefinition: InterfaceDataset OwningSide: 'Owned' } } _Main/BL/Relations/Relation_ShippingActualRow_InterfaceDataset_InterfaceDataset_ShippingActualR.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,23 @@ Quintiq file version 2.0 #parent: #root Relation ShippingActualRow_InterfaceDataset_InterfaceDataset_ShippingActualRow { #keys: '1[415136.0.904040037]' DefaultRelationStrategy { } RelationSide.LeftSide InterfaceDataset { #keys: '3[415136.0.904040039][415136.0.904040038][415136.0.904040040]' Cardinality: '0to1' ObjectDefinition: ShippingActualRow OwningSide: 'Reference' } RelationSide.RightSide ShippingActualRow { #keys: '3[415136.0.904040042][415136.0.904040041][415136.0.904040043]' Cardinality: '1toN' ObjectDefinition: InterfaceDataset OwningSide: 'Owned' } } _Main/BL/Type_InterfaceDataset/StaticMethod_GetResponseJsonData.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,16 @@ Quintiq file version 2.0 #parent: #root StaticMethod GetResponseJsonData ( String result ) as owning JSON { TextBody: [* // çå °é¸½ Jul-17-2024 (created) resultJson := JSON::Parse( result ); //returnsuccess := resultJson.Get( "success"); //msg := resultJson.Get( "msg"); data := resultJson.Get( "data"); return &data; *] } _Main/BL/Type_ShippingActualCell/Attribute_Quantity.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,7 @@ Quintiq file version 2.0 #parent: #root Attribute Quantity { #keys: '3[415136.0.904040075][415136.0.904040074][415136.0.904040076]' ValueType: Real } _Main/BL/Type_ShippingActualCell/_ROOT_Type_ShippingActualCell.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,10 @@ Quintiq file version 2.0 #root #parent: #DomainModel Type ShippingActualCell { #keys: '5[415136.0.904040072][415136.0.904040070][0.0.0][415136.0.904040071][415136.0.904040073]' BaseType: Object Description: 'å®é åè¿æ°æ®åå æ ¼' StructuredName: 'ShippingActualCells' } _Main/BL/Type_ShippingActualColumn/Attribute_Index.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,7 @@ Quintiq file version 2.0 #parent: #root Attribute Index { #keys: '3[415136.0.904040147][415136.0.904040146][415136.0.904040148]' ValueType: Number } _Main/BL/Type_ShippingActualColumn/Attribute_StartDate.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,7 @@ Quintiq file version 2.0 #parent: #root Attribute StartDate { #keys: '3[415136.0.904040023][415136.0.904040022][415136.0.904040024]' ValueType: Date } _Main/BL/Type_ShippingActualColumn/_ROOT_Type_ShippingActualColumn.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,10 @@ Quintiq file version 2.0 #root #parent: #DomainModel Type ShippingActualColumn { #keys: '5[415136.0.904040006][415136.0.904040004][0.0.0][415136.0.904040005][415136.0.904040007]' BaseType: Object Description: 'å®é åè¿æ°æ®å' StructuredName: 'ShippingActualColumns' } _Main/BL/Type_ShippingActualData/Attribute_CreateTime.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,8 @@ Quintiq file version 2.0 #parent: #root Attribute CreateTime { #keys: '3[415136.0.904000065][415136.0.904000064][415136.0.904000066]' Description: 'æ¶é´' ValueType: DateTime } _Main/BL/Type_ShippingActualData/Attribute_DDay.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,8 @@ Quintiq file version 2.0 #parent: #root Attribute DDay { #keys: '3[415136.0.904000085][415136.0.904000084][415136.0.904000086]' Description: 'æ¥æ' ValueType: Date } _Main/BL/Type_ShippingActualData/Attribute_Fac.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,8 @@ Quintiq file version 2.0 #parent: #root Attribute Fac { #keys: '3[415136.0.904000115][415136.0.904000114][415136.0.904000116]' Description: 'å·¥å代ç ' ValueType: String } _Main/BL/Type_ShippingActualData/Attribute_FourCode.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,8 @@ Quintiq file version 2.0 #parent: #root Attribute FourCode { #keys: '3[415136.0.904000095][415136.0.904000094][415136.0.904000096]' Description: 'åä½ç ' ValueType: String } _Main/BL/Type_ShippingActualData/Attribute_ID.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,8 @@ Quintiq file version 2.0 #parent: #root Attribute ID { #keys: '3[415136.0.904000125][415136.0.904000124][415136.0.904000126]' Description: 'é¶ä»¶åç§°' ValueType: Number } _Main/BL/Type_ShippingActualData/Attribute_Quantity.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,7 @@ Quintiq file version 2.0 #parent: #root Attribute Quantity { #keys: '3[415136.0.904000105][415136.0.904000104][415136.0.904000106]' ValueType: Real } _Main/BL/Type_ShippingActualData/StaticMethod_Export.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,64 @@ Quintiq file version 2.0 #parent: #root StaticMethod Export ( InterfaceDataset owner ) as BinaryValue { TextBody: [* // çå °é¸½ Jul-18-2024 (created) name := ShippingActualData::GetDefalutName(); xmlDOMI := XMLDOMImplementation::Create(); xmlDOM := xmlDOMI.CreateDocumentFromString( '<?xml version="1.0" encoding="UTF-16"?><table><name>' + name + '</name></table>' ); tableElement := xmlDOM.GetElementByTagName( "table", 0 ); //Product productcolumnelement := xmlDOM.CreateElement( "column" ); productnameelement := xmlDOM.CreateElement( "name" ); producttypeelement := xmlDOM.CreateElement( "type" ); productnameelement.TextContent( 'Product' ); producttypeelement.TextContent( "String" ); productcolumnelement.AppendChild( productnameelement ); productcolumnelement.AppendChild( producttypeelement ); tableElement.AppendChild( productcolumnelement ); traverse ( owner, ShippingActualColumn, column ) { columnelement := xmlDOM.CreateElement( "column" ); nameelement := xmlDOM.CreateElement( "name" ); typeelement := xmlDOM.CreateElement( "type" ); nameelement.TextContent( column.StartDate().Format( "M2/D2/Y" ) ); typeelement.TextContent( "String" ); columnelement.AppendChild( nameelement ); columnelement.AppendChild( typeelement ); cells := selectsortedset( column, ShippingActualCell, cell, cell.ShippingActualRow().RowNr() ); traverse ( cells, Elements, c ) { if( column.Index() = 0 ){ row := c.ShippingActualRow(); //Product productcellElement := xmlDOM.CreateElement( "cell" ); productcellElement.SetAttribute( "value", row.Name() ); productcolumnelement.AppendChild( productcellElement ); } cellElement := xmlDOM.CreateElement( "cell" ); cellElement.SetAttribute( "value", [String]c.Quantity() ); columnelement.AppendChild( cellElement ); } tableElement.AppendChild( columnelement ); } xmlString := xmlDOMI.CreateSerializer().WriteToString( xmlDOM ) //info( xmlString ); tableGroupHandle := TableGroupHandle::Create( FinancialProductionReport::GetDefaultName() ); tableHandle := TableHandle::ImportXML( BinaryValue::Construct( xmlString ) ); tableGroupHandle.Add( tableHandle ); binaryData := XLS::SaveTableGroupToBinaryData( tableGroupHandle, true ); return binaryData.AsBinaryValue(); *] } _Main/BL/Type_ShippingActualData/StaticMethod_GenerateData.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,29 @@ Quintiq file version 2.0 #parent: #root StaticMethod GenerateData ( InterfaceDataset owner, StringToDateTime cnv1, StringToDate cnv, JSON item ) as ShippingActualData { TextBody: [* // çå °é¸½ Jul-17-2024 (created) createtime := guard( item.Get( "create_time").GetString(),""); dday := guard( item.Get( "dday").GetString(),""); fourcode := guard( item.Get( "four_code").GetString(),""); quantity := guard( item.Get( "qty").GetReal(), 0); fac := guard( item.Get( "fac").GetString(),""); id := guard( item.Get( "id").GetNumber(),0); sadata := owner.ShippingActualData( relnew, CreateTime := cnv1.Convert( createtime ) , Fac := fac , FourCode := fourcode , Quantity := quantity , DDay := cnv.Convert( dday ) , ID := id); return sadata; *] } _Main/BL/Type_ShippingActualData/StaticMethod_GetDefalutName.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,10 @@ Quintiq file version 2.0 #parent: #root StaticMethod GetDefalutName () as String { TextBody: [* // çå °é¸½ Jul-18-2024 (created) return "Shipping actual"; *] } _Main/BL/Type_ShippingActualData/StaticMethod_Synchronize.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,53 @@ Quintiq file version 2.0 #parent: #root StaticMethod Synchronize ( InterfaceDataset owner ) { TextBody: [* // çå °é¸½ Jul-17-2024 (created) column := owner.ShippingActualColumn( relnew, StartDate := Date::ActualDate(), Index := owner.ShippingActualColumn( relsize ) ); url := "http://localhost:8080/api/shippingActual" + "?date=" + column.StartDate().Format( "Y-M2-D2" ); i := HTTPInterface::Create( url, 80 ); i.PostMethod( true ); i.Call(); result := i.Result(); cnv1 := StringToDateTime::StandardConverter(); cnv1.SetCustomConversion(); cnv1.CustomFormatString( 'yyyy-MM-dd HH:mm:ss' ); cnv2 := StringToDate::StandardConverter(); cnv2.SetCustomConversion(); cnv2.CustomFormatString( 'yyyy-MM-dd' ); data := InterfaceDataset::GetResponseJsonData( result ); sadatalist := construct( ShippingActualDatas ); for( seq := 0;seq < data.Size();seq++){ item := data.Get(seq); sadata := ShippingActualData::GenerateData( owner, cnv1, cnv2, item ); sadatalist.Add( sadata ); } beforerowsize := owner.ShippingActualRow( relsize ); traverse( sadatalist, Elements, e ){ row := selectobject( owner, ShippingActualRow, row, row.Name() = e.FourCode() ); if( isnull( row ) ){ owner.ShippingActualRow( relnew, Name := e.FourCode() ); } cell := row.ShippingActualCell( relnew, Quantity := e.Quantity() ); column.ShippingActualCell( relinsert, cell ); } if( beforerowsize <> owner.ShippingActualRow( relsize ) ){ rows := selectsortedset( owner, ShippingActualRow, row, row.Name() ); nr := 0; traverse( rows, Elements, e ){ e.RowNr( nr ); nr := nr + 1; } } *] } _Main/BL/Type_ShippingActualData/_ROOT_Type_ShippingActualData.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,10 @@ Quintiq file version 2.0 #root #parent: #DomainModel Type ShippingActualData { #keys: '5[415136.0.904000038][415136.0.904000036][0.0.0][415136.0.904000037][415136.0.904000039]' BaseType: Object Description: 'åè¿å®é æ°æ®' StructuredName: 'ShippingActualDatas' } _Main/BL/Type_ShippingActualRow/Attribute_Name.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,7 @@ Quintiq file version 2.0 #parent: #root Attribute Name { #keys: '3[415136.0.904040051][415136.0.904040050][415136.0.904040052]' ValueType: String } _Main/BL/Type_ShippingActualRow/Attribute_RowNr.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,7 @@ Quintiq file version 2.0 #parent: #root Attribute RowNr { #keys: '3[415136.0.904040061][415136.0.904040060][415136.0.904040062]' ValueType: Number } _Main/BL/Type_ShippingActualRow/_ROOT_Type_ShippingActualRow.qbl
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,10 @@ Quintiq file version 2.0 #root #parent: #DomainModel Type ShippingActualRow { #keys: '5[415136.0.904040034][415136.0.904040032][0.0.0][415136.0.904040033][415136.0.904040035]' BaseType: Object Description: 'å®é è¹è¿æ°æ®è¡' StructuredName: 'ShippingActualRows' } _Main/UI/MacroPlannerWebApp/Component_ApplicationMacroPlanner/Component_abgSecondDevelopmentPlan.def
@@ -48,6 +48,17 @@ Taborder: 2 ] } Component bShippingActualData { #keys: '[415136.0.905520117]' BaseType: 'WebButton' Properties: [ Image: 'TABLE_CONNECTION' Label: 'Shipping data' Taborder: 4 ] } ] Properties: [ _Main/UI/MacroPlannerWebApp/Component_ApplicationMacroPlanner/Response_MacroPlanner_abgSecondDevelopmentPlan_bShippingActualData_OnClick.def
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,16 @@ Quintiq file version 2.0 #parent: abgSecondDevelopmentPlan/bShippingActualData Response OnClick () id:Response_MacroPlanner_abgSecondDevelopmentPlan_bShippingActualData_OnClick { #keys: '[415136.0.905520217]' CanBindMultiple: false DefinitionID: 'Responsedef_WebButton_OnClick' QuillAction { Body: [* ApplicationScope.ViewManager().ResetUserViewById( "Shipping_actual_data_view", true); *] GroupServerCalls: false } } _Main/UI/MacroPlannerWebApp/Component_FormShippingActualData/Component_MatrixEditorTable.def
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,97 @@ Quintiq file version 2.0 Component MatrixEditorTable { #keys: '[415136.0.904311855]' BaseType: 'WebMatrixEditor' Children: [ Component MatrixEditorCellTable { #keys: '[415136.0.904311856]' BaseType: 'WebMatrixEditorCell' Children: [ Component DataExtractorCell { #keys: '[415136.0.904311857]' BaseType: 'WebDataExtractor' Properties: [ DataType: 'InterfaceDataset' Source: 'InterfaceDataset' Taborder: 0 Transformation: 'ShippingActualRow.ShippingActualCell' ] } ] Properties: [ Attributes: 'Quantity' Column: 'ShippingActualColumn' Row: 'ShippingActualRow' Taborder: 0 ] } Component MatrixEditorRowsTable { #keys: '[415136.0.904311860]' BaseType: 'WebMatrixEditorHeaderLevel' Children: [ Component DataExtractorRow { #keys: '[415136.0.904311861]' BaseType: 'WebDataExtractor' Properties: [ DataType: 'InterfaceDataset' Source: 'InterfaceDataset' Taborder: 0 Transformation: 'ShippingActualRow' ] } ] Properties: [ Legend: 'Name' SortCriteria: 'RowNr' Taborder: 1 ] } Component MatrixEditorColumnsTable { #keys: '[415136.0.904311864]' BaseType: 'WebMatrixEditorHeaderLevel' Children: [ Component DataExtractorColumn { #keys: '[415136.0.904311865]' BaseType: 'WebDataExtractor' Properties: [ DataType: 'InterfaceDataset' Source: 'InterfaceDataset' Taborder: 0 Transformation: 'ShippingActualColumn' ] } ] Properties: [ Legend: 'StartDate' SortCriteria: 'StartDate' Taborder: 2 ] } #child: matrixEditorActionBarPageTable #child: matrixeditorContextMenuTable ] Properties: [ Columns: 'MatrixEditorColumnsTable' ContextMenu: 'matrixeditorContextMenuTable' Rows: 'MatrixEditorRowsTable' Taborder: 0 ] } _Main/UI/MacroPlannerWebApp/Component_FormShippingActualData/Component_PanelButton.def
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,25 @@ Quintiq file version 2.0 Component PanelButton { #keys: '[415136.0.904311760]' BaseType: 'WebPanel' Children: [ Component ButtonButton { #keys: '[415136.0.904311805]' BaseType: 'WebButton' Properties: [ Image: 'EXPORT1' Taborder: 0 ] } ] Properties: [ FixedSize: true Orientation: 'horizontal' Taborder: 0 ] } _Main/UI/MacroPlannerWebApp/Component_FormShippingActualData/Component_PanelTable.def
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,14 @@ Quintiq file version 2.0 Component PanelTable { #keys: '[415136.0.904311784]' BaseType: 'WebPanel' Children: [ #child: MatrixEditorTable ] Properties: [ Taborder: 1 ] } _Main/UI/MacroPlannerWebApp/Component_FormShippingActualData/Component_matrixEditorActionBarPageTable.def
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,10 @@ Quintiq file version 2.0 Component matrixEditorActionBarPageTable { #keys: '[415136.0.904311868]' BaseType: 'matrixEditorActionBarPage' Properties: [ Taborder: 3 ] } _Main/UI/MacroPlannerWebApp/Component_FormShippingActualData/Component_matrixeditorContextMenuTable.def
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,10 @@ Quintiq file version 2.0 Component matrixeditorContextMenuTable { #keys: '[415136.0.904311871]' BaseType: 'matrixeditorContextMenu' Properties: [ Taborder: 4 ] } _Main/UI/MacroPlannerWebApp/Component_FormShippingActualData/Response_PanelButton_ButtonButton_OnClick.def
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,24 @@ Quintiq file version 2.0 #parent: PanelButton/ButtonButton Response OnClick () id:Response_PanelButton_ButtonButton_OnClick { #keys: '[415136.0.904312139]' CanBindMultiple: false DefinitionID: 'Responsedef_WebButton_OnClick' Precondition: [* return not isnull( InterfaceDataset ); *] QuillAction { Body: [* //binaryValue := ShippingActualData::Export( InterfaceDataset ); // //Application.Download( ShippingActualData::GetDefalutName() + '.xlsx', binaryValue.AsBinaryData() ); ShippingActualData::Synchronize( InterfaceDataset ); *] GroupServerCalls: false } } _Main/UI/MacroPlannerWebApp/Component_FormShippingActualData/_ROOT_Component_FormShippingActualData.def
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,18 @@ Quintiq file version 2.0 #root #parent: MacroPlannerWebApp OrphanComponent FormShippingActualData { #keys: '[415136.0.904311721]' BaseType: 'WebForm' Children: [ #child: PanelButton #child: PanelTable ] Properties: [ Image: 'TABLE_CONNECTION' Title: 'Shipping data' ] } _Main/UI/MacroPlannerWebApp/Views/Shipping_actual_data_view.vw
¶Ô±ÈÐÂÎļþ @@ -0,0 +1,92 @@ Quintiq file version 2.0 { viewcontents { forms { form_FormShippingActualData { title: 'QMacroPlanner::FormShippingActualData' shown: true componentID: 'QMacroPlanner::FormShippingActualData' layout { mode: 'open' rowPosition: 1 rowSpan: 15 columnPosition: 1 columnSpan: 12 } components { FormShippingActualData_PanelButton { sizeRatio: 1 } FormShippingActualData_PanelTable { sizeRatio: 1 } FormShippingActualData_MatrixEditorTable { gridColor: '#c4c4c4' totalHeaderWidth: 200 attributeHeaderWidthRatio: 0.6 nameHeaderWidthRatio: 0.4 columnWidth: 100 horizontalGrid: true verticalGrid: true backendState { componentId: 'QMacroPlanner::FormShippingActualData.MatrixEditorTable' state { cells { attributes { attribute_Quantity { type: 'MatrixEditorWebApiCellDataModelInterest' index: 0 rowsubtotal: '' columnsubtotal: '' attribute: 'Quantity' } } } columns { sorting { criteria: "datamember:'StartDate'" } } rows { sorting { criteria: "datamember:'RowNr'" } } } } } } } } userconfigurableinformation { } page: '' group: '' index: 21 image: 'TABLE_CONNECTION' description: '' } formatversion: 2 id: 'Shipping_actual_data_view' name: 'Shipping actual data view' isglobal: false isroot: true }