Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
德宏大魔王
uni-starter
提交
019f116e
U
uni-starter
项目概览
德宏大魔王
/
uni-starter
与 Fork 源项目一致
Fork自
DCloud / uni-starter
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
U
uni-starter
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
提交
019f116e
编写于
4月 21, 2021
作者:
DCloud_JSON
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'master' of
https://gitee.com/dcloud/base-app
上级
4a12f1ed
c8030b4f
变更
9
隐藏空白更改
内联
并排
Showing
9 changed file
with
173 addition
and
27 deletion
+173
-27
pages.json
pages.json
+22
-14
pages/grid/grid.vue
pages/grid/grid.vue
+6
-4
pages/list/news-list.vue
pages/list/news-list.vue
+9
-4
pages/list/search/search.nvue
pages/list/search/search.nvue
+3
-1
pages/ucenter/ucenter.vue
pages/ucenter/ucenter.vue
+25
-2
uniCloud-aliyun/database/uni-id-scores.schema.json
uniCloud-aliyun/database/uni-id-scores.schema.json
+38
-0
uni_modules/opendb-feedback/uniCloud/database/opendb-feedback.schema.json
...db-feedback/uniCloud/database/opendb-feedback.schema.json
+68
-0
uni_modules/uni-list/components/uni-list-item/uni-list-item.vue
...dules/uni-list/components/uni-list-item/uni-list-item.vue
+1
-1
uni_modules/uni-login-page/pages/index/index.vue
uni_modules/uni-login-page/pages/index/index.vue
+1
-1
未找到文件。
pages.json
浏览文件 @
019f116e
...
...
@@ -2,34 +2,40 @@
"pages"
:
[{
"path"
:
"pages/list/list"
,
"style"
:
{
//#ifndef
MP
"navigationStyle"
:
"custom"
,
"enablePullDownRefresh"
:
true
,
"app-plus"
:{
"subNVues"
:[
{
"id"
:
"networkErr"
,
"path"
:
"pages/list/networkErr/networkErr"
,
"style"
:{
"height"
:
"0"
,
"width"
:
"100%"
,
"background"
:
"transparent"
}
}
]
//#endif
"enablePullDownRefresh"
:
true
,
"app-plus"
:{
"subNVues"
:[
{
"id"
:
"networkErr"
,
"path"
:
"pages/list/networkErr/networkErr"
,
"style"
:{
"height"
:
"0"
,
"width"
:
"100%"
,
"background"
:
"transparent"
}
}
]
}
}
},
},
{
"path"
:
"pages/list/news-list"
,
"style"
:
{
//#ifndef
MP
"navigationStyle"
:
"custom"
,
//#endif
"enablePullDownRefresh"
:
true
}
},
{
"path"
:
"pages/grid/grid"
,
"style"
:
{
//#ifndef
MP
"navigationStyle"
:
"custom"
//#endif
}
},
{
"path"
:
"uni_modules/uni-login-page/pages/index/index"
,
...
...
@@ -43,7 +49,9 @@
},
{
"path"
:
"pages/list/search/search"
,
"style"
:
{
//#ifndef
MP
"navigationStyle"
:
"custom"
//#endif
}
},
{
"path"
:
"pages/list/detail"
,
...
...
pages/grid/grid.vue
浏览文件 @
019f116e
<
template
>
<view
class=
"warp"
>
<!-- 搜索 -->
<template>
<status-bar
/>
<template>
<!-- #ifdef APP-PLUS -->
<status-bar
/>
<!-- #endif -->
<uni-search-bar
ref=
"searchBar"
style=
"flex:1;"
radius=
"100"
@
click.native=
"searchClick"
cancelButton=
"none"
disabled
/>
</
template
>
<!-- banner -->
<unicloud-db
ref=
"bannerdb"
v-slot:default=
"{data, loading, error, options}"
:collection=
"collection"
:field=
"field"
@
load=
"load"
>
<uni-swiper-dot
class=
"uni-swiper-dot-box"
@
clickItem=
"clickItem"
:info=
"bannerFormate(data, loading)"
<uni-swiper-dot
class=
"uni-swiper-dot-box"
@
clickItem=
"clickItem"
:info=
"
data ||
bannerFormate(data, loading)"
:current=
"current"
:mode=
"mode"
:dots-styles=
"dotsStyles"
field=
"content"
>
<swiper
class=
"swiper-box"
@
change=
"changeSwiper"
:current=
"swiperDotIndex"
>
<swiper-item
v-for=
"(item, index) in
bannerFormate(data, loading
)"
:key=
"item._id"
>
<swiper-item
v-for=
"(item, index) in
(data || bannerFormate(data, loading)
)"
:key=
"item._id"
>
<view
:draggable=
"false"
class=
"swiper-item"
@
click=
"clickBannerItem(item)"
>
<image
class=
"swiper-image"
:src=
"item.bannerfile"
mode=
"aspectFill"
:draggable=
"false"
/>
</view>
...
...
pages/list/news-list.vue
浏览文件 @
019f116e
...
...
@@ -8,20 +8,24 @@
-->
<view
style=
"overflow: hidden;"
>
<view
class=
"search-box"
>
<!-- #ifdef APP-PLUS -->
<status-bar
class=
"status-bar"
></status-bar>
<!-- #endif -->
<view
class=
"search-container-bar"
>
<uni-search-bar
ref=
"searchBar"
style=
"flex:1;"
radius=
"100"
v-model=
"searchText"
@
click.native=
"searchClick"
cancelButton=
"none"
disabled
/>
</view>
</view>
<view
class=
"list"
>
<status-bar></status-bar>
<!-- #ifdef APP-PLUS -->
<status-bar></status-bar>
<!-- #endif -->
<!-- 刷新页面后的顶部提示框 -->
<!-- 当前弹出内容没有实际逻辑 ,可根据当前业务修改弹出提示 -->
<view
class=
"tips"
:class=
"
{ 'tips-ani': tipShow }">为您更新了10条内容
</view>
<!-- 页面分类标题 -->
<uni-section
style=
"margin:0;"
v-if=
"searchText"
:title=
"listTitle"
type=
"line"
></uni-section>
<unicloud-db
ref=
"udb"
v-slot:default=
"
{data, loading, error, options}" :options="formData"
:collection="collection" :field="field" :where="where" @load="load" @error="isLoading = false">
:collection="collection" :field="field" :
foreignKey="foreignKey" :
where="where" @load="load" @error="isLoading = false">
<text
v-if=
"error"
class=
"list-info"
>
{{
error
.
message
}}
</text>
<!-- 基于 uni-list 的页面布局 -->
<uni-list
:class=
"
{ 'uni-list--waterfall': options.waterfall }">
...
...
@@ -86,8 +90,9 @@
where
:
''
,
// 数据表名
collection
:
'
opendb-news-articles,uni-id-users
'
,
// 查询字段,多个字段用 , 分割
field
:
'
author{username, _id}, user_id,_id,avatar,title,excerpt,last_modify_date, comment_count, like_count
'
,
// 查询字段,多个字段用 , 分割
foreignKey
:
''
,
field
:
'
author{username, _id}, _id,avatar,title,excerpt,last_modify_date, comment_count, like_count
'
,
tipShow
:
false
,
// 是否显示顶部提示框
isLoading
:
true
};
...
...
pages/list/search/search.nvue
浏览文件 @
019f116e
...
...
@@ -143,7 +143,7 @@
associativeList: [],
keyBoardPopup: false,
hotWorld: '
apple
', // 搜索热词,如果没有输入即回车,则搜索热词,但是不会加入搜索记录
hotWorld: '
DCloud
', // 搜索热词,如果没有输入即回车,则搜索热词,但是不会加入搜索记录
focus: true, // 是否自动聚焦
speechEngine: 'iFly' // 语音识别引擎 iFly 讯飞 baidu 百度
}
...
...
@@ -160,7 +160,9 @@
this.searchText = getApp().globalData.searchText;
},
onLoad() {
//#ifdef APP-PLUS
this.statusBarHeight = `${uni.getSystemInfoSync().statusBarHeight}px`;
//#endif
},
methods: {
clear(res) {
...
...
pages/ucenter/ucenter.vue
浏览文件 @
019f116e
...
...
@@ -31,7 +31,10 @@
mapMutations
}
from
'
vuex
'
;
import
checkUpdate
from
'
@/uni_modules/uni-upgrade-center-app/utils/check-update
'
;
import
callCheckVersion
from
'
@/uni_modules/uni-upgrade-center-app/utils/call-check-version
'
;
import
callCheckVersion
from
'
@/uni_modules/uni-upgrade-center-app/utils/call-check-version
'
;
const
db
=
uniCloud
.
database
();
const
dbCollectionName
=
'
uni-id-scores
'
;
export
default
{
data
()
{
return
{
...
...
@@ -70,7 +73,8 @@
to
:
''
},
{
title
:
'
我的积分
'
,
to
:
''
to
:
''
,
event
:
'
getScore
'
}],
[{
title
:
'
问题与反馈
'
,
...
...
@@ -164,6 +168,25 @@
main
.
startActivity
(
intent
);
}
// #endif
},
/**
* 获取积分信息
*/
getScore
()
{
uni
.
showLoading
({
mask
:
true
})
db
.
collection
(
dbCollectionName
).
field
(
'
score,balance
'
).
get
().
then
((
res
)
=>
{
const
data
=
res
.
result
.
data
[
0
]
console
.
log
(
data
);
}).
catch
((
err
)
=>
{
uni
.
showModal
({
content
:
err
.
message
||
'
请求服务失败
'
,
showCancel
:
false
})
}).
finally
(()
=>
{
uni
.
hideLoading
()
})
}
}
}
...
...
uniCloud-aliyun/database/uni-id-scores.schema.json
0 → 100644
浏览文件 @
019f116e
{
"bsonType"
:
"object"
,
"required"
:
[
"user_id"
,
"score"
,
"balance"
],
"properties"
:
{
"_id"
:
{
"description"
:
"ID,系统自动生成"
},
"user_id"
:
{
"bsonType"
:
"string"
,
"description"
:
"用户id,参考uni-id-users表"
},
"score"
:
{
"bsonType"
:
"int"
,
"description"
:
"本次变化的积分"
},
"type"
:
{
"bsonType"
:
"int"
,
"enum"
:
[
1
,
2
],
"description"
:
"积分类型 1:收入 2:支出"
},
"balance"
:
{
"bsonType"
:
"int"
,
"description"
:
"变化后的积分余额"
},
"comment"
:
{
"bsonType"
:
"string"
,
"description"
:
"备注,说明积分新增、消费的缘由"
,
"trim"
:
"both"
},
"create_date"
:
{
"bsonType"
:
"timestamp"
,
"description"
:
"创建时间"
,
"forceDefaultValue"
:
{
"$env"
:
"now"
}
}
}
}
uni_modules/opendb-feedback/uniCloud/database/opendb-feedback.schema.json
0 → 100644
浏览文件 @
019f116e
{
"bsonType"
:
"object"
,
"permission"
:
{
"read"
:
"doc.is_reply == false"
,
"create"
:
true
,
"update"
:
false
,
"delete"
:
false
},
"properties"
:
{
"_id"
:
{
"description"
:
"ID,系统自动生成"
},
"user_id"
:
{
"bsonType"
:
"string"
,
"description"
:
"留言反馈用户ID
\/
回复留言用户ID,参考uni-id-users表"
,
"foreignKey"
:
"uni-id-users._id"
,
"forceDefaultValue"
:
{
"$env"
:
"uid"
}
},
"title"
:
{
"description"
:
"反馈标题(用于列表展示)"
},
"ip"
:
{
"forceDefaultValue"
:
{
"$env"
:
"clientIP"
}
},
"create_date"
:
{
"bsonType"
:
"timestamp"
,
"description"
:
"留言时间
\/
回复留言时间"
,
"forceDefaultValue"
:
{
"$env"
:
"now"
}
},
"content"
:
{
"bsonType"
:
"string"
,
"description"
:
"留言内容
\/
回复内容"
,
"trim"
:
"right"
},
"imgs"
:
{
"bsonType"
:
"array"
,
"description"
:
"图片列表"
},
"is_reply"
:
{
"bsonType"
:
"bool"
,
"description"
:
"是否是回复类型"
},
"feedback_id"
:
{
"bsonType"
:
"string"
,
"description"
:
"被回复留言ID"
},
"contact"
:
{
"bsonType"
:
"string"
,
"description"
:
"联系人"
,
"trim"
:
"both"
},
"mobile"
:
{
"bsonType"
:
"string"
,
"description"
:
"联系电话"
,
"trim"
:
"both"
},
"reply_count"
:
{
"bsonType"
:
"int"
,
"description"
:
"被回复条数"
}
}
}
uni_modules/uni-list/components/uni-list-item/uni-list-item.vue
浏览文件 @
019f116e
...
...
@@ -370,7 +370,7 @@ $list-item-pd: $uni-spacing-col-lg $uni-spacing-row-lg;
/* #endif */
height
:
$uni-img-size-base
;
width
:
$uni-img-size-base
;
mar
g
in-right
:
10px
;
marin-right
:
10px
;
}
.uni-icon-wrapper
{
...
...
uni_modules/uni-login-page/pages/index/index.vue
浏览文件 @
019f116e
...
...
@@ -105,7 +105,7 @@ import baseappConfig from '@/baseapp.config.js';
*/
uni
.
showLoading
();
uni
.
navigateTo
({
url
:
'
./phone-code?phoneNumber=
'
+
this
.
formData
.
phone
+
'
&phoneArea=
'
+
url
:
'
.
./phone-code
/phone-code?phoneNumber=
'
+
this
.
formData
.
phone
+
'
&phoneArea=
'
+
this
.
currenPhoneArea
,
success
:
res
=>
{},
fail
:
()
=>
{},
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录