# 数据字典使用说明

## 一、当前应用获取数字字典

var dict = new this.Dict("fileSource"); //fileSource 数据字典的名称&#x20;

var bxtype = dict.get("报销类型"); //报销类型，项目名称&#x20;

return bxtype; //返回值

## 二、跨应用获取数字字典

var dict = new this.Dict({&#x20;

type : "cms", //应用类型。可以为process cms。如果没有该选项或者值为空字符串，则表示应用脚本和被应用的脚本配置类型相同；比如在流程的A应用脚本中引用流程B应用的脚本配置，则type可以省略。

&#x20;application : "bulletin", //流程、CMS的名称、别名、id, 默认为当前应用&#x20;

name : "bulletinDictionary", // 数据字典的名称、别名、id&#x20;

enableAnonymous : true //允许用户在未登录的情况下读取cms的数据字典, type为process的时候此参数无效，默认为false });

var bxtype = dict.get("报销类型"); //报销类型，项目名称&#x20;

return bxtype; //返回值


---

# Agent Instructions: 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://o2oa.gitbook.io/course/liu-cheng-guan-li/shu-zi-zi-dian-shi-yong.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.
