1
0

2 Коммитууд a93747a603 ... 1e4696deaf

Эзэн SHA1 Мессеж Огноо
  liranlong 1e4696deaf Merge branch 'master' of http://117.72.14.118:3000/ZYjames12345/zhujian_OA 1 өдөр өмнө
  liranlong fd7f09cee7 _ 1 өдөр өмнө

Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 0 - 0
js/axios.min.js


Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 10 - 0
js/vue.min.js


+ 1155 - 0
tpl/shouwenbg/WJCBD/formeditZW_vue.html

@@ -0,0 +1,1155 @@
+<!DOCTYPE html>
+<html xmlns="http://www.w3.org/1999/xhtml" ng-app="app">
+<head>
+    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
+
+    <title>一般收文</title>
+    <link href="../../../AFrontEnd/css/animate.css" rel="stylesheet" />
+    <link href="../../../AFrontEnd/css/fontawesome/css/font-awesome.css" rel="stylesheet" />
+    <link href="../../../AFrontEnd/css/bootstrap.css" rel="stylesheet" />
+    <link href="../../../AFrontEnd/css/style.css" rel="stylesheet" />
+		
+		<script src="../../../js/vue.min.js"></script>
+		<script src="../../../js/axios.min.js"></script>
+    <script>document.write("<link href='../../../AFrontEnd/css/special.css?time=" + new Date().getTime() + "' rel='stylesheet'>");</script>
+    <script>document.write("<link href='../../flowchart_app_imgcss/css/formedit.css?time=" + new Date().getTime() + "' rel='stylesheet'>");</script>
+    <script>document.write("<link href='../../flowchart_app_imgcss/css/formeditZW.css?time=" + new Date().getTime() + "' rel='stylesheet'>");</script>
+    <script>document.write("<link href='../../flowchart_app_imgcss/css/canvasQianzi.css?time=" + new Date().getTime() + "' rel='stylesheet'>");</script>
+</head>
+<body>
+	<div id="appvue">
+		<div class="wrapper wrapper-content">
+			<div class="row">
+				 <div class="col-md-12">
+					  <div class="ibox float-e-margins">
+							 <div class="ibox-content">
+								  <div class="row">
+										<div class="sp-page mousemove" style="position:fixed;z-index:6;background:#c6c6c6;opacity:0.5;display:none"></div>
+										<!-- top -->
+										<div class="sp-box" style="background: #008A94; padding-right: 10px; line-height: 30px; ">
+											<div class="sp-page sp-color-white" style="width: 200px; margin: 7px 0; text-indent: 10px">{{flowTitle}}</div>
+											<div class="sp-page-col sp-pull-right sp-ml-30">
+											    <div class="sp-page-col" v-for="(item,index) in buttonList" :key="index">
+											        <button class="sp-md sp-radius sp-mt-5" style="padding: 4px 10px;" :class="{'sp-btn-gray':item.CODE.indexOf('SENDITEM')==-1,'sp-btn-blue':item.CODE.indexOf('SENDITEM')!=-1}" @click="btnEvent(item)" v-if="item.CODE!='array'&&dotype==1||(dotype!=1&&item.EXPLAIN=='1')">
+											            <img v-if="item.CODE.indexOf('SAVEITEM')!=-1" src="../../flowchart_app_imgcss/img/bc.png" height="14" />
+											            <img v-if="item.CODE.indexOf('PRINTITEM')!=-1" src="../../flowchart_app_imgcss/img/dy.png" height="14" />
+											            <img v-if="item.CODE.indexOf('SENDITEM')!=-1" src="../../flowchart_app_imgcss/img/zfw.png" height="14" />
+											            <img v-if="item.CODE.indexOf('SENDLOG')!=-1" src="../../flowchart_app_imgcss/img/lz.png" height="14" />
+											            {{item.CNAME}}
+											        </button>
+											        <button style="padding: 4px 10px; position: relative" class="sp-btn-md sp-radius sp-btn-blue tiaoahao" v-if="item.CODE=='array'">
+											            {{item.CNAME}}
+											            <div class="sp-page" style="width:auto;background:#fff;border:1px solid #ccc;position:absolute;top:28px;left:50%;transform:translateX(-50%);z-index:12;display:none">
+											                <div class="sp-box sp-text-center" v-for="(item1,index) in item.data" >
+											                    <span class="sp-radius" :class="{'sp-btn-gray':item1.CODE.indexOf('SENDITEM')==-1,'sp-btn-blue':item1.CODE.indexOf('SENDITEM')!=-1}" :click="btnEvent(item1)">{{item1.CNAME}}</span>
+											                </div>
+											            </div>
+											        </button>
+											    </div>
+											    <button style="padding:4px 10px;" class="sp-btn-gray sp-md sp-radius sp-mt-5" onclick="javascript: window.close(); localStorage.setItem('GlWorkPlatform-shouwenbg-refresh', 1)">
+											        <img src="../../flowchart_app_imgcss/img/fh.png" height="14" />
+											        关闭
+											    </button>
+											</div>
+											<div class="sp-wrapper-head-col sp-mr-20">
+											    <span class="sp-wrapper-head-col-span" style="padding: 0; border: 1px solid #eee; border-radius: 5px; display: inline-block; line-height: 30px; height: 30px; margin-top: 5px;">
+											        <i class="icon-map-1 sp-pl-5 pointer" ng-click="onePic()"></i>
+											        <input type="text" class="sp-wrapper-head-search" style="border:0" placeholder="地图搜索" ng-model="headBtnSearchKeyword" ng-change="headBtnSearch()" />
+											    </span>
+											    <div class="sp-wrapper-head-sub-2 sp-text-center" style="width:175px;" ng-if="headSearchResult_view">
+											        <div class="sp-lh-26-wrap" v-for="item in headSearchResult" ng-click="headKeywordPage(item)"><a ng-bind="item.name" title="{{item.name}}"></a></div>
+											    </div>
+											</div>
+											<div class="sp-wrapper-head-col" onclick="$('#attachlist')[0].contentWindow.openTool('../../flfg/bzgf.html', '标准规范');">
+											    <span class="sp-wrapper-head-col-span">
+											        <i class="icon-book"></i>标准规范
+											    </span>
+											</div>
+											<div class="sp-wrapper-head-col" onclick="$('#attachlist')[0].contentWindow.openTool('../../flfg/flgf.html', '法律法规');">
+											    <span class="sp-wrapper-head-col-span">
+											        <i class="fa fa-legal"></i>法律法规
+											    </span>
+											</div>
+											<div class="sp-wrapper-head-col" onclick="$('#attachlist')[0].contentWindow.openTool('../../flfg/dnfg.html', '党内规范');">
+											    <span class="sp-wrapper-head-col-span">
+											        <i class="icon-newspaper-1"></i>党内规范
+											    </span>
+											</div>
+											<div class="sp-wrapper-head-col" onclick="$('#attachlist')[0].contentWindow.openTool('../../fontOA/list.html', '公文查询');">
+											    <span class="sp-wrapper-head-col-span">
+											        <i class="icon-chart-alt-outline"></i>公文查询
+											    </span>
+											</div>
+										</div>
+										<!-- left -->
+										<div class="page-item leftBox" style="width: 70%; overflow: visible;">
+										  <div id="topDiv" class="sp-box" style="width:100%;height:100%;background:#0099FF;padding:0px;margin:0px;border:0px solid yellow">
+										    <div class="sp-page" style="width:100%; padding:2px;margin:2px">
+										            <span class="upload sp-color-white" style="top:5px;height:36px;vertical-align:middle;padding-left:10px;font-size:16px">正文:</span>
+										            <span style="display:inline-block" class="sp-btn-gray-outline sp-btn-sm upload" v-if="dotype!=0&&arrayFile==null">
+										                <span class="upload-tip"></span>
+										                <input id="fileupload-zw" class="upload-file-single" @click="upload_zw()" type="file" name="files[]" multiple>
+										                <i class="fa fa-plus sp-color-white"></i>
+										                <span class="upload-loading" v-if="uploading_zw"><i class="fa fa-spinner fa-pulse sp-fs-20"></i></span>
+										            </span>
+										            <div v-if="arrayFile!=null" style="width: 350px; color: #fff; display: inline-block; cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; position: relative; top: 5px; margin-left: 10px">
+										                <span @click="seeFile(arrayFile)">
+																			{{arrayFile.FILENAMES}}
+																		</span>
+										                <a @click="downLoad(arrayFile)" title="下载">
+										                    <img src="../../flowchart_app_imgcss/img/attachlist/download.png" title="下载" />
+										                </a>
+										                </div>
+										        </div>
+										        <div class="sp-page sp-bg-white" style="height:100%;padding:0px; margin:0px;border:0px solid black;">
+										            <iframe id="iframe_book" style="width:100%;height:600px;background-color:white;padding:0px; margin:0px; border:0px solid red" frameborder="0" class="iframe" scrolling="no"></iframe>
+										        </div>
+										    </div>
+										    <div id="bottomDiv" class="sp-box" style="width: 100%; background: #0099FF; color: #fff;padding:0px;margin:0px; border:0px solid green">
+										        <div class="sp-page" style="width: 100%; vertical-align: middle; padding: 2px; margin: 2px; ">
+										            <span id="lineDiv" class="upload sp-color-white" style="top: 0; height: 36px; padding-left: 10px; padding-top: 5px; font-size: 16px; cursor: ns-resize; " ng-init="reSizeRow()">
+										                <i class="fa fa-arrows-v fa-lg"></i>
+										            </span>
+										            <span class="upload sp-color-white" style="top: 4px; height: 36px; padding-left: 10px; font-size: 16px;">&nbsp;附件({{arrayFile1.length}}):</span>
+										            <span style="display:inline" class="sp-btn-gray-outline sp-btn-sm upload" v-if="dotype!=0&&routeinfoid!=0">
+										                <span class="upload-tip"></span>
+										                <input id="fileupload" class="upload-file-single" v-click="upload()" type="file" name="files[]" multiple>
+										                <i class="fa fa-plus sp-color-white"></i>
+										                <span class="upload-loading" v-if="uploading"><i class="fa fa-spinner fa-pulse sp-fs-20"></i></span>
+										            </span>
+										            <div v-for="item in arrayFile1" ng-if="$index<3" style="width: calc((100% - 250px)/ 3); vertical-align: middle; display: inline-block; color: #fff; cursor: pointer; margin-left: 10px; padding-top: 5px; ">
+										                <span ng-bind="item.FILENAMES" title="{{item.FILENAMES}}" style="display: inline-block; max-width: calc(100% - 40px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap;" ng-click="goAttach(item)"></span>
+										                <a class="sp-pull-right sp-ml-10" ng-click="deleteFile(item)" title="删除" ng-if="dotype!=0">
+										                    <img src="../../flowchart_app_imgcss/img/attachlist/delete.png" title="删除" />
+										                </a>
+										                <a class="sp-pull-right" ng-click="downLoad(item)" title="下载">
+										                    <img src="../../flowchart_app_imgcss/img/attachlist/download.png" title="下载" />
+										                </a>
+										            </div>
+										            <span id="toggleButton" style="width: 20px; height: 20px; display: inline; float: right; margin-right: 15px; margin-top: 5px; cursor: pointer; " ng-if="arrayFile1.length>3" onclick="showToggle(this)">
+										                <i class="fa fa-chevron-up" style="position: relative; display: none"></i>
+										                <i class="fa fa-chevron-down" style="position: relative;"></i>
+										            </span>
+										            <div id="selectDiv" class="sp-page" style="width: 50%; display: none; top: 0px; right: 0; position: absolute; padding: 5px 10px; background: #0099FF; border: 1px solid #0099FF; z-index: 2">
+										                <div v-for="item in arrayFile1" ng-if="$index>2" style="padding: 5px 0; cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;">
+										                    <span ng-bind="item.FILENAMES" title="{{item.FILENAMES}}" ng-click="goAttach(item)"></span>
+										                    <a ng-click="downLoad(item)" title="下载">
+										                        <img src="../../flowchart_app_imgcss/img/attachlist/download.png" title="下载" />
+										                    </a>
+										                    <a ng-click="deleteFile(item)" title="删除" ng-if="dotype!=0">
+										                        <img src="../../flowchart_app_imgcss/img/attachlist/delete.png" title="删除" />
+										                    </a>
+										                </div>
+										            </div>
+										        </div>
+										        <div class="sp-page sp-bg-white" style="width: 100%; height: calc(100% - 40px); padding: 0px; margin: 0px; border: 0px solid black;">
+										            <iframe id="attachlist" src="" style="width:100%;height:200px;padding:0px;margin:0px;border:0px solid red;" frameborder="0" scrolling="no"></iframe>
+										        </div>
+										    </div>
+										    <div class="sp-page-col" style="width: 10px; height: 46px; background: #d0d0d0; position: absolute;right: -10px; top: 0px; z-index: 5; padding: 0px; cursor: pointer; border:0px solid yellow" onclick="showRight(this)">
+										        <i class="fa fa-angle-left fa-2x" style="position: absolute; top: 50%; transform: translateY(-50%); display: none"></i>
+										        <i class="fa fa-angle-right fa-2x" style="position: absolute; top: 50%; transform: translateY(-50%)"></i>
+										    </div>
+										</div>
+										<!-- right -->
+										<div class="page-item rightBox" style="width: 30%; padding-left: 20px;">
+										    <div id="bodyDiv" class="iframe-border-right" style="border:0px solid blue; z-index:3" ng-init="reSize(1)"></div>
+										    <div class="sp-page formedit sp-pb-20">               
+										        <div class="sp-page sp-mt-10">
+										            <div class="sp-page-col pointer" onclick="toggleForm(this)">
+										                <i class="fa fa-angle-down fa-lg"></i>
+										                <i class="fa fa-angle-right fa-lg" style="display: none"></i>
+										                收文简表
+										            </div>
+										            <div class="sp-line-gray"></div>
+										        </div>
+														<div class="form-item" ng-if="!hide('show','CPSX')">
+														    <div class="sp-col-30" style="line-height:32px;" title="呈批时限">呈批时限:</div>
+														    <div class="sp-col-70">
+														        <input type="text" class="sp-input laydate-logo" sp-laydate ng-model="data.CPSX" ng-disabled="hide('readonly','CPSX')" ng-change="changeFiled('CPSX')" />
+														    </div>
+														</div>
+										        <div class="form-item" ng-if="!hide('show','BT')">
+										            <div class="sp-col-30" style="line-height:32px;" title="公文标题">公文标题:</div>
+										            <div class="sp-col-70">
+										                 <textarea class="sp-textarea" ng-model="data.BT" ng-readonly="hide('readonly','BT')" rows="5" style="resize: none" sp-required ng-change="changeFiled('BT')" title="{{data.BT}}" ng-blur="verify('BT')"></textarea>
+										            </div>
+										        </div>
+										        <div class="form-item" ng-if="!hide('show','LWDW')">
+										            <div class="sp-col-30" style="line-height:32px;" title="来文单位">来文单位:</div>
+										            <div class="sp-col-70">
+										                <input type="text" class="sp-input sp-pull-left" style="width:90%" ng-model="data.LWDW" readonly sp-required ng-click="openLWDW()" />
+										                <span class="sp-page-col sp-text-center" style="width:10%;line-height:32px;cursor:pointer" ng-click="setLWDW(0)"><i class="fa fa-cog"></i></span>
+										            </div>
+										        </div>
+										        <div class="form-item" ng-if="!hide('show','LWWH')">
+										            <div class="sp-col-30" style="line-height:32px;" title="文号">文&nbsp;&nbsp;号:</div>
+										            <div class="sp-col-70">
+										                <input type="text" class="sp-input" ng-model="data.LWWH" ng-readonly="hide('readonly','LWWH')" ng-change="changeFiled('LWWH')" />
+										            </div>
+										        </div>
+										        <div class="sp-page toggleForm">
+										            <div class="form-item" ng-if="!hide('show','LWRQ')">
+										                <div class="sp-col-30" style="line-height:32px;" title="来文日期">来文日期:</div>
+										                <div class="sp-col-70">
+										                    <input type="text" class="sp-input laydate-logo" sp-laydate ng-model="data.LWRQ" ng-disabled="hide('readonly','LWRQ')" sp-required ng-change="changeFiled('LWRQ')" />
+										                </div>
+										            </div>
+																<div class="form-item" ng-if="!hide('show','SWLB')">
+																	<div class="sp-col-30" style="line-height:32px;" title="收文类别">收文类别</div>
+																	<div class="sp-col-70">
+																		<select class="sp-select" ng-model="data.SWLB" ng-disabled="hide('readonly','SWLB')" ng-change="changeFiled('SWLB')">
+																			<option v-for="item in SWLB" value="{{item.CODE}}" ng-bind="item.CNAME"></option>
+																		</select>
+																		</div>
+																</div>
+										            <div class="form-item" ng-if="!hide('show','MIJI')">
+										                <div class="sp-col-30" style="line-height:32px;" title="密级">密&nbsp;&nbsp;级:</div>
+										                <div class="sp-col-70">
+										                    <select class="sp-select" ng-model="data.MIJI" ng-disabled="hide('readonly','MIJI')" ng-change="changeFiled('MIJI')">
+										                        <option v-for="item in MIJI" value="{{item.CODE}}" ng-bind="item.CNAME"></option>
+										                    </select>
+										                </div>
+										            </div>
+										            <div class="form-item" ng-if="!hide('show','JJCD')">
+										                <div class="sp-col-30" style="line-height:32px;" title="紧急情况">紧急情况:</div>
+										                <div class="sp-col-70">
+										                    <select class="sp-select" ng-model="data.JJCD" ng-disabled="hide('readonly','JJCD')" sp-required ng-change="changeFiled('JJCD')">
+										                        <option v-for="item in JJCD" value="{{item.CODE}}" ng-bind="item.CNAME"></option>
+										                    </select>
+										                </div>
+										            </div>
+										            <div class="form-item" ng-if="!hide('show','SWBH')">
+										                <div class="sp-col-30" style="line-height:32px;" title="收文编号">收文编号:</div>
+										                <div class="sp-col-70">
+										                    <input type="text" class="sp-input" ng-model="data.SWBH" ng-readonly="hide('readonly','SWBH')" ng-change="changeFiled('SWBH')" />
+										                </div>
+										            </div>
+										            <div class="form-item" ng-if="!hide('show','SFDB')">
+										                <div class="sp-col-30" style="line-height:32px;" title="是否督办">是否督办:</div>
+										                <div class="sp-col-70">
+										                    <select class="sp-select" ng-model="data.SFDB" ng-disabled="hide('readonly','SFDB')" ng-change="changeFiled('SFDB')">
+										                        <option v-for="item in SFDB" value="{{item.CODE}}" ng-bind="item.CNAME" ng-selected="item.CODE==data.SFDB"></option>
+										                    </select>
+										                </div>
+										            </div>
+										            <div class="form-item" ng-if="!hide('show','DBLX')&&data.SFDB=='C01'">
+										                <div class="sp-col-30" style="line-height:32px;" title="督办类型">督办类型:</div>
+										                <div class="sp-col-70">
+										                    <select class="sp-select" ng-model="data.DBLX" ng-disabled="hide('readonly','DBLX')" ng-change="changeFiled('DBLX')">
+										                        <option v-for="item in DBTYPE" value="{{item.CODE}}" ng-bind="item.CNAME"></option>
+										                    </select>
+										                </div>
+										            </div>
+										            <div class="form-item" ng-if="!hide('show','DBSX')">
+										                <div class="sp-col-30" style="line-height:32px;" title="{{data.SWQXLX}}时限">{{data.SWQXLX}}时限:</div>
+										                <div class="sp-col-70">
+										                    <input type="text" class="sp-input laydate-logo" sp-laydate ng-model="data.DBSX" ng-disabled="hide('readonly','DBSX')" ng-change="changeFiled('DBSX')" />
+										                </div>
+										            </div>
+										            <div class="form-item" ng-if="!hide('show','ZBCS')">
+										                <div class="sp-col-30" style="line-height:32px;" title="主办处室">主办处室:</div>
+										                <div class="sp-col-70">
+										                    <input type="text" class="sp-input" readonly ng-model="data.ZBCS" ng-click="openDpList('ZBCS')" />
+										                </div>
+										            </div>
+										            <div class="form-item" ng-if="!hide('show','CDCS')">
+										                <div class="sp-col-30" style="line-height:32px;" title="存档处室">存档处室:</div>
+										                <div class="sp-col-70">
+										                    <input type="text" class="sp-input" readonly ng-model="data.CDCS" ng-click="openDpList('CDCS')" />
+										                </div>
+										            </div>
+										            <div class="form-item" ng-if="!hide('show','SFBJ')">
+										                <div class="sp-col-30" style="line-height:32px;" title="是否办结">是否办结:</div>
+										                <div class="sp-col-70">
+										                    <select class="sp-select" ng-model="data.SFBJ" ng-disabled="hide('readonly','SFBJ')" ng-change="changeFiled('SFBJ')">
+										                        <option v-for="item in SFBJ" value="{{item.CODE}}" ng-bind="item.CNAME"></option>
+										                    </select>
+										                </div>
+										            </div>
+										            <div class="form-item" ng-if="!hide('show','BJQK')">
+										                <div class="sp-col-30" style="line-height:32px;" title="办结情况">办结情况:</div>
+										                <div class="sp-col-70">
+										                    <textarea class="sp-textarea" ng-model="data.BJQK" ng-readonly="hide('readonly','BJQK')" ng-change="changeFiled('BJQK')" title="{{data.BJQK}}" rows="5" style="resize:none;"></textarea>
+										                </div>
+										            </div>
+										            <div class="form-item" ng-if="!hide('show','BZ')">
+										                <div class="sp-col-30" style="line-height:32px;" title="备注">备&nbsp;&nbsp;注:</div>
+										                <div class="sp-col-70">
+										                    <textarea class="sp-textarea" ng-model="data.BZ" ng-readonly="hide('readonly','BZ')" ng-change="changeFiled('BZ')" title="{{data.BZ}}" rows="5" style="resize:none;"></textarea>
+										                </div>
+										            </div>
+										            <div class="form-item" ng-if="!hide('show','NGR')">
+										                <div class="sp-col-30" style="line-height:32px;" title="登记人">登记人:</div>
+										                <div class="sp-col-70">
+										                    <input type="text" class="sp-input" ng-model="data.NGR" ng-readonly="hide('readonly','NGR')" ng-change="changeFiled('NGR')" />
+										                </div>
+										            </div>
+										            <div class="form-item" ng-if="!hide('show','ZBRQ')">
+										                <div class="sp-col-30" style="line-height:32px;" title="登记日期">登记日期:</div>
+										                <div class="sp-col-70">
+										                    <input type="text" class="sp-input laydate-logo" sp-laydate ng-model="data.ZBRQ" ng-disabled="hide('readonly','ZBRQ')" ng-change="changeFiled('ZBRQ')" />
+										                </div>
+										            </div>
+										        </div>
+										        <div class="sp-page sp-mt-10">
+										            公文标签
+										            <div class="sp-line-gray"></div>
+										        </div>
+										        <div class="form-item" ng-if="!hide('show','USAGE')">
+										            <div class="sp-checkbox-blue">
+										                <label v-for="item in USAGE" ng-if="item.USAGE=='1'||(item.USAGE=='0'&&data.USAGE.indexOf(item.CODE)>=0)" sp-checkbox-blue-item>
+										                    <input type="checkbox" name="USAGE" ng-checked="item.checked" ng-disabled="hide('readonly','USAGE')||item.USAGE=='0'"
+										                           value="{{item.CODE}}" ng-click="selectUSAGE(item)" />
+										                    {{item.CNAME}}
+										                </label>
+										            </div>
+										        </div>
+										        <div class="qianzi" v-for="item in YJ.nulla">
+										            <div class="sp-col-100">
+										                <div class="sp-page" style="padding:10px 5px;border:1px solid #999;">
+										                    <div class="sp-page">
+										                        <p class="sp-page sp-text-left" ng-bind-html="item.OPINION | trustHtml"></p>
+										                        <div class="sp-page">
+										                            <div class="sp-page">
+										                                <div v-for="item in item.FILEDATA" style="width: 135px; display: inline-block; cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; position: relative; top: 5px; margin-left: 10px">
+										                                    <a ng-click="downLoadOption(item)" title="下载">
+										                                        <i class="fa fa-download sp-color-red"></i>
+										                                    </a>
+										                                    <a ng-click="deleteOptionFile(item)" title="删除" ng-if="item.ROUTEID==routeid">
+										                                        <i class="fa fa-trash sp-color-red"></i>
+										                                    </a>
+										                                    <span ng-bind="item.FILENAME" title="{{item.FILENAME}}"></span>
+										                                </div>
+										                                <div style="display: inline-block; position: relative; margin-left: 10px; line-height: 40px;" ng-if="item.ROUTEID==routeid&&opinion.nulla==false&&dotype==1">
+										                                    <span class="opbtn" style="position: relative; color: #1c84c6">
+										                                        <span class="upload-tip"></span>
+										                                        <input id="fileupload2" class="upload-file-single" ng-click="upload2(item.COLID)" type="file" name="files[]" multiple>
+										                                        <i class="fa fa-upload"></i>
+										                                        <span class="upload-loading" ng-if="uploading1"><i class="fa fa-spinner fa-pulse sp-fs-20"></i></span>
+										                                    </span>
+										                                </div>
+										                            </div>
+										                            <div class="sp-page sp-text-right sp-pull-right">
+										                                <span ng-bind="item.CMANNAME"></span>
+										                                <span ng-bind="item.CDATE"></span>
+										                            </div>
+										                        </div>
+										                    </div>
+										                    <div class="sp-page sp-text-right">
+										                        <span class="opbtn" style="color: #FF6F6F; width: 55px; "
+										                              ng-click="Dopinion(item)" ng-if="item.ROUTEID==routeid&&opinion.nulla==false&&dotype==1">
+										                            <i class="fa fa-trash-o fa-lg"></i>
+										                        </span>
+										                        <span class="opbtn" style="color: #66D151; width: 55px; "
+										                              ng-click="changeOptionList(item)" ng-if="item.ROUTEID==routeid&&opinion.nulla==false&&dotype==1">
+										                            <i class="fa fa-pencil fa-lg"></i>
+										                        </span>
+										                    </div>
+										                </div>
+										            </div>
+										        </div>
+										    </div>
+										    <div class="sp-page sp-pt-10" style="width: calc(100% - 20px); max-width: 1100px; height: 10px; background: #F0F9FF; box-shadow: 0 -2px 5px #c3c3c3; position: absolute; bottom: 0;right:2px; z-index: 11">
+										        <div class="sp-page-col toggle" style="width: 50px; height: 17px; font-size: 14px; text-align: center; background: #E0E0E0; cursor: pointer; color: #333; position: absolute; right: 0; top: -17px; border-radius: 10px 10px 0 0; " onclick="toggleYJL(this)">
+										            <i class="fa fa-angle-double-up fa-lg"></i>
+										            <i class="fa fa-angle-double-down fa-lg" style="display: none"></i>
+										        </div>
+										        <div class="sp-page-center" style="height: 100%; line-height: 30px; background: #fff; overflow: hidden; ">
+										            <div class="sp-page-col sp-ml-10" ng-if="opinionList1.length>1">
+										                类型:<select class="sp-select sp-pull-right" style="width:100px" ng-model="opiniontype">
+										                    <option :value="{{item.col}}" v-for="item in opinionList1" ng-if="item.show==true" ng-bind="item.name"></option>
+										                </select>
+										            </div>
+										            <div class="sp-page" ng-if="opinion.nulla==true">
+										                <textarea id="nulla" ng-model="nulla" class="op-textarea sp-mb-5 sp-mt-5"></textarea>
+										                <div class="sp-page sp-pb-5" style="border-bottom:1px solid #999">
+										                    <span class="sp-btn-gray sp-btn-sm sp-btn-radius sp-pull-right" ng-click="closeOptionList()">取消</span>
+										                    <span class="sp-btn-gray sp-btn-sm sp-btn-radius sp-pull-right" ng-click="submitOptionList()">保存</span>
+										                    <span class="sp-btn-gray sp-btn-sm sp-btn-radius sp-pull-right" ng-click="phrase()">常用语</span>
+										                </div>
+										            </div>
+										            <div class="sp-page" ng-if="activeOpinion!=null">
+										                <div style="display: inline-block; float: left; position: relative; margin-left: 10px; line-height: 40px;">
+										                    <span class="opbtn" style="position: relative; color: #1c84c6">
+										                        <span class="upload-tip"></span>
+										                        <input id="fileupload1" class="upload-file-single" ng-click="upload1()" type="file" name="files[]" multiple>
+										                        <i class="fa fa-upload"></i>
+										                        <span class="upload-loading" ng-if="uploading1"><i class="fa fa-spinner fa-pulse sp-fs-20"></i></span>
+										                    </span>
+										                </div>
+										                <div v-for="item in activeOpinion.FILEDATA" style="width: 135px; display: inline-block; cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; position: relative; top: 5px; margin-left: 10px">
+										                    <a ng-click="downLoadOption(item)" title="下载">
+										                        <i class="fa fa-download sp-color-red"></i>
+										                    </a>
+										                    <a ng-click="deleteOptionFile(item)" title="删除" ng-if="item.ROUTEID==routeid">
+										                        <i class="fa fa-trash sp-color-red"></i>
+										                    </a>
+										                    <span ng-bind="item.FILENAME" title="{{item.FILENAME}}"></span>
+										                </div>
+										                <div style="display: inline-block; float: right; position: relative; margin-right: 10px; line-height: 40px;">
+										                    <span class="opbtn" style="color: #FF6F6F; width: 55px; "
+										                          ng-click="Dopinion(activeOpinion)">
+										                        <i class="fa fa-trash-o fa-lg"></i>
+										                    </span>
+										                </div>
+										            </div>
+										        </div>
+										    </div>
+										</div>
+										                                
+										
+									</div>
+							 </div>
+						</div>
+				 </div>
+			</div>
+		</div>
+	</div>
+    <div ng-controller="formeditCtrl as ctl" id="app" ng-cloak>
+        <div class="wrapper wrapper-content">
+            <div class="row">
+                <div class="col-md-12">
+                    <div class="ibox float-e-margins">
+                        <div class="ibox-content">
+                            <div class="row">
+                                <div class="col-md-12">
+                                    <div class="sp-page mousemove" style="position:fixed;z-index:6;background:#c6c6c6;opacity:0.5;display:none"></div>
+                                    <!-- top-->
+																		<div class="sp-box" style="background: #008A94; padding-right: 10px; line-height: 30px; ">
+                                        <div class="sp-page sp-color-white" style="width: 200px; margin: 7px 0; text-indent: 10px" ng-bind="ctl.flowTitle"></div>
+                                        <div class="sp-page-col sp-pull-right sp-ml-30">
+                                            <div class="sp-page-col" ng-repeat="item in ctl.buttonList">
+                                                <button class="sp-md sp-radius sp-mt-5" style="padding: 4px 10px;" ng-class="{'sp-btn-gray':item.CODE.indexOf('SENDITEM')==-1,'sp-btn-blue':item.CODE.indexOf('SENDITEM')!=-1}" ng-click="ctl.btnEvent(item)" ng-if="item.CODE!='array'&&ctl.dotype==1||(ctl.dotype!=1&&item.EXPLAIN=='1')">
+                                                    <img ng-if="item.CODE.indexOf('SAVEITEM')!=-1" src="../../flowchart_app_imgcss/img/bc.png" height="14" />
+                                                    <img ng-if="item.CODE.indexOf('PRINTITEM')!=-1" src="../../flowchart_app_imgcss/img/dy.png" height="14" />
+                                                    <img ng-if="item.CODE.indexOf('SENDITEM')!=-1" src="../../flowchart_app_imgcss/img/zfw.png" height="14" />
+                                                    <img ng-if="item.CODE.indexOf('SENDLOG')!=-1" src="../../flowchart_app_imgcss/img/lz.png" height="14" />
+                                                    {{item.CNAME}}
+                                                </button>
+                                                <button style="padding: 4px 10px; position: relative" class="sp-btn-md sp-radius sp-btn-blue tiaoahao" ng-if="item.CODE=='array'">
+                                                    {{item.CNAME}}
+                                                    <div class="sp-page" style="width:auto;background:#fff;border:1px solid #ccc;position:absolute;top:28px;left:50%;transform:translateX(-50%);z-index:12;display:none">
+                                                        <div class="sp-box sp-text-center" ng-repeat="item1 in item.data">
+                                                            <span class="sp-radius" ng-class="{'sp-btn-gray':item1.CODE.indexOf('SENDITEM')==-1,'sp-btn-blue':item1.CODE.indexOf('SENDITEM')!=-1}" ng-click="ctl.btnEvent(item1)">{{item1.CNAME}}</span>
+                                                        </div>
+                                                    </div>
+                                                </button>
+                                            </div>
+                                            <button style="padding:4px 10px;" class="sp-btn-gray sp-md sp-radius sp-mt-5" onclick="javascript: window.close(); localStorage.setItem('GlWorkPlatform-shouwenbg-refresh', 1)">
+                                                <img src="../../flowchart_app_imgcss/img/fh.png" height="14" />
+                                                关闭
+                                            </button>
+                                        </div>
+                                        <div class="sp-wrapper-head-col sp-mr-20">
+                                            <span class="sp-wrapper-head-col-span" style="padding: 0; border: 1px solid #eee; border-radius: 5px; display: inline-block; line-height: 30px; height: 30px; margin-top: 5px;">
+                                                <i class="icon-map-1 sp-pl-5 pointer" ng-click="ctl.onePic()"></i>
+                                                <input type="text" class="sp-wrapper-head-search" style="border:0" placeholder="地图搜索" ng-model="ctl.headBtnSearchKeyword" ng-change="ctl.headBtnSearch()" />
+                                            </span>
+                                            <div class="sp-wrapper-head-sub-2 sp-text-center" style="width:175px;" ng-if="ctl.headSearchResult_view">
+                                                <div class="sp-lh-26-wrap" ng-repeat="item in ctl.headSearchResult" ng-click="ctl.headKeywordPage(item)"><a ng-bind="item.name" title="{{item.name}}"></a></div>
+                                            </div>
+                                        </div>
+                                        <div class="sp-wrapper-head-col" onclick="$('#attachlist')[0].contentWindow.openTool('../../flfg/bzgf.html', '标准规范');">
+                                            <span class="sp-wrapper-head-col-span">
+                                                <i class="icon-book"></i>标准规范
+                                            </span>
+                                        </div>
+                                        <div class="sp-wrapper-head-col" onclick="$('#attachlist')[0].contentWindow.openTool('../../flfg/flgf.html', '法律法规');">
+                                            <span class="sp-wrapper-head-col-span">
+                                                <i class="fa fa-legal"></i>法律法规
+                                            </span>
+                                        </div>
+                                        <div class="sp-wrapper-head-col" onclick="$('#attachlist')[0].contentWindow.openTool('../../flfg/dnfg.html', '党内规范');">
+                                            <span class="sp-wrapper-head-col-span">
+                                                <i class="icon-newspaper-1"></i>党内规范
+                                            </span>
+                                        </div>
+                                        <div class="sp-wrapper-head-col" onclick="$('#attachlist')[0].contentWindow.openTool('../../fontOA/list.html', '公文查询');">
+                                            <span class="sp-wrapper-head-col-span">
+                                                <i class="icon-chart-alt-outline"></i>公文查询
+                                            </span>
+                                        </div>
+                                    </div>
+																		<!-- left -->
+                                    <div class="page-item leftBox" style="width: 70%; overflow: visible;">
+                                        <div id="topDiv" class="sp-box" style="width:100%;height:100%;background:#0099FF;padding:0px;margin:0px;border:0px solid yellow">
+                                            <div class="sp-page" style="width:100%; padding:2px;margin:2px">
+                                                <span class="upload sp-color-white" style="top:5px;height:36px;vertical-align:middle;padding-left:10px;font-size:16px">正文:</span>
+                                                <span style="display:inline-block" class="sp-btn-gray-outline sp-btn-sm upload" ng-if="ctl.dotype!=0&&ctl.arrayFile==null">
+                                                    <span class="upload-tip"></span>
+                                                    <input id="fileupload-zw" class="upload-file-single" ng-click="ctl.upload_zw()" type="file" name="files[]" multiple>
+                                                    <i class="fa fa-plus sp-color-white"></i>
+                                                    <span class="upload-loading" ng-if="ctl.uploading_zw"><i class="fa fa-spinner fa-pulse sp-fs-20"></i></span>
+                                                </span>
+                                                <div ng-if="ctl.arrayFile!=null" style="width: 350px; color: #fff; display: inline-block; cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; position: relative; top: 5px; margin-left: 10px">
+                                                    <span ng-bind="ctl.arrayFile.FILENAMES" title="{{ctl.arrayFile.FILENAMES}}" ng-click="ctl.seeFile(ctl.arrayFile)"></span>
+                                                    <a ng-click="ctl.downLoad(ctl.arrayFile)" title="下载">
+                                                        <img src="../../flowchart_app_imgcss/img/attachlist/download.png" title="下载" />
+                                                    </a>
+                                                    <!--<a ng-click="ctl.deleteFile(ctl.arrayFile)" title="删除" ng-if="ctl.dotype!=0"><i class="fa fa-trash sp-color-red"></i></a>-->
+                                                </div>
+                                            </div>
+                                            <div class="sp-page sp-bg-white" style="height:100%;padding:0px; margin:0px;border:0px solid black;">
+                                                <iframe id="iframe_book" style="width:100%;height:600px;background-color:white;padding:0px; margin:0px; border:0px solid red" frameborder="0" class="iframe" scrolling="no"></iframe>
+                                            </div>
+                                        </div>
+                                        <div id="bottomDiv" class="sp-box" style="width: 100%; background: #0099FF; color: #fff;padding:0px;margin:0px; border:0px solid green">
+                                            <div class="sp-page" style="width: 100%; vertical-align: middle; padding: 2px; margin: 2px; ">
+                                                <span id="lineDiv" class="upload sp-color-white" style="top: 0; height: 36px; padding-left: 10px; padding-top: 5px; font-size: 16px; cursor: ns-resize; " ng-init="ctl.reSizeRow()">
+                                                    <i class="fa fa-arrows-v fa-lg"></i>
+                                                </span>
+                                                <span class="upload sp-color-white" style="top: 4px; height: 36px; padding-left: 10px; font-size: 16px;">&nbsp;附件({{ctl.arrayFile1.length}}):</span>
+                                                <span style="display:inline" class="sp-btn-gray-outline sp-btn-sm upload" ng-if="ctl.dotype!=0&&ctl.routeinfoid!=0">
+                                                    <span class="upload-tip"></span>
+                                                    <input id="fileupload" class="upload-file-single" ng-click="ctl.upload()" type="file" name="files[]" multiple>
+                                                    <i class="fa fa-plus sp-color-white"></i>
+                                                    <span class="upload-loading" ng-if="ctl.uploading"><i class="fa fa-spinner fa-pulse sp-fs-20"></i></span>
+                                                </span>
+                                                <div ng-repeat="item in ctl.arrayFile1" ng-if="$index<3" style="width: calc((100% - 250px)/ 3); vertical-align: middle; display: inline-block; color: #fff; cursor: pointer; margin-left: 10px; padding-top: 5px; ">
+                                                    <span ng-bind="item.FILENAMES" title="{{item.FILENAMES}}" style="display: inline-block; max-width: calc(100% - 40px); overflow: hidden; text-overflow: ellipsis; white-space: nowrap;" ng-click="ctl.goAttach(item)"></span>
+                                                    <a class="sp-pull-right sp-ml-10" ng-click="ctl.deleteFile(item)" title="删除" ng-if="ctl.dotype!=0">
+                                                        <img src="../../flowchart_app_imgcss/img/attachlist/delete.png" title="删除" />
+                                                    </a>
+                                                    <a class="sp-pull-right" ng-click="ctl.downLoad(item)" title="下载">
+                                                        <img src="../../flowchart_app_imgcss/img/attachlist/download.png" title="下载" />
+                                                    </a>
+                                                </div>
+                                                <span id="toggleButton" style="width: 20px; height: 20px; display: inline; float: right; margin-right: 15px; margin-top: 5px; cursor: pointer; " ng-if="ctl.arrayFile1.length>3" onclick="showToggle(this)">
+                                                    <i class="fa fa-chevron-up" style="position: relative; display: none"></i>
+                                                    <i class="fa fa-chevron-down" style="position: relative;"></i>
+                                                </span>
+                                                <div id="selectDiv" class="sp-page" style="width: 50%; display: none; top: 0px; right: 0; position: absolute; padding: 5px 10px; background: #0099FF; border: 1px solid #0099FF; z-index: 2">
+                                                    <div ng-repeat="item in ctl.arrayFile1" ng-if="$index>2" style="padding: 5px 0; cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;">
+                                                        <span ng-bind="item.FILENAMES" title="{{item.FILENAMES}}" ng-click="ctl.goAttach(item)"></span>
+                                                        <a ng-click="ctl.downLoad(item)" title="下载">
+                                                            <img src="../../flowchart_app_imgcss/img/attachlist/download.png" title="下载" />
+                                                        </a>
+                                                        <a ng-click="ctl.deleteFile(item)" title="删除" ng-if="ctl.dotype!=0">
+                                                            <img src="../../flowchart_app_imgcss/img/attachlist/delete.png" title="删除" />
+                                                        </a>
+                                                    </div>
+                                                </div>
+                                            </div>
+                                            <div class="sp-page sp-bg-white" style="width: 100%; height: calc(100% - 40px); padding: 0px; margin: 0px; border: 0px solid black;">
+                                                <iframe id="attachlist" src="" style="width:100%;height:200px;padding:0px;margin:0px;border:0px solid red;" frameborder="0" scrolling="no"></iframe>
+                                            </div>
+                                        </div>
+                                        <div class="sp-page-col" style="width: 10px; height: 46px; background: #d0d0d0; position: absolute;right: -10px; top: 0px; z-index: 5; padding: 0px; cursor: pointer; border:0px solid yellow" onclick="showRight(this)">
+                                            <i class="fa fa-angle-left fa-2x" style="position: absolute; top: 50%; transform: translateY(-50%); display: none"></i>
+                                            <i class="fa fa-angle-right fa-2x" style="position: absolute; top: 50%; transform: translateY(-50%)"></i>
+                                        </div>
+                                    </div>
+																		<!-- right -->
+                                    <div class="page-item rightBox" style="width: 30%; padding-left: 20px;">
+                                        <div id="bodyDiv" class="iframe-border-right" style="border:0px solid blue; z-index:3" ng-init="ctl.reSize(1)"></div>
+                                        <div class="sp-page formedit sp-pb-20">               
+                                            <div class="sp-page sp-mt-10">
+                                                <div class="sp-page-col pointer" onclick="toggleForm(this)">
+                                                    <i class="fa fa-angle-down fa-lg"></i>
+                                                    <i class="fa fa-angle-right fa-lg" style="display: none"></i>
+                                                    收文简表
+                                                </div>
+                                                <div class="sp-line-gray"></div>
+                                            </div>
+																						<div class="form-item" ng-if="!ctl.hide('show','CPSX')">
+																						    <div class="sp-col-30" style="line-height:32px;" title="呈批时限">呈批时限:</div>
+																						    <div class="sp-col-70">
+																						        <input type="text" class="sp-input laydate-logo" sp-laydate ng-model="ctl.data.CPSX" ng-disabled="ctl.hide('readonly','CPSX')" ng-change="ctl.changeFiled('CPSX')" />
+																						    </div>
+																						</div>
+                                            <div class="form-item" ng-if="!ctl.hide('show','BT')">
+                                                <div class="sp-col-30" style="line-height:32px;" title="公文标题">公文标题:</div>
+                                                <div class="sp-col-70">
+                                                    <!--<input type="text" class="sp-input" ng-model="ctl.data.BT" ng-disabled="ctl.hide('readonly','BT')" ng-change="ctl.changeFiled('BT')" ng-blur="ctl.verify('BT')" />-->
+                                                    <textarea class="sp-textarea" ng-model="ctl.data.BT" ng-readonly="ctl.hide('readonly','BT')" rows="5" style="resize: none" sp-required ng-change="ctl.changeFiled('BT')" title="{{ctl.data.BT}}" ng-blur="ctl.verify('BT')"></textarea>
+                                                </div>
+                                            </div>
+                                            <div class="form-item" ng-if="!ctl.hide('show','LWDW')">
+                                                <div class="sp-col-30" style="line-height:32px;" title="来文单位">来文单位:</div>
+                                                <div class="sp-col-70">
+                                                    <!--<input type="text" class="sp-input sp-pull-left" ng-model="ctl.data.LWDW" readonly ng-click="ctl.openLWDW()" />-->
+                                                    <input type="text" class="sp-input sp-pull-left" style="width:90%" ng-model="ctl.data.LWDW" readonly sp-required ng-click="ctl.openLWDW()" />
+                                                    <span class="sp-page-col sp-text-center" style="width:10%;line-height:32px;cursor:pointer" ng-click="ctl.setLWDW(0)"><i class="fa fa-cog"></i></span>
+                                                </div>
+                                            </div>
+                                            <div class="form-item" ng-if="!ctl.hide('show','LWWH')">
+                                                <div class="sp-col-30" style="line-height:32px;" title="文号">文&nbsp;&nbsp;号:</div>
+                                                <div class="sp-col-70">
+                                                    <input type="text" class="sp-input" ng-model="ctl.data.LWWH" ng-readonly="ctl.hide('readonly','LWWH')" ng-change="ctl.changeFiled('LWWH')" />
+                                                </div>
+                                            </div>
+                                            <div class="sp-page toggleForm">
+                                                <div class="form-item" ng-if="!ctl.hide('show','LWRQ')">
+                                                    <div class="sp-col-30" style="line-height:32px;" title="来文日期">来文日期:</div>
+                                                    <div class="sp-col-70">
+                                                        <input type="text" class="sp-input laydate-logo" sp-laydate ng-model="ctl.data.LWRQ" ng-disabled="ctl.hide('readonly','LWRQ')" sp-required ng-change="ctl.changeFiled('LWRQ')" />
+                                                    </div>
+                                                </div>
+																								<div class="form-item" ng-if="!ctl.hide('show','SWLB')">
+																									<div class="sp-col-30" style="line-height:32px;" title="收文类别">收文类别</div>
+																									<div class="sp-col-70">
+																										<select class="sp-select" ng-model="ctl.data.SWLB" ng-disabled="ctl.hide('readonly','SWLB')" ng-change="ctl.changeFiled('SWLB')">
+																											<option ng-repeat="item in ctl.SWLB" value="{{item.CODE}}" ng-bind="item.CNAME"></option>
+																										</select>
+																										</div>
+																								</div>
+                                                <div class="form-item" ng-if="!ctl.hide('show','MIJI')">
+                                                    <div class="sp-col-30" style="line-height:32px;" title="密级">密&nbsp;&nbsp;级:</div>
+                                                    <div class="sp-col-70">
+                                                        <select class="sp-select" ng-model="ctl.data.MIJI" ng-disabled="ctl.hide('readonly','MIJI')" ng-change="ctl.changeFiled('MIJI')">
+                                                            <option ng-repeat="item in ctl.MIJI" value="{{item.CODE}}" ng-bind="item.CNAME"></option>
+                                                        </select>
+                                                    </div>
+                                                </div>
+                                                <div class="form-item" ng-if="!ctl.hide('show','JJCD')">
+                                                    <div class="sp-col-30" style="line-height:32px;" title="紧急情况">紧急情况:</div>
+                                                    <div class="sp-col-70">
+                                                        <select class="sp-select" ng-model="ctl.data.JJCD" ng-disabled="ctl.hide('readonly','JJCD')" sp-required ng-change="ctl.changeFiled('JJCD')">
+                                                            <option ng-repeat="item in ctl.JJCD" value="{{item.CODE}}" ng-bind="item.CNAME"></option>
+                                                        </select>
+                                                    </div>
+                                                </div>
+                                                <div class="form-item" ng-if="!ctl.hide('show','SWBH')">
+                                                    <div class="sp-col-30" style="line-height:32px;" title="收文编号">收文编号:</div>
+                                                    <div class="sp-col-70">
+                                                        <input type="text" class="sp-input" ng-model="ctl.data.SWBH" ng-readonly="ctl.hide('readonly','SWBH')" ng-change="ctl.changeFiled('SWBH')" />
+                                                    </div>
+                                                </div>
+                                                <div class="form-item" ng-if="!ctl.hide('show','SFDB')">
+                                                    <div class="sp-col-30" style="line-height:32px;" title="是否督办">是否督办:</div>
+                                                    <div class="sp-col-70">
+                                                        <select class="sp-select" ng-model="ctl.data.SFDB" ng-disabled="ctl.hide('readonly','SFDB')" ng-change="ctl.changeFiled('SFDB')">
+                                                            <option ng-repeat="item in ctl.SFDB" value="{{item.CODE}}" ng-bind="item.CNAME" ng-selected="item.CODE==ctl.data.SFDB"></option>
+                                                        </select>
+                                                    </div>
+                                                </div>
+                                                <div class="form-item" ng-if="!ctl.hide('show','DBLX')&&ctl.data.SFDB=='C01'">
+                                                    <div class="sp-col-30" style="line-height:32px;" title="督办类型">督办类型:</div>
+                                                    <div class="sp-col-70">
+                                                        <select class="sp-select" ng-model="ctl.data.DBLX" ng-disabled="ctl.hide('readonly','DBLX')" ng-change="ctl.changeFiled('DBLX')">
+                                                            <option ng-repeat="item in ctl.DBTYPE" value="{{item.CODE}}" ng-bind="item.CNAME"></option>
+                                                        </select>
+                                                    </div>
+                                                </div>
+                                                <div class="form-item" ng-if="!ctl.hide('show','DBSX')">
+                                                    <div class="sp-col-30" style="line-height:32px;" title="{{ctl.data.SWQXLX}}时限">{{ctl.data.SWQXLX}}时限:</div>
+                                                    <div class="sp-col-70">
+                                                        <input type="text" class="sp-input laydate-logo" sp-laydate ng-model="ctl.data.DBSX" ng-disabled="ctl.hide('readonly','DBSX')" ng-change="ctl.changeFiled('DBSX')" />
+                                                    </div>
+                                                </div>
+                                                <div class="form-item" ng-if="!ctl.hide('show','ZBCS')">
+                                                    <div class="sp-col-30" style="line-height:32px;" title="主办处室">主办处室:</div>
+                                                    <div class="sp-col-70">
+                                                        <input type="text" class="sp-input" readonly ng-model="ctl.data.ZBCS" ng-click="ctl.openDpList('ZBCS')" />
+                                                    </div>
+                                                </div>
+                                                <div class="form-item" ng-if="!ctl.hide('show','CDCS')">
+                                                    <div class="sp-col-30" style="line-height:32px;" title="存档处室">存档处室:</div>
+                                                    <div class="sp-col-70">
+                                                        <input type="text" class="sp-input" readonly ng-model="ctl.data.CDCS" ng-click="ctl.openDpList('CDCS')" />
+                                                    </div>
+                                                </div>
+                                                <div class="form-item" ng-if="!ctl.hide('show','SFBJ')">
+                                                    <div class="sp-col-30" style="line-height:32px;" title="是否办结">是否办结:</div>
+                                                    <div class="sp-col-70">
+                                                        <select class="sp-select" ng-model="ctl.data.SFBJ" ng-disabled="ctl.hide('readonly','SFBJ')" ng-change="ctl.changeFiled('SFBJ')">
+                                                            <option ng-repeat="item in ctl.SFBJ" value="{{item.CODE}}" ng-bind="item.CNAME"></option>
+                                                        </select>
+                                                    </div>
+                                                </div>
+                                                <div class="form-item" ng-if="!ctl.hide('show','BJQK')">
+                                                    <div class="sp-col-30" style="line-height:32px;" title="办结情况">办结情况:</div>
+                                                    <div class="sp-col-70">
+                                                        <textarea class="sp-textarea" ng-model="ctl.data.BJQK" ng-readonly="ctl.hide('readonly','BJQK')" ng-change="ctl.changeFiled('BJQK')" title="{{ctl.data.BJQK}}" rows="5" style="resize:none;"></textarea>
+                                                    </div>
+                                                </div>
+                                                <div class="form-item" ng-if="!ctl.hide('show','BZ')">
+                                                    <div class="sp-col-30" style="line-height:32px;" title="备注">备&nbsp;&nbsp;注:</div>
+                                                    <div class="sp-col-70">
+                                                        <textarea class="sp-textarea" ng-model="ctl.data.BZ" ng-readonly="ctl.hide('readonly','BZ')" ng-change="ctl.changeFiled('BZ')" title="{{ctl.data.BZ}}" rows="5" style="resize:none;"></textarea>
+                                                    </div>
+                                                </div>
+                                                <div class="form-item" ng-if="!ctl.hide('show','NGR')">
+                                                    <div class="sp-col-30" style="line-height:32px;" title="登记人">登记人:</div>
+                                                    <div class="sp-col-70">
+                                                        <input type="text" class="sp-input" ng-model="ctl.data.NGR" ng-readonly="ctl.hide('readonly','NGR')" ng-change="ctl.changeFiled('NGR')" />
+                                                    </div>
+                                                </div>
+                                                <div class="form-item" ng-if="!ctl.hide('show','ZBRQ')">
+                                                    <div class="sp-col-30" style="line-height:32px;" title="登记日期">登记日期:</div>
+                                                    <div class="sp-col-70">
+                                                        <input type="text" class="sp-input laydate-logo" sp-laydate ng-model="ctl.data.ZBRQ" ng-disabled="ctl.hide('readonly','ZBRQ')" ng-change="ctl.changeFiled('ZBRQ')" />
+                                                    </div>
+                                                </div>
+                                            </div>
+                                            <div class="sp-page sp-mt-10">
+                                                公文标签
+                                                <div class="sp-line-gray"></div>
+                                            </div>
+                                            <div class="form-item" ng-if="!ctl.hide('show','USAGE')">
+                                                <div class="sp-checkbox-blue">
+                                                    <label ng-repeat="item in ctl.USAGE" ng-if="item.USAGE=='1'||(item.USAGE=='0'&&ctl.data.USAGE.indexOf(item.CODE)>=0)" sp-checkbox-blue-item>
+                                                        <input type="checkbox" name="USAGE" ng-checked="item.checked" ng-disabled="ctl.hide('readonly','USAGE')||item.USAGE=='0'"
+                                                               value="{{item.CODE}}" ng-click="ctl.selectUSAGE(item)" />
+                                                        {{item.CNAME}}
+                                                    </label>
+                                                    <!--<span class="sp-btn-blue sp-radius" ng-if="!ctl.hide('readonly','USAGE')" ng-click="ctl.ManageUSAGE(0)">管理标签</span>-->
+                                                </div>
+                                            </div>
+                                            <div class="qianzi" ng-repeat="item in ctl.YJ.nulla">
+                                                <div class="sp-col-100">
+                                                    <div class="sp-page" style="padding:10px 5px;border:1px solid #999;">
+                                                        <div class="sp-page">
+                                                            <p class="sp-page sp-text-left" ng-bind-html="item.OPINION | trustHtml"></p>
+                                                            <div class="sp-page">
+                                                                <div class="sp-page">
+                                                                    <div ng-repeat="item in item.FILEDATA" style="width: 135px; display: inline-block; cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; position: relative; top: 5px; margin-left: 10px">
+                                                                        <a ng-click="ctl.downLoadOption(item)" title="下载">
+                                                                            <i class="fa fa-download sp-color-red"></i>
+                                                                        </a>
+                                                                        <a ng-click="ctl.deleteOptionFile(item)" title="删除" ng-if="item.ROUTEID==ctl.routeid">
+                                                                            <i class="fa fa-trash sp-color-red"></i>
+                                                                        </a>
+                                                                        <span ng-bind="item.FILENAME" title="{{item.FILENAME}}"></span>
+                                                                    </div>
+                                                                    <div style="display: inline-block; position: relative; margin-left: 10px; line-height: 40px;" ng-if="item.ROUTEID==ctl.routeid&&ctl.opinion.nulla==false&&ctl.dotype==1">
+                                                                        <span class="opbtn" style="position: relative; color: #1c84c6">
+                                                                            <span class="upload-tip"></span>
+                                                                            <input id="fileupload2" class="upload-file-single" ng-click="ctl.upload2(item.COLID)" type="file" name="files[]" multiple>
+                                                                            <i class="fa fa-upload"></i>
+                                                                            <span class="upload-loading" ng-if="ctl.uploading1"><i class="fa fa-spinner fa-pulse sp-fs-20"></i></span>
+                                                                        </span>
+                                                                    </div>
+                                                                </div>
+                                                                <div class="sp-page sp-text-right sp-pull-right">
+                                                                    <span ng-bind="item.CMANNAME"></span>
+                                                                    <span ng-bind="item.CDATE"></span>
+                                                                </div>
+                                                            </div>
+                                                        </div>
+                                                        <div class="sp-page sp-text-right">
+                                                            <span class="opbtn" style="color: #FF6F6F; width: 55px; "
+                                                                  ng-click="ctl.Dopinion(item)" ng-if="item.ROUTEID==ctl.routeid&&ctl.opinion.nulla==false&&ctl.dotype==1">
+                                                                <i class="fa fa-trash-o fa-lg"></i>
+                                                            </span>
+                                                            <span class="opbtn" style="color: #66D151; width: 55px; "
+                                                                  ng-click="ctl.changeOptionList(item)" ng-if="item.ROUTEID==ctl.routeid&&ctl.opinion.nulla==false&&ctl.dotype==1">
+                                                                <i class="fa fa-pencil fa-lg"></i>
+                                                            </span>
+                                                        </div>
+                                                    </div>
+                                                </div>
+                                            </div>
+                                        </div>
+                                        <div class="sp-page sp-pt-10" style="width: calc(100% - 20px); max-width: 1100px; height: 10px; background: #F0F9FF; box-shadow: 0 -2px 5px #c3c3c3; position: absolute; bottom: 0;right:2px; z-index: 11">
+                                            <div class="sp-page-col toggle" style="width: 50px; height: 17px; font-size: 14px; text-align: center; background: #E0E0E0; cursor: pointer; color: #333; position: absolute; right: 0; top: -17px; border-radius: 10px 10px 0 0; " onclick="toggleYJL(this)">
+                                                <i class="fa fa-angle-double-up fa-lg"></i>
+                                                <i class="fa fa-angle-double-down fa-lg" style="display: none"></i>
+                                            </div>
+                                            <div class="sp-page-center" style="height: 100%; line-height: 30px; background: #fff; overflow: hidden; ">
+                                                <div class="sp-page-col sp-ml-10" ng-if="ctl.opinionList1.length>1">
+                                                    类型:<select class="sp-select sp-pull-right" style="width:100px" ng-model="ctl.opiniontype">
+                                                        <option value="{{item.col}}" ng-repeat="item in ctl.opinionList1" ng-if="item.show==true" ng-bind="item.name"></option>
+                                                    </select>
+                                                </div>
+                                                <div class="sp-page" ng-if="ctl.opinion.nulla==true">
+                                                    <textarea id="nulla" ng-model="ctl.nulla" class="op-textarea sp-mb-5 sp-mt-5"></textarea>
+                                                    <div class="sp-page sp-pb-5" style="border-bottom:1px solid #999">
+                                                        <span class="sp-btn-gray sp-btn-sm sp-btn-radius sp-pull-right" ng-click="ctl.closeOptionList()">取消</span>
+                                                        <span class="sp-btn-gray sp-btn-sm sp-btn-radius sp-pull-right" ng-click="ctl.submitOptionList()">保存</span>
+                                                        <span class="sp-btn-gray sp-btn-sm sp-btn-radius sp-pull-right" ng-click="ctl.phrase()">常用语</span>
+                                                    </div>
+                                                </div>
+                                                <div class="sp-page" ng-if="ctl.activeOpinion!=null">
+                                                    <div style="display: inline-block; float: left; position: relative; margin-left: 10px; line-height: 40px;">
+                                                        <span class="opbtn" style="position: relative; color: #1c84c6">
+                                                            <span class="upload-tip"></span>
+                                                            <input id="fileupload1" class="upload-file-single" ng-click="ctl.upload1()" type="file" name="files[]" multiple>
+                                                            <i class="fa fa-upload"></i>
+                                                            <span class="upload-loading" ng-if="ctl.uploading1"><i class="fa fa-spinner fa-pulse sp-fs-20"></i></span>
+                                                        </span>
+                                                    </div>
+                                                    <div ng-repeat="item in ctl.activeOpinion.FILEDATA" style="width: 135px; display: inline-block; cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; position: relative; top: 5px; margin-left: 10px">
+                                                        <a ng-click="ctl.downLoadOption(item)" title="下载">
+                                                            <i class="fa fa-download sp-color-red"></i>
+                                                        </a>
+                                                        <a ng-click="ctl.deleteOptionFile(item)" title="删除" ng-if="item.ROUTEID==ctl.routeid">
+                                                            <i class="fa fa-trash sp-color-red"></i>
+                                                        </a>
+                                                        <span ng-bind="item.FILENAME" title="{{item.FILENAME}}"></span>
+                                                    </div>
+                                                    <div style="display: inline-block; float: right; position: relative; margin-right: 10px; line-height: 40px;">
+                                                        <span class="opbtn" style="color: #FF6F6F; width: 55px; "
+                                                              ng-click="ctl.Dopinion(ctl.activeOpinion)">
+                                                            <i class="fa fa-trash-o fa-lg"></i>
+                                                        </span>
+                                                    </div>
+                                                </div>
+                                            </div>
+                                        </div>
+                                    </div>
+                                
+																</div>
+                            </div>
+                        </div>
+                    </div>
+                </div>
+            </div>
+        </div>
+        <div class="sp-layer" id="DpList" style="width: 900px;">
+            <div class="sp-layer-head" style="background:#2176d6">
+                <div class="sp-page sp-text-center sp-font16">
+                    部门列表
+                    <div class="sp-layer-close" title="关闭" onclick="sp.closeCenter('.sp-layer')">
+                        ×
+                    </div>
+                </div>
+            </div>
+            <div class="sp-layer-body" ng-class="{'sp-height-400': '{{ctl.deviceType}}' =='pad'}">
+                <div class="sp-page" style="height:290px;overflow:auto">
+                    <label class="sp-col-20">
+                        <input type="checkbox" style="position:relative;top:2px" ng-checked="ctl.AllCheckedDp[ctl.filed]" ng-click="ctl.checkAllDp()" />
+                        全选
+                    </label>
+                    <div class="sp-page">
+                        <label class="sp-col-25" title="{{item.SECTION}}" ng-repeat="item in ctl.DpList[ctl.filed]">
+                            <input type="checkbox" style="position:relative;top:2px" ng-checked="item.checked" ng-click="ctl.checkDpItem(item)" />
+                            {{item.SECTION}}
+                        </label>
+                    </div>
+                </div>
+                <div class="sp-page sp-text-center sp-pt-10">
+                    <a class="sp-btn-blue sp-radius" ng-click="ctl.submitDpList(0)"><i class="fa fa-check sp-mr-5"></i>确 定</a>
+                    <a class="sp-btn-blue sp-radius" onclick="sp.layerhide()"><i class="fa fa-close sp-mr-5"></i>取 消</a>
+                </div>
+            </div>
+        </div>
+        <div class="sp-layer" id="openLWDW" style="width: 900px;">
+            <div class="sp-layer-head" style="background:#2176d6">
+                <div class="sp-page sp-text-center sp-font16">
+                    部门列表
+                    <div class="sp-layer-close" title="关闭" onclick="sp.closeCenter('.sp-layer')">
+                        ×
+                    </div>
+                </div>
+            </div>
+            <div class="sp-layer-body" ng-class="{'sp-height-400': '{{ctl.deviceType}}' =='pad'}">
+                <div class="sp-page" style="height:290px;overflow:auto">
+                    <div class="sp-page" ng-repeat="item in ctl.LWDW">
+                        <div class="sp-box" style="background: #409EFF;color:#fff;text-indent:2em">
+                            {{item.CNAME}}
+                            <span class="sp-pull-right pointer sp-mr-20" ng-click="item.show=!item.show">
+                                <i ng-if="item.show==false" class="fa fa-plus-square-o"></i>
+                                <i ng-if="item.show==true" class="fa fa-minus-square-o"></i>
+                            </span>
+                        </div>
+                        <div class="sp-box">
+                            <label class="sp-col-33" title="{{item1.CNAME}}" ng-repeat="item1 in item.C_H_I_L_D_DATA" ng-if="item.show==true">
+                                <input type="radio" style="position:relative;top:2px" name="LWDW" ng-checked="item1.checked" ng-click="ctl.checkItem(item1)" />
+                                {{item1.CNAME}}
+                            </label>
+                        </div>
+                    </div>
+                </div>
+                <div class="sp-page sp-text-center sp-pt-10">
+                    <a class="sp-btn-blue sp-radius" ng-click="ctl.submitLWDW()"><i class="fa fa-check sp-mr-5"></i>确 定</a>
+                    <a class="sp-btn-blue sp-radius" onclick="sp.layerhide()"><i class="fa fa-close sp-mr-5"></i>取 消</a>
+                </div>
+            </div>
+        </div>
+        <div class="sp-layer" id="setLWDW" style="width: 900px;">
+            <div class="sp-layer-head" style="background:#2176d6">
+                <div class="sp-page sp-text-center sp-font16">
+                    来文单位
+                    <div class="sp-layer-close" title="关闭" onclick="sp.closeCenter('.sp-layer')">
+                        ×
+                    </div>
+                </div>
+            </div>
+            <div class="sp-layer-body" ng-class="{'sp-height-400': '{{ctl.deviceType}}' =='pad'}">
+                <div class="sp-col-50">
+                    <div class="sp-page" id="treeDivPart" style="overflow:auto;max-height:300px">
+                        <div style="width: 100%;" class="menu-list" tree-view tree-data="ctl.treeData" text-field="CNAME"
+                             item-add="ctl.itemAdd($item,$event)"
+                             item-edit="ctl.itemEdit($item,$event)"
+                             item-delete="ctl.itemDelete($item,$event)">
+                        </div>
+                    </div>
+                </div>
+                <div class="sp-col-50" ng-if="ctl.rightFlag==1">
+                    <table class="sp-grid-job">
+                        <tr ng-if="(ctl.itemNode.id!=0&&ctl.itemNode.level==2)||ctl.itemNode.id==0">
+                            <td width="150">一级单位</td>
+                            <td>
+                                <input type="text" class="sp-input" ng-model="ctl.itemNode.name" ng-if="ctl.itemNode.id==0" ng-disabled="ctl.itemNode.level!=1" sp-required />
+                                <input type="text" class="sp-input" ng-model="ctl.itemNode.name" ng-if="ctl.itemNode.id!=0" ng-disabled="ctl.itemNode.level!=2" sp-required />
+                            </td>
+                        </tr>
+                        <tr ng-if="(ctl.itemNode.id!=0&&ctl.itemNode.level==3)||(ctl.itemNode.id==0&&ctl.itemNode.level!=1)">
+                            <td>二级单位</td>
+                            <td>
+                                <input type="text" class="sp-input" ng-model="ctl.itemNode.child_title" ng-if="ctl.itemNode.id==0" ng-disabled="ctl.itemNode.level!=2" sp-required />
+                                <input type="text" class="sp-input" ng-model="ctl.itemNode.child_title" ng-if="ctl.itemNode.id!=0" ng-disabled="ctl.itemNode.level!=3" sp-required />
+                            </td>
+                        </tr>
+                    </table>
+                    <div class="sp-page sp-text-center sp-pt-10 sp-pad-10">
+                        <button class="sp-btn-blue sp-btn-md" ng-click="ctl.btnSetTitle()">
+                            <i class="fa fa-check"></i>&nbsp;提交
+                        </button>
+                        <button class="sp-btn-default sp-btn-md" ng-click="ctl.btnCancal()">
+                            <i class="fa fa-close"></i>&nbsp;取消
+                        </button>
+                    </div>
+                </div>
+                <div class="sp-page sp-text-center sp-pt-10">
+                    <a class="sp-btn-blue sp-radius" onclick="sp.layerhide()"><i class="fa fa-close sp-mr-5"></i>关 闭</a>
+                </div>
+            </div>
+        </div>
+        <div class="sp-layer" id="print" style="width: 400px;">
+            <div class="sp-layer-head" style="background:#2176d6">
+                <div class="sp-page sp-text-center sp-font16">
+                    打印
+                    <div class="sp-layer-close" title="关闭" onclick="sp.closeCenter('.sp-layer')">
+                        ×
+                    </div>
+                </div>
+            </div>
+            <div class="sp-layer-body" ng-class="{'sp-height-400': '{{ctl.deviceType}}' =='pad'}">
+                <center class="sp-col-33" style="cursor:pointer" ng-class="{'activePirnt':ctl.printFiled==1}" ng-click="ctl.printFiled=1">
+                    <div class="printItem">表单</div>
+                </center>
+                <center class="sp-col-33" style="cursor:pointer" ng-class="{'activePirnt':ctl.printFiled==2}" ng-click="ctl.printFiled=2">
+                    <div class="printItem">意见</div>
+                </center>
+                <center class="sp-col-33" style="cursor:pointer" ng-class="{'activePirnt':ctl.printFiled==3}" ng-click="ctl.printFiled=3">
+                    <div class="printItem">表单+意见</div>
+                </center>
+                <div class="sp-page sp-text-center sp-pt-10">
+                    <a class="sp-btn-blue sp-radius" ng-click="ctl.printSubmit()"><i class="fa fa-check sp-mr-5"></i>确 定</a>
+                    <a class="sp-btn-blue sp-radius" onclick="sp.layerhide()"><i class="fa fa-close sp-mr-5"></i>取 消</a>
+                </div>
+            </div>
+        </div>
+        <div class="sp-layer" id="phrase" style="width:480px;">
+            <div class="sp-layer-head" style="background:#2176d6">
+                <div class="sp-page sp-text-center sp-font16">
+                    常用语库
+                    <div class="sp-layer-close" title="关闭" onclick="sp.closeCenter('.sp-layer')">
+                        ×
+                    </div>
+                </div>
+            </div>
+            <div class="sp-layer-body" ng-class="{'sp-height-400': '{{ctl.deviceType}}' =='pad'}">
+                <div class="sp-box">
+                    <div class="sp-col-70">
+                        <input type="text" ng-model="ctl.phraseText" class="sp-input" />
+                    </div>
+                    <div class="sp-col-30">
+                        <span class="sp-btn-blue sp-pull-left sp-radius" ng-class="{'sp-disabled':ctl.phraseText==''}" ng-click="ctl.Aphrase()">添加常用语</span>
+                    </div>
+                </div>
+                <div class="sp-box">
+                    <div class="sp-col-20" style="line-height:30px;">
+                        常用语:
+                    </div>
+                    <div class="sp-col-60">
+                        <select class="sp-select sp-bg-white" ng-model="ctl.phraseSelect">
+                            <option ng-repeat="item in ctl.phraseList" value="{{item.CONTENTS}}" ng-bind="item.CONTENTS"></option>
+                        </select>
+                    </div>
+                    <div class="sp-col-20">
+                        <span class="sp-btn-blue sp-pull-left sp-radius" ng-click="ctl.Dphrase()">删除</span>
+                    </div>
+                </div>
+                <div class="sp-page sp-text-center sp-pt-10">
+                    <a class="sp-btn-blue sp-radius" ng-click="ctl.btnPhrase()"><i class="fa fa-check sp-mr-5"> </i>确 认</a>
+                    <a class="sp-btn-blue sp-radius" onclick="sp.closeCenter('.sp-layer')"><i class="fa fa-reply-all sp-mr-5"> </i>关 闭</a>
+                </div>
+            </div>
+        </div>
+        <div class="sp-layer" id="forward" style="width: 1000px;">
+            <div class="sp-layer-head" style="background:#2176d6">
+                <div class="sp-page sp-text-center sp-font16">
+                    转&nbsp;&nbsp;发
+                    <div class="sp-layer-close" title="关闭" onclick="sp.closeCenter('.sp-layer')">
+                        ×
+                    </div>
+                </div>
+            </div>
+            <div class="sp-layer-body" ng-class="{'sp-height-400': '{{ctl.deviceType}}' =='pad'}">
+                <iframe id="forwardWin" style="width:100%;border:0"></iframe>
+            </div>
+        </div>
+        <div class="sp-layer" id="RouteList" style="width:900px;">
+            <div class="sp-layer-head" style="background:#2176d6">
+                <div class="sp-page sp-text-center sp-font16">
+                    流转记录
+                    <div class="sp-layer-close" title="关闭" onclick="sp.closeCenter('.sp-layer')">
+                        ×
+                    </div>
+                </div>
+            </div>
+            <div class="sp-layer-body" ng-class="{'sp-height-400': '{{ctl.deviceType}}' =='pad'}">
+                <table class="sp-table">
+                    <thead>
+                        <tr>
+                            <th style="width:100px"><strong>流程名称</strong></th>
+                            <th style="width:200px"><strong>标题</strong></th>
+                            <th style="width:100px"><strong>工作节点</strong></th>
+                            <th style="width:100px"><strong>转发人</strong></th>
+                            <th style="width:100px"><strong>主送</strong></th>
+                            <th style="width:150px"><strong>抄送</strong></th>
+                            <th style="width:200px"><strong>发送日期</strong></th>
+                        </tr>
+                    </thead>
+                </table>
+                <div style="overflow-y:scroll;max-height:400px">
+                    <table class="sp-table" style="margin-top: -38px">
+                        <thead>
+                            <tr>
+                                <th style="width:100px"><strong>流程名称</strong></th>
+                                <th style="width:200px"><strong>标题</strong></th>
+                                <th style="width:100px"><strong>工作节点</strong></th>
+                                <th style="width:100px"><strong>转发人</strong></th>
+                                <th style="width:100px"><strong>主送</strong></th>
+                                <th style="width:150px"><strong>抄送</strong></th>
+                                <th style="width:200px"><strong>发送日期</strong></th>
+                            </tr>
+                        </thead>
+                        <tbody>
+                            <tr ng-repeat="item in ctl.routeList">
+                                <td ng-bind="item.FLOWNAME"></td>
+                                <td ng-bind="item.TITLE"></td>
+                                <td ng-bind="item.ENDNODENAME"></td>
+                                <td ng-bind="item.USERNAMEFROM"></td>
+                                <td ng-bind="item.mainUser"></td>
+                                <td ng-bind="item.copyUsers"></td>
+                                <td ng-bind="item.RECEIVEDATE"></td>
+                            </tr>
+                        </tbody>
+                    </table>
+                </div>
+                <div class="sp-page sp-text-center sp-pt-10">
+                    <a class="sp-btn-blue sp-radius" onclick="sp.closeCenter('.sp-layer')"><i class="fa fa-reply-all sp-mr-5"> </i>关 闭</a>
+                </div>
+            </div>
+        </div>
+        <div class="sp-layer" id="USAGE" style="width:900px;">
+            <div class="sp-layer-head" style="background:#2176d6">
+                <div class="sp-page sp-text-center sp-font16">
+                    管理标签
+                    <div class="sp-layer-close" title="关闭" onclick="sp.closeCenter('.sp-layer')">
+                        ×
+                    </div>
+                </div>
+            </div>
+            <div class="sp-layer-body">
+                <div class="input-group col-lg-8">
+                    <input type="text" ng-model="ctl.addUSAGENAME" class="form-control" placeholder="新增标签">
+                    <span class="input-group-btn">
+                        <button ng-click="ctl.addUSAGE()" class="btn btn-success" type="button">增加</button>
+                    </span>
+                </div>
+                <br />
+                <table class="sp-table">
+                    <thead>
+                        <tr>
+                            <th style="width: 50px"><strong>序号</strong></th>
+                            <th style="width: 200px"><strong>标签名称</strong></th>
+                            <th style="width: 100px"><strong>状态</strong></th>
+                            <th style="width: 200px"><strong>操作</strong></th>
+                        </tr>
+                    </thead>
+                </table>
+                <div style="overflow-y:scroll;max-height:400px">
+                    <table class="sp-table" style="margin-top: -38px">
+                        <thead>
+                            <tr>
+                                <th style="width: 50px"><strong>序号</strong></th>
+                                <th style="width: 200px"><strong>标签名称</strong></th>
+                                <th style="width: 100px"><strong>状态</strong></th>
+                                <th style="width: 200px"><strong>操作</strong></th>
+                            </tr>
+                        </thead>
+                        <tbody>
+                            <tr ng-repeat="item in ctl.USAGELIST">
+                                <td ng-bind="$index+1"></td>
+                                <td>
+                                    <span ng-if="item.change==false" ng-bind="item.CNAME"></span>
+                                    <input type="text" ng-if="item.change==true" class="sp-input" ng-model="item.CNAME1" />
+                                </td>
+                                <td>
+                                    <button class="sp-btn-blue-outline sp-btn-sm sp-btn-radius" ng-if="item.USAGE=='隐藏'" ng-click="ctl.updataUSAGE(item,'显示')">显&nbsp;示</button>
+                                    <button class="sp-btn-red-outline sp-btn-sm sp-btn-radius" ng-if="item.USAGE=='显示'" ng-click="ctl.updataUSAGE(item,'隐藏')">隐&nbsp;藏</button>
+                                </td>
+                                <td>
+                                    <button class="sp-btn-gray-outline sp-btn-radius sp-btn-sm" ng-click="ctl.btnSort($index,'上移')" ng-disabled="{{$index}}==0">上&nbsp;移</button>
+                                    <button class="sp-btn-gray-outline sp-btn-radius sp-btn-sm" ng-click="ctl.btnSort($index,'下移')" ng-disabled="{{$index}}=={{ctl.USAGELIST.length-1}}">下&nbsp;移</button>
+                                    <button class="sp-btn-blue-outline sp-btn-sm sp-btn-radius" ng-disabled="item.USERID!=ctl.userId" ng-if="item.change==false" ng-click="item.change=true">编&nbsp;辑</button>
+                                    <button class="sp-btn-blue-outline sp-btn-sm sp-btn-radius" ng-if="item.change==true" ng-click="ctl.updataUSAGE(item,'CNAME')">保&nbsp;存</button>
+                                    <button class="sp-btn-red-outline sp-btn-sm sp-btn-radius" ng-disabled="item.USERID!=ctl.userId" ng-click="ctl.deleteUSAGE(item)">删&nbsp;除</button>
+                                </td>
+                            </tr>
+                        </tbody>
+                    </table>
+                </div>
+                <div class="sp-page sp-text-center sp-pt-10">
+                    <a class="sp-btn-blue sp-radius" onclick="sp.closeCenter('.sp-layer')"><i class="fa fa-reply-all sp-mr-5"> </i>关 闭</a>
+                </div>
+            </div>
+        </div>
+    </div>
+    <script type="text/ng-template" id="/treeView.html">
+        <ul>
+            <li ng-repeat="item in treeData" ng-include="'/treeItem.html'"></li>
+        </ul>
+    </script>
+    <script type="text/ng-template" id="/treeItem.html">
+        <p ng-class="{'pActive':item.checked}">
+            <i ng-click="itemExpended(item, $event);" class="{{getItemIcon(item)}}"></i>
+            <span style="display: inline-block;height: 18px;line-height: 18px;" ng-click="warpCallback('itemCheck', item, $event);">
+                {{item[textField]}}
+            </span>
+            <span class="edit-menu sp-color-gray">
+                <i ng-if="item.LEVELS!=3"
+                   ng-click="warpCallback('itemAdd', item, $event);" title="新增分类" class="fa fa-plus"></i>
+                <i ng-if="item.LEVELS!=1"
+                   ng-click="warpCallback('itemEdit', item, $event);" title="编辑分类" class="fa fa-pencil"></i>
+                <i ng-if="!item.C_H_I_L_D_DATA || item.C_H_I_L_D_DATA.length<1"
+                   ng-click="warpCallback('itemDelete', item, $event);" title="删除分类" class="fa fa-trash"></i>
+                <i ng-if="$index!=0"
+                   ng-click="warpCallback('itemUp', item, $index, $event);" title="上移" class="fa fa-arrow-up"></i>
+                <i ng-if="$index+1!=item.C_H_I_L_D_DATA_L"
+                   ng-click="warpCallback('itemDown', item, $index, $event);" title="下移" class="fa fa-arrow-down"></i>
+            </span>
+        </p>
+        <ul ng-if="!isEnd(item)" ng-show="!item.$$isExpend">
+            <li ng-repeat="item in item.C_H_I_L_D_DATA" ng-include="'/treeItem.html'"></li>
+        </ul>
+    </script>
+    <script src="../../../AFrontEnd/js/jquery/jquery-2.1.4.min.js"></script>
+    <script src="../../../AFrontEnd/js/laydate/laydate.js"></script>
+    <script src="../../../AFrontEnd/js/angularjs/angular.js"></script>
+    <script src="../../../AFrontEnd/js/angularjs/dirPagination.js"></script>
+    <script src="../../../apiurljs.js"></script>
+    <!--<script src="../../js/watermark.js"></script>-->
+    <script src="../../../js/sm4.js"></script>
+		<script src="./js/api/request.js"></script>
+		<script src="./js/api/g2app_abase.js"></script>
+		<script src="./js/api/g2work_flow.js"></script>
+		<script src="./js/api/g2app_dataabase.js"></script>
+		<script src="./js/api/g2app_shouwen.js"></script>
+    <script>document.write('<scri' + 'pt src="../../../AFrontEnd/js/special/special.js?time=' + new Date().getTime() + '" type="text/javascript"></s' + 'cript>')</script>
+    <script>document.write('<scri' + 'pt src="js/formeditZW_vue.js?time=' + new Date().getTime() + '" type="text/javascript"></s' + 'cript>')</script>
+    <script src="../../../AFrontEnd/js/special/spng.js"></script>
+    <script src="../../../AFrontEnd/js/special/spngvld.js"></script>
+    <!--附件-->
+    <script src="../../../AFrontEnd/plugins/js.fileupload/vendor/jquery.ui.widget.js"></script>
+    <script src="../../../AFrontEnd/plugins/js.fileupload/jquery.iframe-transport.js"></script>
+    <script src="../../../AFrontEnd/plugins/js.fileupload/jquery.fileupload.js"></script>
+</body>
+</html>

