private string GetProduct(int num_iid)
        {
            ProductApiDao      productApiDao = new ProductApiDao();
            product_item_model product       = productApiDao.GetProduct(num_iid);

            if (product == null)
            {
                return(OpenApiErrorMessage.ShowErrorMsg((Enum)(object)OpenApiErrorCode.Product_Not_Exists, "num_iid"));
            }
            product.props_name = productApiDao.GetProps(num_iid);
            product.skus       = productApiDao.GetSkus(num_iid);
            string format = "{{\"product_get_response\":{{\"item\":{0}}}}}";

            return(string.Format(format, JsonConvert.SerializeObject(product)));
        }
        private string lastUpdateProductQuantity(ProductQuantityParam param)
        {
            ProductApiDao      productApiDao = new ProductApiDao();
            product_item_model product       = productApiDao.GetProduct(param.num_iid);

            if (product == null)
            {
                return(OpenApiErrorMessage.ShowErrorMsg((Enum)(object)OpenApiErrorCode.Product_Not_Exists, "num_iid"));
            }
            if (productApiDao.UpdateProductQuantity(param.num_iid, param.sku_id, param.quantity, param.type) <= 0)
            {
                return(OpenApiErrorMessage.ShowErrorMsg((Enum)(object)OpenApiErrorCode.Product_UpdateeQuantity_Faild, "update_quantity"));
            }
            product.props_name = productApiDao.GetProps(param.num_iid);
            product.skus       = productApiDao.GetSkus(param.num_iid);
            string format = "{{\"product_get_response\":{{\"item\":{0}}}}}";

            return(string.Format(format, JsonConvert.SerializeObject(product)));
        }
        public string lastUpdateProductApproveStatus(int num_iid, string approve_status)
        {
            ProductApiDao      productApiDao = new ProductApiDao();
            product_item_model product       = productApiDao.GetProduct(num_iid);

            if (product == null)
            {
                return(OpenApiErrorMessage.ShowErrorMsg((Enum)(object)OpenApiErrorCode.Product_Not_Exists, "num_iid"));
            }
            if (productApiDao.UpdateProductApproveStatus(num_iid, approve_status) <= 0)
            {
                return(OpenApiErrorMessage.ShowErrorMsg((Enum)(object)OpenApiErrorCode.Product_ApproveStatus_Faild, "update_approve_status"));
            }
            product.approve_status = approve_status;
            product.props_name     = productApiDao.GetProps(num_iid);
            product.skus           = productApiDao.GetSkus(num_iid);
            string format = "{{\"product_get_response\":{{\"item\":{0}}}}}";

            return(string.Format(format, JsonConvert.SerializeObject(product)));
        }