diff --git a/app.js b/app.js
index 5b28c5c..f1ad011 100644
--- a/app.js
+++ b/app.js
@@ -16,6 +16,8 @@ App({
this.globalData.height = res.statusBarHeight
this.globalData.deviceInfo.statusHeight = res.statusBarHeight
this.globalData.deviceInfo.navigationHeight = menuButtonInfo.height + (menuButtonInfo.top - res.statusBarHeight) * 2
+ this.globalData.screen.height = res.screenHeight
+ this.globalData.screen.width = res.screenWidth
}
})
},
@@ -44,6 +46,10 @@ App({
deviceInfo: {
statusHeight: 20,
navigationHeight: 40
+ },
+ screen: {
+ width: 375,
+ height: 667
}
}
})
\ No newline at end of file
diff --git a/app.json b/app.json
index 9a5ac81..47a2295 100644
--- a/app.json
+++ b/app.json
@@ -127,7 +127,8 @@
"pages/groupBuyPublish/groupBuyPublish",
"pages/dropByPublish/dropByPublish",
"pages/noticeNewDetail/noticeNewDetail",
- "pages/noticeNewList/noticeNewList"
+ "pages/noticeNewList/noticeNewList",
+ "pages/scanCodeSignin/scanCodeSignin"
]
},
{
@@ -142,7 +143,10 @@
"pages/moduleList/moduleList",
"pages/reportIssue/reportIssue",
"pages/reportIssueList/reportIssueList",
- "pages/reportIssueDetail/reportIssueDetail"
+ "pages/reportIssueDetail/reportIssueDetail",
+ "pages/suggestDict/suggestDict",
+ "pages/suggestDictList/suggestDictList",
+ "pages/suggestDetail/suggestDetail"
]
}
],
diff --git a/images/home/happy.png b/images/home/happy.png
deleted file mode 100644
index b06468b..0000000
Binary files a/images/home/happy.png and /dev/null differ
diff --git a/images/home/scan.png b/images/home/scan.png
new file mode 100644
index 0000000..528ee06
Binary files /dev/null and b/images/home/scan.png differ
diff --git a/pages/heartNew/heartNew.js b/pages/heartNew/heartNew.js
index a39ea48..436e1f3 100644
--- a/pages/heartNew/heartNew.js
+++ b/pages/heartNew/heartNew.js
@@ -49,6 +49,8 @@ Page({
}
],
isLoading: false, //防止标签切换加载数据时点击切换标签
+ btnTop: 0,
+ btnLeft: 0,
},
/**
@@ -73,6 +75,10 @@ Page({
selectedTab:this.data.selectedTab
}
this.selectComponent("#state-0").getActivityList(parms)
+ this.setData({
+ btnTop: app.globalData.screen.height * 2 * 0.75,
+ btnLeft: (app.globalData.screen.width * 2 - 200) * 0.5
+ })
},
/**
* 生命周期函数--监听页面初次渲染完成
@@ -526,5 +532,30 @@ Page({
volunteerTagId: this.data.volunteerTagId
}
this.volunteerlist(parms)
- }
+ },
+ //扫描签到码
+ scanCode () {
+ wx.scanCode({
+ onlyFromCamera: false,
+ scanType: ['barCode', 'qrCode', 'datamatrix', 'pdf417'],
+ success: res => {
+ if (res.errMsg == 'scanCode:ok') {
+ wx.navigateTo({
+ url: `/subpages/heart/pages/scanCodeSignin/scanCodeSignin?id=${res.result}`
+ })
+ }
+ },
+ fail: res => {
+ // 接口调用失败
+ // wx.showToast({
+ // icon: 'none',
+ // title: '接口调用失败!'
+ // })
+ },
+ complete: res => {
+ // 接口调用结束
+ console.log(res)
+ }
+ });
+ },
})
\ No newline at end of file
diff --git a/pages/heartNew/heartNew.wxml b/pages/heartNew/heartNew.wxml
index db03e2c..f5362b8 100644
--- a/pages/heartNew/heartNew.wxml
+++ b/pages/heartNew/heartNew.wxml
@@ -119,5 +119,15 @@
button-left="520"
img-url="../../images/heart/apply-new.png"
bindmovebtnCallBack="myApply">
+
\ No newline at end of file
diff --git a/pages/toRegister/toRegister.js b/pages/toRegister/toRegister.js
index 1051f25..bb84ec5 100644
--- a/pages/toRegister/toRegister.js
+++ b/pages/toRegister/toRegister.js
@@ -21,7 +21,7 @@ Page({
// }
// })
let that = this
- const versionNum = "1.6.25"
+ const versionNum = "1.6.27"
api.getScanSwitch(versionNum).then(function (res) {
console.log(res.data)
let state = res.data.scanFlag
diff --git a/subpages/heart/pages/scanCodeSignin/scanCodeSignin.js b/subpages/heart/pages/scanCodeSignin/scanCodeSignin.js
new file mode 100644
index 0000000..22b197e
--- /dev/null
+++ b/subpages/heart/pages/scanCodeSignin/scanCodeSignin.js
@@ -0,0 +1,69 @@
+// subpages/heart/pages/scanCodeSignin/scanCodeSignin.js
+import { getActInfo, signIn } from '../../../../utils/api'
+Page({
+
+ /**
+ * 页面的初始数据
+ */
+ data: {
+ actId: '',
+ actInfo: {}, //活动信息
+ dialogVisible: false, //提示框
+ lock: false, //debounce
+ },
+
+ /**
+ * 生命周期函数--监听页面加载
+ */
+ onLoad: function (options) {
+ this.setData({
+ actId: options.id
+ })
+ this.getActInfo()
+ },
+
+ //获取活动信息
+ getActInfo () {
+ let para = {
+ qrCodeId: this.data.actId
+ }
+ getActInfo(para).then(res => {
+ this.setData({
+ actInfo: res.data
+ })
+ })
+ },
+ //签到
+ signin () {
+ if (this.data.lock) {
+ wx.showToast({
+ title: '签到中...',
+ icon: 'loading',
+ duration: 2000
+ })
+ return
+ }
+ this.data.lock = true
+ console.log('签到状态:', this.data.actInfo.signInStatus)
+ if (this.data.actInfo.signInStatus == 0) {
+ let para = {
+ actId: this.data.actInfo.id
+ }
+ signIn(para).then(res => {
+ console.log(res.data)
+ if(res.code == 0) {
+ this.setData({
+ dialogVisible: !this.data.dialogVisible
+ })
+ }
+ }).catch(err => {
+ console.log(err)
+ this.data.lock = false
+ })
+ }
+ },
+ //
+ closeDialog () {
+ wx.navigateBack()
+ },
+})
\ No newline at end of file
diff --git a/subpages/heart/pages/scanCodeSignin/scanCodeSignin.json b/subpages/heart/pages/scanCodeSignin/scanCodeSignin.json
new file mode 100644
index 0000000..d8d2bac
--- /dev/null
+++ b/subpages/heart/pages/scanCodeSignin/scanCodeSignin.json
@@ -0,0 +1,9 @@
+{
+ "usingComponents": {
+ "wux-cell": "../../../../dist/cell/index",
+ "notice": "../../components/notice/notice"
+ },
+ "navigationBarTitleText": "活动签到",
+ "navigationBarTextStyle": "white",
+ "navigationBarBackgroundColor": "#d53534"
+}
\ No newline at end of file
diff --git a/subpages/heart/pages/scanCodeSignin/scanCodeSignin.wxml b/subpages/heart/pages/scanCodeSignin/scanCodeSignin.wxml
new file mode 100644
index 0000000..10fbd79
--- /dev/null
+++ b/subpages/heart/pages/scanCodeSignin/scanCodeSignin.wxml
@@ -0,0 +1,29 @@
+
+
+
+
+
+
+
+
+
+ {{actInfo.title}}
+ 奖励积分: +{{actInfo.reward}}
+
+
+
+ 签到时间:{{common.cutTime(actInfo.signinStartTime)}} 至 {{common.cutTime(actInfo.signinEndTime)}}
+
+
+
+
+ 已签到
+ 签到
+
+
+
+
+
+
+ module.exports.cutTime = function(time) { return time.substring(0,16) }
+
\ No newline at end of file
diff --git a/subpages/heart/pages/scanCodeSignin/scanCodeSignin.wxss b/subpages/heart/pages/scanCodeSignin/scanCodeSignin.wxss
new file mode 100644
index 0000000..1ddd2c8
--- /dev/null
+++ b/subpages/heart/pages/scanCodeSignin/scanCodeSignin.wxss
@@ -0,0 +1,102 @@
+/* subpages/heart/pages/scanCodeSignin/scanCodeSignin.wxss */
+page {
+ overflow: hidden;
+}
+.background {
+ box-sizing: border-box;
+ width: 100%;
+ height: 80rpx;
+ background: #d53534;
+ position: absolute;
+ z-index: -1;
+ top: 0;
+}
+.actinfo {
+ width: 690rpx;
+ height: 300rpx;
+ margin: 40rpx auto 80rpx;
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+ justify-content: space-between;
+ background-color: #FFFFFF;
+ border-radius: 16rpx;
+ box-shadow: 10rpx 10rpx 10rpx #bfbfbf;
+ box-sizing: border-box;
+ padding: 20rpx;
+}
+.actinfo .top {
+ width: 100%;
+ display: flex;
+ justify-content: space-between;
+}
+.top .left {
+ width: 176rpx;
+ height: 200rpx;
+}
+.top .left .image {
+ width: 100%;
+ height: 100%;
+ border-radius: 10rpx;
+}
+.top .right {
+ width: 460rpx;
+ height: 200rpx;
+ display: flex;
+ flex-direction: column;
+ justify-content: space-between;
+}
+.top .right .act-title {
+ font-size: 36rpx;
+ font-family: PingFang SC;
+ font-weight: 500;
+ color: #333333;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ word-wrap:break-word;
+ display: -webkit-box;
+ -webkit-box-orient: vertical;
+ -webkit-line-clamp: 2;
+ display: -webkit-box;
+}
+.top .right .act-score {
+ font-size: 28rpx;
+ font-family: PingFang SC;
+ font-weight: 500;
+ color: #E96E00;
+}
+.actinfo .bottom {
+ font-size: 24rpx;
+ font-family: PingFang SC;
+ font-weight: 500;
+ color: #A8A8A8;
+ width: 100%;
+}
+
+.submit {
+ width: 592rpx;
+ height: 116rpx;
+ position: relative;
+ margin: 320rpx auto 0rpx;
+}
+.submit .submit-bk {
+ width: 100%;
+ height: 100%;
+ position: absolute;
+ z-index: -1;
+}
+.submit .submit-text {
+ font-size: 34rpx;
+ font-family: PingFang SC;
+ font-weight: 500;
+ color: #FFFFFF;
+ height: 100rpx;
+ line-height: 100rpx;
+ text-align: center;
+}
+.submit .disabled {
+ background-color: rgba(255,255,255,0.5);
+ border-radius: 100rpx;
+ height: 100%;
+ width: 100%;
+}
\ No newline at end of file
diff --git a/subpages/oneKeyService/images/suggest.png b/subpages/oneKeyService/images/suggest.png
new file mode 100644
index 0000000..e133c6b
Binary files /dev/null and b/subpages/oneKeyService/images/suggest.png differ
diff --git a/subpages/oneKeyService/pages/moduleList/moduleList.js b/subpages/oneKeyService/pages/moduleList/moduleList.js
index f70c72d..77e6d01 100644
--- a/subpages/oneKeyService/pages/moduleList/moduleList.js
+++ b/subpages/oneKeyService/pages/moduleList/moduleList.js
@@ -112,6 +112,15 @@ Page({
pid: this.data.moduleInfo.pid
}
api.moduleCategory(params).then(res => {
+ //为 多个悬浮按钮设置初始位置
+ if (this.data.pageIndex == 1) {
+ let index = 0
+ res.data.forEach(item => {
+ if (item.categoryType == 'module_category_type_button') {
+ item.startY = 600 + 200 * index++ + ''
+ }
+ })
+ }
this.setData({
modulelist: this.data.modulelist.concat(res.data),
loadMoreType: res.data.length === this.data.pageSize ? 'loading' : 'none',
@@ -326,7 +335,7 @@ Page({
this.getNoticelist(e.detail.newsCategoryId)
},
- //type-2 锦水清风-我要举报
+ //type-2 我的诉求 / 建议直通
toReportIssue (e) {
if (this.verifyCompleteInfo()) {
return false
@@ -335,6 +344,10 @@ Page({
wx.navigateTo({
url: "/subpages/oneKeyService/pages/reportIssue/reportIssue"
})
+ } else if (e.currentTarget.dataset.code == 'notice_jsqf_jyzt') {
+ wx.navigateTo({
+ url: "/subpages/oneKeyService/pages/suggestDict/suggestDict"
+ })
} else {
wx.showToast({
title: '暂未开放',
diff --git a/subpages/oneKeyService/pages/moduleList/moduleList.wxml b/subpages/oneKeyService/pages/moduleList/moduleList.wxml
index 43f2705..18afde4 100644
--- a/subpages/oneKeyService/pages/moduleList/moduleList.wxml
+++ b/subpages/oneKeyService/pages/moduleList/moduleList.wxml
@@ -48,7 +48,7 @@
-
- 举报电话:{{item.mobile}}
+ 联系电话:{{item.mobile}}
diff --git a/subpages/oneKeyService/pages/reportIssue/reportIssue.js b/subpages/oneKeyService/pages/reportIssue/reportIssue.js
index 2016777..0d553d3 100644
--- a/subpages/oneKeyService/pages/reportIssue/reportIssue.js
+++ b/subpages/oneKeyService/pages/reportIssue/reportIssue.js
@@ -103,20 +103,28 @@ Page({
onInputContent (e) {
this.setData({
- 'dataForm.content': e.detail.value
+ 'dataForm.content': e.detail.value.trim(' ')
})
},
onInputUser (e) {
this.setData({
- 'dataForm.reportUser': e.detail.value
+ 'dataForm.reportUser': e.detail.value.trim(' ')
})
},
onInputMobile (e) {
this.setData({
- 'dataForm.reportUserMobile': e.detail.value
+ 'dataForm.reportUserMobile': e.detail.value.trim(' ')
})
},
+ //去除 输入内容 首尾空格
+ contentTrim () {
+ this.setData({
+ 'dataForm.content': this.data.dataForm.content.trim(' '),
+ 'dataForm.reportUser': this.data.dataForm.reportUser.trim(' '),
+ 'dataForm.reportUserMobile': this.data.dataForm.reportUserMobile.trim(' ')
+ })
+ },
//提交申请
submitIssue () {
if (!this.data.isAgree) {
@@ -127,6 +135,7 @@ Page({
this.showToast("正在提交,请耐心等待...")
return false
}
+ this.contentTrim()
if (!this.data.dataForm.content) {
this.showToast("请填写诉求内容")
return false
diff --git a/subpages/oneKeyService/pages/suggestDetail/suggestDetail.js b/subpages/oneKeyService/pages/suggestDetail/suggestDetail.js
new file mode 100644
index 0000000..d2a8f4a
--- /dev/null
+++ b/subpages/oneKeyService/pages/suggestDetail/suggestDetail.js
@@ -0,0 +1,31 @@
+const api = require("../../../../utils/api")
+
+Page({
+
+ /**
+ * 页面的初始数据
+ */
+ data: {
+ suggestId: '',
+ suggestDetail: {}
+ },
+
+ /**
+ * 生命周期函数--监听页面加载
+ */
+ onLoad: function (options) {
+ this.setData({
+ suggestId: options.id
+ })
+ this.getSuggestDetail()
+ },
+
+ getSuggestDetail () {
+ api.suggestDetail(this.data.suggestId).then(res => {
+ // console.log(res.data)
+ this.setData({
+ suggestDetail: res.data
+ })
+ })
+ },
+})
\ No newline at end of file
diff --git a/subpages/oneKeyService/pages/suggestDetail/suggestDetail.json b/subpages/oneKeyService/pages/suggestDetail/suggestDetail.json
new file mode 100644
index 0000000..6cc6631
--- /dev/null
+++ b/subpages/oneKeyService/pages/suggestDetail/suggestDetail.json
@@ -0,0 +1,4 @@
+{
+ "navigationBarTitleText": "建议详情",
+ "usingComponents": {}
+}
\ No newline at end of file
diff --git a/subpages/oneKeyService/pages/suggestDetail/suggestDetail.wxml b/subpages/oneKeyService/pages/suggestDetail/suggestDetail.wxml
new file mode 100644
index 0000000..8eb66e2
--- /dev/null
+++ b/subpages/oneKeyService/pages/suggestDetail/suggestDetail.wxml
@@ -0,0 +1,28 @@
+
+
+
+ 建议内容
+ {{suggestDetail.content}}
+
+
+ 是否匿名
+
+ {{suggestDetail.anonymousFlag=='1'?'是':'否'}}
+
+
+
+
+ 建议人姓名
+ {{suggestDetail.adviceUser}}
+
+
+ 建议人电话
+ {{suggestDetail.adviceUserMobile}}
+
+
+
+ 建议时间
+ {{suggestDetail.createdTime}}
+
+
+
diff --git a/subpages/oneKeyService/pages/suggestDetail/suggestDetail.wxss b/subpages/oneKeyService/pages/suggestDetail/suggestDetail.wxss
new file mode 100644
index 0000000..fb3a127
--- /dev/null
+++ b/subpages/oneKeyService/pages/suggestDetail/suggestDetail.wxss
@@ -0,0 +1,40 @@
+page {
+ width: 100%;
+ height: auto;
+ overflow-y: auto;
+ background: #f7f7f7;
+}
+.suggest-detail {
+ margin-bottom: 60rpx;
+}
+.suggest-detail .suggest-item {
+ width: 100%;
+ background-color: white;
+ display: flex;
+ flex-direction: column;
+ align-items: flex-start;
+ justify-content: center;
+ padding: 40rpx 30rpx;
+ margin-top: 16rpx;
+ box-sizing: border-box;
+}
+.suggest-detail .suggest-item .item-title {
+ font-size: 32rpx;
+ font-family: PingFang SC;
+ font-weight: bold;
+ color: #333333;
+}
+.suggest-detail .suggest-item .item-content {
+ font-size: 32rpx;
+ font-family: PingFang SC;
+ font-weight: 500;
+ color: #666666;
+ margin-top: 28rpx;
+}
+.suggest-detail .suggest-item .line {
+ width: 100%;
+ height: 1px;
+ background: #F2F2F2;
+ border-radius: 1px;
+ margin: 28rpx 0rpx;
+}
\ No newline at end of file
diff --git a/subpages/oneKeyService/pages/suggestDict/suggestDict.js b/subpages/oneKeyService/pages/suggestDict/suggestDict.js
new file mode 100644
index 0000000..abd84eb
--- /dev/null
+++ b/subpages/oneKeyService/pages/suggestDict/suggestDict.js
@@ -0,0 +1,274 @@
+const api = require("../../../../utils/api")
+//const understand_api = require("../../../../utils/understandJs")
+
+Page({
+
+ /**
+ * 页面的初始数据
+ */
+ data: {
+ //showPicker: false, //是否显示底部时间选择器插件
+ dataForm: {
+ content: '',
+ anonymousFlag: '1', //0-不匿名 1-匿名
+ adviceUser: '',
+ adviceUserMobile: '',
+ images: [] //当前未要求
+ },
+ dialogVisible: false, //提示框
+ dialogTitle: '提交成功', //提交提示,成功还是失败
+ errMsg: [], //提交失败msg
+ lock: false, //锁定提交状态,防止连击,
+ violationsCount: 0, //内容审核计数
+ isConReview: false, //内容审核标志
+ //isAgree: false, //是否 勾选已阅读
+ //agreement: {}, //须知内容
+ //agreementVisible: false, //是否显示 诉求须知 内容
+ },
+
+ /**
+ * 生命周期函数--监听页面加载
+ */
+ onLoad: function (options) {
+ // 获取须知内容
+ // let params = {
+ // pageIndex: 1,
+ // pageSize: 10,
+ // noticeCategory: 'notice_jsqf_wyjb'
+ // }
+ // understand_api.noticelist(params).then(res => {
+ // console.log(res.data[0])
+ // this.data.agreement = { ...res.data[0] }
+ // this.setData({
+ // agreement: this.data.agreement
+ // })
+ // }).catch(err => { })
+ },
+
+ /**
+ * 生命周期函数--监听页面初次渲染完成
+ */
+ onReady: function () {
+
+ },
+
+ /**
+ * 生命周期函数--监听页面显示
+ */
+ onShow: function () {
+
+ },
+
+ /**
+ * 生命周期函数--监听页面隐藏
+ */
+ onHide: function () {
+
+ },
+
+ /**
+ * 生命周期函数--监听页面卸载
+ */
+ onUnload: function () {
+
+ },
+
+ /**
+ * 页面相关事件处理函数--监听用户下拉动作
+ */
+ onPullDownRefresh: function () {
+
+ },
+
+ /**
+ * 页面上拉触底事件的处理函数
+ */
+ onReachBottom: function () {
+
+ },
+
+ /**
+ * 用户点击右上角分享
+ */
+ // onShareAppMessage: function () {
+
+ // }
+
+ //是否匿名
+ onChangeRadio (e) {
+ this.setData({
+ 'dataForm.anonymousFlag': e.currentTarget.dataset.flag
+ })
+ },
+
+ onInputContent (e) {
+ this.setData({
+ 'dataForm.content': e.detail.value.trim(' ')
+ })
+ },
+ onInputUser (e) {
+ this.setData({
+ 'dataForm.adviceUser': e.detail.value.trim(' ')
+ })
+ },
+ onInputMobile (e) {
+ this.setData({
+ 'dataForm.adviceUserMobile': e.detail.value.trim(' ')
+ })
+ },
+ //去除 输入内容 首尾空格
+ contentTrim () {
+ this.setData({
+ 'dataForm.content': this.data.dataForm.content.trim(' '),
+ 'dataForm.adviceUser': this.data.dataForm.adviceUser.trim(' '),
+ 'dataForm.adviceUserMobile': this.data.dataForm.adviceUserMobile.trim(' ')
+ })
+ },
+ //提交申请
+ submitIssue () {
+ // if (!this.data.isAgree) {
+ // this.showToast("请先勾选我已阅读并同意诉求须知")
+ // return false
+ // }
+ if (this.data.lock) {
+ this.showToast("正在提交,请耐心等待...")
+ return false
+ }
+
+ this.contentTrim()
+ if (!this.data.dataForm.content) {
+ this.showToast("请填写建议内容")
+ return false
+ }
+ if ( this.data.dataForm.anonymousFlag == '0') {
+ if (!this.data.dataForm.adviceUser) {
+ this.showToast("请填写建议人姓名")
+ return false
+ }
+ if (this.data.dataForm.adviceUser.length > 50) {
+ this.showToast("姓名超过字符限制(50字以内)")
+ return false
+ }
+ if (!this.data.dataForm.adviceUserMobile) {
+ this.showToast("请填写建议人电话")
+ return false
+ }
+ if (this.data.dataForm.adviceUserMobile.length > 20) {
+ this.showToast("电话号码超过字符限制(20位)")
+ return false
+ }
+ }
+ wx.showLoading({
+ title: "加载中",
+ })
+ this.setData({
+ lock: true
+ })
+ const para = { ...this.data.dataForm }
+ para.isConReview = this.data.isConReview
+ console.log('submit suggest', para)
+ let that = this
+ api.suggestDict(para).then(res => {
+ wx.hideLoading()
+ this.setData({
+ lock: false
+ })
+ if (res.code == 0 && res.msg == 'success') {
+ this.data.errMsg = []
+ this.setData({
+ 'dataForm.content': '',
+ dialogTitle: '提交成功',
+ errMsg: this.data.errMsg,
+ dialogVisible: !this.data.dialogVisible,
+ violationsCount: 0,
+ isConReview: false
+ })
+ // wx.navigateBack()
+ } else if (res.code == 533) {
+ this.data.violationsCount++
+ console.log(this.data.violationsCount)
+ if (this.data.violationsCount == 1){
+ wx.showToast({
+ title: res.msg,
+ icon: "none",
+ duration: 2000
+ })
+ } else if (this.data.violationsCount == 2) {
+ wx.showModal({
+ title: '提示',
+ content: '您提交的内容再次被判定为违规,您确定是否要提交?',
+ success (res) {
+ if (res.confirm) {
+ console.log('用户点击确定')
+ that.data.isConReview = true
+ that.submitIssue()
+ } else if (res.cancel) {
+ console.log('用户点击取消')
+ that.setData({
+ violationsCount: 0,
+ isConReview: false
+ })
+ }
+ }
+ })
+ }
+ } else {
+ this.data.errMsg[0] = res.msg
+ this.setData({
+ dialogTitle: '提交失败',
+ errMsg: this.data.errMsg,
+ dialogVisible: !this.data.dialogVisible
+ })
+ }
+ }).catch(err => {
+ console.log(err)
+ wx.hideLoading()
+ this.setData({
+ lock: false
+ })
+ })
+ },
+
+ //简化提示
+ showToast (title) {
+ wx.showToast({
+ title: title,
+ icon: "none",
+ duration: 2000
+ })
+ },
+ //跳转到我的列表
+ toSuggestList () {
+ wx.navigateTo({
+ url: "/subpages/oneKeyService/pages/suggestDictList/suggestDictList"
+ })
+ },
+
+ //弹框确定按钮
+ confirmDialog () {
+ if (this.data.errMsg.length == 0) {
+ wx.navigateBack()
+ }
+ },
+
+ // 选择已阅读
+ // checkboxChange (e) {
+ // let value = e.detail.value
+ // this.setData({
+ // isAgree: value.length > 0 ? true : false
+ // })
+ // },
+
+ //是否显示 诉求须知 对话框
+ // showAgreement () {
+ // this.setData({
+ // agreementVisible: true
+ // })
+ // },
+ // 关闭 诉求须知 回调函数
+ // confirmAgreement () {
+ // this.setData({
+ // agreementVisible: false
+ // })
+ // }
+})
\ No newline at end of file
diff --git a/subpages/oneKeyService/pages/suggestDict/suggestDict.json b/subpages/oneKeyService/pages/suggestDict/suggestDict.json
new file mode 100644
index 0000000..63b3c8a
--- /dev/null
+++ b/subpages/oneKeyService/pages/suggestDict/suggestDict.json
@@ -0,0 +1,7 @@
+{
+ "navigationBarTitleText": "建议直通",
+ "usingComponents": {
+ "notice": "../../compontents/notice/notice",
+ "rich-text-dialog": "../../compontents/richTextDialog/richTextDialog"
+ }
+}
\ No newline at end of file
diff --git a/subpages/oneKeyService/pages/suggestDict/suggestDict.wxml b/subpages/oneKeyService/pages/suggestDict/suggestDict.wxml
new file mode 100644
index 0000000..877eb7d
--- /dev/null
+++ b/subpages/oneKeyService/pages/suggestDict/suggestDict.wxml
@@ -0,0 +1,48 @@
+
+
+
+
+
+
+ 建议描述
+
+
+
+ 是否匿名
+
+
+
+
+ 是
+
+
+
+
+
+ 否
+
+
+
+
+
+
+
+
+
+
+
+
+ 提交
+
+
+
+
+
+
\ No newline at end of file
diff --git a/subpages/oneKeyService/pages/suggestDict/suggestDict.wxss b/subpages/oneKeyService/pages/suggestDict/suggestDict.wxss
new file mode 100644
index 0000000..dceddf6
--- /dev/null
+++ b/subpages/oneKeyService/pages/suggestDict/suggestDict.wxss
@@ -0,0 +1,141 @@
+page {
+ width: 100%;
+ overflow-y: auto;
+ background: #f7f7f7;
+}
+.suggest-list {
+ position: relative;
+ overflow: hidden;
+}
+.suggest-list .suggest-dict-img {
+ position: absolute;
+ right: -10rpx;
+ top: 16rpx;
+}
+.suggest-list .suggest-dict-img image {
+ width: 164rpx;
+ height: 76rpx;
+}
+.suggest-list .issue-item {
+ width: 100%;
+ background-color: white;
+ display: flex;
+ flex-direction: column;
+ align-items: flex-start;
+ justify-content: center;
+ padding: 0rpx 30rpx;
+ margin-top: 16rpx;
+ box-sizing: border-box;
+}
+.suggest-list .agree-box {
+ height: 80rpx;
+ display: flex;
+ align-items: center;
+ margin-top: 20rpx;
+}
+.suggest-list .agree-box .checkbox-group {
+ display: flex;
+ align-items: center;
+ justify-content: center;
+}
+.suggest-list .agree-box .checkbox {
+ margin-left: 22rpx;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+}
+.suggest-list .agree-box .checkbox checkbox {
+ transform: scale(0.7);
+}
+.suggest-list .agree-box .agreement {
+ color: cornflowerblue;
+}
+.suggest-list .text-item {
+ height: 450rpx;
+}
+.line {
+ width: 690rpx;
+ height: 1px;
+ background: #DCDCDC;
+ border-radius: 1px;
+}
+.line2 {
+ width: 625rpx;
+ height: 1px;
+ background: #DCDCDC;
+ border-radius: 1px;
+}
+.suggest-list .issue-item .item-title {
+ height: 50rpx;
+ line-height: 50rpx;
+ font-size: 32rpx;
+ font-family: PingFang SC;
+ font-weight: bold;
+ color: #333333;
+ margin: 28rpx 0rpx 12rpx 0rpx;
+}
+.suggest-list .issue-item .item-content {
+ width: 100%;
+ height: 44rpx;
+ line-height: 44rpx;
+ font-size: 32rpx;
+ font-family: PingFang SC;
+ font-weight: 500;
+ color: #666666;
+}
+.suggest-list .issue-item .text-content {
+ font-weight: 400;
+ height: 350rpx;
+}
+.submit {
+ width: 592rpx;
+ height: 116rpx;
+ position: relative;
+ margin: 68rpx auto 0rpx;
+}
+.submit .submit-bk {
+ width: 100%;
+ height: 100%;
+ position: absolute;
+ z-index: -1;
+}
+.submit .submit-text {
+ font-size: 34rpx;
+ font-family: PingFang SC;
+ font-weight: 500;
+ color: #FFFFFF;
+ height: 100rpx;
+ line-height: 100rpx;
+ text-align: center;
+}
+
+.radio-group {
+ width: 100%;
+}
+.radio-group .radio-item:first-child {
+ margin-top: 0rpx;
+}
+.radio-group .radio-item {
+ display: flex;
+ justify-content: flex-start;
+ align-items: center;
+ margin: 30rpx 0rpx;
+}
+.radio-group .radio-item .radio-img {
+ width: 34rpx;
+ height: 34rpx;
+}
+.radio-group .radio-item .radio-text {
+ margin-left: 32rpx;
+ font-size: 32rpx;
+ font-family: PingFang SC;
+ font-weight: 500;
+ color: #666666;
+}
+.radio-group .radio-info {
+ margin-left: 66rpx;
+}
+.radio-group .radio-info .info {
+ margin: 30rpx 0rpx;
+}
+
diff --git a/subpages/oneKeyService/pages/suggestDictList/suggestDictList.js b/subpages/oneKeyService/pages/suggestDictList/suggestDictList.js
new file mode 100644
index 0000000..e680675
--- /dev/null
+++ b/subpages/oneKeyService/pages/suggestDictList/suggestDictList.js
@@ -0,0 +1,75 @@
+const api = require("../../../../utils/api")
+
+Page({
+
+ /**
+ * 页面的初始数据
+ */
+ data: {
+ pageIndex: 1,
+ pageSize: 10,
+ nodata: false,
+ loadMoreType: 'none',
+ loadMoreVisible: false,
+ suggestlist: []
+ },
+
+ /**
+ * 生命周期函数--监听页面加载
+ */
+ onLoad: function (options) {
+ this.getSuggestList()
+ },
+
+ /**
+ * 页面上拉触底事件的处理函数
+ */
+ onReachBottom: function () {
+ this.setData({
+ loadMoreVisible: true
+ })
+ if (this.data.loadMoreType === "loading") {
+ this.setData({
+ pageIndex: this.data.pageIndex + 1
+ })
+ this.getSuggestList()
+ }
+ },
+
+ getSuggestList () {
+ const para = {
+ pageIndex: this.data.pageIndex,
+ pageSize: this.data.pageSize
+ }
+ api.suggestDictList(para).then(res => {
+ console.log(res)
+ this.setData({
+ suggestlist: [...this.data.suggestlist,...res.data],
+ loadMoreType: res.data.length === this.data.pageSize ? 'loading' : 'none',
+ loadMoreVisible: res.data.length === this.data.pageSize ? false : true
+ })
+ if (this.data.suggestlist.length == 0) {
+ this.setData({
+ nodata: true,
+ loadMoreType: 'none',
+ loadMoreVisible: false,
+ })
+ }
+ }).catch(err => {
+ this.setData({
+ suggestlist: [],
+ nodata: true,
+ loadMoreType: 'none',
+ loadMoreVisible: false,
+ })
+ console.log(err)
+ })
+ },
+ //跳转到申请信息详情
+ toSuggestDetail (e) {
+ console.log('跳转详情', e.currentTarget.dataset.id)
+ wx.navigateTo({
+ url: `/subpages/oneKeyService/pages/suggestDetail/suggestDetail?id=${e.currentTarget.dataset.id}`
+ })
+ }
+})
\ No newline at end of file
diff --git a/subpages/oneKeyService/pages/suggestDictList/suggestDictList.json b/subpages/oneKeyService/pages/suggestDictList/suggestDictList.json
new file mode 100644
index 0000000..2675ea5
--- /dev/null
+++ b/subpages/oneKeyService/pages/suggestDictList/suggestDictList.json
@@ -0,0 +1,7 @@
+{
+ "navigationBarTitleText": "建议记录",
+ "usingComponents": {
+ "load-more": "/components/loadMore/loadMore",
+ "no-data": "/components/nodata/nodata"
+ }
+}
\ No newline at end of file
diff --git a/subpages/oneKeyService/pages/suggestDictList/suggestDictList.wxml b/subpages/oneKeyService/pages/suggestDictList/suggestDictList.wxml
new file mode 100644
index 0000000..8808164
--- /dev/null
+++ b/subpages/oneKeyService/pages/suggestDictList/suggestDictList.wxml
@@ -0,0 +1,13 @@
+
+
+
+ {{item.content}}
+
+ 提交时间:{{item.createdTime}}
+
+
+
+
+
+
+
diff --git a/subpages/oneKeyService/pages/suggestDictList/suggestDictList.wxss b/subpages/oneKeyService/pages/suggestDictList/suggestDictList.wxss
new file mode 100644
index 0000000..ecbd959
--- /dev/null
+++ b/subpages/oneKeyService/pages/suggestDictList/suggestDictList.wxss
@@ -0,0 +1,75 @@
+page {
+ width: 100%;
+ height: auto;
+ overflow-y: auto;
+ background: #f7f7f7;
+}
+.suggest-list {
+
+}
+.suggest-list .suggest-item {
+ width: 100%;
+ background-color: white;
+ display: flex;
+ flex-direction: column;
+ align-items: flex-start;
+ justify-content: center;
+ padding: 0rpx 30rpx 30rpx;
+ margin-top: 16rpx;
+ box-sizing: border-box;
+}
+.suggest-list .suggest-item .item-title {
+ font-size: 32rpx;
+ font-family: PingFang SC;
+ font-weight: bold;
+ color: #333333;
+ margin: 32rpx 0rpx;
+ overflow: hidden;
+ text-overflow: ellipsis;
+ display: box;
+ display: -webkit-box;
+ -webkit-line-clamp: 2;
+ -webkit-box-orient: vertical;
+}
+.suggest-list .suggest-item .item-content {
+ width: 100%;
+ height: 44rpx;
+ line-height: 44rpx;
+ font-size: 32rpx;
+ font-family: PingFang SC;
+ font-weight: 500;
+ color: #999999;
+}
+.suggest-list .suggest-item .text-content {
+ height: 88rpx;
+ color: #666666;
+}
+.suggest-list .suggest-item .line {
+ width: 100%;
+ height: 1px;
+ background: #F2F2F2;
+ border-radius: 1px;
+ margin: 28rpx 0rpx;
+}
+.suggest-list .suggest-item .item-time {
+ font-size: 30rpx;
+ font-family: PingFang SC;
+ font-weight: 400;
+ color: #666666;
+}
+.suggest-list .suggest-item .item-state {
+ margin: 26rpx 0rpx 28rpx;
+ font-size: 30rpx;
+ font-family: PingFang SC;
+ font-weight: 400;
+ color: #666666;
+}
+.suggest-list .suggest-item .item-state .state-0 {
+ color: #FB9F00;
+}
+.suggest-list .suggest-item .item-state .state-1 {
+ color: #28C896;
+}
+.suggest-list .suggest-item .item-state .state-2 {
+ color: #D80000;
+}
\ No newline at end of file
diff --git a/utils/api.js b/utils/api.js
index 975f322..73e1ae9 100644
--- a/utils/api.js
+++ b/utils/api.js
@@ -65,7 +65,12 @@ module.exports = {
reportIssue: reportIssue,
reportIssueList: reportIssueList,
reportIssueDetail: reportIssueDetail,
- getVolunteerTags: getVolunteerTags
+ getVolunteerTags: getVolunteerTags,
+ getActInfo: getActInfo,
+ signIn: signIn,
+ suggestDict: suggestDict,
+ suggestDictList: suggestDictList,
+ suggestDetail: suggestDetail
}
function getToken (wxCode) {
@@ -585,4 +590,25 @@ function reportIssueDetail (id) {
//志愿者标签列表
function getVolunteerTags () {
return fly.get(`app-user/volunteer/tags`)
+}
+//居民扫签到码获取活动信息接口
+function getActInfo (para) {
+ return fly.get(`act/actsignin/actInfo`, para)
+}
+// 居民签到打卡
+function signIn (para) {
+ return fly.post("act/actsignin/signin", para)
+}
+
+// 建议直通-我的建议
+function suggestDict (para) {
+ return fly.post("custom/advice/submit", para)
+}
+// 一键服务-建议直通-建议列表接口
+function suggestDictList(para) {
+ return fly.get('custom/advice/list', para)
+}
+//一键服务-建议直通-建议详情接口
+function suggestDetail (id) {
+ return fly.get(`custom/advice/detail/${id}`)
}
\ No newline at end of file