-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1,020 changed files
with
44,831 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
{ // launch.json 配置了启动调试时相关设置,configurations下节点名称可为 app-plus/h5/mp-weixin/mp-baidu/mp-alipay/mp-qq/mp-toutiao/mp-360/ | ||
// launchtype项可配置值为local或remote, local代表前端连本地云函数,remote代表前端连云端云函数 | ||
"version": "0.0", | ||
"configurations": [{ | ||
"default" : | ||
{ | ||
"launchtype" : "remote" | ||
}, | ||
"h5" : | ||
{ | ||
"launchtype" : "remote" | ||
}, | ||
"mp-weixin" : | ||
{ | ||
"launchtype" : "remote" | ||
}, | ||
"type" : "uniCloud" | ||
} | ||
] | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,104 @@ | ||
<script> | ||
import request from '@/util/request.js'; | ||
export default { | ||
globalData: { | ||
site_url:'https://dj.sdwanyue.com', //网站域名 | ||
navHeight:0,//导航栏高度 | ||
userInfo:'',//用户信息 | ||
configInfo:[],//配置信息 | ||
front_auth: [], // 前台用户权限 | ||
login_score: 0, | ||
first_login: 0, | ||
}, | ||
onLaunch: function() { | ||
var _this = this; | ||
//获取本地用户缓存,看看是否登录 | ||
uni.getStorage({ | ||
key: 'userInfo', | ||
success (res) { //有本地缓存登录过 | ||
_this.globalData.userInfo = res.data; | ||
} | ||
}) | ||
uni.getSystemInfo({ | ||
success: res => { | ||
//导航高度 | ||
this.globalData.navHeight = res.statusBarHeight * (750 / res.windowWidth) + 97; | ||
}, fail(err) {} | ||
}); | ||
}, | ||
onShow: function() { | ||
var url = this.globalData.site_url+'/appapi/?s=Home.GetConfig'; | ||
request.requestApi(url,{}).then(res=>{ | ||
this.globalData.configInfo = res.data.info[0]; | ||
}) | ||
const updateManager = uni.getUpdateManager(); | ||
updateManager.onCheckForUpdate(function (res) { | ||
// 请求完新版本信息的回调 | ||
}) | ||
updateManager.onUpdateReady(function () { | ||
uni.showModal({ | ||
title: '更新提示', | ||
content: '新版本已经准备好,是否重启应用?', | ||
success: function (res) { | ||
if (res.confirm) { | ||
// 新的版本已经下载好,调用 applyUpdate 应用新版本并重启 | ||
updateManager.applyUpdate() | ||
} | ||
} | ||
}) | ||
}); | ||
updateManager.onUpdateFailed(function () { | ||
uni.showToast({ | ||
title: '新版本下载失败', | ||
icon:'none' | ||
}) | ||
}) | ||
}, | ||
onHide: function() { | ||
} | ||
} | ||
</script> | ||
|
||
<style> | ||
/*每个页面公共css */ | ||
@import url("/static/dj.css"); | ||
@import url("/static/iconfont.css"); | ||
/deep/.uni-scroll-view ::-webkit-scrollbar { | ||
/* 隐藏滚动条,但依旧具备可以滚动的功能 */ | ||
display: none; | ||
width: 0; | ||
height: 0; | ||
color: transparent; | ||
background: transparent; | ||
} | ||
/deep/::-webkit-scrollbar { | ||
display: none; | ||
width: 0; | ||
height: 0; | ||
color: transparent; | ||
background: transparent; | ||
} | ||
/* 弹窗层级设为最高 */ | ||
uni-toast{ | ||
z-index: 99999; | ||
} | ||
uni-modal { | ||
z-index: 99999; | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,73 @@ | ||
<template> | ||
<view> | ||
<block v-for="(item,index) in list" :key="id"> | ||
<view class="article-list-li" @click="goH5" :data-url="item.url"> | ||
<image class="article-list-li-thumb" :src="item.thumb"></image> | ||
<view class="article-list-li-right"> | ||
<view class="article-list-li-right-title">{{item.title}}</view> | ||
<view class="article-list-li-right-date">结束时间:{{item.endtime}}</view> | ||
</view> | ||
</view> | ||
</block> | ||
</view> | ||
</template> | ||
|
||
<script> | ||
export default { | ||
props:{ | ||
list:{ | ||
type:Array, | ||
value:[] | ||
} | ||
}, | ||
data() { | ||
return { | ||
} | ||
}, | ||
methods: { | ||
goH5(e){ | ||
uni.navigateTo({ | ||
url:'/pages/webview/index?url='+e.currentTarget.dataset.url | ||
}) | ||
} | ||
} | ||
} | ||
</script> | ||
|
||
<style> | ||
.article-list-li-right-date{ | ||
font-size: 28rpx; | ||
margin-top: 46rpx; | ||
color: #969696; | ||
} | ||
.article-list-li-right-title{ | ||
font-size: 36rpx; | ||
letter-spacing: 1rpx; | ||
font-weight: 500; | ||
overflow: hidden; | ||
-webkit-line-clamp: 2; | ||
text-overflow: ellipsis; | ||
display: -webkit-box; | ||
-webkit-box-orient: vertical; | ||
height: 94rpx; | ||
} | ||
.article-list-li-right{ | ||
float: left; | ||
width: 64%; | ||
margin-left: 4%; | ||
} | ||
.article-list-li{ | ||
clear: both; | ||
overflow: hidden; | ||
height: 170rpx; | ||
padding: 40rpx 0 40rpx 0; | ||
border-bottom: 1rpx solid #F0F0F0; | ||
width: 100%; | ||
} | ||
.article-list-li-thumb{ | ||
width: 32%; | ||
height: 100%; | ||
float: left; | ||
} | ||
</style> |
Oops, something went wrong.