Ver Código Fonte

专家用户信息地址字段

zzy.zhiyuan.foxmail 8 anos atrás
pai
commit
eaa5fcf2a4
1 arquivos alterados com 25 adições e 15 exclusões
  1. 25 15
      src/main/webapp/page/professor.html

+ 25 - 15
src/main/webapp/page/professor.html

100
							<input type="text" class="form-control" id="department" placeholder="部门">
100
							<input type="text" class="form-control" id="department" placeholder="部门">
101
						</div>
101
						</div>
102
					</div>
102
					</div>
103
					<div class="form-group">
104
						<label for="address" class="col-sm-2 control-label">住址</label>
105
						<div class="col-sm-10">
106
							<input type="text" class="form-control" id="address" placeholder="住址">
107
						</div>
108
					</div>
103
					<div class="col-sm-2"></div>
109
					<div class="col-sm-2"></div>
104
					<div class="col-sm-10">
110
					<div class="col-sm-10">
105
						<button id="saveProfessor" type="button" class="btn btn-default">保存</button>
111
						<button id="saveProfessor" type="button" class="btn btn-default">保存</button>
487
					</div>
493
					</div>
488
				</div>
494
				</div>
489
				<div class="modal-footer">
495
				<div class="modal-footer">
490
					
491
					<button  type="button" class="btn btn-default" id="closedd"data-dismiss="modal">关闭</button>
496
					<button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
492
					<button id="raSubmit" type="button" class="btn btn-primary">提交更改</button>
497
					<button id="raSubmit" type="button" class="btn btn-primary">提交更改</button>
493
				</div>
498
				</div>
494
			</div>
499
			</div>
669
							$("#department").val($info.department);
674
							$("#department").val($info.department);
670
							$("#subject").val($info.subject);
675
							$("#subject").val($info.subject);
671
							$("#industry").val($info.industry);
676
							$("#industry").val($info.industry);
677
							$("#address").val($info.address);
672
							$("#descp").val($info.descp);
678
							$("#descp").val($info.descp);
673
							$("#headImage").attr("src","/images/head/"+professorId+"_l.jpg");
679
							$("#headImage").attr("src","/images/head/"+professorId+"_l.jpg");
674
							$("#orgImage").attr("src","/images/org/"+$info.orgId+".jpg");
680
							$("#orgImage").attr("src","/images/org/"+$info.orgId+".jpg");
721
									}
727
									}
722
								});
728
								});
723
							});
729
							});
730
							$("#saveAddress").on("click",function(){
731
								$.ajax({"url" : "../ajax/professor/address",
732
									"type" : "POST",
733
									"data" : {"id":professorId,"address":$("#address").val()},
734
									"contentType" : "application/x-www-form-urlencoded",
735
									"success" : function($data) {
736
										if ($data.success) {
737
											alert("save address ok");
738
										} else {
739
											alert($data.msg);
740
										}
741
									}
742
								});
743
							});
724
							$("#saveDescp").on("click",function(){
744
							$("#saveDescp").on("click",function(){
725
								$.ajax({"url" : "../ajax/professor/descp",
745
								$.ajax({"url" : "../ajax/professor/descp",
726
									"type" : "POST",
746
									"type" : "POST",
739
								$.get("../ajax/researchArea/"+professorId,function($data){
759
								$.get("../ajax/researchArea/"+professorId,function($data){
740
									if($data.success){
760
									if($data.success){
741
										if($data.data){
761
										if($data.data){
742
										$('#raLists').empty();
743
											var $ras = $data.data;
762
											var $ras = $data.data;
744
											for(var i = 0 ; i < $ras.length;++i){
763
											for(var i = 0 ; i < $ras.length;++i){
745
												fillRA($ras[i].caption,$ras[i].descp);
764
												fillRA($ras[i].caption,$ras[i].descp);
746
											}
765
											}
747
											
748
										}
766
										}
749
									}else{
767
									}else{
750
										alert($data.msg);
768
										alert($data.msg);
758
								$("#raDescp").val("");
776
								$("#raDescp").val("");
759
								return false;
777
								return false;
760
							});
778
							});
761
							
762
							
763
							
764
							
765
							
766
							$("#raSubmit").on("click",function(){
779
							$("#raSubmit").on("click",function(){
767
								var $data=[];
780
								var $data=[];
768
								$("#raLists > li").each(function(){
781
								$("#raLists > li").each(function(){
790
								});
803
								});
791
								
804
								
792
							});
805
							});
793
							setInterval(function(){
794
							$(".raClose").on("click",function(){
806
							$(".raClose").on("click",function(){
795
								
807
								alert(111);
796
								$this=$(this);
808
								$this=$(this);
797
								$this.parent().remove();
809
								$this.parent().remove();
798
								return false;
810
								return false;
799
							})
800
							},1000);
801
							
802
							
811
							});
803
							$("#jobLabel").on("click",function(){
812
							$("#jobLabel").on("click",function(){
804
								$("#jobModal").data("pid", "");
813
								$("#jobModal").data("pid", "");
805
								$("#job_startMonth").val("");
814
								$("#job_startMonth").val("");
1237
				$data.orgName = $("#orgName").val();
1246
				$data.orgName = $("#orgName").val();
1238
				$data.title = $("#title").val();
1247
				$data.title = $("#title").val();
1239
				$data.department = $("#department").val();
1248
				$data.department = $("#department").val();
1249
				$data.address = $("#address").val();
1240
				if (professorId) {
1250
				if (professorId) {
1241
					$data.id = professorId;
1251
					$data.id = professorId;
1242
				}
1252
				}