+ 35 - 0
tpl/shouwenbg/WJCBD/js/api.js

@@ -0,0 +1,35 @@
+function request(config = {}) {
+  let s4 = new SM4Util();
+	let postCfg = {
+		headers: {
+			'Content-Type': 'application/json',
+			'Authorization': "Bearer " + localStorage.getItem("GlWorkPlatform-AccessToken")
+		}
+	};
+
+	let {
+		url,
+		data,
+		header = {}
+	} = config
+	url = apiurljs.login + url
+
+let headers = {
+	'Content-Type': 'application/json',
+	'Authorization': "Bearer " + localStorage.getItem("GlWorkPlatform-AccessToken")
+}
+
+	return new Promise((resolve, reject) => {
+		axios.post(url, {
+					data: s4.encryptData_CBC(JSON.stringify(data))
+				}, {headers})
+		    .then(response => {
+		        resolve(strToJson(s4.decryptData_CBC(response.data.data)))
+		    })
+		    .catch(error => {
+					  reject(error)
+		    });
+	})
+}
+
+

+ 21 - 0
tpl/shouwenbg/WJCBD/js/api/g2app_abase.js

@@ -0,0 +1,21 @@
+
+function g2app_abase_queryDataLink(data){
+	return request({
+		url:"g2app/abase/queryDataLink",
+		data:data
+	})
+}
+
+function g2app_abase_queryData(data){
+	return request({
+		url:"g2app/abase/queryData",
+		data:data
+	})
+}
+
+function g2app_abase_queryDataCode(data){
+	return request({
+		url:"g2app/abase/queryDataCode",
+		data:data
+	})
+}

