2b4e213d by 任超

style:填报信息页面

1 parent 7956505d
......@@ -5,37 +5,19 @@ layui.use('element', function () {
$(function () {
addTabs('#wssq');
setFristStepPageFLow(GetQueryString('ywid'), GetQueryString('businessno'));
// 业务
layui.use(['form'], function () {
var form = layui.form
//自定义验证规则
form.verify({
title: function (value) {
if (value.length == 0) {
return '权利人不能为空';
} else if (value.length < 2) {
return '权利人至少得2个字符啊';
}
}
});
//监听提交
form.on('submit(check)', function (data) {
bdcqlVerify(data.field);
// layer.alert(JSON.stringify(data.field), {
// title: '最终的提交信息'
// })
return false;
});
})
// 结果弹框
$('.reset').click(function () {
// seizureResult()
})
SetCheckContent();
fetchDataReview();
})
// 初始化渲染数据
function fetchDataReview(){
console.log(getCookie('myCookie'))
let userInfo = getCookie('myCookie');
$('#sqrxm').text(userInfo.username);
if(userInfo.zjzl=='1') {
$('#zjzl').text('身份证');
}
$('#zjhm').text(userInfo.zjhm);
}
//设置查询条件内容
function SetCheckContent() {
layui.use(['form', 'upload', 'layer'], function () {
......
......@@ -38,28 +38,32 @@ $(function () {
loadSqrDetail()
//读取邮寄信息
loadMailDetail();
// 读取权利人
authorityPerson();
applicationMethod();
});
// 区分单方申请和双方申请
function applicationMethod() {
// 在这里页面显示进行处理
if (slsqxx.sqrlb == '1' && slsqxx.sqfs == '2') {
$('.obtaining_license').hide();
if (slsqxx.sqrlb == '1') {
$('.obtaining_license').show();
$('#obligeeInformation').text('权利人信息');
$('.nextSubmitButton').append('<div class="next_button">' +
'<button type="button" lay-submit="" lay-filter="submit1" class="layui-btn layui-btn-normal">' +
'<a onclick="skipClick()">下一步</a>' +
'</button>' +
'</div>')
} else {
$('.obtaining_license').hide();
$('#obligeeInformation').text('义务人信息');
$('.nextSubmitButton').empty();
$('.nextSubmitButton').append('<div class="next_button">'+
'<button type="button" lay-submit="" lay-filter="submit1" class="layui-btn layui-btn-normal">'+
'<a onclick="skipClick()">下一步</a></button></div>')
}
//
if (slsqxx.sqfs == '1') {
if (slsqxx.sqfs == '1' && slsqxx.sqrlb == '1') {
$('.folkObligee').show();
}
// 动态设置样式
for(var i=0;i<$('.conImageUpdate').length;i++) {
$('.conImageUpdate').eq(i).find('.imageUpdateTitle').css('height', $('.conImageUpdate').eq(i).height()-60);
}
});
}
//读取受理信息
function loadAcceptDetail() {
......@@ -140,7 +144,7 @@ function loadSqrDetail() {
function loadMailDetail() {
// 领证方式
lzfs = slsqxx.lzfs;
if (lzfs == 2) {
if (lzfs == '2') {
$('.shipping_method').show();
$('.submitButton').hide();
} else {
......@@ -158,65 +162,68 @@ function loadMailDetail() {
}
}
$('.radioInfo').click(function () {
let index = $(this).attr("value")
if ($('#layui-form .layui-form-item').length > 1) {
return false
} else {
if (index == 2 || index == 3) {
$('.add_form').show()
// 权利人添加
function authorityPerson() {
$('.radioInfo').click(function () {
let index = $(this).attr("value")
if ($('#layui-form .layui-form-item').length > 1) {
return false
} else {
$('.add_form').hide()
if (index == 2 || index == 3) {
$('.add_form').show()
} else {
$('.add_form').hide()
}
}
}
})
// form 添加
$('.add_form').click(function () {
$('#layui-form').append(
'<div class="layui-form-item">' +
'<div class="layui-inline">' +
'<label class="layui-form-label">姓名</label>' +
'<div class="layui-input-block">' +
'<input type="text" name="name" required lay-verify="name" placeholder="请输权利人" class="layui-input">' +
'</div>' +
'</div>' +
'<div class="layui-inline idCard">' +
'<label class="layui-form-label">身份证类型</label>' +
'<div class="layui-input-block">' +
'<select lay-filter="typeId">' +
'<option value="1">身份证</option>' +
'<option value="2">军官证</option>' +
'</select>' +
'</div>' +
'</div>' +
'<div class="layui-inline">' +
'<label class="layui-form-label">证件号码</label>' +
'<div class="layui-input-block">' +
'<input type="tel" name="card" maxlength="18" required lay-verify="card" placeholder="请输证件号码" class="layui-input">' +
'</div>' +
'</div>' +
'<div class="layui-inline">' +
'<label class="layui-form-label">联系方式</label>' +
'<div class="layui-input-block">' +
'<input type="tel" name="phone" maxlength="11" required lay-verify="phone" placeholder="请输联系方式" class="layui-input">' +
'</div>' +
'</div>' +
'<i class="layui-icon layui-icon-reduce-circle"></i>' +
'</div>'
)
layui.use('form', function () {
var form = layui.form;
form.render('select');
form.on('select(typeId)', function (data) {
console.log(data.value);
});
})
// 编辑
$(document).on("click", ".layui-icon-reduce-circle", function (e) {
$(this).parent().remove()
// form 添加
$('.add_form').click(function () {
$('#layui-form').append(
'<div class="layui-form-item">' +
'<div class="layui-inline">' +
'<label class="layui-form-label">姓名</label>' +
'<div class="layui-input-block">' +
'<input type="text" name="name" required lay-verify="name" placeholder="请输权利人" class="layui-input">' +
'</div>' +
'</div>' +
'<div class="layui-inline idCard">' +
'<label class="layui-form-label">身份证类型</label>' +
'<div class="layui-input-block">' +
'<select lay-filter="typeId">' +
'<option value="1">身份证</option>' +
'<option value="2">军官证</option>' +
'</select>' +
'</div>' +
'</div>' +
'<div class="layui-inline">' +
'<label class="layui-form-label">证件号码</label>' +
'<div class="layui-input-block">' +
'<input type="tel" name="card" maxlength="18" required lay-verify="card" placeholder="请输证件号码" class="layui-input">' +
'</div>' +
'</div>' +
'<div class="layui-inline">' +
'<label class="layui-form-label">联系方式</label>' +
'<div class="layui-input-block">' +
'<input type="tel" name="phone" maxlength="11" required lay-verify="phone" placeholder="请输联系方式" class="layui-input">' +
'</div>' +
'</div>' +
'<i class="layui-icon layui-icon-reduce-circle"></i>' +
'</div>'
)
layui.use('form', function () {
var form = layui.form;
form.render('select');
form.on('select(typeId)', function (data) {
console.log(data.value);
});
})
// 编辑
$(document).on("click", ".layui-icon-reduce-circle", function (e) {
$(this).parent().remove()
})
})
})
}
// 图片上传
// 询问笔录
$('.record').click(function (event) {
......
......@@ -52,7 +52,7 @@
</div>
</div>
<div class="layui-form-item">
<div style="float: left;width: 220px;">
<div style="float: left;width: 220px;margin-right:20px">
<select id="bdcqzType" lay-verify="required" lay-filter="xmFilter">
</select>
</div>
......