From 7dcac380a8a86c09892724507d520d62004065c0 Mon Sep 17 00:00:00 2001 From: ancong <12345678> Date: Sun, 9 Nov 2025 10:40:43 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=9A=E4=B8=BB=E5=8D=95=E4=BD=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/apis/yezhudanwei.ts | 1 + src/apis/zhixing.ts | 55 +- src/components/signature/landscape - 副本.vue | 149 ++ src/components/signature/landscape.vue | 77 +- src/components/uni-menu/uni-menu.vue | 49 +- src/pages.json | 5 + src/pages/hetong/hetong.vue | 20 +- src/pages/jianyi/jianyi.vue | 7 +- src/pages/login/login.vue | 16 +- src/pages/tongji/fenshutj.vue | 2 +- src/pages/xiangmu/listindex.vue | 37 +- src/pages/xiangmu/yezhudanwei - 副本.vue | 480 ++++++ src/pages/xiangmu/yezhudanwei.vue | 1420 +++++++++++++---- src/pages/zhixing/addjianchabiao.vue | 2 +- src/pages/zhixing/addwenjuan.vue | 4 +- src/pages/zhixing/jianchabiao.vue | 105 +- src/pages/zhixing/wenjuan.vue | 133 +- src/store/user.ts | 54 +- .../customthree-tree-select/changelog.md | 26 + .../customthree-tree-select.vue | 906 +++++++++++ .../data-select-item.vue | 285 ++++ .../customthree-tree-select/interface.ts | 0 .../customthree-tree-select/utils.ts | 17 + .../customthree-tree-select/package.json | 85 + .../customthree-tree-select/readme.md | 240 +++ src/uni_modules/next-modal/changelog.md | 12 + .../components/next-modal/next-modal.vue | 275 ++++ src/uni_modules/next-modal/package.json | 79 + src/uni_modules/next-modal/readme.md | 341 ++++ src/utils/constant.ts | 6 +- src/utils/storage.ts | 6 +- src/utils/util.ts | 1 + 32 files changed, 4475 insertions(+), 420 deletions(-) create mode 100644 src/components/signature/landscape - 副本.vue create mode 100644 src/pages/xiangmu/yezhudanwei - 副本.vue create mode 100644 src/uni_modules/customthree-tree-select/changelog.md create mode 100644 src/uni_modules/customthree-tree-select/components/customthree-tree-select/customthree-tree-select.vue create mode 100644 src/uni_modules/customthree-tree-select/components/customthree-tree-select/data-select-item.vue create mode 100644 src/uni_modules/customthree-tree-select/components/customthree-tree-select/interface.ts create mode 100644 src/uni_modules/customthree-tree-select/components/customthree-tree-select/utils.ts create mode 100644 src/uni_modules/customthree-tree-select/package.json create mode 100644 src/uni_modules/customthree-tree-select/readme.md create mode 100644 src/uni_modules/next-modal/changelog.md create mode 100644 src/uni_modules/next-modal/components/next-modal/next-modal.vue create mode 100644 src/uni_modules/next-modal/package.json create mode 100644 src/uni_modules/next-modal/readme.md diff --git a/src/apis/yezhudanwei.ts b/src/apis/yezhudanwei.ts index 9b15573..80b9606 100644 --- a/src/apis/yezhudanwei.ts +++ b/src/apis/yezhudanwei.ts @@ -13,6 +13,7 @@ export const getcompanylist = async (data: any) => { data: data }) } + /** * 查询业主树 * diff --git a/src/apis/zhixing.ts b/src/apis/zhixing.ts index 8a99e10..8366016 100644 --- a/src/apis/zhixing.ts +++ b/src/apis/zhixing.ts @@ -148,7 +148,60 @@ export const getcheckTableIdtree = async () => { */ export const getexecutionprojectlist = async (contractId: any) => { return await request.http({ - url: '/safety_hazard/execution/project/list/web/' + contractId, + url: '/safety_hazard/execution/project/list/pad/' + contractId, + // isPost: false, + isPost: '1' + }) +} + +/** + *保存当前某端使用的项目 safety_hazard:project:list + * @returns + */ +export const setprojectcurrent = async (projectId: any) => { + return await request.http({ + // url: `/safety_hazard/execution/project/current/${appType}/${projectId}`, + // isPost: false, + url: `/safety_hazard/execution/project/current/1/${projectId}`, + isPost: '0' + }) +} + +/** + * + +保存当前某端使用的合同 safety_hazard:contract:list + * @returns + */ +export const setcontractcurrent = async (contractId: any) => { + return await request.http({ + // url: `/safety_hazard/execution/contract/current/${appType}/${contractId}`, + url: `/safety_hazard/execution/contract/current/1/${contractId}`, + // isPost: false, + isPost: '0' + }) +} + +/** + *根据APP类型获取当前使用的项目(字典app_type ) safety_hazard:project:list + * @returns + */ +export const getprojectcurrent = async () => { + return await request.http({ + //url: '/safety_hazard/execution/project/current/' + appType, + // isPost: false, + url: '/safety_hazard/execution/project/current/1', + isPost: '1' + }) +} +/** + *根据APP类型获取当前使用的合同(字典app_type ) safety_hazard:contract:list + * @returns + */ +export const getcontractcurrent = async () => { + return await request.http({ + // url: '/safety_hazard/execution/contract/current/' + appType, + url: '/safety_hazard/execution/contract/current/1', // isPost: false, isPost: '1' }) diff --git a/src/components/signature/landscape - 副本.vue b/src/components/signature/landscape - 副本.vue new file mode 100644 index 0000000..2268fca --- /dev/null +++ b/src/components/signature/landscape - 副本.vue @@ -0,0 +1,149 @@ + + + + + \ No newline at end of file diff --git a/src/components/signature/landscape.vue b/src/components/signature/landscape.vue index a35840f..cd94c54 100644 --- a/src/components/signature/landscape.vue +++ b/src/components/signature/landscape.vue @@ -1,8 +1,26 @@ @@ -23,12 +41,17 @@ fontSize: 15, fontFamily: 'Arial', rotate: 60, - spacing: 100, + spacing: 150, single: false } } }, methods: { + goLandscape() { + uni.navigateTo({ + url: '/pages/componentsB/signature/landscape' + }) + }, clear() { this.$refs.signatureRef.clear() }, @@ -36,26 +59,34 @@ this.$refs.signatureRef.undo() }, confirm() { - // debugger this.$refs.signatureRef.getImage().then(res => { - // debugger - this.basicResult = res; - console.log('sdadsa', res) + this.basicResult = res }) }, - onClose() { - uni.navigateBack() - }, onConfirm(res) { - // debugger - // this.$refs.signatureRef.getImage().then(res => { - // debugger - // this.basicResult = res; - // console.log('sdadsa', res) - // }) - this.basicResult = res; - this.showImageModal = true; + // this.basicResult = res + // this.showImageModal = true this.$emit("onConfirm", res); //执行父级函数 + }, + // 水印相关方法 + onFontSizeChange(e) { + this.watermark.fontSize = e.detail.value; + }, + onRotateChange(e) { + this.watermark.rotate = e.detail.value; + }, + onSpacingChange(e) { + this.watermark.spacing = e.detail.value; + 7 + }, + onShowWatermarkChange(e) { + this.showWatermark = e.detail.value; + }, + onSingleWatermarkChange(e) { + this.watermark.single = e.detail.value; + }, + onWatermarkConfirm(res) { + this.watermarkResult = res } } } @@ -64,16 +95,16 @@ \ No newline at end of file diff --git a/src/pages/xiangmu/yezhudanwei.vue b/src/pages/xiangmu/yezhudanwei.vue index f9183fb..1e29e59 100644 --- a/src/pages/xiangmu/yezhudanwei.vue +++ b/src/pages/xiangmu/yezhudanwei.vue @@ -1,13 +1,20 @@ - + + + + \ No newline at end of file diff --git a/src/pages/zhixing/addjianchabiao.vue b/src/pages/zhixing/addjianchabiao.vue index 8b6e1c1..6273895 100644 --- a/src/pages/zhixing/addjianchabiao.vue +++ b/src/pages/zhixing/addjianchabiao.vue @@ -197,7 +197,7 @@ + style="width: 20%; margin-top: 100rpx;" v-if="$checkPermi(['safety_hazard:table:remove'])"> diff --git a/src/pages/zhixing/addwenjuan.vue b/src/pages/zhixing/addwenjuan.vue index 5aaeb82..3850fab 100644 --- a/src/pages/zhixing/addwenjuan.vue +++ b/src/pages/zhixing/addwenjuan.vue @@ -209,7 +209,9 @@ - + diff --git a/src/pages/zhixing/jianchabiao.vue b/src/pages/zhixing/jianchabiao.vue index 5def1ca..c8affaa 100644 --- a/src/pages/zhixing/jianchabiao.vue +++ b/src/pages/zhixing/jianchabiao.vue @@ -10,6 +10,10 @@ + + + @@ -33,13 +37,16 @@ --> + :disabled="activenum==0||!isbutclick" @click="shanchujiancha()" size="small" + v-if="$checkPermi(['safety_hazard:table:remove'])"> + @click="biangenls()" :disabled="activenum!=1||!isbutclick" size="small" + v-if="$checkPermi(['safety_hazard:log:query'])"> + :disabled="!queryParams.projectId" @click="addjianyi()" size="small" + v-if="$checkPermi(['safety_hazard:suggestion:add'])"> @@ -223,7 +230,12 @@ width: 100%;align-items: left; border-top:1px solid #eee;"> getloginfo, delsafety_hazard, getcheckTableIdtree, - getexecutionprojectlist + getexecutionprojectlist, + + setprojectcurrent, + setcontractcurrent, + getprojectcurrent, + getcontractcurrent } from "@/apis/zhixing" import { @@ -653,18 +665,36 @@ width: 100%;align-items: left; border-top:1px solid #eee;"> //系统合同号 //debugger // this.contractId = e.value; + this.queryParams.projectname = ''; this.queryParams.projectId = ''; this.getxmdwlist(); //获取项目单位列表 + if (e) { + setcontractcurrent(this.contractId).then((res) => { + //保存选择的系统合同号 + this.userStore.setxtht(e.value, e.label); + }); + } + + }, changexmbh(e) { //项目编号 //debugger - this.queryParams.projectname = e.lablename; - this.queryParams.projectId = e.projectId; + if (e) { + this.queryParams.projectname = e.lablename; + this.queryParams.projectId = e.projectId; + } this.qingchu(); + if (e) { + setprojectcurrent(this.queryParams.projectId).then((res) => { + //保存选择的项目编号 + this.userStore.setproject(e.projectId, e.lablename); + }); + } + }, xmhandleConfirm(result) { // 处理确认项目 @@ -840,8 +870,23 @@ width: 100%;align-items: left; border-top:1px solid #eee;"> this.xththlist = res.data ? this.parseObjectToArray(res.data) : []; if (this.xththlist.length > 0) { // debugger - this.contractId = this.xththlist[0].value; - this.getxmdwlist(); //获取项目单位列表 + getcontractcurrent().then((res2) => { + //获取当前保存过的合同号 没有就默认 + // debugger + if (res2.data) { + this.contractId = res2.data.contractId; + this.getxmdwlist(); //获取项目单位列表 + //保存选择的系统合同号 + this.userStore.setxtht(res2.data.contractId, res2.data.sysCtcNo); + } else { + this.contractId = this.xththlist[0].value; + this.getxmdwlist(); //获取项目单位列表 + setcontractcurrent(this.contractId).then((res) => { + //保存选择的系统合同号 + this.userStore.setxtht(this.xththlist[0].value, this.xththlist[0].label); + }); + } + }); } }) }, @@ -860,14 +905,46 @@ width: 100%;align-items: left; border-top:1px solid #eee;"> this.xmpickerConfig.options = res.data.projects || []; if (this.xmdwlist.length > 0) { - //debugger - this.queryParams.projectId = this.xmdwlist[0].projectId; - this.queryParams.projectname = this.xmdwlist[0].lablename; - this.xmpickerConfig.value = this.xmdwlist[0]; - // this.xmpickerConfig.value = this.xmdwlist.filter(item => res.data.areaIds.includes(item.value)); + // if (this.contractId == this.userStore.xththid) { + // + getprojectcurrent().then((res2) => { + //获取当前保存过的项目 没有就默认 + // debugger + if (res2.data) { + if (this.contractId == res2.data.contractId) { + //当前选的和保存的一样 + this.queryParams.projectId = res2.data.projectId; + this.queryParams.projectname = res2.data.projectNo + `(${res2.data.name})`; + this.xmpickerConfig.value = res2.data.projectId; + this.userStore.setproject(this.xmdwlist[0].projectId, res2.data.projectNo + + `(${res2.data.name})`); + } else { + this.queryParams.projectId = this.xmdwlist[0].projectId; + this.queryParams.projectname = this.xmdwlist[0].lablename; + this.xmpickerConfig.value = this.xmdwlist[0]; + setprojectcurrent(this.queryParams.projectId).then((res) => { + //保存选择的项目编号 + this.userStore.setproject(this.xmdwlist[0].projectId, this.xmdwlist[0].lablename); + }); + } + + } else { + this.queryParams.projectId = this.xmdwlist[0].projectId; + this.queryParams.projectname = this.xmdwlist[0].lablename; + this.xmpickerConfig.value = this.xmdwlist[0]; + setprojectcurrent(this.queryParams.projectId).then((res) => { + //保存选择的项目编号 + this.userStore.setproject(this.xmdwlist[0].projectId, this.xmdwlist[0].lablename); + }); + } + this.getlistinfo(); //获取检查列表 + }); + + } else { + this.getlistinfo(); //获取检查列表 } - this.getlistinfo(); //获取检查列表 + }) }, diff --git a/src/pages/zhixing/wenjuan.vue b/src/pages/zhixing/wenjuan.vue index 0cb53f0..2f57d1a 100644 --- a/src/pages/zhixing/wenjuan.vue +++ b/src/pages/zhixing/wenjuan.vue @@ -18,8 +18,8 @@ 项目编号: + dataKey="lablename" dataValue="projectId" :localdata="xmpickerConfig.options" :clear="false" + style="width: 400px;"> @@ -31,11 +31,12 @@ + @click="addwenjuan()" size="small" v-if="$checkPermi(['safety_hazard:questionnaire:add'])"> + :disabled="activenum==0" @click="shanchujiancha()" size="small" + v-if="$checkPermi(['safety_hazard:questionnaire:remove'])"> @@ -84,6 +85,9 @@ @@ -239,22 +243,22 @@ - + - - - - - + + + + 手写签名 - - + + + + + + + @@ -262,7 +266,12 @@ + + \ No newline at end of file diff --git a/src/uni_modules/customthree-tree-select/components/customthree-tree-select/data-select-item.vue b/src/uni_modules/customthree-tree-select/components/customthree-tree-select/data-select-item.vue new file mode 100644 index 0000000..ff69562 --- /dev/null +++ b/src/uni_modules/customthree-tree-select/components/customthree-tree-select/data-select-item.vue @@ -0,0 +1,285 @@ + + + + diff --git a/src/uni_modules/customthree-tree-select/components/customthree-tree-select/interface.ts b/src/uni_modules/customthree-tree-select/components/customthree-tree-select/interface.ts new file mode 100644 index 0000000..e69de29 diff --git a/src/uni_modules/customthree-tree-select/components/customthree-tree-select/utils.ts b/src/uni_modules/customthree-tree-select/components/customthree-tree-select/utils.ts new file mode 100644 index 0000000..c164d06 --- /dev/null +++ b/src/uni_modules/customthree-tree-select/components/customthree-tree-select/utils.ts @@ -0,0 +1,17 @@ +export function isString(data: any) { + return typeof data === 'string' +} + +// 分页 +export function paging(data: any[], PAGENUM = 50) { + if (!Array.isArray(data) || !data.length) return data + const pages: any[] = [] + data.forEach((item, index) => { + const i = Math.floor(index / PAGENUM) + if (!pages[i]) { + pages[i] = [] + } + pages[i].push(item) + }) + return pages +} diff --git a/src/uni_modules/customthree-tree-select/package.json b/src/uni_modules/customthree-tree-select/package.json new file mode 100644 index 0000000..be17e96 --- /dev/null +++ b/src/uni_modules/customthree-tree-select/package.json @@ -0,0 +1,85 @@ +{ + "id": "customthree-tree-select", + "displayName": "customthree-tree-select树形选择器支持v-model vue3版本", + "version": "1.1.2", + "description": "树形选择器基于uni-ui,v-model绑定数据,父级可选、数据回显、移除选项", + "keywords": [ + "custom", + "tree-select", + "选择器", + "树形选择器" +], + "repository": "", + "engines": { + "HBuilderX": "^3.8.3" + }, + "dcloudext": { + "type": "component-vue", + "sale": { + "regular": { + "price": "0.00" + }, + "sourcecode": { + "price": "0.00" + } + }, + "contact": { + "qq": "" + }, + "declaration": { + "ads": "无", + "data": "插件不采集任何数据", + "permissions": "无" + }, + "npmurl": "" + }, + "uni_modules": { + "dependencies": [], + "encrypt": [], + "platforms": { + "cloud": { + "tcb": "y", + "aliyun": "y", + "alipay": "n" + }, + "client": { + "Vue": { + "vue2": "n", + "vue3": "y" + }, + "App": { + "app-vue": "y", + "app-nvue": "u" + }, + "H5-mobile": { + "Safari": "y", + "Android Browser": "y", + "微信浏览器(Android)": "y", + "QQ浏览器(Android)": "y" + }, + "H5-pc": { + "Chrome": "y", + "IE": "y", + "Edge": "y", + "Firefox": "y", + "Safari": "y" + }, + "小程序": { + "微信": "y", + "阿里": "u", + "百度": "u", + "字节跳动": "u", + "QQ": "u", + "钉钉": "u", + "快手": "u", + "飞书": "u", + "京东": "u" + }, + "快应用": { + "华为": "u", + "联盟": "u" + } + } + } + } +} \ No newline at end of file diff --git a/src/uni_modules/customthree-tree-select/readme.md b/src/uni_modules/customthree-tree-select/readme.md new file mode 100644 index 0000000..77dea3c --- /dev/null +++ b/src/uni_modules/customthree-tree-select/readme.md @@ -0,0 +1,240 @@ +# customthree-tree-select 使用指南 + +**提示:** 使用该插件前确保你已经导入 `uni-popup` `uni-icons` `uni-easyinput` 插件。 + +**有问题可以加 QQ 群:297080738** + +## 优势 + +💪:基于 `uni-popup`、 `uni-icons`、 `uni-easyinput` 插件进行开发,默认样式与 `uni-easyinput` 样式对标。 + +⚡:全面支持懒加载应对大量数据。 + +🚀:v-model 绑定数据、数据回显、移除选项。 + +⚙ :提供更多配置项。 + +📦:开箱即用。 + +## Props + +| 属性名 | 类型 | 默认值 | 说明 | +| :--------------------: | :-----------------: | :-------------: | :----------------------------------------------------------: | +| canSelectAll | Boolean | false | 开启一键全选功能 | +| clearResetSearch | Boolean | false | 设置为 `true` 并且搜索之后,点击输入框清除按钮,会清空搜索内容并且会直接重置整个弹窗内树形选择器内容,默认情况下只有清除之后再次进行查询才会重置选择器 | +| animation | Boolean | ture | 是否开启弹窗动画 | +| is-mask-click | Boolean | true | 点击遮罩关闭弹窗 | +| mask-background-color | String | rgba(0,0,0,0.4) | 蒙版颜色,建议使用 rgba 颜色值 | +| background-color | String | none | 主窗口背景色 | +| safe-area | Boolean | true | 是否适配底部安全区 | +| **choseParent** | **Boolean** | **true** | **父节点是否可选** | +| **linkage** | **Boolean** | **false** | **父子节点是否联动** | +| placeholder | String | 请选择 | 空状态信息提示、弹窗标题 | +| confirmText | String | 完成 | 确定按钮文字 | +| confirmTextColor | String | #007aff | 确定按钮文字颜色 | +| listData | Array | - | 展示的数据 | +| **dataLabel** | **String** | **name** | **listData 中对应数据的 label** | +| **dataValue** | **String** | **id** | **listData 中对应数据的 value** | +| **dataChildren** | **String** | **children** | **listData 中对应数据的 children** | +| clearable | Boolean | false | 是否显示清除按钮,点击清除所有已选项 | +| **mutiple** | **Boolean** | **false** | **是否可以多选** | +| **disabled** | **Boolean** | **false** | **是否允许修改** | +| search | Boolean | false | 是否可以搜索(常用于数据较多的情况) | +| showChildren | Boolean | true | 默认展开(数据内部 showChildren 属性优先级更高,可以设置全局收起,单独展开某一条数据) | +| border | Boolean | false | 显示引导线 | +| load | Function | function(){} | lazyLoadChildren 设置为true 后,点击某个节点发送请求获取子节点数据,用法见下方异步懒加载示例 | +| lazyLoadChildren | Boolean | false | 是否开启异步懒加载节点 | +| **v-model/modelValue** | **Array \| String** | **[ ]** | **已选择的值,通过 v-model 进行绑定,例如:v-model="formData.selectedList" ,根据你绑定数据的类型自动返回相同类型的数据,String 类型通过 `,` 进行分隔** | + +## Events + +| 事件名称 | 说明 | 返回值 | +| ----------------- | ------------------------ | ------------------------------------------- | +| change | 弹窗组件状态发生变化触发 | e={show: true | false,type:当前模式} | +| maskClick | 点击遮罩层触发 | | +| update:modelValue | 选中数据或取消选中时触发 | 以数组形式返回已选择数据的 dataValue 对应值 | +| select-change | 选中数据或取消选中时触发 | 以数组形式返回选中数据完整信息 | +| removeSelect | 从选择框内删除元素时触发 | | + +## 基础使用示例 + +```vue + + + +``` + +## 禁用某些选项,或隐藏某些选项 + +```vue + + + +``` + +## 异步懒加载 + +```vue + + + + + +``` + diff --git a/src/uni_modules/next-modal/changelog.md b/src/uni_modules/next-modal/changelog.md new file mode 100644 index 0000000..2b99cab --- /dev/null +++ b/src/uni_modules/next-modal/changelog.md @@ -0,0 +1,12 @@ +## 1.0.5(2024-09-14) +更新说明 +## 1.0.4(2023-12-08) +增加弹层宽度可配置 +## 1.0.3(2023-12-08) +更新使用事件说明 +## 1.0.2(2023-06-15) +增加自定义插槽使用说明 +## 1.0.1(2023-06-14) +增加插件使用说明 +## 1.0.0(2023-06-12) +初始化next-modal diff --git a/src/uni_modules/next-modal/components/next-modal/next-modal.vue b/src/uni_modules/next-modal/components/next-modal/next-modal.vue new file mode 100644 index 0000000..6ca36ad --- /dev/null +++ b/src/uni_modules/next-modal/components/next-modal/next-modal.vue @@ -0,0 +1,275 @@ + + + + + \ No newline at end of file diff --git a/src/uni_modules/next-modal/package.json b/src/uni_modules/next-modal/package.json new file mode 100644 index 0000000..cd31a40 --- /dev/null +++ b/src/uni_modules/next-modal/package.json @@ -0,0 +1,79 @@ +{ + "id": "next-modal", + "displayName": "next-modal(vue2 vue3多端通用)轻量modal弹层", + "version": "1.0.5", + "description": "modal弹层,自定义弹层,轻量弹层", + "keywords": [ + "modal", + "next-modal", + "弹层", + "自定义弹层" +], + "repository": "", + "engines": { + "HBuilderX": "^3.1.1" + }, +"dcloudext": { + "sale": { + "regular": { + "price": "0.00" + }, + "sourcecode": { + "price": "0.00" + } + }, + "contact": { + "qq": "" + }, + "declaration": { + "ads": "无", + "data": "插件不采集任何数据", + "permissions": "无" + }, + "npmurl": "", + "type": "component-vue" + }, + "uni_modules": { + "platforms": { + "cloud": { + "tcb": "y", + "aliyun": "y", + "alipay": "n" + }, + "client": { + "App": { + "app-vue": "n", + "app-nvue": "n" + }, + "H5-mobile": { + "Safari": "n", + "Android Browser": "y", + "微信浏览器(Android)": "y", + "QQ浏览器(Android)": "y" + }, + "H5-pc": { + "Chrome": "y", + "IE": "n", + "Edge": "n", + "Firefox": "n", + "Safari": "n" + }, + "小程序": { + "微信": "y", + "阿里": "u", + "百度": "u", + "字节跳动": "u", + "QQ": "u" + }, + "快应用": { + "华为": "n", + "联盟": "n" + }, + "Vue": { + "vue2": "y", + "vue3": "y" + } + } + } + } +} \ No newline at end of file diff --git a/src/uni_modules/next-modal/readme.md b/src/uni_modules/next-modal/readme.md new file mode 100644 index 0000000..199af9a --- /dev/null +++ b/src/uni_modules/next-modal/readme.md @@ -0,0 +1,341 @@ + +## next-modal --modal弹层 + +> 遇到问题或有建议可以加入QQ群(455948571)反馈 +> 如果觉得组件不错,给五星鼓励鼓励咯! + +### 如果有使用问题请加群 + +注意:如果插件问题,请务必给一个完整的复现demo,谢谢配合; +[点击链接加入群聊前端开发(uniapp插件)】](https://qm.qq.com/q/S1bJzQfJAG) + +### 预览 + +*** + +| 功能预览 | +| :----------------------------------------------------------------: | +| ![](https://lixueshiaa.github.io/webtest/www/static/next-modal.gif)| + +## 使用 + +>[从uniapp插件市场导入](https://ext.dcloud.net.cn/plugin?name=next-modal) + +### vue3 使用实例 +```html + +``` + +```js + + + +``` + +### vue2 使用实例 +```html + +``` + +```js + + +``` + +## 参数 + + +### next-search-more Props + +可选参数属性列表 + +|参数名 |说明 |类型 |是否必填 |默认值 |可选值 | +|---- |---- |---- |---- |---- |---- | +|title |弹层标题 |String |否 |'' |- | +|content |弹层内容 |String |否 |'' |- | +|align |弹层内容的对齐方式 |String |否 |left |- | +|cancelText |取消按钮的文字,默认为"取消" |String |否 |取消 |- | +|cancelColor | 取消按钮文字颜色 |String |否 |#333333 |- | +|confirmText |确定按钮的文字,默认为"确定" |String |否 |确定 |- | +|confirmColor | 确认按钮文字颜色 |String |否 |#f0ad4e |- | +|showCancel| 是否显示取消按钮,默认为 true |Boolean |否 |true |false | +|show| 显示弹层 |Boolean |否 |false |true | +|autoClose| 点击遮罩是否自动关闭弹窗 |Boolean |否 |true |false | +|width| 弹层内容宽度(只支持字符串,必须要带单位) |String |否 |- |- | + + +## Slot 插槽 +(注意: 插槽的优先级大于组件的props配置的值) +|名称 |说明 |参数 | +|---- |---- |---- | +|title |title插槽 |无 | +|content |content插槽 |无 | +|footer |footer插槽 |无 | +|default |default插槽 |无 | + +# Event 事件 +|事件名 |说明 |类型 |回调参数 | +|---- |---- |---- |---- | +|confirm|确认的回调事件 |emit |- | +|cancel|取消的回调事件 |emit |- | \ No newline at end of file diff --git a/src/utils/constant.ts b/src/utils/constant.ts index f47c5fb..e66dc0b 100644 --- a/src/utils/constant.ts +++ b/src/utils/constant.ts @@ -11,7 +11,11 @@ const constant = { childrenmenutitle: 'vuex_childrenmenutitle', urlip: 'vuex_urlip', urlpro: 'vuex_urlpro', - allurl: 'vuex_allurl' + allurl: 'vuex_allurl', + xththid: 'vuex_xththid', + xththstr: 'vuex_xththstr', + projectid: 'vuex_projectid', + projectname: 'vuex_projectname' } export default constant diff --git a/src/utils/storage.ts b/src/utils/storage.ts index d6f466a..c57d133 100644 --- a/src/utils/storage.ts +++ b/src/utils/storage.ts @@ -16,7 +16,11 @@ let storageNodeKeys = [ constant.childrenmenutitle, constant.urlip, constant.urlpro, - constant.allurl + constant.allurl, + constant.xththid, + constant.xththstr, + constant.projectid, + constant.projectname ] const storage = { diff --git a/src/utils/util.ts b/src/utils/util.ts index 60ca1bb..45d8992 100644 --- a/src/utils/util.ts +++ b/src/utils/util.ts @@ -370,6 +370,7 @@ export const downloadBinaryFile = (url: any) => { let headers = { Bearerauth: 'Bearer ' + getToken() } + //console.log('下载地址:', JSON.stringify(url)) uni.downloadFile({ url: url, //下载地址 header: headers,