刘桂岩 před 2 roky
rodič
revize
3e22398c9b
1 změnil soubory, kde provedl 1 přidání a 1 odebrání
  1. 1 1
      app/controller/Index.php

+ 1 - 1
app/controller/Index.php

@@ -69,9 +69,9 @@ class Index extends BaseController
         ];   //请求参数
         try{
             $result = $client->GetReportInfo($data);   //请求获取接口
+            Db::table('dianapiinfo')->where('Barcode',$code)->update(['pdf_xml'=>$result]);
             $data = ((array)$result)['GetReportInfoResult'];
             $obj = simplexml_load_string("<data>".$data."</data>","SimpleXMLElement", LIBXML_NOCDATA);
-            Db::table('dianapiinfo')->where('Barcode',$code)->update(['pdf_xml'=>$obj]);
             Db::table('api_log')->insert(['type'=>4,'barcode'=>$code]);
             if($obj)
             {