企业🤖AI智能体构建引擎,智能编排和调试,一键部署,支持私有化部署方案 广告
## 显示加载 ShowLoading ### 平台 - 全平台 ### 参数 名称 | 类型 | 是否必填|说明 :-----------: | :-----------: | :-----------: | ----------- title | String | 否 | 默认显示"加载中…" ,加载提示语 options.mask | Boolean | 否 | 是否显示透明蒙层,防止触摸穿透,默认:false ### 示例 ``` this.$ShowLoading('上传文件中……') ``` ## 关闭加载 CloseLoading ### 平台 - 全平台 ### 参数 无 ### 示例 ``` this.$CloseLoading() ``` ## 消息提示框 ShowToast ### 平台 - 全平台 ### 参数 名称 | 类型 | 是否必填|说明 :-----------: | :-----------: | :-----------: | ----------- title | String | 否 | 默认显示"加载中…" ,加载提示语 options.icon | Boolean | 否 | 图标默认是"none","success"、"loading" 最多显示7个汉字 options.image | Boolean | 否 | 自定义图标的本地路径 options.duration | Boolean | 否 | 提示的延迟时间,单位毫秒,默认:1500 options.mask | Boolean | 否 | 是否显示透明蒙层,防止触摸穿透,默认:true ### 示例 ``` this.$ShowToast('操作成功',{icon:"success"}) ``` ## 弹窗 ShowModal ### 平台 - 全平台 ### 参数 名称 | 类型 | 是否必填|说明 :-----------: | :-----------: | :-----------: | ----------- content | String | 是 | 提示内容 options.title | String | 否 | 询问窗标题,默认是"提示" options.showCancel | String | 否 | 是否显示"取消"按钮,默认是false options.cancelText | String | 否 | "取消"按钮文案 options.cancelColor | String | 否 | "取消"按钮颜色默认是"#000000" options.confirmText | String | 否 | "确认"按钮文案 options.confirmColor | String | 否 | "确认"按钮颜色默认是"#576B95" ### 示例 ``` this.$ShowModal('操作错误',{confirmText:"朕知道了"}).then(res=>{ console.log(res.confirm) console.log(res.cancel) }) ``` ## 询问弹窗 ShowConfirm ### 平台 - 全平台 ### 参数 名称 | 类型 | 是否必填|说明 :-----------: | :-----------: | :-----------: | ----------- content | String | 是 | 提示内容 options.cancelText | String | 否 | "取消"按钮文案 options.confirmText | String | 否 | "确认"按钮文案,默认是"确认" options.confirmColor | String | 否 | "确认"按钮颜色默认是"#576B95" ### 示例 ``` this.$ShowConfirm('是否确认删除?',{confirmText:"是的"}).then(res=>{ console.log(res.confirm) console.log(res.cancel) }) ``` ## 操作菜单 ShowActionSheet ### 平台 - 全平台 ### 参数 名称 | 类型 | 是否必填|说明 :-----------: | :-----------: | :-----------: | ----------- itemList | Array | 是 | 按钮的文字数组 options.itemColor | String | 否 | 按钮的文字颜色,字符串格式,默认为"#000000" options.valueKey | String | 否 | 数据对应显示值的key,默认是 "value" ### 示例 ``` this.$ShowActionSheet([{value:"菜单1",id:1,value:"菜单2",id:2}],{confirmText:"是的"}).then(res=>{ console.log("选择item",res.selectItem) console.log("选择菜单的index",res.tapIndex) }) ```