> For the complete documentation index, see [llms.txt](https://temp-17.gitbook.io/trmenu/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://temp-17.gitbook.io/trmenu/chinese/script/expressions.md).

# 表达式

* TrMenu v2 提供全新的表达式写法，简单易懂
* 暂时不支持自定义添加
* 参数通常由 . 分开

## 示例

```yaml
# 同时拥有权限 test 和 等级 >= 10
hasPerm.test and hasLevel.10
```

## 连词

* and = &&
  * "与"，需要相连的两部分均返回 true 时，表达式才返回 true
* or = ||
  * "或者"，需相连两部分任意一部分返回 true 时，表达式即返回 true


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://temp-17.gitbook.io/trmenu/chinese/script/expressions.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