+ 14 - 0
tpl/shouwenbg/WJCBD/js/api/g2app_dataabase.js

@@ -0,0 +1,14 @@
+function g2app_dataabase_delDataById(data){
+	return request({
+		url:"g2app/dataabase/delDataById",
+		data:data
+	})
+}
+
+function g2app_dataabase_querySectByCode(data){
+	return request({
+		url:"g2app/dataabase/querySectByCode",
+		data:data
+	})
+}
+

+ 7 - 0
tpl/shouwenbg/WJCBD/js/api/g2app_shouwen.js

@@ -0,0 +1,7 @@
+
+function g2app_shouwen_querySWCodeByFlowid(data){
+	return request({
+		url:"g2app/shouwen/querySWCodeByFlowid",
+		data:data
+	})
+}

+ 7 - 0
tpl/shouwenbg/WJCBD/js/api/g2work_flow.js

@@ -0,0 +1,7 @@
+
+function g2work_flow_queryDataByCopyrightid(data){
+	return request({
+		url:"g2work/flow/queryDataByCopyrightid",
+		data:data
+	})
+}

+ 33 - 0
tpl/shouwenbg/WJCBD/js/api/request.js

@@ -0,0 +1,33 @@
+function request(config = {}) {
+
+	var postCfg = {
+		headers: {
+			'Content-Type': 'application/json',
+			'Authorization': "Bearer " + localStorage.getItem("GlWorkPlatform-AccessToken")
+		}
+	};
+
+	let {
+		url,
+		data,
+		header = {}
+	} = config
+	url = apiurljs.login + url
+
+let headers = {
+	'Content-Type': 'application/json',
+	'Authorization': "Bearer " + localStorage.getItem("GlWorkPlatform-AccessToken")
+}
+
+	return new Promise((resolve, reject) => {
+		axios.post(url, {
+					data: s4.encryptData_CBC(JSON.stringify(data))
+				}, {headers})
+		    .then(response => {
+		        resolve(strToJson(s4.decryptData_CBC(response.data.data)))
+		    })
+		    .catch(error => {
+					  reject(error)
+		    });
+	})
+}

+ 3843 - 0
tpl/shouwenbg/WJCBD/js/formeditZW_vue.js

