Exemple #1
0
        public IEnumerable <Sastn> GetSastnList(GetSastnListRequestApi getGetSastnListRequestApi)
        {
            var where = new StringBuilder();
            // First query - based on sastn.codeval.  It should be numeric search criteria for this first query
            // since sastn.codeval is an interger (but no Progress error occurs if alpha-numeric data is sent).
            where.Append($"sastn.cono = {this.sastnRepository.Cono}");

            if (!string.IsNullOrEmpty(getGetSastnListRequestApi.codeiden))
            {
                where.AppendFormatWithEscape(" AND sastn.codeiden = '{0}'", getGetSastnListRequestApi.codeiden);
            }

            if (!string.IsNullOrEmpty(getGetSastnListRequestApi.codeval))
            {
                where.AppendFormatWithEscape(" AND sastn.codeval >= '{0}'", getGetSastnListRequestApi.codeval);
            }

            return(this.sastnRepository.GetList(where.ToString(), getGetSastnListRequestApi.batchsize, getGetSastnListRequestApi.fldlist));
        }
Exemple #2
0
 public IEnumerable <Sastn> GetSastnList(GetSastnListRequestApi GetSastnListRequestApi)
 {
     return(this.sastnService.GetSastnList(GetSastnListRequestApi));
 }