457457 type =" primary"
458458 @click =" sendCode(form.mobile)"
459459 :disabled =" state"
460- >发送验证码<span v-if =" state" >({{ stateNum }})</span >
460+ >发送验证码<span v-if =" state" >({{ stateNum }})</span >
461461 </el-button >
462462 </div >
463463 </el-form-item >
487487 type =" primary"
488488 @click =" sendCode(form.mobile, form.deviceId)"
489489 :disabled =" state"
490- >发送验证码<span v-if =" state" >({{ stateNum }})</span >
490+ >发送验证码<span v-if =" state" >({{ stateNum }})</span >
491491 </el-button >
492492 </div >
493493 </el-form-item >
494494
495495 <el-form-item label =" 验证码" prop =" code" >
496- <el-input v-model =" form.code" placeholder =" 请输入验证码" />
496+ <el-input v-model =" form.code" placeholder =" 请输入验证码" />
497497 </el-form-item >
498498 </el-form >
499499 <div slot =" footer" class =" dialog-footer" >
500500 <el-button
501501 type =" primary"
502502 @click =" refresh(form.mobile, form.code, form.deviceId, 1)"
503- >刷 新
504- </el-button
505- >
503+ >刷 新
504+ </el-button >
506505 <el-button @click =" cancel" >取 消</el-button >
507506 </div >
508507 </el-dialog >
@@ -603,7 +602,6 @@ export default {
603602 listItem ().then ((response ) => {
604603 this .itemList = response .data ;
605604 });
606- console .log (this .guid ());
607605 },
608606 methods: {
609607 // item下拉框选择
@@ -756,7 +754,11 @@ export default {
756754 },
757755 // 发生验证码
758756 sendCode (mobile , deviceId ) {
759- this .form .deviceId = deviceId == " " ? this .guid () : deviceId;
757+ if (deviceId == undefined || deviceId == " " ) {
758+ this .form .deviceId = this .guid ();
759+ } else {
760+ this .form .deviceId = deviceId;
761+ }
760762 sendCode (mobile, this .form .deviceId ).then ((response ) => {
761763 this .$modal .msgSuccess (" 发送成功" );
762764 this .state = true ;
@@ -771,7 +773,7 @@ export default {
771773 },
772774 // 登录
773775 login (mobile , code ) {
774- this .refresh (mobile, code, this .form .deviceId , 0 )
776+ this .refresh (mobile, code, this .form .deviceId , 0 );
775777 },
776778 /** 删除按钮操作 */
777779 handleDelete (row ) {
0 commit comments