上传协议
This commit is contained in:
@@ -258,8 +258,9 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label for="id_code">个人身份证号<span class="glyphicon glyphicon-asterisk" style="color:red;"></span>:</label>
|
<label for="xieyi">上传手持身份证<span class="glyphicon glyphicon-asterisk" style="color:red;"></span>:</label>
|
||||||
<input type="text" v-model="id_code" class="form-control" id="id_code" placeholder="请输入身份证号">
|
<input type="file" id="xieyi" name="xieyi" accept="image/*">
|
||||||
|
<p class="help-block">手持身份证的半身照片 </p>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label for="name">网络安全协议书<span class="glyphicon glyphicon-asterisk" style="color:red;"></span>:</label>
|
<label for="name">网络安全协议书<span class="glyphicon glyphicon-asterisk" style="color:red;"></span>:</label>
|
||||||
@@ -497,11 +498,10 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
var vm = new Vue({
|
var vm = new Vue({
|
||||||
el:'#upload',
|
el:'#upload',
|
||||||
data:{
|
data:{
|
||||||
describe:'',
|
describe:'',
|
||||||
id_code:'',
|
|
||||||
status:false,
|
status:false,
|
||||||
},
|
},
|
||||||
created:function(){
|
created:function(){
|
||||||
@@ -509,6 +509,7 @@
|
|||||||
},
|
},
|
||||||
methods:{
|
methods:{
|
||||||
upload_file() {
|
upload_file() {
|
||||||
|
var xieyi = document.getElementById("xieyi").files[0];
|
||||||
if(!this.status) {
|
if(!this.status) {
|
||||||
alert("请勾选同意协议!");
|
alert("请勾选同意协议!");
|
||||||
return;
|
return;
|
||||||
@@ -517,18 +518,16 @@
|
|||||||
alert("业务描述必须填写!");
|
alert("业务描述必须填写!");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
var reg = /(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/;
|
if (!xieyi) {
|
||||||
if(reg.test(this.id_code) === false)
|
alert("手持身份证必须上传!");
|
||||||
{
|
}
|
||||||
alert("身份证输入不合法");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
var form_data = new FormData();
|
var form_data = new FormData();
|
||||||
form_data.append('cookie',document.cookie);
|
form_data.append('cookie',document.cookie);
|
||||||
form_data.append('describe',this.describe);
|
form_data.append('describe',this.describe);
|
||||||
form_data.append('id_code',this.id_code);
|
form_data.append('id_code',this.id_code);
|
||||||
form_data.append('status',this.status);
|
form_data.append('status',this.status);
|
||||||
|
form_data.append('xieyi',xieyi);
|
||||||
|
|
||||||
$.ajax({
|
$.ajax({
|
||||||
type: 'POST',
|
type: 'POST',
|
||||||
|
|||||||
@@ -17,9 +17,11 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label for="id_code">个人身份证号<span class="glyphicon glyphicon-asterisk" style="color:red;"></span>:</label>
|
<label for="xieyi">上传手持身份证<span class="glyphicon glyphicon-asterisk" style="color:red;"></span>:</label>
|
||||||
<input type="text" v-model="id_code" class="form-control" id="id_code" placeholder="请输入身份证号">
|
<input type="file" id="xieyi" name="xieyi" accept="image/*">
|
||||||
|
<p class="help-block">手持身份证的半身照片 </p>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label for="name">网络安全协议书<span class="glyphicon glyphicon-asterisk" style="color:red;"></span>:</label>
|
<label for="name">网络安全协议书<span class="glyphicon glyphicon-asterisk" style="color:red;"></span>:</label>
|
||||||
<div style="background-color: white;padding: 5rem;">
|
<div style="background-color: white;padding: 5rem;">
|
||||||
@@ -68,7 +70,6 @@
|
|||||||
el:'#upload',
|
el:'#upload',
|
||||||
data:{
|
data:{
|
||||||
describe:'',
|
describe:'',
|
||||||
id_code:'',
|
|
||||||
status:false,
|
status:false,
|
||||||
},
|
},
|
||||||
created:function(){
|
created:function(){
|
||||||
@@ -76,6 +77,7 @@
|
|||||||
},
|
},
|
||||||
methods:{
|
methods:{
|
||||||
upload_file() {
|
upload_file() {
|
||||||
|
var xieyi = document.getElementById("xieyi").files[0];
|
||||||
if(!this.status) {
|
if(!this.status) {
|
||||||
alert("请勾选同意协议!");
|
alert("请勾选同意协议!");
|
||||||
return;
|
return;
|
||||||
@@ -84,18 +86,16 @@
|
|||||||
alert("业务描述必须填写!");
|
alert("业务描述必须填写!");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
var reg = /(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/;
|
if (!xieyi) {
|
||||||
if(reg.test(this.id_code) === false)
|
alert("手持身份证必须上传!");
|
||||||
{
|
}
|
||||||
alert("身份证输入不合法");
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
var form_data = new FormData();
|
var form_data = new FormData();
|
||||||
form_data.append('cookie',document.cookie);
|
form_data.append('cookie',document.cookie);
|
||||||
form_data.append('describe',this.describe);
|
form_data.append('describe',this.describe);
|
||||||
form_data.append('id_code',this.id_code);
|
form_data.append('id_code',this.id_code);
|
||||||
form_data.append('status',this.status);
|
form_data.append('status',this.status);
|
||||||
|
form_data.append('xieyi',xieyi);
|
||||||
|
|
||||||
$.ajax({
|
$.ajax({
|
||||||
type: 'POST',
|
type: 'POST',
|
||||||
|
|||||||
Reference in New Issue
Block a user