public List <int> GetLayerByCode(List <string> codeList)
        {
            List <int> layerList = new List <int>();

            foreach (string str in codeList)
            {
                int item = str.Length / 3;
                layerList.Add(item);
            }
            return(BudTaskTypeServices.GetStandardLayer(layerList));
        }
Exemple #2
0
        public List <int> GetLayerByCode(List <string> codeList)
        {
            List <int> layerList = new List <int>();

            foreach (string str in codeList)
            {
                int item = 1;
                if (str.Contains("."))
                {
                    item = BudTaskTypeServices.GetSeparatorCount(str, '.');
                }
                layerList.Add(item);
            }
            return(BudTaskTypeServices.GetStandardLayer(layerList));
        }
Exemple #3
0
        public void ParseTaskTable(IDictionary <string, int> colRelation)
        {
            foreach (KeyValuePair <string, int> pair in colRelation)
            {
                switch (pair.Key)
                {
                case "TaskCode":
                    this.codeIndex = pair.Value;
                    break;

                case "TaskName":
                    this.nameIndex = pair.Value;
                    break;

                case "TaskType":
                    this.taskTypeIndex = pair.Value;
                    break;

                case "Unit":
                    this.unitIndex = pair.Value;
                    break;

                case "Quantity":
                    this.quantityIndex = pair.Value;
                    break;

                case "UnitPrice":
                    this.unitPriceIndex = pair.Value;
                    break;

                case "StartDate":
                    this.startDateIndex = pair.Value;
                    break;

                case "EndDate":
                    this.endDateIndex = pair.Value;
                    break;

                case "Note":
                    this.noteIndex = pair.Value;
                    break;

                case "InputUser":
                    this.inputUserIndex = pair.Value;
                    break;

                case "InputDate":
                    this.inputDateIndex = pair.Value;
                    break;

                case "Total":
                    this.totalIndex = pair.Value;
                    break;

                case "Rank":
                    this.rankIndex = pair.Value;
                    break;

                case "ConstructionPeriod":
                    this.constructionPeriodIndex = pair.Value;
                    break;

                case "FeatureDescription":
                    this.featureDescriptionIndex = pair.Value;
                    break;

                case "MainMaterial":
                    this.mainMaterialIndex = pair.Value;
                    break;

                case "SubMaterial":
                    this.subMaterialIndex = pair.Value;
                    break;

                case "Labor":
                    this.laborIndex = pair.Value;
                    break;
                }
            }
            List <string> codeList = this.GetCodeList();

            this.budTaskTypeServices = new BudTaskTypeServices(codeList);
        }