Пример #1
0
    public static void logPurchase(XPurchase xPurchae)
    {
        Debug.Log("logPurchase");
        string productsString    = getProductList(xPurchae.getProductList());
        string xPropertiesString = getXProperties(xPurchae.getXProperties());

        CallLogRevenue(xPurchae.getOrderNo(), xPurchae.getRevenueType(), xPurchae.getCurrency(), productsString, xPropertiesString);
    }
Пример #2
0
 public static void logPurchase(XPurchase xPurchase)
 {
     Debug.Log("set log purchase");
     if (unityHelperInstance != null)
     {
         string xPurchaseString = xPurchaseObjectToDictionary(xPurchase);
         unityHelperInstance.Call("logPurchase", xPurchaseString);
     }
 }
Пример #3
0
    public static string xPurchaseObjectToDictionary(XPurchase xPurchase)
    {
        Dictionary <string, object> dictionary = new Dictionary <string, object>();

        dictionary.Add("ordNo", xPurchase.getOrderNo());
        dictionary.Add("eventType", xPurchase.getRevenueType());
        dictionary.Add("curcy", xPurchase.getCurrency());
        dictionary.Add("product", getProductList(xPurchase.getProductList()));
        dictionary.Add("properties", getXProperties(xPurchase.getXProperties()));
        string json = Serializer.Serialize(dictionary);

        Debug.Log("xPurchase json string : " + json);
        return(json);
    }
Пример #4
0
 public static void logPurchase(XPurchase purchaseData)
 {
 }