rislai
2024-08-16 bcd7eb876bff759f6aef96f1014b0bca7a3322ff
_Main/BL/Type_FinancialSalesReport/Method_GetRow.qbl
@@ -2,18 +2,19 @@
#parent: #root
Method GetRow (
  String salessegment,
  String product
  Product_MP product
) as FinancialSalesRow
{
  TextBody:
  [*
    // 甄兰鸽 Jun-28-2024 (created)
    row := selectobject( this, FinancialSalesRow, row, row.Name() = product and row.Unit() = salessegment );
    row := selectobject( this, FinancialSalesRow, row, row.Name() = product.ID() and row.Unit() = salessegment );
    
    if( isnull( row ) ){
      row := this.FinancialSalesRow( relnew, Name := product, Unit := salessegment );
      row := this.FinancialSalesRow( relnew, Name := product.ID(), Unit := salessegment );
      row.Product_MP( relset, product );
      //初始化单元格
      row.InitializeCell( this );
      row.InitializeCell( this, product );
    }
    
    return row;