コード例 #1
0
ファイル: LoginProxy.cs プロジェクト: hadasat/Web-Store-
        public string GetStore(int storeId)
        {
            Store storeAnse = StoreService.GetStore(storeId);

            if (storeAnse == null)
            {
                throw new Exception("store not found");
            }
            else
            {
                return(JsonHandler.SerializeObject(storeAnse));
            }
        }
コード例 #2
0
ファイル: LoginProxy.cs プロジェクト: hadasat/Web-Store-
        public List <Product> getAllProductsForStore(int storeId)
        {
            Store storeAns = StoreService.GetStore(storeId);

            if (storeAns == null)
            {
                return(new List <Product>());
            }
            else
            {
                return(storeAns.getAllProducst());
            }
        }
コード例 #3
0
        public string GetStore(int storeId)
        {
            Store ret;

            try
            {
                ret = StoreService.GetStore(storeId);
                return(objDynamicJson(ret));
            }
            catch (Exception e)
            {
                return(generateMessageFormatJason(e.Message));
            }
        }