Forráskód Böngészése

设置修改 添加投诉意见 添加用户协议 隐私政策

wangxin 5 éve
szülő
commit
2f23641fdf

+ 3 - 0
api/api.js

@@ -70,6 +70,9 @@ const url = {
   myHpAgencyFeeList: '/f/api/hpAgencyFee/myHpAgencyFeeList', // 返费列表
   myHpAgencyFeeDetail: '/f/api/hpAgencyFee/myHpAgencyFeeDetail', // 返费详情
   confirmHpAgencyFee: "/f/api/hpAgencyFee/confirmHpAgencyFee", // 入职奖励
+  saveHpComplaintAdvice: '/f/api/hpComplaintAdvice/saveHpComplaintAdvice',//保存投诉建议
+  saveHpUserLog: '/f/api/hpComplaintAdvice/saveHpUserLog',//保存日志
+  logout_new: '/f/api/login/logout_new',//注销账户
   /** +++++++++++++++++++++++++++  废弃接口 ++++++++++++++++++++++++++++++++++++++ */
   // userLogin: '/wxAppletsLogin/wxVoteLogin', // post ,根据微信CODE获取微信用户信息
   // userLogin: '/f/api/wxAppletsLogin/decodeUserInfo',

+ 12 - 0
app.js

@@ -10,6 +10,7 @@ import {
 import {
   wxLogin,
 } from './services/wx.js'
+import { saveHpUserLog } from './services/index'
 var startTime = Date.now(); //启动时间
 App({
   onLaunch: function (options) {
@@ -26,6 +27,17 @@ App({
       .then(res => {
         wx.aldPushSendOpenid(res.data.openId)
       })
+    const userId = wx.getStorageSync("user_id");
+    const userToken = wx.getStorageSync("user_token");
+    const memberId = wx.getStorageSync("member_id");
+    if (userId && userToken && memberId) {
+      saveHpUserLog({
+        user_id: userId,
+        user_token: userToken,
+        member_id: memberId,
+        login_type: 0
+      })
+    }
   },
   onShow(options) {
     //群聊信息

+ 10 - 2
app.json

@@ -22,7 +22,7 @@
     "pages/user-job/index",
     "pages/user-works/index",
     "pages/apply-list/index",
-    "pages/about/index",
+ 
     "pages/share/index",
     "pages/check-iphone/index",
     "pages/bind-pt/index",
@@ -52,7 +52,7 @@
     "pages/pt-tip/index",
     "pages/collection-list/index",
     "pages/interview/index",
-    "pages/set/index",
+   
     "pages/address/index",
     "pages/bind-phone/index",
     "pages/bind-phone/bind",
@@ -86,6 +86,14 @@
         "pages/withdrawal/withdrawal",
         "pages/withdrawal-result/withdrawal-result"
       ]
+    },
+    {
+      "root": "pages/setting",
+      "pages":[
+        "pages/set/index",
+        "pages/suggestions/suggestions",
+        "pages/about/index"
+      ]
     }
   ],
   "window": {

+ 10 - 7
config/config.js

@@ -1,14 +1,17 @@
 // 测试服
-const apiUrl = "https://kf.hap-job.com/happyjob"
-const imgServerUrl = "https://hpjobtest.oss-cn-shanghai.aliyuncs.com/uploadfiles/mina"//静态资源图片服务器地址
-const imgServerUrl_new = "https://hpjobtest.oss-cn-shanghai.aliyuncs.com"//图片服务器地址
+// const apiUrl = "https://kf.hap-job.com/happyjob"
+// const rootUrl = "https://kf.hap-job.com"
+// const imgServerUrl = "https://hpjobtest.oss-cn-shanghai.aliyuncs.com/uploadfiles/mina"//静态资源图片服务器地址
+// const imgServerUrl_new = "https://hpjobtest.oss-cn-shanghai.aliyuncs.com"//图片服务器地址
 // 正式服
-// const apiUrl = "https://web.hap-job.com/happyjob"
-// const imgServerUrl = "https://happyjob.oss-cn-shanghai.aliyuncs.com/uploadfiles/mina" //图片服务器地址
-// const imgServerUrl_new = "https://happyjob.oss-cn-shanghai.aliyuncs.com" //图片服务器地址
+const apiUrl = "https://web.hap-job.com/happyjob"
+const rootUrl = "https://web.hap-job.com"
+const imgServerUrl = "https://happyjob.oss-cn-shanghai.aliyuncs.com/uploadfiles/mina" //图片服务器地址
+const imgServerUrl_new = "https://happyjob.oss-cn-shanghai.aliyuncs.com" //图片服务器地址
 
 module.exports = {
   apiUrl,
   imgServerUrl,
-  imgServerUrl_new
+  imgServerUrl_new,
+  rootUrl
 }

+ 0 - 6
pages/about/index.js

@@ -1,6 +0,0 @@
-import { imgServerUrl } from '../../config/config.js'
-Page({
-  data: {
-    imgServerUrl: imgServerUrl
-  },
-})

+ 5 - 0
pages/detail/index.js

@@ -785,4 +785,9 @@ Page({
       })
     })
   },
+  callPhone() {
+    wx.makePhoneCall({
+      phoneNumber: '4006920099',
+    })
+  }
 })

