|
@@ -52,19 +52,19 @@
|
|
|
|
|
|
<script>
|
|
|
import { MobileAreaCode } from "@/utils/mobileCode";
|
|
|
-import { uploadurl, User } from "@/config/api.js";
|
|
|
+import { uploadurl, User, Mine } from "@/config/api.js";
|
|
|
export default {
|
|
|
data() {
|
|
|
return {
|
|
|
- radioValue: "1",
|
|
|
+ radioValue: 1,
|
|
|
radioList: [
|
|
|
{
|
|
|
label: "填写手机号/机构名",
|
|
|
- value: "1",
|
|
|
+ value: 1,
|
|
|
},
|
|
|
{
|
|
|
label: "上传名片",
|
|
|
- value: "2",
|
|
|
+ value: 2,
|
|
|
},
|
|
|
],
|
|
|
seconds: 60,
|
|
@@ -83,6 +83,9 @@ export default {
|
|
|
return MobileAreaCode;
|
|
|
},
|
|
|
},
|
|
|
+ props: {
|
|
|
+ codeId: {},
|
|
|
+ },
|
|
|
methods: {
|
|
|
radioChange(e) {
|
|
|
console.log(e);
|
|
@@ -126,9 +129,10 @@ export default {
|
|
|
});
|
|
|
},
|
|
|
// 确认签到
|
|
|
- submitButton() {
|
|
|
- if (this.radioValue == "1") {
|
|
|
+ async submitButton() {
|
|
|
+ if (this.radioValue == 1) {
|
|
|
if (this.phoneNumber && this.phoneCode && this.userName && this.corporateName) {
|
|
|
+ this.submitPost();
|
|
|
} else {
|
|
|
let msg = !this.phoneNumber
|
|
|
? "请输入手机号"
|
|
@@ -146,6 +150,22 @@ export default {
|
|
|
this.$util.toast("请上传名片");
|
|
|
return;
|
|
|
}
|
|
|
+ this.submitPost();
|
|
|
+ }
|
|
|
+ },
|
|
|
+ async submitPost() {
|
|
|
+ const res = await Mine.activity_signin_byHand({
|
|
|
+ ActivityId: this.codeId || 2161, //活动ID
|
|
|
+ CountryCode: this.countryCode, //区号
|
|
|
+ Mobile: this.phoneNumber, //手机号
|
|
|
+ VCode: this.phoneCode, //验证码
|
|
|
+ CompanyName: this.corporateName, //公司名称
|
|
|
+ BusinessCard: this.fileUrl, //名片地址
|
|
|
+ RealName: this.userName, //姓名
|
|
|
+ SigninType: Number(this.radioValue), //签到方式,1:填写手机号/机构名称;2:上传名片
|
|
|
+ });
|
|
|
+ if (res.Ret === 200) {
|
|
|
+ this.$emit("getDetail");
|
|
|
}
|
|
|
},
|
|
|
},
|
|
@@ -204,7 +224,7 @@ export default {
|
|
|
display: flex;
|
|
|
align-items: center;
|
|
|
justify-content: center;
|
|
|
- width: 168rpx;
|
|
|
+ width: 185rpx;
|
|
|
height: 60rpx;
|
|
|
border: 2rpx solid #caaf8b;
|
|
|
border-radius: 4rpx;
|