123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165 |
- <!DOCTYPE html>
- <html>
- <head>
- <title>TODO supply a title</title>
- {include file="../application/manage/view/commons/headers.html" }
- <script >
- // 编辑窗口
- var $editWin;
- var winHeight=$(window).height();
- var frameHeight=winHeight*0.9;
- $(function(){
- $editWin = $('#edit-window').window({
- title: '关键词编辑',
- width: 800,height: frameHeight,
- top: ($(document).height() -frameHeight ) /2 ,
- left: ($(document).width() -820 ) /2 ,
- shadow: true,modal: true,
- iconCls: 'icon-edit',closed: true,
- minimizable: false,maximizable: false,collapsible: false
- });
- })
- function dateFormatter(date){
- if(typeof date=="undefined"){ return "--"; }
- return new Date(date).format("yyyyMMdd hh:mm:ss");
- }
- function commandsFormatter(id,row){
- var cmdEdit="<a href='#' onclick=\"javascript:showEditWin('"+row.id+"');\" >编辑</a> ";
- if(row.status != 1){
- cmdEdit+="<a href='#' onclick=\"javascript:deleteRow('"+row.id+"');\" >删除</a>";
- }
- return cmdEdit;
- }
- function delstatusFormatter(mode){
- if(mode == '1'){ return "屏蔽";
- }else if(mode=="0"){ return "正常";
- }else{ return "--";
- }
- }
- function urgentFormatter(mode){
- if(mode == '1'){ return "是";
- }else if(mode=="0"){ return "否";
- }else{ return "--";
- }
- }
- function applicationFormatter(mode){
- if(mode == '1'){ return "未申请";
- }else if(mode=="2"){ return "已申请,待接受";
- }else if(mode=="3"){ return "诊断中";
- }else if(mode=="4"){ return "诊断完成,待确认";
- }else if(mode=="5"){ return "已确认";
- }else if(mode=="6"){ return "已打印";
- }else if(mode=="7"){ return "驳回";
- }else{ return "--";
- }
- }
- $(function(){
- var height=$(document).height();
- $("#gd").height(height);
- $('#gd').datagrid({
- url:'/manage/remoteapplication/datas',
- idField:'id',method: 'get',rownumbers: true,showFooter: true,
- toolbar: '#tb',pageList: [ dgRowSize , dgRowSize*2 , 100 ] , pagination:true, pageSize: dgRowSize ,
- columns:[[
- {field:'id',title:'ID',width:180 ,hidden:true },
- {field:'remote_institution_id',title:'申请的目标医院',align: 'center',width:120,hidden:true },
- {field:'remote_institution_name',title:'申请的目标医院',align: 'center',width:120},
- {field:'remote_doctor_id',title:'申请的目标医生',width:"120",align: 'center',hidden:true },
- {field:'remote_doctor_name',title:'申请的目标医生',width:"120",align: 'center' },
- {field:'local_institution_id',title:'发起申请医院',width:120,align: 'center',hidden:true },
- {field:'local_institution_name',title:'发起申请医院',width:120,align: 'center'},
- {field:'req_date_time',title:'发起时间',align: 'center', width:135, formatter:dateFormatter },
- {field:'req_doctor_id',title:'申请医生',width:"100",align: 'center',hidden:true },
- {field:'req_doctor_name',title:'申请医生',width:"100",align: 'center'},
- {field:'illness_desc',title:'主诉',align: 'center', width:135},
- {field:'clin_symp',title:'临床症状',width:"120",align: 'center'},
- {field:'phys_sign',title:'体征',width:"100",align: 'center' },
- {field:'clin_diag',title:'临床诊断',width:"120",align: 'center' },
- {field:'anamnesis',title:'既往史',width:"120",align: 'center' },
- {field:'family_ill',title:'家族史',width:"120",align: 'center'},
- {field:'marrital',title:'婚姻史',width:"120",align: 'center' },
- {field:'remark',title:'备注',width:"100",align: 'center' },
- {field:'exam_id',title:'检查表id',width:"120",align: 'center',hidden:true},
- {field:'is_urgent',title:'是否急诊',width:"120",align: 'center',formatter:urgentFormatter },
- {field:'application_status',title:'远程申请状态',width:180,align: 'center',formatter:applicationFormatter },
- {field:'status',title:'删除状态',width:80,align: 'center',formatter:delstatusFormatter },
- {field:'createdAt',title:'创建时间',align: 'center', width:135, formatter:dateFormatter },
- {field:'grid_commands',title:'操作',align: 'center',width:100, formatter:commandsFormatter },
- ]],
- onDblClickRow :function(rowIndex,rowData){
- showEditWin(rowData.id);
- },
- });
- });
- // 显示编辑窗口
- function showEditWin(id){
- if("undefined"== typeof id){
- $editWin.window('open');$('#editFrame').attr('src','/manage/remoteapplication/edit');
- }else{
- $editWin.window('open');$('#editFrame').attr('src','/manage/remoteapplication/edit?id='+id);
- }
- }
- function deleteRow(id){
- $.messager.confirm('Confirm','确定要删除这条记录吗?',function(r){
- if(r){
- $.ajax({
- url:"/manage/remoteapplication/delete",
- data:"ids="+id+"&t="+new Date(),
- success:function(rs){
- if(rs=="delete_ok"){
- alert("操作已成功!");
- document.location.reload();
- }else{
- alert("操作失败!");
- }
- }
- });
- }
- });
- }
- // 关闭编辑窗口
- function closeEditWin(isReload){
- $editWin.window('close');
- if(isReload=="reload"){
- document.location.reload();
- }
- }
- </script>
- </head>
- <body>
- <div id="gd" class="easyui-datagrid" style="width:100%;height:auto;" ></div>
- <div id="tb" class="editform" style="display: none; padding-top: 1px;">
- 菜单:<select id="catid" name="params.catid" style="width: 150px; " >
- <option value="" >查询全部</option></select>
- 状态:<select id="status" name="params.status" style="width: 80px; " >
- <option value="" >查询全部</option><option value="1" >可用</option><option value="0" >不可用</option>
- </select>
- 标题:<input type="text" id="title" name="title" class="easyui-textbox" style="width: 200px; vertical-align: middle;" title="菜单名称" />
- <a id="submit" href="#" class="easyui-linkbutton" data-options="iconCls:'icon-search'" style="width: 80px">查询</a>
- <a id="reset" href="#" class="easyui-linkbutton" data-options="iconCls:'icon-clear'" style="width: 80px" onclick="reset()" >重置</a>
-
- </div>
- <div id="edit-window" class="easyui-window" style="overflow: hidden" ><iframe src="about:blank" id="editFrame" width="100%" height="100%" frameborder="0" scrolling="yes" ></iframe></div>
- </body>
- </html>
|