Beispiel #1
0
        public static string[] RunserviceOnHandAsync()
        {
            //string itemid;
            string[] array = new string[40];

            InventOnHandDimService.QueryCriteria     query   = new InventOnHandDimService.QueryCriteria();
            InventOnHandDimService.CriteriaElement[] element = { new InventOnHandDimService.CriteriaElement() };

            InventOnHandDimService.EntityKey[] entityKey = { new InventOnHandDimService.EntityKey() };

            element[0].DataSourceName = "InventSum";
            element[0].FieldName      = "ItemId";
            element[0].Operator       = InventOnHandDimService.Operator.Equal;
            element[0].Value1         = "001009";

            query.CriteriaElement = element;


            entityKey = Find(query).Result.EntityKeyList;

            if (entityKey != null)
            {
                //itemid = entityKey.First().KeyData[1].Value;
                for (int i = 0; i <= entityKey.Length - 1; i++)
                {
                    array[i] = entityKey[i].KeyData[1].Value;
                }
                return(array);
            }
            else
            {
                //itemid = "чота не нашлось";
                return(null);
            }

            //            return itemid;
        }
Beispiel #2
0
        public static async Task <InventOnhandDimServiceFindKeysResponse> Find(InventOnHandDimService.QueryCriteria queryCriteria)
        {
            InventOnhandDimServiceClient client = new InventOnhandDimServiceClient();

            return(await client.findKeysAsync(queryCriteria));
        }