Commit 696bcb40 by 李伟康

Merge branch 'v1.0.1' of http://192.168.3.233:8090/glsx/gl_tape into v1.0.1

2 parents e4d87c18 1c55c877
<template>
<uni-popup ref="tips" type="center" :is-mask-click="false" :animation="false">
<view class="tips-wrapper">
<view class="tips-content">
<view class="tips-title"
>{{ title }}
<view class="icon-close" @click="close">×</view>
</view>
<view class="tips-text">{{ content }}</view>
</view>
<view class="tips-footer">
<view class="tips-btn close" @click="close()">{{ cancelBtnText }}</view>
<view class="tips-btn preview" @click="confirm()">{{
confirmBtnText
}}</view>
</view>
</view>
</uni-popup>
</template>
<script>
export default {
name: "MessageBox",
data() {
return {};
},
props: {
title: {
type: String,
default: "提示",
},
content: {
type: String,
default: "提示",
},
confirmBtnText: {
type: String,
default: "确定",
},
cancelBtnText: {
type: String,
default: "取消",
},
},
mounted() {
this.$refs.tips.open("center");
},
methods: {
close() {
this.$refs.tips.close();
this.$emit("cancel");
},
confirm() {
this.$refs.tips.close();
this.$emit("confirm");
},
},
};
</script>
<style scoped lang="scss">
.tips-wrapper {
width: 704rpx;
height: 372rpx;
background: #ffffff;
border-radius: 20rpx;
.tips-content {
padding: 48rpx;
border-bottom: 1px solid #e8e8e8;
.tips-title {
position: relative;
width: 100%;
font-weight: 500;
font-size: 32rpx;
color: #292d33;
text-align: center;
.icon-close {
position: absolute;
right: 0;
top: -24rpx;
width: 160rpx;
font-size: 50rpx;
text-align: right;
padding-right: 20rpx;
line-height: 96rpx;
}
}
}
.tips-text {
font-size: 30rpx;
color: #5a5e66;
letter-spacing: 1rpx;
text-align: center;
line-height: 40rpx;
margin-top: 48rpx;
}
.tips-footer {
display: flex;
align-items: center;
justify-content: center;
height: 100rpx;
.close {
color: #6c6c70;
}
.preview {
color: #2c66f7;
}
}
.tips-btn {
width: 50%;
text-align: center;
font-size: 32rpx;
text-align: center;
line-height: 44rpx;
}
}
</style>
......@@ -5,9 +5,11 @@ import store from "@/store";
import api from "./api/index";
import { Storage } from "./utils/cache/index";
import GlsxImage from "./components/GlsxImage";
import wnCanvas from './components/Canvas/wn-canvas'
import MessageBox from "./components/MessageBox/index";
Vue.component("GlsxImage", GlsxImage);
Vue.component('wnCanvas', wnCanvas)
Vue.component("MessageBox", MessageBox);
import wnCanvas from "./components/Canvas/wn-canvas";
Vue.component("wnCanvas", wnCanvas);
uni.$api = api;
uni.$storage = new Storage();
Vue.config.productionTip = false;
......
......@@ -2,8 +2,8 @@
* @Description: 首页
* @Author: huyue
* @Date: 2024-04-07 14:39:40
* @LastEditors: huyue
* @LastEditTime: 2024-04-08 19:37:16
* @LastEditors: 前端 qianduan01@didihu.com.cn
* @LastEditTime: 2024-04-09 14:37:11
-->
<template>
<view class="container">
......@@ -61,28 +61,13 @@
</view>
</view>
<!-- 未点击开始接待,弹窗 -->
<uni-popup
ref="tips"
type="center"
:is-mask-click="false"
:animation="false"
>
<view class="tips-wrapper">
<view class="tips-content">
<view class="tips-title"
>提示
<view class="icon-close" @click="close">×</view>
</view>
<view class="tips-text"
>直接点击素材可进行预览,若面向车辆主展示,请点击页面下方的「开始接待」</view
>
</view>
<view class="tips-footer">
<view class="tips-btn close" @click="close()">取消</view>
<view class="tips-btn preview" @click="preview()">预览素材</view>
</view>
</view>
</uni-popup>
<MessageBox
v-if="messageBoxVisible"
@cancel="cancel"
@confirm="preview"
content="直接点击素材可进行预览,若面向车辆主展示,请点击页面下方的「开始接待」"
confirmBtnText="预览"
></MessageBox>
</view>
</view>
</template>
......@@ -92,6 +77,7 @@ export default {
mixins: [myClick],
data() {
return {
messageBoxVisible: false,
moduleList: [
// {
// id: 1,
......@@ -103,7 +89,7 @@ export default {
// },
],
userInfo: {},
id:''
id: "",
};
},
onLoad(options) {
......@@ -123,8 +109,8 @@ export default {
},
// 退出
logout() {
uni.$storage.rm('userInfo')
uni.$storage.rm('sessionId')
uni.$storage.rm("userInfo");
uni.$storage.rm("sessionId");
this.stopAudio();
uni.reLaunch({
url: "/pages/common/login",
......@@ -136,19 +122,19 @@ export default {
url: `../detail/detail?id=${item.id}&type=edit`,
});
} else {
this.id = item.id
this.$refs.tips.open("center");
this.id = item.id;
this.messageBoxVisible = true;
}
},
close() {
this.$refs.tips.close();
cancel() {
this.messageBoxVisible = false;
},
preview() {
let {id} = this
let { id } = this;
uni.navigateTo({
url: `../detail/detail?type=preview&id=${id}`,
});
this.close()
this.messageBoxVisible = false;
},
},
};
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!