Browse Source

数据录入-全部任务

yuedefeng 6 năm trước cách đây
mục cha
commit
7e378c21d0

+ 1 - 1
src/dashoo.cn/backend/api/controllers/casbin/module.go

@@ -44,7 +44,7 @@ func (this *ModuleController) List() {
 		where = where + " and Id in ( " + ids + " )"
 	}
 	var list []module.Base_Module
-	svc.GetEntities(&list, where)
+	svc.GetEntitiesByWhereOrder(&list, "SortCode asc", where)
 	var datainfo DataInfo
 	datainfo.Items = list
 	//datainfo.CurrentItemCount = total

+ 14 - 4
src/dashoo.cn/backend/api/controllers/lims/limsdataentry.go

@@ -224,6 +224,8 @@ func (this *LimsDataEntryController) GetToDoList() {
 	var list []limsdataentry.LimsDateEntryModel
 	//获取分页信息
 	page := this.GetPageInfoForm()
+	queryTaskStatus := this.GetString("queryTaskStatus")
+
 	svc := limsdataentry.GetLimsDataEntryService(utils.DBE)
 	//启动数据录入工作流
 	svcActiviti := workflow.GetActivitiService(utils.DBE)
@@ -233,10 +235,16 @@ func (this *LimsDataEntryController) GetToDoList() {
 	rsvc.GetAuditStepRoleEntity(OilAuditSettingName, this.User.DepartmentId, workflow.DATAAUDIT, &RoleSet)
 	//processInstanceId = svcActiviti.GetMyTasks(RoleSet.WorkFlowCord, this.User.Id)
 	//查出所有的待办和已办任务
-	processInstanceId = svcActiviti.GetAllMyTasks(RoleSet.WorkFlowCord, this.User.Id)
-	if len(processInstanceId) <= 0 {
-		processInstanceId = "0"
+	if len(queryTaskStatus) <= 0 { //保留原来的功能
+		processInstanceId = svcActiviti.GetMyTasks(RoleSet.WorkFlowCord, this.User.Id)
+	} else if queryTaskStatus == "1" { //待办
+		processInstanceId = svcActiviti.GetMyTasks(RoleSet.WorkFlowCord, this.User.Id)
+	} else if queryTaskStatus == "2" { //已办
+		processInstanceId = svcActiviti.GetAllMyTasks(RoleSet.WorkFlowCord, this.User.Id)
+	} else {
+
 	}
+
 	//switch this.User.DepartmentId {
 	//case "100000150":
 	//	processInstanceId = svcActiviti.GetMyTasks(workflow.TJZ_DATA_KEY, this.User.Id)
@@ -261,7 +269,9 @@ func (this *LimsDataEntryController) GetToDoList() {
 		orderby = Prop + " " + Order
 	}
 	where := " b.BalanceStatus <> 0 "
-	where += " and a.Id in (" + processInstanceId + ")"
+	if len(processInstanceId) > 0 {
+		where += " and a.Id in (" + processInstanceId + ")"
+	}
 	if EntrustNo != "" {
 		where = where + " and b.EntrustNo like '%" + EntrustNo + "%'"
 	}

+ 0 - 13
src/dashoo.cn/frontend_web/src/pages/index.vue

@@ -195,19 +195,6 @@
       _this.user.host = _this.authUser.Profile.Host
       _this.user.id = _this.authUser.Profile.Id
     },
-
-    async beforeMount () {
-      // 暂时从本地取菜单
-      let {data: menus1} = await this.$axios.get('users/getusermoduletree')
-      for (let idx in menus1) {
-        if (menus1[idx].url === '/') {
-          break
-        } else if (menus1[idx].url === '/lims/secondcenter') {
-          this.$router.push('/lims/secondcenter')
-        }
-      }
-    },
-
     methods: {
       handleClick (tab) {
         if (tab.index === '0') {

+ 9 - 3
src/dashoo.cn/frontend_web/src/pages/lims/dataentry/tacktodo.vue

@@ -4,7 +4,7 @@
       <el-breadcrumb-item :to="{ path: '/' }">平台首页</el-breadcrumb-item>
       <el-breadcrumb-item :to="{ path: '/lims/dataentry' }">检测数据录入</el-breadcrumb-item>
     </el-breadcrumb>-->
-    <el-card class="box-card" style="height: calc(100vh - 105px);">
+    <el-card class="box-card">
       <div slot="header">
         <span>
           <i class="icon icon-table2"></i> 数据录入
@@ -40,8 +40,8 @@
           </el-form-item>
         </el-form>
       </div>
-      <el-table :data="taskbalacelist" size="small" border height="calc(100vh - 243px)" :row-class-name="tableRowClassName"
-        @sort-change="orderby" @selection-change="handleSelectionChange">
+      <el-table :data="taskbalacelist" size="small" border style="height: calc(100vh - 243px)"  :row-class-name="tableRowClassName"
+        @sort-change="orderby" @selection-change="handleSelectionChange" v-loading="tableLoading">
         <el-table-column label="操作" width="180" align="center" fixed>
           <template slot-scope="scope">
             <el-button slot="reference" type="primary" size="mini" plain title="原始数据录入" v-if="scope.row.CheckStatus != 1 && scope.row.CheckStatus != 2"
@@ -327,6 +327,7 @@
     },
     data () {
       return {
+        tableLoading: true,
         // dialogdataentryhistoryVisible: false,
         adddataentryShow: false,
         dialogVisible: false,
@@ -504,6 +505,8 @@
           Prop: this.Column.Prop
         }
         Object.assign(params, this.searchform)
+
+        this.tableLoading = true
         // request
         _this.$axios.get('/limsdataentry/todolist?BalanceTime=' + BalanceTime.join(','), {
           params
@@ -511,8 +514,11 @@
           .then(res => {
             _this.taskbalacelist = res.data.items
             _this.currentItemCount = res.data.currentItemCount
+
+            this.tableLoading = false
           })
           .catch(err => {
+            this.tableLoading = false
             // handle error
             console.error(err)
           })

+ 1314 - 0
src/dashoo.cn/frontend_web/src/pages/lims/dataentry/tasktodo2.vue

@@ -0,0 +1,1314 @@
+<template>
+  <div>
+    <!--<el-breadcrumb class="heading">
+      <el-breadcrumb-item :to="{ path: '/' }">平台首页</el-breadcrumb-item>
+      <el-breadcrumb-item :to="{ path: '/lims/dataentry' }">检测数据录入</el-breadcrumb-item>
+    </el-breadcrumb>-->
+    <el-card class="box-card">
+      <div slot="header" style="height: 13px">
+        <el-radio-group v-model="queryTaskStatus" size="mini" style=" margin-top: -10px; float: left;" @change="initdata2()">
+          <el-radio-button :label="0">全部</el-radio-button>
+          <el-radio-button :label="1">待办</el-radio-button>
+          <el-radio-button :label="2">已办</el-radio-button>
+        </el-radio-group>
+
+        <span style="float: right; margin-top: -8px" class="cardrightform">
+          <el-button type="primary" size="mini" @click="adddataentry">添加</el-button>
+        </span>
+        <el-form ref="form" :inline="true" style="float: right; margin-top: -15px">
+
+          <el-form-item label="截止时间">
+            <el-date-picker size="mini" style="width: 220px" v-model="BalanceTime" type="daterange" range-separator="至"
+                            start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
+          </el-form-item>
+          <el-form-item label="委托单号">
+            <el-input size="mini" style="width: 165px;" v-model="searchform.EntrustNo" placeholder="请输入委托单号"></el-input>
+          </el-form-item>
+
+          <el-form-item label="审核状态">
+            <el-select size="mini" style="width: 90px;" v-model="searchform.CheckStatus" placeholder="请选择">
+              <el-option label="待审核" value="0"></el-option>
+              <el-option label="已审核" value="1"></el-option>
+              <el-option label="审核未通过" value="2"></el-option>
+            </el-select>
+          </el-form-item>
+
+          <el-form-item>
+            <el-dropdown split-button type="primary" size="mini" @click="clicksearch" @command="searchCommand">
+              查询
+              <el-dropdown-menu slot="dropdown">
+                <el-dropdown-item command="search">高级查询</el-dropdown-item>
+                <el-dropdown-item command="clear">查询重置</el-dropdown-item>
+              </el-dropdown-menu>
+            </el-dropdown>
+          </el-form-item>
+        </el-form>
+      </div>
+      <el-table :data="taskbalacelist" size="small" border style="height: calc(100vh - 243px)"  :row-class-name="tableRowClassName"
+                @sort-change="orderby" @selection-change="handleSelectionChange" v-loading="tableLoading">
+        <el-table-column label="操作" width="180" align="center" fixed>
+          <template slot-scope="scope">
+            <el-button slot="reference" type="primary" size="mini" plain title="原始数据录入" v-if="scope.row.CheckStatus != 1 && scope.row.CheckStatus != 2"
+                       @click="OpenOrignDataInput(scope.row)">
+              打开
+            </el-button>
+            <el-button slot="reference" type="primary" plain size="mini" title="数据校核" v-if="scope.row.CheckStatus == 1"
+                       @click="jiaoheshowdialog(scope.row)">
+              校核
+            </el-button>
+            <el-button slot="reference" type="primary" plain size="mini" title="预审" v-if="scope.row.CheckStatus == 2"
+                       @click="preauditdialog(scope.row)">
+              预审
+            </el-button>
+            <el-button slot="reference" type="primary" plain size="mini" title="数据审核" v-if="scope.row.CheckStatus == 4"
+                       @click="shenHeFunc(scope.row)">
+              审核
+            </el-button>
+            &nbsp;
+            <el-dropdown @command="MoreCmdClick">
+              <el-button size="mini" type="primary" plain>
+                更多<i class="el-icon-arrow-down el-icon--right"></i>
+              </el-button>
+              <el-dropdown-menu slot="dropdown">
+                <el-dropdown-item :command="GetCommand('Open', scope.row)" v-if="scope.row.CheckStatus == 1 || scope.row.CheckStatus == 2">数据打开</el-dropdown-item>
+                <el-dropdown-item :command="GetCommand('History', scope.row)">审批历史</el-dropdown-item>
+                <el-dropdown-item :command="GetCommand('ViewDocPdf', scope.row)">PDF查看</el-dropdown-item>
+                <el-dropdown-item :command="GetCommand('OpenExcel', scope.row)" v-if="scope.row.TaskId != ''" divided>打开Excel</el-dropdown-item>
+                <el-dropdown-item :command="GetCommand('DownLoadExcel', scope.row)" v-if="scope.row.TaskId != ''">下载Excel</el-dropdown-item>
+                <el-dropdown-item :command="GetCommand('DownloadTool', scope.row)" divided>下载工具</el-dropdown-item>
+                <el-dropdown-item :command="GetCommand('Delete', scope.row)" :disabled="scope.row.CheckStatus != 0"
+                                  divided>删除数据</el-dropdown-item>
+              </el-dropdown-menu>
+            </el-dropdown>
+            <!-- <el-button slot="reference" style="margin-left :10px;" type="primary" size="mini" plain title="查看文档" @click="ViewDocPdf(scope.row)">
+              查看
+            </el-button> -->
+            <!--<el-button slot="reference" type="primary" plain size="mini" title="校核" v-if="scope.row.CheckStatus == 1"  @click="jiaoheshowdialog(scope.row)">
+             校核
+            </el-button>
+            <el-button slot="reference" type="primary" plain size="mini" title="审核" v-if="scope.row.CheckStatus == 2"  @click="shenHeFunc(scope.row)">
+             审核
+            </el-button>
+            <el-button slot="reference" type="primary" size="mini" plain title="原始数据录入" @click="OpenOrignDataInput(scope.row)">
+              录入
+            </el-button>
+            <el-popover v-if="scope.row.TaskId != ''" placement="top" trigger="click" style="margin-left:10px">
+              <el-alert title="" description="请选择原始记录导出方式" type="success" :closable="false"></el-alert>
+              <br />
+              <div style="text-align: right; margin: 0">
+                <el-button type="primary" size="mini" @click="docdownload(scope.row)">导出</el-button>
+                <el-button type="primary" size="mini" @click="datadownload(scope.row)">下载到本地</el-button>
+              </div>
+              <el-button slot="reference" type="primary" title="导出" plain size="mini">
+                导出
+              </el-button>
+            </el-popover>-->
+          </template>
+        </el-table-column>
+        <el-table-column prop="EntrustNo" sortable min-width="110" label="委托单号" align="center" show-overflow-tooltip></el-table-column>
+        <el-table-column prop="DataEntryCode" sortable min-width="110" label="录入编码" align="center"
+                         show-overflow-tooltip></el-table-column>
+        <el-table-column prop="CustomerName" sortable min-width="120" label="委托方名称" align="center"
+                         show-overflow-tooltip></el-table-column>
+        <el-table-column prop="TestDetail" sortable min-width="120" label="检测明细项" align="center" show-overflow-tooltip></el-table-column>
+        <el-table-column prop="CreateBy" sortable min-width="90" label="负责人" align="center" show-overflow-tooltip></el-table-column>
+        <el-table-column prop="BalanceTime" sortable min-width="110" label="检测时间" align="center" show-overflow-tooltip>
+          <template slot-scope="scope">
+            {{ jstimehandle(scope.row.BalanceTime+'') }}
+          </template>
+        </el-table-column>
+        <el-table-column sortable min-width="110" align="center" prop="CheckStatus" label="审核状态">
+          <template slot-scope="scope">
+            <el-alert v-if="scope.row.CheckStatus=='2'" :closable="false" style="background:rgba(255,255,255,0.2)"
+                      title="待预审" type="warning">
+            </el-alert>
+            <el-alert v-if="scope.row.CheckStatus=='4'" :closable="false" style="background:rgba(255,255,255,0.2)"
+                      title="待审批" type="warning">
+            </el-alert>
+            <el-alert v-if="scope.row.CheckStatus=='0'" :closable="false" style="background:rgba(255,255,255,0.2)"
+                      title="待录入" type="info">
+            </el-alert>
+            <el-alert v-if="scope.row.CheckStatus=='1'" :closable="false" style="background:rgba(255,255,255,0.2)"
+                      title="待校核" type="warning">
+            </el-alert>
+            <el-alert v-if="scope.row.CheckStatus=='5'" :closable="false" style="background:rgba(255,255,255,0.2)"
+                      title="预审未通过" type="error">
+            </el-alert>
+            <el-alert v-if="scope.row.CheckStatus=='3'" :closable="false" style="background:rgba(255,255,255,0.2)"
+                      title="校核未通过" type="error">
+            </el-alert>
+            <el-alert v-if="scope.row.CheckStatus=='6'" :closable="false" style="background:rgba(255,255,255,0.2)"
+                      title="审批通过" type="success">
+            </el-alert>
+            <el-alert v-if="scope.row.CheckStatus=='7'" :closable="false" style="background:rgba(255,255,255,0.2)"
+                      title="审批未通过" type="error">
+            </el-alert>
+            <!-- <el-tag v-show="scope.row.CheckStatus=='0'" type="info" style="background:#FFFFFF" >待录入</el-tag>
+            <el-tag v-show="scope.row.CheckStatus=='1'" type="warning" >待校核</el-tag>
+            <el-tag v-show="scope.row.CheckStatus=='2'" type="success" style="background:#FFFFFF">待审核</el-tag>
+            <el-tag v-show="scope.row.CheckStatus=='3'" type="danger" style="background:#FFFFFF">校核未通过</el-tag>
+            <el-tag v-show="scope.row.CheckStatus=='4'" type="success" >审核通过</el-tag>
+            <el-tag v-show="scope.row.CheckStatus=='5'" type="danger" >审核未通过</el-tag> -->
+          </template>
+        </el-table-column>
+        <el-table-column prop="Remark" sortable label="备注" align="center" show-overflow-tooltip></el-table-column>
+      </el-table>
+      <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange" :current-page="currentPage"
+                     :page-sizes="[10, 15, 20, 25]" :page-size="size" layout="total, sizes, prev, pager, next, jumper" :total="currentItemCount">
+      </el-pagination>
+    </el-card>
+    <el-dialog title="历史版本" :visible.sync="historydialog" size="small" top="5vh" width="80%">
+      <el-table :data="historylist" border style="width: 100%" @sort-change="orderby">
+        <el-table-column label="操作" width="100" align="center" fixed>
+          <template slot-scope="scope">
+            <el-button type="primary" plain size="mini" title="查看" @click="historyview(scope.row)">
+              查看
+            </el-button>
+            <!-- <el-button type="text" title="数据录入历史" size="small" @click="history(scope.row)">
+              <i class="icon icon-file-text"></i>
+            </el-button> -->
+            <!-- <el-button size="small" type="text" style="margin-left:3px" icon="el-icon-delete" title="删除" @click="deletedata(scope.row)"></el-button> -->
+          </template>
+        </el-table-column>
+        <!-- <el-table-column sortable min-width="120" align="center" show-overflow-tooltip prop="DocKey" label="标识"></el-table-column> -->
+        <!-- <el-table-column sortable min-width="120" align="center" show-overflow-tooltip prop="DocType" label="文档类型名称"></el-table-column> -->
+        <el-table-column sortable min-width="120" align="center" show-overflow-tooltip prop="Version" label="文档版本"></el-table-column>
+        <el-table-column sortable min-width="120" align="center" show-overflow-tooltip prop="SaveTime" label="保存时间">
+          <template slot-scope="scope">
+            <p>{{jstimehandle(scope.row.SaveTime)}}</p>
+          </template>
+        </el-table-column>
+      </el-table>
+      <div slot="footer" class="dialog-footer" style="margin-top:-30px;">
+        <el-button type="primary" @click="historydialog = false">确 定</el-button>
+      </div>
+    </el-dialog>
+    <el-dialog title="高级查询" :visible.sync="dialogVisible" width="700px">
+      <el-form ref="advancedSearchForm" label-width="90px">
+        <el-row>
+          <el-col :span="12">
+            <el-form-item label="截止时间">
+              <el-date-picker size="mini" v-model="BalanceTime" type="daterange" style="width:100%" range-separator="至"
+                              start-placeholder="开始日期" end-placeholder="结束日期"></el-date-picker>
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <el-form-item label="委托单号">
+              <el-input size="mini" v-model="searchform.EntrustNo" style="width:100%" placeholder="请输入委托单号"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <el-form-item label="检验明细项">
+              <el-select size="mini" ref="refdetailselect" style="width:100%" v-model="searchform.TestDetailId"
+                         clearable>
+                <el-option v-for="item in detailList" :label="item.FullName" :value="item.Id" :key="item.Id"></el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <el-form-item label="审核状态">
+              <el-select size="mini" v-model="searchform.CheckStatus" style="width:100%" placeholder="请选择">
+                <el-option label="待审核" value="0"></el-option>
+                <el-option label="待校核" value="1"></el-option>
+                <el-option label="待审核" value="2"></el-option>
+                <el-option label="校核未通过" value="3"></el-option>
+                <el-option label="审核通过" value="4"></el-option>
+                <el-option label="审核未通过" value="5"></el-option>
+              </el-select>
+            </el-form-item>
+          </el-col>
+        </el-row>
+      </el-form>
+      <span slot="footer" class="dialog-footer">
+        <el-button size="mini" @click="dialogVisible = false">取 消</el-button>
+        <el-button size="mini" type="primary" @click="clicksearch">查 询</el-button>
+      </span>
+    </el-dialog>
+    <el-dialog title="校核信息" :visible.sync="jiaoheshow" top="5vh">
+      <el-form :model="jiaoheForm" label-width="130px" ref="jiaoheForm">
+        <el-form-item label="校核状态">
+          <template>
+            <el-radio class="radio" v-model="jiaoheForm.SuccessStatus" :label="2">待审核</el-radio>
+            <el-radio class="radio" v-model="jiaoheForm.SuccessStatus" :label="3">校核未通过</el-radio>
+          </template>
+        </el-form-item>
+        <el-form-item label="说明">
+          <el-input type="textarea" v-model="jiaoheForm.AuditorRemark" placeholder="请输入校核说明"></el-input>
+        </el-form-item>
+      </el-form>
+      <div slot="footer" class="dialog-footer" style="margin-top: -25px">
+        <el-button size="small" @click="jiaoheshow = false">取 消</el-button>
+        <el-button type="primary" size="small" @click="makesure()">确 定</el-button>
+      </div>
+    </el-dialog>
+    <el-dialog title="数据录入" :visible.sync="dataentryShow" top="15vh" width="460px" :before-close="handleClose">
+      <el-form :model="dataentryForm" label-width="160px" ref="dataentryForm">
+        <el-alert title="" description="请先访问网址 【weed1.labsop.cn:9390/3,0b86ca7a6f80】" type="warning" :closable="false">
+        </el-alert>
+        <el-alert title="" description="解压到后,以管理员身份运行一下,即安装成功 " type="warning" :closable="false">
+        </el-alert>
+        <br />
+        <el-alert title="文件保存修改注意!" description="请编辑完毕点击保存修改,不然您的修改将无效!" type="success" :closable="false">
+        </el-alert>
+        <!-- {{ dataentryForm.message }} -->
+      </el-form>
+      <div slot="footer" class="dialog-footer" style="margin-top: -25px">
+        <el-button v-if="this.dialogbuttonvisble" type="primary" size="small" @click="upload()">保存修改</el-button>
+        <el-button size="small" @click="cancel()">取 消</el-button>
+      </div>
+    </el-dialog>
+    <el-dialog title="历史数据录入信息" :visible.sync="dialogTableVisible">
+      <el-button type="primary" size="mini" style="float: right; margin-top: -10px" @click="opendocentry()">直接录入</el-button>
+      <br />
+      <el-alert title="" description="您可以选择相同模板输入的历史数据,加入您的数据中再做相应修改" type="success" :closable="false">
+      </el-alert>
+      <br />
+      <el-table :data="dataentryhistorylist" :stripe="true">
+        <el-table-column label="操作" width="100">
+          <template slot-scope="scope">
+            <el-button @click="handleselectentry(scope.row)" type="primary" plain size="mini" title="选择">
+              选择</el-button>
+          </template>
+        </el-table-column>
+        <el-table-column sortable min-width="120" align="center" show-overflow-tooltip prop="DocType" label="文档名称"></el-table-column>
+        <el-table-column sortable min-width="120" align="center" show-overflow-tooltip prop="CreatedTime" label="生成时间">
+          <template slot-scope="scope">
+            <p>{{jstimehandle(scope.row.CreatedTime)}}</p>
+          </template>
+        </el-table-column>
+      </el-table>
+      <el-pagination @size-change="historyhandleSizeChange" @current-change="historyhandleCurrentChange" :current-page="historycurrentPage"
+                     :page-sizes="[10, 15, 20, 25]" :page-size="historysize" layout="total, sizes, prev, pager, next, jumper" :total="historycurrentItemCount">
+      </el-pagination>
+    </el-dialog>
+    <el-dialog title="数据录入添加" :visible.sync="adddataentryShow" top="5vh">
+      <el-form :model="adddataentryFrom" label-width="130px" ref="adddataentryFrom">
+        <el-row>
+          <el-form-item label="委托单号">
+            <el-input type="text" v-model="adddataentryFrom.EntrustNo" placeholder="请输入委托单号" style="width: 100%">
+            </el-input>
+          </el-form-item>
+        </el-row>
+        <el-row>
+          <el-form-item label="检测人">
+            <el-select ref="selectConUserId" v-model="adddataentryFrom.ConUserId" filterable placeholder="请选择检测人" style="width: 100%">
+              <el-option v-for="item in partuserlist" :key="item.Id" :label="item.Realname" :value="item.Id">
+              </el-option>
+            </el-select>
+          </el-form-item>
+        </el-row>
+        <el-row>
+          <el-form-item label="备注">
+            <el-input type="textarea" v-model="adddataentryFrom.Remark" placeholder="请输入备注"></el-input>
+          </el-form-item>
+        </el-row>
+      </el-form>
+      <div slot="footer" class="dialog-footer" style="margin-top: -25px">
+        <el-button size="small" @click="adddataentryShow = false">取 消</el-button>
+        <el-button type="primary" size="small" @click="makesureaddata()">确 定</el-button>
+      </div>
+    </el-dialog>
+    <historytaskdialog :entryinfo="entrydetail" :visible.sync="historyVisible"></historytaskdialog>
+  </div>
+</template>
+<script>
+  import {
+    mapGetters
+  } from 'vuex'
+  // import DataEntryHistoryDialog from '../../../../components/lims/dataentryhistorydialog'
+  import historytaskdialog from '../../../components/lims/historytaskdialog'
+  import docTemplateApi from '@/api/lims/docTemplate'
+  import api from '@/api/lims/dataEntry'
+  export default {
+    name: 'tacktodo',
+    components: {
+      historytaskdialog
+    },
+    computed: {
+      ...mapGetters({
+        authUser: 'authUser'
+      })
+    },
+    data () {
+      return {
+        tableLoading: true,
+        queryTaskStatus: 0,
+        // dialogdataentryhistoryVisible: false,
+        adddataentryShow: false,
+        dialogVisible: false,
+        historyVisible: false,
+        entrydetail: {
+          process: '',
+          business: '',
+          instance: ''
+        },
+        auditorShow: false,
+        dataentryShow: false,
+        historylist: [],
+        historydialog: false,
+        addsheetshow: false,
+        dialogbuttonvisble: true,
+        dialogTableVisible: false,
+        tooldownloaddialog: false,
+        jiaoheshow: false,
+        CheckStatus: 0,
+        BalanceTime: [],
+        EntryId: '',
+        key: '',
+        SId: 0,
+        eid: 0,
+        tbid: 0,
+        datadocId: 0,
+        datadoc: '',
+        dataurl: '',
+        docname: '',
+        dataentryid: 0,
+        DataEntryId: 0,
+        currentdate: '',
+        detailList: [],
+        taskbalacelist: [],
+        selectSamples: [],
+        docTemplateDictList: [],
+        tableColumns2: [],
+        dataentryhistorylist: [],
+        currentItemCount: 0,
+        historycurrentItemCount: 0,
+        historycurrentPage: 1,
+        historysize: 10,
+        currentPage: 1,
+        size: 10,
+        searchform: {
+          EntrustNo: '',
+          testDetail: '',
+          TestDetailId: '',
+          department: '',
+          departmentId: '',
+          conUserId: '', // 负责人
+          DataDocId: '',
+          DataDoc: '',
+          conUserBy: '',
+          CheckStatus: ''
+        },
+        dataentryForm: {
+          message: '',
+          sheetnum: 1,
+          addsheetshow: false
+        },
+        shenheForm: {
+          SuccessStatus: 1,
+          AuditorRemark: ''
+        },
+        jiaoheForm: {
+          SuccessStatus: 2,
+          AuditorRemark: '',
+          DataEntryId: 0
+        },
+        Column: {
+          Order: '',
+          Prop: ''
+        },
+        tableColumns: [{
+          prop: 'DocType',
+          label: '文档名称',
+          width: 100,
+          sort: true
+        },
+
+          {
+            prop: 'CreatedTime',
+            label: '生成时间',
+            width: 100,
+            sort: true
+          }
+        ],
+        partuserlist: [],
+        adddataentryFrom: {
+          // TestDetail: '',
+          EntrustNo: '',
+          // CustomerName: '',
+          ConUserId: '',
+          ConUserBy: '',
+          Remark: ''
+        }
+      }
+    },
+    created () {
+      // this.initData()
+      this.getDictList()
+      this.getDetaillist() // 检测明细项下拉
+      this.initdata2()
+    },
+    watch: {
+      $route (val) {
+        this.initdata2()
+      }
+    },
+    methods: {
+      // 添加数据录入记录
+      adddataentry () {
+        this.getpartuserlist()
+        this.adddataentryShow = true
+      },
+      // 检测人列表
+      getpartuserlist () {
+        let _this = this
+        _this.$axios.get('limsbalance/partuserlist', {})
+          .then(res => {
+            // response
+            _this.partuserlist = res.data.items
+            /* _this.partuserlist.unshift({
+             'Id': _this.authUser.Profile.Id,
+             'Realname': _this.authUser.Profile.Realname
+             }) */
+          })
+          .catch(err => {
+            // handle error
+            console.error(err)
+          })
+      },
+      // 数据录入添加确认按钮
+      makesureaddata () {
+        this.adddataentryFrom.ConUserBy = this.$refs.selectConUserId.selectedLabel + ''
+        api.adddataentry(this.adddataentryFrom, this.$axios).then(res => {
+          if (res.data.code === 0) {
+            this.$message({
+              type: 'success',
+              message: res.data.message
+            })
+            this.adddataentryShow = false
+            this.initdata2()
+          } else {
+            this.$message({
+              type: 'warning',
+              message: res.data.message
+            })
+          }
+        }).catch(err => {
+          console.error(err)
+        })
+      },
+      initdata2 () {
+        let _this = this
+        let BalanceTime = []
+        if (!_this.BalanceTime) {
+          _this.BalanceTime = []
+        }
+        // 解析时间
+        if (_this.BalanceTime.length === 2) {
+          _this.BalanceTime[1].setHours(23)
+          _this.BalanceTime[1].setMinutes(59)
+          _this.BalanceTime[1].setSeconds(59)
+          BalanceTime.push(_this.formatDateTime(_this.BalanceTime[0]))
+          BalanceTime.push(_this.formatDateTime(_this.BalanceTime[1]))
+        }
+        // paginate
+        const params = {
+          docid: this.$route.query.docid,
+          _currentPage: this.currentPage,
+          _size: this.size,
+          Order: this.Column.Order,
+          Prop: this.Column.Prop,
+          queryTaskStatus: this.queryTaskStatus
+        }
+        Object.assign(params, this.searchform)
+
+        this.tableLoading = true
+        // request
+        _this.$axios.get('/limsdataentry/todolist?BalanceTime=' + BalanceTime.join(','), {
+          params
+        })
+          .then(res => {
+            _this.taskbalacelist = res.data.items
+            _this.currentItemCount = res.data.currentItemCount
+
+            this.tableLoading = false
+          })
+          .catch(err => {
+            this.tableLoading = false
+            // handle error
+            console.error(err)
+          })
+      },
+      // table背景
+      tableRowClassName ({
+                           row,
+                           rowIndex
+                         }) {
+        if (row.Recheck === 1) {
+          return 'warning-row'
+        }
+        return ''
+      },
+      MoreCmdClick (cmd) {
+        if (cmd.Command === 'Open') {
+          this.OpenOrignDataInput(cmd.row)
+        } else if (cmd.Command === 'JiaoHe') {
+          this.jiaoheshowdialog(cmd.row)
+        } else if (cmd.Command === 'ShenHe') {
+          this.shenHeFunc(cmd.row)
+        } else if (cmd.Command === 'History') {
+          this.getvalues(cmd.row)
+        } else if (cmd.Command === 'ViewDocPdf') {
+          this.ViewDocPdf(cmd.row)
+        } else if (cmd.Command === 'OpenExcel') {
+          this.docdownload(cmd.row)
+        } else if (cmd.Command === 'DownLoadExcel') {
+          this.datadownload(cmd.row)
+        } else if (cmd.Command === 'Delete') {
+          this.deldataentry(cmd.row)
+        } else if (cmd.Command === 'DownloadTool') {
+          this.tooldownload()
+        }
+      },
+      GetCommand (cmdType, row) {
+        let cmd = {}
+        cmd.Command = cmdType
+        cmd.row = row
+        return cmd
+      },
+      // 工具下载
+      tooldownload () {
+        let url = 'http://weed1.labsop.cn:9390/2,1080b2997d49'
+        window.open(url)
+        this.tooldownloaddialog = true
+      },
+      preauditdialog (row) {
+        this.dataentrytoexcel(row)
+      },
+      // 审核
+      shenHeFunc (row) {
+        this.dataentrytoexcel(row)
+      },
+      // 生成excel数据
+      dataentrytoexcel (row) {
+        api.docexport(row.Id, this.$axios)
+          .then(res => {
+            // response
+            if (res.data.code === 0) {
+              let docurl = res.data.item
+              let furl = docurl.DocUrl
+              this.changepage(row, furl)
+            }
+          }).catch(err => {
+          console.error(err)
+        })
+      },
+      // 审核页面跳转
+      changepage (row, DocAddress) {
+        let _this = this
+        let queryParams = {
+          key: row.DocKey,
+          docurl: DocAddress,
+          dataentryId: row.Id,
+          docname: row.DocName,
+          checkstaus: row.CheckStatus
+        }
+        console.log(queryParams, 'queryParamsqueryParams')
+        _this.$router.push({
+          path: '/lims/dataentry/onlyofficesframe',
+          query: queryParams
+        })
+      },
+      getDictList () {
+        docTemplateApi.getDictList(this.$axios).then(res => {
+          this.docTemplateDictList = res.data
+        })
+      },
+      getvalues (val) {
+        this.entrydetail.business = val.Id
+        this.entrydetail.instance = val.DocKey
+        this.historyVisible = true
+      },
+      handleChange (value) {
+      },
+      OpenOrignDataInput (row) {
+        this.CheckStatus = row.CheckStatus
+        this.eid = row.EId
+        this.tbid = row.TaskId
+        this.DataEntryId = row.Id
+        this.datadocId = row.DataDocId
+        this.datadoc = row.DataDoc
+        this.opendocentry()
+
+        /** const params = {
+          _currentPage: this.historycurrentPage,
+          _size: this.historysize,
+          datadocId: this.datadocId
+        }
+         let entryId = row.Id
+         api.getDataEntryReportList(params, entryId, this.$axios)
+         .then(res => {
+            if (!res.data.item) {
+              this.DataEntryId = res.data.info
+              this.opendocentry()
+            } else {
+              this.dataentryhistorylist = res.data.item
+              this.historycurrentItemCount = res.data.currentItemCount
+              this.dialogTableVisible = true
+            }
+          }).catch(err => {
+            console.error(err)
+          }) */
+      },
+      ViewDocPdf (row) {
+        api.docexport(row.Id, this.$axios)
+          .then(res => {
+            // response
+            if (res.data.code === 0) {
+              let docurl = res.data.item
+              let furl = docurl.DocUrl
+              this.changepdfpage(row, furl)
+            }
+          }).catch(err => {
+          console.error(err)
+        })
+      },
+      // 查看文档pdf
+      changepdfpage (row, DocAddress) {
+        let _this = this
+        let queryParams = {
+          key: row.DocKey,
+          docurl: DocAddress,
+          dataentryId: row.Id,
+          docname: row.DocName
+        }
+        _this.$router.push({
+          path: '/lims/dataentry/docviewframe',
+          query: queryParams
+        })
+      },
+      // 选择页码刷新历史数据
+      refreshdataentrydata () {
+        const params = {
+          _currentPage: this.historycurrentPage,
+          _size: this.historysize,
+          datadocId: this.datadocId
+        }
+        api.getDataEntryRefresh(params, this.$axios)
+          .then(res => {
+            this.dataentryhistorylist = res.data.item
+            this.historycurrentItemCount = res.data.currentItemCount
+            this.dialogTableVisible = true
+          }).catch(err => {
+          console.error(err)
+        })
+      },
+      datadownload (val) {
+        api.docexport(val.Id, this.$axios)
+          .then(res => {
+            // response
+            if (res.data.code === 0) {
+              this.$message({
+                type: 'success',
+                message: res.data.message
+              })
+              let docurl = res.data.item
+              this.dataentryid = docurl.DataEntryId
+              // let furl = docurl.DocAddress
+              let fdocurl = docurl.DocUrl
+              // let fname = docurl.DocName
+              location.href = 'http://' + fdocurl
+            }
+          }).catch(err => {
+          console.error(err)
+        })
+      },
+      // 数据录入导出
+      docdownload (val) {
+        api.docexport(val.Id, this.$axios)
+          .then(res => {
+            // response
+            if (res.data.code === 0) {
+              this.$message({
+                type: 'success',
+                message: res.data.message
+              })
+              let docurl = res.data.item
+              this.dataentryid = docurl.DataEntryId
+              let furl = docurl.DocAddress
+              let fname = docurl.DocName
+              location.href = 'petrotool://furl=' + furl + '&fname=' + fname + '&doctype=data&id=' + this.dataentryid +
+                '&act=edit'
+            }
+          }).catch(err => {
+          console.error(err)
+        })
+      },
+      // 删除数据
+      deldataentry (val) {
+        this.$confirm('此操作将永久删除该数据, 是否继续?', '提示', {
+          confirmButtonText: '确定',
+          cancelButtonText: '取消',
+          type: 'warning'
+        }).then(() => {
+          api.dataentrydelect(val.Id, this.$axios).then(res => {
+            if (res.data.code === 0) {
+              this.$message({
+                type: 'success',
+                message: res.data.message
+              })
+              this.initdata2()
+            } else {
+              this.$message({
+                type: 'warning',
+                message: res.data.message
+              })
+            }
+          }).catch(err => {
+            // handle error
+            console.error(err)
+          })
+        }).catch(err => {
+          // handle error
+          console.error(err)
+        })
+      },
+      opendocentry () {
+        let docTempType = ''
+        for (let idx in this.docTemplateDictList) {
+          if (this.datadocId === this.docTemplateDictList[idx].Id) {
+            docTempType = this.docTemplateDictList[idx].TemplateCode
+          }
+        }
+        let queryParams = {
+          eid: this.eid,
+          tbid: this.tbid,
+          deid: this.DataEntryId,
+          datastatus: this.CheckStatus,
+          datadocId: this.datadocId,
+          sign: '1',
+          ischeck: this.CheckStatus
+        }
+        switch (docTempType) {
+          // 漏电保护
+          case 'DAYT.LeakProtect.Detail':
+            this.$router.push({
+              path: '/lims/reportleakprotect/subdata/datalist',
+              query: queryParams
+            })
+            break
+          // 空气泡沫
+          case 'DAYT.Airfoamgenerator.Detail':
+            this.$router.push({
+              path: '/lims/reportairfoamgenerator/subdata/datalist',
+              query: queryParams
+            })
+            break
+          // 呼吸阀
+          case 'DAYT.AtmosValve.Detail':
+            this.$router.push({
+              path: '/lims/reportatmosvalve/subdata/datalist',
+              query: queryParams
+            })
+            break
+          // 液压安全阀
+          case 'DAYT.HydraulicSafe.Detail':
+            this.$router.push({
+              path: '/lims/reporthydraulicsafe/subdata/datalist',
+              query: queryParams
+            })
+            break
+          // 电气接地
+          case 'DAYT.ElecGround.Detail':
+            this.$router.push({
+              path: '/lims/reportelecground/subdata/datalist',
+              query: queryParams
+            })
+            break
+          // 防雷装置等电位
+          case 'DAYT.Equipotent.Detail':
+            this.$router.push({
+              path: '/lims/reportequipotent/subdata/datalist',
+              query: queryParams
+            })
+            break
+          // 防雷装置
+          case 'DAYT.LightProtect.Detail':
+            this.$router.push({
+              path: '/lims/reportlightprotect/datareview',
+              query: queryParams
+            })
+            break
+          // 电流表
+          case 'DAYT.Ammeter.Detail':
+            this.$router.push({
+              path: '/lims/reportammeter/subdata/dataopera',
+              query: queryParams
+            })
+            break
+          // 阻火器
+          case 'DAYT.BackFire.Detail':
+            this.$router.push({
+              path: '/lims/reportzuhq/subdata/datalist',
+              query: queryParams
+            })
+            break
+          // 游梁式抽油机
+          case 'DAYT.BeamPumpingUnits.Detail':
+            this.$router.push({
+              path: '/lims/reportbeampumpingUnits/subdata/dataopera',
+              query: queryParams
+            })
+            break
+          // 无游梁式抽油机
+          case 'DAYT.NoBeamPumpingUnits.Detail':
+            this.$router.push({
+              path: '/lims/reportnobeampumpingUnits/subdata/dataopera',
+              query: queryParams
+            })
+            break
+          // 苯气检测报警器检定记录
+          case 'DAYT.ReportAlertorBenDetect.Detail':
+            this.$router.push({
+              path: '/lims/reportalertorbendetect/operation',
+              query: queryParams
+            })
+            break
+          // 一氧化碳检测报警器检定记录
+          case 'DAYT.ReportAlertorCarbonDetect.Detail':
+            this.$router.push({
+              path: '/lims/reportalertorcarbondetect/operation',
+              query: queryParams
+            })
+            break
+          // 复合气体检测报警器检定记录
+          case 'DAYT.ReportAlertorFHGasDetect.Detail':
+            this.$router.push({
+              path: '/lims/reportalertorfhgasdetect/operation',
+              query: queryParams
+            })
+            break
+          // 可燃气体检测报警器检定记录
+          case 'DAYT.ReportAlertorKRGasDetect.Detail':
+            this.$router.push({
+              path: '/lims/reportalertorkrgasdetect/operation',
+              query: queryParams
+            })
+            break
+          // 一氧化碳红外气体分析器检定记录
+          case 'DAYT.ReportAnalyzer1CarbonRedGas.Detail':
+            this.$router.push({
+              path: '/lims/reportanalyzer1carbonredgas/operation',
+              query: queryParams
+            })
+            break
+          // 二氧化碳红外气体分析器检定记录
+          case 'DAYT.ReportAnalyzer2CarbonRedGas.Detail':
+            this.$router.push({
+              path: '/lims/reportanalyzer2carbonredgas/operation',
+              query: queryParams
+            })
+            break
+          // 电化学氧测定仪检定记录
+          case 'DAYT.ReportDetectorElectOxygen.Detail':
+            this.$router.push({
+              path: '/lims/reportdetectorelectoxygen/operation',
+              query: queryParams
+            })
+            break
+          // 硫化氢气体检测仪检定记录
+          case 'DAYT.ReportDetectorHSGas.Detail':
+            this.$router.push({
+              path: '/lims/reportdetectorHSgas/operation',
+              query: queryParams
+            })
+            break
+          // 离心泵机组液体输送系统节能监测原始记录
+          case 'DAYT.LiquidTransportation.Detail':
+            this.$router.push({
+              path: '/lims/reportliquidtransportation/operation',
+              query: queryParams
+            })
+            break
+          // 柱塞泵机组液体输送系统
+          case 'DAYT.ReportPistonPumpUnit.Detail':
+            this.$router.push({
+              path: '/lims/reportpistonpumpunit/operation',
+              query: queryParams
+            })
+            break
+          // 电动机节能
+          case 'DAYT.LimsReportMotor.Detail':
+            this.$router.push({
+              path: '/lims/reportmotor/operation',
+              query: queryParams
+            })
+            break
+          // 电泵井节能
+          case 'DAYT.LimsReportElecPumpWell.Detail':
+            this.$router.push({
+              path: '/lims/reportelecpumpwell/operation',
+              query: queryParams
+            })
+            break
+          // 螺杆泵
+          case 'DAYT.LimsReportScrewPump.Detail':
+            this.$router.push({
+              path: '/lims/reportscrewpump/operation',
+              query: queryParams
+            })
+            break
+          // 油田专用变压器
+          case 'DAYT.LimsReportSpecialField.Detail':
+            this.$router.push({
+              path: '/lims/reportspecialfield/operation',
+              query: queryParams
+            })
+            break
+          // 加热炉节能监测原始记录表
+          case 'DAYT.ReportHeatingFurnace.Detail':
+            this.$router.push({
+              path: '/lims/reportheatingfurnace/operation',
+              query: queryParams
+            })
+            break
+          // 石油专用管材钻杆
+          case 'DAYT.PipeDrillPipe.Detail':
+            this.$router.push({
+              path: '/lims/wzjys/reportpipedrillpipe/datalist',
+              query: queryParams
+            })
+            break
+          // 石油专用管材方钻杆
+          case 'DAYT.PetroleumPipe.Detail':
+            this.$router.push({
+              path: '/lims/wzjys/reportpetroleumpipe/datalist',
+              query: queryParams
+            })
+            break
+          // 钻铤
+          case 'DAYT.DrillCollar.Detail':
+            this.$router.push({
+              path: '/lims/wzjys/reportdrillcollar/datalist',
+              query: queryParams
+            })
+            break
+          // 石油专用管材油(套)管超声波检测
+          case 'DAYT.ReportOilPipeUltrasonic.Detail':
+            this.$router.push({
+              path: '/lims/wzjys/reportoilpipeult/datalist',
+              query: queryParams
+            })
+            break
+          default:
+            this.$message.warning('无模板类型相匹配,请重试')
+        }
+      },
+      handleselectentry (val) {
+        let params = {
+          eid: this.eid,
+          tbid: this.tbid,
+          deid: this.DataEntryId,
+          datadocId: this.datadocId
+        }
+        api.dataEntryhistory(params, val.Id, this.$axios)
+          .then(res => {
+            if (res.data.code === 0) {
+              this.dialogTableVisible = false
+              this.DataEntryId = res.data.item
+              this.opendocentry()
+            } else {
+              this.$message({
+                type: 'warning',
+                message: res.data.message
+              })
+            }
+          }).catch(err => {
+          console.error(err)
+        })
+      },
+      dataentry (val) {
+        let _this = this
+        _this.key = val.EntrustNo + '' + val.TestDetailId
+        // var accCode = this.authUser.Profile.AccCode
+        // var userId = this.authUser.Profile.Id
+        // var realname = this.authUser.Profile.Realname
+        Object.assign(val, this.dataentryForm)
+        if (val.CheckStatus !== 0) {
+          this.dialogbuttonvisble = false
+        }
+        if (val.DataDocId === '') {
+          this.$message({
+            type: 'warning',
+            message: '无模板!'
+          })
+        } else {
+          // 先将初始数据录入记录写入excel
+          _this.$axios.post('/limsdataentry/datatoexcel/' + _this.key, val)
+            .then(res => {
+              // response
+              if (res.data.code === 0) {
+                this.dataentryForm.message = '请编辑完毕点击保存修改,不然您的修改将无效!'
+                let docurl = res.data.item
+                this.dataurl = docurl.DocAddress
+                this.docname = docurl.DocName
+                this.dataentryid = docurl.DataEntryId
+                let furl = docurl.DocAddress
+                let fname = docurl.DocName
+                location.href = 'petrotool://furl=' + furl + '&fname=' + fname + '&doctype=data&id=' + this.dataentryid +
+                  '&act=edit'
+                this.initdata2()
+              } else {
+                _this.$message({
+                  type: 'warning',
+                  message: res.data.message
+                })
+              }
+            })
+            .catch(err => {
+              // handle error
+              console.error(err)
+            })
+        }
+        this.dataentryShow = true
+      },
+      review (val) {
+        let url = 'dataentry/' + val.DocVersion + '/office_history?Address=' + val.DocAddress
+        window.open(url)
+      },
+      upload () {
+        location.href = 'petrotool://furl=' + this.dataurl + '&fname=' + this.docname + '&doctype=data&id=' + this.dataentryid +
+          '&act=up&token=' + localStorage.getItem('token')
+        this.$message({
+          type: 'success',
+          message: '修改已保存'
+        })
+        this.initdata2()
+        this.dataentryShow = false
+      },
+      cancel () {
+        location.href = 'petrotool://furl=' + this.dataurl + '&fname=' + this.docname + '&doctype=data&id=' + this.dataentryid +
+          '&act=cancel&token=' + localStorage.getItem('token')
+        this.dataentryShow = false
+        this.initdata2()
+      },
+      dataentry_onlyoffice (val) {
+        let _this = this
+        _this.key = val.EntrustNo + '' + val.TestDetailId
+        var accCode = this.authUser.Profile.AccCode
+        var userId = this.authUser.Profile.Id
+        var realname = this.authUser.Profile.Realname
+        if (val.DataDocId === '') {
+          this.$message({
+            type: 'warning',
+            message: '还没有模板!'
+          })
+        } else {
+          // 先将初始数据录入记录写入excel
+          _this.$axios.post('/limsdataentry/datatoexcel/' + _this.key, val)
+            .then(res => {
+              // response
+              if (res.data.code === 0) {
+                _this.$message({
+                  type: 'success',
+                  message: res.data.message
+                })
+                let docurl = res.data.item
+                let key = docurl.DocKey
+                let url = 'dataentry/' + key + '/office?DocId=' + val.DataDocId + '&DocType=' + val.DataDoc +
+                  '&AccCode=' + accCode + '&UserId=' + userId + '&RealName=' + realname + '&Edit=true&Address=' +
+                  docurl.DocAddress
+                window.open(url)
+              } else {
+                _this.$message({
+                  type: 'warning',
+                  message: res.data.message
+                })
+              }
+            })
+            .catch(err => {
+              // handle error
+              console.error(err)
+            })
+        }
+      },
+      gethistory (val) {
+        let _this = this
+        _this.historydialog = true
+        this.$axios.get('/limsdataentry/historylist/' + val.Id, {})
+          .then(res => {
+            _this.historylist = res.data.items
+          })
+          .catch(err => {
+            // handle error
+            console.error(err)
+          })
+      },
+      historyview (val) {
+        let historykey = val.DocKey + '' + val.Version
+        let url = 'dataentry/' + historykey + '/office_history?Address=' + val.Address
+        window.open(url)
+      },
+      dataentryview (val) {
+        let key = val.DocKey + '' + val.Version
+        var accCode = this.authUser.Profile.AccCode
+        var userId = this.authUser.Profile.Id
+        var realname = this.authUser.Profile.Realname
+        let url = 'dataentry/' + key + '/office?DocId=' + val.DataDocId + '&DocType=' + val.DataDoc + '&AccCode=' +
+          accCode + '&UserId=' + userId + '&RealName=' + realname + '&Edit=false'
+        window.open(url)
+      },
+      handleSelectionChange (val) {
+        this.selectSamples = val
+      },
+      handleClose (done) {
+        this.$confirm('确认关闭?')
+          .then(_ => {
+            done()
+            this.initdata2()
+            this.dialogbuttonvisble = true
+          })
+          .catch(_ => {})
+      },
+      // 打开校核弹窗
+      jiaoheshowdialog (val) {
+        // console.log('------jioahe', val)
+        // this.jiaoheForm.DataEntryId = val.Id
+        // this.jiaoheshow = true
+        this.OpenOrignDataInput(val)
+      },
+      makesure () {
+        this.$confirm('确认校核!', '提示', {
+          confirmButtonText: '确定',
+          cancelButtonText: '取消',
+          type: 'warning'
+        })
+          .then(() => {
+            this.jiaoheshow = false
+            this.checkstatus()
+          })
+          .catch(() => {})
+      },
+      checkstatus () {
+        let params = this.jiaoheForm
+        this.$axios.put('/limsdataentry/jiaohe/', params)
+          .then(res => {
+            // response
+            if (res.data.code === 0) {
+              this.$message({
+                type: 'success',
+                message: res.data.message
+              })
+              this.initdata2()
+            } else {
+              this.$message({
+                type: 'warning',
+                message: '校核错误,请先确定您已经录入内容并且录入的内容已经保存'
+              })
+            }
+          })
+          .catch(err => {
+            // handle error
+            console.error(err)
+          })
+      },
+      openexcel (val) {
+        let key = val.EntrustNo + '' + val.TestDetailId
+        let url = 'dataentry/' + key + '/office'
+        window.open(url)
+      },
+      searchCommand (command) {
+        if (command === 'search') {
+          this.dialogVisible = true
+        } else if (command === 'clear') {
+          this.clearSearch()
+        }
+      },
+      // 列表排序功能
+      orderby (column) {
+        if (column.order === 'ascending') {
+          this.Column.Order = 'asc'
+        } else if (column.order === 'descending') {
+          this.Column.Order = 'desc'
+        }
+        this.Column.Prop = column.prop
+        this.initdata2()
+      },
+      getDetaillist () {
+        let _this = this
+        _this.$axios.get('/limsbalance/getdetaillist', {})
+          .then(res => {
+            _this.detailList = res.data.items
+          })
+          .catch(err => {
+            // handle error
+            console.error(err)
+          })
+      },
+      clearSearch () {
+        this.searchform.EntrustNo = ''
+        this.searchform.TestDetailId = ''
+        this.searchform.CheckStatus = ''
+        this.BalanceTime = []
+        // this.searchform.TestDetailId = ''
+        this.initdata2()
+      },
+      clicksearch () {
+        this.currentPage = 1
+        this.initdata2()
+      },
+      handleCurrentChange (value) {
+        this.currentPage = value
+        this.initdata2()
+      },
+      handleSizeChange (value) {
+        this.size = value
+        this.currentPage = 1
+        this.initdata2()
+      },
+      historyhandleCurrentChange (value) {
+        this.historycurrentPage = value
+        this.refreshdataentrydata()
+      },
+      historyhandleSizeChange (value) {
+        this.historysize = value
+        this.historycurrentPage = 1
+        this.refreshdataentrydata()
+      },
+      jstimehandle (val) {
+        if (val === '') {
+          return '----'
+        } else if (val === '0001-01-01T08:00:00+08:00') {
+          return '----'
+        } else if (val === '5000-01-01T23:59:59+08:00') {
+          return '永久'
+        } else {
+          val = val.replace('T', ' ')
+          return val.substring(0, 19)
+        }
+      },
+      formatDateTime (date) {
+        var y = date.getFullYear()
+        var m = date.getMonth() + 1
+        m = m < 10 ? ('0' + m) : m
+        var d = date.getDate()
+        d = d < 10 ? ('0' + d) : d
+        var h = date.getHours()
+        var minute = date.getMinutes()
+        minute = minute < 10 ? ('0' + minute) : minute
+        return y + '-' + m + '-' + d + ' ' + h + ':' + minute
+      },
+      getdate () {
+        let date = new Date()
+        var year = date.getFullYear()
+        var month = date.getMonth() + 1
+        var strDate = date.getDate()
+        if (month >= 1 && month <= 9) {
+          month = '0' + month
+        }
+        if (strDate >= 0 && strDate <= 9) {
+          strDate = '0' + strDate
+        }
+        this.currentdate = year + '' + month + '' + strDate
+      }
+    }
+  }
+</script>
+
+<style lang="scss">
+  .el-pagination {
+    margin: 1rem 0 2rem;
+    text-align: right;
+  }
+
+</style>

+ 1 - 1
src/dashoo.cn/frontend_web/src/pages/lims/secondcenter/towLevelCenter.vue

@@ -3,7 +3,7 @@
     <el-card class="box-card">
       <div slot="header">
         <span>
-          <i class="icon icon-table2"></i> 统计
+          <i class="icon icon-table2"></i> 首页
         </span>
         <el-form ref="form" :inline="true" style="float: right; margin-top: -10px" v-if="beijiance || Isauthority">
           <!--<el-form-item label="检测时间">

+ 2 - 2
src/dashoo.cn/frontend_web/src/pages/lims/taskplan/_opera/operation.vue

@@ -98,8 +98,8 @@
             </el-form-item>
           </el-col>
 
-          <el-col :span="8" v-if="tjz">
-          </el-col>
+         <!-- <el-col :span="8" v-if="tjz">
+          </el-col>-->
 
           <!-- 暂时隐藏
           <el-col :span="8">

+ 2 - 2
src/dashoo.cn/frontend_web/src/pages/lims/tasksentrust/index.vue

@@ -9,11 +9,11 @@
           <el-breadcrumb-item :to="{ path: '/' }">平台首页</el-breadcrumb-item>
           <el-breadcrumb-item :to="{ path: '/lims/tasksentrust' }">检测任务</el-breadcrumb-item>
         </el-breadcrumb>
-        <span style="float: right;">
+        <!--<span style="float: right;">
           <router-link :to="'/lims/tasksentrust/addentrust/operation'">
             <el-button type="primary" size="mini" style="margin-left:10px; margin-top: -4px;" :disabled="!permissions[permissionscode.add]">添加</el-button>
           </router-link>
-        </span>
+        </span>-->
         <el-form ref="form" :inline="true" style="float: right; margin-top: -10px">
           <el-form-item label="委托时间">
             <el-date-picker size="mini" style="width: 220px" v-model="EntrustTime" type="daterange" range-separator="至"

+ 4 - 0
src/dashoo.cn/frontend_web/src/pages/login.vue

@@ -161,6 +161,10 @@
                   this.$router.push(this.$route.query.page || '/')
                 } else if (menus1[idx].url === '/lims/secondcenter') {
                   this.$router.push('/lims/secondcenter')
+                } else if (menus1[idx].url === '/lims/secondunitform/positionmgr') {
+                  this.$router.push('/lims/secondunitform/positionmgr')
+                } else {
+                  this.$router.push(this.$route.query.page || '/')
                 }
               }
             } else if (process.env.appclient === 'cellbank') {

+ 1 - 1
src/dashoo.cn/frontend_web/src/pages/system/module.vue

@@ -198,7 +198,7 @@
             console.error(err)
           })
       },
-      getmoduletreelist() {
+      getmoduletreelist () {
         let _this = this
         // request
         _this.$axios.get('/module/list', {