Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
梁建民
/
h5
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
9b25bc2a
authored
Feb 19, 2019
by
梁建民
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
js
parent
21af6d68
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
22 additions
and
4 deletions
src/views/smt/Index.vue
src/views/supplier/Index.vue
view/3.js
view/4.js
src/views/smt/Index.vue
View file @
9b25bc2a
...
...
@@ -280,11 +280,24 @@
...
mapState
({
loading
:
state
=>
state
.
smt
.
loading
}),
linkName
(){
return
this
.
form
.
linkName
;
},
mobileVal
()
{
return
this
.
form
.
mobile
;
}
},
watch
:
{
linkName
(
val
){
var
reg
=
/^
[\u
0391-
\u
FFE5A-Za-z
]
+$/
;
if
(
!
reg
.
test
(
val
)
){
this
.
formError
=
true
;
this
.
formMsg
=
'亲,称呼只能为英文和中文'
;
}
else
{
this
.
formError
=
false
this
.
formMsg
=
''
;
}
},
mobileVal
(
val
)
{
if
(
val
.
length
>=
11
)
{
this
.
verifyCodeFlag
=
true
;
...
...
src/views/supplier/Index.vue
View file @
9b25bc2a
...
...
@@ -271,8 +271,13 @@
}
},
linkName
(
val
)
{
if
(
val
)
{
this
.
formError
=
false
;
var
reg
=
/^
[\u
0391-
\u
FFE5A-Za-z
]
+$/
;
if
(
!
reg
.
test
(
val
)
){
this
.
formError
=
true
;
this
.
formMsg
=
'亲,称呼只能为英文和中文'
;
}
else
{
this
.
formError
=
false
this
.
formMsg
=
''
;
}
},
verifyCode
(
val
)
{
...
...
view/3.js
View file @
9b25bc2a
...
...
@@ -19,7 +19,7 @@ eval("module.exports = __webpack_require__(/*! core-js/library/fn/parse-int */ \
/***/
(
function
(
module
,
__webpack_exports__
,
__webpack_require__
)
{
"use strict"
;
eval
(
"__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var E_h5_node_modules_babel_runtime_corejs2_core_js_parse_int__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./node_modules/@babel/runtime-corejs2/core-js/parse-int */ \"./node_modules/_@babel_runtime-corejs2@7.3.1@@babel/runtime-corejs2/core-js/parse-int.js\");\n/* harmony import */ var E_h5_node_modules_babel_runtime_corejs2_core_js_parse_int__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(E_h5_node_modules_babel_runtime_corejs2_core_js_parse_int__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var E_h5_node_modules_babel_runtime_corejs2_helpers_esm_objectSpread__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./node_modules/@babel/runtime-corejs2/helpers/esm/objectSpread */ \"./node_modules/_@babel_runtime-corejs2@7.3.1@@babel/runtime-corejs2/helpers/esm/objectSpread.js\");\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! vue */ \"./node_modules/_vue@2.5.22@vue/dist/vue.runtime.esm.js\");\n/* harmony import */ var vuex__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! vuex */ \"./node_modules/_vuex@3.1.0@vuex/dist/vuex.esm.js\");\n/* harmony import */ var vant__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! vant */ \"./node_modules/_vant@1.5.7@vant/es/index.js\");\n/* harmony import */ var _views_common_Menu_vue__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @/views/common/Menu.vue */ \"./src/views/common/Menu.vue\");\n\n\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\n\n\n\nvue__WEBPACK_IMPORTED_MODULE_2__[\"default\"].use(vant__WEBPACK_IMPORTED_MODULE_4__[\"Swipe\"]).use(vant__WEBPACK_IMPORTED_MODULE_4__[\"SwipeItem\"]).use(vant__WEBPACK_IMPORTED_MODULE_4__[\"Loading\"]);\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: 'supplier',\n data: function data() {\n return {\n color: '#fff',\n active: 0,\n supplierActive: 0,\n itemtext: ['自营供应商', '联营供应商'],\n isAvisible: 'block',\n isBvisible: 'none',\n numberFlag: false,\n verifyCodeFlag: false,\n codetext: '获取验证码',\n disabled: false,\n codeactive: false,\n firmNum: 0,\n secondNum: 0,\n max: 50,\n formMsg: '',\n formError: false,\n form: {\n com_name: '',\n linkName: '',\n mobile: '',\n verifyCode: '',\n supplier_type: '',\n main_brand: ''\n }\n };\n },\n computed: Object(E_h5_node_modules_babel_runtime_corejs2_helpers_esm_objectSpread__WEBPACK_IMPORTED_MODULE_1__[\"default\"])({}, Object(vuex__WEBPACK_IMPORTED_MODULE_3__[\"mapState\"])({\n loading: function loading(state) {\n return state.smt.loading;\n }\n }), {\n comName: function comName() {\n return this.form.com_name;\n },\n linkName: function linkName() {\n return this.form.linkName;\n },\n mainBrand: function mainBrand() {\n return this.form.main_brand;\n },\n verifyCode: function verifyCode() {\n return this.form.verifyCode;\n },\n mobileVal: function mobileVal() {\n return this.form.mobile;\n }\n }),\n watch: {\n mainBrand: function mainBrand(val) {\n if (val.length > this.max) {\n this.secondNum = this.max;\n } else {\n this.secondNum = val.length;\n }\n },\n linkName: function linkName(val) {\n
if (val) {\n this.formError = false
;\n }\n },\n verifyCode: function verifyCode(val) {\n if (val) {\n this.formError = false;\n }\n },\n comName: function comName(val) {\n if (val) {\n this.formError = false;\n\n if (val.length > this.max) {\n this.firmNum = this.max;\n } else {\n this.firmNum = val.length;\n }\n }\n },\n mobileVal: function mobileVal(val) {\n if (val.length >= 11) {\n this.verifyCodeFlag = true;\n this.formError = false;\n this.$store.dispatch({\n type: 'checkAccountExists',\n account: this.form.mobile\n });\n }\n }\n },\n methods: {\n tab: function tab(index) {\n this.active = index;\n this.isAvisible = 'none';\n this.isBvisible = 'none';\n\n if (index == 0) {\n index == 0 ? this.isAvisible = 'block' : this.isAvisible = 'none';\n } else if (index == 1) {\n index == 1 ? this.isBvisible = 'block' : this.isBvisible = 'none';\n }\n },\n submit: function submit() {\n var character_reg = /^[\\u0391-\\uFFE5A-Za-z]+$/;\n var tel_reg = /^1[34578]\\d{9}$/;\n\n if (!this.form.com_name) {\n this.formError = true;\n this.formMsg = '亲,请输入公司名称';\n return;\n }\n\n if (!this.form.linkName) {\n this.formError = true;\n this.formMsg = '亲,请输入您的称呼';\n return;\n }\n\n if (!character_reg.test(this.form.linkName)) {\n this.formError = true;\n this.formMsg = '亲,称呼只能为英文和中文';\n return;\n }\n\n if (!this.form.mobile) {\n this.formError = true;\n this.formMsg = '亲,请输入手机';\n return;\n }\n\n if (!tel_reg.test(this.form.mobile)) {\n this.formError = true;\n this.formMsg = '亲,手机格式不正确';\n return;\n }\n\n if (!this.form.verifyCode) {\n this.formError = true;\n this.formMsg = '亲,请输入验证码';\n return;\n } //提交\n\n\n this.$store.dispatch({\n type: 'chainFind',\n types: 1,\n mobile: this.form.mobile,\n linkName: this.form.linkName,\n verifyCode: this.form.verifyCode,\n com_name: this.form.com_name,\n main_brand: this.form.main_brand,\n supplier_type: E_h5_node_modules_babel_runtime_corejs2_core_js_parse_int__WEBPACK_IMPORTED_MODULE_0___default()(this.supplierActive) + 1\n });\n },\n getCode: function getCode() {\n this.timeNum();\n this.$store.dispatch({\n type: 'customSmsVerify',\n mobile: this.form.mobile\n });\n },\n timeNum: function timeNum() {\n var me = this;\n var wait = 60;\n me.disabled = true;\n me.codeactive = true;\n me.codetext = wait + '秒后获取';\n var clock = setInterval(doLoop, 1000);\n\n function doLoop() {\n wait--;\n\n if (wait > 0) {\n me.codetext = wait + '秒后获取';\n me.codeactive = true;\n } else {\n clearInterval(clock);\n me.disabled = false;\n me.codeactive = false;\n me.codetext = '重新获取';\n wait = 60;\n }\n }\n },\n goAnchor: function goAnchor(type) {\n if (type === 1) {\n var anchor = this.$el.querySelector('#join-btn');\n document.documentElement.scrollTop = document.body.scrollTop = 0;\n } else if (type === 2) {\n this.supplierActive = 0;\n document.documentElement.scrollTop = document.body.scrollTop = 0;\n } else if (type === 3) {\n this.supplierActive = 1;\n document.documentElement.scrollTop = document.body.scrollTop = 0;\n }\n }\n },\n components: {\n Menu: _views_common_Menu_vue__WEBPACK_IMPORTED_MODULE_5__[\"default\"]\n }\n});\n\n//# sourceURL=webpack:///./src/views/supplier/Index.vue?./node_modules/_cache-loader@1.2.5@cache-loader/dist/cjs.js??ref--12-0!./node_modules/_babel-loader@8.0.5@babel-loader/lib!./node_modules/_cache-loader@1.2.5@cache-loader/dist/cjs.js??ref--0-0!./node_modules/_vue-loader@15.6.2@vue-loader/lib??vue-loader-options"
);
eval
(
"__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var E_h5_node_modules_babel_runtime_corejs2_core_js_parse_int__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./node_modules/@babel/runtime-corejs2/core-js/parse-int */ \"./node_modules/_@babel_runtime-corejs2@7.3.1@@babel/runtime-corejs2/core-js/parse-int.js\");\n/* harmony import */ var E_h5_node_modules_babel_runtime_corejs2_core_js_parse_int__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(E_h5_node_modules_babel_runtime_corejs2_core_js_parse_int__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var E_h5_node_modules_babel_runtime_corejs2_helpers_esm_objectSpread__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./node_modules/@babel/runtime-corejs2/helpers/esm/objectSpread */ \"./node_modules/_@babel_runtime-corejs2@7.3.1@@babel/runtime-corejs2/helpers/esm/objectSpread.js\");\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! vue */ \"./node_modules/_vue@2.5.22@vue/dist/vue.runtime.esm.js\");\n/* harmony import */ var vuex__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! vuex */ \"./node_modules/_vuex@3.1.0@vuex/dist/vuex.esm.js\");\n/* harmony import */ var vant__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! vant */ \"./node_modules/_vant@1.5.7@vant/es/index.js\");\n/* harmony import */ var _views_common_Menu_vue__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! @/views/common/Menu.vue */ \"./src/views/common/Menu.vue\");\n\n\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\n\n\n\nvue__WEBPACK_IMPORTED_MODULE_2__[\"default\"].use(vant__WEBPACK_IMPORTED_MODULE_4__[\"Swipe\"]).use(vant__WEBPACK_IMPORTED_MODULE_4__[\"SwipeItem\"]).use(vant__WEBPACK_IMPORTED_MODULE_4__[\"Loading\"]);\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: 'supplier',\n data: function data() {\n return {\n color: '#fff',\n active: 0,\n supplierActive: 0,\n itemtext: ['自营供应商', '联营供应商'],\n isAvisible: 'block',\n isBvisible: 'none',\n numberFlag: false,\n verifyCodeFlag: false,\n codetext: '获取验证码',\n disabled: false,\n codeactive: false,\n firmNum: 0,\n secondNum: 0,\n max: 50,\n formMsg: '',\n formError: false,\n form: {\n com_name: '',\n linkName: '',\n mobile: '',\n verifyCode: '',\n supplier_type: '',\n main_brand: ''\n }\n };\n },\n computed: Object(E_h5_node_modules_babel_runtime_corejs2_helpers_esm_objectSpread__WEBPACK_IMPORTED_MODULE_1__[\"default\"])({}, Object(vuex__WEBPACK_IMPORTED_MODULE_3__[\"mapState\"])({\n loading: function loading(state) {\n return state.smt.loading;\n }\n }), {\n comName: function comName() {\n return this.form.com_name;\n },\n linkName: function linkName() {\n return this.form.linkName;\n },\n mainBrand: function mainBrand() {\n return this.form.main_brand;\n },\n verifyCode: function verifyCode() {\n return this.form.verifyCode;\n },\n mobileVal: function mobileVal() {\n return this.form.mobile;\n }\n }),\n watch: {\n mainBrand: function mainBrand(val) {\n if (val.length > this.max) {\n this.secondNum = this.max;\n } else {\n this.secondNum = val.length;\n }\n },\n linkName: function linkName(val) {\n
var reg = /^[\\u0391-\\uFFE5A-Za-z]+$/;\n\n if (!reg.test(val)) {\n this.formError = true;\n this.formMsg = '亲,称呼只能为英文和中文';\n } else {\n this.formError = false;\n this.formMsg = ''
;\n }\n },\n verifyCode: function verifyCode(val) {\n if (val) {\n this.formError = false;\n }\n },\n comName: function comName(val) {\n if (val) {\n this.formError = false;\n\n if (val.length > this.max) {\n this.firmNum = this.max;\n } else {\n this.firmNum = val.length;\n }\n }\n },\n mobileVal: function mobileVal(val) {\n if (val.length >= 11) {\n this.verifyCodeFlag = true;\n this.formError = false;\n this.$store.dispatch({\n type: 'checkAccountExists',\n account: this.form.mobile\n });\n }\n }\n },\n methods: {\n tab: function tab(index) {\n this.active = index;\n this.isAvisible = 'none';\n this.isBvisible = 'none';\n\n if (index == 0) {\n index == 0 ? this.isAvisible = 'block' : this.isAvisible = 'none';\n } else if (index == 1) {\n index == 1 ? this.isBvisible = 'block' : this.isBvisible = 'none';\n }\n },\n submit: function submit() {\n var character_reg = /^[\\u0391-\\uFFE5A-Za-z]+$/;\n var tel_reg = /^1[34578]\\d{9}$/;\n\n if (!this.form.com_name) {\n this.formError = true;\n this.formMsg = '亲,请输入公司名称';\n return;\n }\n\n if (!this.form.linkName) {\n this.formError = true;\n this.formMsg = '亲,请输入您的称呼';\n return;\n }\n\n if (!character_reg.test(this.form.linkName)) {\n this.formError = true;\n this.formMsg = '亲,称呼只能为英文和中文';\n return;\n }\n\n if (!this.form.mobile) {\n this.formError = true;\n this.formMsg = '亲,请输入手机';\n return;\n }\n\n if (!tel_reg.test(this.form.mobile)) {\n this.formError = true;\n this.formMsg = '亲,手机格式不正确';\n return;\n }\n\n if (!this.form.verifyCode) {\n this.formError = true;\n this.formMsg = '亲,请输入验证码';\n return;\n } //提交\n\n\n this.$store.dispatch({\n type: 'chainFind',\n types: 1,\n mobile: this.form.mobile,\n linkName: this.form.linkName,\n verifyCode: this.form.verifyCode,\n com_name: this.form.com_name,\n main_brand: this.form.main_brand,\n supplier_type: E_h5_node_modules_babel_runtime_corejs2_core_js_parse_int__WEBPACK_IMPORTED_MODULE_0___default()(this.supplierActive) + 1\n });\n },\n getCode: function getCode() {\n this.timeNum();\n this.$store.dispatch({\n type: 'customSmsVerify',\n mobile: this.form.mobile\n });\n },\n timeNum: function timeNum() {\n var me = this;\n var wait = 60;\n me.disabled = true;\n me.codeactive = true;\n me.codetext = wait + '秒后获取';\n var clock = setInterval(doLoop, 1000);\n\n function doLoop() {\n wait--;\n\n if (wait > 0) {\n me.codetext = wait + '秒后获取';\n me.codeactive = true;\n } else {\n clearInterval(clock);\n me.disabled = false;\n me.codeactive = false;\n me.codetext = '重新获取';\n wait = 60;\n }\n }\n },\n goAnchor: function goAnchor(type) {\n if (type === 1) {\n var anchor = this.$el.querySelector('#join-btn');\n document.documentElement.scrollTop = document.body.scrollTop = 0;\n } else if (type === 2) {\n this.supplierActive = 0;\n document.documentElement.scrollTop = document.body.scrollTop = 0;\n } else if (type === 3) {\n this.supplierActive = 1;\n document.documentElement.scrollTop = document.body.scrollTop = 0;\n }\n }\n },\n components: {\n Menu: _views_common_Menu_vue__WEBPACK_IMPORTED_MODULE_5__[\"default\"]\n }\n});\n\n//# sourceURL=webpack:///./src/views/supplier/Index.vue?./node_modules/_cache-loader@1.2.5@cache-loader/dist/cjs.js??ref--12-0!./node_modules/_babel-loader@8.0.5@babel-loader/lib!./node_modules/_cache-loader@1.2.5@cache-loader/dist/cjs.js??ref--0-0!./node_modules/_vue-loader@15.6.2@vue-loader/lib??vue-loader-options"
);
/***/
}),
...
...
view/4.js
View file @
9b25bc2a
...
...
@@ -8,7 +8,7 @@
/***/
(
function
(
module
,
__webpack_exports__
,
__webpack_require__
)
{
"use strict"
;
eval
(
"__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var E_h5_node_modules_babel_runtime_corejs2_helpers_esm_objectSpread__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./node_modules/@babel/runtime-corejs2/helpers/esm/objectSpread */ \"./node_modules/_@babel_runtime-corejs2@7.3.1@@babel/runtime-corejs2/helpers/esm/objectSpread.js\");\n/* harmony import */ var
vue__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! vue */ \"./node_modules/_vue@2.5.22@vue/dist/vue.runtime.esm.js\");\n/* harmony import */ var vuex__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! vuex */ \"./node_modules/_vuex@3.1.0@vuex/dist/vuex.esm.js\");\n/* harmony import */ var vant__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! vant */ \"./node_modules/_vant@1.5.7@vant/es/index.js\");\n/* harmony import */ var _views_common_Menu_vue__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! @/views/common/Menu.vue */ \"./src/views/common/Menu.vue\");\n\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\n\n\n\nvue__WEBPACK_IMPORTED_MODULE_1__[\"default\"].use(vant__WEBPACK_IMPORTED_MODULE_3__[\"Loading\"]).use(vant__WEBPACK_IMPORTED_MODULE_3__[\"Dialog\"]);\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: 'smt',\n data: function data() {\n return {\n color: \"#fff\",\n active: 0,\n active_1: 0,\n itemtext: ['客户需要提供资料', '物料要求'],\n itemtext_1: ['售后服务', '免责条款'],\n isAvisible: 'block',\n isBvisible: 'none',\n isCvisible: 'block',\n isDvisible: 'none',\n formMsg: '',\n showButton: false,\n formError: false,\n verifyCodeFlag: false,\n codetext: '获取验证码',\n disabled: false,\n codeactive: false,\n layer_1: false,\n layer_2: false,\n layer_3: false,\n closeOnClickOverlay: true,\n firmNum: 0,\n form: {\n mobile: '',\n linkName: '',\n verifyCode: ''\n }\n };\n },\n computed: Object(E_h5_node_modules_babel_runtime_corejs2_helpers_esm_objectSpread__WEBPACK_IMPORTED_MODULE_0__[\"default\"])({}, Object(vuex__WEBPACK_IMPORTED_MODULE_2__[\"mapState\"])({\n loading: function loading(state) {\n return state.smt.loading;\n }\n }), {\n mobileVal: function mobileVal() {\n return this.form.mobile;\n }\n }),\n watch: {\n mobileVal: function mobileVal(val) {\n if (val.length >= 11) {\n this.verifyCodeFlag = true;\n this.formError = false;\n this.$store.dispatch({\n type: 'checkAccountExists',\n account: this.form.mobile\n });\n }\n }\n },\n methods: {\n tab: function tab(index, type) {\n if (type == 'a') {\n this.active = index;\n this.isAvisible = 'none';\n this.isBvisible = 'none';\n\n if (index == 0) {\n index == 0 ? this.isAvisible = 'block' : this.isAvisible = 'none';\n } else if (index == 1) {\n index == 1 ? this.isBvisible = 'block' : this.isBvisible = 'none';\n }\n } else if (type == 'b') {\n this.active_1 = index;\n this.isCvisible = 'none';\n this.isDvisible = 'none';\n\n if (index == 0) {\n index == 0 ? this.isCvisible = 'block' : this.isCvisible = 'none';\n } else if (index == 1) {\n index == 1 ? this.isDvisible = 'block' : this.isDvisible = 'none';\n }\n }\n },\n getCode: function getCode() {\n this.timeNum();\n this.$store.dispatch({\n type: 'customSmsVerify',\n mobile: this.form.mobile\n });\n },\n timeNum: function timeNum() {\n var me = this;\n var wait = 60;\n me.disabled = true;\n me.codeactive = true;\n me.codetext = wait + '秒后获取';\n var clock = setInterval(doLoop, 1000);\n\n function doLoop() {\n wait--;\n\n if (wait > 0) {\n me.codetext = wait + '秒后获取';\n me.codeactive = true;\n } else {\n clearInterval(clock);\n me.disabled = false;\n me.codeactive = false;\n me.codetext = '重新获取';\n wait = 60;\n }\n }\n },\n submit: function submit() {\n var character_reg = /^[\\u0391-\\uFFE5A-Za-z]+$/;\n var tel_reg = /^1[34578]\\d{9}$/;\n\n if (!this.form.linkName) {\n this.formError = true;\n this.formMsg = '亲,请输入您的称呼';\n return;\n }\n\n if (!character_reg.test(this.form.linkName)) {\n this.formError = true;\n this.formMsg = '亲,称呼只能为英文和中文';\n return;\n }\n\n if (!this.form.mobile) {\n this.formError = true;\n this.formMsg = '亲,请输入手机';\n return;\n }\n\n if (!tel_reg.test(this.form.mobile)) {\n this.formError = true;\n this.formMsg = '亲,手机格式不正确';\n return;\n }\n\n if (!this.form.verifyCode) {\n this.formError = true;\n this.formMsg = '亲,请输入验证码';\n return;\n } //提交\n\n\n this.$store.dispatch({\n type: 'chainFind',\n types: 3,\n mobile: this.form.mobile,\n linkName: this.form.linkName,\n verifyCode: this.form.verifyCode\n });\n },\n goAnchor: function goAnchor() {\n document.documentElement.scrollTop = document.body.scrollTop = 0;\n }\n },\n components: {\n Menu: _views_common_Menu_vue__WEBPACK_IMPORTED_MODULE_4
__[\"default\"]\n }\n});\n\n//# sourceURL=webpack:///./src/views/smt/Index.vue?./node_modules/_cache-loader@1.2.5@cache-loader/dist/cjs.js??ref--12-0!./node_modules/_babel-loader@8.0.5@babel-loader/lib!./node_modules/_cache-loader@1.2.5@cache-loader/dist/cjs.js??ref--0-0!./node_modules/_vue-loader@15.6.2@vue-loader/lib??vue-loader-options"
);
eval
(
"__webpack_require__.r(__webpack_exports__);\n/* harmony import */ var E_h5_node_modules_babel_runtime_corejs2_helpers_esm_objectSpread__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./node_modules/@babel/runtime-corejs2/helpers/esm/objectSpread */ \"./node_modules/_@babel_runtime-corejs2@7.3.1@@babel/runtime-corejs2/helpers/esm/objectSpread.js\");\n/* harmony import */ var
core_js_modules_es6_promise__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! core-js/modules/es6.promise */ \"./node_modules/_core-js@2.6.3@core-js/modules/es6.promise.js\");\n/* harmony import */ var core_js_modules_es6_promise__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_promise__WEBPACK_IMPORTED_MODULE_1__);\n/* harmony import */ var core_js_modules_es6_symbol__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! core-js/modules/es6.symbol */ \"./node_modules/_core-js@2.6.3@core-js/modules/es6.symbol.js\");\n/* harmony import */ var core_js_modules_es6_symbol__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(core_js_modules_es6_symbol__WEBPACK_IMPORTED_MODULE_2__);\n/* harmony import */ var vue__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! vue */ \"./node_modules/_vue@2.5.22@vue/dist/vue.runtime.esm.js\");\n/* harmony import */ var vuex__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! vuex */ \"./node_modules/_vuex@3.1.0@vuex/dist/vuex.esm.js\");\n/* harmony import */ var vant__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! vant */ \"./node_modules/_vant@1.5.7@vant/es/index.js\");\n/* harmony import */ var _views_common_Menu_vue__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! @/views/common/Menu.vue */ \"./src/views/common/Menu.vue\");\n\n\n\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n//\n\n\n\n\nvue__WEBPACK_IMPORTED_MODULE_3__[\"default\"].use(vant__WEBPACK_IMPORTED_MODULE_5__[\"Loading\"]).use(vant__WEBPACK_IMPORTED_MODULE_5__[\"Dialog\"]);\n/* harmony default export */ __webpack_exports__[\"default\"] = ({\n name: 'smt',\n data: function data() {\n return {\n color: \"#fff\",\n active: 0,\n active_1: 0,\n itemtext: ['客户需要提供资料', '物料要求'],\n itemtext_1: ['售后服务', '免责条款'],\n isAvisible: 'block',\n isBvisible: 'none',\n isCvisible: 'block',\n isDvisible: 'none',\n formMsg: '',\n showButton: false,\n formError: false,\n verifyCodeFlag: false,\n codetext: '获取验证码',\n disabled: false,\n codeactive: false,\n layer_1: false,\n layer_2: false,\n layer_3: false,\n closeOnClickOverlay: true,\n firmNum: 0,\n form: {\n mobile: '',\n linkName: '',\n verifyCode: ''\n }\n };\n },\n computed: Object(E_h5_node_modules_babel_runtime_corejs2_helpers_esm_objectSpread__WEBPACK_IMPORTED_MODULE_0__[\"default\"])({}, Object(vuex__WEBPACK_IMPORTED_MODULE_4__[\"mapState\"])({\n loading: function loading(state) {\n return state.smt.loading;\n }\n }), {\n linkName: function linkName() {\n return this.form.linkName;\n },\n mobileVal: function mobileVal() {\n return this.form.mobile;\n }\n }),\n watch: {\n linkName: function linkName(val) {\n var reg = /^[\\u0391-\\uFFE5A-Za-z]+$/;\n\n if (!reg.test(val)) {\n this.formError = true;\n this.formMsg = '亲,称呼只能为英文和中文';\n } else {\n this.formError = false;\n this.formMsg = '';\n }\n },\n mobileVal: function mobileVal(val) {\n if (val.length >= 11) {\n this.verifyCodeFlag = true;\n this.formError = false;\n this.$store.dispatch({\n type: 'checkAccountExists',\n account: this.form.mobile\n });\n }\n }\n },\n methods: {\n tab: function tab(index, type) {\n if (type == 'a') {\n this.active = index;\n this.isAvisible = 'none';\n this.isBvisible = 'none';\n\n if (index == 0) {\n index == 0 ? this.isAvisible = 'block' : this.isAvisible = 'none';\n } else if (index == 1) {\n index == 1 ? this.isBvisible = 'block' : this.isBvisible = 'none';\n }\n } else if (type == 'b') {\n this.active_1 = index;\n this.isCvisible = 'none';\n this.isDvisible = 'none';\n\n if (index == 0) {\n index == 0 ? this.isCvisible = 'block' : this.isCvisible = 'none';\n } else if (index == 1) {\n index == 1 ? this.isDvisible = 'block' : this.isDvisible = 'none';\n }\n }\n },\n getCode: function getCode() {\n this.timeNum();\n this.$store.dispatch({\n type: 'customSmsVerify',\n mobile: this.form.mobile\n });\n },\n timeNum: function timeNum() {\n var me = this;\n var wait = 60;\n me.disabled = true;\n me.codeactive = true;\n me.codetext = wait + '秒后获取';\n var clock = setInterval(doLoop, 1000);\n\n function doLoop() {\n wait--;\n\n if (wait > 0) {\n me.codetext = wait + '秒后获取';\n me.codeactive = true;\n } else {\n clearInterval(clock);\n me.disabled = false;\n me.codeactive = false;\n me.codetext = '重新获取';\n wait = 60;\n }\n }\n },\n submit: function submit() {\n var character_reg = /^[\\u0391-\\uFFE5A-Za-z]+$/;\n var tel_reg = /^1[34578]\\d{9}$/;\n\n if (!this.form.linkName) {\n this.formError = true;\n this.formMsg = '亲,请输入您的称呼';\n return;\n }\n\n if (!character_reg.test(this.form.linkName)) {\n this.formError = true;\n this.formMsg = '亲,称呼只能为英文和中文';\n return;\n }\n\n if (!this.form.mobile) {\n this.formError = true;\n this.formMsg = '亲,请输入手机';\n return;\n }\n\n if (!tel_reg.test(this.form.mobile)) {\n this.formError = true;\n this.formMsg = '亲,手机格式不正确';\n return;\n }\n\n if (!this.form.verifyCode) {\n this.formError = true;\n this.formMsg = '亲,请输入验证码';\n return;\n } //提交\n\n\n this.$store.dispatch({\n type: 'chainFind',\n types: 3,\n mobile: this.form.mobile,\n linkName: this.form.linkName,\n verifyCode: this.form.verifyCode\n });\n },\n goAnchor: function goAnchor() {\n document.documentElement.scrollTop = document.body.scrollTop = 0;\n }\n },\n components: {\n Menu: _views_common_Menu_vue__WEBPACK_IMPORTED_MODULE_6
__[\"default\"]\n }\n});\n\n//# sourceURL=webpack:///./src/views/smt/Index.vue?./node_modules/_cache-loader@1.2.5@cache-loader/dist/cjs.js??ref--12-0!./node_modules/_babel-loader@8.0.5@babel-loader/lib!./node_modules/_cache-loader@1.2.5@cache-loader/dist/cjs.js??ref--0-0!./node_modules/_vue-loader@15.6.2@vue-loader/lib??vue-loader-options"
);
/***/
}),
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment