Skip to content

Commit

Permalink
complete stocks
Browse files Browse the repository at this point in the history
  • Loading branch information
hyansuper committed Jan 5, 2025
1 parent 7c0949a commit 9488ded
Show file tree
Hide file tree
Showing 9 changed files with 56 additions and 14 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-gh-pages-action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ jobs:
cd xdial/docs/manual
bash gh_make.sh ../../manual
cd ../../docs/manual
mv *.json *.js *.html ../../manual
mv *.json *.js *.html *.js.gz ../../manual
cd ../..
rm -r docs/manual
mv manual docs
Expand Down
11 changes: 9 additions & 2 deletions docs/manual/en/coincap_assets.rst → docs/manual/en/crypto.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
coincap assets
==================
Cryptocurrencies
====================

Value and 24-hour change rate are fetched from :xref:`coincap.io <https://coincap.io>`

Crypto ids
----------------

.. _ids:

.. raw:: html

Expand Down
6 changes: 6 additions & 0 deletions docs/manual/en/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,12 @@ User Manual
alarms
weather
perfmon
crypto
stocks

.. toctree::
:maxdepth: 2

faq


Expand Down
16 changes: 12 additions & 4 deletions docs/manual/en/stocks.rst
Original file line number Diff line number Diff line change
@@ -1,11 +1,18 @@
Stocks
=========

Stock ticker symbols consist of
The values below the line are: opening price, highest and lowest price in the day.

* *A股* 代码为 6 位数字,如平安银行是 `000001`
* *港股* 是 5 位数字,如小米集团 `01801`
* *美股* 代码一般是大写的英文,比如特斯拉是 `TSLA`
Stock ids
--------------

.. _ids:

Stock ids consist of a 2-letter exchange market symbol and the stock code (ticker symbol). Note that stock ids are case sensitive!

* Exchange markets in **Chinese mainland** includes Shanghai "sh", Shenzhen "sz" and Beijing "bj" Exchange. e.g. 贵州茅台 `sh600519`, 平安银行 `sz000001`, 聚星科技 `bj920111`
* For **Hong Kong** exchange market, it's "hk" + 5 digits. e.g. XiaoMi Corporation is `hk01810`
* For stocks in the **U.S.**, it's "us" + ticker symbol. e.g. Tesla is `usTSLA`

.. raw:: html

Expand Down Expand Up @@ -40,3 +47,4 @@ Stock ticker symbols consist of
</style>
<div style="display:flex;justify-content:space-between;gap:0.15em"><input id='stock_id' type='text' placeholder='usTSLA' style="flex:1"/><button onclick='var st_id=eid("stock_id");if(st_id.value.length==0)st_id.value=st_id.placeholder;query_stock(st_id.value.split(",")[0].trim())'>Test</button></div>
<br><table id='tb'></table>
<br><br><br><br>
Binary file added docs/manual/tiny-pinyin.js.gz
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
coincap assets
==================
加密货币
===============

加密货币界面显示的涨跌幅为 24 小时内的涨跌幅。数据来自 :xref:`coincap.io <https://coincap.io>`

id 号
-------------

.. _ids:

.. raw:: html

Expand Down
4 changes: 2 additions & 2 deletions docs/manual/zh-cn/faq.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,14 @@
加密货币价格无法显示
--------------------

#. 确保 :xref:`https://coincap.io <https://coincap.io>` 网站能够通过您的路由器正常访问
#. 确保 :xref:`https://coincap.io <https://coincap.io>` 网站能够通过您的路由器正常访问
#. 检查设置页面中加密货币的其他一栏是否有填错 `id 号 <coincap_assets.html>`_


更新固件后无法启动
-----------------------

当新固件无法读取旧的设置时可能会导致取法启动,您可以通过 :ref:`恢复出厂设置 <如何恢复出厂设置?>` 来清除旧的设置。
新固件无法读取旧的设置时可能会发生启动异常,您可以通过 :ref:`恢复出厂设置 <如何恢复出厂设置?>` 来清除旧的设置。

下载表盘后设备不断重启
------------------------------
Expand Down
6 changes: 6 additions & 0 deletions docs/manual/zh-cn/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,12 @@
alarms
weather
perfmon
crypto
stocks

.. toctree::
:maxdepth: 2

faq


Expand Down
14 changes: 11 additions & 3 deletions docs/manual/zh-cn/stocks.rst
Original file line number Diff line number Diff line change
@@ -1,10 +1,17 @@
股票
=======

股票界面的大数字为当前价格,其下方显示当天或最后一个交易日的开盘价、最高价和最低价。在收盘时,当前价即为收盘价。

id 号
-----------

.. _ids:

股票 id 号以交易所两位字母开头,加上数字或英文代码。注意大小写不能写错!

* *A股* 分为上交所(sh)、深交所(sz)和北交所(bj),如上证指数 `sh000001`, 平安银行 `sz000001`, 聚星科技 `bj920111`
* *港股* "hk" + 5 位数字, 如小米集团 `hk01810`
* *A股* 分为上交所 "sh"、深交所 "sz" 和北交所 "bj",加上 6 位数字。如贵州茅台 `sh600519`, 平安银行 `sz000001`, 聚星科技 `bj920111`
* *港股* 一般是 "hk" + 5 位数字, 如小米集团 `hk01810`;指数则是 "hk" + 大写字母,如恒生指数 `hkHSI`
* *美股* 是 "us" + 大写的英文,如特斯拉 `usTSLA`

.. raw:: html
Expand Down Expand Up @@ -35,5 +42,6 @@
td:first-child{background-color: lightgrey}
}
</style>
<div style="display:flex;justify-content:space-between;gap:0.15em"><input id='stock_id' placeholder="sz000001" type='text' style="flex:1"/><button onclick='var st_id=eid("stock_id");if(st_id.value.length==0)st_id.value=st_id.placeholder;query_stock(st_id.value.split(",")[0].trim())'>测试</button></div>
<div style="display:flex;justify-content:space-between;gap:0.15em"><input id='stock_id' placeholder="sh600519" type='text' style="flex:1"/><button onclick='var st_id=eid("stock_id");if(st_id.value.length==0)st_id.value=st_id.placeholder;query_stock(st_id.value.split(",")[0].trim())'>测试</button></div>
<br><table id='tb'></table>
<br><br><br><br>

0 comments on commit 9488ded

Please sign in to comment.