From 6b033a00948b6a14637601dc3ccdf94fd7561074 Mon Sep 17 00:00:00 2001 From: YWQ HK IX <568170040@qq.com> Date: Sat, 27 May 2023 00:34:17 +0800 Subject: [PATCH] =?UTF-8?q?=E6=88=91=E7=9A=84=E8=A7=86=E9=A2=91=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E4=BC=98=E5=8C=96=EF=BC=8C=E6=96=B0=E5=A2=9E=E5=88=86?= =?UTF-8?q?=E9=A1=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/apis/createVideo.js | 27 +- src/apis/myCreating.js | 7 +- src/lang/package/en.ts | 3 + src/lang/package/zh-cn.ts | 3 + src/layout/index.vue | 3 +- src/types/components.d.ts | 6 + src/views/createVideo/index.vue | 52 ++-- src/views/myCreating/index.vue | 439 +++++++++++++++++++------------ yarn.lock | 453 -------------------------------- 9 files changed, 330 insertions(+), 663 deletions(-) diff --git a/src/apis/createVideo.js b/src/apis/createVideo.js index 2911ccd..455128a 100644 --- a/src/apis/createVideo.js +++ b/src/apis/createVideo.js @@ -1,22 +1,39 @@ import request from "@/utils/request.js"; +/** + * @description 获取人脸列表 + * @params pageNum, pageSize + * @returns data + */ +export function personPhotoList(pageNum, pageSize) { + return request({ + url: `api/personPhoto/list?pageNum=${pageNum}&pageSize=${pageSize}`, + method: 'get' + }) +} + /** * @description 上传图片 - * @params ticket + * @params data * @returns data */ -export function awsImgUpload(formData) { +export function awsImgUpload(data) { return request({ url: `/api/upload/awsImgUpload`, method: 'post', - data: formData + data }) } -export function awsMp3Upload(formData) { +/** + * @description 上传视频 + * @params data + * @returns data + */ +export function videoUpload(data) { return request({ url: `api/video/upload`, method: 'post', - data: formData + data }) } \ No newline at end of file diff --git a/src/apis/myCreating.js b/src/apis/myCreating.js index 5f8e2da..c6317f9 100644 --- a/src/apis/myCreating.js +++ b/src/apis/myCreating.js @@ -1,15 +1,14 @@ import request from "@/utils/request.js"; -const baseURL = import.meta.env.VITE_APP_BASE_API /** * @description 获取我的视频作品 - * @params pageSize,pageNum + * @params pageNum, pageSize * @returns data */ -export function userPhotoVideoList(pageSize, pageNum, title) { +export function userPhotoVideoList(pageNum, pageSize, title) { return request({ - url: `/api/userPhotoVideo/list?pageSize=${pageSize}&pageNum=${pageNum}&title=${title}`, + url: `/api/userPhotoVideo/list?pageNum=${pageNum}&pageSize=${pageSize}&title=${title}`, method: 'get' }) } diff --git a/src/lang/package/en.ts b/src/lang/package/en.ts index 5a7090c..54f5b60 100644 --- a/src/lang/package/en.ts +++ b/src/lang/package/en.ts @@ -31,6 +31,7 @@ export default { // 创作视频 createVideo: { title: "CreateVideo", + availableMould:"Available Moulds", typeScript: "Type your Script", uploadAudio: "Upload Audio", aiScript: "Ai Script", @@ -55,6 +56,8 @@ export default { download: "Download", delete: "Delete", more: "More", + noList:"Nothing here. How about making one ?", + goCreate:"Go Create !", draft: "Draft", generating: "Generating", generationFailed: "Failed", diff --git a/src/lang/package/zh-cn.ts b/src/lang/package/zh-cn.ts index 84736c5..01bdd71 100644 --- a/src/lang/package/zh-cn.ts +++ b/src/lang/package/zh-cn.ts @@ -31,6 +31,7 @@ export default { // 创作视频 createVideo: { title: "创作视频", + availableMould:"可用模板", typeScript: "输入文案", uploadAudio: "上传音频", aiScript: "AI生成文本", @@ -55,6 +56,8 @@ export default { download: "下载", delete: "删除", more: "更多", + noList:"暂无没有作品哦,快去尝试制作你的第一个视频吧!", + goCreate:"去创作", draft: "草稿", generating: "生成中", generationFailed: "生成失败", diff --git a/src/layout/index.vue b/src/layout/index.vue index 1c95584..a6692c9 100644 --- a/src/layout/index.vue +++ b/src/layout/index.vue @@ -98,8 +98,7 @@ onMounted(() => {}); position: relative; width: 100%; height: 100%; - - &.mobile.openSidebar { + e &.mobile.openSidebar { position: fixed; top: 0; } diff --git a/src/types/components.d.ts b/src/types/components.d.ts index ee70419..924a107 100644 --- a/src/types/components.d.ts +++ b/src/types/components.d.ts @@ -11,6 +11,7 @@ declare module '@vue/runtime-core' { ElBreadcrumb: typeof import('element-plus/es')['ElBreadcrumb'] ElBreadcrumbItem: typeof import('element-plus/es')['ElBreadcrumbItem'] ElButton: typeof import('element-plus/es')['ElButton'] + ElDialog: typeof import('element-plus/es')['ElDialog'] ElDivider: typeof import('element-plus/es')['ElDivider'] ElDropdown: typeof import('element-plus/es')['ElDropdown'] ElDropdownItem: typeof import('element-plus/es')['ElDropdownItem'] @@ -20,6 +21,7 @@ declare module '@vue/runtime-core' { ElIcon: typeof import('element-plus/es')['ElIcon'] ElInput: typeof import('element-plus/es')['ElInput'] ElOption: typeof import('element-plus/es')['ElOption'] + ElPagination: typeof import('element-plus/es')['ElPagination'] ElRow: typeof import('element-plus/es')['ElRow'] ElScrollbar: typeof import('element-plus/es')['ElScrollbar'] ElSelect: typeof import('element-plus/es')['ElSelect'] @@ -32,10 +34,14 @@ declare module '@vue/runtime-core' { IconSelect: typeof import('./../components/IconSelect/index.vue')['default'] IEpCaretBottom: typeof import('~icons/ep/caret-bottom')['default'] IEpClose: typeof import('~icons/ep/close')['default'] + IEpDelete: typeof import('~icons/ep/delete')['default'] + IEpDownload: typeof import('~icons/ep/download')['default'] IEpEdit: typeof import('~icons/ep/edit')['default'] IEpGoods: typeof import('~icons/ep/goods')['default'] IEpMenu: typeof import('~icons/ep/menu')['default'] + IEpSearch: typeof import('~icons/ep/search')['default'] IEpSetting: typeof import('~icons/ep/setting')['default'] + IEpVideoPlay: typeof import('~icons/ep/video-play')['default'] LangSelect: typeof import('./../components/LangSelect/index.vue')['default'] MultiUpload: typeof import('./../components/Upload/MultiUpload.vue')['default'] Pagination: typeof import('./../components/Pagination/index.vue')['default'] diff --git a/src/views/createVideo/index.vue b/src/views/createVideo/index.vue index 99f1c83..6a2b0ac 100644 --- a/src/views/createVideo/index.vue +++ b/src/views/createVideo/index.vue @@ -61,15 +61,12 @@
-
-
-
Generate By Ai
-
-
+
{{ $t("createVideo.availableMould") }}:
+
@@ -263,24 +260,23 @@