public override void Begin(List <int> session)
        {
            if (session != null)
            {
                if (session.Contains(Current.ID))
                {
                    return;
                }
                else
                {
                    session.Add(Current.ID);
                }
            }

            //工料机计算(没经过子目取费)

            /*_Entity_SubInfo info = null;
             * DataRow row = null;
             * _Methods met = null;
             *
             *
             * _Subheadings_Statistics stat = new _Subheadings_Statistics(this.Current, this.Unit);
             * stat.DataSource = this.GetDataSource;
             * stat.Begin();
             * //计算子目经过子目取费
             * _ResultSubheadings_Statictics sta = new _ResultSubheadings_Statictics(this.Current, this.Unit);
             * sta.DataSource = this.GetDataSource;
             * sta.Begin();
             *
             * //计算子目所属清单
             * info = new _Entity_SubInfo();
             * row = this.Unit.StructSource.ModelSubSegments.GetRowByOther(this.Current.PID.ToString());
             * _ObjectSource.GetObject(info, row);
             * met = new _Methods_Fixed(this.Unit, info);
             * met.Begin();*/
            _Entity_SubInfo info = null;
            DataRow         row  = null;
            _Methods        met  = null;

            _Subheadings_Statistics stat = new _Subheadings_Statistics(this.Current, this.Unit);

            stat.Begin();
            //计算子目经过子目取费
            _ResultSubheadings_Statictics sta = new _ResultSubheadings_Statictics(this.Current, this.Unit);

            sta.DataSource = this.GetDataSource;
            sta.Begin();

            //计算子目所属清单
            info = new _Entity_SubInfo();
            row  = this.Unit.StructSource.ModelMeasures.GetRowByOther(this.Current.PID.ToString());
            _ObjectSource.GetObject(info, row);
            met = new _Mothods_MFixed(this.CurrentBusiness, this.Unit, info);
            met.Begin(session);
        }
Exemple #2
0
 private void CalculateKCAQWMCSF()
 {
     DataRow[] rows1 = this.Unit.StructSource.ModelMeasures.Select(string.Format("XMBM='{0}'", "C10101"), "", DataViewRowState.CurrentRows);
     if (rows1.Length > 0)
     {
         _Entity_SubInfo CSAQ = new _Entity_SubInfo();
         _ObjectSource.GetObject(CSAQ, rows1[0]);
         _Mothods_MFixed fix = new _Mothods_MFixed(null, this.Unit, CSAQ);
         fix.Begin(null);
         _Method_Metaanalysis method = new _Method_Metaanalysis(this.Unit);
         method.Calculate();
     }
 }