| 
					
				 | 
			
			
				@@ -29,7 +29,7 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     <tbody> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     <tbody> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     <% if (ctx.session.sessionProject.page_show.openChangeProject) { %> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    <tr> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    <tr id="project"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         <td class="text-center">变更立项</td> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         <td><% if (changeProjectInfo) { %><%- changeProjectInfo.code %><% } %></td> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         <td><% if (changeProjectInfo) { %><%- changeProjectInfo.name %><% } %></td> 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -37,7 +37,7 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     </tr> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     <% } %> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     <% if (ctx.session.sessionProject.page_show.openChangeApply) { %> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    <tr> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    <tr id="apply"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         <td class="text-center">变更申请</td> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         <td><% if (changeApplyInfo) { %><%- changeApplyInfo.code %><% } %></td> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         <td><% if (changeApplyInfo) { %><%- changeApplyInfo.name %><% } %></td> 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -45,9 +45,9 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     </tr> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     <% } %> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     <% if (ctx.session.sessionProject.page_show.openChangePlan) { %> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    <tr> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    <tr id="plan"> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         <td class="text-center">变更方案</td> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        <td><% if (changePlanInfo) { %><%- changePlanInfo.code %><% } %></td> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        <td><% if (ctx.session.sessionUser.accountId === ctx.change.uid) { %><input id="plan_code" class="form-control form-control-sm" type="text" value="<% if (changePlanInfo) { %><%- changePlanInfo.code %><% } %>" data-name="plan_code" <% if (ctx.session.sessionUser.accountId !== change.uid) { %>readonly<% } %> placeholder="自动读取,没有就为空,可编辑"><% } else { %><% if (changePlanInfo) { %><%- changePlanInfo.code %><% } %><% } %></td> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         <td><% if (changePlanInfo) { %><%- changePlanInfo.name %><% } %></td> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                         <td class="text-center"><% if (changePlanInfo) { %><a target="_blank" href="/tender/<%- tender.id %>/change/plan/<%- changePlanInfo.id %>/information">查看详情</a><% } %></td> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     </tr> 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -60,4 +60,37 @@ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 </div> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 <script> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     autoFlashHeight(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <% if (ctx.session.sessionUser.accountId === ctx.change.uid) { %> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    $(function () { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        $('#plan input').change(function () { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            postData('/tender/' + window.location.pathname.split('/')[2] + '/change/' + window.location.pathname.split('/')[4] + '/information/save', { type: 'plan_code', plan_code: $(this).val() }, function (data) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                if (data.projectInfo) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    $('#project td').eq(1).text(data.projectInfo.code); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    $('#project td').eq(2).text(data.projectInfo.name); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    $('#project td').eq(3).html('<a target="_blank" href="/tender/' + window.location.pathname.split('/')[2] + '/change/project/' + data.projectInfo.id + '/information">查看详情</a>') 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    $('#project td').eq(1).text(''); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    $('#project td').eq(2).text(''); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    $('#project td').eq(3).html(''); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                if (data.applyInfo) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    $('#apply td').eq(1).text(data.applyInfo.code); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    $('#apply td').eq(2).text(data.applyInfo.name); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    $('#apply td').eq(3).html('<a target="_blank" href="/tender/' + window.location.pathname.split('/')[2] + '/change/apply/' + data.applyInfo.id + '/information">查看详情</a>') 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    $('#apply td').eq(1).text(''); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    $('#apply td').eq(2).text(''); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    $('#apply td').eq(3).html(''); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                if (data.planInfo) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    $('#plan td').eq(2).text(data.planInfo.name); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    $('#plan td').eq(3).html('<a target="_blank" href="/tender/' + window.location.pathname.split('/')[2] + '/change/plan/' + data.planInfo.id + '/information">查看详情</a>') 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    $('#plan td').eq(2).text(''); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    $('#plan td').eq(3).html(''); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            }); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        }); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    }); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    <% } %> 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 </script> 
			 |