update
This commit is contained in:
parent
fd6d35b044
commit
75e60a734c
@ -57,11 +57,13 @@ Vue.prototype.$clipboard = clipboard
|
|||||||
Vue.prototype.$md5 = md5
|
Vue.prototype.$md5 = md5
|
||||||
Vue.use(wxShare)
|
Vue.use(wxShare)
|
||||||
Vue.use(CanvasPoster)
|
Vue.use(CanvasPoster)
|
||||||
import { RadioGroup, Radio, AddressEdit } from 'vant'
|
import { RadioGroup, Radio, AddressEdit, Icon, Loading } from 'vant'
|
||||||
Vue.use(AddressEdit)
|
Vue.use(AddressEdit)
|
||||||
Vue.use(Radio)
|
Vue.use(Radio)
|
||||||
Vue.use(RadioGroup)
|
Vue.use(RadioGroup)
|
||||||
|
|
||||||
|
Vue.use(Icon)
|
||||||
|
Vue.use(Loading)
|
||||||
var i18n = new VueI18n({
|
var i18n = new VueI18n({
|
||||||
locale: localStorage.getItem('locale') || 'zh',
|
locale: localStorage.getItem('locale') || 'zh',
|
||||||
messages: {
|
messages: {
|
||||||
|
|||||||
@ -99,16 +99,12 @@ class="activity-item"
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { nextTick } from 'vue' // 注意:Vue 2 中通常不需要从 vue 导入 nextTick,直接使用 this.$nextTick
|
|
||||||
import html2canvas from 'html2canvas'
|
import html2canvas from 'html2canvas'
|
||||||
import { ImagePreview, Icon, Loading } from 'vant'
|
import { ImagePreview } from 'vant'
|
||||||
import { $toastText, $toastSuccess, $toastLoading, $toastClear } from '@/config/toast'
|
import { $toastText, $toastSuccess, $toastLoading, $toastClear } from '@/config/toast'
|
||||||
import requestApp from '@/utils/request'
|
import requestApp from '@/utils/request'
|
||||||
import QRCode from 'qrcode'
|
import QRCode from 'qrcode'
|
||||||
import Vue from 'vue'
|
|
||||||
|
|
||||||
Vue.use(Icon)
|
|
||||||
Vue.use(Loading)
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'ActivityPoster',
|
name: 'ActivityPoster',
|
||||||
@ -237,7 +233,9 @@ export default {
|
|||||||
|
|
||||||
async generatePoster() {
|
async generatePoster() {
|
||||||
try {
|
try {
|
||||||
|
console.log(this.selectedActivity, 'pp--')
|
||||||
if (!this.selectedActivity) {
|
if (!this.selectedActivity) {
|
||||||
|
console.log('fd')
|
||||||
$toastText('请先选择活动!')
|
$toastText('请先选择活动!')
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -271,7 +269,9 @@ export default {
|
|||||||
$toastText('生成海报失败,请重试!')
|
$toastText('生成海报失败,请重试!')
|
||||||
} finally {
|
} finally {
|
||||||
this.isGenerating = false
|
this.isGenerating = false
|
||||||
|
setTimeout(() => {
|
||||||
$toastClear()
|
$toastClear()
|
||||||
|
}, 3000)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -728,6 +728,7 @@ img {
|
|||||||
padding: 20px;
|
padding: 20px;
|
||||||
box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
|
box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
|
||||||
transition: all 0.3s;
|
transition: all 0.3s;
|
||||||
|
box-sizing: border-box;
|
||||||
}
|
}
|
||||||
|
|
||||||
.preview-header {
|
.preview-header {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user