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

Merge branch 'test'

tremble 5 éve
szülő
commit
bfb7daa054

+ 2 - 2
mobile/src/components/toast/binding.vue

@@ -44,14 +44,14 @@ let binginfo = [
   '2、绑定设备后,可进行充值、查看消费记录和解绑等操作。',
   '3、同一台设备只能被一个账号绑定,已经被绑定的设备需要原“用户账号”解绑才可以被再次绑定。',
   '4、设备始终可通过“相机账号”登录,但需要使用APP扫码功能进行。',
-  '5 、“相机账号”登录可进行上传、编辑和删除场景等操作,但无法进行充值扩容等操作。'
+  '5 、“相机账号”登录可进行编辑和删除场景等操作,但无法进行充值扩容等操作。'
 ]
 let binginfoEn = [
   '1、You may bind the camera account of the device to your user account.',
   '2、 After binding a device, you may top-up, view the billing records, unbind the device, etc.',
   '3、A device can only be bond to one account. ',
   '4、You can always log into the camera account of the device by scan the QR code on the website via the APP.',
-  '5、Login via camera account can upload, edit, and delete the scenes, but not top-up or expand the storage.'
+  '5、Login via camera account can edit, and delete the scenes, but not top-up or expand the storage.'
 ]
 export default {
   props: ['visible', 'btype'],

+ 22 - 6
mobile/src/pages/account/manage/myscene/index.vue

@@ -219,12 +219,28 @@ export default {
     },
     gotoEdit (item) {
       let url = item.webSite
-      let temp = ''
-      temp = url.replace('show', 'edit')
-      // let temp1 = temp.replace('//pro', '//test')
-      let temp1 = temp.replace('showProPC.html', 'showProMobile.html')
-      // console.log(temp1)
-      window.open(temp1.replace('http://', 'https://') + (this.language === 'en' ? '&lang=en' : ''), '_blank')
+      let page = url.substring(url.lastIndexOf('/') + 1, url.lastIndexOf('.html'))
+      let pStr = ''
+      if (item.buildType) {
+        switch (item.buildType.toLowerCase()) {
+          case 'v1':
+            pStr = 'edit'
+            break
+          case 'v2':
+            pStr = 'editProMobile'
+
+            break
+          case 'v3':
+            pStr = 'emobile'
+            break
+          default:
+            break
+        }
+      }
+
+      url = pStr ? url.replace(page, pStr) : url
+
+      window.open(url.replace('http://', 'https://') + (this.language === 'en' ? '&lang=en' : ''), '_blank')
     },
     async del (item) {
       this.$toast.showConfirm(

+ 4 - 2
mobile/src/pages/account/manage/payselect/index.vue

@@ -81,8 +81,10 @@ export default {
 
       if (PAYS[item.id] !== 'paypal') {
         if (this.isWeixin) {
-          let href = spaceId ? `https://open.weixin.qq.com/connect/oauth2/authorize?redirect_uri=http%3a%2f%2fwww.4dkankan.com%2fapi%2forder%2fpay%2fwechatPreJsPay%3forderId=${orderId}%26spaceId=${spaceId || null}%26orderType=${Number(orderType)}&appid=wx779dbafb46bab697&response_type=code&scope=snsapi_base&state=1&connect_redirect=1#wechat_redirect`
-            : `https://open.weixin.qq.com/connect/oauth2/authorize?redirect_uri=http%3a%2f%2fwww.4dkankan.com%2fapi%2forder%2fpay%2fwechatPreJsPay%3forderId=${orderId}%26orderType=${Number(orderType)}&appid=wx779dbafb46bab697&response_type=code&scope=snsapi_base&state=1&connect_redirect=1#wechat_redirect`
+          let hostName = window.location.hostname
+
+          let href = spaceId ? `https://open.weixin.qq.com/connect/oauth2/authorize?redirect_uri=https%3a%2f%2f${hostName}%2fapi%2forder%2fpay%2fwechatPreJsPay%3forderId=${orderId}%26spaceId=${spaceId || null}%26orderType=${Number(orderType)}&appid=wx779dbafb46bab697&response_type=code&scope=snsapi_base&state=1&connect_redirect=1#wechat_redirect`
+            : `https://open.weixin.qq.com/connect/oauth2/authorize?redirect_uri=https%3a%2f%2f${hostName}%2fapi%2forder%2fpay%2fwechatPreJsPay%3forderId=${orderId}%26orderType=${Number(orderType)}&appid=wx779dbafb46bab697&response_type=code&scope=snsapi_base&state=1&connect_redirect=1#wechat_redirect`
           return location.replace(href)
         }
         let response = await this.$http

+ 2 - 1
mobile/src/pages/account/manage/submit/index.vue

@@ -217,7 +217,8 @@ export default {
 
       if (Number(payType) !== 2) {
         if (this.isWeixin) {
-          return location.replace(`https://open.weixin.qq.com/connect/oauth2/authorize?redirect_uri=http%3a%2f%2fwww.4dkankan.com%2fapi%2forder%2fpay%2fwechatPreJsPay%3forderId=${this.orderId}%26orderType=${Number(this.orderType)}&appid=wx779dbafb46bab697&response_type=code&scope=snsapi_base&state=1&connect_redirect=1#wechat_redirect`)
+          let hostName = window.location.hostname
+          return location.replace(`https://open.weixin.qq.com/connect/oauth2/authorize?redirect_uri=https%3a%2f%2f${hostName}%2fapi%2forder%2fpay%2fwechatPreJsPay%3forderId=${this.orderId}%26orderType=${Number(this.orderType)}&appid=wx779dbafb46bab697&response_type=code&scope=snsapi_base&state=1&connect_redirect=1#wechat_redirect`)
         }
         let response = await this.$http
           .post(`order/pay/${paytypes[payType]}`, data, {

+ 1 - 1
mobile/src/store/language/cn/manage.js

@@ -127,7 +127,7 @@ export default{
     id: '设备ID:',
     noScenes: '暂无任何场景,赶紧去拍摄吧。',
     placeholder: {
-      searchID: '搜索场景或设备S/N'
+      searchID: '搜索场景'
     },
     delwarn: '确定要删除当前场景吗?',
     share: {

+ 1 - 1
mobile/src/store/language/cn/toast.js

@@ -74,7 +74,7 @@ export default{
   '3008': '该手机已被注册',
   '3009': '两次输入的密码不一致',
   '3010': '昵称长度错误',
-  '3011': '密码必须包含英文字母和数字,长度在8-16位之间',
+  '3011': '密码必须包含英文大小写、数字,长度8-16个字符',
   '3012': '昵称包含敏感词',
   '3013': '手机号码格式错误',
   '3014': '账号或密码不正确',

+ 1 - 1
mobile/src/store/language/en/manage.js

@@ -125,7 +125,7 @@ export default{
     edit: 'Edit',
     delete: 'Delete',
     placeholder: {
-      searchID: 'Search scene or camera S/N'
+      searchID: 'Search scene'
     },
     id: 'camera id: ',
     shooting: 'Shooting date: ',

+ 1 - 1
mobile/src/store/language/en/toast.js

@@ -73,7 +73,7 @@ export default{
   '3008': 'The mobile number is already registered.',
   '3009': 'The password you typed don\'t match.',
   '3010': 'Incorrect user name length.',
-  '3011': 'Passoword must contain letters and numbers, 8-16 characters.',
+  '3011': 'Password must contain English case and numbers, 8-16 characters. ',
   '3012': 'User name contains sensitive words.',
   '3013': 'Incorrect format of mobile number.',
   '3014': 'Incorrect user name or password.',

+ 2 - 2
pc/src/components/toast/binding.vue

@@ -42,7 +42,7 @@ let binginfo = [
   '2、绑定设备后,可进行充值、查看消费记录和解绑等操作。',
   '3、同一台设备只能被一个账号绑定,已经被绑定的设备需要原“用户账号”解绑才可以被再次绑定。',
   '4、设备始终可通过“相机账号”登录,但需要使用APP扫码功能进行。',
-  '5 、“相机账号”登录可进行上传、编辑和删除场景等操作,但无法进行充值扩容等操作。'
+  '5 、“相机账号”登录可进行编辑和删除场景等操作,但无法进行充值扩容等操作。'
 
 ]
 let binginfoEn = [
@@ -50,7 +50,7 @@ let binginfoEn = [
   '2、 After binding a device, you may top-up, view the billing records, unbind the device, etc.',
   '3、A device can only be bond to one account. ',
   '4、You can always log into the camera account of the device by scan the QR code on the website via the APP.',
-  '5、Login via camera account can upload, edit, and delete the scenes, but not top-up or expand the storage.'
+  '5、Login via camera account can edit, and delete the scenes, but not top-up or expand the storage.'
 ]
 export default {
   props: ['visible', 'btype'],

+ 2 - 0
pc/src/page/layout/aside/temp/ltemp/login.vue

@@ -78,6 +78,8 @@ export default {
     let username = localStorage.getItem('username')
     let password = localStorage.getItem('password')
 
+    console.log(remember)
+
     return {
       phone: username,
       password: password,

+ 22 - 3
pc/src/page/manage/temp/scene.vue

@@ -257,9 +257,28 @@ export default {
     },
     gotoEdit (item) {
       let url = item.webSite
-      let temp = ''
-      temp = url.replace('show', 'edit')
-      window.open(temp.replace('http://', 'https://') + (this.language === 'en' ? '&lang=en' : ''), '_blank')
+      let page = url.substring(url.lastIndexOf('/') + 1, url.lastIndexOf('.html'))
+      let pStr = ''
+      if (item.buildType) {
+        switch (item.buildType.toLowerCase()) {
+          case 'v1':
+            pStr = 'edit'
+            break
+          case 'v2':
+            pStr = 'editProPC'
+
+            break
+          case 'v3':
+            pStr = 'epc'
+            break
+          default:
+            break
+        }
+      }
+
+      url = pStr ? url.replace(page, pStr) : url
+
+      window.open(url.replace('http://', 'https://') + (this.language === 'en' ? '&lang=en' : ''), '_blank')
     },
     async del (item) {
       this.$toast.showConfirm('warn', this.langScenes.delwarn, async () => {

+ 1 - 1
pc/src/store/language/cn/manage.js

@@ -111,7 +111,7 @@ export default{
     id: 'S/N:',
     noScenes: '暂无任何场景,赶紧去拍摄吧。',
     placeholder: {
-      searchID: '搜索场景或设备S/N'
+      searchID: '搜索场景'
     },
     delwarn: '确定要删除当前场景吗?',
     share: {

+ 1 - 1
pc/src/store/language/cn/toast.js

@@ -66,7 +66,7 @@ export default{
   '3008': '该手机已被注册',
   '3009': '两次输入的密码不一致',
   '3010': '昵称长度在2-11位之间',
-  '3011': '密码必须包含英文字母和数字,长度在8-16位之间',
+  '3011': '密码必须包含英文大小写、数字,长度8-16个字符',
   '3012': '昵称包含敏感词',
   '3013': '手机号码格式错误',
   '3014': '账号或密码不正确',

+ 1 - 1
pc/src/store/language/en/manage.js

@@ -109,7 +109,7 @@ export default{
     edit: 'Edit',
     delete: 'Delete',
     placeholder: {
-      searchID: 'Search scene or device S/N'
+      searchID: 'Search scene'
     },
     id: 'S/N: ',
     shooting: 'Shooting date: ',

+ 1 - 1
pc/src/store/language/en/toast.js

@@ -66,7 +66,7 @@ export default{
   '3008': 'The mobile number is already registered.',
   '3009': 'The password you typed don\'t match.',
   '3010': 'Incorrect user name length. (2-11 characters)',
-  '3011': 'Passoword must contain letters and numbers, 8-16 characters.',
+  '3011': 'Password must contain English case and numbers, 8-16 characters. ',
   '3012': 'User name contains sensitive words.',
   '3013': 'Incorrect format of mobile number.',
   '3014': 'Incorrect user name or password.',

+ 36 - 1
pc/src/util/index.js

@@ -48,7 +48,42 @@ module.exports = {
   },
   isWorkPhone: function (phone) {
     let phones = [
-      /^1(?:3\d|4[4-9]|5[0-35-9]|6[67]|7[013-8]|8\d|9\d)\d{8}$/
+      /^1(?:3\d|4[4-9]|5[0-35-9]|6[67]|7[013-8]|8\d|9\d)\d{8}$/,
+      /^(\+?213|0)(5|6|7)\d{8}$/,
+      /^(!?(\+?963)|0)?9\d{8}$/,
+      /^(!?(\+?966)|0)?5\d{8}$/,
+      /^(\+?1)?[2-9]\d{2}[2-9](?!11)\d{6}$/,
+      /^(\+?420)? ?[1-9][0-9]{2} ?[0-9]{3} ?[0-9]{3}$/,
+      /^(\+?49[ .-])?([(]{1}[0-9]{1,6}[)])?([0-9 .-/]{3,20})((x|ext|extension)[ ]?[0-9]{1,4})?$/,
+      /^(\+?45)?(\d{8})$/,
+      /^(\+?30)?(69\d{8})$/,
+      /^(\+?61|0)4\d{8}$/,
+      /^(\+?44|0)7\d{9}$/,
+      /^(\+?852-?)?[569]\d{3}-?\d{4}$/,
+      /^(\+?91|0)?[789]\d{9}$/,
+      /^(\+?64|0)2\d{7,9}$/,
+      /^(\+?27|0)\d{9}$/,
+      /^(\+?26)?09[567]\d{7}$/,
+      /^(\+?34)?(6\d{1}|7[1234])\d{7}$/,
+      /^(\+?358|0)\s?(4(0|1|2|4|5)?|50)\s?(\d\s?){4,8}\d$/,
+      /^(\+?33|0)[67]\d{8}$/,
+      /^(\+972|0)([23489]|5[0248]|77)[1-9]\d{6}/,
+      /^(\+?36)(20|30|70)\d{7}$/,
+      /^(\+?39)?\s?3\d{2} ?\d{6,7}$/,
+      /^(\+?81|0)\d{1,4}[ -]?\d{1,4}[ -]?\d{4}$/,
+      /^(\+?6?01){1}(([145]{1}(-|\s)?\d{7,8})|([236789]{1}(\s|-)?\d{7}))$/,
+      /^(\+?47)?[49]\d{7}$/,
+      /^(\+?32|0)4?\d{8}$/,
+      /^(\+?47)?[49]\d{7}$/,
+      /^(\+?48)? ?[5-8]\d ?\d{3} ?\d{2} ?\d{2}$/,
+      /^(\+?55|0)-?[1-9]{2}-?[2-9]{1}\d{3,4}-?\d{4}$/,
+      /^(\+?351)?9[1236]\d{7}$/,
+      /^(\+?7|8)?9\d{9}$/,
+      /^(\+3816|06)[- \d]{5,9}$/,
+      /^(\+?90|0)?5\d{9}$/,
+      /^(\+?84|0)?((1(2([0-9])|6([2-9])|88|99))|(9((?!5)[0-9])))([0-9]{7})$/,
+      /^(\+?0?86-?)?1[345789]\d{9}$/,
+      /^(\+?886-?|0)?9\d{8}$/
     ]
     for (let i = 0; i < phones.length; i++) {
       if (phones[i].test(phone)) {