<!doctype html>
|
<html class="no-js">
|
<head>
|
<meta charset="utf-8">
|
<title>事件基本信息</title>
|
</head>
|
|
<body>
|
[#include "/business/pages/include/static.html" /]
|
[#include "/component/newupload.html" /]
|
[#include "/component/DatePicker.html" /]
|
[#include "/component/newsel.html" /]
|
|
<script type="text/javascript">
|
$(document).ready(function() {
|
$.formValidator.initConfig({formID:"myform",onError:function(msg){window.top.popupTips(msg)},onSuccess:function(){
|
|
return true;
|
}});
|
|
$("#name").formValidator({empty: false, onShow:"请输入问题名称!",onFocus: "请输入问题名称"}).inputValidator({min: 1,max:100, onError: "问题名称为1到50个汉字"});
|
$("#descrip").formValidator({empty: false, onShow:"请输入问题内容!",onFocus: "请输入问题内容"}).inputValidator({min: 1,onError: "问题内容不能为空"});
|
$("#customer_id").formValidator({empty: false, onShow:"请选择${Constants.CUSTOMER_CONSTANTS}!",onFocus: "请选择${Constants.CUSTOMER_CONSTANTS}"}).inputValidator({min: 1,onError: "${Constants.CUSTOMER_CONSTANTS}不能为空"});
|
$("#contact_name").formValidator({empty: false, onShow:"请输入联系人!",onFocus: "联系人不能为空"}).inputValidator({min: 1,max:100,onError: "联系人为1到100个字符"});
|
$("#contact_phone").formValidator({empty:false,onShow:"请输入联系方式!",onFocus:"联系方式不能为空!"}).functionValidator({fun:checkPhone});
|
$("#source_id").formValidator({empty: false, onShow:"请选择问题来源!",onFocus: "问题来源不能为空"}).inputValidator({min: 1,onError: "问题来源不能为空"});
|
$("#want_deal_time").formValidator({empty: false, onShow:"请选择期望完成时间!",onFocus: "期望完成时间不能为空"}).inputValidator({min: 1,onError: "期望完成时间不能为空"});
|
$("#serivceListId").formValidator({empty: false, onShow:"请选择服务目录!",onFocus: "服务目录不能为空"}).inputValidator({min: 1,onError: "服务目录不能为空"});
|
$("#priority_id").formValidator({empty: false, onShow:"请选择优先级!",onFocus: "优先级不能为空"}).inputValidator({min: 1,onError: "优先级不能为空"});
|
$("#influence_id").formValidator({empty: false, onShow:"请选择影响度!",onFocus: "影响度不能为空"}).inputValidator({min: 1,onError: "影响度不能为空"});
|
$("#repeat_order").formValidator({empty: false, onShow:"请选择重复工单!",onFocus: "重复工单不能为空"}).inputValidator({min: 1,onError: "重复工单不能为空"});
|
$("#slaId").formValidator({empty: false}).inputValidator({min: 1,onError: "服务等级不能为空"});
|
});
|
function checkPhone(value) {
|
if($.util.isEmpty(value)) {
|
return "联系方式不能为空";
|
}
|
if(!$.util.isMobile(value) && !$.util.isTelphone(value)) {
|
return "联系方式格式不正确";
|
}
|
return true;
|
}
|
</script>
|
|
<div class="deal_switch_con" style="display:block;">
|
<div class="deal_record_tittle"><a id="save">保存</a></div>
|
<div class="fsm_left" id="fsmLeft">
|
<div class="edit_title"><h3>基本信息</h3></div>
|
[#if question?? && question?size>0]
|
<form id="myform" action="${base}/business/pages/question/editQuestion.html" method="post">
|
<input type="hidden" value="${question.ID}" name="id">
|
<input type="hidden" value="${RequestParameters.flowId}" name="flowId">
|
<table class="edit_layout2">
|
<tr>
|
<th><label>问题名称:</label></th>
|
<td colspan="3">
|
<input class="general maintitle" type="text" id="name" name="name" value="${question.NAME}" style="width:80%;"/>
|
<div id="nameTip" style="display:inline-block;"></div>
|
</td>
|
</tr>
|
<tr>
|
<th class="postop"><label class="required">问题描述:</label></th>
|
<td colspan="3"><textarea class="general" id="descrip" name="descrip" style="width:80%;">${question.DESCRIP}</textarea>
|
<div id="descripTip" style="display:inline-block;"></div>
|
</td>
|
</tr>
|
<tr>
|
<th><label class="required">${Constants.CUSTOMER_CONSTANTS}名称:</label></th>
|
<td>
|
${question.CUSTOMER_NAME}
|
<input type="hidden" id="customer_id" name="customer_id" value="${question.CUSTOMER_ID}"/>
|
<input type="hidden" id="customer_name" name="customer_name" value="${question.CUSTOMER_NAME}"/>
|
</td>
|
<th><label>${Constants.UNIT_CONSTANTS}:</label></th>
|
<td>
|
${question.SUB_CUSTOMER_NAME}
|
</td>
|
</tr>
|
<tr>
|
<th><label class="required">${Constants.CUSTOMER_CONSTANTS}联系人:</label></th>
|
<td>
|
<input class="general" type="text" name="contact_name" id="contact_name" value="${question.CONTACT_NAME}"/>
|
<div id="contact_nameTip" style="display:inline-block;"></div>
|
</td>
|
</tr>
|
<tr>
|
<th><label>联系方式:</label></th>
|
<td>
|
<input class="general" type="text" name="contact_phone" id="contact_phone" value="${question.CONTACT_PHONE}"/>
|
<div id="contact_phoneTip" style="display:inline-block;"></div>
|
</td>
|
<th><label >业务科室:</label></th>
|
<td>
|
<input class="general" type="text" name="keshi" id="keshi" value="${question.KESHI}" />
|
</td>
|
|
</tr>
|
<tr>
|
<th><label>问题来源:</label></th>
|
<td>
|
[@sel id="source_id" name="source_id" source=froms textField="DATAKEY" valueField="DATAVALUE" labelName="source_name" value="${question.SOURCE_ID}" text="${question.SOURCE_NAME}"/]
|
|
<div id="source_idTip" style="display:inline-block;"></div>
|
</td>
|
<th><label>服务目录:</label></th>
|
<td>
|
${question.FIRST_CATEGORY_NAME}-${question.SECOND_CATEGORY_NAME}-${question.THIRD_CATEGORY_NAME}
|
<input type="hidden" id="serivceList" name="serivceList" value="${question.FIRST_CATEGORY_NAME}-${question.SECOND_CATEGORY_NAME}-${question.THIRD_CATEGORY_NAME}"/>
|
<input type="hidden" id="serivceListId" name="serivceListId" value="${question.FIRST_CATEGORY_ID}-${question.SECOND_CATEGORY_ID}-${question.THIRD_CATEGORY_ID}"/>
|
</td>
|
</tr>
|
<tr>
|
<th><label>期望完成时间:</label></th>
|
<td>
|
[@datepicker id="want_deal_time" value="" class="general" minDate=question.WANT_DEAL_TIME length=8 value=question.WANT_DEAL_TIME /]<div id="want_deal_timeTip" style="display:inline-block;"></div>
|
</td>
|
</tr>
|
<tr>
|
<th><label>优先级:</label></th>
|
<td>
|
[@sel id="priority_id" name="priority_id" source=eventPri textField="DATAKEY" valueField="DATAVALUE" labelName="priority_name" value="${question.PRIORITY_ID}" text="${question.PRIORITY_NAME}" callback="queryLevel"/]
|
<div id="priority_idTip" style="display:inline-block;"></div>
|
</td>
|
<th><label class="required">影响度:</label></th>
|
<td>
|
[@sel id="influence_id" name="influence_id" source=eventDg textField="DATAKEY" valueField="DATAVALUE" labelName="influence_name" value="${question.INFLUENCE_ID}" text="${question.INFLUENCE_NAME}" callback="queryLevel"/]
|
<div id="influence_idTip" style="display:inline-block;"></div>
|
</td>
|
</tr>
|
<tr id="level" style="display:none;">
|
<input type="hidden" id="slaId" name="sla_id" value="${question.PRI_LEVEL_ID}"/>
|
<input type="hidden" id="slaName" name="sla_name" value="${question.PRI_LEVEL}"/>
|
<th><label class="required">优先级等级:</label></th>
|
<td colspan="3" class="scores_con">
|
<h4 id="levelName">${question.PRI_LEVEL}</h4>
|
<div id="slaIdTip" style="display:inline-block;"></div>
|
</td>
|
</tr>
|
</table>
|
</form>
|
[/#if]
|
</div>
|
</div>
|
|
|
<script type="text/javascript">
|
function subCus() {
|
var customer_id = $("#customer_id").val();
|
if($.util.isEmpty(customer_id)) {
|
popupTips("请先选择${Constants.CUSTOMER_CONSTANTS}");
|
return;
|
}
|
|
var sub_customer_id = $("#sub_customer_id").val();
|
|
var url = "${base}/business/pages/servicelist/slaproject/subCus.html?type=1&customerId="+customer_id+"&subCustomerId="+sub_customer_id;
|
window.top.openDialog("selectSubCus","操作",
|
{},
|
{"width":80,"height":80},
|
[{btnId:"btnSure", btnName:"确定", btnStyle:"bluebtn"}],url);
|
}
|
|
|
function showCus(labelId,labelName) {
|
$("#sub_customer_name").val(labelName);
|
$("#sub_customer_id").val(labelId);
|
}
|
|
function showSl() {
|
var customer_id = $("#customer_id").val();
|
if($.util.isEmpty(customer_id)) {
|
popupTips("请先选择${Constants.CUSTOMER_CONSTANTS}");
|
return;
|
}
|
|
var serivceList = $("#serivceList").val();
|
var serivceListId = $("#serivceListId").val();
|
var url = "${base}/business/pages/servicelist/slaproject/serviceListTree.html?customerId="+customer_id+"&type=1";
|
if(!$.util.isEmpty(serivceList)&&!$.util.isEmpty(serivceListId)) {
|
var names = serivceList.split("-");
|
var ids = serivceListId.split("-");
|
if(ids.length==3) {
|
url += "&sl="+ids[2];
|
}
|
}
|
|
window.top.openDialog("selectSl","操作",
|
{},
|
{"width":80,"height":80},
|
[{btnId:"btnSure", btnName:"确定", btnStyle:"bluebtn"}],url);
|
}
|
|
function showName(labelId,labelName) {
|
$("#serivceList").val(labelName);
|
$("#serivceListId").val(labelId);
|
|
}
|
|
function changeMsg() {
|
$("#serivceListId,#serivceList").val("");
|
}
|
|
function queryLevel(a,b) {
|
var priority_id = $("#priority_id").val();
|
var influence_id = $("#influence_id").val();
|
var serivceListId = $("#serivceListId").val();
|
var customer_id = $("#customer_id").val();
|
if(!$.util.isEmpty(priority_id) && !$.util.isEmpty(influence_id) && !$.util.isEmpty(serivceListId) && !$.util.isEmpty(customer_id)) {
|
$.post("${base}/business/pages/question/queryLevel.html",{"priority_id":priority_id,"influence_id":influence_id,"serivceListId":serivceListId,"customer_id":customer_id},function(data,textStatus) {
|
if(data.LEVEL_ID) {
|
$("#slaId").val(data.LEVEL_ID);
|
}
|
if(data.LEVEL_NAME) {
|
$("#slaName").val(data.LEVEL_NAME);
|
$("#levelName").text(data.LEVEL_NAME);
|
}
|
|
$("#level").show();
|
},"json")
|
}
|
}
|
|
$(function() {
|
var pri_level_id = '${question.PRI_LEVEL_ID}';
|
if(!$.util.isEmpty(pri_level_id) ){
|
$("#level").show();
|
}else{
|
$("#level").hide();
|
}
|
$("#save").click(function() {
|
|
$("#myform").submit();
|
});
|
})
|
|
</script>
|
</body>
|
</html>
|