From dd1c85f36b3120d0031ce28145d55c94ee848c25 Mon Sep 17 00:00:00 2001 From: 26947 <12@1> Date: Tue, 4 Jun 2024 18:57:45 +0800 Subject: [PATCH 1/5] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E6=B4=BB=E5=8A=A8?= =?UTF-8?q?=E5=8F=91=E5=B8=83=E9=A1=B5=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- config.js | 4 +- main.js | 1 + package.json | 1 + pages.json | 8 ++ pages/activity/publish.vue | 174 +++++++++++++++++++++++++ pages/common/activityList/index.vue | 6 + pages/common/file/fileUpload/index.vue | 9 +- pages/index.vue | 11 +- pages/loginInfo/login.vue | 2 +- pages/work/index.vue | 3 + store/modules/user.js | 2 +- 11 files changed, 212 insertions(+), 9 deletions(-) create mode 100644 pages/activity/publish.vue diff --git a/config.js b/config.js index c724aeb..1692a89 100644 --- a/config.js +++ b/config.js @@ -4,8 +4,8 @@ export default { uploadQiNiuDomain: 'https://upload-z2.qiniup.com', // baseUrl: 'https://vue.ruoyi.vip/prod-api', // baseUrl: 'http://47.93.242.168:8080', - baseUrl: 'http://47.93.242.168:8080', - // baseUrl: 'http://localhost:8080', + // baseUrl: 'http://47.93.242.168:8080', + baseUrl: 'http://localhost:8080', // 应用信息 appInfo: { // 应用名称 diff --git a/main.js b/main.js index c6877c5..3ff3274 100644 --- a/main.js +++ b/main.js @@ -12,6 +12,7 @@ export function createApp() { app.config.globalProperties.iconConfig = iconConfig app.use(uviewPlus) app.use(store) + // app.use(uView) install(app) return { diff --git a/package.json b/package.json index 7cf09d4..0927339 100644 --- a/package.json +++ b/package.json @@ -22,6 +22,7 @@ "dayjs": "^1.11.11", "qiniu": "^7.12.0", "qiniu-js": "^3.4.2", + "quill": "^1.3.7", "uview-plus": "^3.2.15" } } diff --git a/pages.json b/pages.json index aa77fb1..6fb4db7 100644 --- a/pages.json +++ b/pages.json @@ -56,6 +56,14 @@ "navigationBarTextStyle": "white" } } + , { + "path": "pages/activity/publish", + "style": { + "navigationBarTitleText": "发布活动", + "navigationStyle": "custom", + "navigationBarTextStyle": "white" + } + } , { "path": "pages/work/index", "style": { diff --git a/pages/activity/publish.vue b/pages/activity/publish.vue new file mode 100644 index 0000000..e1c92e0 --- /dev/null +++ b/pages/activity/publish.vue @@ -0,0 +1,174 @@ + + + \ No newline at end of file diff --git a/pages/common/activityList/index.vue b/pages/common/activityList/index.vue index 604a63d..05f81c7 100644 --- a/pages/common/activityList/index.vue +++ b/pages/common/activityList/index.vue @@ -43,6 +43,12 @@ import { useStore } from 'vuex'; const emit = defineEmits(['scrolltolower']); const { proxy } = getCurrentInstance(); +const iconConfig = proxy.iconConfig; +const tu21 = iconConfig.tu21; +const tu22 = iconConfig.tu22; +const tu51 = iconConfig.tu51; +const tu52 = iconConfig.tu52; +const tu53 = iconConfig.tu53; const props = defineProps({ modelValue: Array }); diff --git a/pages/common/file/fileUpload/index.vue b/pages/common/file/fileUpload/index.vue index 05079d9..b881eb6 100644 --- a/pages/common/file/fileUpload/index.vue +++ b/pages/common/file/fileUpload/index.vue @@ -113,6 +113,7 @@ const afterRead = async (event) => { }; const uploadFilePromise = async (fileInfo1, name) => { + console.log("fileInfo1:",fileInfo1); // 主要目的的拼名字,大小,类型 let fileNameOld = [0, 1]; if (fileInfo1.name !== undefined) { @@ -122,12 +123,14 @@ const uploadFilePromise = async (fileInfo1, name) => { fileInfo.name = fileNameOld[0] + "_" + store.state.user.phoneType + "_" + name; let extension1 = fileInfo1.url.split('.'); + // 防止 h5 报错 - if (extension1[1] == null) { - extension1[1] = fileNameOld[1]; + if (extension1[1] === undefined) { + extension1[1] = fileNameOld[fileNameOld.length-1]; //保证取最后一个 } //主要是为了拼接文件type(video/mp4),因为各端传入的type各有不同 - fileInfo.type = fileInfo1.type + "/" + extension1[1]; + fileInfo.type = fileInfo1.type + "/" + extension1[extension1.length-1]; + console.log("fileInfo.type:",fileInfo); fileInfo.extension = extension1[1]; try { const tokenData = await getQNtoken(fileInfo); diff --git a/pages/index.vue b/pages/index.vue index ab30ab4..1324aa2 100644 --- a/pages/index.vue +++ b/pages/index.vue @@ -10,7 +10,7 @@ - {{item}} + {{item.lable}} @@ -239,7 +239,7 @@ lefther: 0, searchPrerequisite: '热门', postTypeOpen: false, - postTypeList: ['发布话题', '发布活动'], + postTypeList: [{lable:'发布话题',id:1}, {lable:'发布活动',id:2}], bgColor: 'rgba(170, 0, 0, 0)', searchPrerequisiteList: [ '热门', '最新', '筛选3', '筛选4', '筛选5', '筛选6', '筛选7', '筛选8', '筛选9' @@ -362,6 +362,13 @@ console.log() this.$tab.navigateTo('/pages/search/index') }, + publishTalk(item){ + console.log() + if(item.id === 2){ + this.$tab.navigateTo('/pages/activity/publish') + } + + }, rightClick() { console.log('rightClick'); }, diff --git a/pages/loginInfo/login.vue b/pages/loginInfo/login.vue index a68802d..61b5425 100644 --- a/pages/loginInfo/login.vue +++ b/pages/loginInfo/login.vue @@ -85,7 +85,7 @@ const loginSuccess = async () => { await store.dispatch('GetInfo') await store.dispatch('getQNDomainInfo') proxy.$tab.reLaunch('/pages/index'); - // await store.dispatch('GetUserInfo'); + store.dispatch('GetUserInfo'); } catch (error) { console.log("获取用户信息失败", error) } diff --git a/pages/work/index.vue b/pages/work/index.vue index 4d36ed7..dc2b817 100644 --- a/pages/work/index.vue +++ b/pages/work/index.vue @@ -79,10 +79,13 @@ + + + + diff --git a/pages/Friend/messagenotification.vue b/pages/Friend/messagenotification.vue new file mode 100644 index 0000000..2c70a35 --- /dev/null +++ b/pages/Friend/messagenotification.vue @@ -0,0 +1,14 @@ + + + + + + diff --git a/pages/common/navbar/navbar.css b/pages/common/navbar/navbar.css new file mode 100644 index 0000000..ccc2f35 --- /dev/null +++ b/pages/common/navbar/navbar.css @@ -0,0 +1,13 @@ +:deep(.uni-nav-bar-text.data-v-26544265) { + font-size: 36rpx; + font-weight: 600; +} + +:deep(.uni-icons) { + font-family: uniicons; + text-decoration: none; + text-align: center; + width: 31rpx; + height: 44rpx; + line-height: 44rpx; +} \ No newline at end of file diff --git a/pages/common/navbar/navbar_nead.vue b/pages/common/navbar/navbar_nead.vue new file mode 100644 index 0000000..b5d4786 --- /dev/null +++ b/pages/common/navbar/navbar_nead.vue @@ -0,0 +1,43 @@ + + + + + \ No newline at end of file diff --git a/pages/signln/exchangemall.vue b/pages/signln/exchangemall.vue new file mode 100644 index 0000000..a51550c --- /dev/null +++ b/pages/signln/exchangemall.vue @@ -0,0 +1,214 @@ + + + + + + \ No newline at end of file diff --git a/pages/signln/exdetail.vue b/pages/signln/exdetail.vue new file mode 100644 index 0000000..9e300d0 --- /dev/null +++ b/pages/signln/exdetail.vue @@ -0,0 +1,36 @@ + + + + + + \ No newline at end of file diff --git a/pages/signln/signid.vue b/pages/signln/signid.vue new file mode 100644 index 0000000..c4dc29a --- /dev/null +++ b/pages/signln/signid.vue @@ -0,0 +1,451 @@ + + + + + + + + + \ No newline at end of file diff --git a/pages/signln/signiddetails.vue b/pages/signln/signiddetails.vue index ca62781..d3c9c96 100644 --- a/pages/signln/signiddetails.vue +++ b/pages/signln/signiddetails.vue @@ -1,6 +1,7 @@ + diff --git a/permission.js b/permission.js index 240b684..805fa42 100644 --- a/permission.js +++ b/permission.js @@ -1,41 +1,42 @@ -import { getToken } from '@/utils/auth' +import { getToken } from "@/utils/auth"; // 登录页面 -const loginPage = "/pages/loginInfo/login" - +const loginPage = "/pages/loginInfo/login"; + // 页面白名单 const whiteList = [ - '/pages/loginInfo/login', '/pages/register', '/pages/common/webview/index' -] + "/pages/loginInfo/login", + "/pages/register", + "/pages/common/webview/index", +]; // 检查地址白名单 function checkWhite(url) { - const path = url.split('?')[0] - return whiteList.indexOf(path) !== -1 + const path = url.split("?")[0]; + return whiteList.indexOf(path) !== -1; } // 页面跳转验证拦截器 -let list = ["navigateTo", "redirectTo", "reLaunch", "switchTab"] -list.forEach(item => { - uni.addInterceptor(item, { - invoke(to) { - - if (getToken()) { - if (to.url === loginPage) { - console.log("to:",to); - uni.reLaunch({ url: "/" }) - } - return true - } else { - if (checkWhite(to.url)) { - return true - } - uni.reLaunch({ url: loginPage }) - return false - } - }, - fail(err) { - console.log("错误信息:",err) - } - }) -}) \ No newline at end of file +let list = ["navigateTo", "redirectTo", "reLaunch", "switchTab"]; +// list.forEach((item) => { +// uni.addInterceptor(item, { +// invoke(to) { +// if (getToken()) { +// if (to.url === loginPage) { +// console.log("to:", to); +// uni.reLaunch({ url: "/" }); +// } +// return true; +// } else { +// if (checkWhite(to.url)) { +// return true; +// } +// uni.reLaunch({ url: loginPage }); +// return false; +// } +// }, +// fail(err) { +// console.log("错误信息:", err); +// }, +// }); +// }); diff --git a/utils/icon/icon.js b/utils/icon/icon.js index 2709241..5caef50 100644 --- a/utils/icon/icon.js +++ b/utils/icon/icon.js @@ -9,10 +9,14 @@ const tu51 = ref(QNDomain + "home/icon/image/png/tu5-1_20240601124004353.png") const tu52 = ref(QNDomain + "home/icon/image/png/tu5-2_20240601124010403.png") const tu53 = ref(QNDomain + "home/icon/image/png/tu5-3_20240601124016641.png") const tu23 = ref(QNDomain + "home/icon/image/png/tu2-3_20240602093303793.png") +//文件上传 const tu2x = ref(QNDomain + "home/icon/image/png/添加图片@2x_20240603101717136.png") - +//话题发布-等待审核 +const sh2x = ref(QNDomain + "home/icon/image/png/等待审核@2x_20240604202431502.png") +const sh2x1 = ref(QNDomain + "home/icon/image/png/等待审核@2x1_20240604202431492.png") export default { tu21,tu22,tu23,tu2x, - tu51,tu52,tu53 + tu51,tu52,tu53, + sh2x,sh2x1 } \ No newline at end of file From c5483524a9b2e4f4262ef9306e2454ed07c6b9a6 Mon Sep 17 00:00:00 2001 From: 26947 <12@1> Date: Tue, 4 Jun 2024 22:03:27 +0800 Subject: [PATCH 5/5] =?UTF-8?q?=E4=BF=AE=E6=94=B9pages?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages.json | 24 +++++++++--------------- 1 file changed, 9 insertions(+), 15 deletions(-) diff --git a/pages.json b/pages.json index e7516fb..906021f 100644 --- a/pages.json +++ b/pages.json @@ -8,6 +8,14 @@ } }, "pages": [ + { + "path": "pages/index", + "style": { + "navigationBarTitleText": "若依移动端框架", + "navigationStyle": "custom", + "navigationBarTextStyle": "white" + } + }, { "path" : "pages/signln/signid", "style" : @@ -41,14 +49,7 @@ } }, - { - "path": "pages/index", - "style": { - "navigationBarTitleText": "若依移动端框架", - "navigationStyle": "custom", - "navigationBarTextStyle": "white" - } - }, + { "path": "pages/common/talkState/publish", "style": { @@ -74,14 +75,7 @@ } }, - { - "path": "pages/signln/signiddetails", - "style": { - "navigationBarTitleText": "签到明细", - "navigationStyle": "custom" - } - }, {