diff --git a/components/uni-agree/uni-agree.vue b/components/uni-agree/uni-agree.vue
new file mode 100644
index 0000000000000000000000000000000000000000..71890ff1d3e79b72e043b25ddac132bd99728393
--- /dev/null
+++ b/components/uni-agree/uni-agree.vue
@@ -0,0 +1,34 @@
+
+
+
+
+
+
+
+
+
+
+
diff --git a/components/uni-popup-agree/uni-popup-agree.vue b/components/uni-popup-agree/uni-popup-agree.vue
new file mode 100644
index 0000000000000000000000000000000000000000..f8cd7b10d201d35f6aafe1ea245d7ac62866bf20
--- /dev/null
+++ b/components/uni-popup-agree/uni-popup-agree.vue
@@ -0,0 +1,212 @@
+
+
+
+
+
+
+
diff --git a/pages.json b/pages.json
index 48609cb9bc6d3d7b45b9d4a48dd834f6dda1ec1f..e839f5c9604c8a64fc4b5f7cee4c31dbbda50e76 100644
--- a/pages.json
+++ b/pages.json
@@ -19,12 +19,12 @@
}
}, {
"path": "uni_modules/uni-login-page/pages/index/index",
- "style": {
+ "style": {
"navigationBarTitleText": "",
"app-plus": {
"animationType": "none",
- "popGesture": "none",
- "navigationStyle": "custom",
+ "popGesture": "none",
+ "navigationStyle": "custom",
"backgroundColor": "transparent"
// "titleNView": {
// "buttons": [{
@@ -67,17 +67,17 @@
"navigationStyle": "custom"
}
}, {
- "path": "uni_modules/opendb-feedback/pages/opendb-feedback/list",
+ "path": "uni_modules/uni-feedback/pages/opendb-feedback/list",
"style": {
"navigationBarTitleText": "常见问题"
}
}, {
- "path": "uni_modules/opendb-feedback/pages/opendb-feedback/add",
+ "path": "uni_modules/uni-feedback/pages/opendb-feedback/add",
"style": {
"navigationBarTitleText": "问题反馈"
}
}, {
- "path": "uni_modules/opendb-feedback/pages/opendb-feedback/detail",
+ "path": "uni_modules/uni-feedback/pages/opendb-feedback/detail",
"style": {
"navigationBarTitleText": "问题反馈"
}
@@ -127,7 +127,8 @@
}
}, {
- "path": "pages/ucenter/edit/edit",
+ "path": "uni_modules/uni-id-users/pages/uni-id-users/edit",
+ // "path": "pages/ucenter/edit/edit",
"style": {
"navigationBarTitleText": "编辑资料"
}
@@ -137,49 +138,19 @@
"navigationStyle": "custom"
}
}, {
- "path": "uni_modules/uni-login-page/pages/index/pwd-login",
+ "path": "uni_modules/uni-login-page/pages/pwd-login/pwd-login",
"style": {
- "navigationBarTitleText": "",
- "app-plus": {
- // "titleNView": {
- // "buttons": [{
- // "text": "帮助",
- // "type": "none",
- // "fontSize": "16px",
- // "width": "60px"
- // }]
- // }
- }
+ "navigationBarTitleText": ""
}
}, {
- "path": "uni_modules/uni-login-page/pages/index/pwd-retrieve",
+ "path": "uni_modules/uni-login-page/pages/pwd-retrieve/pwd-retrieve",
"style": {
- "navigationBarTitleText": "",
- "app-plus": {
- // "titleNView": {
- // "buttons": [{
- // "text": "帮助",
- // "type": "none",
- // "fontSize": "16px",
- // "width": "60px"
- // }]
- // }
- }
+ "navigationBarTitleText": ""
}
}, {
- "path": "uni_modules/uni-login-page/pages/index/phone-code",
+ "path": "uni_modules/uni-login-page/pages/phone-code/phone-code",
"style": {
- "navigationBarTitleText": "",
- "app-plus": {
- // "titleNView": {
- // "buttons": [{
- // "text": "帮助",
- // "type": "none",
- // "fontSize": "16px",
- // "width": "60px"
- // }]
- // }
- }
+ "navigationBarTitleText": ""
}
}, {
@@ -190,24 +161,24 @@
}
}
- ,{
- "path" : "pages/test/test",
- "style" :
- {
- "navigationBarTitleText": "",
- "enablePullDownRefresh": false
- }
-
- }
- ,{
- "path" : "pages/common/webview/webview",
- "style" :
- {
- "navigationBarTitleText": "",
- "enablePullDownRefresh": false
- }
-
- }
+ ,{
+ "path" : "pages/test/test",
+ "style" :
+ {
+ "navigationBarTitleText": "",
+ "enablePullDownRefresh": false
+ }
+
+ }
+ ,{
+ "path" : "pages/common/webview/webview",
+ "style" :
+ {
+ "navigationBarTitleText": "",
+ "enablePullDownRefresh": false
+ }
+
+ }
],
"globalStyle": {
"navigationBarTextStyle": "black",
@@ -215,6 +186,7 @@
"navigationBarBackgroundColor": "#FFFFFF",
"backgroundColor": "#F8F8F8"
},
+<<<<<<< HEAD
// "condition": {
// "list": [
// {
@@ -229,6 +201,22 @@
// ],
// "current":1
// },
+=======
+ "condition": {
+ "list": [
+ {
+ "path": "uni_modules/uni-login-page/pages/index/index"
+ },
+ {
+ "path": "pages/test/test"
+ },
+ {
+ "path":"pages/ucenter/settings/settings"
+ }
+ ],
+ "current":2
+ },
+>>>>>>> 82ef1c53dc0aebef37985e23752a43c7aab5b82e
"tabBar": {
"color": "#7A7E83",
"selectedColor": "#007AFF",
@@ -251,4 +239,4 @@
"text": "我的"
}]
}
-}
+}
diff --git a/pages/list/detail.vue b/pages/list/detail.vue
index a42a29e1e450db4143b096616eabdd8c4dd02581..1b77d90bc69fe58f0772088c8e71c6ee5c2ea039 100644
--- a/pages/list/detail.vue
+++ b/pages/list/detail.vue
@@ -7,6 +7,7 @@
DB Schema 规范:https://uniapp.dcloud.net.cn/uniCloud/schema
-->
+
diff --git a/pages/list/list.vue b/pages/list/list.vue
index b5e12ab80c9b95af67d0f8bec120d7d174f1a2a6..6c6cd7218eb65d45c9ade20b3269fc79638382a9 100644
--- a/pages/list/list.vue
+++ b/pages/list/list.vue
@@ -1,7 +1,9 @@
-
+
+
+
diff --git a/pages/ucenter/edit/edit.vue b/pages/ucenter/edit/edit.vue
deleted file mode 100644
index e54d416f66ae31f06b2191f362a332b6e842884a..0000000000000000000000000000000000000000
--- a/pages/ucenter/edit/edit.vue
+++ /dev/null
@@ -1,109 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/pages/ucenter/edit/uploadCutImageToUnicloud.vue b/pages/ucenter/edit/uploadCutImageToUnicloud.vue
index 839b03d6058cff09e94400ba80a4d2b579e101ce..4b6b61ce106208be14e38066eabc974e1c1214e3 100644
--- a/pages/ucenter/edit/uploadCutImageToUnicloud.vue
+++ b/pages/ucenter/edit/uploadCutImageToUnicloud.vue
@@ -17,15 +17,15 @@ export default {
},
methods:{
successFn(e){
- uni.getImageInfo({
- src:e.url,
- complete: (e) => {
- console.log(e);
- }
- })
+ // uni.getImageInfo({
+ // src:e.url,
+ // complete: (e) => {
+ // console.log(e);
+ // }
+ // })
this.uploadImgToUnicloud(e.url,(url)=>{
//console.log(url);
- uni.$emit('uploadAvatarAfter', {url});
+ this.getOpenerEventChannel().emit('uploadAvatarAfter', {url})
uni.navigateBack()
})
},
diff --git a/pages/ucenter/settings/settings.nvue b/pages/ucenter/settings/settings.nvue
index 6992458731c6b076544a3709f4a843e6e1454d57..0832405bc53daa325405094051448f8773be5f23 100644
--- a/pages/ucenter/settings/settings.nvue
+++ b/pages/ucenter/settings/settings.nvue
@@ -66,7 +66,7 @@
}),
toEdit(){
uni.navigateTo({
- url: '/pages/ucenter/edit/edit'
+ url: '/uni_modules/uni-id-users/pages/uni-id-users/edit'
});
},
changePwd(){
@@ -142,8 +142,9 @@
});
},
fail:(err)=> {
+ console.log(`认证失败:${err.errCode}`);
uni.showToast({
- title: `认证失败:${err.errCode}`,
+ title: `认证失败`,
icon: 'none'
});
}
diff --git a/pages/ucenter/ucenter.vue b/pages/ucenter/ucenter.vue
index 7376e7637b3696042621b712bf007812310224ac..7200b164815563d51db7cf2374488511c4d18a6e 100644
--- a/pages/ucenter/ucenter.vue
+++ b/pages/ucenter/ucenter.vue
@@ -72,10 +72,14 @@
event: 'checkVersion',
showBadge: true
},
+ {
+ title:'去评分',
+ event:'gotoMarket'
+ },
//#endif
{
- title: '反馈',
- to: '/uni_modules/opendb-feedback/pages/opendb-feedback/list' // /pages/ucenter/uni-feedback/uni-feedback uni_modules/opendb-feedback/pages/opendb-feedback/list
+ title: '问题与反馈',
+ to: '/uni_modules/uni-feedback/pages/opendb-feedback/list' // /pages/ucenter/uni-feedback/uni-feedback uni_modules/uni-feedback/pages/opendb-feedback/list
},{
title: '关于',
to: '/pages/ucenter/about/about'
@@ -96,11 +100,11 @@
methods: {
...mapMutations({
logout: 'user/logout'
- }),
- toSettings(){
- uni.navigateTo({
- url:"/pages/ucenter/settings/settings"
- })
+ }),
+ toSettings(){
+ uni.navigateTo({
+ url:"/pages/ucenter/settings/settings"
+ })
},
/**
* 个人中心项目列表点击事件
@@ -131,6 +135,26 @@
title: '你点击了,第' + (index+1) + '个',
icon: 'none'
});
+ },
+ /**
+ * 去应用市场评分
+ */
+ gotoMarket(){
+ // #ifdef APP-PLUS
+ if (uni.getSystemInfoSync().platform == "ios") {
+ // 这里填写appstore应用id
+ let appstoreid = 'id1417078253';
+ plus.runtime.openURL("itms-apps://" + 'itunes.apple.com/cn/app/wechat/'+appstoreid+'?mt=8');
+ }
+ if (uni.getSystemInfoSync().platform == "android") {
+ var Uri = plus.android.importClass("android.net.Uri");
+ var uri = Uri.parse("market://details?id=" + plus.runtime.appid );
+ var Intent = plus.android.importClass('android.content.Intent');
+ var intent = new Intent(Intent.ACTION_VIEW, uri);
+ var main = plus.android.runtimeMainActivity();
+ main.startActivity(intent);
+ }
+ // #endif
}
}
}
@@ -275,4 +299,4 @@
/* #endif */
background-color: #DD524D;
}
-
+
diff --git a/uni_modules/uni-data-picker/changelog.md b/uni_modules/uni-data-picker/changelog.md
index 8ad6f35bc8c56e84b4b04af637302e6ef8040d2b..78243da877fb9cf8032380c9e1b82926a92da8c7 100644
--- a/uni_modules/uni-data-picker/changelog.md
+++ b/uni_modules/uni-data-picker/changelog.md
@@ -1,3 +1,8 @@
+## 0.3.1(2021-04-15)
+- 修复 本地数据概率无法回显时问题
+## 0.3.0(2021-04-07)
+- 新增 支持云端非树形表结构数据
+- 修复 根节点 parent_field 字段等于null时选择界面错乱问题
## 0.2.0(2021-03-15)
- 修复 nodeclick、popupopened、popupclosed事件无法触发的问题
## 0.1.9(2021-03-09)
diff --git a/uni_modules/uni-data-picker/components/uni-data-picker/uni-data-picker.vue b/uni_modules/uni-data-picker/components/uni-data-picker/uni-data-picker.vue
index a3bd82182d39cda5a5c61efa5d29e29afcef7015..b6f730f2d0d0cb5fdf28d73d65cf755d53f9b5cc 100644
--- a/uni_modules/uni-data-picker/components/uni-data-picker/uni-data-picker.vue
+++ b/uni_modules/uni-data-picker/components/uni-data-picker/uni-data-picker.vue
@@ -1,462 +1,466 @@
-
-
-
-
-
- {{errorMessage}}
-
-
-
-
-
-
- {{item.text}}{{split}}
-
-
-
- {{placeholder}}
-
-
-
-
-
-
-
-
-
-
- {{popupTitle}}
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/uni_modules/uni-data-picker/components/uni-data-pickerview/uni-data-picker.js b/uni_modules/uni-data-picker/components/uni-data-pickerview/uni-data-picker.js
index af69e741ae0172cac3e179096178ee9d1e93bd8b..84b51f3344366987d6b9bca6792477161b2ce894 100644
--- a/uni_modules/uni-data-picker/components/uni-data-pickerview/uni-data-picker.js
+++ b/uni_modules/uni-data-picker/components/uni-data-pickerview/uni-data-picker.js
@@ -105,7 +105,11 @@ export default {
return this.localdata.length > 0
},
postField() {
- return `${this.field}, ${this.parentField} as parent_value`
+ let fields = [this.field];
+ if (this.parentField) {
+ fields.push(`${this.parentField} as parent_value`);
+ }
+ return fields.join(',');
}
},
created() {
@@ -192,6 +196,23 @@ export default {
return db
},
+ getNodeData(callback) {
+ if (this.loading) {
+ return
+ }
+ this.loading = true
+ this.getCommand({
+ field: this.postField,
+ where: this._pathWhere()
+ }).then((res) => {
+ this.loading = false
+ this.selected = res.result.data
+ callback && callback()
+ }).catch((err) => {
+ this.loading = false
+ this.errorMessage = err
+ })
+ },
getTreePath(callback) {
if (this.loading) {
return
@@ -280,13 +301,29 @@ export default {
this.errorMessage = err
})
},
+ _pathWhere() {
+ let result = []
+ let where_field = this._getParentNameByField();
+ if (where_field) {
+ result.push(`${where_field} == '${this.value}'`)
+ }
+
+ if (this.where) {
+ return `(${this.where}) && (${result.join(' || ')})`
+ }
+
+ return result.join(' || ')
+ },
_postWhere() {
let result = []
let selected = this.selected
- result.push(`${this.parentField} == null`)
+ let parentField = this.parentField
+ if (parentField) {
+ result.push(`${parentField} == null || ${parentField} == ""`)
+ }
if (selected.length) {
for (var i = 0; i < selected.length - 1; i++) {
- result.push(`${this.parentField} == '${selected[i].value}'`)
+ result.push(`${parentField} == '${selected[i].value}'`)
}
}
@@ -309,6 +346,24 @@ export default {
return result.join(' || ')
},
+ _getParentNameByField() {
+ const fields = this.field.split(',');
+ let where_field = null;
+ for (let i = 0; i < fields.length; i++) {
+ const items = fields[i].split('as');
+ if (items.length < 2) {
+ continue;
+ }
+ if (items[1].trim() === 'value') {
+ where_field = items[0].trim();
+ break;
+ }
+ }
+ return where_field
+ },
+ _isTreeView() {
+ return (this.parentField && this.selfField)
+ },
_updateSelected() {
var dl = this.dataList
var sl = this.selected
@@ -388,7 +443,7 @@ export default {
child[key] = node[key]
}
}
- if (parent_value !== null) {
+ if (parent_value !== undefined) {
child.parent_value = parent_value
}
result.push(child)
diff --git a/uni_modules/uni-data-picker/components/uni-data-pickerview/uni-data-pickerview.vue b/uni_modules/uni-data-picker/components/uni-data-pickerview/uni-data-pickerview.vue
index 80075ac59bfcd0beac42bd3da19cde171e6d4314..ad0c275ae36c4475e00c6d4f3bc9de06d222a817 100644
--- a/uni_modules/uni-data-picker/components/uni-data-pickerview/uni-data-pickerview.vue
+++ b/uni_modules/uni-data-picker/components/uni-data-pickerview/uni-data-pickerview.vue
@@ -110,6 +110,11 @@
hasNodes
} = this._updateBindData()
+ if (!this._isTreeView()) {
+ this.onSelectedChange(node, true)
+ return
+ }
+
if (this.isLocaldata && (!hasNodes || isleaf)) {
this.onSelectedChange(node, true)
return
diff --git a/uni_modules/uni-data-picker/package.json b/uni_modules/uni-data-picker/package.json
index 72cd4ce06afc80f196e6e098dda0589c9e380afb..ece35f4c959d95001608eb60daf20792d715111d 100644
--- a/uni_modules/uni-data-picker/package.json
+++ b/uni_modules/uni-data-picker/package.json
@@ -1,7 +1,7 @@
{
"id": "uni-data-picker",
"displayName": "DataPicker 数据驱动的picker选择器",
- "version": "0.2.0",
+ "version": "0.3.1",
"description": "Picker选择器",
"keywords": [
"",
diff --git a/uni_modules/uni-data-picker/readme.md b/uni_modules/uni-data-picker/readme.md
index 350f5a53214ccff9a4b4f4868d7dd1e1f250aac1..9c64fe9680b5a80c4edd46c3821e2d59fff29a0b 100644
--- a/uni_modules/uni-data-picker/readme.md
+++ b/uni_modules/uni-data-picker/readme.md
@@ -1,4 +1,5 @@
## DataPicker 级联选择
+> **组件名:uni-data-picker**
> 代码块: `uDataPicker`
> 关联组件:`uni-data-pickerview`、`uni-load-more`。
@@ -18,6 +19,7 @@
在uniCloud数据表中新建表“uni-id-address”和“opendb-city-china”,这2个表的schema自带foreignKey关联。在“uni-id-address”表的表结构页面使用schema2code生成前端页面,会自动生成地址管理的维护页面,自动从“opendb-city-china”表包含的中国所有省市区信息里选择地址。
+> **注意事项**
> 为了避免错误使用,给大家带来不好的开发体验,请在使用组件前仔细阅读下面的注意事项,可以帮你避免一些错误。
> - 组件需要依赖 `sass` 插件 ,请自行手动安装
> - 如使用过程中有任何问题,或者您对uni-ui有一些好的建议,欢迎加入 uni-ui 交流群:871950839
@@ -50,11 +52,12 @@
|parent-field |String | | |分步查询时父字段名称|
|collection |String | | |表名。支持输入多个表名,用 `,` 分割|
|field |String | | |查询字段,多个字段用 `,` 分割|
-|where |String | | |查询条件,内容较多,另见jql文档:[详情](https://uniapp.dcloud.net.cn/uniCloud/unicloud-db?id=jsquery)|
+|where |String | | |查询条件,内容较多,另见jql文档:[详情](https://uniapp.dcloud.net.cn/uniCloud/uni-clientDB?id=jsquery)|
|orderby |String | | |排序字段及正序倒叙设置|
|popup-title |String | | |弹出层标题|
+> ****
> `collection/where/orderby` 和 `` 的用法一致,[详情](https://uniapp.dcloud.net.cn/uniCloud/unicloud-db)
@@ -75,6 +78,7 @@
#### 云端数据
+> **注意事项**
> - 云端数据需要关联服务空间
> - 下面示例中使用的表 `opendb-city-china`(中国城市省市区数据,含港澳台), 在[uniCloud控制台](https://unicloud.dcloud.net.cn/)使用opendb创建,[详情](https://gitee.com/dcloud/opendb)
@@ -82,12 +86,14 @@
```html
-
+```
+```js
+
+
diff --git a/uni_modules/uni-list/components/uni-list-item/uni-list-item.vue b/uni_modules/uni-list/components/uni-list-item/uni-list-item.vue
index f5d744a79f4f21aae60c1bd9a9345191b7d23d8a..7f1eced06f74880838557eaf162f6cc295d9a3ac 100644
--- a/uni_modules/uni-list/components/uni-list-item/uni-list-item.vue
+++ b/uni_modules/uni-list/components/uni-list-item/uni-list-item.vue
@@ -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;
- margin-right: 10px;
+ marin-right: 10px;
}
.uni-icon-wrapper {
diff --git a/uni_modules/uni-login-page/pages/index/phone-code.vue b/uni_modules/uni-login-page/pages/phone-code/phone-code.vue
similarity index 100%
rename from uni_modules/uni-login-page/pages/index/phone-code.vue
rename to uni_modules/uni-login-page/pages/phone-code/phone-code.vue
diff --git a/uni_modules/uni-login-page/pages/index/pwd-login.vue b/uni_modules/uni-login-page/pages/pwd-login/pwd-login.vue
similarity index 100%
rename from uni_modules/uni-login-page/pages/index/pwd-login.vue
rename to uni_modules/uni-login-page/pages/pwd-login/pwd-login.vue
diff --git a/uni_modules/uni-login-page/pages/index/pwd-retrieve.vue b/uni_modules/uni-login-page/pages/pwd-retrieve/pwd-retrieve.vue
similarity index 100%
rename from uni_modules/uni-login-page/pages/index/pwd-retrieve.vue
rename to uni_modules/uni-login-page/pages/pwd-retrieve/pwd-retrieve.vue