学校周边重点人员
以上功能完善
This commit is contained in:
parent
dfb6a4c984
commit
4e8afee4b9
@ -1,7 +1,9 @@
|
||||
package cn.com.tenlion.systembase.controller.api.schoolkey;
|
||||
|
||||
import cn.com.tenlion.systembase.pojo.dtos.population.PopulationDTO;
|
||||
import cn.com.tenlion.systembase.pojo.dtos.schoolkey.SchoolKeyDTO;
|
||||
import cn.com.tenlion.systembase.pojo.vos.schoolkey.SchoolKeyVO;
|
||||
import cn.com.tenlion.systembase.remote.populationmsg.IPopulationMsgService;
|
||||
import cn.com.tenlion.systembase.service.schoolkey.ISchoolKeyService;
|
||||
import ink.wgink.annotation.CheckRequestBodyAnnotation;
|
||||
import ink.wgink.common.base.DefaultBaseController;
|
||||
@ -33,6 +35,8 @@ public class SchoolKeyController extends DefaultBaseController {
|
||||
|
||||
@Autowired
|
||||
private ISchoolKeyService schoolKeyService;
|
||||
@Autowired
|
||||
private IPopulationMsgService populationMsgService;
|
||||
|
||||
@ApiOperation(value = "新增学校周边重点人员", notes = "新增学校周边重点人员接口")
|
||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
||||
@ -108,4 +112,16 @@ public class SchoolKeyController extends DefaultBaseController {
|
||||
return new SuccessResultData<>(schoolKeyService.count(params));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "住户信息表详情", notes = "住户信息表详情接口")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "houseUserId", value = "住户信息表ID", paramType = "path")
|
||||
})
|
||||
@ApiResponses({@ApiResponse(code = 400, message = "请求失败", response = ErrorResult.class)})
|
||||
@GetMapping("get-by-id-card-number/{cardNumber}")
|
||||
public PopulationDTO getByIdCardNumber(@PathVariable("cardNumber") String cardNumber) {
|
||||
String url = "http://192.168.0.109:8080/population";
|
||||
PopulationDTO populationDTO = populationMsgService.getByIdCardNumber(url, cardNumber);
|
||||
return populationDTO;
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,317 @@
|
||||
package cn.com.tenlion.systembase.pojo.dtos.population;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
|
||||
/**
|
||||
*
|
||||
* @ClassName: BasePopulationInfoDTO
|
||||
* @Description: 人员信息基础表
|
||||
* @Author: WenG
|
||||
* @Date: 2020-11-16 17:17
|
||||
* @Version: 1.0
|
||||
**/
|
||||
@ApiModel
|
||||
public class PopulationDTO {
|
||||
|
||||
@ApiModelProperty(name = "basePopulationInfoId", value = "主键")
|
||||
private String basePopulationInfoId;
|
||||
@ApiModelProperty(name = "idCardNumber", value = "公民身份证号")
|
||||
private String idCardNumber;
|
||||
@ApiModelProperty(name = "fullName", value = "全名")
|
||||
private String fullName;
|
||||
@ApiModelProperty(name = "nameUsedBefore", value = "曾用名")
|
||||
private String nameUsedBefore;
|
||||
@ApiModelProperty(name = "gender", value = "性别")
|
||||
private String gender;
|
||||
@ApiModelProperty(name = "genderDictionaryName", value = "性别字典名称")
|
||||
private String genderDictionaryName;
|
||||
@ApiModelProperty(name = "birthDate", value = "出生日期")
|
||||
private String birthDate;
|
||||
@ApiModelProperty(name = "nation", value = "民族")
|
||||
private String nation;
|
||||
@ApiModelProperty(name = "nationDictionaryName", value = "民族字典名称")
|
||||
private String nationDictionaryName;
|
||||
@ApiModelProperty(name = "nativePlace", value = "籍贯")
|
||||
private String nativePlace;
|
||||
@ApiModelProperty(name = "nativePlaceAddr", value = "籍贯详细地址")
|
||||
private String nativePlaceAddr;
|
||||
@ApiModelProperty(name = "nativePlaceDictionaryName", value = "籍贯字典名称")
|
||||
private String nativePlaceDictionaryName;
|
||||
@ApiModelProperty(name = "politicalStatus", value = "政治面貌")
|
||||
private String politicalStatus;
|
||||
@ApiModelProperty(name = "politicalStatusDictionaryName", value = "政治面貌字典名称")
|
||||
private String politicalStatusDictionaryName;
|
||||
@ApiModelProperty(name = "maritalStatus", value = "婚姻情况")
|
||||
private String maritalStatus;
|
||||
@ApiModelProperty(name = "maritalStatusDictionaryName", value = "婚姻情况字典名称")
|
||||
private String maritalStatusDictionaryName;
|
||||
@ApiModelProperty(name = "education", value = "学历")
|
||||
private String education;
|
||||
@ApiModelProperty(name = "educationDictionaryName", value = "学历字典名称")
|
||||
private String educationDictionaryName;
|
||||
@ApiModelProperty(name = "religion", value = "宗教信仰")
|
||||
private String religion;
|
||||
@ApiModelProperty(name = "religionDictionaryName", value = "宗教信仰字典名称")
|
||||
private String religionDictionaryName;
|
||||
@ApiModelProperty(name = "occupationCategory", value = "职业类别")
|
||||
private String occupationCategory;
|
||||
@ApiModelProperty(name = "occupationCategoryDictionaryName", value = "职业类别字典名称")
|
||||
private String occupationCategoryDictionaryName;
|
||||
@ApiModelProperty(name = "occupation", value = "职业")
|
||||
private String occupation;
|
||||
@ApiModelProperty(name = "serviceSpace", value = "服务处所")
|
||||
private String serviceSpace;
|
||||
@ApiModelProperty(name = "telephone", value = "联系方式(手机号码或固话)")
|
||||
private String telephone;
|
||||
@ApiModelProperty(name = "registeredResidence", value = "户籍地")
|
||||
private String registeredResidence;
|
||||
@ApiModelProperty(name = "registeredResidenceDictionaryName", value = "户籍地字典名称")
|
||||
private String registeredResidenceDictionaryName;
|
||||
@ApiModelProperty(name = "registeredResidenceAddr", value = "户籍详细地址")
|
||||
private String registeredResidenceAddr;
|
||||
@ApiModelProperty(name = "currentResidence", value = "现住地")
|
||||
private String currentResidence;
|
||||
@ApiModelProperty(name = "currentResidenceDictionaryName", value = "现住地字典名称")
|
||||
private String currentResidenceDictionaryName;
|
||||
@ApiModelProperty(name = "currentResidenceAddr", value = "现住地详细地址")
|
||||
private String currentResidenceAddr;
|
||||
|
||||
public String getBasePopulationInfoId() {
|
||||
return basePopulationInfoId == null ? "" : basePopulationInfoId.trim();
|
||||
}
|
||||
|
||||
public void setBasePopulationInfoId(String basePopulationInfoId) {
|
||||
this.basePopulationInfoId = basePopulationInfoId;
|
||||
}
|
||||
|
||||
public String getIdCardNumber() {
|
||||
return idCardNumber == null ? "" : idCardNumber.trim();
|
||||
}
|
||||
|
||||
public void setIdCardNumber(String idCardNumber) {
|
||||
this.idCardNumber = idCardNumber;
|
||||
}
|
||||
|
||||
public String getFullName() {
|
||||
return fullName == null ? "" : fullName.trim();
|
||||
}
|
||||
|
||||
public void setFullName(String fullName) {
|
||||
this.fullName = fullName;
|
||||
}
|
||||
|
||||
public String getNameUsedBefore() {
|
||||
return nameUsedBefore == null ? "" : nameUsedBefore.trim();
|
||||
}
|
||||
|
||||
public void setNameUsedBefore(String nameUsedBefore) {
|
||||
this.nameUsedBefore = nameUsedBefore;
|
||||
}
|
||||
|
||||
public String getGender() {
|
||||
return gender == null ? "" : gender.trim();
|
||||
}
|
||||
|
||||
public void setGender(String gender) {
|
||||
this.gender = gender;
|
||||
}
|
||||
|
||||
public String getGenderDictionaryName() {
|
||||
return genderDictionaryName == null ? "" : genderDictionaryName.trim();
|
||||
}
|
||||
|
||||
public void setGenderDictionaryName(String genderDictionaryName) {
|
||||
this.genderDictionaryName = genderDictionaryName;
|
||||
}
|
||||
public String getBirthDate() {
|
||||
return birthDate == null ? "" : birthDate.trim();
|
||||
}
|
||||
|
||||
public void setBirthDate(String birthDate) {
|
||||
this.birthDate = birthDate;
|
||||
}
|
||||
|
||||
public String getNation() {
|
||||
return nation == null ? "" : nation.trim();
|
||||
}
|
||||
|
||||
public void setNation(String nation) {
|
||||
this.nation = nation;
|
||||
}
|
||||
|
||||
public String getNationDictionaryName() {
|
||||
return nationDictionaryName == null ? "" : nationDictionaryName.trim();
|
||||
}
|
||||
|
||||
public void setNationDictionaryName(String nationDictionaryName) {
|
||||
this.nationDictionaryName = nationDictionaryName;
|
||||
}
|
||||
public String getNativePlace() {
|
||||
return nativePlace == null ? "" : nativePlace.trim();
|
||||
}
|
||||
|
||||
public void setNativePlace(String nativePlace) {
|
||||
this.nativePlace = nativePlace;
|
||||
}
|
||||
|
||||
public String getNativePlaceDictionaryName() {
|
||||
return nativePlaceDictionaryName == null ? "" : nativePlaceDictionaryName.trim();
|
||||
}
|
||||
|
||||
public void setNativePlaceDictionaryName(String nativePlaceDictionaryName) {
|
||||
this.nativePlaceDictionaryName = nativePlaceDictionaryName;
|
||||
}
|
||||
public String getPoliticalStatus() {
|
||||
return politicalStatus == null ? "" : politicalStatus.trim();
|
||||
}
|
||||
|
||||
public void setPoliticalStatus(String politicalStatus) {
|
||||
this.politicalStatus = politicalStatus;
|
||||
}
|
||||
|
||||
public String getPoliticalStatusDictionaryName() {
|
||||
return politicalStatusDictionaryName == null ? "" : politicalStatusDictionaryName.trim();
|
||||
}
|
||||
|
||||
public void setPoliticalStatusDictionaryName(String politicalStatusDictionaryName) {
|
||||
this.politicalStatusDictionaryName = politicalStatusDictionaryName;
|
||||
}
|
||||
public String getMaritalStatus() {
|
||||
return maritalStatus == null ? "" : maritalStatus.trim();
|
||||
}
|
||||
|
||||
public void setMaritalStatus(String maritalStatus) {
|
||||
this.maritalStatus = maritalStatus;
|
||||
}
|
||||
|
||||
public String getMaritalStatusDictionaryName() {
|
||||
return maritalStatusDictionaryName == null ? "" : maritalStatusDictionaryName.trim();
|
||||
}
|
||||
|
||||
public void setMaritalStatusDictionaryName(String maritalStatusDictionaryName) {
|
||||
this.maritalStatusDictionaryName = maritalStatusDictionaryName;
|
||||
}
|
||||
public String getEducation() {
|
||||
return education == null ? "" : education.trim();
|
||||
}
|
||||
|
||||
public void setEducation(String education) {
|
||||
this.education = education;
|
||||
}
|
||||
|
||||
public String getEducationDictionaryName() {
|
||||
return educationDictionaryName == null ? "" : educationDictionaryName.trim();
|
||||
}
|
||||
|
||||
public void setEducationDictionaryName(String educationDictionaryName) {
|
||||
this.educationDictionaryName = educationDictionaryName;
|
||||
}
|
||||
public String getReligion() {
|
||||
return religion == null ? "" : religion.trim();
|
||||
}
|
||||
|
||||
public void setReligion(String religion) {
|
||||
this.religion = religion;
|
||||
}
|
||||
|
||||
public String getReligionDictionaryName() {
|
||||
return religionDictionaryName == null ? "" : religionDictionaryName.trim();
|
||||
}
|
||||
|
||||
public void setReligionDictionaryName(String religionDictionaryName) {
|
||||
this.religionDictionaryName = religionDictionaryName;
|
||||
}
|
||||
public String getOccupationCategory() {
|
||||
return occupationCategory == null ? "" : occupationCategory.trim();
|
||||
}
|
||||
|
||||
public void setOccupationCategory(String occupationCategory) {
|
||||
this.occupationCategory = occupationCategory;
|
||||
}
|
||||
|
||||
public String getOccupationCategoryDictionaryName() {
|
||||
return occupationCategoryDictionaryName == null ? "" : occupationCategoryDictionaryName.trim();
|
||||
}
|
||||
|
||||
public void setOccupationCategoryDictionaryName(String occupationCategoryDictionaryName) {
|
||||
this.occupationCategoryDictionaryName = occupationCategoryDictionaryName;
|
||||
}
|
||||
public String getOccupation() {
|
||||
return occupation == null ? "" : occupation.trim();
|
||||
}
|
||||
|
||||
public void setOccupation(String occupation) {
|
||||
this.occupation = occupation;
|
||||
}
|
||||
|
||||
public String getServiceSpace() {
|
||||
return serviceSpace == null ? "" : serviceSpace.trim();
|
||||
}
|
||||
|
||||
public void setServiceSpace(String serviceSpace) {
|
||||
this.serviceSpace = serviceSpace;
|
||||
}
|
||||
|
||||
public String getTelephone() {
|
||||
return telephone == null ? "" : telephone.trim();
|
||||
}
|
||||
|
||||
public void setTelephone(String telephone) {
|
||||
this.telephone = telephone;
|
||||
}
|
||||
|
||||
public String getRegisteredResidence() {
|
||||
return registeredResidence == null ? "" : registeredResidence.trim();
|
||||
}
|
||||
|
||||
public void setRegisteredResidence(String registeredResidence) {
|
||||
this.registeredResidence = registeredResidence;
|
||||
}
|
||||
|
||||
public String getRegisteredResidenceDictionaryName() {
|
||||
return registeredResidenceDictionaryName == null ? "" : registeredResidenceDictionaryName.trim();
|
||||
}
|
||||
|
||||
public void setRegisteredResidenceDictionaryName(String registeredResidenceDictionaryName) {
|
||||
this.registeredResidenceDictionaryName = registeredResidenceDictionaryName;
|
||||
}
|
||||
public String getRegisteredResidenceAddr() {
|
||||
return registeredResidenceAddr == null ? "" : registeredResidenceAddr.trim();
|
||||
}
|
||||
|
||||
public void setRegisteredResidenceAddr(String registeredResidenceAddr) {
|
||||
this.registeredResidenceAddr = registeredResidenceAddr;
|
||||
}
|
||||
|
||||
public String getCurrentResidence() {
|
||||
return currentResidence == null ? "" : currentResidence.trim();
|
||||
}
|
||||
|
||||
public void setCurrentResidence(String currentResidence) {
|
||||
this.currentResidence = currentResidence;
|
||||
}
|
||||
|
||||
public String getCurrentResidenceDictionaryName() {
|
||||
return currentResidenceDictionaryName == null ? "" : currentResidenceDictionaryName.trim();
|
||||
}
|
||||
|
||||
public void setCurrentResidenceDictionaryName(String currentResidenceDictionaryName) {
|
||||
this.currentResidenceDictionaryName = currentResidenceDictionaryName;
|
||||
}
|
||||
public String getCurrentResidenceAddr() {
|
||||
return currentResidenceAddr == null ? "" : currentResidenceAddr.trim();
|
||||
}
|
||||
|
||||
public void setCurrentResidenceAddr(String currentResidenceAddr) {
|
||||
this.currentResidenceAddr = currentResidenceAddr;
|
||||
}
|
||||
|
||||
public String getNativePlaceAddr() {
|
||||
return nativePlaceAddr == null ? "" : nativePlaceAddr;
|
||||
}
|
||||
|
||||
public void setNativePlaceAddr(String nativePlaceAddr) {
|
||||
this.nativePlaceAddr = nativePlaceAddr;
|
||||
}
|
||||
}
|
@ -0,0 +1,23 @@
|
||||
package cn.com.tenlion.systembase.remote.populationmsg;
|
||||
|
||||
import cn.com.tenlion.systembase.pojo.dtos.population.PopulationDTO;
|
||||
import ink.wgink.annotation.rpc.rest.RemoteService;
|
||||
import ink.wgink.annotation.rpc.rest.method.RemoteGetMethod;
|
||||
import ink.wgink.annotation.rpc.rest.params.RemotePathParams;
|
||||
import ink.wgink.annotation.rpc.rest.params.RemoteServerParams;
|
||||
|
||||
/**
|
||||
* @ClassName: IPopulationMsgService
|
||||
* @Description: 通过身份证号码,查询人口信息表中的数据
|
||||
* @Author: CodeFactory
|
||||
* @Date: 2021-09-24 17:03:54
|
||||
* @Version: 3.0
|
||||
**/
|
||||
|
||||
@RemoteService
|
||||
public interface IPopulationMsgService {
|
||||
|
||||
@RemoteGetMethod("/app/basepopulationinforelease/getByIdCardNumber/{userId}")
|
||||
PopulationDTO getByIdCardNumber(@RemoteServerParams String remotePath, @RemotePathParams("userId") String userId);
|
||||
|
||||
}
|
@ -86,16 +86,7 @@
|
||||
[
|
||||
{type:'checkbox', fixed: 'left'},
|
||||
{field:'rowNum', width:80, title: '序号', fixed: 'left', align:'center', templet: '<span>{{d.LAY_INDEX}}</span>'},
|
||||
{field: 'degreeOfHarm', width: 180, title: '危害程度字典表ID', align:'center',
|
||||
templet: function(row) {
|
||||
var rowData = row[this.field];
|
||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
||||
return '-';
|
||||
}
|
||||
return rowData;
|
||||
}
|
||||
},
|
||||
{field: 'degreeOfHarmName', width: 180, title: '危害程度名称', align:'center',
|
||||
{field: 'degreeOfHarmName', width: 180, title: '危害程度', align:'center',
|
||||
templet: function(row) {
|
||||
var rowData = row[this.field];
|
||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
||||
@ -121,52 +112,7 @@
|
||||
}
|
||||
return rowData;
|
||||
}
|
||||
},
|
||||
{field: 'creator', width: 180, title: '', align:'center',
|
||||
templet: function(row) {
|
||||
var rowData = row[this.field];
|
||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
||||
return '-';
|
||||
}
|
||||
return rowData;
|
||||
}
|
||||
},
|
||||
{field: 'gmtCreate', width: 180, title: '', align:'center',
|
||||
templet: function(row) {
|
||||
var rowData = row[this.field];
|
||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
||||
return '-';
|
||||
}
|
||||
return rowData;
|
||||
}
|
||||
},
|
||||
{field: 'modifier', width: 180, title: '', align:'center',
|
||||
templet: function(row) {
|
||||
var rowData = row[this.field];
|
||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
||||
return '-';
|
||||
}
|
||||
return rowData;
|
||||
}
|
||||
},
|
||||
{field: 'gmtModified', width: 180, title: '', align:'center',
|
||||
templet: function(row) {
|
||||
var rowData = row[this.field];
|
||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
||||
return '-';
|
||||
}
|
||||
return rowData;
|
||||
}
|
||||
},
|
||||
{field: 'isDelete', width: 180, title: '', align:'center',
|
||||
templet: function(row) {
|
||||
var rowData = row[this.field];
|
||||
if(typeof(rowData) === 'undefined' || rowData == null || rowData == '') {
|
||||
return '-';
|
||||
}
|
||||
return rowData;
|
||||
}
|
||||
},
|
||||
}
|
||||
]
|
||||
],
|
||||
page: true,
|
||||
|
@ -22,40 +22,90 @@
|
||||
</div>
|
||||
<div class="layui-card-body" style="padding: 15px;">
|
||||
<form class="layui-form layui-form-pane" lay-filter="dataForm">
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">基础人员信息表ID</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="baseId" name="baseId" class="layui-input" value="" placeholder="请输入基础人员信息表ID" maxlength="36">
|
||||
<input type="hidden" id="baseId" name="baseId" class="layui-input" value="" placeholder="请输入基础人员信息表ID" maxlength="36">
|
||||
<div class="layui-row">
|
||||
<div class="layui-col-md3">
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">身份证</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="idCardNumber" name="idCardNumber" class="layui-input" value="" placeholder="请输入公民身份证进行检索">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-col-md3">
|
||||
<div style="margin: 4px 4px;">
|
||||
<button type="button" id="search" class="layui-btn layui-btn-sm">
|
||||
<i class="fa fa-lg fa-search"></i> 搜索
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="div-base-population-info" style="display: none">
|
||||
<blockquote class="layui-elem-quote">人员基础信息</blockquote>
|
||||
<div class="layui-row">
|
||||
<div class="layui-col-md3">
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">姓名</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="fullName" name="fullName" class="layui-input" value="" readonly="readonly">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-col-md3">
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">性别</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="gender" name="gender" class="layui-input" value="" readonly="readonly">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-col-md3">
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">联系方式</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="telephone" name="telephone" class="layui-input" value="" readonly="readonly">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-col-md3">
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">籍贯</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="nativePlace" name="nativePlace" class="layui-input" value="" readonly="readonly">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-row">
|
||||
<div class="layui-col-md12">
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">现住地</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="currentResidence" name="currentResidence" class="layui-input" value="" readonly="readonly">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">危害程度字典表ID</label>
|
||||
<input type="hidden" id="degreeOfHarmName" name="degreeOfHarmName" class="layui-input" value="" placeholder="请输入危害程度名称" maxlength="20">
|
||||
<input type="hidden" id="degreeOfHarmCode" name="degreeOfHarmCode" class="layui-input" value="" placeholder="请输入危害程度编码" maxlength="2">
|
||||
<label class="layui-form-label">危害程度</label>
|
||||
<div class="layui-input-block layui-form" id="degreeOfHarmSelectTemplateBox" lay-filter="degreeOfHarmSelectTemplateBox"></div>
|
||||
<script id="degreeOfHarmSelectTemplate" type="text/html">
|
||||
<select id="degreeOfHarm" name="degreeOfHarm">
|
||||
<option value="">请选择危害程度字典表ID</option>
|
||||
<option value="">请选择危害程度</option>
|
||||
{{# for(var i = 0, item; item = d[i++];) { }}
|
||||
<option value="{{item.selectId}}">{{item.selectName}}</option>
|
||||
<option value="{{item.dataId}},{{item.dataSummary}}">{{item.dataName}}</option>
|
||||
{{# } }}
|
||||
</select>
|
||||
</script>
|
||||
</div>
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">危害程度名称</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="degreeOfHarmName" name="degreeOfHarmName" class="layui-input" value="" placeholder="请输入危害程度名称" maxlength="20">
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">危害程度编码</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="degreeOfHarmCode" name="degreeOfHarmCode" class="layui-input" value="" placeholder="请输入危害程度编码" maxlength="2">
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-form-item">
|
||||
<div class="layui-form-item" pane>
|
||||
<label class="layui-form-label">是否关注</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="number" id="isFollow" name="isFollow" class="layui-input" value="" placeholder="请输入是否关注" lay-verify="required">
|
||||
<input type="radio" name="isFollow" lay-filter="isFollow" value="1" title="是" checked>
|
||||
<input type="radio" name="isFollow" lay-filter="isFollow" value="0" title="否">
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-form-item layui-layout-admin">
|
||||
@ -88,63 +138,75 @@
|
||||
var wangEditorObj = {};
|
||||
var viewerObj = {};
|
||||
|
||||
$(document).on('click','#search',function(){
|
||||
queryBasePopulationInfo($('#idCardNumber').val());
|
||||
});
|
||||
|
||||
function queryBasePopulationInfo(idCardNumber){
|
||||
if(!idCardNumber){
|
||||
top.dialog.msg('请输入身份证号进行查询');
|
||||
return false;
|
||||
}
|
||||
var loadIndex = layer.load(0);
|
||||
top.restAjax.get(top.restAjax.path('api/schoolkey/get-by-id-card-number/{idCardNumber}', [idCardNumber]),
|
||||
{}, null, function(code, data) {
|
||||
if(!data || !data.basePopulationInfoId) {
|
||||
top.dialog.msg('暂无此人,请先补充人员基本信息');
|
||||
var dataFormData = {};
|
||||
dataFormData['populationId'] = '';
|
||||
dataFormData['name'] = '';
|
||||
dataFormData['sex'] = '';
|
||||
dataFormData['cardNum'] = '';
|
||||
form.val('dataForm', dataFormData);
|
||||
form.render(null, 'dataForm');
|
||||
$('#submitBtn').addClass("layui-btn-disabled").attr("disabled", true);
|
||||
$('.div-base-population-info').hide();
|
||||
return false;
|
||||
}
|
||||
var dataFormData = {};
|
||||
for(var i in data) {
|
||||
dataFormData[i] = data[i] +'';
|
||||
}
|
||||
dataFormData['baseId'] = dataFormData['basePopulationInfoId'];
|
||||
dataFormData['name'] = dataFormData['fullName'];
|
||||
dataFormData['sex'] = dataFormData['genderDictionaryName'];
|
||||
dataFormData['cardNum'] = dataFormData['idCardNumber'];
|
||||
form.val('dataForm', dataFormData);
|
||||
form.render(null, 'dataForm');
|
||||
$('.div-base-population-info').show();
|
||||
}, function(code, data) {
|
||||
top.dialog.msg(data.msg);
|
||||
},function(){
|
||||
|
||||
},
|
||||
function () {
|
||||
layer.close(loadIndex);
|
||||
});
|
||||
}
|
||||
|
||||
// 危害程度change事件
|
||||
form.on('select(degreeOfHarm)', function(data){
|
||||
if(!data.value) {
|
||||
|
||||
}else {
|
||||
var valueArr = data.value.split(',');
|
||||
if(2 == valueArr.length) {
|
||||
var text = $('#degreeOfHarm option:selected').text();
|
||||
$('#degreeOfHarm option:selected').val(valueArr[0]);
|
||||
$('#degreeOfHarmName').val(text);
|
||||
$('#degreeOfHarmCode').val(valueArr[1]);
|
||||
}
|
||||
}
|
||||
form.render("select");
|
||||
});
|
||||
|
||||
function closeBox() {
|
||||
parent.layer.close(parent.layer.getFrameIndex(window.name));
|
||||
}
|
||||
|
||||
function refreshDownloadTemplet(fileName, file) {
|
||||
var dataRander = {};
|
||||
dataRander[fileName] = file;
|
||||
|
||||
laytpl(document.getElementById(fileName +'FileDownload').innerHTML).render(dataRander, function(html) {
|
||||
document.getElementById(fileName +'FileBox').innerHTML = html;
|
||||
});
|
||||
}
|
||||
|
||||
// 初始化文件列表
|
||||
function initFileList(fileName, ids, callback) {
|
||||
var dataForm = {};
|
||||
dataForm[fileName] = ids;
|
||||
form.val('dataForm', dataForm);
|
||||
|
||||
if(!ids) {
|
||||
refreshDownloadTemplet(fileName, []);
|
||||
if(callback) {
|
||||
callback(fileName, []);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
top.restAjax.get(top.restAjax.path('api/file/list', []), {
|
||||
ids: ids
|
||||
}, null, function(code, data) {
|
||||
refreshDownloadTemplet(fileName, data);
|
||||
if(callback) {
|
||||
callback(fileName, data);
|
||||
}
|
||||
}, function(code, data) {
|
||||
top.dialog.msg(data.msg);
|
||||
});
|
||||
}
|
||||
|
||||
// 初始化视频
|
||||
function initVideo(fileName, data) {
|
||||
for(var i = 0, item; item = data[i++];) {
|
||||
var player = new ckplayer({
|
||||
container: '#'+ fileName + i,
|
||||
variable: 'player',
|
||||
flashplayer: false,
|
||||
video: {
|
||||
file: 'route/file/download/true/'+ item.fileId,
|
||||
type: 'video/mp4'
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
// 初始化危害程度字典表ID下拉选择
|
||||
// 初始化危害程度下拉选择
|
||||
function initDegreeOfHarmSelect() {
|
||||
top.restAjax.get(top.restAjax.path('api/url/selectUrl', []), {}, null, function(code, data, args) {
|
||||
top.restAjax.get(top.restAjax.path('api/data/listbyparentid/{dataParentId}', ['ac006130-7403-40ef-b647-e89bb8cce631']), {}, null, function(code, data, args) {
|
||||
laytpl(document.getElementById('degreeOfHarmSelectTemplate').innerHTML).render(data, function(html) {
|
||||
document.getElementById('degreeOfHarmSelectTemplateBox').innerHTML = html;
|
||||
});
|
||||
@ -154,7 +216,6 @@
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
// 初始化内容
|
||||
function initData() {
|
||||
initDegreeOfHarmSelect();
|
||||
@ -163,6 +224,11 @@
|
||||
|
||||
// 提交表单
|
||||
form.on('submit(submitForm)', function(formData) {
|
||||
var baseId = $('#baseId').val();
|
||||
if(!baseId) {
|
||||
top.dialog.msg('请先查询人员基础信息');
|
||||
return false;
|
||||
}
|
||||
top.dialog.confirm(top.dataMessage.commit, function(index) {
|
||||
top.dialog.close(index);
|
||||
var loadLayerIndex;
|
||||
@ -193,10 +259,6 @@
|
||||
$('.close').on('click', function() {
|
||||
closeBox();
|
||||
});
|
||||
|
||||
// 校验
|
||||
form.verify({
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
|
@ -22,46 +22,96 @@
|
||||
</div>
|
||||
<div class="layui-card-body" style="padding: 15px;">
|
||||
<form class="layui-form layui-form-pane" lay-filter="dataForm">
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">基础人员信息表ID</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="baseId" name="baseId" class="layui-input" value="" placeholder="请输入基础人员信息表ID" maxlength="36">
|
||||
<input type="hidden" id="baseId" name="baseId" class="layui-input" value="" placeholder="请输入基础人员信息表ID" maxlength="36">
|
||||
<div class="layui-row">
|
||||
<div class="layui-col-md3">
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">身份证</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="idCardNumber" name="idCardNumber" class="layui-input" value="" placeholder="请输入公民身份证进行检索">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-col-md3">
|
||||
<div style="margin: 4px 4px;">
|
||||
<button type="button" id="search" class="layui-btn layui-btn-sm">
|
||||
<i class="fa fa-lg fa-search"></i> 搜索
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="div-base-population-info" style="display: none">
|
||||
<blockquote class="layui-elem-quote">人员基础信息</blockquote>
|
||||
<div class="layui-row">
|
||||
<div class="layui-col-md3">
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">姓名</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="fullName" name="fullName" class="layui-input" value="" readonly="readonly">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-col-md3">
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">性别</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="gender" name="gender" class="layui-input" value="" readonly="readonly">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-col-md3">
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">联系方式</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="telephone" name="telephone" class="layui-input" value="" readonly="readonly">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-col-md3">
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">籍贯</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="nativePlace" name="nativePlace" class="layui-input" value="" readonly="readonly">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-row">
|
||||
<div class="layui-col-md12">
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">现住地</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="currentResidence" name="currentResidence" class="layui-input" value="" readonly="readonly">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">危害程度字典表ID</label>
|
||||
<input type="hidden" id="degreeOfHarmName" name="degreeOfHarmName" class="layui-input" value="" placeholder="请输入危害程度名称" maxlength="20">
|
||||
<input type="hidden" id="degreeOfHarmCode" name="degreeOfHarmCode" class="layui-input" value="" placeholder="请输入危害程度编码" maxlength="2">
|
||||
<label class="layui-form-label">危害程度</label>
|
||||
<div class="layui-input-block layui-form" id="degreeOfHarmSelectTemplateBox" lay-filter="degreeOfHarmSelectTemplateBox"></div>
|
||||
<script id="degreeOfHarmSelectTemplate" type="text/html">
|
||||
<select id="degreeOfHarm" name="degreeOfHarm">
|
||||
<option value="">请选择危害程度字典表ID</option>
|
||||
<option value="">请选择危害程度</option>
|
||||
{{# for(var i = 0, item; item = d[i++];) { }}
|
||||
<option value="{{item.selectId}}">{{item.selectName}}</option>
|
||||
<option value="{{item.dataId}},{{item.dataSummary}}">{{item.dataName}}</option>
|
||||
{{# } }}
|
||||
</select>
|
||||
</script>
|
||||
</div>
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">危害程度名称</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="degreeOfHarmName" name="degreeOfHarmName" class="layui-input" value="" placeholder="请输入危害程度名称" maxlength="20">
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-form-item">
|
||||
<label class="layui-form-label">危害程度编码</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="text" id="degreeOfHarmCode" name="degreeOfHarmCode" class="layui-input" value="" placeholder="请输入危害程度编码" maxlength="2">
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-form-item">
|
||||
<div class="layui-form-item" pane>
|
||||
<label class="layui-form-label">是否关注</label>
|
||||
<div class="layui-input-block">
|
||||
<input type="number" id="isFollow" name="isFollow" class="layui-input" value="" placeholder="请输入是否关注" lay-verify="required">
|
||||
<input type="radio" name="isFollow" lay-filter="isFollow" value="1" title="是" checked>
|
||||
<input type="radio" name="isFollow" lay-filter="isFollow" value="0" title="否">
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-form-item layui-layout-admin">
|
||||
<div class="layui-input-block">
|
||||
<div class="layui-footer" style="left: 0;">
|
||||
<button type="button" class="layui-btn" lay-submit lay-filter="submitForm">提交编辑</button>
|
||||
<button type="button" class="layui-btn" lay-submit lay-filter="submitForm">提交新增</button>
|
||||
<button type="button" class="layui-btn layui-btn-primary close">返回上级</button>
|
||||
</div>
|
||||
</div>
|
||||
@ -90,63 +140,76 @@
|
||||
var wangEditorObj = {};
|
||||
var viewerObj = {};
|
||||
|
||||
|
||||
$(document).on('click','#search',function(){
|
||||
queryBasePopulationInfo($('#idCardNumber').val());
|
||||
});
|
||||
|
||||
function queryBasePopulationInfo(idCardNumber){
|
||||
if(!idCardNumber){
|
||||
top.dialog.msg('请输入身份证号进行查询');
|
||||
return false;
|
||||
}
|
||||
var loadIndex = layer.load(0);
|
||||
top.restAjax.get(top.restAjax.path('api/schoolkey/get-by-id-card-number/{idCardNumber}', [idCardNumber]),
|
||||
{}, null, function(code, data) {
|
||||
if(!data || !data.basePopulationInfoId) {
|
||||
top.dialog.msg('暂无此人,请先补充人员基本信息');
|
||||
var dataFormData = {};
|
||||
dataFormData['populationId'] = '';
|
||||
dataFormData['name'] = '';
|
||||
dataFormData['sex'] = '';
|
||||
dataFormData['cardNum'] = '';
|
||||
form.val('dataForm', dataFormData);
|
||||
form.render(null, 'dataForm');
|
||||
$('#submitBtn').addClass("layui-btn-disabled").attr("disabled", true);
|
||||
$('.div-base-population-info').hide();
|
||||
return false;
|
||||
}
|
||||
var dataFormData = {};
|
||||
for(var i in data) {
|
||||
dataFormData[i] = data[i] +'';
|
||||
}
|
||||
dataFormData['baseId'] = dataFormData['basePopulationInfoId'];
|
||||
dataFormData['name'] = dataFormData['fullName'];
|
||||
dataFormData['sex'] = dataFormData['genderDictionaryName'];
|
||||
dataFormData['cardNum'] = dataFormData['idCardNumber'];
|
||||
form.val('dataForm', dataFormData);
|
||||
form.render(null, 'dataForm');
|
||||
$('.div-base-population-info').show();
|
||||
}, function(code, data) {
|
||||
top.dialog.msg(data.msg);
|
||||
},function(){
|
||||
|
||||
},
|
||||
function () {
|
||||
layer.close(loadIndex);
|
||||
});
|
||||
}
|
||||
|
||||
// 危害程度change事件
|
||||
form.on('select(degreeOfHarm)', function(data){
|
||||
if(!data.value) {
|
||||
|
||||
}else {
|
||||
var valueArr = data.value.split(',');
|
||||
if(2 == valueArr.length) {
|
||||
var text = $('#degreeOfHarm option:selected').text();
|
||||
$('#degreeOfHarm option:selected').val(valueArr[0]);
|
||||
$('#degreeOfHarmName').val(text);
|
||||
$('#degreeOfHarmCode').val(valueArr[1]);
|
||||
}
|
||||
}
|
||||
form.render("select");
|
||||
});
|
||||
|
||||
function closeBox() {
|
||||
parent.layer.close(parent.layer.getFrameIndex(window.name));
|
||||
}
|
||||
|
||||
function refreshDownloadTemplet(fileName, file) {
|
||||
var dataRander = {};
|
||||
dataRander[fileName] = file;
|
||||
|
||||
laytpl(document.getElementById(fileName +'FileDownload').innerHTML).render(dataRander, function(html) {
|
||||
document.getElementById(fileName +'FileBox').innerHTML = html;
|
||||
});
|
||||
}
|
||||
|
||||
// 初始化文件列表
|
||||
function initFileList(fileName, ids, callback) {
|
||||
var dataForm = {};
|
||||
dataForm[fileName] = ids;
|
||||
form.val('dataForm', dataForm);
|
||||
|
||||
if(!ids) {
|
||||
refreshDownloadTemplet(fileName, []);
|
||||
if(callback) {
|
||||
callback(fileName, []);
|
||||
}
|
||||
return;
|
||||
}
|
||||
|
||||
top.restAjax.get(top.restAjax.path('api/file/list', []), {
|
||||
ids: ids
|
||||
}, null, function(code, data) {
|
||||
refreshDownloadTemplet(fileName, data);
|
||||
if(callback) {
|
||||
callback(fileName, data);
|
||||
}
|
||||
}, function(code, data) {
|
||||
top.dialog.msg(data.msg);
|
||||
});
|
||||
}
|
||||
|
||||
// 初始化视频
|
||||
function initVideo(fileName, data) {
|
||||
for(var i = 0, item; item = data[i++];) {
|
||||
var player = new ckplayer({
|
||||
container: '#'+ fileName + i,
|
||||
variable: 'player',
|
||||
flashplayer: false,
|
||||
video: {
|
||||
file: 'route/file/download/true/'+ item.fileId,
|
||||
type: 'video/mp4'
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
// 初始化危害程度字典表ID下拉选择
|
||||
function initDegreeOfHarmSelect(selectValue) {
|
||||
top.restAjax.get(top.restAjax.path('api/url/selectUrl', []), {}, null, function(code, data, args) {
|
||||
top.restAjax.get(top.restAjax.path('api/data/listbyparentid/{dataParentId}', ['ac006130-7403-40ef-b647-e89bb8cce631']), {}, null, function(code, data, args) {
|
||||
laytpl(document.getElementById('degreeOfHarmSelectTemplate').innerHTML).render(data, function(html) {
|
||||
document.getElementById('degreeOfHarmSelectTemplateBox').innerHTML = html;
|
||||
});
|
||||
@ -160,7 +223,6 @@
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
// 初始化内容
|
||||
function initData() {
|
||||
var loadLayerIndex;
|
||||
@ -171,7 +233,8 @@
|
||||
}
|
||||
form.val('dataForm', dataFormData);
|
||||
form.render(null, 'dataForm');
|
||||
initDegreeOfHarmSelect(data['degreeOfHarm']);
|
||||
initDegreeOfHarmSelect(data['degreeOfHarm'] + ',' + data['degreeOfHarmCode']);
|
||||
queryBasePopulationInfo(data['cardNum']);
|
||||
}, function(code, data) {
|
||||
top.dialog.msg(data.msg);
|
||||
}, function() {
|
||||
@ -180,10 +243,22 @@
|
||||
top.dialog.close(loadLayerIndex);
|
||||
});
|
||||
}
|
||||
|
||||
initData();
|
||||
|
||||
function changeFun(value, id, formData) {
|
||||
var valueArr = value.split(',');
|
||||
if(2 == valueArr.length) {
|
||||
var name = $('#' + id + 'option:selected').text();
|
||||
formData.field[id] = valueArr[0];
|
||||
$('#' + id + 'Name').val(name);
|
||||
$('#' + id + 'Code').val(valueArr[1]);
|
||||
}
|
||||
}
|
||||
|
||||
// 提交表单
|
||||
form.on('submit(submitForm)', function(formData) {
|
||||
changeFun(formData.field['degreeOfHarm'], 'degreeOfHarm', formData);
|
||||
top.dialog.confirm(top.dataMessage.commit, function(index) {
|
||||
top.dialog.close(index);
|
||||
var loadLayerIndex;
|
||||
@ -214,10 +289,6 @@
|
||||
$('.close').on('click', function() {
|
||||
closeBox();
|
||||
});
|
||||
|
||||
// 校验
|
||||
form.verify({
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
|
Loading…
Reference in New Issue
Block a user