@@ -0,0 +1,3843 @@
+'use strict';
+
+// let s4 = new SM4Util();
+const vm = new Vue({
+	el:"#appvue",
+	data:{
+		userId :"",
+		userName :"",
+		get_AccessToken :"",
+		routeid:"",
+		routeinfoid :"",
+		copyrightid :"",
+		directionid :"",
+		formeditid :"",
+		mbid :"",
+		fjid :"",
+		docmode :"",
+		dotype :"",
+		get_lastReturnPageno :"",
+		get_lastReturnPage :"",
+		get_type :"",
+		return:"",
+		deviceType :"",
+		FormTitle:"",
+		//右上角按钮
+		buttonList:[],
+		s4 : new SM4Util(),
+		//上层附件、业务参考、共享沟通组件
+		arrayFile : null,
+		arrayFile1 : [],
+		uploading_zw : false,
+		uploading : false,
+		readonly:{
+			CPSX: true,
+			JJCD: false,
+			MIJI: false,
+			SWLB: false,
+			SWBH: false,
+			LWDW: false,
+			LWRQ: false,
+			LWWH: false,
+			SFDB: false,
+			BT: false,
+			DBSX: false,
+			CDCS: false,
+			ZBCS: false,
+			SFBJ: false,
+			BJQK: false,
+			BZ: false,
+			NGR: false,
+			ZBRQ: false,
+			USAGE: false
+		},
+		show:{
+			CPSX: false,
+			JJCD: false,
+			MIJI: false,
+			SWLB: false,
+			SWBH: false,
+			LWDW: false,
+			LWRQ: false,
+			LWWH: false,
+			SFDB: false,
+			BT: false,
+			DBSX: false,
+			CDCS: false,
+			ZBCS: false,
+			SFBJ: false,
+			BJQK: false,
+			BZ: false,
+			NGR: false,
+			ZBRQ: false,
+			USAGE: false
+		},
+		Loaling:false,
+		pdfContent:[],
+		itemNode:{
+			level: "",
+			id: "",
+			name: "",
+			code: "",
+			child_title: ""
+		},
+		rightFlag :0,
+		printFiled:1,
+		opinion:{
+			BGSNBYJ: false,
+			BGSNBYJImg: false,
+			WLDPS: false,
+			WLDPSImg: false,
+			FGLDBJQR: false,
+			FGLDBJQRImg: false,
+			CBCSCLQK: false,
+			CBCSCLQKImg: false,
+			nulla: false
+		},
+		YJ:{
+			BGSNBYJ: [],
+			BGSNBYJSTATUS: false,
+			WLDPS: [],
+			WLDPSSTATUS: false,
+			FGLDBJQR: [],
+			FGLDBJQRSTATUS: false,
+			CBCSCLQK: [],
+			CBCSCLQKSTATUS: false,
+			nulla: [],
+			nullaSTATUS: false
+		},
+		uploading1:false,
+		uploading2:false,
+		phraseText:"",//添加常用语
+		phraseList:[],//常用语列表
+		repeat:false,
+		headBtnSearchKeyword :"",
+		headSearchResult:[],
+		headSearchResult_view:false,
+		data:{},
+		flowTitle:""
+	},
+	
+	created() {
+		this.userId = $.cookie("GlWorkPlatform-userid");
+		this.userName = $.cookie("GlWorkPlatform-chineseName");
+		this.get_AccessToken = localStorage.getItem("GlWorkPlatform-AccessToken");
+		this.routeid = sp.getUrlName("routeid");
+		this.routeinfoid = sp.getUrlName("routeinfoid");
+		this.copyrightid = sp.getUrlName("copyrightid");
+		this.directionid = sp.getUrlName("directionid");
+		this.formeditid = sp.getUrlName("formeditid");
+		this.mbid = sp.getUrlName("mbid");
+		this.fjid = sp.getUrlName("fjid");
+		this.docmode = sp.getUrlName("docmode");
+		this.dotype = sp.getUrlName("dotype");
+		this.get_lastReturnPageno = sp.getUrlName("lastReturnPageno");
+		this.get_lastReturnPage = sp.getUrlName("lastReturnPage");
+		this.get_type = sp.getUrlName("type");
+		this.return = "../list.html?lastReturnPageno=" + self.get_lastReturnPageno + "&type=" + self.get_type
+		this.deviceType = localStorage.getItem("tjJxtGoldenlinkWork-deviceType");
+		this.FormTitle = $.cookie("GlWorkPlatform-SYSNAME");
+	},
+	mounted() {
+		this.getSwenList(0)
+	},
+	methods:{
+		//上传正文
+		upload_zw(){
+			let uploadformat = strToJson(s4.decryptData_CBC(apiurljs.uploadformat)).data.map(function (item) {
+			    return item.CNAME
+			})
+			$('#fileupload-zw').fileupload({
+			    url: apiurljs.login + (this.routeinfoid == 0 ? 'g2app/abase/uploadFileWithFormWithSaveRouteinfo' : 'g2app/abase/uploadFileWithFormAndGetPage'),//'g2app/abase/uploadFileWithForm'),
+			    dataType: 'json',
+			    beforeSend: function (xhr, data) {
+			        xhr.setRequestHeader("Authorization", "Bearer " + this.get_AccessToken);
+			        if (self.routeinfoid == 0) {
+			            xhr.setRequestHeader("File-Argument", s4.encryptData_CBC("copyrightid=" + self.copyrightid + ",directionid=" + self.directionid + ",formeditid=" + self.formeditid + ",routeinfoid=" + self.routeinfoid + ",routeid=" + self.routeid + ",tablename=FILE_ATTACH,ATTACHTYPE=行政公文-正文"));
+			        } else {
+			            xhr.setRequestHeader("File-Argument", s4.encryptData_CBC("tablename=FILE_ATTACH,routeinfoid=" + self.routeinfoid + ",ATTACHTYPE=行政公文-正文"));
+			        }
+			    },
+			    add: function (e, data) {
+			        var num = 0;
+			        var acceptFileTypes = eval('/(' + uploadformat.join("|") + ')$/i')
+			        //文件类型判断
+			        $.each(data.originalFiles, function (index, item) {
+			            if (item['type'].length > 0 && !acceptFileTypes.test(item['name'])) {
+			                sp.dialog("您好,请上传" + uploadformat.join("/") + "格式的文件!");
+			                return;
+			            } else {
+			                num++
+			            }
+			        })
+			        if (num == data.originalFiles.length) {
+			            self.uploading_zw = true;
+			            data.submit();
+			            $scope.$apply();
+			        }
+			    },
+			    // 上传完成后的执行逻辑
+			    done: function (e, data) {
+			        self.uploading_zw = false;
+			        if (self.routeinfoid == 0) {
+			            var res = strToJson(s4.decryptData_CBC(data.result.data));
+			            self.data.ID = res.data2.ID;
+			            self.routeid = res.data2.ROUTEID;
+			            self.routeinfoid = res.data2.ROUTEINFOID;
+			            self.getSwenList(0)
+			        } else {
+			            self.getOther1()
+			        }
+			    }
+			})
+		},
+		upload(){
+			var uploadformat = strToJson(s4.decryptData_CBC(apiurljs.uploadformat)).data.map(function (item) {
+			    return item.CNAME
+			})
+			  $('#fileupload').fileupload({
+			      url: apiurljs.login + 'g2app/abase/uploadFileWithFormAndGetPage',//'g2app/abase/uploadFileWithForm',
+			      dataType: 'json',
+			      beforeSend: function (xhr, data) {
+			          xhr.setRequestHeader("Authorization", "Bearer " + self.get_AccessToken);
+			          xhr.setRequestHeader("File-Argument", s4.encryptData_CBC("tablename=FILE_ATTACH,routeinfoid=" + self.routeinfoid + ",ATTACHTYPE=行政公文"));
+			      },
+			      add: function (e, data) {
+			          var num = 0;
+			          var acceptFileTypes = eval('/(' + uploadformat.join("|") + ')$/i')
+			          //文件类型判断
+			          $.each(data.originalFiles, function (index, item) {
+			              if (item['type'].length > 0 && !acceptFileTypes.test(item['name'])) {
+			                  sp.dialog("您好,请上传" + uploadformat.join("/") + "格式的文件!");
+			                  return;
+			              } else {
+			                  num++
+			              }
+			          })
+			          if (num == data.originalFiles.length) {
+			              self.uploading = true;
+			              data.submit();
+			              $scope.$apply();
+			          }
+			      },
+			      // 上传完成后的执行逻辑
+			      done: function (e, data) {
+			          self.uploading = false;
+			          self.getOther()
+			      }
+			  })
+		},
+		downLoad(item){
+			window.open(apiurljs.login + "g2work/files/" + item.FILEURL.slice(7))
+			
+		},
+		deleteFile(file){
+			var dialogHead = "<span class=\"sp-dialog-head\"><span class=\"sp-dialog-tip\">温馨提示</span><span class=\"sp-dialog-close sp-closeDialog\" title=\"关闭\">×</span></span>";
+			var dialogBody = "<div class=\"sp-dialog-body\">删除后不可恢复,您确认要删除吗?</div>";
+			var dialogFoot = "<div class=\"sp-dialog-foot\"><input id='delDataTrue' type='button' value='确 认' class='sp-dialog-btnTrue' /><input type='button' value='取 消' class='sp-dialog-btnCancle sp-closeDialog' /></div>";
+			$('.sp-dialog').html(dialogHead + dialogBody + dialogFoot);
+			
+			sp.openCenter(".sp-dialog");
+			
+			///取消按钮
+			$('.sp-closeDialog').click(function (event) {
+			    sp.closeCenter(".sp-dialog");
+			    event.preventDefault();
+			    event.stopPropagation();
+			});
+			//post消息的id
+			$("#delDataTrue").click(function () {
+			
+			    var data = {
+			        tablename: "FILE_ATTACH",
+			        id: file.ID
+			    };
+			    $http.post(apiurljs.login + "g2app/dataabase/delDataById", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			        .success(function (obj) {
+			            var res = strToJson(s4.decryptData_CBC(obj.data));
+			            sp.dialoghide();
+			            if (res.success) {
+			                self.getOther();
+			            } else {
+			                sp.dialog("删除失败,请联系管理员!");
+			            }
+			        });
+			});
+		},
+		seeFile(obj){
+			self.seeFileItem = obj;
+			var set_convertType = 0;
+			if (obj.FILEEXT == "doc") {
+			    set_convertType = 0;
+			} else if (obj.FILEEXT == "pdf") {
+			    set_convertType = 20;
+			} else if (obj.FILEEXT == "ofd") {
+			    set_convertType = 570;
+			} else {
+			    set_convertType = 0;
+			}
+			let postData = {
+			    convertType: set_convertType,
+			    isSignature: 1,
+			    signCallback: "g2app/fawenfiles/uploadFileFCS/" + obj.FILEURL.slice(7),
+			    fileUrl: apiurljs.login + "g2work/files2/inline/" + obj.FILEURL.slice(7)
+			};
+			var postCfg_transfer = {
+			    headers: { 'Content-Type': 'application/x-www-form-urlencoded' },
+			    transformRequest: function (data) {
+			        return $.param(data);
+			    }
+			};
+			$http.post(apiurljs.login.split("glwork/")[0] + "fcscloud/composite/httpfile", postData, postCfg_transfer)
+			.success(function (res) {
+			    if (res.errorcode === 0) {
+			       //$("#iframe_book").css("height", $(".ibox-content").height() - 123)
+			        $("#iframe_book").attr("src", res.data.viewUrl)
+			    } else {
+			        sp.dialog(res.message);
+			    }
+			});
+		},
+		goAttach(){
+			if (obj) {
+			      if (apiurljs.zhType.indexOf(obj.FILEEXT) == -1) {
+			          sp.dialog("文件暂不支持在线预览,请点击下载查看!")
+			          return
+			      }
+			    $("#attachlist")[0].contentWindow.openFile(obj)
+			    if ($(".fa-chevron-down").is(":hidden") == true) {
+			        showToggle(document.getElementById("toggleButton"))
+			    }
+			} else {
+			    $("#attachlist").attr("src", "attachlist.html?routeinfoid=" + self.routeinfoid)
+			}
+		},
+		getSwenList(n){
+			this.SwenList = [];
+			let data = {
+			    directionid: this.directionid,
+			    userid: this.userId,
+			    routeinfoid: this.routeinfoid,
+			    routeid: this.routeid,
+			    formeditid: ""
+			}
+			g2app_abase_queryDataLink(data).then(res=>{
+				if (this.copyrightid == "") {
+				    this.copyrightid = res.data.LINKS[0].COPYRIGHTID
+				}
+				for(let i=0;i<res.data.LINKS.length;i++){
+					let index = i
+					let item = res.data.LINKS[i]
+					item.TEMPFORM = item.TEMPFORM + "&flowid=" + sp.getUrlName("flowid")
+					if (item.TEMPFORM.indexOf("formeditZW.html") > -1) {
+					    this.Title = item.VNAME;
+					}
+					if (item.TEMPFORM.indexOf("?docmode") > 0) {
+					    item.TEMPFORM = item.TEMPFORM + "&dotype=" + this.dotype + "&type=" + this.get_type + "&lastReturnPageno=" + this.get_lastReturnPageno + "&lastReturnPage=" + this.get_lastReturnPage;
+					} else {
+					    item.TEMPFORM = "#";
+					}
+					this.SwenList.push(item)
+				}
+				this.SwenList.push({
+				    VNAME: "流程图",
+				    DIRECTIONID: this.SwenList[0].DIRECTIONID,
+				    TEMPFORM: "modeler_read.html?" + this.SwenList[0].TEMPFORM.split("?")[1]
+				})
+				if (n == 0) {
+				    this.getFLOW()
+				} 
+				// else {
+				//     this.getData()
+				// }
+			})
+		},
+		getFLOW(){
+			g2work_flow_queryDataByCopyrightid({copyrightid: this.copyrightid}).then(res=>{
+				this.flowTitle = res.data.CNAME;
+				this.getJJQK()
+			})
+		},
+		getJJQK(){
+			g2app_abase_queryDataCode( {
+			    ckey: "CODE_EMERGENCY",
+			    routeinfoid: this.routeinfoid
+			}).then(res=>{
+				this.JJCD = res.data.CODE_EMERGENCY;
+				this.getCDDB()
+			})
+		},
+		getCDDB(){
+			g2app_abase_queryDataCode({
+			    ckey: "CODE_DUBAN",
+			    routeinfoid: this.routeinfoid
+			}).then(res=>{
+			    this.DBTYPE = res.data.CODE_DUBAN;
+			    this.getMIJI()
+			})
+		},
+		getMIJI(){
+			g2app_abase_queryDataCode({
+			    ckey: "CODE_SECRET",
+			    routeinfoid: this.routeinfoid
+			}).then(res=>{
+			    this.MIJI = res.data.CODE_SECRET;
+			    this.getSFDB()
+			})
+		},
+		getSFDB(){
+			g2app_abase_queryDataCode({
+			    ckey: "CODE_SFDB",
+			    routeinfoid: this.routeinfoid
+			}).then(res=>{
+			    this.SFDB = res.data.CODE_SFDB;
+			    this.getSFBJ()
+			})
+		},
+		getSFBJ(){
+			g2app_abase_queryDataCode({
+			    ckey: "CODE_SF",
+			    routeinfoid: this.routeinfoid
+			}).then(res=>{
+			    this.SFBJ = res.data.CODE_SF;
+			    this.getSWLB()
+			})
+		},
+		getSWLB(){
+			g2app_abase_queryDataCode({
+			    ckey: "CODE_SWLB",
+			    routeinfoid: this.routeinfoid
+			}).then(res=>{
+			    this.SWLB = res.data.CODE_SWLB;
+			    this.getDpList()
+			})
+		},
+		getDpList(){
+			g2app_dataabase_querySectByCode({ unitid: "AA"}).then(res=>{
+				this.dpList = [];
+				res.data.forEach((item) => {
+				    if (item.CHILD_DATA.length == 0) {
+				        this.dpList.push(item)
+				    } else {
+				        item.CHILD_DATA.forEach( (item1)=> {
+				            if (item1.CHILD_DATA.length == 0) {
+				                this.dpList.push(item1)
+				            } else {
+				                item1.CHILD_DATA.forEach( (item2)=> {
+				                    if (item2.CHILD_DATA.length == 0) {
+				                        this.dpList.push(item2)
+				                    }
+				                })
+				            }
+				        })
+				    }
+				})
+				this.dpList.forEach( (item)=> {
+				    item.checked = false;
+				})
+				this.DpList = {
+				    ZBCS: JSON.parse(JSON.stringify(this.dpList)),
+				    CDCS: JSON.parse(JSON.stringify(this.dpList))
+				}
+				this.AllCheckedDp = {};
+				this.DpLength = {};
+				this.selectDpList = {};
+				this.getUSAGE(0)
+			})
+		},
+		//标签
+		getUSAGE(n){
+			g2app_abase_queryDataCode({
+				ckey: "CODE_SHOUWENLABEL",
+				routeinfoid: this.routeinfoid
+			}).then(res=>{
+				this.USAGE = res.data.CODE_SHOUWENLABEL;
+				this.USAGE.forEach(item=>{
+					 item.checked = false;
+				})
+				if (n == 0) {
+				    this.getSWBH()
+				}
+				if (n == 1) {
+					this.USAGE.forEach(item=>{
+						if (this.data.USAGE.indexOf(item.CODE) != -1) {
+						    item.checked = true;
+						}
+					})
+				    $timeout(function () {
+				        $(".sp-checkbox-blue input[name=USAGE]").each(function () {
+				            if (this.data.USAGE.indexOf($(this).val()) != -1) {
+				                $(this).attr("checked", true);
+				                $(this).parent("label").addClass("chb-blue-checked");
+				            }
+				        })
+				    }, 1)
+				}
+			})
+		},
+		//管理标签
+		ManageUSAGE(n) {
+		    self.addUSAGENAME = "";
+		    var data = {
+		        tablename: "CODE_SHOUWENLABEL"
+		    }
+		    $http.post(apiurljs.login + "g2app/shouwen/queryLabelCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+		    .success(function (obj) {
+		        var res = strToJson(s4.decryptData_CBC(obj.data));
+		        self.USAGELIST = res.data;
+		        $.each(self.USAGELIST, function (index, item) {
+		            item.change = false;
+		            item.CNAME1 = item.CNAME;
+		            item.USAGE = item.USAGE == 0 ? "隐藏" : "显示";
+		        })
+		        if (n == 0) {
+		            $timeout(function () {
+		                sp.layer("#USAGE");
+		            }, 1)
+		        }
+		    })
+		},
+		//新增标签
+		addUSAGE() {
+		    if (self.addUSAGENAME == "") {
+		        sp.dialog("标签名称不可为空!");
+		        return;
+		    }
+		    var data = {
+		        tablename: "CODE_SHOUWENLABEL",
+		        data: {
+		            CODE: "C0" + (self.USAGELIST.length + 1),
+		            CNAME: self.addUSAGENAME,
+		            USERID: self.userId,
+		            TABLENAME: "SW_ZJWWJCBD",
+		            USAGE: "1"
+		        }
+		    }
+		    $http.post(apiurljs.login + "g2app/shouwen/insertCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+		    .success(function (obj) {
+		        var res = strToJson(s4.decryptData_CBC(obj.data));
+		        if (res.success) {
+		            self.ManageUSAGE(1);
+		            self.getUSAGE(1);
+		        } else {
+		            sp.dialog(res.message);
+		        }
+		    })
+		},
+		
+		//标签排序上下移
+		btnSort($index, tip) {
+		    var set_id = "";
+		    var set_sortid = "";
+		    if (tip == "上移") {
+		        var set_index = parseInt($index - 1);
+		        set_id = self.USAGELIST[set_index].ID;
+		        set_sortid = self.USAGELIST[set_index].SORTID;
+		    } else {
+		        var set_index = parseInt($index + 1);
+		        set_id = self.USAGELIST[set_index].ID;
+		        set_sortid = self.USAGELIST[set_index].SORTID;
+		    }
+		    var data = {
+		        tablename: "CODE_SHOUWENLABEL",
+		        id: self.USAGELIST[$index].ID,
+		        sortid: self.USAGELIST[$index].SORTID,
+		        id_other: set_id,
+		        sortid_other: set_sortid
+		    };
+		    $http.post(apiurljs.login + "g2app/shouwen/MoveCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+		    .success(function (obj) {
+		        var res = strToJson(s4.decryptData_CBC(obj.data));
+		        if (res.success) {
+		            self.ManageUSAGE(1);
+		        } else {
+		            sp.dialog(res.message);
+		        }
+		    });
+		},
+		updataUSAGE(item, str){
+			if (str == "CNAME") {
+			    var data = {
+			        tablename: "SW_ZJWWJCBD",
+			        code: item.CODE,
+			    }
+			    $http.post(apiurljs.login + "g2app/shouwen/querynumCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			    .success(function (obj) {
+			        var res = strToJson(s4.decryptData_CBC(obj.data));
+			        if (res.success) {
+			            var data = {
+			                tablename: "CODE_SHOUWENLABEL",
+			                id: item.ID,
+			                data: {
+			                    "cname": item.CNAME1
+			                }
+			            }
+			            $http.post(apiurljs.login + "g2app/shouwen/upCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			            .success(function (obj) {
+			                var res = strToJson(s4.decryptData_CBC(obj.data));
+			                if (res.success) {
+			                    item.change = false;
+			                    self.ManageUSAGE(1);
+			                    self.getUSAGE(1);
+			                } else {
+			                    sp.dialog(res.message);
+			                }
+			            });
+			        } else {
+			            var dialogHead = "<span class=\"sp-dialog-head\"><span class=\"sp-dialog-tip\">温馨提示</span><span class=\"sp-dialog-close sp-closeDialog\" title=\"关闭\">×</span></span>";
+			            var dialogBody = "<div class=\"sp-dialog-body\">该标签已被使用,您确认要修改吗?</div>";
+			            var dialogFoot = "<div class=\"sp-dialog-foot\"><input id='upDataTrue' type='button' value='确 认' class='sp-dialog-btnTrue' /><input type='button' value='取 消' class='sp-dialog-btnCancle sp-closeDialog' /></div>";
+			            $('.sp-dialog').html(dialogHead + dialogBody + dialogFoot);
+			            sp.openCenter(".sp-dialog");
+			            $('.sp-closeDialog').click(function (event) {
+			                sp.dialoghide();
+			                $timeout(function () {
+			                    item.CNAME1 = item.CNAME;
+			                }, 1)
+			                //sp.closeCenter(".sp-dialog");
+			                event.preventDefault(); event.stopPropagation();
+			            });
+			            $("#upDataTrue").click(function () {
+			                var data = {
+			                    tablename: "CODE_SHOUWENLABEL",
+			                    id: item.ID,
+			                    data: {
+			                        "cname": item.CNAME1
+			                    }
+			                }
+			                $http.post(apiurljs.login + "g2app/shouwen/upCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			                .success(function (obj) {
+			                    var res = strToJson(s4.decryptData_CBC(obj.data));
+			                    if (res.success) {
+			                        sp.dialoghide();
+			                        item.change = false;
+			                        self.ManageUSAGE(1);
+			                        self.getUSAGE(1);
+			                    } else {
+			                        sp.dialog(res.message);
+			                    }
+			                });
+			            });
+			        }
+			    })
+			} else if (str == "显示") {
+			    var data = {
+			        tablename: "CODE_SHOUWENLABEL",
+			        id: item.ID,
+			        data: {
+			            "USAGE": "1"
+			        }
+			    }
+			    $http.post(apiurljs.login + "g2app/shouwen/upCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			    .success(function (obj) {
+			        var res = strToJson(s4.decryptData_CBC(obj.data));
+			        if (res.success) {
+			            item.change = false;
+			            self.ManageUSAGE(1);
+			            self.getUSAGE(1);
+			        } else {
+			            sp.dialog(res.message);
+			        }
+			    });
+			} else {
+			    var data = {
+			        tablename: "CODE_SHOUWENLABEL",
+			        id: item.ID,
+			        data: {
+			            "USAGE": "0"
+			        }
+			    }
+			    $http.post(apiurljs.login + "g2app/shouwen/upCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			    .success(function (obj) {
+			        var res = strToJson(s4.decryptData_CBC(obj.data));
+			        if (res.success) {
+			            item.change = false;
+			            self.ManageUSAGE(1);
+			            self.getUSAGE(1);
+			        } else {
+			            sp.dialog(res.message);
+			        }
+			    });
+			}
+		},
+		deleteUSAGE(item){
+			var data = {
+			    tablename: "CODE_SHOUWENLABEL",
+			    tablename_form: "SW_ZJWWJCBD",
+			    id: item.ID,
+			    code: item.CODE
+			}
+			$http.post(apiurljs.login + "g2app/shouwen/delCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			.success(function (obj) {
+			    var res = strToJson(s4.decryptData_CBC(obj.data));
+			    if (res.success) {
+			        self.ManageUSAGE(1);
+			        self.getUSAGE(1);
+			    } else {
+			        sp.dialog("此标签已被使用");
+			    }
+			});
+		},
+		getSWBH(){
+			g2app_shouwen_querySWCodeByFlowid({flowid: sp.getUrlName("flowid")}).then(res=>{
+				this.SWBH = res.data;
+				this.getData()
+			})
+		},
+		getData(){
+			g2app_abase_queryData({
+				ckey: "SW_ZJWWJCBD",
+				id: 0,
+				directionid: this.directionid,
+				formeditid: this.formeditid,
+				routeid: this.routeid,
+				routeinfoid: this.routeinfoid
+			}).then(res=>{
+				this.data = {
+						CPSX: res.data.SW_ZJWWJCBD.CPSX == "" ? "" : sp.format(res.data.SW_ZJWWJCBD.CPSX),
+				    ID: res.data.SW_ZJWWJCBD.ID,
+				    APPCODE: res.data.SW_ZJWWJCBD.APPCODE,
+				    JJCD: res.data.SW_ZJWWJCBD.JJCD == "" ? this.JJCD[0].CODE : res.data.SW_ZJWWJCBD.JJCD,
+				    MIJI: res.data.SW_ZJWWJCBD.MIJI == "" ? this.MIJI[0].CODE : res.data.SW_ZJWWJCBD.MIJI,
+						SWLB: res.data.SW_ZJWWJCBD.SWLB == "" ? this.SWLB[0].CODE : res.data.SW_ZJWWJCBD.SWLB,
+				    SWBH: res.data.SW_ZJWWJCBD.SWBH == "" ? this.SWBH.replace("|", "〔 ").replace("|", " 〕") + "号" : res.data.SW_ZJWWJCBD.SWBH,              
+				    SWBH1: res.data.SW_ZJWWJCBD.SWBH,
+				    LWDW: res.data.SW_ZJWWJCBD.LWDW,
+				    LWRQ: res.data.SW_ZJWWJCBD.LWRQ == "" || res.data.SW_ZJWWJCBD.LWRQ == null ? sp.format(sp.getLocalDate()) : sp.format(res.data.SW_ZJWWJCBD.LWRQ),
+				    LWWH: res.data.SW_ZJWWJCBD.LWWH == "" ? "〔 " + sp.currentYear() + " 〕号" : res.data.SW_ZJWWJCBD.LWWH,
+				    SFDB: res.data.SW_ZJWWJCBD.SFDB == "" ? "C03" : res.data.SW_ZJWWJCBD.SFDB,
+				    DBLX: res.data.SW_ZJWWJCBD.DBLX == "" ? res.data.SW_ZJWWJCBD.SFDB == "" || res.data.SW_ZJWWJCBD.SFDB == self.SFDB[1].CODE ? "" : self.DBTYPE[0].CODE : res.data.SW_ZJWWJCBD.DBLX,
+				    BT: res.data.SW_ZJWWJCBD.BT,
+				    DBSX: res.data.SW_ZJWWJCBD.DBSX == "" ? "" : sp.format(res.data.SW_ZJWWJCBD.DBSX),
+				    CDCS: res.data.SW_ZJWWJCBD.CDCS,
+				    ZBCS: res.data.SW_ZJWWJCBD.ZBCS,
+				    SFBJ: res.data.SW_ZJWWJCBD.SFBJ == "" ? this.SFBJ[0].CODE : res.data.SW_ZJWWJCBD.SFDB,
+				    BJQK:res.data.SW_ZJWWJCBD.BJQK,
+				    BZ: res.data.SW_ZJWWJCBD.BZ,
+				    NGR: res.data.SW_ZJWWJCBD.NGR == "" ? this.userName : res.data.SW_ZJWWJCBD.NGR,
+				    ZBRQ: res.data.SW_ZJWWJCBD.ZBRQ == "" || res.data.SW_ZJWWJCBD.ZBRQ == null ? sp.format(sp.getLocalDate()) : sp.format(res.data.SW_ZJWWJCBD.ZBRQ),
+				    USAGE: res.data.SW_ZJWWJCBD.USAGE,
+				    ZBCSCODE: res.data.SW_ZJWWJCBD.ZBCSCODE,
+				    FGLDBJQR: res.data.SW_ZJWWJCBD.FGLDBJQR,
+				    SWQXLX: res.data.SW_ZJWWJCBD.SWQXLX == "" ? res.data.SW_ZJWWJCBD.SFDB != "C01" ? "办理" : "督办" : res.data.SW_ZJWWJCBD.SWQXLX
+				}
+				this.readonly = {
+					  CPSX: true,
+				    JJCD: res.data.SW_ZJWWJCBD["JJCD.EREADONLY"] == "true",
+				    MIJI: res.data.SW_ZJWWJCBD["MIJI.EREADONLY"] == "true",
+						SWLB: res.data.SW_ZJWWJCBD["SWLB.EREADONLY"] == "true",
+				    SWBH: res.data.SW_ZJWWJCBD["SWBH.EREADONLY"] == "true",
+				    LWDW: res.data.SW_ZJWWJCBD["LWDW.EREADONLY"] == "true",
+				    LWRQ: res.data.SW_ZJWWJCBD["LWRQ.EREADONLY"] == "true",
+				    LWWH: res.data.SW_ZJWWJCBD["LWWH.EREADONLY"] == "true",
+				    SFDB: res.data.SW_ZJWWJCBD["SFDB.EREADONLY"] == "true",
+				    BT: res.data.SW_ZJWWJCBD["BT.EREADONLY"] == "true",
+				    BGSNBYJ: res.data.SW_ZJWWJCBD["BGSNBYJ.EREADONLY"] == "true",
+				    WLDPS: res.data.SW_ZJWWJCBD["WLDPS.EREADONLY"] == "true",
+				    CBCSCLQK: res.data.SW_ZJWWJCBD["CBCSCLQK.EREADONLY"] == "true",
+				    DBLX: res.data.SW_ZJWWJCBD["DBLX.EREADONLY"] == "true",
+				    CDCS: res.data.SW_ZJWWJCBD["CDCS.EREADONLY"] == "true",
+				    DBSX: res.data.SW_ZJWWJCBD["DBSX.EREADONLY"] == "true",
+				    ZBCS: res.data.SW_ZJWWJCBD["ZBCS.EREADONLY"] == "true",
+				    SFBJ: res.data.SW_ZJWWJCBD["SFBJ.EREADONLY"] == "true",
+				    BJQK: res.data.SW_ZJWWJCBD["BJQK.EREADONLY"] == "true",
+				    FGLDBJQR: res.data.SW_ZJWWJCBD["FGLDBJQR.EREADONLY"] == "true",
+				    BZ: res.data.SW_ZJWWJCBD["BZ.EREADONLY"] == "true",
+				    NGR: res.data.SW_ZJWWJCBD["NGR.EREADONLY"] == "true",
+				    ZBRQ: res.data.SW_ZJWWJCBD["ZBRQ.EREADONLY"] == "true",
+				    USAGE: res.data.SW_ZJWWJCBD["USAGE.EREADONLY"] == "true"
+				}
+				this.show = {
+					 CPSX:  res.data.SW_ZJWWJCBD["CPSX.ESHOW"] == "true",
+				    JJCD: res.data.SW_ZJWWJCBD["JJCD.ESHOW"] == "true",
+				    MIJI: res.data.SW_ZJWWJCBD["MIJI.ESHOW"] == "true",
+						SWLB: res.data.SW_ZJWWJCBD["SWLB.ESHOW"] == "true",
+				    SWBH: res.data.SW_ZJWWJCBD["SWBH.ESHOW"] == "true",
+				    LWDW: res.data.SW_ZJWWJCBD["LWDW.ESHOW"] == "true",
+				    LWRQ: res.data.SW_ZJWWJCBD["LWRQ.ESHOW"] == "true",
+				    LWWH: res.data.SW_ZJWWJCBD["LWWH.ESHOW"] == "true",
+				    SFDB: res.data.SW_ZJWWJCBD["SFDB.ESHOW"] == "true",
+				    BT: res.data.SW_ZJWWJCBD["BT.ESHOW"] == "true",
+				    BGSNBYJ: res.data.SW_ZJWWJCBD["BGSNBYJ.ESHOW"] == "true",
+				    WLDPS: res.data.SW_ZJWWJCBD["WLDPS.ESHOW"] == "true",
+				    CBCSCLQK: res.data.SW_ZJWWJCBD["CBCSCLQK.ESHOW"] == "true",
+				    DBLX: res.data.SW_ZJWWJCBD["DBLX.ESHOW"] == "true",
+				    CDCS: res.data.SW_ZJWWJCBD["CDCS.ESHOW"] == "true",
+				    DBSX: res.data.SW_ZJWWJCBD["DBSX.ESHOW"] == "true",
+				    ZBCS: res.data.SW_ZJWWJCBD["ZBCS.ESHOW"] == "true",
+				    SFBJ: res.data.SW_ZJWWJCBD["SFBJ.ESHOW"] == "true",
+				    BJQK: res.data.SW_ZJWWJCBD["BJQK.ESHOW"] == "true",
+				    FGLDBJQR: res.data.SW_ZJWWJCBD["FGLDBJQR.ESHOW"] == "true",
+				    BZ: res.data.SW_ZJWWJCBD["BZ.ESHOW"] == "true",
+				    NGR: res.data.SW_ZJWWJCBD["NGR.ESHOW"] == "true",
+				    ZBRQ: res.data.SW_ZJWWJCBD["ZBRQ.ESHOW"] == "true",
+				    USAGE: res.data.SW_ZJWWJCBD["USAGE.ESHOW"] == "true"
+				}
+				this.selectUSAGEs = this.data.USAGE != "" && this.data.USAGE != null ? this.data.USAGE.split(",") : [];
+
+				this.USAGE.forEach(item=>{
+					if (this.data.USAGE.indexOf(item.CODE) != -1) {
+					    item.checked = true;
+					}
+				})
+				// setTimeout(()=>{
+				// 	$(".sp-checkbox-blue input[name=USAGE]").each(function () {
+				// 	    if (this.data.USAGE.indexOf($(this).val()) != -1) {
+				// 	        $(this).attr("checked", true);
+				// 	        $(this).parent("label").addClass("chb-blue-checked");
+				// 	    }
+				// 	})
+				// },0)
+				this.filedChange = true;
+				let buttonList = [{ CNAME: "转发", CODE: "array", data: [] }];
+				res.data["SW_ZJWWJCBD.FUNCLIST"].forEach(function (item) {
+				    if (item.BUTTONGROUP == "FORMITEM") {
+				        buttonList.push(item)
+				    } else {
+				        buttonList[0].data.push(item)
+				    }
+				})
+				if (buttonList[0].data.length == 0) {
+				    buttonList = buttonList.slice(1)
+				} else if (buttonList[0].data.length == 1) {
+				    buttonList[0] = buttonList[0].data[0]
+				}
+				console.log(buttonList)
+				this.buttonList = buttonList;//res.data["SW_ZJWWJCBD.FUNCLIST"];
+				var n = {}, all = {};
+				for (var i in this.DpList) {
+				    this.AllCheckedDp[i] = false;
+				    this.DpLength[i] = 0;
+				    this.selectDpList[i] = []
+				    all[i] = 0;
+						this.DpList[i].forEach(item=>{
+							this.DpLength[i]++
+							if (this.data.ZBCS.indexOf(item.SECTION) != -1 && i == "ZBCS") {
+							    all[i]++;
+							    item.checked = true;
+							    this.selectDpList[i].push(item);
+							}
+							if (this.data.CDCS.indexOf(item.SECTION) != -1 && i == "CDCS") {
+							    all[i]++;
+							    item.checked = true;
+							    this.selectDpList[i].push(item);
+							}
+						})
+				    if (all[i] == this.DpList[i].length) {
+				        this.AllCheckedDp[i] = true;
+				    } else {
+				        this.AllCheckedDp[i] = false;
+				    }
+				}
+				// this.getOpinion1()
+				// this.getOther1()
+				// this.getOther()
+				this.opinionList = [{
+				    name: "拟办意见",
+				    col: "BGSNBYJ",
+				    show: !this.hide("show", "BGSNBYJ") && !this.hide("readonly", "BGSNBYJ")
+				}, {
+				    name: "领导批示",
+				    col: "WLDPS",
+				    show: !this.hide("show", "WLDPS") && !this.hide("readonly", "WLDPS")
+				}, {
+				    name: "分管领导办结确认",
+				    col: "FGLDBJQR",
+				    show: !this.hide("show", "FGLDBJQR") && !this.hide("readonly", "FGLDBJQR")
+				}, {
+				    name: "承办处室处理情况",
+				    col: "CBCSCLQK",
+				    show: !this.hide("show", "CBCSCLQK") && !this.hide("readonly", "CBCSCLQK")
+				}]
+				this.opinionList1 = [];
+				this.opinionList.forEach( (item)=> {
+				    if (item.show == true) {
+				        this.opinionList1.push(item)
+				    }
+				})
+				if (this.opinionList1.length > 0) {
+				    this.opiniontype = this.opinionList1[0].col;
+				}
+			})
+		},
+		getContent(){
+			if (self.Loaling == true) {
+			    return;
+			}
+			self.Loaling = true;
+			$("#pdfContent").nextAll("div").addClass("sp-page-loading")
+			self.pdfContent = [];
+			var data = {
+			    fileurl: self.seeFileItem.FILEURL
+			}
+			$http.post(apiurljs.login + "g2app/dataabase/queryPDFContent", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			.success(function (obj) {
+			    var res = strToJson(s4.decryptData_CBC(obj.data));
+			    self.Loaling = false;
+			    $("#pdfContent").nextAll("div").removeClass("sp-page-loading")
+			    for (var i in res.data) {
+			        self.pdfContent.push({ id: parseInt(i.slice(i.indexOf("_") + 1)), content: res.data[i] })
+			    }
+			    self.pdfContent.sort(function (a, b) {
+			        return a.id - b.id;
+			    })
+			})
+		},
+		getOpinion1(){
+			var data = {
+			    cmanid: self.userId,
+			    routeinfoid: self.routeinfoid,
+			    routeid: "",//self.routeid,
+			    tableid: "SW_ZJWWJCBD",
+			    colid: "",
+			    opiniontype: "",//self.opiniontype,
+			    orderbycol: "CDATE desc"
+			}
+			$http.post(apiurljs.login + "g2app/abase/queryDataOpinionWithRouteAttach", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			.success(function (obj) {
+			    var res = strToJson(s4.decryptData_CBC(obj.data));
+			    if (res.success == true) {
+			        self.YJ.nulla = res.data;
+			        self.YJ.nullaSTATUS = false;
+			        self.YJ.nulla.forEach(function (item) {
+			            item.CDATE = sp.datefmt("yyyy-MM-dd", item.CDATE);
+			            if (self.activeOpinion != null) {
+			                self.activeOpinion.FILEDATA = item.FILEDATA
+			            }
+			        })
+			    } else {
+			        sp.dialog(res.message)
+			    }
+			})
+		},
+		getOther1(){
+			var data = {
+			    tablename: "FILE_ATTACH",
+			    colums: "*",
+			    order: "ID asc",
+			    sqlwhere: { ROUTEINFOID: self.routeinfoid },
+			    sqlinwhere: "",
+			    sqllikewhere: { ATTACHTYPE: "-正文" }
+			}
+			$http.post(apiurljs.login + "g2app/dataabase/queryDataByCol", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			.success(function (obj) {
+			    var res = strToJson(s4.decryptData_CBC(obj.data));
+			    if (res.data.length > 0) {
+			        res.data.forEach(function (item) {
+			            if (item.ATTACHTYPE.indexOf("-正文") > -1) {
+			                self.arrayFile = item;
+			                self.seeFile(self.arrayFile)
+			            }
+			        })
+			    }
+			})
+		},
+		getOther(){
+			if (self.routeinfoid == 0) { return }
+			var data = {
+			    tablename: "FILE_ATTACH",
+			    colums: "*",
+			    order: "ID asc",
+			    sqlwhere: { ROUTEINFOID: self.routeinfoid },
+			    sqlinwhere: "",
+			    sqllikewhere: ""
+			}
+			$http.post(apiurljs.login + "g2app/dataabase/queryDataByCol", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			.success(function (obj) {
+			    var res = strToJson(s4.decryptData_CBC(obj.data));
+			    self.arrayFile1 = [];
+			    if (res.data.length > 0) {
+			        res.data.forEach(function (item) {
+			            if (item.ATTACHTYPE.indexOf("-正文") == -1) {
+			                self.arrayFile1.push(item)
+			            }
+			        })
+			        $timeout(function () {
+			            self.goAttach()
+			        },1000)
+			    }
+			})
+		},
+		hide(type, field){
+			if (this.dotype == 0 && type == "readonly") {
+			    return true;
+			} else {
+			    if (this[type][field] == true) {
+			        return true;
+			    } else {
+			        return false;
+			    }
+			}
+		},
+		btnEvent(item){
+			if (item.CODE == "NEWFLOWQB") {
+			    var data = {
+			        flowid: "AA65",
+			        userid: self.userId,
+			        routeinfoid: self.routeinfoid,
+			        directionid: self.directionid,
+			        copyrightid: self.copyrightid
+			    }
+			    $http.post(apiurljs.login + "g2app/fawenfiles/createNewWorkFlowWithGwtype", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			    .success(function (obj) {
+			        var res = strToJson(s4.decryptData_CBC(obj.data));
+			        console.log(res)
+			        window.top.sp.addTabNav(item.FUNCID, item.CNAME, "tpl/qianbaomgr/" + res.data.FILEN + "&dotype=1&flowid=AA65")
+			        $timeout(function () {
+			            window.top.sp.restoreWorkLayer("#wrapper_tabs_box_col_" + item.FUNCID)
+			        }, 1000)
+			    })
+			    return
+			} else if (item.CODE == "NEWFLOWDW") {
+			    var data = {
+			        flowid: "AA95",
+			        userid: self.userId,
+			        routeinfoid: self.routeinfoid,
+			        directionid: self.directionid,
+			        copyrightid: self.copyrightid
+			    }
+			    $http.post(apiurljs.login + "g2app/fawenfiles/createNewWorkFlowWithGwtype", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			    .success(function (obj) {
+			        var res = strToJson(s4.decryptData_CBC(obj.data));
+			        console.log(res)
+			        window.top.sp.addTabNav(item.FUNCID, item.CNAME, "tpl/DWHYTCB/" + res.data.FILEN + "&dotype=1&flowid=AA95")
+			        window.top.sp.restoreWorkLayer("#" + item.FUNCID)
+			    })
+			    return
+			} else if (item.CODE == "NEWFLOWXZ") {
+			    var data = {
+			        flowid: "AA10",
+			        userid: self.userId,
+			        routeinfoid: self.routeinfoid,
+			        directionid: self.directionid,
+			        copyrightid: self.copyrightid
+			    }
+			    $http.post(apiurljs.login + "g2app/fawenfiles/createNewWorkFlowWithGwtype", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			    .success(function (obj) {
+			        var res = strToJson(s4.decryptData_CBC(obj.data));
+			        console.log(res)
+			        window.top.sp.addTabNav(item.FUNCID, item.CNAME, "tpl/fawenbg/" + res.data.FILEN + "&dotype=1&flowid=AA10")
+			        $timeout(function () {
+			            window.top.sp.restoreWorkLayer("#wrapper_tabs_box_col_" + item.FUNCID)
+			        }, 1000)
+			    })
+			    return
+			}
+			switch (item.CODE) {
+			    case "SAVEITEM": self.btnSave(0); break;
+			    case "PRINTITEM": self.btnPrint(); break;
+			    case "PRINTITEMEXTEND": self.btnPrint1(); break;
+			    case "MEETITEM": self.Meet(); break;
+			    case "SENDLOG": self.RouteList(); break;
+			    default: self.forward(item); break;
+			}
+		},
+		openDpList(str){
+			if (self.hide("readonly", str) == true) {
+			    return
+			} else {
+			    self.filed = str;
+			    //self.AllCheckedDp = false;
+			    sp.layer("#DpList")
+			    $("#DpList .sp-page").eq(0).scrollTop(0);
+			}
+		},
+		checkAllDp(){
+			self.AllCheckedDp[self.filed] = !self.AllCheckedDp[self.filed];
+			$.each(self.DpList[self.filed], function (index, item) {
+			    item.checked = self.AllCheckedDp[self.filed];
+			})
+			self.submitDpList(1)
+		},
+		checkDpItem(item){
+			item.checked = !item.checked;
+			var n = 0;
+			$.each(self.DpList[self.filed], function (index, item) {
+			    if (item.checked == true) {
+			        n++
+			    }
+			})
+			if (n == self.DpList[self.filed].length) {
+			    self.AllCheckedDp[self.filed] = true;
+			} else {
+			    self.AllCheckedDp[self.filed] = false;
+			}
+			self.submitDpList(1)
+		},
+		submitDpList(n){
+			var AllCheckedLength1 = 0;
+			self.selectDpList[self.filed] = [];
+			$.each(self.DpList[self.filed], function (index, item) {
+			    if (item.checked == true) {
+			        AllCheckedLength1++;
+			        self.selectDpList[self.filed].push(item)
+			    }
+			})
+			self.data[self.filed] = self.selectDpList[self.filed].map(function (item) {
+			    return item.SECTION
+			}).join(",")
+			if (self.filed == "ZBCS") {
+			    self.data.ZBCSCODE = self.selectDpList[self.filed].map(function (item) {
+			        return item.CODE
+			    }).join(",")
+			    self.data.CDCS = self.data.CDCS == "" ? self.data.ZBCS : self.data.CDCS;
+			}
+			self.AllCheckedDp[self.filed] = AllCheckedLength1 == self.DpLength[self.filed];
+			self.changeFiled(self.filed)
+			if (n == 0) {
+			    sp.layerhide();
+			}
+		},
+		openLWDW(){
+			var data = {
+			      tablename: "CODE_LWDWLABEL"
+			  }
+			  //$http.post(apiurljs.login + "g2app/shouwen/getTreeListByTablename", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			  $http.post(apiurljs.login + "g2app/shouwen/getTreeListByTablename", data, postCfg)
+			      .success(function (obj) {
+			          //var res = strToJson(s4.decryptData_CBC(obj.data));
+			          var res = obj;
+			          self.getMenuBtnList(res.data);
+			          self.LWDW = res.data[0].C_H_I_L_D_DATA;
+			          self.LWDW.forEach(function (item) {
+			              item.show = true;
+			              item.C_H_I_L_D_DATA.forEach(function (item1) {
+			item1.checked = false;
+			                  if (item1.CNAME == self.data.LWDW) {
+			                      item1.checked = true;
+			                  }
+			              })
+			          })
+			          sp.layer("#openLWDW")
+			      })
+			      .error(function (XMLHttpRequest, textStatus, errorThrown) {
+			          self.treeData = [];
+			      })
+		},
+		checkItem(obj){
+			self.LWDW.forEach(function (item) {
+			    item.C_H_I_L_D_DATA.forEach(function (item1) {
+			        item1.checked = false;
+			        if (item1.ID == obj.ID) {
+			            item1.checked=true
+			        }
+			    })
+			})
+		},
+		submitLWDW(){
+			self.LWDW.forEach(function (item) {
+			    item.C_H_I_L_D_DATA.forEach(function (item1) {
+			        if (item1.checked == true) {
+			            self.data.LWDW = item1.CNAME;
+			        }
+			    })
+			})
+			console.log(self.data.LWDW)
+			self.changeFiled('LWDW')
+			sp.layerhide();
+		},
+		setLWDW(n){
+			var data = {
+			    tablename: "CODE_LWDWLABEL"
+			}
+			//$http.post(apiurljs.login + "g2app/shouwen/getTreeListByTablename", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			$http.post(apiurljs.login + "g2app/shouwen/getTreeListByTablename", data, postCfg)
+			    .success(function (obj) {
+			        //var res = strToJson(s4.decryptData_CBC(obj.data));
+			        var res = obj;
+			        self.getMenuBtnList(res.data);
+			        self.treeData = res.data;
+			        $timeout(function () {
+			            self.nowNodeCode = self.treeData[0].CODE;
+			            self.nowNodeName = self.treeData[0].CNAME;
+			            self.nowNodeID = self.treeData[0].ID;
+			            self.treeData[0].checked = true;
+			            if (n == 0) {
+			                sp.layer("#setLWDW")
+			            }
+			        })
+			    })
+			    .error(function (XMLHttpRequest, textStatus, errorThrown) {
+			        self.treeData = [];
+			    })
+		},
+		getMenuBtnList(data){
+			data.forEach(function (item) {
+			    item.checked = false;
+			    item.C_H_I_L_D_DATA_L = data.length;
+			    if (sp.isval(item.C_H_I_L_D_DATA) && item.C_H_I_L_D_DATA.length > 0) {
+			        self.getMenuBtnList(item.C_H_I_L_D_DATA);
+			    } else {
+			        item.C_H_I_L_D_DATA = [];
+			    }
+			})
+		},
+		itemAdd($item){
+			self.itemNode.level = $item.LEVELS;
+			self.itemNode.id = 0;
+			self.itemNode.name = $item.CNAME;
+			self.itemNode.code = $item.CODE;
+			self.itemNode.child_title = "";
+			self.rightFlag = 1;
+			console.log(self.itemNode)
+		},
+		itemEdit(){
+			self.itemNode.level = $item.LEVELS;
+			self.itemNode.id = $item.ID;
+			self.itemNode.name = $item.CNAME;
+			self.itemNode.code = $item.CODE;
+			self.itemNode.child_title = $item.CNAME;
+			self.rightFlag = 1;
+			console.log(self.itemNode)
+		},
+		itemDelete($item){
+			var data = {
+			    "id": $item.ID,
+			    "tablename": "CODE_LWDWLABEL",
+			    "parentid": $item.PARENTID,
+			    "formtablename": ""
+			}
+			$http.post(apiurljs.login + "g2app/dataabase/delNode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			.success(function (obj) {
+			    var res = strToJson(s4.decryptData_CBC(obj.data));
+			    if (res.success) {
+			        self.setLWDW(1);
+			        self.btnCancal();
+			    } else {
+			        sp.dialog(res.message);
+			    }
+			})
+		},
+		btnSetTitle(){
+			if (self.itemNode.id != 0) {
+			    if (spngvld.submit("#LWDW")) {
+			        let postData = {
+			            id: self.itemNode.id,
+			            tablename: "CODE_LWDWLABEL",
+			            data: {
+			                CNAME: self.itemNode.level == 2 ? self.itemNode.name : self.itemNode.child_title
+			            }
+			        }
+			        $http.post(apiurljs.login + "g2app/dataabase/upFormData", { data: s4.encryptData_CBC(JSON.stringify(postData)) }, postCfg)
+			            .success(function (obj) {
+			                var res = strToJson(s4.decryptData_CBC(obj.data));
+			                if (res.success) {
+			                    self.setLWDW(1);
+			                    self.btnCancal();
+			                } else {
+			                    sp.dialog(res.message);
+			                }
+			            })
+			            .error(function (XMLHttpRequest, textStatus, errorThrown) {
+			            })
+			    }
+			} else {
+			    if (spngvld.submit("#LWDW")) {
+			        let postData = {
+			            tablename: "CODE_LWDWLABEL",
+			            code: self.itemNode.code,
+			            levels: self.itemNode.level,
+			            cname: self.itemNode.level == 1 ? self.itemNode.name : self.itemNode.child_title,
+			            userid: self.userId
+			        }
+			        $http.post(apiurljs.login + "g2app/shouwen/TreeAdd", { data: s4.encryptData_CBC(JSON.stringify(postData)) }, postCfg)
+			            .success(function (obj) {
+			                var res = strToJson(s4.decryptData_CBC(obj.data));
+			                if (res.success) {
+			                    self.setLWDW(1);
+			                    self.btnCancal();
+			                } else {
+			                    sp.dialog(res.message);
+			                }
+			            })
+			            .error(function (XMLHttpRequest, textStatus, errorThrown) {
+			            })
+			    }
+			}
+		},
+		btnCancal(){
+			self.itemNode = {
+			    level: "",
+			    id: "",
+			    name: "",
+			    code: "",
+			    child_title: ""
+			}
+			self.rightFlag = 0;
+		},
+		  //保存提交
+		btnSave(n){
+			if (self.repeat == true) {
+			    return
+			}
+			if (spngvld.submit(".formedit")) {
+			    if (self.data.SFDB == "C01" && self.data.DBSX == "") {
+			        sp.dialog("请填写督办时限!");
+			        return
+			    }
+			    if (self.data.DBSX == "") {
+			        sp.dialog("督办时限不能为空!已为您设为来文日期后15天!")
+			        self.data.DBSX = sp.getNextDate(self.data.LWRQ, 15);
+			        self.data.CPSX = sp.getNextDate(self.data.LWRQ, 13);
+			        return
+			    }
+			    if (self.data.SWBH1 == "") {
+			        var postData = {
+			            swcode: self.SWBH,
+			            cuserid: self.userId,
+			            flowid: sp.getUrlName("flowid")
+			        }
+			        $http.post(apiurljs.login + "g2app/shouwen/saveSWCodeBySWCode", { data: s4.encryptData_CBC(JSON.stringify(postData)) }, postCfg)
+			        .success(function (obj1) {
+			            var res1 = strToJson(s4.decryptData_CBC(obj1.data));
+			            if (res1.success) {
+			                if (res1.data == "-1") {
+			                    sp.dialog("保存失败!");
+			                    return;
+			                }
+			                var dataArray = [];
+			                self.data.USAGE = self.selectUSAGEs.join(",")
+			                dataArray.push(self.data);
+			                var data = {
+			                    ckey: "SW_ZJWWJCBD",
+			                    id: self.data.ID,
+			                    routeid: self.routeid,
+			                    routeinfoid: self.routeinfoid,
+			                    routeinfotitle: self.data.BT.replace(/\n/g, '').replace(/\s/g, ''),//self.data.BT,
+			                    directionid: self.directionid,
+			                    formeditid: self.formeditid,
+			                    data: JSON.stringify(dataArray)
+			                }
+			                $http.post(apiurljs.login + "g2app/abase/saveData", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			                .success(function (obj) {
+			                    var res = strToJson(s4.decryptData_CBC(obj.data));
+			                    if (res.code == 0) {
+			                        self.data.ID = res.data.ID;
+			                        self.routeid = res.data.ROUTEID;
+			                        self.routeinfoid = res.data.ROUTEINFOID;
+			                        self.filedChange = false;
+			                        if (n == 0) {
+			                            if (res1.data != self.SWBH.split("|")[2]) {
+			                                sp.dialog("收文编号已改变!")
+			                            } else {
+			                                sp.dialog("保存成功!");
+			                            }
+			                            $timeout(function () {
+			                                sp.dialoghide()
+			                            }, 1500)
+			                            self.getSwenList(1)
+			                        } else if (n == 1) {
+			                            self.forward(self.btnItem);
+			                        } else if (n == 2) {
+			                            self.sendAll();
+			                        } else if (n == 3) {
+			                            self.btnPrint();
+			                        }
+			                    } else {
+			                        sp.dialog(res.message)
+			                    }
+			                })
+			            } else {
+			                sp.dialog(res1.message)
+			            }
+			        })
+			    } else {
+			        var dataArray = [];
+			        self.data.USAGE = self.selectUSAGEs.join(",")
+			        dataArray.push(self.data);
+			        var data = {
+			            ckey: "SW_ZJWWJCBD",
+			            id: self.data.ID,
+			            routeid: self.routeid,
+			            routeinfoid: self.routeinfoid,
+			            routeinfotitle: self.data.BT.replace(/\n/g, '').replace(/\s/g, ''),//self.data.BT,
+			            directionid: self.directionid,
+			            formeditid: self.formeditid,
+			            data: JSON.stringify(dataArray)
+			        }
+			        $http.post(apiurljs.login + "g2app/abase/saveData", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			        .success(function (obj) {
+			            var res = strToJson(s4.decryptData_CBC(obj.data));
+			            if (res.code == 0) {
+			                self.data.ID = res.data.ID;
+			                self.routeid = res.data.ROUTEID;
+			                self.routeinfoid = res.data.ROUTEINFOID;
+			                self.filedChange = false;
+			                if (n == 0) {
+			                    sp.dialog("保存成功!");
+			                    $timeout(function () {
+			                        sp.dialoghide()
+			                    }, 1500)
+			                    self.getSwenList(1)
+			                } else if (n == 1) {
+			                    self.forward(self.btnItem);
+			                } else if (n == 2) {
+			                    self.sendAll();
+			                } else if (n == 3) {
+			                    self.btnPrint();
+			                }
+			            } else {
+			                sp.dialog(res.message)
+			            }
+			        })
+			    }
+			}
+		},
+		btnPrint(){
+			if (self.filedChange == true) {
+			    self.btnSave(3)
+			} else {
+			    // 创建隐藏的可下载链接
+			    var eleLink = document.createElement('a');
+			    eleLink.download = "";
+			    eleLink.style.display = 'none';
+			    eleLink.href = apiurljs.login + "g2app/shouwen/PrintWord?data=" + encodeURIComponent(s4.encryptData_CBC("templatefilename=moban33.ftl&tablename=SW_ZJWWJCBD&outfilepath=/tmp/行政公文.wps&printdate=LWRQ,DBSX,ZBRQ&routeinfoid=" + self.routeinfoid));
+			    // 触发点击
+			    document.body.appendChild(eleLink);
+			    eleLink.click();
+			    // 然后移除
+			    document.body.removeChild(eleLink);
+			}
+		},
+		 /*综合打印*/
+		 btnPrint1(){
+			 if (self.filedChange == true) {
+			     self.btnSave(3)
+			 } else {
+			     sp.layer("#print")
+			 }
+		 },
+		 printSubmit(){
+			 if (self.printFiled == 1) {
+			     var templatefilename = "moban33"
+			 } else if (self.printFiled == 2) {
+			     var templatefilename = "mobanoption"
+			 } else {
+			     var templatefilename = "moban33_all"
+			 }
+			 var data = {
+			     templatefilename: templatefilename + ".ftl",
+			     outfilepath: "/tmp/行政公文" + sp.datefmt('yyyyMMddHHmmss', sp.getLocalDate()) + ".wps",
+			     routeinfoid: self.routeinfoid,
+			     tablename: "SW_ZJWWJCBD",
+			     printtype: self.printFiled,
+			     printdate: "LWRQ,DBSX,ZBRQ"
+			 }
+			 $http.post(apiurljs.login + "g2app/dataabase/PrintWordExtend", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			 .success(function (obj) {
+			     var res = strToJson(s4.decryptData_CBC(obj.data));
+			     if (self.deviceType == "pad") {
+			         window.location.href = "../../../printPreview.html?url=" + apiurljs.yzFcscloud + "g2work" + res.data[0].url
+			     } else {
+			         sp.openNewWindow("../../../printPreview.html?url=" + apiurljs.yzFcscloud + "g2work" + res.data[0].url, '打印预览')
+			     }
+			 })
+			 sp.layerhide()
+		 },
+		 openOptionList(){
+			 if (self.routeinfoid == 0 && self.routeid == 0) {
+			     sp.dialog("请先保存!")
+			     return;
+			 }
+			 if (self.dotype == 0) {
+			     return
+			 }
+			 if (self.opinion.nulla == true) {
+			     return;
+			 }
+			 self.nulla = "";
+			 self.opinion.nulla = true;
+		 },
+		openOptionList1(){
+			self.openOptionList()
+			self.activeOpinion = null;
+			self.showBottom = "opinion";
+			self.YJ.nulla.forEach(function (item) {
+			    if (item.ROUTEID == self.routeid) {
+			        self.activeOpinion = item;
+			        self.nulla = item.OPINION;
+			    }
+			})
+			$(".toggle").trigger("click")
+		},
+		closeOptionList(){
+			self.opinion.nulla = false;
+			self.activeOpinion = null;
+			$(".toggle").trigger("click")
+		},
+		submitOptionList(){
+			var data = {
+			    cmanid: self.userId,
+			    routeinfoid: self.routeinfoid,
+			    routeid: self.routeid,
+			    tableid: "SW_ZJWWJCBD",
+			    colid: self.opiniontype,
+			    opiniontype: self.opiniontype == "nulla" ? 99 : 0,
+			    cresult: "",
+			    opinion: self.nulla,
+			    opinionimage: ""
+			}
+			if (self.opiniontype == "BGSNBYJ") {
+			    data.cmans = "王勇";
+			}
+			$http.post(apiurljs.login + "g2app/abase/saveDataOpinion", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			.success(function (obj) {
+			    var res = strToJson(s4.decryptData_CBC(obj.data));
+			    if (res.success == true) {
+			        self.getOpinion1();
+			        self.opinion.nulla = false;
+			        $(".toggle").trigger("click")
+			    } else {
+			        sp.dialog(res.message)
+			    }
+			})
+		},
+		changeOptionList(item){
+			self.showBottom = "opinion";
+			self.opinion.nulla = true;
+			self.nulla = item.OPINION;
+			self.activeOpinion = item;
+			$(".toggle").trigger("click")
+		},
+		 //意见附件(下表)
+		upload1(){
+			$('#fileupload1').fileupload({
+			    url: apiurljs.login + 'g2app/abase/UploadWholeFileWithRouteAttach',
+			    dataType: 'json',
+			    beforeSend: function (xhr, data) {
+			        xhr.setRequestHeader("Authorization", "Bearer " + self.get_AccessToken);
+			        xhr.setRequestHeader("File-Argument", s4.encryptData_CBC("tablename=SYS_ROUTE_ATTACHLIST,userid=" + self.userId + ",routeinfoid=" + self.routeinfoid
+			             + ",routeid=" + self.routeid + ",tableid=SW_ZJWWJCBD,colid=" + self.opiniontype));
+			    },
+			    // 上传完成后的执行逻辑
+			    done: function (e, data) {
+			        self.uploading1 = false;
+			        self.getOpinion1()
+			    }
+			})
+		},
+		upload2(str){
+			$('#fileupload2').fileupload({
+			    url: apiurljs.login + 'g2app/abase/UploadWholeFileWithRouteAttach',
+			    dataType: 'json',
+			    beforeSend: function (xhr, data) {
+			        xhr.setRequestHeader("Authorization", "Bearer " + self.get_AccessToken);
+			        xhr.setRequestHeader("File-Argument", s4.encryptData_CBC("tablename=SYS_ROUTE_ATTACHLIST,userid=" + self.userId + ",routeinfoid=" + self.routeinfoid
+			             + ",routeid=" + self.routeid + ",tableid=SW_ZJWWJCBD,colid=" + str));
+			    },
+			    // 上传完成后的执行逻辑
+			    done: function (e, data) {
+			        self.uploading1 = false;
+			        self.getOpinion1()
+			    }
+			})
+		},
+		    //下载意见表附件
+		downLoadOption(item){
+			window.open(apiurljs.login + "g2work/files/" + item.FILEPATH.slice(7))
+			
+		},
+		    //删除意见表附件
+		deleteOptionFile(file){
+			var data = {
+			    routeid: file.ROUTEID,
+			    tableid: "SW_ZJWWJCBD",
+			    colid: file.COLID,
+			    fileid: file.FILEID
+			};
+			$http.post(apiurljs.login + "g2app/abase/deleteDataOpinionWithRouteAttach", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			    .success(function (obj) {
+			        var res = strToJson(s4.decryptData_CBC(obj.data));
+			        sp.dialoghide();
+			        if (res.success) {
+			            self.getOpinion1();
+			        } else {
+			            sp.dialog("删除失败,请联系管理员!");
+			        }
+			    });
+		},
+		//删除意见
+			Dopinion(item){
+				var data = {
+				    cmanid: self.userId,
+				    routeid: self.routeid,
+				    tableid: "SW_ZJWWJCBD",
+				    colid: item.COLID,
+				}
+				$http.post(apiurljs.login + "g2app/abase/deleteDataOpinion", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+				.success(function (obj) {
+				    var res = strToJson(s4.decryptData_CBC(obj.data));
+				    if (res.success == true) {
+				        self.getOpinion1();
+				        self.nulla = "";
+				        self.activeOpinion = null;
+				        self.changeFiled(item.COLID)
+				    } else {
+				        sp.dialog(res.message)
+				    }
+				})
+			},
+			
+		phrase(colid){
+			sp.layer("#phrase");
+			self.colid = colid;
+			self.getPhrase();
+		},
+		Aphrase(){
+			if (self.phraseText == "") {
+			    return;
+			}
+			var data = {
+			    cmanid: self.userId,
+			    tableid: "SW_ZJWWJCBD",
+			    colid: self.colid,
+			    contents: self.phraseText
+			}
+			$http.post(apiurljs.login + "g2app/abase/insertDataPatterns", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			.success(function (obj) {
+			    var res = strToJson(s4.decryptData_CBC(obj.data));
+			    if (res.success == true) {
+			        self.phraseText = "";
+			        self.getPhrase();
+			    } else {
+			        sp.dialog(res.message)
+			    }
+			})
+		},
+		    //获取常用语库
+		getPhrase(){
+			var data = {
+			    cmanid: self.userId,
+			    tableid: "SW_ZJWWJCBD",
+			    colid: self.colid
+			}
+			$http.post(apiurljs.login + "g2app/abase/queryDataPatterns", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			.success(function (obj) {
+			    var res = strToJson(s4.decryptData_CBC(obj.data));
+			    self.phraseList = res.data;
+			    self.phraseSelect = self.phraseList[0].CONTENTS;
+			})
+		},
+		    //从常用语库删除
+		Dphrase(){
+			var id = null;
+			$.each(self.phraseList, function (index, item) {
+			    if (item.CONTENTS == self.phraseSelect) {
+			        id = item.ID;
+			    }
+			})
+			var data = {
+			    id: id
+			}
+			$http.post(apiurljs.login + "g2app/abase/deleteDataPatterns", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			.success(function (obj) {
+			    var res = strToJson(s4.decryptData_CBC(obj.data));
+			    self.getPhrase();
+			})
+		},
+		btnPhrase(){
+			self.nulla = self.phraseSelect;
+			sp.layerhide();
+		},
+		selectUSAGE(item){
+			item.checked = !item.checked;
+			self.selectUSAGEs = [];
+			$.each(self.USAGE, function (index, item) {
+			    if (item.checked == true) {
+			        self.selectUSAGEs.push(item.CODE)
+			    }
+			})
+			self.changeFiled('USAGE')
+		},
+		changeFiled(str){
+			self.filedChange = true;
+			if (self.data.SFDB != "C01") {
+			    self.data.DBLX = "";
+			    self.data.SWQXLX = "办理";
+			} else {
+			    self.data.SWQXLX = "督办";
+			    //self.data.DBLX = self.DBTYPE[0].CODE;
+			}
+			
+			if(str == "DBSX"){
+				let objDate = new Date()
+				let DBSXDate = new Date(self.data.DBSX)
+				let dif_t = DBSXDate.getTime() - objDate.getTime();
+				let Day_dif_t = dif_t/(1000*60*60*24)
+				if(Day_dif_t>10){
+					self.data.CPSX = sp.getNextDate(self.data.DBSX, -2);
+				}else{
+					self.data.CPSX = sp.getNextDate(self.data.DBSX, -1);
+				}
+				
+			}
+		},
+		verify(str){
+			if (self.data[str] == "") { return; }
+			var data = {
+			    tablename: "SW_ZJWWJCBD",
+			    colums: "*",
+			    order: "ID desc",
+			    sqlwhere: {},
+			    sqlinwhere: "",
+			    sqllikewhere: ""
+			}
+			data.sqlwhere[str] = self.data[str]
+			$http.post(apiurljs.login + "g2app/dataabase/queryDataByCol", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			.success(function (obj) {
+			    var res = strToJson(s4.decryptData_CBC(obj.data));
+			    if (res.data.length > 0 && self.data.ID != res.data[0].ID) {
+			        self.repeat = true;
+			        sp.dialog("标题已存在,请修改后重试!")
+			    } else {
+			        self.repeat = false;
+			    }
+			})
+		},
+		    //转发
+		forward(){
+			self.btnItem = obj;
+			if (self.filedChange == true) {
+			    self.btnSave(1)
+			} else {
+			    $("#forwardWin").attr("src", "../../forward/forward.html?routeid=" + self.routeid + "&routeinfoid=" + self.routeinfoid + "&copyrightid=" + self.copyrightid + "&directionid=" + self.directionid + "&formeditid=" + self.formeditid + "&codefuncbutton=" + obj.CODE + "&directionidtarget=" + obj.DIRECTIONIDTARGET + "&cookie=shouwenbg")
+			    sp.layer("#forward")
+			}
+		},
+		//查看流转记录
+		RouteList(){
+			if (self.deviceType == "pad") {
+			    window.location.href = "../../forward/modeler_read.html?" + self.SwenList[0].TEMPFORM.split("?")[1]
+			} else {
+			    sp.openNewWindow("../../forward/modeler_read.html?" + self.SwenList[0].TEMPFORM.split("?")[1], "流程图")
+			}
+		},
+		reSize(n){
+			var leftbox = document.getElementsByClassName("page-item")[n - 1];
+			var rightbox = document.getElementsByClassName("page-item")[n];
+			var line = document.getElementsByClassName("iframe-border-right")[n - 1];
+			document.getElementsByClassName("iframe-border-right")[n - 1].addEventListener("mousedown", function (event) {
+			    $(".mousemove").show()
+			    var leftboxW = leftbox.clientWidth;//leftbox.style.width.slice(0, leftbox.style.width.length - 2);
+			    var rightboxW = rightbox.clientWidth;//rightbox.style.width.slice(0, rightbox.style.width.length - 2);
+			    var x = event.pageX - line.offsetLeft;
+			    document.addEventListener("mousemove", boxMove)
+			    function boxMove(event) {
+			        if (leftboxW * 1 + (event.pageX - x) * 1 <= 200) {
+			            //$(".leftBox").children().not(".iframe-border-right").hide()
+			        } else if (rightboxW * 1 - (event.pageX - x) * 1 <= 200) {
+			            //$(".rightBox").children().not(".iframe-border-right").hide()
+			        } else {
+			            leftbox.style.width = leftboxW * 1 + (event.pageX - x) * 1 + "px";
+			            leftbox.getElementsByTagName("iframe")[0].style.width = leftboxW * 1 + (event.pageX - x) * 1 - 10 + "px";
+			            //$(".leftBox").children().not(".iframe-border-right").show()
+			
+			            rightbox.style.width = rightboxW * 1 - (event.pageX - x) * 1 + "px";
+			            //rightbox.getElementsByTagName("iframe")[0].style.width = rightboxW * 1 - (event.pageX - x) * 1 - 10 + "px";
+			            //$(".rightBox").children().not(".iframe-border-right").show()
+			        }
+			    }
+			    document.addEventListener("mouseup", function () {
+			        $(".mousemove").hide()
+			        document.removeEventListener("mousemove", boxMove)
+			    })
+			})
+		},
+		reSizeRow(){
+			var bodybox = document.getElementById("bodyDiv");
+			var topbox = document.getElementById("topDiv");
+			var bottombox = document.getElementById("bottomDiv");
+			var line = document.getElementById("lineDiv");
+			document.getElementById("lineDiv").addEventListener("mousedown", function (event) {
+			    $(".mousemove").show()
+			    var bodyboxH = bodybox.clientHeight;
+			    var topboxH = topbox.clientHeight;
+			    var bottomboxH = bottombox.clientHeight;
+			    //var y = event.pageY - line.offsetTop;
+			    var y = event.pageY - line.clientHeight;
+			    document.addEventListener("mousemove", boxMove)
+			    function boxMove(event) {
+			        if (topboxH * 1 + (event.pageY - y) * 1 - 36 <= 45) {
+			            //
+			        } else if (bottomboxH * 1 - (event.pageY - y) * 1 - 36 <= 45) {
+			            //
+			        } else {
+			            topbox.style.height = topboxH * 1 + (event.pageY - y) * 1 - 36 + "px";
+			            topbox.getElementsByTagName("iframe")[0].style.height = topboxH * 1 + (event.pageY - y) * 1 - 45 + "px";
+			
+			            bottombox.style.height = bodyboxH * 1 - topboxH * 1 - (event.pageY - y) * 1 + 36 - 45 + "px";
+			            bottombox.getElementsByTagName("iframe")[0].style.height = bodyboxH * 1 - topboxH * 1 - (event.pageY - y) * 1 + 36 - 75 + "px";
+			        }
+			    }
+			    document.addEventListener("mouseup", function () {
+			        $(".mousemove").hide()
+			        document.removeEventListener("mousemove", boxMove)
+			    })
+			})
+		},
+		headBtnSearch(){
+			if (sp.isval(self.headBtnSearchKeyword)) {
+			    self.headSearchResult = [];
+			    var data = {
+			        "url": "/basic/api/StatSelect/selectCodeList",
+			        "data": { "keyWord": self.headBtnSearchKeyword }
+			    }
+			    //console.log(JSON.stringify(data));
+			    $http.post(apiurljs.login + "g2app/yizhangtu/selectCodeList", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+			    .success(function (obj) {
+			        var res = strToJson(s4.decryptData_CBC(obj.data));
+			        //console.log(JSON.stringify(res.data));
+			        self.headSearchResult = res.data.build;
+			        if (sp.isval(self.headSearchResult)) {
+			            self.headSearchResult_view = true;
+			        } else {
+			            self.headSearchResult_view = false;
+			        }
+			    })
+			} else {
+			    self.headSearchResult_view = false;
+			}
+		},
+		headKeywordPage(){
+			var get_token = localStorage.getItem("main-token");
+			var set_url = apiurljs.onePic + "wholeProcessPage/?token=" + get_token + "&name=" + itemdata.name + "&type=" + itemdata.type + "&id=" + itemdata.id;
+			sp.openNewWindow(set_url, '一张图');
+			self.headSearchResult_view = false;
+		},
+		onePic(){
+			sp.openNewWindow(apiurljs.onePic + "wholeProcessPage/?token=" + localStorage.getItem("main-token"), "地图搜索")
+			
+		},
+		closeToggle(){
+			$timeout(function () {
+			    self.opinion.nulla = false;
+			    self.activeOpinion = null;
+			})
+		}
+		
+	}
+
+})
+
+var app = angular.module('app', [
+]);
+
+app.controller("formeditCtrl", ["$scope", "$http", "$timeout", "$sce", function ($scope, $http, $timeout, $sce) {
+    var self = this;
+    var s4 = new SM4Util();
+
+    self.userId = $.cookie("GlWorkPlatform-userid");
+    self.userName = $.cookie("GlWorkPlatform-chineseName");
+    self.get_AccessToken = localStorage.getItem("GlWorkPlatform-AccessToken");
+    self.routeid = sp.getUrlName("routeid");
+    self.routeinfoid = sp.getUrlName("routeinfoid");
+    self.copyrightid = sp.getUrlName("copyrightid");
+    self.directionid = sp.getUrlName("directionid");
+    self.formeditid = sp.getUrlName("formeditid");
+    self.mbid = sp.getUrlName("mbid");
+    self.fjid = sp.getUrlName("fjid");
+    self.docmode = sp.getUrlName("docmode");
+    self.dotype = sp.getUrlName("dotype");
+    self.get_lastReturnPageno = sp.getUrlName("lastReturnPageno");
+    self.get_lastReturnPage = sp.getUrlName("lastReturnPage");
+    self.get_type = sp.getUrlName("type");
+    self.return = "../list.html?lastReturnPageno=" + self.get_lastReturnPageno + "&type=" + self.get_type
+    self.deviceType = localStorage.getItem("tjJxtGoldenlinkWork-deviceType");
+
+    var postCfg = {
+        headers: {
+            'Content-Type': 'application/json',
+            'Authorization': "Bearer " + self.get_AccessToken
+        }
+    };
+    self.FormTitle = $.cookie("GlWorkPlatform-SYSNAME");
+    //初始化右上角按钮
+    self.buttonList = []
+
+
+
+    //上层附件、业务参考、共享沟通组件
+    self.arrayFile = null;
+    self.arrayFile1 = [];
+    self.uploading_zw = false;
+    self.uploading = false;
+    self.upload_zw = function () {
+			var uploadformat = strToJson(s4.decryptData_CBC(apiurljs.uploadformat)).data.map(function (item) {
+			    return item.CNAME
+			})
+        $('#fileupload-zw').fileupload({
+            url: apiurljs.login + (self.routeinfoid == 0 ? 'g2app/abase/uploadFileWithFormWithSaveRouteinfo' : 'g2app/abase/uploadFileWithFormAndGetPage'),//'g2app/abase/uploadFileWithForm'),
+            dataType: 'json',
+            beforeSend: function (xhr, data) {
+                xhr.setRequestHeader("Authorization", "Bearer " + self.get_AccessToken);
+                if (self.routeinfoid == 0) {
+                    xhr.setRequestHeader("File-Argument", s4.encryptData_CBC("copyrightid=" + self.copyrightid + ",directionid=" + self.directionid + ",formeditid=" + self.formeditid + ",routeinfoid=" + self.routeinfoid + ",routeid=" + self.routeid + ",tablename=FILE_ATTACH,ATTACHTYPE=行政公文-正文"));
+                } else {
+                    xhr.setRequestHeader("File-Argument", s4.encryptData_CBC("tablename=FILE_ATTACH,routeinfoid=" + self.routeinfoid + ",ATTACHTYPE=行政公文-正文"));
+                }
+            },
+            add: function (e, data) {
+                var num = 0;
+                var acceptFileTypes = eval('/(' + uploadformat.join("|") + ')$/i')
+                //文件类型判断
+                $.each(data.originalFiles, function (index, item) {
+                    if (item['type'].length > 0 && !acceptFileTypes.test(item['name'])) {
+                        sp.dialog("您好,请上传" + uploadformat.join("/") + "格式的文件!");
+                        return;
+                    } else {
+                        num++
+                    }
+                })
+                if (num == data.originalFiles.length) {
+                    self.uploading_zw = true;
+                    data.submit();
+                    $scope.$apply();
+                }
+            },
+            // 上传完成后的执行逻辑
+            done: function (e, data) {
+                self.uploading_zw = false;
+                if (self.routeinfoid == 0) {
+                    var res = strToJson(s4.decryptData_CBC(data.result.data));
+                    self.data.ID = res.data2.ID;
+                    self.routeid = res.data2.ROUTEID;
+                    self.routeinfoid = res.data2.ROUTEINFOID;
+                    self.getSwenList(0)
+                } else {
+                    self.getOther1()
+                }
+            }
+        })
+    }
+    self.upload = function () {
+			var uploadformat = strToJson(s4.decryptData_CBC(apiurljs.uploadformat)).data.map(function (item) {
+			    return item.CNAME
+			})
+        $('#fileupload').fileupload({
+            url: apiurljs.login + 'g2app/abase/uploadFileWithFormAndGetPage',//'g2app/abase/uploadFileWithForm',
+            dataType: 'json',
+            beforeSend: function (xhr, data) {
+                xhr.setRequestHeader("Authorization", "Bearer " + self.get_AccessToken);
+                xhr.setRequestHeader("File-Argument", s4.encryptData_CBC("tablename=FILE_ATTACH,routeinfoid=" + self.routeinfoid + ",ATTACHTYPE=行政公文"));
+            },
+            add: function (e, data) {
+                var num = 0;
+                var acceptFileTypes = eval('/(' + uploadformat.join("|") + ')$/i')
+                //文件类型判断
+                $.each(data.originalFiles, function (index, item) {
+                    if (item['type'].length > 0 && !acceptFileTypes.test(item['name'])) {
+                        sp.dialog("您好,请上传" + uploadformat.join("/") + "格式的文件!");
+                        return;
+                    } else {
+                        num++
+                    }
+                })
+                if (num == data.originalFiles.length) {
+                    self.uploading = true;
+                    data.submit();
+                    $scope.$apply();
+                }
+            },
+            // 上传完成后的执行逻辑
+            done: function (e, data) {
+                self.uploading = false;
+                self.getOther()
+            }
+        })
+    }
+    self.downLoad = function (item) {
+        window.open(apiurljs.login + "g2work/files/" + item.FILEURL.slice(7))
+    }
+    self.deleteFile = function (file) {
+        var dialogHead = "<span class=\"sp-dialog-head\"><span class=\"sp-dialog-tip\">温馨提示</span><span class=\"sp-dialog-close sp-closeDialog\" title=\"关闭\">×</span></span>";
+        var dialogBody = "<div class=\"sp-dialog-body\">删除后不可恢复,您确认要删除吗?</div>";
+        var dialogFoot = "<div class=\"sp-dialog-foot\"><input id='delDataTrue' type='button' value='确 认' class='sp-dialog-btnTrue' /><input type='button' value='取 消' class='sp-dialog-btnCancle sp-closeDialog' /></div>";
+        $('.sp-dialog').html(dialogHead + dialogBody + dialogFoot);
+
+        sp.openCenter(".sp-dialog");
+
+        ///取消按钮
+        $('.sp-closeDialog').click(function (event) {
+            sp.closeCenter(".sp-dialog");
+            event.preventDefault();
+            event.stopPropagation();
+        });
+        //post消息的id
+        $("#delDataTrue").click(function () {
+            var data = {
+                tablename: "FILE_ATTACH",
+                id: file.ID
+            };
+						delDataById(data).then(res=>{
+							sp.dialoghide();
+							if (res.success) {
+							    self.getOther();
+							} else {
+							    sp.dialog("删除失败,请联系管理员!");
+							}
+						})
+        });
+    }
+		
+    self.seeFile = function (obj) {
+        self.seeFileItem = obj;
+        var set_convertType = 0;
+        if (obj.FILEEXT == "doc") {
+            set_convertType = 0;
+        } else if (obj.FILEEXT == "pdf") {
+            set_convertType = 20;
+        } else if (obj.FILEEXT == "ofd") {
+            set_convertType = 570;
+        } else {
+            set_convertType = 0;
+        }
+        let postData = {
+            convertType: set_convertType,
+            isSignature: 1,
+            signCallback: "g2app/fawenfiles/uploadFileFCS/" + obj.FILEURL.slice(7),
+            fileUrl: apiurljs.login + "g2work/files2/inline/" + obj.FILEURL.slice(7)
+        };
+        var postCfg_transfer = {
+            headers: { 'Content-Type': 'application/x-www-form-urlencoded' },
+            transformRequest: function (data) {
+                return $.param(data);
+            }
+        };
+        $http.post(apiurljs.login.split("glwork/")[0] + "fcscloud/composite/httpfile", postData, postCfg_transfer)
+        .success(function (res) {
+            if (res.errorcode === 0) {
+               //$("#iframe_book").css("height", $(".ibox-content").height() - 123)
+                $("#iframe_book").attr("src", res.data.viewUrl)
+            } else {
+                sp.dialog(res.message);
+            }
+        });
+    }
+	self.goAttach = function (obj) {
+	    if (obj) {
+	        if (apiurljs.zhType.indexOf(obj.FILEEXT) == -1) {
+	            sp.dialog("文件暂不支持在线预览,请点击下载查看!")
+	            return
+	        }
+		    $("#attachlist")[0].contentWindow.openFile(obj)
+		    if ($(".fa-chevron-down").is(":hidden") == true) {
+		        showToggle(document.getElementById("toggleButton"))
+		    }
+		} else {
+		    $("#attachlist").attr("src", "attachlist.html?routeinfoid=" + self.routeinfoid)
+		}
+	}
+
+    self.readonly = {
+			  CPSX: true,
+        JJCD: false,
+        MIJI: false,
+		SWLB: false,
+        SWBH: false,
+        LWDW: false,
+        LWRQ: false,
+        LWWH: false,
+        SFDB: false,
+        BT: false,
+        DBSX: false,
+        CDCS: false,
+        ZBCS: false,
+        SFBJ: false,
+        BJQK: false,
+        BZ: false,
+        NGR: false,
+        ZBRQ: false,
+        USAGE: false
+    }
+    self.show = {
+			  CPSX: false,
+        JJCD: false,
+        MIJI: false,
+				SWLB: false,
+        SWBH: false,
+        LWDW: false,
+        LWRQ: false,
+        LWWH: false,
+        SFDB: false,
+        BT: false,
+        DBSX: false,
+        CDCS: false,
+        ZBCS: false,
+        SFBJ: false,
+        BJQK: false,
+        BZ: false,
+        NGR: false,
+        ZBRQ: false,
+        USAGE: false
+    }
+
+    self.getSwenList = function (n) {
+        self.SwenList = [];
+        var data = {
+            directionid: self.directionid,
+            userid: self.userId,
+            routeinfoid: self.routeinfoid,
+            routeid: self.routeid,
+            formeditid: ""
+        }
+        $http.post(apiurljs.login + "g2app/abase/queryDataLink", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            if (self.copyrightid == "") {
+                self.copyrightid = res.data.LINKS[0].COPYRIGHTID
+            }
+            $.each(res.data.LINKS, function (index, item) {
+                item.TEMPFORM = item.TEMPFORM + "&flowid=" + sp.getUrlName("flowid")
+                if (item.TEMPFORM.indexOf("formeditZW.html") > -1) {
+                    self.Title = item.VNAME;
+                }
+                if (item.TEMPFORM.indexOf("?docmode") > 0) {
+                    item.TEMPFORM = item.TEMPFORM + "&dotype=" + self.dotype + "&type=" + self.get_type + "&lastReturnPageno=" + self.get_lastReturnPageno + "&lastReturnPage=" + self.get_lastReturnPage;
+                } else {
+                    item.TEMPFORM = "#";
+                }
+                self.SwenList.push(item)
+            })
+            self.SwenList.push({
+                VNAME: "流程图",
+                DIRECTIONID: self.SwenList[0].DIRECTIONID,
+                TEMPFORM: "modeler_read.html?" + self.SwenList[0].TEMPFORM.split("?")[1]
+            })
+            if (n == 0) {
+                self.getFLOW()
+            } else {
+                self.getData()
+            }
+        })
+    }
+    self.getSwenList(0)
+
+    self.getFLOW = function () {
+        var data = {
+            copyrightid: self.copyrightid
+        }
+        $http.post(apiurljs.login + "g2work/flow/queryDataByCopyrightid", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            self.flowTitle = res.data.CNAME;
+            self.getJJQK()
+        })
+    }
+
+    self.getJJQK = function () {
+        var data = {
+            ckey: "CODE_EMERGENCY",
+            routeinfoid: self.routeinfoid
+        }
+        $http.post(apiurljs.login + "g2app/abase/queryDataCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            self.JJCD = res.data.CODE_EMERGENCY;
+            self.getCDDB()
+        })
+    }
+    self.getCDDB = function () {
+        var data = {
+            ckey: "CODE_DUBAN",
+            routeinfoid: self.routeinfoid
+        }
+        $http.post(apiurljs.login + "g2app/abase/queryDataCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            self.DBTYPE = res.data.CODE_DUBAN;
+            self.getMIJI()
+        })
+    }
+    self.getMIJI = function () {
+        var data = {
+            ckey: "CODE_SECRET",
+            routeinfoid: self.routeinfoid
+        }
+        $http.post(apiurljs.login + "g2app/abase/queryDataCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            self.MIJI = res.data.CODE_SECRET;
+            self.getSFDB()
+        })
+    }
+    self.getSFDB = function () {
+        var data = {
+            ckey: "CODE_SFDB",
+            routeinfoid: self.routeinfoid
+        }
+        $http.post(apiurljs.login + "g2app/abase/queryDataCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            self.SFDB = res.data.CODE_SFDB;
+            self.getSFBJ()
+        })
+    }
+    self.getSFBJ = function () {
+        var data = {
+            ckey: "CODE_SF",//"CODE_SFBJ",
+            routeinfoid: self.routeinfoid
+        }
+        $http.post(apiurljs.login + "g2app/abase/queryDataCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            self.SFBJ = res.data.CODE_SF;
+            self.getSWLB()
+        })
+    }
+    self.getSWLB = function () {
+        var data = {
+            ckey: "CODE_SWLB",
+            routeinfoid: self.routeinfoid
+        }
+        $http.post(apiurljs.login + "g2app/abase/queryDataCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            self.SWLB = res.data.CODE_SWLB;
+            self.getDpList()
+        })
+    }
+    self.getDpList = function () {
+        var data = {
+            unitid: "AA"
+        }
+        $http.post(apiurljs.login + "g2app/dataabase/querySectByCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            self.dpList = [];
+            res.data.forEach(function (item) {
+                if (item.CHILD_DATA.length == 0) {
+                    self.dpList.push(item)
+                } else {
+                    item.CHILD_DATA.forEach(function (item1) {
+                        if (item1.CHILD_DATA.length == 0) {
+                            self.dpList.push(item1)
+                        } else {
+                            item1.CHILD_DATA.forEach(function (item2) {
+                                if (item2.CHILD_DATA.length == 0) {
+                                    self.dpList.push(item2)
+                                }
+                            })
+                        }
+                    })
+                }
+            })
+            self.dpList.forEach(function (item) {
+                item.checked = false;
+            })
+            self.DpList = {
+                ZBCS: JSON.parse(JSON.stringify(self.dpList)),
+                CDCS: JSON.parse(JSON.stringify(self.dpList))
+            }
+            self.AllCheckedDp = {};
+            self.DpLength = {};
+            self.selectDpList = {};
+            self.getUSAGE(0)
+        })
+    }
+    //标签
+    self.getUSAGE = function (n) {
+        var data = {
+            ckey: "CODE_SHOUWENLABEL",          
+            routeinfoid: self.routeinfoid
+        }
+        $http.post(apiurljs.login + "g2app/abase/queryDataCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            self.USAGE = res.data.CODE_SHOUWENLABEL;
+            $.each(self.USAGE, function (index, item) {
+                item.checked = false;
+            })
+            if (n == 0) {
+                self.getSWBH()
+            }
+            if (n == 1) {
+                $.each(self.USAGE, function (index, item) {
+                    if (self.data.USAGE.indexOf(item.CODE) != -1) {
+                        item.checked = true;
+                    }
+                })
+                $timeout(function () {
+                    $(".sp-checkbox-blue input[name=USAGE]").each(function () {
+                        if (self.data.USAGE.indexOf($(this).val()) != -1) {
+                            $(this).attr("checked", true);
+                            $(this).parent("label").addClass("chb-blue-checked");
+                        }
+                    })
+                }, 1)
+            }
+        })
+    }
+    //管理标签
+    self.ManageUSAGE = function (n) {
+        self.addUSAGENAME = "";
+        var data = {
+            tablename: "CODE_SHOUWENLABEL"
+        }
+        $http.post(apiurljs.login + "g2app/shouwen/queryLabelCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            self.USAGELIST = res.data;
+            $.each(self.USAGELIST, function (index, item) {
+                item.change = false;
+                item.CNAME1 = item.CNAME;
+                item.USAGE = item.USAGE == 0 ? "隐藏" : "显示";
+            })
+            if (n == 0) {
+                $timeout(function () {
+                    sp.layer("#USAGE");
+                }, 1)
+            }
+        })
+    }
+
+    //新增标签
+    self.addUSAGE = function () {
+        if (self.addUSAGENAME == "") {
+            sp.dialog("标签名称不可为空!");
+            return;
+        }
+        var data = {
+            tablename: "CODE_SHOUWENLABEL",
+            data: {
+                CODE: "C0" + (self.USAGELIST.length + 1),
+                CNAME: self.addUSAGENAME,
+                USERID: self.userId,
+                TABLENAME: "SW_ZJWWJCBD",
+                USAGE: "1"
+            }
+        }
+        $http.post(apiurljs.login + "g2app/shouwen/insertCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            if (res.success) {
+                self.ManageUSAGE(1);
+                self.getUSAGE(1);
+            } else {
+                sp.dialog(res.message);
+            }
+        })
+    }
+
+    //标签排序上下移
+    self.btnSort = function ($index, tip) {
+        var set_id = "";
+        var set_sortid = "";
+        if (tip == "上移") {
+            var set_index = parseInt($index - 1);
+            set_id = self.USAGELIST[set_index].ID;
+            set_sortid = self.USAGELIST[set_index].SORTID;
+        } else {
+            var set_index = parseInt($index + 1);
+            set_id = self.USAGELIST[set_index].ID;
+            set_sortid = self.USAGELIST[set_index].SORTID;
+        }
+        var data = {
+            tablename: "CODE_SHOUWENLABEL",
+            id: self.USAGELIST[$index].ID,
+            sortid: self.USAGELIST[$index].SORTID,
+            id_other: set_id,
+            sortid_other: set_sortid
+        };
+        $http.post(apiurljs.login + "g2app/shouwen/MoveCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            if (res.success) {
+                self.ManageUSAGE(1);
+            } else {
+                sp.dialog(res.message);
+            }
+        });
+    };
+
+    //更新标签
+    self.updataUSAGE = function (item, str) {
+        if (str == "CNAME") {
+            var data = {
+                tablename: "SW_ZJWWJCBD",
+                code: item.CODE,
+            }
+            $http.post(apiurljs.login + "g2app/shouwen/querynumCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+            .success(function (obj) {
+                var res = strToJson(s4.decryptData_CBC(obj.data));
+                if (res.success) {
+                    var data = {
+                        tablename: "CODE_SHOUWENLABEL",
+                        id: item.ID,
+                        data: {
+                            "cname": item.CNAME1
+                        }
+                    }
+                    $http.post(apiurljs.login + "g2app/shouwen/upCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+                    .success(function (obj) {
+                        var res = strToJson(s4.decryptData_CBC(obj.data));
+                        if (res.success) {
+                            item.change = false;
+                            self.ManageUSAGE(1);
+                            self.getUSAGE(1);
+                        } else {
+                            sp.dialog(res.message);
+                        }
+                    });
+                } else {
+                    var dialogHead = "<span class=\"sp-dialog-head\"><span class=\"sp-dialog-tip\">温馨提示</span><span class=\"sp-dialog-close sp-closeDialog\" title=\"关闭\">×</span></span>";
+                    var dialogBody = "<div class=\"sp-dialog-body\">该标签已被使用,您确认要修改吗?</div>";
+                    var dialogFoot = "<div class=\"sp-dialog-foot\"><input id='upDataTrue' type='button' value='确 认' class='sp-dialog-btnTrue' /><input type='button' value='取 消' class='sp-dialog-btnCancle sp-closeDialog' /></div>";
+                    $('.sp-dialog').html(dialogHead + dialogBody + dialogFoot);
+                    sp.openCenter(".sp-dialog");
+                    $('.sp-closeDialog').click(function (event) {
+                        sp.dialoghide();
+                        $timeout(function () {
+                            item.CNAME1 = item.CNAME;
+                        }, 1)
+                        //sp.closeCenter(".sp-dialog");
+                        event.preventDefault(); event.stopPropagation();
+                    });
+                    $("#upDataTrue").click(function () {
+                        var data = {
+                            tablename: "CODE_SHOUWENLABEL",
+                            id: item.ID,
+                            data: {
+                                "cname": item.CNAME1
+                            }
+                        }
+                        $http.post(apiurljs.login + "g2app/shouwen/upCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+                        .success(function (obj) {
+                            var res = strToJson(s4.decryptData_CBC(obj.data));
+                            if (res.success) {
+                                sp.dialoghide();
+                                item.change = false;
+                                self.ManageUSAGE(1);
+                                self.getUSAGE(1);
+                            } else {
+                                sp.dialog(res.message);
+                            }
+                        });
+                    });
+                }
+            })
+        } else if (str == "显示") {
+            var data = {
+                tablename: "CODE_SHOUWENLABEL",
+                id: item.ID,
+                data: {
+                    "USAGE": "1"
+                }
+            }
+            $http.post(apiurljs.login + "g2app/shouwen/upCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+            .success(function (obj) {
+                var res = strToJson(s4.decryptData_CBC(obj.data));
+                if (res.success) {
+                    item.change = false;
+                    self.ManageUSAGE(1);
+                    self.getUSAGE(1);
+                } else {
+                    sp.dialog(res.message);
+                }
+            });
+        } else {
+            var data = {
+                tablename: "CODE_SHOUWENLABEL",
+                id: item.ID,
+                data: {
+                    "USAGE": "0"
+                }
+            }
+            $http.post(apiurljs.login + "g2app/shouwen/upCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+            .success(function (obj) {
+                var res = strToJson(s4.decryptData_CBC(obj.data));
+                if (res.success) {
+                    item.change = false;
+                    self.ManageUSAGE(1);
+                    self.getUSAGE(1);
+                } else {
+                    sp.dialog(res.message);
+                }
+            });
+        }
+    }
+
+    //删除标签
+    self.deleteUSAGE = function (item) {
+        var data = {
+            tablename: "CODE_SHOUWENLABEL",
+            tablename_form: "SW_ZJWWJCBD",
+            id: item.ID,
+            code: item.CODE
+        }
+        $http.post(apiurljs.login + "g2app/shouwen/delCode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            if (res.success) {
+                self.ManageUSAGE(1);
+                self.getUSAGE(1);
+            } else {
+                sp.dialog("此标签已被使用");
+            }
+        });
+    }
+
+    self.getSWBH = function () {
+        var data = {
+            flowid: sp.getUrlName("flowid")
+        }
+        $http.post(apiurljs.login + "g2app/shouwen/querySWCodeByFlowid", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            self.SWBH = res.data;
+            self.getData()
+        })
+    }
+    //获取数据
+    self.getData = function () {
+        let data = {
+            ckey: "SW_ZJWWJCBD",
+            id: 0,
+            directionid: self.directionid,
+            formeditid: self.formeditid,
+            routeid: self.routeid,
+            routeinfoid: self.routeinfoid
+        }
+				g2app_abase_queryData(data).then(res=>{
+					console.log(res.data.SW_ZJWWJCBD)
+					self.data = {
+						
+							CPSX: res.data.SW_ZJWWJCBD.CPSX == "" ? "" : sp.format(res.data.SW_ZJWWJCBD.CPSX),
+					    ID: res.data.SW_ZJWWJCBD.ID,
+					    APPCODE: res.data.SW_ZJWWJCBD.APPCODE,
+					    JJCD: res.data.SW_ZJWWJCBD.JJCD == "" ? self.JJCD[0].CODE : res.data.SW_ZJWWJCBD.JJCD,
+					    MIJI: res.data.SW_ZJWWJCBD.MIJI == "" ? self.MIJI[0].CODE : res.data.SW_ZJWWJCBD.MIJI,
+							SWLB: res.data.SW_ZJWWJCBD.SWLB == "" ? self.SWLB[0].CODE : res.data.SW_ZJWWJCBD.SWLB,
+					    SWBH: res.data.SW_ZJWWJCBD.SWBH == "" ? self.SWBH.replace("|", "〔 ").replace("|", " 〕") + "号" : res.data.SW_ZJWWJCBD.SWBH,              
+					    SWBH1: res.data.SW_ZJWWJCBD.SWBH,
+					    LWDW: res.data.SW_ZJWWJCBD.LWDW,
+					    LWRQ: res.data.SW_ZJWWJCBD.LWRQ == "" || res.data.SW_ZJWWJCBD.LWRQ == null ? sp.format(sp.getLocalDate()) : sp.format(res.data.SW_ZJWWJCBD.LWRQ),
+					    LWWH: res.data.SW_ZJWWJCBD.LWWH == "" ? "〔 " + sp.currentYear() + " 〕号" : res.data.SW_ZJWWJCBD.LWWH,
+					    SFDB: res.data.SW_ZJWWJCBD.SFDB == "" ? "C03" : res.data.SW_ZJWWJCBD.SFDB,
+					    DBLX: res.data.SW_ZJWWJCBD.DBLX == "" ? res.data.SW_ZJWWJCBD.SFDB == "" || res.data.SW_ZJWWJCBD.SFDB == self.SFDB[1].CODE ? "" : self.DBTYPE[0].CODE : res.data.SW_ZJWWJCBD.DBLX,
+					    BT: res.data.SW_ZJWWJCBD.BT,
+					    DBSX: res.data.SW_ZJWWJCBD.DBSX == "" ? "" : sp.format(res.data.SW_ZJWWJCBD.DBSX),
+					    CDCS: res.data.SW_ZJWWJCBD.CDCS,
+					    ZBCS: res.data.SW_ZJWWJCBD.ZBCS,
+					    SFBJ: res.data.SW_ZJWWJCBD.SFBJ == "" ? self.SFBJ[0].CODE : res.data.SW_ZJWWJCBD.SFDB,
+					    BJQK:res.data.SW_ZJWWJCBD.BJQK,
+					    BZ: res.data.SW_ZJWWJCBD.BZ,
+					    NGR: res.data.SW_ZJWWJCBD.NGR == "" ? self.userName : res.data.SW_ZJWWJCBD.NGR,
+					    ZBRQ: res.data.SW_ZJWWJCBD.ZBRQ == "" || res.data.SW_ZJWWJCBD.ZBRQ == null ? sp.format(sp.getLocalDate()) : sp.format(res.data.SW_ZJWWJCBD.ZBRQ),
+					    USAGE: res.data.SW_ZJWWJCBD.USAGE,
+					    ZBCSCODE: res.data.SW_ZJWWJCBD.ZBCSCODE,
+					    FGLDBJQR: res.data.SW_ZJWWJCBD.FGLDBJQR,
+					    SWQXLX: res.data.SW_ZJWWJCBD.SWQXLX == "" ? res.data.SW_ZJWWJCBD.SFDB != "C01" ? "办理" : "督办" : res.data.SW_ZJWWJCBD.SWQXLX
+					}
+					self.readonly = {
+						CPSX: true,
+					    JJCD: res.data.SW_ZJWWJCBD["JJCD.EREADONLY"] == "true",
+					    MIJI: res.data.SW_ZJWWJCBD["MIJI.EREADONLY"] == "true",
+							SWLB: res.data.SW_ZJWWJCBD["SWLB.EREADONLY"] == "true",
+					    SWBH: res.data.SW_ZJWWJCBD["SWBH.EREADONLY"] == "true",
+					    LWDW: res.data.SW_ZJWWJCBD["LWDW.EREADONLY"] == "true",
+					    LWRQ: res.data.SW_ZJWWJCBD["LWRQ.EREADONLY"] == "true",
+					    LWWH: res.data.SW_ZJWWJCBD["LWWH.EREADONLY"] == "true",
+					    SFDB: res.data.SW_ZJWWJCBD["SFDB.EREADONLY"] == "true",
+					    BT: res.data.SW_ZJWWJCBD["BT.EREADONLY"] == "true",
+					    BGSNBYJ: res.data.SW_ZJWWJCBD["BGSNBYJ.EREADONLY"] == "true",
+					    WLDPS: res.data.SW_ZJWWJCBD["WLDPS.EREADONLY"] == "true",
+					    CBCSCLQK: res.data.SW_ZJWWJCBD["CBCSCLQK.EREADONLY"] == "true",
+					    DBLX: res.data.SW_ZJWWJCBD["DBLX.EREADONLY"] == "true",
+					    CDCS: res.data.SW_ZJWWJCBD["CDCS.EREADONLY"] == "true",
+					    DBSX: res.data.SW_ZJWWJCBD["DBSX.EREADONLY"] == "true",
+					    ZBCS: res.data.SW_ZJWWJCBD["ZBCS.EREADONLY"] == "true",
+					    SFBJ: res.data.SW_ZJWWJCBD["SFBJ.EREADONLY"] == "true",
+					    BJQK: res.data.SW_ZJWWJCBD["BJQK.EREADONLY"] == "true",
+					    FGLDBJQR: res.data.SW_ZJWWJCBD["FGLDBJQR.EREADONLY"] == "true",
+					    BZ: res.data.SW_ZJWWJCBD["BZ.EREADONLY"] == "true",
+					    NGR: res.data.SW_ZJWWJCBD["NGR.EREADONLY"] == "true",
+					    ZBRQ: res.data.SW_ZJWWJCBD["ZBRQ.EREADONLY"] == "true",
+					    USAGE: res.data.SW_ZJWWJCBD["USAGE.EREADONLY"] == "true"
+					}
+					self.show = {
+						CPSX:  res.data.SW_ZJWWJCBD["CPSX.ESHOW"] == "true",
+					    JJCD: res.data.SW_ZJWWJCBD["JJCD.ESHOW"] == "true",
+					    MIJI: res.data.SW_ZJWWJCBD["MIJI.ESHOW"] == "true",
+							SWLB: res.data.SW_ZJWWJCBD["SWLB.ESHOW"] == "true",
+					    SWBH: res.data.SW_ZJWWJCBD["SWBH.ESHOW"] == "true",
+					    LWDW: res.data.SW_ZJWWJCBD["LWDW.ESHOW"] == "true",
+					    LWRQ: res.data.SW_ZJWWJCBD["LWRQ.ESHOW"] == "true",
+					    LWWH: res.data.SW_ZJWWJCBD["LWWH.ESHOW"] == "true",
+					    SFDB: res.data.SW_ZJWWJCBD["SFDB.ESHOW"] == "true",
+					    BT: res.data.SW_ZJWWJCBD["BT.ESHOW"] == "true",
+					    BGSNBYJ: res.data.SW_ZJWWJCBD["BGSNBYJ.ESHOW"] == "true",
+					    WLDPS: res.data.SW_ZJWWJCBD["WLDPS.ESHOW"] == "true",
+					    CBCSCLQK: res.data.SW_ZJWWJCBD["CBCSCLQK.ESHOW"] == "true",
+					    DBLX: res.data.SW_ZJWWJCBD["DBLX.ESHOW"] == "true",
+					    CDCS: res.data.SW_ZJWWJCBD["CDCS.ESHOW"] == "true",
+					    DBSX: res.data.SW_ZJWWJCBD["DBSX.ESHOW"] == "true",
+					    ZBCS: res.data.SW_ZJWWJCBD["ZBCS.ESHOW"] == "true",
+					    SFBJ: res.data.SW_ZJWWJCBD["SFBJ.ESHOW"] == "true",
+					    BJQK: res.data.SW_ZJWWJCBD["BJQK.ESHOW"] == "true",
+					    FGLDBJQR: res.data.SW_ZJWWJCBD["FGLDBJQR.ESHOW"] == "true",
+					    BZ: res.data.SW_ZJWWJCBD["BZ.ESHOW"] == "true",
+					    NGR: res.data.SW_ZJWWJCBD["NGR.ESHOW"] == "true",
+					    ZBRQ: res.data.SW_ZJWWJCBD["ZBRQ.ESHOW"] == "true",
+					    USAGE: res.data.SW_ZJWWJCBD["USAGE.ESHOW"] == "true"
+					}
+					self.selectUSAGEs = self.data.USAGE != "" && self.data.USAGE != null ? self.data.USAGE.split(",") : [];
+					$.each(self.USAGE, function (index, item) {
+					    if (self.data.USAGE.indexOf(item.CODE) != -1) {
+					        item.checked = true;
+					    }
+					})
+					$timeout(function () {
+					    $(".sp-checkbox-blue input[name=USAGE]").each(function () {
+					        if (self.data.USAGE.indexOf($(this).val()) != -1) {
+					            $(this).attr("checked", true);
+					            $(this).parent("label").addClass("chb-blue-checked");
+					        }
+					    })
+					}, 0)
+					self.filedChange = true;
+					//if (self.data.ID == 0) {
+					//    self.filedChange = true;
+					//} else {
+					//    self.filedChange = false;
+					//}
+					var buttonList = [{ CNAME: "转发", CODE: "array", data: [] }];
+					res.data["SW_ZJWWJCBD.FUNCLIST"].forEach(function (item) {
+					    if (item.BUTTONGROUP == "FORMITEM") {
+					        buttonList.push(item)
+					    } else {
+					        buttonList[0].data.push(item)
+					    }
+					})
+					if (buttonList[0].data.length == 0) {
+					    buttonList = buttonList.slice(1)
+					} else if (buttonList[0].data.length == 1) {
+					    buttonList[0] = buttonList[0].data[0]
+					}
+					console.log(buttonList)
+					self.buttonList = buttonList;//res.data["SW_ZJWWJCBD.FUNCLIST"];
+					var n = {}, all = {};
+					for (var i in self.DpList) {
+					    self.AllCheckedDp[i] = false;
+					    self.DpLength[i] = 0;
+					    self.selectDpList[i] = []
+					    all[i] = 0;
+					    $.each(self.DpList[i], function (index, item) {
+					        self.DpLength[i]++
+					        if (self.data.ZBCS.indexOf(item.SECTION) != -1 && i == "ZBCS") {
+					            all[i]++;
+					            item.checked = true;
+					            self.selectDpList[i].push(item);
+					        }
+					        if (self.data.CDCS.indexOf(item.SECTION) != -1 && i == "CDCS") {
+					            all[i]++;
+					            item.checked = true;
+					            self.selectDpList[i].push(item);
+					        }
+					    })
+					    if (all[i] == self.DpList[i].length) {
+					        self.AllCheckedDp[i] = true;
+					    } else {
+					        self.AllCheckedDp[i] = false;
+					    }
+					}
+					self.getOpinion1()
+					self.getOther1()
+					self.getOther()
+					self.opinionList = [{
+					    name: "拟办意见",
+					    col: "BGSNBYJ",
+					    show: !self.hide("show", "BGSNBYJ") && !self.hide("readonly", "BGSNBYJ")
+					}, {
+					    name: "领导批示",
+					    col: "WLDPS",
+					    show: !self.hide("show", "WLDPS") && !self.hide("readonly", "WLDPS")
+					}, {
+					    name: "分管领导办结确认",
+					    col: "FGLDBJQR",
+					    show: !self.hide("show", "FGLDBJQR") && !self.hide("readonly", "FGLDBJQR")
+					}, {
+					    name: "承办处室处理情况",
+					    col: "CBCSCLQK",
+					    show: !self.hide("show", "CBCSCLQK") && !self.hide("readonly", "CBCSCLQK")
+					}]
+					self.opinionList1 = [];
+					self.opinionList.forEach(function (item) {
+					    if (item.show == true) {
+					        self.opinionList1.push(item)
+					    }
+					})
+					if (self.opinionList1.length > 0) {
+					    self.opiniontype = self.opinionList1[0].col;
+					}
+				})
+    }
+
+    //转换
+    self.Loaling = false;
+    self.pdfContent = [];
+    self.getContent = function () {
+        if (self.Loaling == true) {
+            return;
+        }
+        self.Loaling = true;
+        $("#pdfContent").nextAll("div").addClass("sp-page-loading")
+        self.pdfContent = [];
+        var data = {
+            fileurl: self.seeFileItem.FILEURL
+        }
+        $http.post(apiurljs.login + "g2app/dataabase/queryPDFContent", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            self.Loaling = false;
+            $("#pdfContent").nextAll("div").removeClass("sp-page-loading")
+            for (var i in res.data) {
+                self.pdfContent.push({ id: parseInt(i.slice(i.indexOf("_") + 1)), content: res.data[i] })
+            }
+            self.pdfContent.sort(function (a, b) {
+                return a.id - b.id;
+            })
+        })
+    }
+    //获取意见(不上表)
+    self.getOpinion1 = function () {
+        var data = {
+            cmanid: self.userId,
+            routeinfoid: self.routeinfoid,
+            routeid: "",//self.routeid,
+            tableid: "SW_ZJWWJCBD",
+            colid: "",
+            opiniontype: "",//self.opiniontype,
+            orderbycol: "CDATE desc"
+        }
+        $http.post(apiurljs.login + "g2app/abase/queryDataOpinionWithRouteAttach", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            if (res.success == true) {
+                self.YJ.nulla = res.data;
+                self.YJ.nullaSTATUS = false;
+                self.YJ.nulla.forEach(function (item) {
+                    item.CDATE = sp.datefmt("yyyy-MM-dd", item.CDATE);
+                    if (self.activeOpinion != null) {
+                        self.activeOpinion.FILEDATA = item.FILEDATA
+                    }
+                })
+            } else {
+                sp.dialog(res.message)
+            }
+        })
+    }
+    //获取正文
+    self.getOther1 = function () {
+        var data = {
+            tablename: "FILE_ATTACH",
+            colums: "*",
+            order: "ID asc",
+            sqlwhere: { ROUTEINFOID: self.routeinfoid },
+            sqlinwhere: "",
+            sqllikewhere: { ATTACHTYPE: "-正文" }
+        }
+        $http.post(apiurljs.login + "g2app/dataabase/queryDataByCol", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            if (res.data.length > 0) {
+                res.data.forEach(function (item) {
+                    if (item.ATTACHTYPE.indexOf("-正文") > -1) {
+                        self.arrayFile = item;
+                        self.seeFile(self.arrayFile)
+                    }
+                })
+            }
+        })
+    }
+    //获取附件
+    self.getOther = function () {
+        if (self.routeinfoid == 0) { return }
+        var data = {
+            tablename: "FILE_ATTACH",
+            colums: "*",
+            order: "ID asc",
+            sqlwhere: { ROUTEINFOID: self.routeinfoid },
+            sqlinwhere: "",
+            sqllikewhere: ""
+        }
+        $http.post(apiurljs.login + "g2app/dataabase/queryDataByCol", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            self.arrayFile1 = [];
+            if (res.data.length > 0) {
+                res.data.forEach(function (item) {
+                    if (item.ATTACHTYPE.indexOf("-正文") == -1) {
+                        self.arrayFile1.push(item)
+                    }
+                })
+                $timeout(function () {
+                    self.goAttach()
+                },1000)
+            }
+        })
+    }
+    //判断页面字段是否只读readonly、是否隐藏show
+    self.hide = function (type, field) {
+        if (self.dotype == 0 && type == "readonly") {
+            return true;
+        } else {
+            if (self[type][field] == true) {
+                return true;
+            } else {
+                return false;
+            }
+        }
+    }
+    //右上角按钮调用方法
+    self.btnEvent = function (item) {
+        if (item.CODE == "NEWFLOWQB") {
+            var data = {
+                flowid: "AA65",
+                userid: self.userId,
+                routeinfoid: self.routeinfoid,
+                directionid: self.directionid,
+                copyrightid: self.copyrightid
+            }
+            $http.post(apiurljs.login + "g2app/fawenfiles/createNewWorkFlowWithGwtype", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+            .success(function (obj) {
+                var res = strToJson(s4.decryptData_CBC(obj.data));
+                console.log(res)
+                window.top.sp.addTabNav(item.FUNCID, item.CNAME, "tpl/qianbaomgr/" + res.data.FILEN + "&dotype=1&flowid=AA65")
+                $timeout(function () {
+                    window.top.sp.restoreWorkLayer("#wrapper_tabs_box_col_" + item.FUNCID)
+                }, 1000)
+            })
+            return
+        } else if (item.CODE == "NEWFLOWDW") {
+            var data = {
+                flowid: "AA95",
+                userid: self.userId,
+                routeinfoid: self.routeinfoid,
+                directionid: self.directionid,
+                copyrightid: self.copyrightid
+            }
+            $http.post(apiurljs.login + "g2app/fawenfiles/createNewWorkFlowWithGwtype", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+            .success(function (obj) {
+                var res = strToJson(s4.decryptData_CBC(obj.data));
+                console.log(res)
+                window.top.sp.addTabNav(item.FUNCID, item.CNAME, "tpl/DWHYTCB/" + res.data.FILEN + "&dotype=1&flowid=AA95")
+                window.top.sp.restoreWorkLayer("#" + item.FUNCID)
+            })
+            return
+        } else if (item.CODE == "NEWFLOWXZ") {
+            var data = {
+                flowid: "AA10",
+                userid: self.userId,
+                routeinfoid: self.routeinfoid,
+                directionid: self.directionid,
+                copyrightid: self.copyrightid
+            }
+            $http.post(apiurljs.login + "g2app/fawenfiles/createNewWorkFlowWithGwtype", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+            .success(function (obj) {
+                var res = strToJson(s4.decryptData_CBC(obj.data));
+                console.log(res)
+                window.top.sp.addTabNav(item.FUNCID, item.CNAME, "tpl/fawenbg/" + res.data.FILEN + "&dotype=1&flowid=AA10")
+                $timeout(function () {
+                    window.top.sp.restoreWorkLayer("#wrapper_tabs_box_col_" + item.FUNCID)
+                }, 1000)
+            })
+            return
+        }
+        switch (item.CODE) {
+            case "SAVEITEM": self.btnSave(0); break;
+            case "PRINTITEM": self.btnPrint(); break;
+            case "PRINTITEMEXTEND": self.btnPrint1(); break;
+            case "MEETITEM": self.Meet(); break;
+            case "SENDLOG": self.RouteList(); break;
+            default: self.forward(item); break;
+        }
+    }
+    self.openDpList = function (str) {
+        if (self.hide("readonly", str) == true) {
+            return
+        } else {
+            self.filed = str;
+            //self.AllCheckedDp = false;
+            sp.layer("#DpList")
+            $("#DpList .sp-page").eq(0).scrollTop(0);
+        }
+    }
+    self.checkAllDp = function () {
+        self.AllCheckedDp[self.filed] = !self.AllCheckedDp[self.filed];
+        $.each(self.DpList[self.filed], function (index, item) {
+            item.checked = self.AllCheckedDp[self.filed];
+        })
+        self.submitDpList(1)
+    }
+    self.checkDpItem = function (item) {
+        item.checked = !item.checked;
+        var n = 0;
+        $.each(self.DpList[self.filed], function (index, item) {
+            if (item.checked == true) {
+                n++
+            }
+        })
+        if (n == self.DpList[self.filed].length) {
+            self.AllCheckedDp[self.filed] = true;
+        } else {
+            self.AllCheckedDp[self.filed] = false;
+        }
+        self.submitDpList(1)
+    }
+
+    self.submitDpList = function (n) {
+        var AllCheckedLength1 = 0;
+        self.selectDpList[self.filed] = [];
+        $.each(self.DpList[self.filed], function (index, item) {
+            if (item.checked == true) {
+                AllCheckedLength1++;
+                self.selectDpList[self.filed].push(item)
+            }
+        })
+        self.data[self.filed] = self.selectDpList[self.filed].map(function (item) {
+            return item.SECTION
+        }).join(",")
+        if (self.filed == "ZBCS") {
+            self.data.ZBCSCODE = self.selectDpList[self.filed].map(function (item) {
+                return item.CODE
+            }).join(",")
+            self.data.CDCS = self.data.CDCS == "" ? self.data.ZBCS : self.data.CDCS;
+        }
+        self.AllCheckedDp[self.filed] = AllCheckedLength1 == self.DpLength[self.filed];
+        self.changeFiled(self.filed)
+        if (n == 0) {
+            sp.layerhide();
+        }
+    }
+    self.openLWDW = function () {
+        var data = {
+            tablename: "CODE_LWDWLABEL"
+        }
+        //$http.post(apiurljs.login + "g2app/shouwen/getTreeListByTablename", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        $http.post(apiurljs.login + "g2app/shouwen/getTreeListByTablename", data, postCfg)
+            .success(function (obj) {
+                //var res = strToJson(s4.decryptData_CBC(obj.data));
+                var res = obj;
+                self.getMenuBtnList(res.data);
+                self.LWDW = res.data[0].C_H_I_L_D_DATA;
+                self.LWDW.forEach(function (item) {
+                    item.show = true;
+                    item.C_H_I_L_D_DATA.forEach(function (item1) {
+			item1.checked = false;
+                        if (item1.CNAME == self.data.LWDW) {
+                            item1.checked = true;
+                        }
+                    })
+                })
+                sp.layer("#openLWDW")
+            })
+            .error(function (XMLHttpRequest, textStatus, errorThrown) {
+                self.treeData = [];
+            })
+    }
+    self.checkItem = function (obj) {
+        self.LWDW.forEach(function (item) {
+            item.C_H_I_L_D_DATA.forEach(function (item1) {
+                item1.checked = false;
+                if (item1.ID == obj.ID) {
+                    item1.checked=true
+                }
+            })
+        })
+    }
+    self.submitLWDW = function () {
+        self.LWDW.forEach(function (item) {
+            item.C_H_I_L_D_DATA.forEach(function (item1) {
+                if (item1.checked == true) {
+                    self.data.LWDW = item1.CNAME;
+                }
+            })
+        })
+        console.log(self.data.LWDW)
+        self.changeFiled('LWDW')
+        sp.layerhide();
+    }
+    self.setLWDW = function (n) {
+        var data = {
+            tablename: "CODE_LWDWLABEL"
+        }
+        //$http.post(apiurljs.login + "g2app/shouwen/getTreeListByTablename", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        $http.post(apiurljs.login + "g2app/shouwen/getTreeListByTablename", data, postCfg)
+            .success(function (obj) {
+                //var res = strToJson(s4.decryptData_CBC(obj.data));
+                var res = obj;
+                self.getMenuBtnList(res.data);
+                self.treeData = res.data;
+                $timeout(function () {
+                    self.nowNodeCode = self.treeData[0].CODE;
+                    self.nowNodeName = self.treeData[0].CNAME;
+                    self.nowNodeID = self.treeData[0].ID;
+                    self.treeData[0].checked = true;
+                    if (n == 0) {
+                        sp.layer("#setLWDW")
+                    }
+                })
+            })
+            .error(function (XMLHttpRequest, textStatus, errorThrown) {
+                self.treeData = [];
+            })
+    }
+    self.getMenuBtnList = function (data) {
+        data.forEach(function (item) {
+            item.checked = false;
+            item.C_H_I_L_D_DATA_L = data.length;
+            if (sp.isval(item.C_H_I_L_D_DATA) && item.C_H_I_L_D_DATA.length > 0) {
+                self.getMenuBtnList(item.C_H_I_L_D_DATA);
+            } else {
+                item.C_H_I_L_D_DATA = [];
+            }
+        })
+    }
+
+    self.itemNode = {
+        level: "",
+        id: "",
+        name: "",
+        code: "",
+        child_title: ""
+    }
+    self.rightFlag = 0;
+
+    //添加目录树形非一级
+    self.itemAdd = function ($item) {
+        self.itemNode.level = $item.LEVELS;
+        self.itemNode.id = 0;
+        self.itemNode.name = $item.CNAME;
+        self.itemNode.code = $item.CODE;
+        self.itemNode.child_title = "";
+        self.rightFlag = 1;
+        console.log(self.itemNode)
+    };
+
+    //修改目录
+    self.itemEdit = function ($item) {
+        self.itemNode.level = $item.LEVELS;
+        self.itemNode.id = $item.ID;
+        self.itemNode.name = $item.CNAME;
+        self.itemNode.code = $item.CODE;
+        self.itemNode.child_title = $item.CNAME;
+        self.rightFlag = 1;
+        console.log(self.itemNode)
+    };
+    //删除底稿
+    self.itemDelete = function ($item) {
+        var data = {
+            "id": $item.ID,
+            "tablename": "CODE_LWDWLABEL",
+            "parentid": $item.PARENTID,
+            "formtablename": ""
+        }
+        $http.post(apiurljs.login + "g2app/dataabase/delNode", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            if (res.success) {
+                self.setLWDW(1);
+                self.btnCancal();
+            } else {
+                sp.dialog(res.message);
+            }
+        })
+    }
+    self.btnSetTitle = function () {
+        if (self.itemNode.id != 0) {
+            if (spngvld.submit("#LWDW")) {
+                let postData = {
+                    id: self.itemNode.id,
+                    tablename: "CODE_LWDWLABEL",
+                    data: {
+                        CNAME: self.itemNode.level == 2 ? self.itemNode.name : self.itemNode.child_title
+                    }
+                }
+                $http.post(apiurljs.login + "g2app/dataabase/upFormData", { data: s4.encryptData_CBC(JSON.stringify(postData)) }, postCfg)
+                    .success(function (obj) {
+                        var res = strToJson(s4.decryptData_CBC(obj.data));
+                        if (res.success) {
+                            self.setLWDW(1);
+                            self.btnCancal();
+                        } else {
+                            sp.dialog(res.message);
+                        }
+                    })
+                    .error(function (XMLHttpRequest, textStatus, errorThrown) {
+                    })
+            }
+        } else {
+            if (spngvld.submit("#LWDW")) {
+                let postData = {
+                    tablename: "CODE_LWDWLABEL",
+                    code: self.itemNode.code,
+                    levels: self.itemNode.level,
+                    cname: self.itemNode.level == 1 ? self.itemNode.name : self.itemNode.child_title,
+                    userid: self.userId
+                }
+                $http.post(apiurljs.login + "g2app/shouwen/TreeAdd", { data: s4.encryptData_CBC(JSON.stringify(postData)) }, postCfg)
+                    .success(function (obj) {
+                        var res = strToJson(s4.decryptData_CBC(obj.data));
+                        if (res.success) {
+                            self.setLWDW(1);
+                            self.btnCancal();
+                        } else {
+                            sp.dialog(res.message);
+                        }
+                    })
+                    .error(function (XMLHttpRequest, textStatus, errorThrown) {
+                    })
+            }
+        }
+    }
+    self.btnCancal = function () {
+        self.itemNode = {
+            level: "",
+            id: "",
+            name: "",
+            code: "",
+            child_title: ""
+        }
+        self.rightFlag = 0;
+    }
+
+    //保存提交
+    self.btnSave = function (n) {
+        if (self.repeat == true) {
+            return
+        }
+        if (spngvld.submit(".formedit")) {
+            if (self.data.SFDB == "C01" && self.data.DBSX == "") {
+                sp.dialog("请填写督办时限!");
+                return
+            }
+            if (self.data.DBSX == "") {
+                sp.dialog("督办时限不能为空!已为您设为来文日期后15天!")
+                self.data.DBSX = sp.getNextDate(self.data.LWRQ, 15);
+                self.data.CPSX = sp.getNextDate(self.data.LWRQ, 13);
+                return
+            }
+            if (self.data.SWBH1 == "") {
+                var postData = {
+                    swcode: self.SWBH,
+                    cuserid: self.userId,
+                    flowid: sp.getUrlName("flowid")
+                }
+                $http.post(apiurljs.login + "g2app/shouwen/saveSWCodeBySWCode", { data: s4.encryptData_CBC(JSON.stringify(postData)) }, postCfg)
+                .success(function (obj1) {
+                    var res1 = strToJson(s4.decryptData_CBC(obj1.data));
+                    if (res1.success) {
+                        if (res1.data == "-1") {
+                            sp.dialog("保存失败!");
+                            return;
+                        }
+                        var dataArray = [];
+                        self.data.USAGE = self.selectUSAGEs.join(",")
+                        dataArray.push(self.data);
+                        var data = {
+                            ckey: "SW_ZJWWJCBD",
+                            id: self.data.ID,
+                            routeid: self.routeid,
+                            routeinfoid: self.routeinfoid,
+                            routeinfotitle: self.data.BT.replace(/\n/g, '').replace(/\s/g, ''),//self.data.BT,
+                            directionid: self.directionid,
+                            formeditid: self.formeditid,
+                            data: JSON.stringify(dataArray)
+                        }
+                        $http.post(apiurljs.login + "g2app/abase/saveData", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+                        .success(function (obj) {
+                            var res = strToJson(s4.decryptData_CBC(obj.data));
+                            if (res.code == 0) {
+                                self.data.ID = res.data.ID;
+                                self.routeid = res.data.ROUTEID;
+                                self.routeinfoid = res.data.ROUTEINFOID;
+                                self.filedChange = false;
+                                if (n == 0) {
+                                    if (res1.data != self.SWBH.split("|")[2]) {
+                                        sp.dialog("收文编号已改变!")
+                                    } else {
+                                        sp.dialog("保存成功!");
+                                    }
+                                    $timeout(function () {
+                                        sp.dialoghide()
+                                    }, 1500)
+                                    self.getSwenList(1)
+                                } else if (n == 1) {
+                                    self.forward(self.btnItem);
+                                } else if (n == 2) {
+                                    self.sendAll();
+                                } else if (n == 3) {
+                                    self.btnPrint();
+                                }
+                            } else {
+                                sp.dialog(res.message)
+                            }
+                        })
+                    } else {
+                        sp.dialog(res1.message)
+                    }
+                })
+            } else {
+                var dataArray = [];
+                self.data.USAGE = self.selectUSAGEs.join(",")
+                dataArray.push(self.data);
+                var data = {
+                    ckey: "SW_ZJWWJCBD",
+                    id: self.data.ID,
+                    routeid: self.routeid,
+                    routeinfoid: self.routeinfoid,
+                    routeinfotitle: self.data.BT.replace(/\n/g, '').replace(/\s/g, ''),//self.data.BT,
+                    directionid: self.directionid,
+                    formeditid: self.formeditid,
+                    data: JSON.stringify(dataArray)
+                }
+                $http.post(apiurljs.login + "g2app/abase/saveData", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+                .success(function (obj) {
+                    var res = strToJson(s4.decryptData_CBC(obj.data));
+                    if (res.code == 0) {
+                        self.data.ID = res.data.ID;
+                        self.routeid = res.data.ROUTEID;
+                        self.routeinfoid = res.data.ROUTEINFOID;
+                        self.filedChange = false;
+                        if (n == 0) {
+                            sp.dialog("保存成功!");
+                            $timeout(function () {
+                                sp.dialoghide()
+                            }, 1500)
+                            self.getSwenList(1)
+                        } else if (n == 1) {
+                            self.forward(self.btnItem);
+                        } else if (n == 2) {
+                            self.sendAll();
+                        } else if (n == 3) {
+                            self.btnPrint();
+                        }
+                    } else {
+                        sp.dialog(res.message)
+                    }
+                })
+            }
+        }
+    }
+    //打印
+    self.btnPrint = function () {
+        if (self.filedChange == true) {
+            self.btnSave(3)
+        } else {
+            // 创建隐藏的可下载链接
+            var eleLink = document.createElement('a');
+            eleLink.download = "";
+            eleLink.style.display = 'none';
+            eleLink.href = apiurljs.login + "g2app/shouwen/PrintWord?data=" + encodeURIComponent(s4.encryptData_CBC("templatefilename=moban33.ftl&tablename=SW_ZJWWJCBD&outfilepath=/tmp/行政公文.wps&printdate=LWRQ,DBSX,ZBRQ&routeinfoid=" + self.routeinfoid));
+            // 触发点击
+            document.body.appendChild(eleLink);
+            eleLink.click();
+            // 然后移除
+            document.body.removeChild(eleLink);
+        }
+    }
+    /*综合打印*/
+    self.printFiled = 1;
+    self.btnPrint1 = function () {
+        if (self.filedChange == true) {
+            self.btnSave(3)
+        } else {
+            sp.layer("#print")
+        }
+    }
+    self.printSubmit = function () {
+        if (self.printFiled == 1) {
+            var templatefilename = "moban33"
+        } else if (self.printFiled == 2) {
+            var templatefilename = "mobanoption"
+        } else {
+            var templatefilename = "moban33_all"
+        }
+        var data = {
+            templatefilename: templatefilename + ".ftl",
+            outfilepath: "/tmp/行政公文" + sp.datefmt('yyyyMMddHHmmss', sp.getLocalDate()) + ".wps",
+            routeinfoid: self.routeinfoid,
+            tablename: "SW_ZJWWJCBD",
+            printtype: self.printFiled,
+            printdate: "LWRQ,DBSX,ZBRQ"
+        }
+        $http.post(apiurljs.login + "g2app/dataabase/PrintWordExtend", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            if (self.deviceType == "pad") {
+                window.location.href = "../../../printPreview.html?url=" + apiurljs.yzFcscloud + "g2work" + res.data[0].url
+            } else {
+                sp.openNewWindow("../../../printPreview.html?url=" + apiurljs.yzFcscloud + "g2work" + res.data[0].url, '打印预览')
+            }
+        })
+        sp.layerhide()
+    }
+
+    //签写意见编辑状态
+    self.opinion = {
+        BGSNBYJ: false,
+        BGSNBYJImg: false,
+        WLDPS: false,
+        WLDPSImg: false,
+        FGLDBJQR: false,
+        FGLDBJQRImg: false,
+        CBCSCLQK: false,
+        CBCSCLQKImg: false,
+        nulla: false
+    }
+    self.YJ = {
+        BGSNBYJ: [],
+        BGSNBYJSTATUS: false,
+        WLDPS: [],
+        WLDPSSTATUS: false,
+        FGLDBJQR: [],
+        FGLDBJQRSTATUS: false,
+        CBCSCLQK: [],
+        CBCSCLQKSTATUS: false,
+        nulla: [],
+        nullaSTATUS: false
+    }
+    //意见(下表) 
+    self.openOptionList = function () {
+        if (self.routeinfoid == 0 && self.routeid == 0) {
+            sp.dialog("请先保存!")
+            return;
+        }
+        if (self.dotype == 0) {
+            return
+        }
+        if (self.opinion.nulla == true) {
+            return;
+        }
+        self.nulla = "";
+        self.opinion.nulla = true;
+    }
+    self.openOptionList1 = function () {
+        self.openOptionList()
+        self.activeOpinion = null;
+        self.showBottom = "opinion";
+        self.YJ.nulla.forEach(function (item) {
+            if (item.ROUTEID == self.routeid) {
+                self.activeOpinion = item;
+                self.nulla = item.OPINION;
+            }
+        })
+        $(".toggle").trigger("click")
+    }
+    self.closeOptionList = function () {
+        self.opinion.nulla = false;
+        self.activeOpinion = null;
+        $(".toggle").trigger("click")
+    }
+    self.submitOptionList = function () {
+        var data = {
+            cmanid: self.userId,
+            routeinfoid: self.routeinfoid,
+            routeid: self.routeid,
+            tableid: "SW_ZJWWJCBD",
+            colid: self.opiniontype,
+            opiniontype: self.opiniontype == "nulla" ? 99 : 0,
+            cresult: "",
+            opinion: self.nulla,
+            opinionimage: ""
+        }
+        if (self.opiniontype == "BGSNBYJ") {
+            data.cmans = "王勇";
+        }
+        $http.post(apiurljs.login + "g2app/abase/saveDataOpinion", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            if (res.success == true) {
+                self.getOpinion1();
+                self.opinion.nulla = false;
+                $(".toggle").trigger("click")
+            } else {
+                sp.dialog(res.message)
+            }
+        })
+    }
+    self.changeOptionList = function (item) {
+        self.showBottom = "opinion";
+        self.opinion.nulla = true;
+        self.nulla = item.OPINION;
+        self.activeOpinion = item;
+        $(".toggle").trigger("click")
+    }
+    //意见附件(下表)
+    self.uploading1 = false;
+    self.upload1 = function () {
+        $('#fileupload1').fileupload({
+            url: apiurljs.login + 'g2app/abase/UploadWholeFileWithRouteAttach',
+            dataType: 'json',
+            beforeSend: function (xhr, data) {
+                xhr.setRequestHeader("Authorization", "Bearer " + self.get_AccessToken);
+                xhr.setRequestHeader("File-Argument", s4.encryptData_CBC("tablename=SYS_ROUTE_ATTACHLIST,userid=" + self.userId + ",routeinfoid=" + self.routeinfoid
+                     + ",routeid=" + self.routeid + ",tableid=SW_ZJWWJCBD,colid=" + self.opiniontype));
+            },
+            // 上传完成后的执行逻辑
+            done: function (e, data) {
+                self.uploading1 = false;
+                self.getOpinion1()
+            }
+        })
+    }
+    //意见附件(上表)
+    self.uploading2 = false;
+    self.upload2 = function (str) {
+        $('#fileupload2').fileupload({
+            url: apiurljs.login + 'g2app/abase/UploadWholeFileWithRouteAttach',
+            dataType: 'json',
+            beforeSend: function (xhr, data) {
+                xhr.setRequestHeader("Authorization", "Bearer " + self.get_AccessToken);
+                xhr.setRequestHeader("File-Argument", s4.encryptData_CBC("tablename=SYS_ROUTE_ATTACHLIST,userid=" + self.userId + ",routeinfoid=" + self.routeinfoid
+                     + ",routeid=" + self.routeid + ",tableid=SW_ZJWWJCBD,colid=" + str));
+            },
+            // 上传完成后的执行逻辑
+            done: function (e, data) {
+                self.uploading1 = false;
+                self.getOpinion1()
+            }
+        })
+    }
+    //下载意见表附件
+    self.downLoadOption = function (item) {
+        window.open(apiurljs.login + "g2work/files/" + item.FILEPATH.slice(7))
+    }
+    //删除意见表附件
+    self.deleteOptionFile = function (file) {
+        var data = {
+            routeid: file.ROUTEID,
+            tableid: "SW_ZJWWJCBD",
+            colid: file.COLID,
+            fileid: file.FILEID
+        };
+        $http.post(apiurljs.login + "g2app/abase/deleteDataOpinionWithRouteAttach", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+            .success(function (obj) {
+                var res = strToJson(s4.decryptData_CBC(obj.data));
+                sp.dialoghide();
+                if (res.success) {
+                    self.getOpinion1();
+                } else {
+                    sp.dialog("删除失败,请联系管理员!");
+                }
+            });
+    }
+    //删除意见
+    self.Dopinion = function (item) {
+        var data = {
+            cmanid: self.userId,
+            routeid: self.routeid,
+            tableid: "SW_ZJWWJCBD",
+            colid: item.COLID,
+        }
+        $http.post(apiurljs.login + "g2app/abase/deleteDataOpinion", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            if (res.success == true) {
+                self.getOpinion1();
+                self.nulla = "";
+                self.activeOpinion = null;
+                self.changeFiled(item.COLID)
+            } else {
+                sp.dialog(res.message)
+            }
+        })
+    }
+
+    self.phraseText = "";//添加常用语
+    self.phraseList = []//常用语列表
+
+    //获取常用语库
+    self.phrase = function (colid) {
+        sp.layer("#phrase");
+        self.colid = colid;
+        self.getPhrase();
+    }
+    //添加常用语到常用语库
+    self.Aphrase = function () {
+        if (self.phraseText == "") {
+            return;
+        }
+        var data = {
+            cmanid: self.userId,
+            tableid: "SW_ZJWWJCBD",
+            colid: self.colid,
+            contents: self.phraseText
+        }
+        $http.post(apiurljs.login + "g2app/abase/insertDataPatterns", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            if (res.success == true) {
+                self.phraseText = "";
+                self.getPhrase();
+            } else {
+                sp.dialog(res.message)
+            }
+        })
+    }
+    //获取常用语库
+    self.getPhrase = function () {
+        var data = {
+            cmanid: self.userId,
+            tableid: "SW_ZJWWJCBD",
+            colid: self.colid
+        }
+        $http.post(apiurljs.login + "g2app/abase/queryDataPatterns", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            self.phraseList = res.data;
+            self.phraseSelect = self.phraseList[0].CONTENTS;
+        })
+    }
+    //从常用语库删除
+    self.Dphrase = function () {
+        var id = null;
+        $.each(self.phraseList, function (index, item) {
+            if (item.CONTENTS == self.phraseSelect) {
+                id = item.ID;
+            }
+        })
+        var data = {
+            id: id
+        }
+        $http.post(apiurljs.login + "g2app/abase/deleteDataPatterns", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            self.getPhrase();
+        })
+    }
+    //常用语确认为意见
+    self.btnPhrase = function () {
+        self.nulla = self.phraseSelect;
+        sp.layerhide();
+    }
+    self.selectUSAGE = function (item) {
+        item.checked = !item.checked;
+        self.selectUSAGEs = [];
+        $.each(self.USAGE, function (index, item) {
+            if (item.checked == true) {
+                self.selectUSAGEs.push(item.CODE)
+            }
+        })
+        self.changeFiled('USAGE')
+    }
+    //发生修改
+    self.changeFiled = function (str) {
+        self.filedChange = true;
+        if (self.data.SFDB != "C01") {
+            self.data.DBLX = "";
+            self.data.SWQXLX = "办理";
+        } else {
+            self.data.SWQXLX = "督办";
+            //self.data.DBLX = self.DBTYPE[0].CODE;
+        }
+				
+				if(str == "DBSX"){
+					let objDate = new Date()
+					let DBSXDate = new Date(self.data.DBSX)
+					let dif_t = DBSXDate.getTime() - objDate.getTime();
+					let Day_dif_t = dif_t/(1000*60*60*24)
+					if(Day_dif_t>10){
+						self.data.CPSX = sp.getNextDate(self.data.DBSX, -2);
+					}else{
+						self.data.CPSX = sp.getNextDate(self.data.DBSX, -1);
+					}
+					
+				}
+    }
+    //验证是否重复
+    self.repeat = false;
+    self.verify = function (str) {
+        if (self.data[str] == "") { return; }
+        var data = {
+            tablename: "SW_ZJWWJCBD",
+            colums: "*",
+            order: "ID desc",
+            sqlwhere: {},
+            sqlinwhere: "",
+            sqllikewhere: ""
+        }
+        data.sqlwhere[str] = self.data[str]
+        $http.post(apiurljs.login + "g2app/dataabase/queryDataByCol", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        .success(function (obj) {
+            var res = strToJson(s4.decryptData_CBC(obj.data));
+            if (res.data.length > 0 && self.data.ID != res.data[0].ID) {
+                self.repeat = true;
+                sp.dialog("标题已存在,请修改后重试!")
+            } else {
+                self.repeat = false;
+            }
+        })
+    }
+
+    //转发
+    self.forward = function (obj) {
+        self.btnItem = obj;
+        if (self.filedChange == true) {
+            self.btnSave(1)
+        } else {
+            $("#forwardWin").attr("src", "../../forward/forward.html?routeid=" + self.routeid + "&routeinfoid=" + self.routeinfoid + "&copyrightid=" + self.copyrightid + "&directionid=" + self.directionid + "&formeditid=" + self.formeditid + "&codefuncbutton=" + obj.CODE + "&directionidtarget=" + obj.DIRECTIONIDTARGET + "&cookie=shouwenbg")
+            sp.layer("#forward")
+        }
+    }
+
+    //查看流转记录
+    self.RouteList = function () {
+        if (self.deviceType == "pad") {
+            window.location.href = "../../forward/modeler_read.html?" + self.SwenList[0].TEMPFORM.split("?")[1]
+        } else {
+            sp.openNewWindow("../../forward/modeler_read.html?" + self.SwenList[0].TEMPFORM.split("?")[1], "流程图")
+        }
+        //var data = {
+        //    directionid: self.directionid,
+        //    userid: self.userId,
+        //    routeid: self.routeid,
+        //    routeinfoid: self.routeinfoid,
+        //}
+        //$http.post(apiurljs.login + "g2app/abase/queryDataRouteList", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+        //.success(function (obj) {
+        //    var res = strToJson(s4.decryptData_CBC(obj.data));
+        //    self.routeList = res.data;
+        //    $.each(self.routeList, function (index, item) {
+        //        item.mainUser = [];
+        //        item.copyUsers = [];
+        //        $.each(item.USERS, function (index1, item1) {
+        //            if (item1.KIND == 0) {
+        //                item.mainUser.push(item1.USERNAME);
+        //            } else {
+        //                item.copyUsers.push(item1.USERNAME);
+        //            }
+        //        })
+        //        item.mainUser = item.mainUser.join(",");
+        //        item.copyUsers = item.copyUsers.join(",");
+        //    })
+        //    setTimeout(function (item) {
+        //        sp.layer("#RouteList");
+        //    }, 100);
+        //})
+    }
+    self.reSize = function (n) {
+        var leftbox = document.getElementsByClassName("page-item")[n - 1];
+        var rightbox = document.getElementsByClassName("page-item")[n];
+        var line = document.getElementsByClassName("iframe-border-right")[n - 1];
+        document.getElementsByClassName("iframe-border-right")[n - 1].addEventListener("mousedown", function (event) {
+            $(".mousemove").show()
+            var leftboxW = leftbox.clientWidth;//leftbox.style.width.slice(0, leftbox.style.width.length - 2);
+            var rightboxW = rightbox.clientWidth;//rightbox.style.width.slice(0, rightbox.style.width.length - 2);
+            var x = event.pageX - line.offsetLeft;
+            document.addEventListener("mousemove", boxMove)
+            function boxMove(event) {
+                if (leftboxW * 1 + (event.pageX - x) * 1 <= 200) {
+                    //$(".leftBox").children().not(".iframe-border-right").hide()
+                } else if (rightboxW * 1 - (event.pageX - x) * 1 <= 200) {
+                    //$(".rightBox").children().not(".iframe-border-right").hide()
+                } else {
+                    leftbox.style.width = leftboxW * 1 + (event.pageX - x) * 1 + "px";
+                    leftbox.getElementsByTagName("iframe")[0].style.width = leftboxW * 1 + (event.pageX - x) * 1 - 10 + "px";
+                    //$(".leftBox").children().not(".iframe-border-right").show()
+
+                    rightbox.style.width = rightboxW * 1 - (event.pageX - x) * 1 + "px";
+                    //rightbox.getElementsByTagName("iframe")[0].style.width = rightboxW * 1 - (event.pageX - x) * 1 - 10 + "px";
+                    //$(".rightBox").children().not(".iframe-border-right").show()
+                }
+            }
+            document.addEventListener("mouseup", function () {
+                $(".mousemove").hide()
+                document.removeEventListener("mousemove", boxMove)
+            })
+        })
+    }
+
+   self.reSizeRow = function () {
+        var bodybox = document.getElementById("bodyDiv");
+        var topbox = document.getElementById("topDiv");
+        var bottombox = document.getElementById("bottomDiv");
+        var line = document.getElementById("lineDiv");
+        document.getElementById("lineDiv").addEventListener("mousedown", function (event) {
+            $(".mousemove").show()
+            var bodyboxH = bodybox.clientHeight;
+            var topboxH = topbox.clientHeight;
+            var bottomboxH = bottombox.clientHeight;
+            //var y = event.pageY - line.offsetTop;
+            var y = event.pageY - line.clientHeight;
+            document.addEventListener("mousemove", boxMove)
+            function boxMove(event) {
+                if (topboxH * 1 + (event.pageY - y) * 1 - 36 <= 45) {
+                    //
+                } else if (bottomboxH * 1 - (event.pageY - y) * 1 - 36 <= 45) {
+                    //
+                } else {
+                    topbox.style.height = topboxH * 1 + (event.pageY - y) * 1 - 36 + "px";
+                    topbox.getElementsByTagName("iframe")[0].style.height = topboxH * 1 + (event.pageY - y) * 1 - 45 + "px";
+
+                    bottombox.style.height = bodyboxH * 1 - topboxH * 1 - (event.pageY - y) * 1 + 36 - 45 + "px";
+                    bottombox.getElementsByTagName("iframe")[0].style.height = bodyboxH * 1 - topboxH * 1 - (event.pageY - y) * 1 + 36 - 75 + "px";
+                }
+            }
+            document.addEventListener("mouseup", function () {
+                $(".mousemove").hide()
+                document.removeEventListener("mousemove", boxMove)
+            })
+        })
+    }
+		
+    ////头部关键字搜索---20230905
+    self.headBtnSearchKeyword = "";
+    self.headSearchResult = [];
+    self.headSearchResult_view = false;
+    self.headBtnSearch = function () {
+        if (sp.isval(self.headBtnSearchKeyword)) {
+            self.headSearchResult = [];
+            var data = {
+                "url": "/basic/api/StatSelect/selectCodeList",
+                "data": { "keyWord": self.headBtnSearchKeyword }
+            }
+            //console.log(JSON.stringify(data));
+            $http.post(apiurljs.login + "g2app/yizhangtu/selectCodeList", { data: s4.encryptData_CBC(JSON.stringify(data)) }, postCfg)
+            .success(function (obj) {
+                var res = strToJson(s4.decryptData_CBC(obj.data));
+                //console.log(JSON.stringify(res.data));
+                self.headSearchResult = res.data.build;
+                if (sp.isval(self.headSearchResult)) {
+                    self.headSearchResult_view = true;
+                } else {
+                    self.headSearchResult_view = false;
+                }
+            })
+        } else {
+            self.headSearchResult_view = false;
+        }
+    };
+    self.headKeywordPage = function (itemdata) {
+        var get_token = localStorage.getItem("main-token");
+        var set_url = apiurljs.onePic + "wholeProcessPage/?token=" + get_token + "&name=" + itemdata.name + "&type=" + itemdata.type + "&id=" + itemdata.id;
+        sp.openNewWindow(set_url, '一张图');
+        self.headSearchResult_view = false;
+    };
+    self.onePic = function () {
+        sp.openNewWindow(apiurljs.onePic + "wholeProcessPage/?token=" + localStorage.getItem("main-token"), "地图搜索")
+    }
+
+    $scope.closeToggle = function () {
+        $timeout(function () {
+            self.opinion.nulla = false;
+            self.activeOpinion = null;
+        })
+    }
+    //头部下滚冻结
+    $(function () {
+        //页面高度撑满
+        setTimeout(function () {
+            $(".formedit").css("height", $(window).height() - 70)
+            //$("#iframe_book").css("height", $(window).height() - 135)
+            $(".iframe-border-right").css("height", $(window).height() - 34)
+            $(".mousemove").css("top", 0).css("left", 0).css("width", $(window).width()).css("height", $(window).height() - 10)
+        }, 1)
+    })
+}])
+app.directive('treeView', [function () {
+    return {
+        restrict: 'EA',
+        templateUrl: '/treeView.html',
+        scope: {
+            treeData: '=',///声明数据
+            textField: '@',
+            itemAdd: '&', ///声明新增变量
+            itemEdit: '&',///声明修改变量
+            itemCheck: '&',///声明修改变量
+            itemDelete: '&',///声明修改变量
+            itemUp: '&',
+            itemDown: '&'
+        },
+        controller: ['$scope', function ($scope) {
+            $scope.itemExpended = function (item, $event) {
+                item.$$isExpend = !item.$$isExpend;
+                $event.stopPropagation();
+            };
+            ///展开折叠图标设置
+            $scope.getItemIcon = function (item) {
+                var isEnd = $scope.isEnd(item);
+                if (isEnd) {
+                    return 'fa fa-paper-plane-o';
+                }
+                return item.$$isExpend ? 'fa fa-plus-square-o' : 'fa fa-minus-square-o';
+            };
+            ///判断是否是最后一级菜单
+            $scope.isEnd = function (item) {
+                return !item.C_H_I_L_D_DATA || !item.C_H_I_L_D_DATA.length;
+            };
+            ///事件调用返回
+            $scope.warpCallback = function (callback, item, $index, $event) {
+                ($scope[callback] || angular.noop)({
+                    $item: item,
+                    $index: $index,
+                    $event: $event
+                });
+            };
+        }]
+    };
+}]);
+app.directive("repeatFinish", function () {
+    return {
+        link: function (scope) {
+            if (scope.$last == true) {
+                $(".toggle").trigger("click")
+            }
+        }
+    };
+});
+app.directive("spCheckboxBlueItem", function () {
+    return {
+        restrict: "A",
+        link: function (scope, elem, attrs) {
+            if (!scope == false) {
+                spng.funcheckbox(elem, "chb-blue", "chb-blue-checked");    //蓝色checkbox 
+            }
+        }
+    }
+});
+app.filter('trustHtml', function ($sce) {
+    return function (input) {
+        return $sce.trustAsHtml(input.replace(/\n/g, '<br/>').replace(/\s/g, '&nbsp;'));
+    };
+});
+function showRight(e) {
+    if ($(e).children(".fa-angle-left").is(":hidden")) {
+        $(".leftBox").css("width", "99.5%");
+        $("#iframe_book").css("width", "100%")
+        $(".rightBox").css("width", "0%");
+        $(".rightBox").hide()
+        $(e).children(".fa-angle-left").show()
+        $(e).children(".fa-angle-right").hide()
+    } else {
+        $(".leftBox").css("width", "69.5%");
+        $("#iframe_book").css("width", "100%")
+        $(".rightBox").css("width", "30%");
+        $(".rightBox").show()
+        $(e).children(".fa-angle-left").hide()
+        $(e).children(".fa-angle-right").show()
+    }
+}
+function showToggle(e) {
+	document.getElementById("selectDiv").style.top = e.style.top;
+	//document.getElementById("selectDiv").toggle();
+    $(e).children().toggle()
+    $(e).next().toggle()
+}
+function toggleYJL(e) {
+    if ($(e).children(".fa-angle-double-down").is(":hidden") == true) {
+        $(e).parent().css("height", 320)
+    } else {
+        $(e).parent().css("height", 10)
+        angular.element(document.getElementById("app")).scope().closeToggle()
+    }
+    $(e).children().toggle()
+}
+function toggleForm(e) {
+    $(e).children().toggle()
+    $(".toggleForm").toggle()
+}
+//文字不可被选中
+//document.body.onselectstart = function () {
+//    return true;
+//}

Энэ ялгаанд хэт олон файл өөрчлөгдсөн тул зарим файлыг харуулаагүй болно