[WordPress] 外掛分享: Scout Units List

首頁外掛目錄 › Scout Units List
全新外掛
安裝啟用
尚無評分
2636 天前
最後更新
問題解決
WordPress 3.0.0+ v0.6.0 上架:2016-11-22

內容簡介

這個外掛能讓您建立一個單位結構,該結構依賴於主單位,並使用各種短碼以及可自訂模板在頁面或文章中呈現。

顯示單位列表

添加 [sul-units-list id="X"] 短碼,其中 X 是基礎單位的 ID。您也可以使用其他屬性:

class(字串)- 允許添加 CSS 類別,
current(布林值,預設值為 false)- 允許顯示/隱藏目前的單位在列表中,
external(布林值,預設值為 false)- 決定結構是否應該從外部來源接收(如果是,配置中應該定義外部來源 URL),
levels(整數,預設值為 1)- 允許定義具有依賴單位的層級數,
types(預設值為空)- 允許定義要顯示的類型列表(透過逗號分隔)。

要定義自己的模板,請在當前佈景主題目錄下創建 scout-units-list 目錄(或在配置中定義其他目錄),然後在其中創建 UnitsList.phtml、UnitsList-Y.phtml 或 UnitsList-X.phtml 檔案,其中 Y 是一個類型,X 是基礎單位的 ID。要自訂依賴單位層級的模板,您還需在相同位置中創建 UnitsListLevel.phtml、UnitsListLevel-Y.phtml 或 UnitsListLevel-X.phtml 檔案。請檢查 View/Shortcodes 目錄中的預設模板,以查看如何存取單位資料。

顯示人員列表

添加 [sul-persons-list id="X"] 短碼,其中 X 是基礎單位的 ID。您也可以使用其他屬性:

class(字串)- 允許添加 CSS 類別,
external(布林值,預設值為 false)- 決定結構是否應該從外部來源接收(如果是,配置中應該定義外部來源 URL)。

要定義自己的模板,請在當前佈景主題目錄下創建 scout-units-list 目錄(或在配置中定義其他目錄),然後在其中創建 PersonsList.phtml、PersonsList-Y.phtml 或 PersonsList-X.phtml 檔案,其中 Y 是一個類型,X 是基礎單位的 ID。要知道如何存取單位資料,請檢查 View/Shortcodes 目錄中的預設模板。

穩定版本發布前需要完成的事項

新增一個短碼,該短碼能夠在地圖上標示選定的單位。
可配置的類型/子類型列表和依賴性。

未來計畫

為每個單位添加更改(版本)列表。
為每個使用者添加職位更改(版本)列表。
在管理面板中對單位/職位列表進行排序/搜尋。

外掛標籤

開發者團隊

⬇ 下載最新版 (v0.6.0) 或搜尋安裝

① 下載 ZIP → 後台「外掛 › 安裝外掛 › 上傳外掛」
② 後台搜尋「Scout Units List」→ 直接安裝(推薦)
📦 歷史版本下載

原文外掛簡介

This plugin allows you to create a structure of units which are dependent on main one and then present it inside page or post using variety of shortcodes equipped with customizable templates.
Showing units list
Add [sul-units-list id="X"] shortcode, where X is an ID of a base unit. You can use also other attributes:

class (string) – allows to add CSS class,
current (boolean, false as a default value) – allows to show/hide current unit on a list,
external (boolean, false as a default value) – decides if structure should be receive from external source (if so, external source URL in configuration should be defined),
levels (integer, 1 as a default value) – allows to define number of levels with dependent units,
types (empty as a default value) – allows to define list of types (separated by comma) which have to be showed.

To define your own template create scout-units-list directory in your current theme directory (or define other directory in configuration form) and then create there UnitsList.phtml, UnitsList-Y.phtml or UnitsList-X.phtml file where Y is a type and X is an ID of a base unit. To customize template of dependent units level you have to create in the same location UnitsListLevel.phtml, UnitsListLevel-Y.phtml or UnitsListLevel-X.phtml file as well. To know how to access units data please check default templates in View/Shortcodes directory.
Showing persons list
Add [sul-persons-list id="X"] shortcode, where X is an ID of a base unit. You can use also other attributes:

class (string) – allows to add CSS class,
external (boolean, false as a default value) – decides if structure should be receive from external source (if so, external source URL in configuration should be defined).

To define your own template create scout-units-list directory in your current theme directory (or define other directory in configuration form) and then create there PersonsList.phtml, PersonsList-Y.phtml or PersonsList-X.phtml file where Y is a type and X is an ID of a base unit. To know how to access units data please check default template in View/Shortcodes directory.
Things to do before stable version release

Add a shortcode which implements a map with selected units marked on it.
Configurable types/subtypes lists and dependencies.

Future plans

Add for each unit a list of changes (versions).
Add for each user a list of position changes (versions).
Sorting/searching on units/positions lists in admin panel.

文章
Filter
Mastodon