Commit e991348b authored by wangwei's avatar wangwei

首次编写打包

parent 36f56fe3
......@@ -7,5 +7,6 @@ module.exports = merge(prodEnv, {
API_URL: '"/"',
MAX_FILESIZE:'1024*1024*10',
IMAGE_URL_HEAD:'"http://cdn.singsingenglish.com/"',
INVITE_URL:'"http://wechat.test.singsingenglish.com"',
AUTHOR_UEL:'"https://wechat_test.changchangenglish.com/api/client/login"',
REDIRECT_URL:'"http://localhost:8085/"',
});
......@@ -4,4 +4,5 @@ module.exports = {
IMAGE_URL_HEAD:'"http://cdn.singsingenglish.com/"',
API_URL: '"/"',
MAX_FILESIZE:'1024*1024*10',
AUTHOR_UEL:'"https://wechat_test.changchangenglish.com/api/client/login"'
}
......@@ -7,4 +7,5 @@ module.exports = merge(prodEnv, {
IMAGE_URL_HEAD:'"http://cdn.singsingenglish.com/"',
API_URL: '"/"',
MAX_FILESIZE:'1024*1024*10',
AUTHOR_UEL:'"https://wechat_test.changchangenglish.com/api/client/login"'
})
......@@ -2,8 +2,9 @@
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1.0">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no" />
<title>唱唱启蒙英语</title>
<link rel="stylesheet" href="https://at.alicdn.com/t/font_822651_udxjxcaax8f.css">
</head>
<body>
<div id="app"></div>
......
This diff is collapsed.
<template>
<div id="app">
<img src="./assets/logo.png">
<router-view/>
</div>
</template>
......@@ -13,11 +12,20 @@ export default {
<style>
#app {
font-family: 'Avenir', Helvetica, Arial, sans-serif;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
text-align: center;
color: #2c3e50;
margin-top: 60px;
font-family: "Helvetica Neue",
Helvetica,
"PingFang SC",
"Hiragino Sans GB",
"Microsoft YaHei",
"微软雅黑",
Arial,
sans-serif;
}
html,body{
height: 100%;
}
*{
margin: auto;
padding: auto;
}
</style>
<template>
<div class="hello">
<h1>{{ msg }}</h1>
<h2>Essential Links</h2>
<ul>
<li>
<a
href="https://vuejs.org"
target="_blank"
>
Core Docs
</a>
</li>
<li>
<a
href="https://forum.vuejs.org"
target="_blank"
>
Forum
</a>
</li>
<li>
<a
href="https://chat.vuejs.org"
target="_blank"
>
Community Chat
</a>
</li>
<li>
<a
href="https://twitter.com/vuejs"
target="_blank"
>
Twitter
</a>
</li>
<br>
<li>
<a
href="http://vuejs-templates.github.io/webpack/"
target="_blank"
>
Docs for This Template
</a>
</li>
</ul>
<h2>Ecosystem</h2>
<ul>
<li>
<a
href="http://router.vuejs.org/"
target="_blank"
>
vue-router
</a>
</li>
<li>
<a
href="http://vuex.vuejs.org/"
target="_blank"
>
vuex
</a>
</li>
<li>
<a
href="http://vue-loader.vuejs.org/"
target="_blank"
>
vue-loader
</a>
</li>
<li>
<a
href="https://github.com/vuejs/awesome-vue"
target="_blank"
>
awesome-vue
</a>
</li>
</ul>
</div>
</template>
<script>
export default {
name: 'HelloWorld',
data () {
return {
msg: 'Welcome to Your Vue.js App'
}
}
}
</script>
<!-- Add "scoped" attribute to limit CSS to this component only -->
<style scoped>
h1, h2 {
font-weight: normal;
}
ul {
list-style-type: none;
padding: 0;
}
li {
display: inline-block;
margin: 0 10px;
}
a {
color: #42b983;
}
</style>
<template>
<div class="address">
<!--地址选择组件-->
<mt-popup v-model="show" position="bottom" :closeOnClickModal="closeOnClickModal">
<section style="width:100%; height: 100%;">
<div class="padding">
<span @click="hidePicker">取消</span>
<span @click="saveAddress" class="float-right">完成</span>
</div>
<mt-picker :slots="slots" @change="onValuesChange"></mt-picker>
</section>
</mt-popup>
</div>
</template>
<script>
import Address from './addr.js'
let type = 1
let provinceValue = 2
let cityValue = 52
//根据apid查找对象
function findcity(item) {
return item.type == type;
}
//根据aname获取名字
function getAddressName(item) {
return item.label
}
//根据aname获取children
function getAddressChildren(item) {
return item.children
}
// 根据label获取对象
function findObj (list, label) {
let filtered = list.filter((item) => {
return item.label === label
})
return filtered[0]
}
// 根据value获取list中的children
function findChildren(list, value) {
let filtered = list.filter((item) => {
return item.value === value
})
return filtered[0].children
}
//筛选出各省级对象
let pObj = Address.filter(findcity)
//获取各省级对象名字
let provinces = pObj.map(getAddressName)
// 根据省级value获取各市对象
let citiesObj = findChildren(pObj, provinceValue)
let cities = citiesObj.map(getAddressName)
let countriesObj = findChildren(citiesObj, cityValue)
let countries = countriesObj.map(getAddressName)
export default {
name: 'address',
props: {
showAddressPicker: Boolean,
init: String
},
created() {
if (this.init) {
this.initVal = this.init
}
this.initAddress()
},
mounted() {
let vm = this
vm.show = vm.showAddressPicker
},
data() {
return {
slots: [{
flex: 1,
values: [],
className: 'slot1',
textAlign: 'center',
defaultIndex: 3
}, {
divider: true,
content: '-',
className: 'slot2'
}, {
flex: 1,
values: [],
className: 'slot3',
textAlign: 'center'
}, {
divider: true,
content: '-',
className: 'slot4',
defaultIndex: 0
}, {
flex: 1,
values: [],
className: 'slot5',
textAlign: 'center',
defaultIndex: 0
}],
addressValue: '',
addressValueCode: '',
disableClear: true,
show: true,
initVal: '北京-北京-东城区',
closeOnClickModal: false
}
},
watch: {
showAddressPicker(old, val) {
this.show = !val
},
init(val) {
this.initVal = val
this.initAddress()
}
},
methods: {
saveAddress() { //保存所选地区
let vm = this
vm.show = false
vm.$emit('save-address', vm.addressValue, vm.addressValueCode);
},
hidePicker() { // 取消选择
this.$emit('hide-picker', false);
},
initAddress() { //初始化地址组件
let vm = this
let initAddress = vm.initVal.split("-")
let defaultIndex0 = pObj.findIndex((obj)=>{
return obj.label === initAddress[0]
});
vm.slots[0].values = provinces
vm.slots[0].defaultIndex = defaultIndex0
let tempCitiesObj = pObj[defaultIndex0].children
let defaultIndex1 = tempCitiesObj.findIndex((obj)=>{
return obj.label === initAddress[1]
});
vm.slots[2].values = tempCitiesObj.map(getAddressName)
vm.slots[2].defaultIndex = defaultIndex1
let tempCountriesObj = tempCitiesObj[defaultIndex1].children
let defaultIndex2 = tempCountriesObj.findIndex((obj)=>{
return obj.label === initAddress[2]
});
vm.slots[4].values = tempCountriesObj.map(getAddressName)
vm.slots[4].defaultIndex = defaultIndex2
vm.addressValue = vm.slots[0].values[vm.slots[0].defaultIndex] +
"-" + vm.slots[2].values[vm.slots[2].defaultIndex] +
"-" + vm.slots[4].values[vm.slots[4].defaultIndex]
},
onValuesChange(picker, values) {
let vm = this
let valueCodes = []
let defaultIndex0 = pObj.findIndex((obj)=>{
return obj.label === values[0]
});
if(defaultIndex0 > -1){
vm.slots[0].defaultIndex = defaultIndex0
valueCodes[0] = pObj[defaultIndex0].value
let tempCitiesObj = pObj[defaultIndex0].children
vm.slots[2].values = tempCitiesObj.map(getAddressName)
let defaultIndex1 = tempCitiesObj.findIndex((obj)=>{
return obj.label === values[1]
})
if(defaultIndex1 > -1) {
vm.slots[2].defaultIndex = defaultIndex1
valueCodes[1] = tempCitiesObj[defaultIndex1].value
let tempCountriesObj = tempCitiesObj[defaultIndex1].children
vm.slots[4].values = tempCountriesObj.map(getAddressName)
let defaultIndex2 = tempCountriesObj.findIndex((obj)=>{
return obj.label === values[2]
})
valueCodes[2] = defaultIndex2 > -1 ? tempCountriesObj[defaultIndex2].value : tempCountriesObj[0].value
vm.slots[4].defaultIndex = defaultIndex2 > -1 ? defaultIndex2 : 0
vm.addressValue = values.join("-")
vm.addressValueCode = valueCodes.join("-")
}
}
}
}
}
</script>
<style scoped>
.mint-popup {
width: 100%;
}
.footer-btn {
box-sizing: border-box;
position: fixed;
width: 100%;
z-index: 2;
left: 0;
bottom: 3rem;
}
.input {
border: none;
}
.padding {
padding: 1.5rem;
font-size: 1.4rem;
}
.float-right {
float: right;
}
</style>
This diff is collapsed.
This diff is collapsed.
<template>
<div class="author">
<img :src="loadingUrl" />
<p>正在加载中......</p>
<p class="reload" :click="onPageReload">点击重新加载</p>
</div>
</template>
<script>
export default {
name: 'author',
data () {
return {
loadingUrl: 'https://cdn.singsingenglish.com/singsing/poster/monkey.jpg'
}
},
created () {
window.location.href = `${process.env.AUTHOR_UEL}?redirect_url=${this.$route.query.retUrl}`
},
methods: {
onPageReload: function () {
window.location.reload()
}
}
}
</script>
<style scoped lang="less">
img[lazy=loading] {
width: 50vw !important;
height: 50vw;
background-color: #eee;
margin: auto;
}
.author {
display: flex;
flex-flow: column nowrap;
justify-content: center;
align-items: center;
height: 100vh;
font-size: 1.8rem;
&>img {
width: 50vw;
}
.reload {
font-size: 1.2rem;
color: #199be0;
}
}
</style>
<template>
<div class="address">
<mt-header title="添加地址">
<mt-button icon="back" slot="left" @click="closeAdd">返回</mt-button>
</mt-header>
<mt-field label="收货人" v-model="receiveName"></mt-field>
<mt-field label="手机号" v-model="receiveMobile"></mt-field>
<mt-cell title="所在地区" :value="addressArea" @click.native="showPicker" is-link></mt-cell>
<mt-field label="详细地址" v-model="address"></mt-field>
<div @click="onSave" class="btn">保存</div>
<my-address :showAddressPicker="showAddressPicker" @save-address="saveAddress" @hide-picker="hidePicker" :init="addressArea">
</my-address>
</div>
</template>
<script>
import MyAddress from '@/components/address-picker/Address.vue'
import { Toast } from 'mint-ui'
export default {
name: 'address',
components: {
MyAddress
},
data () {
return {
receiveName: '',
receiveMobile: '',
addressDetail: '',
showAddressPicker: false,
addressArea: '广东-深圳-福田区',
addressAreaCode: '6-77-705',
address: ''
}
},
mounted () {
this.getUserAddress()
},
computed: {
courseUrl: function () {
return this[`courseType${this.type}Url`]
}
},
methods: {
closeAdd(){
this.$emit('closeAdd', false)
},
onSave: function () {
let values = this.addressAreaCode.split('-')
let labels = this.addressArea.split('-')
if (!this.receiveName) {
Toast('收货人不能为空')
return false
} else if (!this.receiveMobile) {
Toast('手机号不能为空')
return false
} else if (!(/^1\d{10}$/.test(this.receiveMobile))) {
Toast('手机号格式不正确')
return false
} else if (!this.address) {
Toast('详细地址不能为空')
return false
}
let param = {}
param.receive_name = this.receiveName
param.receive_mobile = this.receiveMobile
param.address = this.address
param.province_id = values[0]
param.province_name = labels[0]
param.city_id = values[1]
param.city = labels[1]
param.area_id = values[2]
param.area = labels[2]
Server.saveAddress(param).then((res) => {
if (res.data.result === 'success') {
this.closeAdd()
}
})
},
onValuesChange: function (picker, values) {
if (values[0] > values[1]) {
picker.setSlotValue(1, values[0])
}
},
hidePicker () {
// 接受子组件关闭popup事件
this.showAddressPicker = false
},
showPicker () {
this.showAddressPicker = !this.showAddressPicker
},
saveAddress (labels, values) {
// 从子组件接受返回所选值 val
this.addressArea = labels
this.addressAreaCode = values
this.showAddressPicker = !this.showAddressPicker
},
getUserAddress: function () {
Server.getUserAddress().then((res) => {
if (res.data.result === 'success' && res.data.data) {
if (res.data.data) {
let addressInfo = res.data.data
this.receiveName = addressInfo.receive_name ? addressInfo.receive_name : ''
this.receiveMobile = addressInfo.receive_mobile ? addressInfo.receive_mobile : ''
this.address = addressInfo.address
this.addressArea = `${addressInfo.province_name}-${addressInfo.city}-${addressInfo.area}`
this.addressAreaCode = `${addressInfo.province_id}-${addressInfo.city_id}-${addressInfo.area_id}`
}
}
})
}
}
}
</script>
<style scoped lang="less">
image[lazy=loading] {
width: 140px;
height: 300px;
margin: auto;
}
.no-select {
-webkit-touch-callout: none;
-webkit-text-size-adjust: none;
-webkit-tap-highlight-color: transparent;
-webkit-user-select: none;
user-select: none;
}
.address {
.btn{
margin-top: 20vw;
height: 11.73333vw;
line-height: 11.73333vw;
color: #fff;
font-size: 1.4rem;
text-align: center;
background: #60ADF0;
-webkit-box-shadow: 0 2px 6.66667vw 0 rgba(200, 205, 220, 0.7);
box-shadow: 0 2px 6.66667vw 0 rgba(200, 205, 220, 0.7);
border-radius: 20px;
margin-left: 1rem;
margin-right: 1rem;
}
}
</style>
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
<template>
<div class="index">
<div class="banner-block">
<mt-swipe :auto="5000">
<mt-swipe-item v-for="(data,index) in bannerList" :key="index">
<img class="banner" :src="data.url">
</mt-swipe-item>
</mt-swipe>
</div>
<div class="btn-block">
<div class="btn">
<img :src="imgUrl.record"/>
</div>
<div class="btn">
<img :src="imgUrl.money"/>
</div>
<div class="btn">
<img :src="imgUrl.listen"/>
</div>
<div class="btn">
<img :src="imgUrl.more"/>
</div>
</div>
<div class="class-block">
<div class="title">
我的课程
</div>
</div>
</div>
</template>
<script>
export default {
name: "index"
import {getBannerListApi} from "../service/api";
import {Swipe, SwipeItem} from 'mint-ui'
import {IndexImage} from "../util/imgUrl";
export default {
name: "index",
components:{
'mt-swipe':Swipe,
'mt-swipe-item':SwipeItem
},
data(){
return {
bannerList:[],
imgUrl: IndexImage
}
},
methods:{
initPage(){
getBannerListApi().then(res=>{
this.bannerList = res.list
})
}
},
mounted(){
this.initPage()
}
}
</script>
<style scoped>
<style scoped lang="less">
@import "../util/public";
.index{
background: #eee;
}
.banner-block{
width: 375*@toVw;
height: 140*@toVw;
.banner{
width: 375*@toVw;
height: 140*@toVw;
}
}
.btn-block{
display: flex;
padding: 12*@toVw 8*@toVw;
background: white;
justify-content: space-around;
.btn{
width: 68*@toVw;
height: 68*@toVw;
img{
width: 100%;
}
}
}
.class-block{
margin-top: 10px;
background: white;
padding: 5px;
font-family: PingFang-SC-Medium;
font-size: 20px;
color: #333333;
text-align: center;
}
</style>
......@@ -3,10 +3,8 @@
import Vue from 'vue'
import App from './App'
import router from './router'
import Mint from 'mint-ui'
import store from './store'
Vue.use(Mint);
import 'mint-ui/lib/style.css'
Vue.config.productionTip = false;
/* eslint-disable no-new */
......
import Vue from 'vue'
import Router from 'vue-router'
import index from '@/components/index'
import buyDetail from '@/components/buy/index'
import buy from '@/components/buy/buy'
import success from '@/components/buy/success'
import author from'@/components/author'
Vue.use(Router)
Vue.use(Router);
export default new Router({
const router =new Router({
routes: [
{
path: '/',
name: 'index',
component: index
}, {
path: '/author',
name: 'author',
component: author
},{
path: '/buyDetail',
name: 'buyDetail',
component: buyDetail
}, {
path: '/buy',
name: 'buy',
component: buy
}, {
path: '/success',
name: 'success',
component: success
}
]
})
});
router.beforeEach((to,from,next)=> {
});
export default router;
This diff is collapsed.
import axios from 'axios';
import md5 from 'js-md5';
import store from "@/store"
import { MessageBox ,Message } from 'element-ui';
import { Toast,MessageBox } from 'mint-ui';
import router from '../router'
import Cookie from '../util/cookie'
// 默认超时设置
......@@ -99,7 +99,7 @@ export function upload(url,json) {
resolve(response.data.data);
}
}else{
Message.error(response.data.msg)
Toast(response.data.msg)
}
})
.catch(err => {
......@@ -109,7 +109,6 @@ export function upload(url,json) {
MessageBox({
title:'错误!',
message:message,
type:'error',
})
})
};
......@@ -132,7 +131,7 @@ export function fetch(url,params={}){
if(response.data.code === 200){
resolve(response.data.data);
}else{
Message.error(response.data.msg)
Toast(response.data.msg)
}
})
.catch(err => {
......@@ -142,7 +141,6 @@ export function fetch(url,params={}){
MessageBox({
title:'错误!',
message:message,
type:'error',
})
})
})
......@@ -163,7 +161,7 @@ export function post(url,data = {}){
if(response.data.code === 200){
resolve(response.data.data);
}else{
Message.error(response.data.msg)
Toast(response.data.msg)
}
},err => {
reject(err);
......@@ -172,7 +170,6 @@ export function post(url,data = {}){
MessageBox({
title:'错误!',
message:message,
type:'error',
})
})
})
......@@ -192,7 +189,7 @@ export function patch(url,data = {}){
if(response.data.code === 200){
resolve(response.data.data);
}else{
Message.error(response.data.msg)
Toast(response.data.msg)
}
},err => {
reject(err);
......@@ -201,7 +198,6 @@ export function patch(url,data = {}){
MessageBox({
title:'错误!',
message:message,
type:'error',
})
})
})
......@@ -221,7 +217,7 @@ export function put(url,data = {}){
if(response.data.code === 200){
resolve(response.data.data);
}else{
Message.error(response.data.msg)
Toast(response.data.msg)
}
},err => {
reject(err);
......@@ -230,7 +226,6 @@ export function put(url,data = {}){
MessageBox({
title:'错误!',
message:message,
type:'error',
})
})
})
......@@ -243,7 +238,7 @@ export function del(url,data = {}){
if(response.data.code === 200){
resolve(response.data.data);
}else{
Message.error(response.data.msg)
Toast(response.data.msg)
}
},err => {
reject(err);
......@@ -252,7 +247,6 @@ export function del(url,data = {}){
MessageBox({
title:'错误!',
message:message,
type:'error',
})
})
})
......
export default{
//设置token
setToken({commit},token){
commit('setToken',token);
},
//设置用户名
setUserName({commit},name){
commit('setUserName',name);
},
setProgress({commit},data){
commit('progress',data);
},
}
import Vue from 'vue'
import vuex from 'vuex'
import menu from '../util/menuList'
import mutations from './mutations'
import actions from './actions'
Vue.use(vuex);
export default new vuex.Store({
state:{
show:false,
userName:'',
token:'',
mainLoad:true,
menuList:menu,
menuType:false,
nowTab:'first',
progressList:[],
openedTab:[
{
value:'首页',
routerName:'first',
name:'first',
delNo:true,
path:'/index'
}
],
},
mutations,
actions
......
import Cookie from "@/util/cookie";
const mutations={
//设置token
setToken(state,token){
state.token=token;
Cookie.set('cc_token',token);
},
//设置用户名
setUserName(state,userName){
state.userName=userName;
Cookie.set('cc_user_name',userName);
},
mainCanShow(state){
state.mainLoad = false
},
mainUnShow(state){
state.mainLoad = true
},
changeParentRouter(state,data){
state.menuList.find((a)=>{return a.name === data.name}).routerName = data.to.name
},
progress(state,data){
switch (data.type) {
case 'new':
state.progressList.push({num:0,id:data.id});
break;
case 'change':
state.progressList.find((x)=>{return x.id === data.id}).num = data.num;
break;
case 'delete':
delete state.progressList.find((x)=>{return x.id === data.id});
break
}
}
};
export default mutations;
export default{
dateFmt:function(date,format) {
var o = {
"M+" : date.getMonth()+1, //month
"d+" : date.getDate(), //day
"h+" : date.getHours(), //hour
"m+" : date.getMinutes(), //minute
"s+" : date.getSeconds(), //second
"q+" : Math.floor((date.getMonth()+3)/3), //quarter
"S" : date.getMilliseconds() //millisecond
}
if(/(y+)/.test(format)) format=format.replace(RegExp.$1,
(date.getFullYear()+"").substr(4 - RegExp.$1.length));
for(var k in o)if(new RegExp("("+ k +")").test(format))
format = format.replace(RegExp.$1,
RegExp.$1.length==1 ? o[k] :
("00"+ o[k]).substr((""+ o[k]).length));
return format;
},
getUrlParam(name){
var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)"); //构造一个含有目标参数的正则表达式对象
var spList=window.location.href.split('?');
if(spList.length>0){
var r = spList[spList.length-1].match(reg); //匹配目标参数
let r2 = spList[spList.length-2].match(reg)
if (r != null) {
return unescape(r[2]);
}else if(r2 != null) {
return unescape(r2[2]);
}//返回参数值
}else{
return '';
}
},
toDataURL (src, callback) {
var xhttp = new XMLHttpRequest()
xhttp.onload = function () {
var fileReader = new FileReader()
fileReader.onloadend = function () {
callback(fileReader.result)
}
fileReader.readAsDataURL(xhttp.response)
};
xhttp.responseType = 'blob'
xhttp.open('GET', src, true)
xhttp.send()
}
}
\ No newline at end of file
import indexBtn1 from '../assets/record.png'
import indexBtn2 from '../assets/money.png'
import indexBtn3 from '../assets/listen.png'
import indexBtn4 from '../assets/more.png'
export const IndexImage={
record:indexBtn1,
money:indexBtn2,
listen:indexBtn3,
more:indexBtn4
};
export default [
{
name: '',
value: '教研管理',
icon: 'icon-material',
list: [
{
value:'教材列表',
routerName:'resources',
path:'/resources'
}
]
},{
name: '',
value: '课程管理',
icon: 'icon-kecheng',
list: [
{
value:'课程列表',
routerName:'lesson',
path:'/lesson'
}
]
},{
name: '',
value: '期数管理',
icon: 'icon-rili',
list: [
{
value:'班级列表',
routerName:'class',
path:'/class'
},
{
value:'期数列表',
routerName:'periods',
path:'/periods'
},{
value:'不上课日期',
routerName:'noLesson',
path:'/noLesson'
},
]
},{
name: '',
value: '商品管理',
icon: 'icon-shangpin1',
list: [
{
value:'商品列表',
routerName:'shop',
path:'/shop'
}
]
},{
name: '',
value: '人员管理',
icon: 'icon-laoshi',
list: [
{
value:'教师列表',
routerName:'teacher',
path:'/teacher'
},
{
value:'用户列表',
routerName:'user',
path:'/user'
}
]
},{
name: '',
value: '订单管理',
icon: 'icon-dingdan',
list: [
{
value:'订单列表',
routerName:'order',
path:'/order'
},
{
value:'发货管理',
routerName:'consignment',
path:'/consignment'
}
]
},{
name: '',
value: '实物管理',
icon: 'icon-shu',
list: [
{
value:'单品列表',
routerName:'single',
path:'/single'
},
{
value:'盒子列表',
routerName:'box',
path:'/box'
}
]
},{
name: '',
value: '公众号',
icon: 'icon-ai-weixin',
list: [
{
value:'关注回复',
routerName:'focusReply',
path:'/focusReply'
},
{
value:'关键词回复',
routerName:'autoReply',
path:'/autoReply'
},
{
value:'公众号',
routerName:'weChat',
path:'/weChat'
},
{
value:'素材管理',
routerName:'weChatResource',
path:'/weChatResource'
}
]
},{
name: '',
value: '系统管理',
icon: 'icon-shezhi',
list: [
{
value:'账号管理',
routerName:'admin',
path:'/admin'
},{
value:'Banner管理',
routerName:'banner',
path:'/banner'
},{
value:'角色管理',
routerName:'role',
path:'/role'
},{
value:'菜单管理',
routerName:'menu',
path:'/menu'
},{
value:'系统配置',
routerName:'sysConfig',
path:'/sysConfig'
}
]
},{
name: '',
value: '帮助中心',
icon: 'icon-bangzhu',
list: [
{
value:'帮助中心',
routerName:'help',
path:'/help'
}
]
}
]
import look1_bg from '../assets/mould/look1/bg.png'
import look1_bank from '../assets/mould/look1/bank.png'
import look1_feiji from '../assets/mould/look1/feiji.png'
import look1_flour from '../assets/mould/look1/flour.png'
import look1_go from '../assets/mould/look1/go.png'
import look1_qiqiu from '../assets/mould/look1/qiqiu.png'
import look1_radio from '../assets/mould/look1/radio.png'
import look1_rainbow from '../assets/mould/look1/rainbow.png'
import look1_redM from '../assets/mould/look1/redM.png'
import look1_reqiqiu from '../assets/mould/look1/reqiqiu.png'
import look1_tadayBg from '../assets/mould/look1/tadayBg.png'
import look1_title1 from '../assets/mould/look1/title1.png'
import look1_title2 from '../assets/mould/look1/title2.png'
import look1_xuxian from '../assets/mould/look1/xuxian.png'
import look1_yun from '../assets/mould/look1/yun.png'
import radio1_bg from '../assets/mould/radio1/bg.png'
import radio1_backLookBtn from '../assets/mould/radio1/backLookBtn.png'
import radio1_CD from '../assets/mould/radio1/CD.png'
import radio1_contentBg from '../assets/mould/radio1/contentBg.png'
import radio1_loading from '../assets/mould/radio1/loading.png'
import radio1_near from '../assets/mould/radio1/near.png'
import radio1_next from '../assets/mould/radio1/next.png'
import radio1_play from '../assets/mould/radio1/play.png'
import radio1_showBtn from '../assets/mould/radio1/showBtn.png'
import radio_moerduo from '../assets/mould/radio1/moerduo.png'
import radio_moerduoBg from '../assets/mould/radio1/moerduobg.png'
import radio_tabVideo from '../assets/mould/radio1/tabVideo.png'
import playTitle from '../assets/mould/radio1/title.png'
import play1_bg from '../assets/mould/video/bg.png'
import play1_back from '../assets/mould/video/back.png'
import play1_next from '../assets/mould/video/next.png'
import play1_paly from '../assets/mould/video/paly.png'
import play1_radio from '../assets/mould/video/radio.png'
import show1_bg from '../assets/mould/show1/bg.png'
import show1_backBtn from '../assets/mould/show1/backBtn.png'
import show1_contentBg from '../assets/mould/show1/contentBg.png'
import show1_haiou from '../assets/mould/show1/haiou.png'
import show1_imgIcon from '../assets/mould/show1/imgIcon.png'
import show1_jiayoubao from '../assets/mould/show1/jiayoubao.png'
import show1_radioIcon from '../assets/mould/show1/radioIcon.png'
import show1_riji from '../assets/mould/show1/riji.png'
import show1_subBtn from '../assets/mould/show1/subBtn.png'
import show1_videoIcon from '../assets/mould/show1/videoIcon.png'
import show1_yeziyou from '../assets/mould/show1/yeziyou.png'
import show1_yezizuo from '../assets/mould/show1/yezizuo.png'
import show1_zhaopianqiang from '../assets/mould/show1/zhaopianqiang.png'
import show1_zhuangshi from '../assets/mould/show1/zhuangshi.png'
import show1_title from '../assets/mould/show1/title.png'
import refueling1_bg from '../assets/mould/refueling1/bg.png'
import refueling1_backBtn from '../assets/mould/refueling1/backBtn.png'
import refueling1_finish from '../assets/mould/refueling1/finish.png'
import refueling1_next from '../assets/mould/refueling1/next.png'
import refueling1_radio from '../assets/mould/refueling1/radio.png'
import refueling1_title from '../assets/mould/refueling1/title.png'
export default {
look1:{
bg:look1_bg,
bank:look1_bank,
feiji:look1_feiji,
flour:look1_flour,
go:look1_go,
qiqiu:look1_qiqiu,
radio:look1_radio,
rainbow:look1_rainbow,
redM:look1_redM,
reqiqiu:look1_reqiqiu,
tadayBg:look1_tadayBg,
title1:look1_title1,
title2:look1_title2,
xuxian:look1_xuxian,
yun:look1_yun
},
radio1:{
bg:radio1_bg,
backLookBtn:radio1_backLookBtn,
CD:radio1_CD,
contentBg:radio1_contentBg,
loading:radio1_loading,
near:radio1_near,
next:radio1_next,
play:radio1_play,
showBtn:radio1_showBtn,
title:playTitle,
moerduo:radio_moerduo,
moerduoBg:radio_moerduoBg,
finishBtn:refueling1_finish,
nextBtn:refueling1_next,
backPlayBtn:refueling1_backBtn,
tabVideo: radio_tabVideo
},
play1:{
bg:play1_bg,
backBtn:play1_back,
next:play1_next,
radio:play1_radio,
play:play1_paly,
},
show1:{
bg: show1_bg,
backBtn: show1_backBtn,
contentBg: show1_contentBg,
haiou: show1_haiou,
imgIcon: show1_imgIcon,
jiayoubao: show1_jiayoubao,
radioIcon: show1_radioIcon,
riji: show1_riji,
subBtn: show1_subBtn,
videoIcon: show1_videoIcon,
yeziyou: show1_yeziyou,
yezizuo: show1_yezizuo,
zhaopianqiang: show1_zhaopianqiang,
zhuangshi: show1_zhuangshi,
title:show1_title
},
refueling1:{
bg:refueling1_bg,
backBtn:refueling1_backBtn,
finish: refueling1_finish,
next: refueling1_next,
radio: refueling1_radio,
title: refueling1_title,
}
}
//颜色参数
@toVw:100/375vw;
@bg-b: #333;
@bg-b-s:#444;
@black-line:#191919;
......@@ -19,14 +20,7 @@
padding: 5px;
}
html{
font-family: "Helvetica Neue",
Helvetica,
"PingFang SC",
"Hiragino Sans GB",
"Microsoft YaHei",
"微软雅黑",
Arial,
sans-serif;
}
.clear-both{
&:after{
......
import lookUrl from '../assets/mould/example/look.png'
import playRadioUrl from '../assets/mould/example/playRadio.png'
import playVideoUrl from '../assets/mould/example/playVideo.png'
import RefuelingUrl from '../assets/mould/example/Refueling.png'
import showBabyUrl from '../assets/mould/example/showBaby.png'
export const MOULDLIST = [
{
title:'爸妈看一看',
imgUrl:lookUrl,
name:'看一看-1',
key:'look1',
content:{
radioUrl:[],
today:'',
directory:'',
nextIndex:'',
timeLang:0,
}
},{
title:'宝贝玩一玩',
imgUrl:playRadioUrl,
name:'玩-radio-1',
key:'radio1',
content:{
radio:[
],
nextIndex:'',
lastIndex:'',
buttonType:0,
titleType:0,
tabVideo:{
type:false,
index:''
},
}
},{
title:'宝贝玩一玩',
imgUrl:playVideoUrl,
name:'玩-video-1',
key:'play1',
content:{
videoUrl:[],
banner:[],
nextIndex:'',
lastIndex:'',
tabRadio:{
type:false,
index:''
}
}
},{
title:'唱学加油包',
imgUrl:RefuelingUrl,
name:'加油包-1',
key:'refueling1',
content:{
radio:[],
banner:[],
nextIndex:'',
nextType:true,
lastIndex:'',
}
},{
title:'爸妈秀宝贝',
imgUrl:showBabyUrl,
name:'秀宝贝-1',
key:'show1',
content:{
text:'',
check:true,
nextIndex:'',
lastIndex:'',
}
},
];
export default {
setOptions: function(options) {
var defaults = {
title: "我的推荐",
desc: "我的推荐",
link: location.href, //分享页面地址,不能为空
imgUrl: 'https://cdn.singsingenglish.com/singsing/recommend/logo-refer.png', //分享是封面图片,不能为空
success: function() {}, //分享成功触发
cancel: function() {} //分享取消触发,需要时可以调用
}
options = Object.assign({}, defaults, options);
wx.ready(function() {
var thatopts = options;
wx.onMenuShareTimeline({
title: thatopts.title, // 分享标题
desc: thatopts.desc, // 分享描述
link: thatopts.link, // 分享链接
imgUrl: thatopts.imgUrl, // 分享图标
success: function() {
// alert("成功");
},
cancel: function() {
// alert("失败")
}
});
wx.onMenuShareAppMessage({
title: thatopts.title, // 分享标题
desc: thatopts.desc, // 分享描述
link: thatopts.link, // 分享链接
imgUrl: thatopts.imgUrl, // 分享图标
success: function() {
// alert("成功");
},
cancel: function() {
// alert("失败")
}
});
});
},
wxConfig: function(jssdk) {
wx.config({
debug: false,
appId: jssdk.appId,
timestamp: parseInt(jssdk.timestamp),
nonceStr: jssdk.nonceStr,
signature: jssdk.signature,
jsApiList: [
"onMenuShareTimeline",
"onMenuShareAppMessage"
]
});
},
disableShare: function(jssdk) {
wx.config({
debug: false,
appId: jssdk.appId,
timestamp: parseInt(jssdk.timestamp),
nonceStr: jssdk.nonceStr,
signature: jssdk.signature,
jsApiList: []
});
}
};
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment