zhuyiyi 10 meses atrás
pai
commit
e722f74323

+ 9 - 8
SiteCore/Handler/sync.order.cs

@@ -66,7 +66,7 @@ namespace SiteCore.Handler
             //CeErpTradeCell entity = CeErpTradeCell.GetByCtid("2484048723252587257");
             //int sid = commonHelper.autoDistributeToSupplier(entity);
             // string a  = apiHelper.API_GetPrintData("YT8951457355085");
-            //tmcHelper.Api_TmcTradeMsg("{\"content\":{\"businessType\":\"GUARANTEE\",\"buyerMemo\":\"\",\"consolidateType\":\"\",\"createTime\":1742461349000,\"deliveryType\":\"OFFLINE\",\"discountFee\":3.0,\"flag\":\"NONE\",\"latestDeliveryTime\":1743325347000,\"lines\":[{\"mark2\":[],\"num\":31,\"outerId\":\"JSBHUVZYT\",\"payment\":1547.0,\"picUrl\":\"https://img.alicdn.com/bao/uploaded/i4/2200806677467/O1CN01aEDI6s251wFlRwWHL_!!0-item_pic.jpg\",\"platServiceFee\":0.0,\"price\":50.0,\"refOlId\":\"4271229037819075415\",\"refSkuId\":\"0\",\"refSpuId\":\"620901028368\",\"refundStatus\":\"NO_REFUND\",\"sellPrice\":49.9032,\"singleFee\":49.9,\"spuOuterId\":\"JSBHUVZYT\",\"standards\":\"\",\"status\":\"NOT_SHIPPED\",\"title\":\"水晶标贴金属标签LOGO贴纸定制车热uv转印贴透明商标打印移丝印广告自粘刻字烫金定做公司标志防水不干胶印刷\",\"totalFee\":1547.0,\"totalPrice\":1550.0,\"totalSellPrice\":1547.0}],\"logisticsOrderNo\":\"\",\"mark2\":[],\"modifyTime\":1742464167000,\"openBuyerId\":\"AAELRHraABkUZRPgSx2KM2Bx\",\"openBuyerNick\":\"美**\",\"openSellerNick\":\"翊喜旗舰店\",\"orderSource\":\"SYNC\",\"orderTime\":1742461325000,\"payTime\":1742461347000,\"payment\":1547.0,\"platServiceFee\":0.0,\"posCode\":\"yixi\",\"posId\":598788,\"postFee\":0.0,\"props\":{\"payType\":\"ALI_PAY\",\"govSubsidyAmount\":0},\"receivedPayment\":0.0,\"receiverCity\":\"长沙市\",\"receiverCountry\":\"中国\",\"receiverDistrict\":\"岳麓区\",\"receiverId\":\"ae45da4cb4cce6519f6bc00bdc10208b$\",\"receiverState\":\"湖南省\",\"receiverTown\":\"天顶街道\",\"refOid\":\"4271229037819075415\",\"refType\":\"TMALL\",\"refundStatus\":\"NO_REFUND\",\"sellerMemo\":\"90x60mm-3000张-插旗-250克白卡纸对裱-覆哑膜模切-美美de二胖-小白-(粘牙签12cm)-老客户改稿\",\"serviceFee\":0.0,\"status\":\"NOT_SHIPPED\",\"totalFee\":1547.0,\"totalPrice\":1550.0,\"totalSellPrice\":1547.0,\"type\":\"SALE\"}}");
+            //tmcHelper.Api_TmcTradeMsg("{\"content\":{\"businessType\":\"GUARANTEE\",\"buyerMemo\":\"\",\"consolidateType\":\"\",\"createTime\":1743037314000,\"deliveryType\":\"OFFLINE\",\"discountFee\":0.0,\"flag\":\"NONE\",\"latestDeliveryTime\":1743210111000,\"lines\":[{\"mark2\":[],\"num\":2,\"outerId\":\"JSBHUVZYT\",\"payment\":100.0,\"picUrl\":\"https://img.alicdn.com/bao/uploaded/i2/2200806677467/O1CN01FNM4MW251wJNQ0RTV_!!0-item_pic.jpg\",\"platServiceFee\":0.0,\"price\":50.0,\"refOlId\":\"4279817918999398627\",\"refSkuId\":\"0\",\"refSpuId\":\"743796792540\",\"refundStatus\":\"NO_REFUND\",\"sellPrice\":50.0,\"singleFee\":50.0,\"spuOuterId\":\"JSBHUVZYT\",\"standards\":\"\",\"status\":\"NOT_SHIPPED\",\"title\":\"【活动价】镜子贴纸定制婚礼迎宾牌装饰静电贴镜面玻璃窗户字母转印贴画墙贴\",\"totalFee\":100.0,\"totalPrice\":100.0,\"totalSellPrice\":100.0}],\"logisticsOrderNo\":\"\",\"mark2\":[],\"modifyTime\":1743040267000,\"openBuyerId\":\"AAEXRHraABkUZRPgSx1Mbz6h\",\"openBuyerNick\":\"天**\",\"openSellerNick\":\"翊喜旗舰店\",\"orderSource\":\"SYNC\",\"orderTime\":1743037310000,\"payTime\":1743037311000,\"payment\":100.0,\"platServiceFee\":0.0,\"posCode\":\"yixi\",\"posId\":598788,\"postFee\":0.0,\"props\":{\"payType\":\"ALI_PAY\",\"govSubsidyAmount\":0},\"receivedPayment\":0.0,\"receiverCity\":\"齐齐哈尔市\",\"receiverCountry\":\"中国\",\"receiverDistrict\":\"建华区\",\"receiverId\":\"82f9bfecd2ef7df766b42edd73faa2f3$\",\"receiverState\":\"黑龙江省\",\"receiverTown\":\"文化街道\",\"refOid\":\"4279817918999398627\",\"refType\":\"TMALL\",\"refundStatus\":\"NO_REFUND\",\"sellerMemo\":\"500x640mm-1张-uv静电膜-模切-单面印刷-天意5516-昕昕-50,580x585mm-1张-uv静电膜-模切-单面印刷-天意5516-昕昕-50\",\"serviceFee\":0.0,\"status\":\"NOT_SHIPPED\",\"totalFee\":100.0,\"totalPrice\":100.0,\"totalSellPrice\":100.0,\"type\":\"SALE\"}}");
             //refundTmcHelper.Api_TmcRefundMsg("{\"content\":{\"afterStatus\":\"SUCCESS\",\"createTime\":1735287446000,\"desc\":\"\",\"interceptInvestor\":\"NONE\",\"interceptStatus\":\"NONE\",\"interceptType\":\"NONE\",\"lines\":[{\"num\":2,\"outerId\":\"\",\"price\":50.0,\"refAid\":\"313001208133750610\",\"refAlId\":\"313001208133750610\",\"refBoughtSkuId\":\"\",\"refOid\":\"4181722704291751006\",\"refOlId\":\"4181722704291751006\",\"refSkuId\":\"0\",\"refSpuId\":\"865893808768\",\"refundFee\":98.86,\"refundStatus\":\"SUCCESS\",\"title\":\"新年会抽奖券定制2025蛇年公司活动正副可撕代金券打印纪念票根奖品兑换尾牙晚宴邀请卡号码牌创意入场券设计\",\"totalFee\":98.86,\"type\":1}],\"logisticsCompany\":\"\",\"logisticsOrderNo\":\"\",\"mark2\":[],\"openBuyerNick\":\"0**\",\"openSellerNick\":\"万慕办公旗舰店\",\"posCode\":\"wanmu\",\"posId\":598798,\"reason\":\"订单信息拍错(规格/尺码/颜色等)\",\"receiverCity\":\"\",\"receiverCountry\":\"中国\",\"receiverDistrict\":\"\",\"receiverId\":\"\",\"receiverState\":\"\",\"receiverTown\":\"\",\"receiverZip\":\"\",\"refAid\":\"313001208133750610\",\"refOid\":\"4181722704291751006\",\"refPlatform\":\"TB\",\"refType\":\"TMALL\",\"refundCreateTime\":1735287358000,\"refundFee\":\"98.86\",\"refundPhase\":\"ON_SALE\",\"refundTime\":1735289443000,\"refundUpdateTime\":1735289443000,\"refundVersion\":1735287358100,\"senderAddress\":\"\",\"senderCity\":\"\",\"senderCountry\":\"中国\",\"senderDistrict\":\"\",\"senderMobile\":\"\",\"senderName\":\"\",\"senderPhone\":\"\",\"senderState\":\"\",\"senderTown\":\"\",\"senderZip\":\"\",\"status\":\"SUCCESS\",\"statusCode\":\"SUCCESS\",\"statusName\":\"退款成功\",\"totalFee\":\"98.86\",\"type\":\"REFUND\",\"updateTime\":1735289479000}}");
             List<string> lw = new List<string>();
             string tid = GetPostString("ctid");
