addBT3.jsp 37 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877
  1. <%-- 补贴申请表12--外来务工人员--%>
  2. <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
  3. <style type="text/css">
  4. em {color:red;font-size:13px;font-style:normal}
  5. .changeLine th{
  6. white-space: NOWRAP;
  7. }
  8. </style>
  9. <script type="text/javascript">
  10. function addBT3_load(){
  11. //婚姻
  12. $("#maritalStatus_add").append(maritalStatus_array);
  13. $("#maritalStatus1").append(maritalStatus_array);
  14. $("#nationality1").append(nationality_array);
  15. $("#education1").append(education_array);
  16. //街办
  17. getStreetList("1",0,"street_add");
  18. $("#street_add").children('option').remove();
  19. $("#street_add").change(function(){
  20. $("#neighborhood_add").children('option').remove();
  21. getNeighborhoodList($("#street_add").val(),0,"neighborhood_add");
  22. $("#communityId_add").children('option').remove();
  23. $("#communityId_add").append("<option value=''>请选择</option>");
  24. });
  25. $("#neighborhood_add").change(function(){
  26. $("#communityId_add").children('option').remove();
  27. getCommunityList($("#neighborhood_add").val(),0,"communityId_add");
  28. $("#community_add").val("");
  29. });
  30. $("#communityId_add").change(function(){
  31. var community = $("#communityId_add").find("option:selected").text();
  32. $("#community_add").val(community);
  33. });
  34. }
  35. function addBT3_submit(){
  36. var flag= true;
  37. var flag1 = verifyCurrentHouseSituation();
  38. var flag2 = checkData();
  39. if($("#avgIncome_add").val()==""||$("#avgIncome_add").val()==null){
  40. countAvgIncome();
  41. flag = false;
  42. }
  43. if(flag1&&flag2&&flag){
  44. $.ajax({
  45. type: "POST",
  46. url:"securityPersonApply2Action_addSecurityPersonApply",
  47. data:$('#bt3Form').serialize(),// 你的formid
  48. async: false,
  49. error: function(data) {
  50. $.messager.alert("提示","提交失败");
  51. },
  52. success: function(result) {
  53. var parseResult = $.parseJSON(result);
  54. if(parseResult.success){
  55. $('#addBT3Dialog').dialog("close");
  56. var securityPersonApplyId = parseResult.obj.id;
  57. var fileNum = parseResult.obj.fileNum;
  58. for(var i=1;i<=index;i++){
  59. if($("#mbtb_" + i).length > 0 ){
  60. var url = whzl.basePath+'/securityPersonApply2Action_addSecurityPersonApplyRelative';
  61. $.ajax({
  62. type: "post",//使用post方法访问后台
  63. dataType: "json",//返回json格式的数据
  64. url: url,//要访问的后台地址
  65. async: false,
  66. data:{"securityPersonApplyRelative.securityPersonApplyId":securityPersonApplyId ,
  67. "securityPersonApplyRelative.fileNum":fileNum ,
  68. "securityPersonApplyRelative.name":$("#name" + i ).val() ,
  69. "securityPersonApplyRelative.relative":$("#relative" + i ).val() ,
  70. "securityPersonApplyRelative.idCard":$("#idCard" + i ).val() ,
  71. "securityPersonApplyRelative.maritalStatus":$("#maritalStatus" + i ).val() ,
  72. "securityPersonApplyRelative.maritalDate":$("#maritalDate" + i ).datebox('getValue') ,
  73. "securityPersonApplyRelative.company":$("#company" + i ).val() ,
  74. "securityPersonApplyRelative.residenceNo":$("#residenceNo" + i ).val() ,
  75. "securityPersonApplyRelative.wageIncome":$("#wageIncome" + i ).val() ,
  76. "securityPersonApplyRelative.operatingNetIncome":$("#operatingNetIncome" + i ).val() ,
  77. "securityPersonApplyRelative.propertyIncome":$("#propertyIncome" + i ).val() ,
  78. "securityPersonApplyRelative.otherIncome":$("#otherIncome" + i ).val() ,
  79. "securityPersonApplyRelative.otherIncomeRemark":$("#otherIncomeRemark" + i ).val() ,
  80. "securityPersonApplyRelative.securitiesTotal":$("#securitiesInfo_input" + i ).val() ,
  81. "securityPersonApplyRelative.bankTotal":$("#bankInfo_input" + i ).val() ,
  82. "securityPersonApplyRelative.isResidencePermit":$("input:radio[name='isResidencePermit_"+i+"']:checked").val(),
  83. "securityPersonApplyRelative.commercialInsurance":$("#commercialInsuranceInfo_input" + i ).val(),
  84. "securityPersonApplyRelative.phone":$("#phone" + i ).val(),
  85. "securityPersonApplyRelative.nationality":$("#nationality" + i ).val() ,
  86. "securityPersonApplyRelative.education":$("#education" + i ).val() ,
  87. "securityPersonApplyRelative.deathDate":$("#deathDate" + i ).datebox('getValue') ,
  88. },
  89. success : function(result){
  90. $.ajax({
  91. type: "post",//使用post方法访问后台
  92. dataType: "json",//返回json格式的数据
  93. url: whzl.basePath+'/securityPersonApply2Action_addAssets',//要访问的后台地址
  94. async: false,
  95. data:{"securityPersonApplyRelative.id":result.obj.id ,
  96. "cars":$("#carInfo_input"+i).val() ,
  97. "businesses": $("#businessInfo_input"+i).val() ,
  98. },
  99. });
  100. $("#securityPersonApplyDataGrid").datagrid("reload");
  101. }
  102. });
  103. }
  104. }
  105. }
  106. }
  107. })
  108. }
  109. }
  110. function checkData(){
  111. var flag= true;
  112. //姓名验证
  113. if($("#name_add").val()==''){
  114. $.messager.alert('提醒','请输入姓名');
  115. flag = false;
  116. }
  117. //身份证验证
  118. if($("#idCard_add").val()==''){
  119. $.messager.alert('提醒','请输入身份证号');
  120. flag = false;
  121. }else{
  122. if(!idCard1($("#idCard_add").val())){
  123. $.messager.alert('提醒','请检查输入的身份证号是否正确');
  124. flag = false;
  125. }
  126. }
  127. //婚姻状况验证
  128. if($("#maritalStatus_add").val()==''){
  129. $.messager.alert('提醒','请选择现婚姻状况');
  130. flag = false;
  131. }
  132. //手机号码验证
  133. if($("#phone_add").val()==''){
  134. $.messager.alert('提醒','请输入手机号码');
  135. flag = false;
  136. }
  137. if($("#accountLocation_add").val()==''){
  138. $.messager.alert('提醒','请输入户口所在地');
  139. flag = false;
  140. }
  141. if($("#neighborhood_add").val()==''){
  142. $.messager.alert('提醒','请选择居住地址');
  143. flag = false;
  144. }
  145. if($("#community_add").val()==''){
  146. $.messager.alert('提醒','请选择居住地社区');
  147. flag = false;
  148. }
  149. //单位名称
  150. if($("#company_add").val()==''){
  151. $.messager.alert('提醒','请输入单位名称');
  152. flag = false;
  153. }
  154. //验证家庭成员信息
  155. var isCar=2;
  156. var isBusiness=2;
  157. for(var i=1;i<=index;i++){
  158. var mbtb = $("#mbtb_"+i);
  159. //如果被删除,直接跳过
  160. if(mbtb.length > 0){
  161. var residenceNo=$("#residenceNo"+i).val()
  162. var idCard=$("#idCard"+i).val();
  163. var name=$("#name"+i).val();
  164. var relative=$("#relative"+i).val();
  165. var maritalStatus=$("#maritalStatus"+i).val();
  166. var wageIncome=$("#wageIncome"+i).val();
  167. var maritalDate = $("#maritalDate"+i).datebox('getValue');
  168. var phone=$("#phone"+i).val();
  169. var nationality=$("#nationality"+i).val();
  170. var education=$("#education"+i).val();
  171. var carInfo =$("#carInfo_input"+i).val();
  172. var businessesInfo =$("#businessInfo_input"+i).val();
  173. //户号
  174. if(residenceNo==''){
  175. $.messager.alert('提醒','请填户号');
  176. flag = false;
  177. }
  178. //验证姓名
  179. if(name==''){
  180. $.messager.alert('提醒','请填写姓名');
  181. flag = false;
  182. }
  183. //验证身份证号
  184. if(idCard!=''){
  185. if(!idCard1(idCard)){
  186. $.messager.alert('提醒','请填正确身份证号');
  187. flag = false;
  188. }
  189. }else{
  190. $.messager.alert('提醒','请填身份证号');
  191. flag = false;
  192. }
  193. //验证户籍关系
  194. if(relative==''){
  195. $.messager.alert('提醒','请填与申请人关系');
  196. flag = false;
  197. }
  198. //验证婚姻关系
  199. if(maritalStatus==''){
  200. $.messager.alert('提醒','请填婚姻状况');
  201. flag = false;
  202. }
  203. //除未成年、未婚都要填写登记时间
  204. if(maritalStatus !="6"&&maritalStatus !="5"){
  205. if(maritalDate ==''){
  206. $.messager.alert('提醒','请填婚姻登记日期');
  207. flag = false;
  208. }
  209. }
  210. //验证民族
  211. if(nationality==''){
  212. $.messager.alert('提醒','请选择民族');
  213. flag = false;
  214. }
  215. //验证文化
  216. if(education==''){
  217. $.messager.alert('提醒','请选择文化程度');
  218. flag = false;
  219. }
  220. //验证电话
  221. if(phone==''){
  222. $.messager.alert('提醒','请填联系电话');
  223. flag = false;
  224. }
  225. //验证是否有车与工商信息
  226. if(carInfo!=''){
  227. isCar = 1;
  228. }
  229. if(businessesInfo!=''){
  230. isBusiness = 1;
  231. }
  232. }
  233. }
  234. $("#isCar_add").val(isCar);
  235. $("#isBusiness_add").val(isBusiness);
  236. //家庭人口数量
  237. var mbtbNum = $(".mbtb > table").size();
  238. $("#familyNum_add").val(mbtbNum);
  239. return flag;
  240. }
  241. //计算人均收入
  242. function countAvgIncome(){
  243. var wageIncomeTotal = 0;
  244. var operatingNetIncomeTotal = 0;
  245. var propertyIncomeTotal = 0;
  246. var otherIncomeTotal = 0
  247. var avgIncome = 0;
  248. var avgArea = 0;
  249. var areaTotal = 0;
  250. var mbtbNum = $(".mbtb > table").size();
  251. for(var i=1;i<=index;i++){
  252. if($("#wageIncome"+i).val()==''||$("#wageIncome"+i).val()==undefined){
  253. $("#wageIncome"+i).val(0);
  254. }else{
  255. wageIncomeTotal+=parseInt($("#wageIncome"+i).val());
  256. }
  257. if($("#operatingNetIncome"+i).val()==''||$("#operatingNetIncome"+i).val()==undefined){
  258. $("#operatingNetIncome"+i).val(0);
  259. }else{
  260. operatingNetIncomeTotal+=parseInt($("#operatingNetIncome"+i).val());
  261. }
  262. if($("#propertyIncome"+i).val()==''||$("#propertyIncome"+i).val()==undefined){
  263. $("#propertyIncome"+i).val(0);
  264. }else{
  265. propertyIncomeTotal+=parseInt($("#propertyIncome"+i).val());
  266. }
  267. if($("#otherIncome"+i).val()==''||$("#otherIncome"+i).val()==undefined){
  268. $("#otherIncome"+i).val(0);
  269. }else{
  270. otherIncomeTotal+=parseInt($("#otherIncome"+i).val());
  271. }
  272. }
  273. avgIncome = Number((wageIncomeTotal+operatingNetIncomeTotal+propertyIncomeTotal+otherIncomeTotal)/mbtbNum).toFixed(2);
  274. $("#avgIncome_add").val(avgIncome);
  275. $("#avgIncome_span").text("家庭平均月收入=( "+wageIncomeTotal+"【工资收入】+"+operatingNetIncomeTotal+"【经营净收入】+"+propertyIncomeTotal+"【财产性收入】+"+otherIncomeTotal+"【其他收入】"+")/"+mbtbNum+"【人数】 = " + avgIncome + "元");
  276. }
  277. //验证家庭住房情况
  278. function verifyCurrentHouseSituation(){
  279. var flag = true;
  280. var currentHouseSituation=$('input:radio[name="securityPersonApply.currentHouseSituation"]:checked').val();
  281. var propertyCompany=$('#propertyCompany_add').val();
  282. if(typeof(propertyCompany)=="undefined" || propertyCompany == ''){
  283. $.messager.alert('提醒','请输入产权单位');
  284. flag = false;
  285. }
  286. var existArea=$('#existArea_add').val();
  287. if(typeof(existArea)=="undefined" || existArea == ''){
  288. $.messager.alert('提醒','请输房屋面积');
  289. flag = false;
  290. }
  291. var existReal=$('#existReal_add').val();
  292. if(typeof(existReal)=="undefined" || existReal == ''){
  293. $.messager.alert('提醒','请输房屋地址');
  294. flag = false;
  295. }
  296. return flag;
  297. }
  298. var index = 1;
  299. function addSecurityPersonApplyRelative(){
  300. index++;
  301. var $table = $("<table id='mbtb_"+index+"' class='mytable changeLine'></table>");
  302. var $tr1 = $("<tr style='border-top: 2px solid blue;'></tr>");
  303. var $th1_1 = $("<th width='11%'>户号</th>");
  304. var $td1_2 = $("<td width='20%'><input id='residenceNo"+index+"' type='text' style='width: 100px;'></td>");
  305. var $th1_3 = $("<th width='11%'>姓名</th>");
  306. var $td1_4 = $("<td width='24%'><input id='name"+index+"' type='text' style='width: 100px;'></td>");
  307. var $th1_5 = $("<th width='11%'>身份证号</th>");
  308. var $td1_6 = $("<td><input id='idCard"+index+"' type='text' style='width: 172px;'></td>");
  309. $tr1.append($th1_1);
  310. $tr1.append($td1_2);
  311. $tr1.append($th1_3);
  312. $tr1.append($td1_4);
  313. $tr1.append($th1_5);
  314. $tr1.append($td1_6);
  315. var $tr2 = $("<tr></tr>");
  316. var $th2_1 = $("<th>与申请人关系</th>");
  317. var $td2_2 = $("<td></td>");
  318. var $select_relative=$("<select id='relative" + index + "' style='width: 120px;'><option value=''>选择</option></select>")
  319. $select_relative.append(relative_array);
  320. $td2_2.append($select_relative);
  321. var $th2_3 = $("<th>婚姻状况</th>");
  322. var $td2_4 = $("<td></td>");
  323. var $select_maritalStatus=$("<select id='maritalStatus" + index + "' style='width: 120px;height: 20px;vertical-align: middle;'><option value=''>选择</option></select>")
  324. $select_maritalStatus.append(maritalStatus_array);
  325. var $maritalDate = $("<input type='text' style='width: 100px;' id='maritalDate" + index + "' class='easyui-datebox' editable='fasle'/>");
  326. $td2_4.append($select_maritalStatus);
  327. $td2_4.append($maritalDate);
  328. $.parser.parse($td2_4);
  329. var $th2_5 = $("<th>民族</th>");
  330. var $td2_6 = $("<td></td>");
  331. var $select_nationality=$("<select id='nationality" + index + "' style='width: 120px;'><option value=''>选择</option></select>")
  332. $select_nationality.append(nationality_array);
  333. $td2_6.append($select_nationality);
  334. $tr2.append($th2_1);
  335. $tr2.append($td2_2);
  336. $tr2.append($th2_3);
  337. $tr2.append($td2_4);
  338. $tr2.append($th2_5);
  339. $tr2.append($td2_6);
  340. var $tr3 = $("<tr></tr>");
  341. var $th3_1 = $("<th>联系电话</th>");
  342. var $td3_2 = $("<td><input id='phone"+index+"' type='text'/></td>");
  343. var $th3_3 = $("<th>工作单位</th>");
  344. var $td3_4 = $("<td><input id='company"+index+"' type='text'></td>");
  345. var $th3_5 = $("<th>文化程度</th>");
  346. var $td3_6 = $("<td></td>");
  347. var $select_education=$("<select id='education" + index + "' style='width: 120px;'><option value=''>选择</option></select>")
  348. $select_education.append(education_array);
  349. $td3_6.append($select_education);
  350. $tr3.append($th3_1);
  351. $tr3.append($td3_2);
  352. $tr3.append($th3_3);
  353. $tr3.append($td3_4);
  354. $tr3.append($th3_5);
  355. $tr3.append($td3_6);
  356. var $tr4 = $("<tr></tr>");
  357. var $th4_1 = $("<th>工薪收入(元/月)</th>");
  358. var $td4_2 = $("<td><input id='wageIncome"+index+"' type='text'></td>");
  359. var $th4_3 = $("<th>经营净收入(元/月)</th>");
  360. var $td4_4 = $("<td><input id='operatingNetIncome"+index+"' type='text'></td>");
  361. var $th4_5 = $("<th>财产性收入(元/月)</th>");
  362. var $td4_6 = $("<td><input id='propertyIncome"+index+"' type='text'></td>");
  363. $tr4.append($th4_1);
  364. $tr4.append($td4_2);
  365. $tr4.append($th4_3);
  366. $tr4.append($td4_4);
  367. $tr4.append($th4_5);
  368. $tr4.append($td4_6);
  369. var $tr5 = $("<tr></tr>");
  370. var $th5_1 = $("<th>其他收入(元/月)</th>");
  371. var $td5_2 = $("<td><input id='otherIncome"+index+"' type='text'></td>");
  372. var $th5_3 = $("<th>其他收入备注</th>");
  373. var $td5_4 = $("<td><input id='otherIncomeRemark"+index+"' type='text'></td>");
  374. var $th5_5 = $("<th>死亡注销日期</th>");
  375. var $td5_6 = $("<td></td>");
  376. var $deathDate = $("<input type='text' style='width: 100px;' id='deathDate" + index + "' class='easyui-datebox' editable='fasle'/>");
  377. $td5_6.append($deathDate);
  378. $.parser.parse($td5_6);
  379. $tr5.append($th5_1);
  380. $tr5.append($td5_2);
  381. $tr5.append($th5_3);
  382. $tr5.append($td5_4);
  383. $tr5.append($th5_5);
  384. $tr5.append($td5_6);
  385. var $tr6 = $("<tr></tr>");
  386. var $th6_1 = $("<th>是否持居住证</th>");
  387. var $td6_2 = $("<td>"+
  388. "<input value='1' type='radio' name='isResidencePermit_"+index+"' id='isResidencePermit_"+index+"-1' checked='checked' />"+
  389. "<label for='isResidencePermit_"+index+"-1' style='cursor: pointer;'>是&nbsp;</label>"+
  390. "<input value='2' type='radio' name='isResidencePermit_"+index+"' id='isResidencePermit_"+index+"-2' />"+
  391. "<label for='isResidencePermit_"+index+"-2' style='cursor: pointer;'>否&nbsp;</label>"+
  392. "</td>"
  393. );
  394. $tr6.append($th6_1);
  395. $tr6.append($td6_2);
  396. var $tr7 = $("<tr></tr>");
  397. var $th7_1 = $("<th>资产信息</th>");
  398. var $td7_2 = $("<td colspan='5'></td>");
  399. var $button1 =$("<input id='carInfo"+index+"' type='button' value='车辆信息' onclick='carInfo_add("+index+")' style='margin: 0 0 0 6px;'/>");
  400. var $button2 =$("<input id='businessInfo"+index+"' type='button' value='工商信息' onclick='businessInfo_add("+index+")' style='margin: 0 0 0 6px;'/>");
  401. var $button3 =$("<input id='securitiesInfo"+index+"' type='button' value='证券信息' onclick='securitiesInfo_add("+index+")' style='margin: 0 0 0 6px;'/>");
  402. var $button4 =$("<input id='bankInfo"+index+"' type='button' value='银行信息' onclick='bankInfo_add("+index+")' style='margin: 0 0 0 6px;'/>");
  403. var $button5 =$("<input id='commercialInsuranceInfo"+index+"' type='button' value='商业保险信息' onclick='commercialInsuranceInfo_add("+index+")' style='margin: 0 0 0 6px;'/>");
  404. var $img = $("<img align='right' src='images/remove.png' onclick=remove('mbtb_" + index + "')>");
  405. $td7_2.append($button1);
  406. $td7_2.append($button2);
  407. $td7_2.append($button3);
  408. $td7_2.append($button4);
  409. $td7_2.append($button5);
  410. $td7_2.append($img);
  411. $tr7.append($th7_1);
  412. $tr7.append($td7_2);
  413. var $tr8 = $("<tr id='tr"+index+"_8' style='display: none;'></tr>");
  414. var $th8_1 = $("<th>资产信息</th>");
  415. var $td8_2 = $("<td id='all_td"+index+"' colspan='5'></td>");
  416. var $carInfo_div = $("<div id='carInfo_span"+index+"'></div>");
  417. var $carInfo_input = $("<input id='carInfo_input"+index+"' type='hidden'/>");
  418. var $businessInfo_div = $("<div id='businessInfo_span"+index+"'></div>");
  419. var $businessInfo_input = $("<input id='businessInfo_input"+index+"' type='hidden'/>");
  420. var $securitiesInfo_span = $("<span id='securitiesInfo_span"+index+"'></span>");
  421. var $securitiesInfo_input = $("<input id='securitiesInfo_input"+index+"' type='hidden' value='0'/>");
  422. var $bankInfo_span = $("<span id='bankInfo_span"+index+"'></span>");
  423. var $bankInfo_input = $("<input id='bankInfo_input"+index+"' type='hidden' value='0'/>");
  424. var $commercialInsuranceInfo_span = $("<span id='commercialInsuranceInfo_span"+index+"'></span>");
  425. var $commercialInsuranceInfo_input = $("<input id='commercialInsuranceInfo_input"+index+"' type='hidden' value='0'/>");
  426. $td8_2.append($carInfo_div);
  427. $td8_2.append($businessInfo_div);
  428. $td8_2.append($carInfo_input);
  429. $td8_2.append($businessInfo_input);
  430. $td8_2.append($securitiesInfo_span);
  431. $td8_2.append($securitiesInfo_input);
  432. $td8_2.append($bankInfo_span);
  433. $td8_2.append($bankInfo_input);
  434. $td8_2.append($commercialInsuranceInfo_span);
  435. $td8_2.append($commercialInsuranceInfo_input);
  436. $tr8.append($th8_1);
  437. $tr8.append($td8_2);
  438. $table.append($tr1);
  439. $table.append($tr2);
  440. $table.append($tr3);
  441. $table.append($tr4);
  442. $table.append($tr5);
  443. $table.append($tr6);
  444. $table.append($tr7);
  445. $table.append($tr8);
  446. $("#mbtb_1").after($table);
  447. }
  448. //删除家庭成员表格
  449. function remove(id){
  450. $("#" + id).remove();
  451. }
  452. function carInfo_add(index){
  453. $("#addAssetsInfoDialog").dialog({
  454. buttons:[{
  455. text:"确认",
  456. iconCls : 'icon-ok',
  457. handler : function(){
  458. $("#car_id").val(index)
  459. var id = "car_index_" + (new Date()).valueOf();
  460. var indexCar = $("#car_id").val();
  461. var vehicleBrand = "车辆品牌:" + $("#vehicleBrand1").val();
  462. var vehicleModel = "车辆型号:" + $("#vehicleModel1").val();
  463. var buyFirstTime = "初次购买日期:" + $("#buyFirstTime1").datebox("getValue");
  464. var estimatePrice = "车辆价值(元):" + $("#estimatePrice1").val();
  465. if($("#estimatePrice1").val()==''){
  466. $.messager.alert('提醒','请输入车辆价值');
  467. return ;
  468. }
  469. var spanText = vehicleBrand + "," + vehicleModel + "," + buyFirstTime + "," + estimatePrice;
  470. var delBtn = "<img src='images/i_de.png' style='float:left; margin-left:10px;cursor:pointer' onclick=delCar('"+id+"','"+spanText+"','"+indexCar+"')>";
  471. var html = "<div id='"+id+"' style='height:20px;'><span style='float:left;'>"+spanText+"</span>"+ delBtn + "</div>";
  472. var pText = $('#carInfo_span'+indexCar).html();
  473. $("#carInfo_span"+indexCar).html(pText + html);
  474. var cars_hidden_text_id = '#carInfo_input' + indexCar;
  475. $(cars_hidden_text_id).val($(cars_hidden_text_id).val() + "###" + spanText);
  476. $("#tr"+index+"_8").show();
  477. $("#addAssetsInfoDialog").dialog("close");
  478. }
  479. },{
  480. text:"取消",
  481. iconCls : 'icon-cancel',
  482. handler : function(){
  483. $("#addAssetsInfoDialog").dialog("close");
  484. }
  485. }],
  486. onLoad : function(){
  487. $("#carInfo_tb").show();
  488. }
  489. })
  490. }
  491. function delCar(id,spanText,indexCar){
  492. //删除该车辆
  493. $("#"+id).remove();
  494. //删除车辆信息
  495. $("#carInfo_input"+indexCar).val($("#carInfo_input"+indexCar).val().replace('###'+spanText,''));
  496. }
  497. function businessInfo_add(index){
  498. $("#addAssetsInfoDialog").dialog({
  499. buttons:[{
  500. text:"确认",
  501. iconCls : 'icon-ok',
  502. handler : function(){
  503. $("#business_id").val(index)
  504. var id = "business_index_" + (new Date()).valueOf();
  505. var indexbusiness = $("#business_id").val();
  506. var businessName = "企业名称:" + $("#businessName1").val();
  507. var businessAddress = "地址:" + $("#businessAddress1").val();
  508. var shareholderName = "股东名称:" + $("#shareholderName1").val();;
  509. var investmentAmount = "出资金额:" + $("#investmentAmount1").val();
  510. var spanText = businessName + "," + businessAddress + "," + shareholderName + "," + investmentAmount;
  511. var delBtn = "<img src='images/i_de.png' style='float:left; margin-left:10px;cursor:pointer' onclick=delBusiness('"+id+"','"+spanText+"','"+indexbusiness+"')>";
  512. var html = "<div id='"+id+"' style='height:20px;'><span style='float:left;'>"+spanText+"</span>"+ delBtn + "</div>";
  513. var pText = $('#businessInfo_span'+indexbusiness).html();
  514. $("#businessInfo_span"+indexbusiness).html(pText + html);
  515. var businesss_hidden_text_id = '#businessInfo_input' + indexbusiness;
  516. $(businesss_hidden_text_id).val($(businesss_hidden_text_id).val() + "###" + spanText);
  517. $("#tr"+index+"_8").show();
  518. $("#addAssetsInfoDialog").dialog("close");
  519. }
  520. },{
  521. text:"取消",
  522. iconCls : 'icon-cancel',
  523. handler : function(){
  524. $("#addAssetsInfoDialog").dialog("close");
  525. }
  526. }],
  527. onLoad : function(){
  528. $("#businessInfo_tb").show();
  529. }
  530. })
  531. }
  532. function delBusiness(id,spanText,indexBusiness){
  533. //删除该车辆
  534. $("#"+id).remove();
  535. //删除车辆信息
  536. $("#businessInfo_input"+indexBusiness).val($("#businessInfo_input"+indexBusiness).val().replace('###'+spanText,''));
  537. }
  538. //股票信息添加
  539. function securitiesInfo_add(index){
  540. $("#addAssetsInfoDialog").dialog({
  541. buttons:[{
  542. text:"确认",
  543. iconCls : 'icon-ok',
  544. handler : function(){
  545. $("#addAssetsInfoDialog").dialog("close");
  546. var securitiesTotal=$("#securitiesTotal1").val()
  547. $("#securitiesInfo_span"+index).html("证券总额为:"+securitiesTotal+"</br>");
  548. $("#securitiesInfo_input"+index).val(securitiesTotal);
  549. $("#tr"+index+"_8").show();
  550. }
  551. },{
  552. text:"取消",
  553. iconCls : 'icon-cancel',
  554. handler : function(){
  555. $("#addAssetsInfoDialog").dialog("close");
  556. }
  557. }],
  558. onLoad : function(){
  559. $("#securitiesInfo_tb").show();
  560. }
  561. })
  562. }
  563. //银行存款信息添加
  564. function bankInfo_add(index){
  565. $("#addAssetsInfoDialog").dialog({
  566. buttons:[{
  567. text:"确认",
  568. iconCls : 'icon-ok',
  569. handler : function(){
  570. $("#addAssetsInfoDialog").dialog("close");
  571. var bankTotal=$("#bankTotal1").val()
  572. $("#bankInfo_span"+index).html("银行存款总额为:"+bankTotal+"</br>");
  573. $("#bankInfo_input"+index).val(bankTotal);
  574. $("#tr"+index+"_8").show();
  575. }
  576. },{
  577. text:"取消",
  578. iconCls : 'icon-cancel',
  579. handler : function(){
  580. $("#addAssetsInfoDialog").dialog("close");
  581. }
  582. }],
  583. onLoad : function(){
  584. $("#bankInfo_tb").show();
  585. }
  586. })
  587. }
  588. //商业保险添加
  589. function commercialInsuranceInfo_add(index){
  590. $("#addAssetsInfoDialog").dialog({
  591. buttons:[{
  592. text:"确认",
  593. iconCls : 'icon-ok',
  594. handler : function(){
  595. $("#addAssetsInfoDialog").dialog("close");
  596. var commercialInsuranceInfo=$("#commercialInsuranceTotal1").val();
  597. $("#commercialInsuranceInfo_span"+index).html("商业保险总额为:"+commercialInsuranceInfo+"</br>");
  598. $("#commercialInsuranceInfo_input"+index).val(commercialInsuranceInfo);
  599. $("#tr"+index+"_8").show();
  600. }
  601. },{
  602. text:"取消",
  603. iconCls : 'icon-cancel',
  604. handler : function(){
  605. $("#addAssetsInfoDialog").dialog("close");
  606. }
  607. }],
  608. onLoad : function(){
  609. $("#commercialInsuranceInfo_tb").show();
  610. }
  611. })
  612. }
  613. </script>
  614. <form id="bt3Form" action="securityPersonApplyAction_addSecurityPersonApply" method="post" >
  615. <input type="hidden" id="familyNum_add" name="securityPersonApply.familyNum"/>
  616. <input type="hidden" id="addType_add" name="securityPersonApply.addType" value="1"/>
  617. <input type="hidden" id="flow_add" name="securityPersonApply.flow" value="1"/>
  618. <input type="hidden" id="type_add" name="securityPersonApply.type" value="12"/>
  619. <input type="hidden" name="securityPersonApply.isCar" id="isCar_add" value="2"/>
  620. <input type="hidden" name="securityPersonApply.isBusiness" id="isBusiness_add" value="2"/>
  621. <table id="securityPersonInfo" class="mytable">
  622. <tr>
  623. <th colspan="4"><span style="font-weight: bolder;">淮安市市区公租房租赁补贴--外来务工人员</span></th>
  624. </tr>
  625. <tr>
  626. <th colspan="4">申请人基本信息</th>
  627. </tr>
  628. <tr>
  629. <th width="11%"><em>*</em>申请人姓名</th>
  630. <td width="38%"><input type="text" name="securityPersonApply.securityPersonName" id="name_add"/></td>
  631. <th width="11%"><em>*</em>身份证号码</th>
  632. <td><input type="text" name="securityPersonApply.securityPersonIdCard" id="idCard_add" onchange="check(this.value)"/></td>
  633. </tr>
  634. <tr>
  635. <th><em>*</em>现婚姻状况</th>
  636. <td>
  637. <select name="securityPersonApply.maritalStatus" id="maritalStatus_add" style="width:172px">
  638. <option value="">请选择</option>
  639. </select>
  640. </td>
  641. <th><em>*</em>手机号码</th>
  642. <td><input type="text" name="securityPersonApply.phone" id="phone_add"/></td>
  643. </tr>
  644. <tr>
  645. <th><em>*</em>居住地址</th>
  646. <td>
  647. <select id="street_add" style="width: 80px">
  648. <option value="">请选择</option>
  649. </select>
  650. <select id="neighborhood_add" name="securityPersonApply.houseRegister.id" style="width: 130px">
  651. <option value="">请选择</option>
  652. </select>
  653. <select id="communityId_add" name="securityPersonApply.communityId" style="width: 100px">
  654. <option value="">请选择</option>
  655. </select>
  656. <input type="hidden" id="community_add" name="securityPersonApply.community"/>
  657. </td>
  658. <th><em>*</em>户口所在地</th>
  659. <td>
  660. <input type="text" id="accountLocation_add" style="width: 400px;" name="securityPersonApply.accountLocation"/>
  661. </td>
  662. </tr>
  663. <tr>
  664. <th><em>*</em>工作单位名称</th>
  665. <td><input type="text" id="company_add" name="securityPersonApply.company"/></td>
  666. <th><em>*</em>工作单位地址</th>
  667. <td><input type="text" id="workPlace_add" name="securityPersonApply.workPlace"/></td>
  668. </tr>
  669. <tr>
  670. <th><em>*</em><span>社保连续交纳是否满两年</span></th>
  671. <td>
  672. <input value="1" type="radio" name="securityPersonApply.pension" id="pension-1">
  673. <label for="pension-1" style="cursor: pointer;">是&nbsp;</label>
  674. <input value="2" type="radio" name="securityPersonApply.pension" id="pension-2">
  675. <label for="pension-2" style="cursor: pointer;">否&nbsp;</label>
  676. </td>
  677. <th><em>*</em>缴纳时间</th>
  678. <td>
  679. <input type="text" id="pensionDate_add" name="securityPersonApply.pensionDate" class="easyui-datebox"/>至
  680. <input type="text" id="pensionEndDate_add" name="securityPersonApply.pensionEndDate" class="easyui-datebox"/>
  681. </td>
  682. </tr>
  683. <tr>
  684. <th><em>*</em><span>是否签订劳动合同(聘用合同)</span></th>
  685. <td>
  686. <input value="1" type="radio" name="securityPersonApply.laborContract" id="laborContract-1">
  687. <label for="laborContract-1" style="cursor: pointer;">是&nbsp;</label>
  688. <input value="2" type="radio" name="securityPersonApply.laborContract" id="laborContract-2">
  689. <label for="laborContract-2" style="cursor: pointer;">否&nbsp;</label>
  690. </td>
  691. </tr>
  692. </table>
  693. <div id="mbtb_div" class="mbtb">
  694. <table class="mytable changeLine" id="mbtb_1">
  695. <tr>
  696. <th colspan="8">家庭成员基本信息
  697. <input id="" type="button" value="新增家庭成员" onclick="addSecurityPersonApplyRelative();" style="margin-left: 30px"/>
  698. <input type="button" value="计算家庭平均收入" onclick="countAvgIncome()"/>
  699. <span id="avgIncome_span"></span>
  700. <input id="avgIncome_add" name="securityPersonApply.avgIncome" type="hidden"/>
  701. </th>
  702. </tr>
  703. <tr style="border-top: 2px solid blue;">
  704. <th width="11%">户号</th>
  705. <td width="20%"><input id='residenceNo1' type='text' style="width: 100px;"></td>
  706. <th width="11%">姓名</th>
  707. <td width="24%"><input id='name1' type='text' style="width: 100px;"></td>
  708. <th width="11%">身份证号码</th>
  709. <td width="23%"><input id='idCard1' type='text' style="width: 172px;"></td>
  710. </tr>
  711. <tr>
  712. <th>与申请人关系</th>
  713. <td>
  714. <select id='relative1' style='width: 120px;'>
  715. <option value='0'>申请人</option>
  716. </select>
  717. </td>
  718. <th>婚姻状况</th>
  719. <td>
  720. <select id='maritalStatus1' style='width: 120px;height: 20px;vertical-align: middle;'>
  721. <option value=''>选择</option>
  722. </select>
  723. <input type="text" style="width: 100px;" id='maritalDate1' class="easyui-datebox" editable="fasle"/>
  724. </td>
  725. <th>民族</th>
  726. <td>
  727. <select id='nationality1' style='width: 120px;'>
  728. <option value=''>选择</option>
  729. </select>
  730. </td>
  731. </tr>
  732. <tr>
  733. <th>联系电话</th>
  734. <td><input id="phone1"/></td>
  735. <th>工作单位</th>
  736. <td><input id='company1' type='text' style="width: 172px;"></td>
  737. <th>文化程度</th>
  738. <td>
  739. <select id='education1' style='width: 120px;'>
  740. <option value=''>选择</option>
  741. </select>
  742. </td>
  743. </tr>
  744. <tr>
  745. <th>工薪收入(元/月)</th>
  746. <td><input id="wageIncome1" /></td>
  747. <th>经营净收入(元/月)</th>
  748. <td><input id="operatingNetIncome1" /></td>
  749. <th>财产性收入(元/月)</th>
  750. <td><input id="propertyIncome1" /></td>
  751. </tr>
  752. <tr>
  753. <th>其他收入(元/月)</th>
  754. <td><input id="otherIncome1" /></td>
  755. <th>其他收入备注</th>
  756. <td><input id="otherIncomeRemark1" /></td>
  757. <th>死亡注销日期</th>
  758. <td><input id='deathDate1' class="easyui-datebox" editable="fasle"/></td>
  759. </tr>
  760. <tr>
  761. <th>是否持居住证</th>
  762. <td>
  763. <input value="1" type="radio" name="isResidencePermit_1" id="isResidencePermit_1-1" checked="checked">
  764. <label for="isResidencePermit_1-1" style="cursor: pointer;">是&nbsp;</label>
  765. <input value="2" type="radio" name="isResidencePermit_1" id="isResidencePermit_1-2">
  766. <label for="isResidencePermit_1-2" style="cursor: pointer;">否&nbsp;</label>
  767. </td>
  768. </tr>
  769. <tr>
  770. <th>资产信息</th>
  771. <td colspan="5">
  772. <input id="carInfo1" type="button" value="车辆信息" onclick="carInfo_add(1)"/>
  773. <input id="businessInfo1" type="button" value="工商信息" onclick="businessInfo_add(1)"/>
  774. <input id="securitiesInfo1" type="button" value="证券信息" onclick="securitiesInfo_add(1)"/>
  775. <input id="bankInfo1" type="button" value="银行信息" onclick="bankInfo_add(1)"/>
  776. <input id="commercialInsuranceInfo1" type="button" value="商业保险信息" onclick="commercialInsuranceInfo_add(1)"/>
  777. </td>
  778. </tr>
  779. <tr id="tr1_8" style="display: none;">
  780. <th>资产信息</th>
  781. <td id="all_td1" colspan="5">
  782. <!-- 车辆 -->
  783. <div id="carInfo_span1"></div>
  784. <input id="carInfo_input1" type="hidden"/>
  785. <!-- 工商 -->
  786. <div id="businessInfo_span1"></div>
  787. <input id="businessInfo_input1" type="hidden"/>
  788. <!-- 证券 -->
  789. <span id="securitiesInfo_span1"></span>
  790. <input id="securitiesInfo_input1" name="securityPersonApplyRelative.securitiesTotal" type="hidden" value="0"/>
  791. <!-- 银行 -->
  792. <span id="bankInfo_span1"></span>
  793. <input id="bankInfo_input1" name="securityPersonApplyRelative.bankTotal" type="hidden" value="0"/>
  794. <!-- 商业保险 -->
  795. <span id="commercialInsuranceInfo_span1"></span>
  796. <input id="commercialInsuranceInfo_input1" name="securityPersonApplyRelative.commercialInsurance" type="hidden" value="0"/>
  797. </td>
  798. </tr>
  799. </table></div>
  800. <table class="mytable">
  801. <tr>
  802. <th colspan="2">现住房信息</th>
  803. </tr>
  804. <tr>
  805. <th width="20%"><em>*</em>家庭住房困难类型:</th>
  806. <td>
  807. <input value="1" type="radio" name="securityPersonApply.currentHouseSituation" id="currentHouseSituation-1">
  808. <label for="currentHouseSituation-1" style="cursor: pointer;">自有房产&nbsp;</label>
  809. <input value="2" type="radio" name="securityPersonApply.currentHouseSituation" id="currentHouseSituation-2">
  810. <label for="currentHouseSituation-2" style="cursor: pointer;">租住私房&nbsp;</label>
  811. <input value="3" type="radio" name="securityPersonApply.currentHouseSituation" id="currentHouseSituation-3">
  812. <label for="currentHouseSituation-3" style="cursor: pointer;">借住私房&nbsp;</label>
  813. <input value="4" type="radio" name="securityPersonApply.currentHouseSituation" id="currentHouseSituation-4">
  814. <label for="currentHouseSituation-4" style="cursor: pointer;">租住公房&nbsp;</label></br>
  815. <span style="color:#000;">房屋坐落:</span><input id="existReal_add" name="securityPersonApply.existReal" type="text" class="form-control" style="width: 300px;display: inline;"/>
  816. <span style="color:#000;">,面积:</span><input id="existArea_add" name="securityPersonApply.existArea" type="text" class="form-control" style="width: 100px;display: inline;"/>
  817. <span style="color:#000;">平方米,产权人:</span><input type="text" id="propertyCompany_add" name="securityPersonApply.propertyCompany" style="width: 100px;display: inline;">
  818. </td>
  819. </tr>
  820. <tr>
  821. <th>是否存在转让房产、取得拆迁安置补偿不满两年的情况:</th>
  822. <td>
  823. <input value="1" type="radio" name="securityPersonApply.isAssignmentHouse" id="isAssignmentHouse-1" />
  824. <label for="isAssignmentHouse-1" style="cursor: pointer;">是&nbsp;</label>
  825. <input value="2" type="radio"name="securityPersonApply.isAssignmentHouse" checked="checked" id="isAssignmentHouse-2" />
  826. <label for="isAssignmentHouse-2" style="cursor: pointer;">否&nbsp;</label>
  827. </td>
  828. </tr>
  829. <tr>
  830. <th>申请之日前两年是否享受过房改房、政策性商品房或其他住房保障政策:</th>
  831. <td>
  832. <input value="1" type="radio" name="securityPersonApply.hasUsed" id="hasUsed-1" />
  833. <label for="hasUsed-1" style="cursor: pointer;">是&nbsp;</label>
  834. <input value="2" type="radio"name="securityPersonApply.hasUsed" id="hasUsed-2" />
  835. <label for="hasUsed-2" style="cursor: pointer;">否&nbsp;</label>
  836. </td>
  837. </tr>
  838. </table>
  839. </form>