123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626 |
- <!DOCTYPE html>
- <html lang="en">
- <head>
- <meta charset="UTF-8">
- <title>单仓档案管理系统</title>
- <link rel="stylesheet" type="text/css" href="/themes/metro/easyui.css">
- <link rel="stylesheet" type="text/css" href="/themes/icon.css">
- <link rel="stylesheet" href="/themes/oneIndex.css">
- <link rel="stylesheet" type="text/css" href="/themes/modle_index.css">
- <script src="/src/jquery.min.js"></script>
- <script type="text/javascript" src="/src/jquery.easyui.min.js"></script>
- <script type="text/javascript" src="/locale/easyui-lang-zh_CN.js"></script>
- <script src="/src/page.js"></script>
- <script type="text/javascript" src="/src/modle_page.js"></script>
- <script type="text/javascript" src="/src/template-native.js"></script>
- <!-- <script type="text/javascript" src="/src/template.js"></script> -->
- </head>
- <body>
- <div class="tool-wrap">
- <div class="tool">
- <span><a href="#">收藏</a>|<a href="#">帮助</a></span>
- <span class="emp-item">
- <span class="emp-name"><a href="#">某某分公司-某某粮仓-某某管理员</a></span>
- <span class="albumn">
- <img src="/img/albumn.png"></span>
- <a href="">张大鹏</a>
- <span class="albumn-arrow"></span>
- </span>
- </span>
- </div>
- </div>
- <div class="logo-wrap">
- <div class="logo">
- <img src="/img/logo.png" alt="logo">
- </div>
- </div>
- <div class="nav-wrap">
- <div class="nav">
- <ul>
- <li><a href="/index.html">首页</a></li><li class="active"><a href="/pages/company.html">单仓档案</a></li><li>工作平台</li><li>单仓设备集成平台</li><li>单仓业务分析系统</li><li>手持移动端管理</li><li>用户管理</li><li>基础参数管理</li><li>站点平台管理</li>
- </ul>
- </div>
- </div>
- <div class="con-wrap" style="min-height: 600px;">
- <!--上方的足迹导航-->
- <span class="back-last"><img src="/img/back-1.png"> 上一级</span><span class="status-title" style="font-size: 14px;"> 仓房信息档案</span>
- <!--左边题目的框架,取出框再次-->
- <!-- <div class="easyui-tabs" style="width: 100%;height: 600px;" data-options="tabPosition:'left'"> -->
- <!--左边的题目-->
- <!-- <div title='仓房信息'> -->
- <div class="easyui-tabs" style="width: 100%;height: 100%" data-options="border:false">
- <!--每个左边拓展的右边的 仓房基本信息-->
- <div title="仓房基本信息" style="padding: 5px;" id="warehouse_basic_message_container">
- <script type="text/html" id="warehouse_basic_message">
- <div>
- <a href="#" class="easyui-linkbutton l-btn l-btn-small l-btn-plain" iconcls="icon-export" plain="true" group="" id="">
- <span class="l-btn-text" style="margin-left:0px">导出Excel</span>
- </a>
- </div>
- <form>
- <fieldset class="warehouse_base_msg_header">
- <legend><h3>仓房基本信息详情</h3></legend>
- <ul>
- <li>
- <div><strong>所属库:</strong></div>
- <span> <%=%> </span>
- <div><strong>仓房类型:</strong></div>
- <span><%=type%></span>
- <div><strong>仓号:</strong></div>
- <span><%=%></span>
- <div><strong>交付使用日期:</strong></div>
- <span><%=%></span>
- </li>
- <li>
- <div style="width:26px;"></div>
- <div><strong>门窗更换时间:</strong></div>
- <input class="easyui-datebox door_time" style="width:160px;" value="<%=doorChangeDate%>"></input>
- <button class="easyui-linkbutton door_update" data-id="<%=id%>">
- 编辑
- </button>   
- <div><strong>外墙粉刷时间:</strong></div>
- <input class="easyui-datebox wall_time" style="width:160px;" value="<%=wallWashDate%>"></input>
- <button class="easyui-linkbutton wall_update" data-id="<%=id%>">
- 编辑
- </button>
- </li>
- </ul>
- </fieldset>
- <ul>
- <li>
- <fieldset class="warehouse_base_msg_body">
- <legend>结构</legend>
- <ul class="body_block_warehouse">
- <li>
- <div class='warehouse_label'>墙体:</div>
- <span> <%=areaWall%>平方米</span>
- </li>
- <li>
- <div class='warehouse_label'>屋面:</div>
- <span> <%=areaHouse%>平方米</span>
- </li>
- <li>
- <div class='warehouse_label'>地面</div>
- <span> <%=areaFloor%>平方米</span>
- </li>
- <li>
- <div class='warehouse_label'>设计容量:</div>
- <span> <%=areaVolume%>吨</span>
- </li>
- <li>
- <div class='warehouse_label'> </div>
- <span> </span>
- </li>
- </ul>
- </fieldset>
- <fieldset class="warehouse_base_msg_body">
- <legend>仓内</legend>
- <ul class="body_block_warehouse">
- <li>
- <div class='warehouse_label'>长:</div>
- <span> <%=innerWidth%>米</span>
- </li>
- <li>
- <div class='warehouse_label'>宽:</div>
- <span> <%=innerHeight%>米</span>
- </li>
- <li>
- <div class='warehouse_label'>堆粮线高:</div>
- <span> <%=innerLineHeight%>米</span>
- </li>
- <li>
- <div class='warehouse_label'>筒仓内径:</div>
- <span> <%=innerDiameter%>米</span>
- </li>
- <li>
- <div class='warehouse_label'>仓内体积:</div>
- <span> <%=innerVolume%>立方米</span>
- </li>
- </ul>
- </fieldset>
- <fieldset class="warehouse_base_msg_body">
- <legend>其他</legend>
- <ul class="body_block_warehouse">
- <li>
- <div class='warehouse_label'>库门数量:</div>
- <span> <%=doorNumber%>个</span>
- </li>
- <li>
- <div class='warehouse_label'>库门高度:</div>
- <span> <%=doorHeight%>米</span>
- </li>
- <li>
- <div class='warehouse_label'>库门宽度:</div>
- <span> <%=doorWidth%>米</span>
- </li>
- <li>
- <div class='warehouse_label'>通风方式:</div>
- <span> <%=airFormat%></span>
- </li>
- <li>
- <div class='warehouse_label'> 隔热方式::</div>
- <span> <%=hotFormat%></span>
- </li>
- </ul>
- </fieldset>
- </li>
- </ul>
- </form>
- <div class="warehouse_base_info_foot">
- <ul>
- <li>
- <div class="warehouse_label"><strong>货位列表:</strong></div>
- <span><%=%></span>
- </li>
- <li>
- <div class="warehouse_label"><strong>货位号:</strong></div>
- <span><%=positionNumber%></span>
- </li>
- </ul>
- </div>
- </script>
- </div>
- <!--每个左边拓展的右边的 仓房电缆布置图-->
- <div title="仓房电缆布置图">
- <img src="/themes/picture/layout_show.jpg" width='975'>
- </div>
- <!--每个左边拓展的右边的 记录查询-->
- <div title="记录查询" style="padding-left:5px" id="record_check">
- <div class="dt-nav">
- 检查日期:
- <input class="easyui-datebox" type="text" id="start_time_record" value="">-
- <input class="easyui-datebox" id="end_time_record" value=""> 
- 检查类别:
- <select id="apartment_record" style="width: 100px;height: 22px;border-color: rgb(224, 224, 224);">
- <option selected="selected" value="0">全选</option>
- <script type="text/html" id="record_option_equip">
- <%for(var i=0;i<type.length;i++){%>
- <option value="<%=type[i]%>"><%=type[i]%></option>
- <%}%>
- </script>
- </select>
- <a href="#" class="easyui-linkbutton" style="height: 22px;padding: 0 10px;" id="warehouse_equip_record_search">搜索</a>
- </div>
- <div class="dt-item" id="">
- <div class="wp-item-export">
- <a class="wp-port wp-port-export" id="warehouse_add_record">添加</a>
- <a class="wp-port wp-port-import">导出</a>
- </div>
- <table class="easyui-datagrid" id="record_equip" style="width:100%;"
- toolbar="#record_equip_tool"
- title="" iconCls="icon-save"
- rownumbers="true" pagination="true">
- <!-- <thead>
- <tr>
- <th style="width:8%" data-options="field:'checkDate'">检查日期</th>
- <th style="width:7%" data-options="field:'type'">检查类别</th>
- <th style="width:7%" data-options="field:'bosshead'">检察人员</th>
- <th style="width:8%" data-options="field:'problem'">存在问题</th>
- <th style="width:6%" data-options="field:'opinion'">处理意见</th>
- <th style="width:11%" data-options="field:'maintainStartDate'">维修开始日期</th>
- <th style="width:11%" data-options="field:'maintainEndDate'">维修结束日期</th>
- <th style="width:11%" data-options="field:'bosshead'">维修责任人</th>
- <th style="width:9%" data-options="field:'result'">维修结果</th>
- <th style="width:9%" data-options="field:'remark',align:'center'">备注</th>
- <th style="width:12%" data-options="field:'operation',align:'center'">操作</th>
- </tr>
- </thead> -->
- </table>
- <!--这里是模板渲染出来的地方,在框架中很麻烦,暂时省略-->
- <!-- <div id="warehouse_record_list_container">
- <script type='text/html' id="warehouse_record_list">
- <table class="easyui-datagrid" id="record_equip" style="width:100%;"
- toolbar="#tb"
- title="" iconCls="icon-save"
- rownumbers="true" pagination="true">
- <thead>
- <tr>
- <th style="width:8%" data-options="field:'check_data'">检查日期</th>
- <th style="width:7%" data-options="field:'check_type'">检查类别</th>
- <th style="width:7%" data-options="field:'check_person'">检察人员</th>
- <th style="width:8%" data-options="field:'exsit_pro'">存在问题</th>
- <th style="width:6%" data-options="field:'deal_advise'">处理意见</th>
- <th style="width:8%" data-options="field:'begin_date'">维修开始日期</th>
- <th style="width:8%" data-options="field:'end_date'">维修结束日期</th>
- <th style="width:8%" data-options="field:'jjj'">维修责任人</th>
- <th style="width:7%" data-options="field:'result'">维修结果</th>
- <th style="width:7%" data-options="field:'attachment',align:'center'">备注</th>
- <th style="width:12%" data-options="field:'operation',align:'center'">操作</th>
- </tr>
- </thead>
- <tbody>
- <%for(var i = 0; i<list.length; i++ ){%>
- <tr>
- <td><%=list[i]['checkDate']%></td>
- <td><%=list[i]['type']%></td>
- <td>检察人员?</td>
- <td><%=list[i]['problem']%></td>
- <td><%=list[i]['opinion']%></td>
- <td><%=list[i]['maintainStartDate']%></td>
- <td><%=list[i]['maintainEndDate']%></td>
- <td><%=list[i]['bosshead']%></td>
- <td><%=list[i]['result']%></td>
- <td><%=list[i]['remark']%></td>
- <td>
- <a href="#" data-id='<%=list[i]['id']%>'>【修改】</a>
- <a href="#" data-id='<%=list[i]['id']%>'>【详情】</a>
- </td>
- </tr>
- <%}%>
- </tbody>
- </table>
- </script>
- </div> -->
- </div>
- </div>
- <!-- </div> -->
- <!-- </div> -->
- </div>
- </div>
- <div class="bottom-wrap">© 2018 中储粮-单仓档案管理系统 版权所有</div>
- <!--主要窗口的弹窗窗口-->
- <div id="warehouse_basic_record_add_win" class="easyui-window " title="记录查询添加" closed='true' style="width:680px;height:500px;padding:5px;">
- <form method="post" action="#" id="warehouse_basic_record_add_form">
- <input name="id" type="hidden"></input>
- <ul class="warehouse_basic_record_add_win_ul">
- <li>
- <div>检查日期:</div>
- <input type="text" name="checkDate" class="easyui-datebox easyui-validatebox"></input>
- <div>检查类别:</div>
- <input type="text" name="type" class="easyui-validatebox "></input>
- <div>检查项目:</div>
- <input type="text" name="project" class="easyui-validatebox"></input>
- </li>
- <li>
- <div class="text_title_public_style easyui-validatebox">存在问题:</div>
- <textarea name="problem"></textarea>
- </li>
- <li>
- <div class="text_title_public_style easyui-validatebox" name='opinion'>处理意见:</div>
- <textarea></textarea>
- </li>
- <li>
- <div>维修责任人:</div>
- <input type="text" name="bosshead" class="easyui-validatebox"></input>
- <div>维修开始日期:</div>
- <input type="text" class="easyui-datebox easyui-validatebox" name="maintainStartDate"></input>
- <div>维修结束日期:</div>
- <input type="text" class="easyui-datebox easyui-validatebox" name="maintainEndDate"></input>
- </li>
- <li>
- <div class="text_title_public_style">维修结果:</div>
- <textarea name="result" class="easyui-validatebox"></textarea>
- </li>
- <li>
- <div class="text_title_public_style">备注:</div>
- <textarea name="remark" class="easyui-validatebox"></textarea>
- </li>
- <li>
- <a href="#" class="easyui-linkbutton" icon="icon-ok" data-control='edit' id="comfirm_add_record" style="margin:auto 20px auto 250px;">确认</a>
- <a href="#" class="easyui-linkbutton" id="close_warehouse_record_add" icon="icon-cancel" style="margin-left:40px;">取消</a>
- </li>
- </ul>
- </form>
- </div>
- <script>
- (function(win,$){
- var ip = modle_one._ip;
- var app = {
- init:function(){
- modle_one._open('#warehouse_add_record','#warehouse_basic_record_add_win');
- modle_one._close('#close_warehouse_record_add','#warehouse_basic_record_add_win');
- //首次页面出来时候加载的信息
- app.get_house_show();
- app.update_door_wall();
- app.add_equip_record();
- app.record_equip_search();
- app.delete_record_msg();
- app.clear_form_add_record();
- app.update_record_msg();
- },
- dateFormart:function(time){
- var date = new Date(time);
- var year = date.getFullYear();
- var month = date.getMonth()+1;
- var day = date.getDate();
- return year+'/'+month+'/'+day;
- },
- //由于添加的表单不是新的窗口,所以啊,每次进入要清空表单的数据
- clear_form_add_record:function(){
- $('#warehouse_add_record').on('click',function(){
- $('#warehouse_basic_record_add_form').form('clear');
- })
- },
- //仓房基本信息进入填充标签页表格数据
- get_house_show:function(){
- //得到仓房基本信息页面的展示数据
- var url_warehouse_basic_msg = ip+"/house/show";
- var data_warehouse_basic_msg = {houseId:'1'};
- var condition_warehouse_basic_msg =
- {
- url:url_warehouse_basic_msg,
- data:data_warehouse_basic_msg
- };
- modle_one._get(condition_warehouse_basic_msg,function(msg){
- show_data = msg.house;
- var html = modle_one._show('warehouse_basic_message',show_data);
- $('#warehouse_basic_message_container').html(html);
- $.parser.parse($('#warehouse_basic_message_container'));
- });
- //数据表格
- $('#record_equip').datagrid({
- url: ip+'/house/record/get',
- method: 'get',
- // toolbar: '#bd-toolbar',
- rownumbers: true,
- pagination: true,
- fitColumns:true,
- singleSelect:false,
- title: '记录查询',
- fit: true,
- striped:true,
- showFooter:true,
- columns: [[
- {field:'checkDate', title:'检查日期', width:'8%'},
- {field:'type', title:'检测类型', width:'7%'},
- {field:'bosshead', title:'检察人员', width:'7%'},
- {field:'problem', title:'存在问题', width:'8%'},
- {field:'opinion', title:'处理意见', width:'8%'},
- {field:'maintainStartDate', title:'维修开始日期', width:'11%'},
- {field:'maintainEndDate', title:'维修结束日期', width:'11%'},
- {field:'bosshead', title:'维修责任人', width:'11%'},
- {field:'result', title:'处理结果', width:'9%'},
- {field:'remark', title:'备注', width:'9%'},
- {
- field:'id',
- title:'操作',
- width:'14%',
- align: 'center',
- formatter: function(value, row, index) {
- return '<a class="record_record_update" data-id=' + value + '>修改</a> | <a class="record_equip_del" data-id=' + value + '>删除</a>';
- }
- }
- ]],
- loadFilter: function(data) {
- return {
- // page: e.data.pageNo,
- total: data.result.count,
- rows: data.result.list
- };
- },
- onLoadSuccess: function(){
- }
- });
- //这里是模板渲染出来的地方,在框架中很麻烦,暂时省略
- //得到记录查询的记录
- // var url_warehouse_record_msg = ip+'/house/record/get';
- // var data_warehouse_record_msg = {};
- // var condition_warehouse_record_msg = {
- // url:url_warehouse_record_msg,
- // data:data_warehouse_record_msg
- // };
- // modle_one._get(condition_warehouse_record_msg,function(msg){
- // console.info(msg);
- // //编译单选框
- // var select_content = modle_one._show('record_option_equip',msg);
- // // console.info(select_content);
- // $('#apartment_record').append(select_content);
- // //编译内容
- // var msg_obj = msg.records;
- // var html = modle_one._show('warehouse_record_list',msg_obj);
- // // console.log(html);
- // $('#warehouse_record_list_container').html(html);
- // $.parser.parse($('#warehouse_record_list_container'));
- // })
- },
- //更新门和墙的时间
- update_door_wall:function(){
- var url = ip+"/house/edit";
- $(document).on('click','.door_update',function(){
- var door_date_str = $('.door_time').val();
- var id = $(this).data('id');
- var data = {
- doorChangeDate:door_date_str,
- houseId:id,
- wallWashDate:''
- };
- var condition = {
- url:url,
- data:data
- };
- // console.log(condition);
- modle_one._get(condition,function(msg){
- // console.info(msg);
- modle_one._alert('成功提示','修改成功!');
- })
- });
- $(document).on('click','.wall_update',function(){
- var wall_date_str = $('.wall_time').val();
- var id = $(this).data('id');
- var data = {
- doorChangeDate:'',
- houseId:id,
- wallWashDate:wall_date_str
- };
- var condition = {
- url:url,
- data:data
- };
- // console.log(condition);
- modle_one._get(condition,function(msg){
- // console.info(msg);
- modle_one._alert('成功提示','修改成功!');
- })
- });
- },
- //记录添加数据
- add_equip_record:function(){
- $('#comfirm_add_record').on('click',function(){
- //这个control是用来看是是编辑的还是是添加的
- var control = $(this).data('control');
- console.log(control);
- var form_data = $('#warehouse_basic_record_add_form').serializeArray();
- var data = {};
- var url;
- if(control=='edit'){
- url = ip+'/house/record/edit';
- }
- else{
- url = ip+'/house/record/insert';
- }
- console.log(url);
- for(var i=0;i<form_data.length;i++){
- data[form_data[i]['name']] = form_data[i]['value'];
- }
- // console.error(data);
- var condition = {
- url:url,
- data:data
- };
- // console.log(condition);
- modle_one._post(condition,function(msg){
- // console.log(msg);
- modle_one._alert('成功提示','保存成功!');
- $('#warehouse_basic_record_add_win').window('close');
- $('#record_equip').datagrid('reload');
- })
- })
- },
- //warehouse_equip_record_search
- record_equip_search:function(){
- $('#warehouse_equip_record_search').on('click',function(e){
- var start = $('#start_time_record').next().find('*').filter('.textbox-value').val();
- var end = $('#end_time_record').next().find('*').filter('.textbox-value').val();;
- var type = $('#apartment_record').val();
- var data = {};
- // console.log(start+''+end+''+type);
- if(type ==0){
- data = {
- maintainStartDate:start,
- maintainEndDate:end
- };
- }else{
- data = {
- maintainStartDate:start,
- maintainEndDate:end,
- type:type
- };
- }
- $('#record_equip').datagrid({
- url: ip+'/house/record/get',
- method: 'get',
- // toolbar: '#bd-toolbar',
- rownumbers: true,
- pagination: true,
- fitColumns:true,
- singleSelect:false,
- title: '记录查询',
- fit: true,
- striped:true,
- showFooter:true,
- queryParams:data,
- columns: [[
- {field:'checkDate', title:'检查日期', width:'8%'},
- {field:'type', title:'检测类型', width:'7%'},
- {field:'bosshead', title:'检察人员', width:'7%'},
- {field:'problem', title:'存在问题', width:'8%'},
- {field:'opinion', title:'处理意见', width:'8%'},
- {field:'maintainStartDate', title:'维修开始日期', width:'11%'},
- {field:'maintainEndDate', title:'维修结束日期', width:'11%'},
- {field:'bosshead', title:'维修责任人', width:'11%'},
- {field:'result', title:'处理结果', width:'9%'},
- {field:'remark', title:'备注', width:'9%'},
- {
- field:'id',
- title:'操作',
- width:'14%',
- align: 'center',
- formatter: function(value, row, index) {
- return '<a class="record_record_update" data-id=' + value + '>修改</a> | <a class="record_equip_del" data-id=' + value + '>删除</a>';
- }
- }
- ]],
- loadFilter: function(data) {
- return {
- total: data.result.count,
- rows: data.result.list
- };
- }
- });
- })
- },
- delete_record_msg:function(){
- $(document).on('click','.record_equip_del',function(){
- $.messager.confirm('确认提示','你确认删除磁条记录吗?',function(r){
- if (r){
- var url = ip+'/house/record/delete';
- var data = $('.record_equip_del').data('id');
- console.log(data);
- var condition = {
- url:url,
- data:{id:data}
- }
- modle_one._post(condition,function(msg){
- console.log(msg);
- if(msg.code=='-1'){
- modle_one._alert('成功提示','删除失败!');
- }
- else{
- modle_one._alert('成功提示','删除成功!');
- $('#record_equip').datagrid('reload');
- }
- })
- }
- });
- })
- },
- update_record_msg:function(){
- $(document).on('click','.record_record_update',function(){
- //我被坑了半天了,这个easyui里面的时间的格式,就算是传过来给我的是时间戳,
- //也要穿个字符串,刚被坑了半天,我真的醉了
- var row = $('#record_equip').datagrid('getSelected');
- // console.log(row);
- modle_one._open('.record_record_update','#warehouse_basic_record_add_win');
- $('#warehouse_basic_record_add_form').form('load',row);
- });
- }
- }
- app.init();
- })(window,jQuery);
- </script>
- </body>
- </html>
|