@@ -6898,14 +6898,15 @@ namespace SiteCore.Handler
                             ishav = false;
                             newentity.ctid = "S_" + entity.ctid;
                             newentity.OrderState = 0;
+                            //唯一标识
+                            newentity.OrderSn = newentity.ctid;
+                            string orderSn = dataHelper.getSaleOrderSn();
+                            if (orderSn != "")
+                            {
+                                newentity.OrderSn = orderSn;
+                            }
                         }
-                        //唯一标识
-                        newentity.OrderSn = newentity.ctid;
-                        string orderSn = dataHelper.getSaleOrderSn();
-                        if (orderSn != "")
-                        {
-                            newentity.OrderSn = orderSn;
-                        }
+                        
                         newentity.AfterSaleState = 0;
                         newentity.AfterSaleMethod = afterMethod;
                         if (!ishav)

+ 30 - 1
SiteCore/taobao/designHelper.cs

@@ -58,7 +58,7 @@ namespace SiteCore.Handler
             }
         }
         static string pUrl = "http://api.lingtao8.com/api/manager/";
-        //static string pUrl = "http://47.122.40.91:9999/api/manager/";
+        //static string pUrl = "http://47.122.40.91:8099/api/manager/";
 
         static HttpHelper tb_http = new HttpHelper();
 