+ 2 - 1
pages/detail/index.wxml

@@ -613,12 +613,13 @@
 <view class="btn-group fixed-footer">
 	<form bindsubmit="applyJob" report-submit='true' wx:if="{{positionCategory!=4 && !isApply}}">
 		<view class="button">
+			<view class="call-kefu" bindtap='callPhone'>电话咨询</view>
 			<button class=" selfBtn" form-type="submit">投递简历</button>
 		</view>
 	</form>
 	<form bindsubmit="applyPt" report-submit='true' wx:if="{{positionCategory==4 && !isApply}}">
 		<view class="button">
-			<!-- <view class="collection" bindtap='favourate'>{{isFarovite?'已收藏':'收藏职位'}}</view> -->
+			<view class="call-kefu" bindtap='callPhone'>电话咨询</view>
 			<button class=" selfBtn" form-type="submit">申请开团</button>
 		</view>
 	</form>

+ 1 - 1
pages/detail/index.wxss

@@ -959,7 +959,7 @@ page {
   justify-content: space-between;
 }
 
-.collection {
+.call-kefu {
   width: 220rpx;
   height: 88rpx;
   color: #0177FF;

+ 7 - 0
pages/login/login.js

@@ -9,6 +9,7 @@ import {
   wxLogin,
   saveLogin
 } from '../../services/wx.js'
+import { saveHpUserLog } from '../../services/index'
 import {
   showToast
 } from '../../utils/tips.js'
@@ -79,6 +80,12 @@ Page({
                     app.userInfoReadyCallback(res)
                   }
                   showToast("登录成功");
+                  saveHpUserLog({
+                    user_id: data.data.hpUser.id,
+                    user_token: data.data.hpUser.userToken,
+                    member_id: data.data.hpMember.id,
+                    login_type: 0
+                  })
                   setTimeout(function () {
                     wx.navigateBack({
                       fail: () => {

+ 1 - 1
pages/mine/index.js

@@ -315,7 +315,7 @@ Page({
     }
     //设置
     wx.navigateTo({
-      url: '../set/index',
+      url: '../setting/pages/set/index',
     })
   },
   toPayRoll(e) {

+ 4 - 4
pages/mine/index.wxml

@@ -51,9 +51,9 @@
 	<view class='col'>
 	</view>
 
-	<view class='jianli' wx:if="{{isLogin}}">
+	<view class='jianli' wx:if="{{isLogin}}"  bindtap='tojianli'>
 		<view class="jianli-left">
-			<view class="jianli-title" bindtap='tojianli'>
+			<view class="jianli-title">
 				<text>我的简历</text>
 				<view class="edit" wx:if='{{percent === "100"}}' >
 					<image class="edit1" src="{{imgServerUrl}}/images/happyjob/edit1.png" />
@@ -172,8 +172,8 @@
 	</view>
 	<view class='query' bindtap='setup'>
 		<view class='querys'>
-			<image class='shezhi-image' src='{{imgServerUrl}}/images/happyjob/shezhi.png'></image>
-			<text class='queryxz'>设置</text>
+			<image class='shezhi-image' src='{{imgServerUrl}}/images/happyjob/gengduo.png'></image>
+			<text class='queryxz'>更多</text>
 		</view>
 		<view class="jiantou">
 			<image class='' src='{{imgServerUrl}}/images/happyjob/rightwjt.png'></image>

+ 0 - 80
pages/set/index.js

@@ -1,80 +0,0 @@
-import {
-  imgServerUrl
-} from '../../config/config.js'
-import {
-  showToast
-} from '../../utils/tips.js'
-var app = getApp()
-Page({
-
-  /**
-   * 页面的初始数据
-   */
-  data: {
-    imgServerUrl: imgServerUrl,
-  },
-
-  /**
-   * 生命周期函数--监听页面加载
-   */
-  onLoad: function(options) {
-
-  },
-  toclear() {
-    wx.showModal({
-      title: '清除缓存',
-      content: '是否清除所有缓存内容',
-      success(res) {
-        if (res.confirm) {
-          try {
-            wx.clearStorage({
-              success: function(res) {
-                wx.clearStorageSync()
-                app.globalData.userId = '';
-                app.globalData.userToken = '';
-                app.globalData.memberId = '';
-                app.globalData.userInfo = null;
-                showToast('清除成功')
-              }
-            })
-          } catch (e) {
-            // Do something when catch error
-          }
-        } else if (res.cancel) {
-          console.log('用户点击取消')
-        }
-      }
-    })
-  },
-  toabout() {
-    wx.navigateTo({
-      url: '../about/index',
-    })
-  },
-  login_out() {
-    wx.showModal({
-      title: '提示',
-      content: '确定退出登录吗?',
-      success: function(res) {
-        if (res.confirm) {
-          //清除登录缓存
-          wx.removeStorageSync("user_id");
-          wx.removeStorageSync("member_id");
-          wx.removeStorageSync("user_token");
-          wx.removeStorageSync("userInfo");
-          app.globalData.userId = '';
-          app.globalData.userToken = '';
-          app.globalData.memberId = '';
-          app.globalData.userInfo = null;
-          showToast('退出成功');
-          setTimeout(function () {
-            wx.navigateBack();
-          }, 500)
-        } else if (res.cancel) {
-
-        }
-      }
-    })
-  }
-
-})

+ 0 - 13
pages/set/index.wxml

@@ -1,13 +0,0 @@
-<view class='clear' bindtap='toclear'>
-  <view class='cleartip'>清除缓存</view>
-  <image class='jiantou' src='{{imgServerUrl}}/images/happyjob/rightwjt.png'></image>
-</view>
-
-<view class='about' bindtap='toabout'>
-  <view class='aboutus'>关于我们</view>
-  <image class='jiantou' src='{{imgServerUrl}}/images/happyjob/rightwjt.png'></image>
-</view>
-
-<view class='btn-group fixed-footer'>
-  <button class='selfBtn' bindtap='login_out'>退出登录</button>
-</view>

+ 0 - 69
pages/set/index.wxss

@@ -1,69 +0,0 @@
-.clear {
-  display: flex;
-  flex-direction: row;
-  justify-content: space-between;
-  align-items: center;
-  height: 76rpx;
-  width: 100%;
-  border-bottom: 1rpx solid rgba(221, 221, 221, 1);
-  border-top: 1rpx solid rgba(242, 242, 242, 1);
-}
-
-.cleartip {
-  font-size: 28rpx;
-  font-family: SourceHanSansCN-Regular;
-  font-weight: 400;
-  color: rgba(34, 34, 34, 1);
-  margin-left: 30rpx;
-}
-
-.jiantou {
-  width: 17rpx;
-  height: 29rpx;
-  margin-right: 30rpx;
-}
-
-.about {
-  display: flex;
-  flex-direction: row;
-  justify-content: space-between;
-  align-items: center;
-  height: 76rpx;
-  width: 100%;
-  border-bottom: 1rpx solid rgba(221, 221, 221, 1);
-}
-
-.aboutus {
-  font-size: 28rpx;
-  font-family: SourceHanSansCN-Regular;
-  font-weight: 400;
-  color: rgba(34, 34, 34, 1);
-  margin-left: 30rpx;
-}
-
-.fixed-footer {
-  position: fixed;
-  left: 0;
-  bottom: 0;
-  width: 100%;
-}
-
-.btn-group {
-  background: #fff;
-  padding: 20rpx;
-  box-sizing: border-box;
-}
-
-.selfBtn {
-  display: flex;
-  height: 88rpx;
-  line-height: 88rpx;
-  align-items: center;
-  justify-content: center;
-  background: linear-gradient(90deg, rgba(160, 164, 169, 1), rgba(199, 202, 205, 1));
-  border-radius: 42rpx;
-  font-size: 38rpx;
-  font-family: SourceHanSansCN-Normal;
-  font-weight: 400;
-  color: rgba(255, 254, 254, 1);
-}

+ 6 - 0
pages/setting/pages/about/index.js

@@ -0,0 +1,6 @@
+import { imgServerUrl } from '../../../../config/config.js'
+Page({
+  data: {
+    imgServerUrl: imgServerUrl
+  },
+})

pages/about/index.json → pages/setting/pages/about/index.json


pages/about/index.wxml → pages/setting/pages/about/index.wxml


pages/about/index.wxss → pages/setting/pages/about/index.wxss


+ 198 - 0
pages/setting/pages/set/index.js

@@ -0,0 +1,198 @@
+import {
+  imgServerUrl
+} from '../../../../config/config.js'
+import {
+  showToast
+} from '../../../../utils/tips.js'
+import { logout_new } from '../../../../services/index'
+import { rootUrl } from '../../../../config/config'
+var app = getApp()
+Page({
+
+  /**
+   * 页面的初始数据
+   */
+  data: {
+    rootUrl,
+    imgServerUrl: imgServerUrl,
+    visible: false,
+    actions: [
+      {
+        name: '确定注销',
+        color: '#0177FF',
+        fontWeight: 500
+      },
+      {
+        name: '取消',
+        color: '#0177FF',
+      },
+    ]
+  },
+
+  /**
+   * 生命周期函数--监听页面加载
+   */
+  onLoad: function (options) {
+
+  },
+  toclear() {
+    wx.showModal({
+      title: '清除缓存',
+      content: '是否清除所有缓存内容',
+      success(res) {
+        if (res.confirm) {
+          try {
+            wx.clearStorage({
+              success: function (res) {
+                wx.clearStorageSync()
+                app.globalData.userId = '';
+                app.globalData.userToken = '';
+                app.globalData.memberId = '';
+                app.globalData.userInfo = null;
+                showToast('清除成功')
+              }
+            })
+          } catch (e) {
+            // Do something when catch error
+          }
+        } else if (res.cancel) {
+          console.log('用户点击取消')
+        }
+      }
+    })
+  },
+  toabout() {
+    wx.navigateTo({
+      url: '../about/index',
+    })
+  },
+  updateVersion() {
+    // 小程序版本更新
+    if (wx.getUpdateManager) {
+      const updateManager = wx.getUpdateManager()
+      updateManager.onCheckForUpdate((res) => {
+        // 请求完新版本信息的回调
+        if (res.hasUpdate) {
+          updateManager.onUpdateReady(() => {
+            wx.showModal({
+              title: '更新提示',
+              content: '新版本已经准备好,是否重启应用?',
+              success: (res) => {
+                if (res.confirm) {
+                  // 新的版本已经下载好,调用 applyUpdate 应用新版本并重启
+                  wx.removeStorageSync("user_id");
+                  wx.removeStorageSync("member_id");
+                  wx.removeStorageSync("user_token");
+                  wx.removeStorageSync("userInfo");
+                  this.globalData.userId = '';
+                  this.globalData.userToken = '';
+                  this.globalData.memberId = '';
+                  this.globalData.userInfo = null;
+                  updateManager.applyUpdate()
+                }
+              }
+            })
+          })
+        } else {
+          wx.showToast({
+            icon: 'none',
+            title: '当前已经是最新版本了~',
+          })
+        }
+      })
+      updateManager.onUpdateFailed(function () {
+        // 新版本下载失败
+        wx.showToast({
+          icon: 'none',
+          title: '新版本下载失败请稍后重试!',
+        })
+      })
+    } else {
+      wx.showModal({
+        title: '提示',
+        showCancel: false,
+        content: '微信版本过低,请手动删除后重新搜索进入!'
+      })
+    }
+  },
+  toPage(e) {
+    const { url } = e.currentTarget.dataset;
+    wx.navigateTo({
+      url,
+    })
+  },
+  cancellation() {
+    this.setData({
+      visible: true
+    })
+  },
+  readFile() {
+    wx.downloadFile({
+      url: '../../docx/用户协议.docx',
+      success: res => {
+        console.log(res)
+      }
+    })
+    wx.openDocument({
+      filePath: '../../docx/用户协议.docx',
+    })
+  },
+  login_out() {
+    wx.showModal({
+      title: '提示',
+      content: '确定退出登录吗?',
+      success: function (res) {
+        if (res.confirm) {
+          //清除登录缓存
+          wx.removeStorageSync("user_id");
+          wx.removeStorageSync("member_id");
+          wx.removeStorageSync("user_token");
+          wx.removeStorageSync("userInfo");
+          app.globalData.userId = '';
+          app.globalData.userToken = '';
+          app.globalData.memberId = '';
+          app.globalData.userInfo = null;
+          showToast('退出成功');
+          setTimeout(function () {
+            wx.navigateBack();
+          }, 500)
+        } else if (res.cancel) {
+
+        }
+      }
+    })
+  },
+  handel(e) {
+    const {
+      index
+    } = e.detail;
+    this.setData({
+      visible: false
+    })
+    if (index === 0) {
+      logout_new({}).then(data => {
+        wx.removeStorageSync("user_id");
+        wx.removeStorageSync("member_id");
+        wx.removeStorageSync("user_token");
+        wx.removeStorageSync("userInfo");
+        app.globalData.userId = '';
+        app.globalData.userToken = '';
+        app.globalData.memberId = '';
+        app.globalData.userInfo = null;
+        wx.showToast({
+          icon: 'none',
+          mask: true,
+          title: '注销成功',
+          success: res => {
+            setTimeout(function () {
+              wx.switchTab({
+                url: '/pages/index/index',
+              })
+            }, 1500)
+          }
+        })
+      })
+    }
+  },
+
+})

+ 5 - 0
pages/setting/pages/set/index.json

@@ -0,0 +1,5 @@
+{
+  "usingComponents": {
+    "i-modal": "../../ui/modal/index"
+  }
+}

+ 39 - 0
pages/setting/pages/set/index.wxml

@@ -0,0 +1,39 @@
+<view class='cell' hover-class="hover" bindtap='toclear'>
+	<view class='content'>清除缓存</view>
+	<image class='jiantou' src='{{imgServerUrl}}/images/happyjob/rightwjt.png'></image>
+</view>
+<view class='cell' hover-class="hover" bindtap='toabout'>
+	<view class='content'>
+		<text>关于我们</text>
+		<text class="version">v3.3.5</text>
+	</view>
+	<image class='jiantou' src='{{imgServerUrl}}/images/happyjob/rightwjt.png'></image>
+</view>
+<view class='cell' hover-class="hover" bindtap="updateVersion">
+	<view class='content'>版本更新</view>
+	<image class='jiantou' src='{{imgServerUrl}}/images/happyjob/rightwjt.png'></image>
+</view>
+<view class='cell' hover-class="hover" data-url="../suggestions/suggestions" bindtap="toPage">
+	<view class='content'>投诉建议</view>
+	<image class='jiantou' src='{{imgServerUrl}}/images/happyjob/rightwjt.png'></image>
+</view>
+<view class='cell' hover-class="hover" data-url="/pages/web-view/web-view?url={{rootUrl}}/apk-download/uploadfiles/security/userAgreement.html" bindtap="toPage">
+	<view class='content'>用户协议</view>
+	<image class='jiantou' src='{{imgServerUrl}}/images/happyjob/rightwjt.png'></image>
+</view>
+<view class='cell' hover-class="hover" data-url="/pages/web-view/web-view?url={{rootUrl}}/apk-download/uploadfiles/security/privacyPolicy.html" bindtap="toPage">
+	<view class='content'>隐私政策</view>
+	<image class='jiantou' src='{{imgServerUrl}}/images/happyjob/rightwjt.png'></image>
+</view>
+<view class='cell' hover-class="hover" bindtap="cancellation">
+	<view class='content'>注销账户</view>
+	<image class='jiantou' src='{{imgServerUrl}}/images/happyjob/rightwjt.png'></image>
+</view>
+<view class='btn-group fixed-footer'>
+	<button class='selfBtn' bindtap='login_out'>退出登录</button>
+</view>
+
+
+<i-modal visible="{{ visible }}" actions="{{ actions }}" bind:click="handel">
+	<view style="padding:15rpx 30px;color:#000;font-size:34rpx;font-wight:500;">注销后,您在开心工作的所有信息都将会删除。该操作不可逆,请谨慎操作!</view>
+</i-modal>

+ 63 - 0
pages/setting/pages/set/index.wxss

@@ -0,0 +1,63 @@
+.cell {
+  display: flex;
+  flex-direction: row;
+  justify-content: space-between;
+  align-items: center;
+  height: 116rpx;
+  width: 100%;
+  border-bottom: 1rpx solid #EEEEEE;
+}
+
+.content {
+  flex: 1;
+  font-size: 30rpx;
+  font-weight: 400;
+  color: #333333;
+  margin-left: 30rpx;
+  display: flex;
+  align-items: center;
+  justify-content: space-between;
+}
+
+.jiantou {
+  width: 17rpx;
+  height: 29rpx;
+  padding-right: 30rpx;
+}
+
+.version {
+  color: #666666;
+  font-size: 26rpx;
+  margin-right: 30rpx;
+}
+
+
+.fixed-footer {
+  position: fixed;
+  left: 0;
+  bottom: 0;
+  width: 100%;
+}
+
+.btn-group {
+  background: #fff;
+  padding: 20rpx;
+  box-sizing: border-box;
+}
+
+.selfBtn {
+  display: flex;
+  height: 88rpx;
+  line-height: 88rpx;
+  align-items: center;
+  justify-content: center;
+  background: #0177FF;
+  font-size: 34rpx;
+  font-family: PingFangSC-Medium, PingFang SC;
+  font-weight: 500;
+  color: #fff;
+}
+
+.hover {
+  background: #f5f5f5;
+}

+ 103 - 0
pages/setting/pages/suggestions/suggestions.js

@@ -0,0 +1,103 @@
+// pages/suggestions/suggestions.js
+import { saveHpComplaintAdvice } from '../../../../services/index'
+let can = true;
+Page({
+
+	/**
+	 * 页面的初始数据
+	 */
+	data: {
+
+	},
+	submit(e) {
+		const { content } = e.detail.value;
+		if (content) {
+			if (can) {
+				can = false;
+				saveHpComplaintAdvice({
+					content,
+					phone: wx.getStorageSync('hpuser').phone
+				}).then(() => {
+					wx.showToast({
+						icon: 'none',
+						mask: true,
+						title: '提交成功',
+						success: _ => {
+							setTimeout(() => {
+								can = true
+								wx.navigateBack({
+									delta: 1,
+								})
+							}, 1500)
+						}
+					})
+				})
+			} else {
+				wx.showToast({
+					icon: 'none',
+					title: '请勿重复提交~',
+				})
+			}
+		} else {
+			wx.showToast({
+				icon: 'none',
+				title: '请填写反馈信息~',
+			})
+		}
+	},
+	/**
+	 * 生命周期函数--监听页面加载
+	 */
+	onLoad: function (options) {
+
+	},
+
+	/**
+	 * 生命周期函数--监听页面初次渲染完成
+	 */
+	onReady: function () {
+
+	},
+
+	/**
+	 * 生命周期函数--监听页面显示
+	 */
+	onShow: function () {
+
+	},
+
+	/**
+	 * 生命周期函数--监听页面隐藏
+	 */
+	onHide: function () {
+
+	},
+
+	/**
+	 * 生命周期函数--监听页面卸载
+	 */
+	onUnload: function () {
+
+	},
+
+	/**
+	 * 页面相关事件处理函数--监听用户下拉动作
+	 */
+	onPullDownRefresh: function () {
+
+	},
+
+	/**
+	 * 页面上拉触底事件的处理函数
+	 */
+	onReachBottom: function () {
+
+	},
+
+	/**
+	 * 用户点击右上角分享
+	 */
+	onShareAppMessage: function () {
+
+	}
+})

pages/set/index.json → pages/setting/pages/suggestions/suggestions.json


+ 12 - 0
pages/setting/pages/suggestions/suggestions.wxml

@@ -0,0 +1,12 @@
+<!--pages/suggestions/suggestions.wxml-->
+<view class="container">
+	<form bindsubmit="submit">
+		<textarea class="textarea" placeholder='请输入您的反馈信息' name='content' maxlength="1000"></textarea>
+		<view class="button">
+			<view class="button-content">
+				<text>提交</text>
+				<button form-type="submit"></button>
+			</view>
+		</view>
+	</form>
+</view>

+ 51 - 0
pages/setting/pages/suggestions/suggestions.wxss

@@ -0,0 +1,51 @@
+/* pages/suggestions/suggestions.wxss */
+
+page {
+	background: #f5f5f5;
+}
+
+.container {
+	display: flex;
+	justify-content: center;
+}
+
+.textarea {
+	width: 690rpx;
+	height: 420rpx;
+	font-size: 24rpx;
+	background: rgba(255, 255, 255, 1);
+	border-radius: 10px;
+	border: 2px solid rgba(221, 221, 221, 1);
+	box-sizing: border-box;
+	padding: 30rpx;
+	margin-top: 22rpx;
+}
+
+.button {
+	display: flex;
+	align-items: center;
+	justify-content: center;
+	margin-top: 60rpx;
+}
+
+.button-content {
+	width: 690rpx;
+	height: 88rpx;
+	font-size: 34rpx;
+	color: #fff;
+	background: rgba(1, 119, 255, 1);
+	border-radius: 10rpx;
+	display: flex;
+	align-items: center;
+	justify-content: center;
+	position: relative;
+}
+
+.button-content button {
+	height: 100%;
+	width: 100%;
+	position: absolute;
+	left: 0;
+	top: 0;
+	opacity: 0;
+}

+ 2 - 1
pages/user-works/index.js

@@ -159,8 +159,9 @@ Page({
   },
   //入职时间
   startDateChange(e) {
+    const time = e.detail.value.split('-');
     this.setData({
-      startDate: formateYM(e.detail.value)
+      startDate: `${time[0]}年${time[1]}月`
     }, _ => {
       this.check()
     })

+ 8 - 8
project.config.json

@@ -13,7 +13,7 @@
 		]
 	},
 	"setting": {
-		"urlCheck": true,
+		"urlCheck": false,
 		"es6": true,
 		"enhance": true,
 		"postcss": true,
@@ -37,7 +37,7 @@
 	},
 	"compileType": "miniprogram",
 	"libVersion": "2.8.3",
-	"appid": "wx5ae6908ae55edcb7",
+	"appid": "wx1e8ed93850777ffb",
 	"projectname": "kaixin",
 	"debugOptions": {
 		"hidedInDevtools": []
@@ -343,17 +343,17 @@
 					"scene": null
 				},
 				{
-					"id": -1,
-					"name": "pages/ence_push/ence_push",
-					"pathName": "pages/ence_push/ence_push",
+					"id": 39,
+					"name": "pages/setting/pages/set/index",
+					"pathName": "pages/setting/pages/set/index",
 					"query": "",
 					"scene": null
 				},
 				{
 					"id": -1,
-					"name": "pages/detail/index",
-					"pathName": "pages/detail/index",
-					"query": "hpPositionId=361&cate=0",
+					"name": "投诉建议",
+					"pathName": "pages/suggestions/suggestions",
+					"query": "",
 					"scene": null
 				}
 			]

+ 26 - 0
services/index.js

@@ -533,6 +533,32 @@ module.exports = {
       header: {}
     })
   },
+  // 保存日志
+  saveHpUserLog(params) {
+    return http({
+      url: url.saveHpUserLog,
+      data: params,
+      method: 'POST',
+      header: {}
+    })
+  },
+  // 保存日志
+  saveHpComplaintAdvice(params) {
+    return http({
+      url: url.saveHpComplaintAdvice,
+      data: params,
+      method: 'POST',
+      header: {}
+    })
+  },
+  logout_new(params) {
+    return http({
+      url: url.logout_new,
+      data: params,
+      method: 'POST',
+      header: {}
+    })
+  },
   /**************************废弃接口**************************** */
   //post 用户简历:用户教育背景编辑、新增
   resumeEdu(params) {

+ 85 - 23
utils/http.js

@@ -75,6 +75,25 @@ const http = (params) => {
             wx.redirectTo({
               url: '/pages/bind-phone/index',
             })
+          } else if (errorCode == 4000) {
+            wx.showModal({
+              title: '提示',
+              confirmText: '好的',
+              content: res.data.errmsg,
+              showCancel: false,
+              success: () => {
+                // wx.setClipboardData({
+                //   data: '4009960099',
+                //   success: (res) => {
+                //     // wx.showToast({
+                //     //   icon: 'none',
+                //     //   title: '客服电话已复制',
+                //     // })
+                //   },
+                // })
+              }
+            })
+            return
           } else if (errorCode == 1005) {
             //未获取到微信登录信息
             wx.navigateTo({
@@ -90,7 +109,8 @@ const http = (params) => {
           } else if (errorCode == 2008) {
             //账号不存在,或token无效
             if (model && params.data.task_id !== 10) {
-              wx.reLaunch({
+              const _type = pages.length === 1 ? 'reLaunch' : 'navigateTo';
+              wx[_type]({
                 url: '/pages/login/login',
                 success: res => {
                   wx.showModal({
@@ -105,6 +125,39 @@ const http = (params) => {
                   })
                 }
               })
+              // if (pages.length === 1) {
+              //   wx.reLaunch({
+              //     url: '/pages/login/login',
+              //     success: res => {
+              //       wx.showModal({
+              //         title: '提示',
+              //         content: '登录失效请重新登录',
+              //         showCancel: false,
+              //         success: res => {
+              //           if (res.confirm) {
+              //             model = true;
+              //           }
+              //         }
+              //       })
+              //     }
+              //   })
+              // } else {
+              //   wx.navigateTo({
+              //     url: '/pages/login/login',
+              //     success: res => {
+              //       wx.showModal({
+              //         title: '提示',
+              //         content: '登录失效请重新登录',
+              //         showCancel: false,
+              //         success: res => {
+              //           if (res.confirm) {
+              //             model = true;
+              //           }
+              //         }
+              //       })
+              //     }
+              //   })
+              // }
               model = false
             }
             return
@@ -121,28 +174,37 @@ const http = (params) => {
             //后台接口异常
           } else if (errorCode == 2010) {
             //用户未登录
-            if (pages.length === 1) {
-              wx.reLaunch({
-                url: '/pages/login/login',
-                success: data => {
-                  wx.showToast({
-                    icon: 'none',
-                    title: '请先登录',
-                  })
-                }
-              })
-            } else {
-              wx.navigateTo({
-                url: '/pages/login/login',
-                success: data => {
-                  wx.showToast({
-                    icon: 'none',
-                    title: '请先登录',
-                  })
-                }
-              })
-            }
-
+            const _type = pages.length === 1 ? 'reLaunch' : 'navigateTo';
+            wx[_type]({
+              url: '/pages/login/login',
+              success: data => {
+                wx.showToast({
+                  icon: 'none',
+                  title: '请先登录',
+                })
+              }
+            })
+            // if (pages.length === 1) {
+            //   wx.reLaunch({
+            //     url: '/pages/login/login',
+            //     success: data => {
+            //       wx.showToast({
+            //         icon: 'none',
+            //         title: '请先登录',
+            //       })
+            //     }
+            //   })
+            // } else {
+            //   wx.navigateTo({
+            //     url: '/pages/login/login',
+            //     success: data => {
+            //       wx.showToast({
+            //         icon: 'none',
+            //         title: '请先登录',
+            //       })
+            //     }
+            //   })
+            // }
             return
           }
           params.data.task_id !== 10 && showToast(res.data.errmsg);

+ 1 - 1
utils/util.js

@@ -46,7 +46,7 @@ function formateym(dates, split = ".") {
 // 时间转成年月
 function formateYM(date, status = true) {
   const _date = date.replace(/-/g, '/')
-  var time = new Date(_date)
+  var time = new Date(date)
   var year = time.getFullYear()
   var month = time.getMonth() + 1
   var day = time.getDate()