| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216 |
- @{
- ViewBag.Title = "表设备管理";
- Layout = "~/Views/Shared/_Form.cshtml";
- }
- <script>
- var keyValue = request('keyValue');
- $(function () {
- initControl();
- })
- //初始化控件
- function initControl() {
- //电池电压状态
- $("#BatteryVoltageState").ComboBox({
- description: "==请选择电池电压状态==",
- height: "170px"
- });
- //箱门报警
- $("#BoxDoorAlarm").ComboBox({
- description: "==请选择箱门报警==",
- height: "170px"
- });
- //流量计故障
- $("#MeterFault").ComboBox({
- description: "==请选择箱门报警==",
- height: "170px"
- });
- //换表组标记
- $("#MeterTag").ComboBox({
- description: "==请选择换表组标记==",
- height: "170px"
- });
- //表类型
- $("#MeterTypeId").ComboBoxTree({
- url: "/PipeNetworkManage/Meter/GetTreeJson",
- id: "ItemValue",
- text: "ItemName",
- description: "==请选择==",
- height: "200px"
- });
- $("#MeterAssessmentType").val(keyValue == "" ? "0" : keyValue);
- //获取表单
- if (!!keyValue) {
- $.SetForm({
- url: "/PipeNetworkManage/Meter/GetMeterTypeFormJson",
- param: { keyValue: keyValue },
- success: function (data) {
- $("#form1").SetWebControls(data);
- }
- });
- }
- }
- //保存表单
- function AcceptClick() {
- if (!$('#form1').Validform()) {
- return false;
- }
- var postData = $("#form1").GetWebControls(keyValue);
- //postData 格式化 将 替换为 ""
- for (var i in postData) {
- if (postData[i] == " ") {
- postData[i] = "";
- }
- }
- $.SaveForm({
- url: "/PipeNetworkManage/Meter/SaveMeterTypeForm?keyValue=" + keyValue,
- param: { "keyValue": keyValue, "strMeterType": JSON.stringify(postData) },
- loading: "正在保存数据...",
- success: function () {
- $.currentIframe().$("#gridTable").resetSelection();
- $.currentIframe().$("#gridTable").trigger("reloadGrid");
- }
- })
- }
- </script>
- <style type="text/css">
- .form .formTitle {
- width: 150px;
- }
- </style>
- <div style="margin-left: 10px; margin-top: 20px; margin-right: 30px;">
- <table class="form">
- <tr>
- <th class="formTitle">考核表名称<font face="宋体">*</font></th>
- <td class="formValue">
- <input id="MeterAssessmentName" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" errormsg="请输入表名称" placeholder="请输入表名称" />
- </td>
- <input id="MeterAssessmentId" class="form-control" type="hidden" />
- <th class="formTitle">考核表类型<font face="宋体">*</font></th>
- <td class="formValue">
- <div id="MeterTypeId" type="select" class="ui-select" isvalid="yes" checkexpession="NotNull" errormsg="请选择表类型">
- </div>
- </td>
- </tr>
- <tr>
- <th class="formTitle">厂商编码<font face="宋体">*</font></th>
- <td class="formValue">
- <input id="ManufacturerCode" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" errormsg="厂商编码不能为空" placeholder="请输入厂商编码" />
- </td>
- <th class="formTitle">考核表编号<font face="宋体">*</font></th>
- <td class="formValue">
- <input id="MeterAssessmentCode" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" errormsg="考核表编号不能为空" placeholder="请输入考核表编号" />
- </td>
- </tr>
- <tr>
- <th class="formTitle">换表时间</th>
- <td class="formValue">
- <input id="ChangeMeterTime" type="text" class="form-control input-wdatepicker" onfocus="WdatePicker()" isvalid="yes" checkexpession="NotNull"/>
- </td>
- <th class="formTitle">采集时间</th>
- <td class="formValue">
- <input id="GetDateTime" type="text" class="form-control input-wdatepicker" onfocus="WdatePicker()" />
- </td>
- </tr>
- <tr>
- <th class="formTitle">净累计流量(m³/h)</th>
- <td class="formValue">
- <input id="NetCumulativeFlow" type="text" class="form-control" />
- </td>
- <th class="formTitle">正累计流量(m³/h)</th>
- <td class="formValue">
- <input id="PositiveCumulativeFlow" type="text" class="form-control" />
- </td>
- </tr>
- <tr>
- <th class="formTitle">负累计流量(m³/h)</th>
- <td class="formValue">
- <input id="NegativeCumulativeFlow" type="text" class="form-control" />
- </td>
- <th class="formTitle">瞬时流量(m³/h)</th>
- <td class="formValue">
- <input id="InstantaneousFlow" type="text" class="form-control" />
- </td>
- </tr>
- <tr>
- <th class="formTitle">瞬时流量上限报警值(m³/h)</th>
- <td class="formValue">
- <input id="InstantaneousFlowUpAlarm" type="text" class="form-control" />
- </td>
- <th class="formTitle">瞬时流量下限报警值(m³/h)</th>
- <td class="formValue">
- <input id="InstantaneousFlowDownAlarm" type="text" class="form-control" />
- </td>
- </tr>
- <tr>
- <th class="formTitle">压力</th>
- <td class="formValue">
- <input id="Pressure" type="text" class="form-control" />
- </td>
- <th class="formTitle">压力上限报警值</th>
- <td class="formValue">
- <input id="PressureUpAlarm" type="text" class="form-control" />
- </td>
- </tr>
- <tr>
- <th class="formTitle">压力下限报警值</th>
- <td class="formValue">
- <input id="PressureDownAlarm" type="text" class="form-control" />
- </td>
- <th class="formTitle">电池电压值</th>
- <td class="formValue">
- <input id="BatteryVoltageValue" type="text" class="form-control" />
- </td>
- </tr>
- <tr>
- <th class="formTitle">电池电压状态</th>
- <td class="formValue">
- <div id="BatteryVoltageState" type="select" class="ui-select">
- <ul>
- <li data-value="0">正常</li>
- <li data-value="1">欠压</li>
- </ul>
- </div>
- </td>
- <th class="formTitle">箱门报警</th>
- <td class="formValue">
- <div id="BoxDoorAlarm" type="select" class="ui-select">
- <ul>
- <li data-value="0">正常</li>
- <li data-value="1">报警</li>
- </ul>
- </div>
- </td>
- </tr>
- <tr>
- <th class="formTitle">流量计故障</th>
- <td class="formValue">
- <div id="MeterFault" type="select" class="ui-select">
- <ul>
- <li data-value="0">正常</li>
- <li data-value="1">故障</li>
- </ul>
- </div>
- </td>
- <th class="formTitle">换表组标记</th>
- <td class="formValue">
- <div id="MeterTag" type="select" class="ui-select">
- <ul>
- <li data-value="0">正常</li>
- <li data-value="1">故障</li>
- </ul>
- </div>
- </td>
- </tr>
- </table>
- </div>
|