@@ -150,6 +150,35 @@ namespace SiteCore.Handler
             }
             return new designApiResponseVo(200, result);
         }
+        public static designApiResponseVo API_update_renewOrder(CeErpTradeCell ceErpTradeCell)
+        {
+            string post_url = pUrl + "renewOrder";
+            WebClient wc = new WebClient();
+            wc.Encoding = Encoding.GetEncoding("utf-8");
+            NameValueCollection PostVars = getParams(ceErpTradeCell);
+            PostVars.Add("actionName", "orderRemarks");
+            PostVars.Add("orderNumber", ceErpTradeCell.ctid);
+
+            string result = "";
+            try
+            {
+                byte[] ret = wc.UploadValues(post_url, "POST", PostVars);
+                string remoteInfo = Encoding.GetEncoding("utf-8").GetString(ret);
+                designApiResponseVo response = JsonConvert.DeserializeObject<designApiResponseVo>(remoteInfo);
+                result = "设计共创:失败-" + response.msg;
+                if (response.code == 200)
+                {
+                    result = "设计共创:成功";
+                    CeErpSukuraData.createInfo(ceErpTradeCell.ctid, 2);
+                    //commonHelper.updateDataTradeCellDesignInfo(ceErpTradeCell.ctid);
+                }
+            }
+            catch (Exception ex)
+            {
+                XLog.SaveLog(0, "API_update_renewOrder:" + ex.Message);
+            }
+            return new designApiResponseVo(200, result);
+        }
 
         private static NameValueCollection getParams(CeErpTradeCell ceErpTradeCell)
         {

+ 1 - 1
SiteCore/taobao/preSalesHelper.cs

@@ -2125,7 +2125,7 @@ namespace SiteCore.Handler
                 else
                 {
                     LogHelper.addLog(entity.ctid, entity.CustomerUserId, "更新推送生成:" + entity.seller_memo, entity.OrderState);
-                    designHelper.API_update_order(entity);
+                    designHelper.API_update_renewOrder(entity);
                     entity.Update();
                 }