Преглед на файлове

共享申请字段调整

hujie преди 1 година
родител
ревизия
ca08332801
променени са 1 файла, в които са добавени 48 реда и са изтрити 3 реда
  1. 48 3
      cn.com.taiji.system/src/main/resources/templates/thymeleaf/tshareapply/tshareapply_gxsq.html

+ 48 - 3
cn.com.taiji.system/src/main/resources/templates/thymeleaf/tshareapply/tshareapply_gxsq.html

@@ -149,14 +149,24 @@
                        		<input type="text" name="contacttel" id="contacttel" th:value="${dto.contacttel}" class="input-normal input-wdl"  datatype="dhhm" nullmsg="必填" sucmsg="&nbsp;" errormsg="请输入正确电话号码"/>
                        </td>
                     </tr>
-                    <tr>
+					<tr>
+						<th><font class="fontred">*</font>是否关联应用场景</th>
+						<td colspan="3">
+							<select name="sfglyycj" id="sfglyycj" class="input-select" datatype="*1-100" nullmsg="必填" sucmsg="&nbsp;" errormsg="必填">
+								<option value="" title="请选择">请选择</option>
+								<option title="是" value="是">是</option>
+								<option title="否" value="否">否</option>
+							</select>
+						</td>
+					</tr>
+                    <tr class="scene-info">
 						<th><font class="fontred">*</font>应用场景</th>
                        	<td colspan="3">
                         <input type="text" placeholder="点击选择应用场景" ignore="ignore" readonly="true" name="scenename"  id="scenename" class="input-normal input-wdl  " datatype="*1-400" nullmsg="必填" sucmsg="&nbsp;" errormsg="不超过400个字符"/>
                          <input type="hidden"  name="sceneid"  id="sceneid" />
                        </td>
                       </tr>
-                      <tr>
+                      <tr class="scene-info">
                     <th><font class="fontred">*</font>应用场景描述</th>
                       <td colspan="3">
                        		 <textarea style="width:98%;height:50px;resize: none;" name="cjDes" id="cjDes" th:text="${dto.cjDes}" class="input-normal input-wdl" datatype="*1-200" nullmsg="必填" sucmsg="&nbsp;" errormsg="不超过200个字符" value=""></textarea>
@@ -249,7 +259,42 @@
 </div>
 </form>
 <script th:inline="javascript">
-/*<![CDATA[*/ 
+/*<![CDATA[*/
+$(document).ready(function() {
+	$("#sfglyycj").bind("change",function(){
+		if ($("#sfglyycj").val() == "否") {
+			// 撤销值
+			document.getElementById("scenename").value = "";
+			document.getElementById("sceneid").value = "";
+			if(document.getElementById("cjDes")) {
+				document.getElementById("cjDes").value= "";
+			}
+			// 没这个字段,但是chooselist.js事件里面写到了
+			if(document.getElementById("workscenario")) {
+				document.getElementById("workscenario").value = "";
+			}
+			//字段隐藏
+			$(".scene-info").hide();
+		} else {
+			$(".scene-info").show();
+		}
+	})
+	var tempsceneid = $("#sceneid").val()
+	if (tempsceneid == null || tempsceneid == undefined || tempsceneid =="") {
+		$("#sfglyycj").val("否");
+	} else {
+		$("#sfglyycj").val("是");
+	}
+	$("#sfglyycj").change();
+
+	var tempywxtId = $("#ywxtId").val()
+	if (tempywxtId == null || tempywxtId == undefined || tempywxtId =="") {
+		$("#hasywxt").val("否");
+	} else {
+		$("#hasywxt").val("是");
+	}
+	$("#hasywxt").change();
+})
 	$("#ywxtName").bind("click",function(){
 			var dgurl="../systeminfo/systeminfo_choose_list";
 			var indexNum = layer.open({