From 800a6769e4faf0cb2b9c9aabe4dbbbbfa8387a61 Mon Sep 17 00:00:00 2001 From: liwenxuan <1298531568@qq.com> Date: Mon, 11 Dec 2023 10:00:13 +0800 Subject: [PATCH 01/11] =?UTF-8?q?=E7=AD=BE=E5=90=8D=E6=9D=BF=E6=95=B4?= =?UTF-8?q?=E5=90=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/assets/paintboard.png | Bin 0 -> 10670 bytes src/components/DesignForm/assembly/index.ts | 9 + .../DesignForm/public/form/formGroup.vue | 3 +- src/views/sysworkflow/codepage/page.vue | 17 +- src/views/sysworkflow/codepage/page_black.vue | 19 + src/widget/index.ts | 2 + src/widget/writingboard/index.vue | 186 +++++ src/widget/writingboard/paintBoard.vue | 124 +++ src/widget/writingboard/vueSignature.vue | 713 ++++++++++++++++++ 9 files changed, 1064 insertions(+), 9 deletions(-) create mode 100644 src/assets/paintboard.png create mode 100644 src/views/sysworkflow/codepage/page_black.vue create mode 100644 src/widget/writingboard/index.vue create mode 100644 src/widget/writingboard/paintBoard.vue create mode 100644 src/widget/writingboard/vueSignature.vue diff --git a/src/assets/paintboard.png b/src/assets/paintboard.png new file mode 100644 index 0000000000000000000000000000000000000000..252b4631e33f4b45244486608fafd99ee847f792 GIT binary patch literal 10670 zcmeAS@N?(olHy`uVBq!ia0y~y;QYtHz+%C{1QfaJe!>z+F%}28J29*~C-V}>VM%xN zb!1@J*w6hZkrl}2EbxddW?zuZTe zS??z(8SnOWNx8e39jFlq8aBNbg|c*Bi$hon=YN5W1%eZs>lh)dPix{Kj0T%gWuTB4 z4G?g87)>GIU>MCZ;9wXn9KgXaS~x(0VYF}jj3zopr0HWJ9hyVZp literal 0 HcmV?d00001 diff --git a/src/components/DesignForm/assembly/index.ts b/src/components/DesignForm/assembly/index.ts index e6fda85f0..30a93419b 100644 --- a/src/components/DesignForm/assembly/index.ts +++ b/src/components/DesignForm/assembly/index.ts @@ -246,6 +246,15 @@ const selectOption: any = [ control: { }, config: {} + }, + { + type: 'signaturemap', + label: '签名板', + icon: 'faedit', + iconFont: 'fa-edit', + control: { + }, + config: {} } ] }, diff --git a/src/components/DesignForm/public/form/formGroup.vue b/src/components/DesignForm/public/form/formGroup.vue index b3e12d574..01dd78689 100644 --- a/src/components/DesignForm/public/form/formGroup.vue +++ b/src/components/DesignForm/public/form/formGroup.vue @@ -426,6 +426,7 @@ onMounted(()=>{ + @@ -433,7 +434,7 @@ onMounted(()=>{ - + + diff --git a/src/views/sysworkflow/codepage/page.vue b/src/views/sysworkflow/codepage/page.vue index e019ffec0..c4290aa65 100644 --- a/src/views/sysworkflow/codepage/page.vue +++ b/src/views/sysworkflow/codepage/page.vue @@ -8,7 +8,7 @@ + \ No newline at end of file diff --git a/src/widget/videoupload/videoUploadPlay.vue b/src/widget/videoupload/videoUploadPlay.vue new file mode 100644 index 000000000..b1476f488 --- /dev/null +++ b/src/widget/videoupload/videoUploadPlay.vue @@ -0,0 +1,102 @@ + + + + + \ No newline at end of file From 4dff74a20349cd48dbb41e20717203f10f1d0332 Mon Sep 17 00:00:00 2001 From: liwenxuan <1298531568@qq.com> Date: Wed, 10 Jan 2024 08:19:44 +0800 Subject: [PATCH 03/11] =?UTF-8?q?=E8=A7=86=E9=A2=91=E7=BB=84=E4=BB=B6?= =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/store/modules/lowcodevideo.ts | 52 +++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) create mode 100644 src/store/modules/lowcodevideo.ts diff --git a/src/store/modules/lowcodevideo.ts b/src/store/modules/lowcodevideo.ts new file mode 100644 index 000000000..4b5d70079 --- /dev/null +++ b/src/store/modules/lowcodevideo.ts @@ -0,0 +1,52 @@ +//定义组合式API仓库 +import { defineStore } from "pinia"; +import { ref, computed,watch,reactive} from 'vue'; +type VideoMsg = { + CreatedAt: string + UpdatedAt: string + fileSize: bigint + id: bigint + key: string + name: string + physicspath: string + size: string + tag: string + type: number + url: string + } + /* type VideoObj = {} */ + + +//创建小仓库 +let uselowcodevideoStore = defineStore('lowcodevideo', () => { + + //视频地址 + const videoResource = ref(); + //是否上传成功 + const videoReady = ref(false); + //成功后接受的视频详细信息 + const videoMsg = reactive({ + CreatedAt: '', + UpdatedAt: '', + fileSize: 0n, + id: 0n, + key: '', + name: '', + physicspath: '', + size: '', + tag: '', + type: 0, + url: '' + }); + //表单视频信息数组 + /* const videoArr = reactive<> */ + + //务必要返回一个对象:属性与方法可以提供给组件使用 + return { + videoReady, + videoResource, + videoMsg, + } +}); + +export default uselowcodevideoStore; \ No newline at end of file From a244d70a5fb1abd60d3a446f73b8cd407d82c651 Mon Sep 17 00:00:00 2001 From: liwenxuan <1298531568@qq.com> Date: Wed, 10 Jan 2024 08:20:50 +0800 Subject: [PATCH 04/11] =?UTF-8?q?=E8=A7=86=E9=A2=91=E7=BB=84=E4=BB=B6?= =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/DesignForm/formControlAttr.vue | 74 ++++ src/views/knowledge/news/index.vue | 356 +----------------- src/widget/videoupload/videoUploadPlay.vue | 96 +---- 3 files changed, 83 insertions(+), 443 deletions(-) diff --git a/src/components/DesignForm/formControlAttr.vue b/src/components/DesignForm/formControlAttr.vue index 9e6d340d7..e185c890e 100644 --- a/src/components/DesignForm/formControlAttr.vue +++ b/src/components/DesignForm/formControlAttr.vue @@ -14,6 +14,10 @@ import { PublicAtrr } from '@/api/DesignForm/types' import { chineseToPinyin } from '@/api/DesignForm/requestapi' +import { uploadUrl } from '@/api/DesignForm' +import { UploadFilled } from '@element-plus/icons-vue' +import { UploadFile, UploadFiles } from 'element-plus/es/components/upload/src/upload'; + const props = withDefaults( //接收父级参数 defineProps<{ formData: any @@ -584,6 +588,14 @@ const attrList = computed(() => { path: 'config.componentName', vShow: ['component'] }, + { + label: '上传视频', + value: config.disabledAdd, + path: 'config.disabledAdd', + type: 'uploadvideo', + vIf: state.isSearch, + vHide: ['uploadvideo'] + }, { label: '上传地址', value: control.action, @@ -1206,6 +1218,53 @@ const isNotWrite = (val:any) =>{ } return false } + +//liwenxuan 20240108 vidioupload start +import uselowcodevideoStore from '@/store/modules/lowcodevideo' +const lowcodevideoStore = uselowcodevideoStore(); + +//const emits = defineEmits(["addedVideo"]); +//上传成功钩子 +function videoUploadOk(response: any, uploadFile: UploadFile, uploadFiles: UploadFiles) { + //更新pinia中的视频上传信息 + lowcodevideoStore.videoResource = response.data.url; + lowcodevideoStore.videoReady = true; + console.log(response) + console.log(lowcodevideoStore); + lowcodevideoStore.videoMsg.CreatedAt = response.data.CreatedAt; + lowcodevideoStore.videoMsg.UpdatedAt = response.data.UpdatedAt; + lowcodevideoStore.videoMsg.fileSize = response.data.fileSize; + lowcodevideoStore.videoMsg.id = response.data.id; + lowcodevideoStore.videoMsg.key = response.data.key; + lowcodevideoStore.videoMsg.name = response.data.name; + lowcodevideoStore.videoMsg.physicspath = response.data.physicspath; + lowcodevideoStore.videoMsg.size = response.data.size; + lowcodevideoStore.videoMsg.tag = response.data.tag; + lowcodevideoStore.videoMsg.type = response.data.type; + lowcodevideoStore.videoMsg.url = response.data.url; + //emits("addedVideo",videoArr) +} + +//删除钩子 禁止删除 +function beforeRemove(){ + return false; +} + +//上传失败钩子 +function videoUploadErr(error: Error, uploadFile: UploadFile, uploadFiles: UploadFiles){ + alert("上传失败,请重试") + console.log("上传失败"+error); + +} +//点击文件列表中已上传的文件时的钩子,点击即替换video标签的src +/* function selectVideo(uploadFile: UploadFile){ + + const res:any = uploadFile.response; + const resd = res.data; + const resdurl = resd.url; + lowcodevideoStore.videoResource = resdurl; +} */ +//liwenxuan 20240108 vidioupload end + \ No newline at end of file +} + diff --git a/src/widget/carousel/index.vue b/src/widget/carousel/index.vue index f99d79198..895a669e3 100644 --- a/src/widget/carousel/index.vue +++ b/src/widget/carousel/index.vue @@ -14,7 +14,7 @@ - + \ No newline at end of file From 3d9c023bd0f9bd7ac1987e226955dcb67aa3c938 Mon Sep 17 00:00:00 2001 From: liwenxuan <1298531568@qq.com> Date: Thu, 25 Jan 2024 10:35:42 +0800 Subject: [PATCH 11/11] =?UTF-8?q?=E8=BD=AE=E6=92=AD=E5=9B=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/DesignForm/assembly/index.ts | 7 +- src/components/DesignForm/formControlAttr.vue | 11 ++- src/widget/carousel/lowcodeCarousel.vue | 90 ++++++++++++++----- 3 files changed, 80 insertions(+), 28 deletions(-) diff --git a/src/components/DesignForm/assembly/index.ts b/src/components/DesignForm/assembly/index.ts index 96361afae..63b132672 100644 --- a/src/components/DesignForm/assembly/index.ts +++ b/src/components/DesignForm/assembly/index.ts @@ -350,7 +350,12 @@ const selectOption: any = [ imgSort:1, imgUrl: '', link: '' - }] + }], + config: { + carsuselWidth:448, + carsuselHeight:252, + interval:2000, + } }, config: {} } diff --git a/src/components/DesignForm/formControlAttr.vue b/src/components/DesignForm/formControlAttr.vue index 71124f3ea..355341119 100644 --- a/src/components/DesignForm/formControlAttr.vue +++ b/src/components/DesignForm/formControlAttr.vue @@ -2006,7 +2006,12 @@ const changeCurrentUploadImgid = (clickedRow:any) => { - + +
+ 轮播图宽度(像素): + 轮播图高度(像素): + 切图间隔(毫秒): +
@@ -2040,7 +2045,7 @@ const changeCurrentUploadImgid = (clickedRow:any) => { - +