wanggangtao 5 年之前
父節點
當前提交
0f6818cb10
共有 2 個文件被更改,包括 7 次插入1 次删除
  1. 0 1
      lib/financeTencent.class.php
  2. 7 0
      lib/stock.class.php

+ 0 - 1
lib/financeTencent.class.php

@@ -65,7 +65,6 @@ class FinanceTencent
         $url = "http://qt.gtimg.cn/q=" . $code;
         //市盈率,流通市值,总市值,市净率
         $content1 = self::curl_get_data($url);
-
 //      解析返回的历史数据
         if (!empty($content1)) {
             $data["pe_ttm"] = floatval($content1[39]);//pe_ttm市盈率

+ 7 - 0
lib/stock.class.php

@@ -27,6 +27,13 @@ class Stock {
         return $id;
     }
 
+    /***
+     * @param $stock_code
+     * @param $attrs
+     * @return mixed
+     * @throws Exception
+     * 更新部分静态数据
+     */
     static public function updateByCode($stock_code,$attrs)
     {
         if (empty($attrs)) throw new Exception('参数不能为空', 102);