|
@@ -13,22 +13,6 @@
|
|
|
v-model="search.Name"
|
|
v-model="search.Name"
|
|
|
placeholder="请输入人员姓名"></el-input>
|
|
placeholder="请输入人员姓名"></el-input>
|
|
|
</el-form-item>
|
|
</el-form-item>
|
|
|
- <!-- <el-form-item label="设备大类"
|
|
|
|
|
- class="sbutton_margin">
|
|
|
|
|
- <el-select style="width:140px;"
|
|
|
|
|
- v-model="search.classification"
|
|
|
|
|
- clearable
|
|
|
|
|
- placeholder="请选择设备大类">
|
|
|
|
|
- <el-option v-for="item in classificationlist"
|
|
|
|
|
- :key="item.Value"
|
|
|
|
|
- :label="item.Value"
|
|
|
|
|
- :value="item.Value">
|
|
|
|
|
- </el-option>
|
|
|
|
|
- </el-select>
|
|
|
|
|
- </el-form-item> -->
|
|
|
|
|
- <!-- <el-form-item label="创建时间" class="sbutton_margin">
|
|
|
|
|
- <el-date-picker style="width: 220px" v-model="CalibrationTime" type="daterange" range-separator="至" start-placeholder="开始时间" end-placeholder="结束日期"></el-date-picker>
|
|
|
|
|
- </el-form-item> -->
|
|
|
|
|
<el-button size="mini"
|
|
<el-button size="mini"
|
|
|
type="primary"
|
|
type="primary"
|
|
|
@click="initDatas()"
|
|
@click="initDatas()"
|
|
@@ -59,15 +43,12 @@
|
|
|
align="center"
|
|
align="center"
|
|
|
fixed='right'>
|
|
fixed='right'>
|
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
|
- <!-- <router-link :to="'/personnel/' + scope.row.Id + '/personneledit'"> -->
|
|
|
|
|
- <!-- <router-link :to="'/personnel/personneldetails?id='+scope.row.Id +''"> -->
|
|
|
|
|
<el-button size="mini"
|
|
<el-button size="mini"
|
|
|
title="编辑"
|
|
title="编辑"
|
|
|
type="primary"
|
|
type="primary"
|
|
|
@click="personneledit(scope.row.Id)"
|
|
@click="personneledit(scope.row.Id)"
|
|
|
icon="el-icon-edit"
|
|
icon="el-icon-edit"
|
|
|
circle></el-button>
|
|
circle></el-button>
|
|
|
- <!-- </router-link> -->
|
|
|
|
|
<el-button size="mini"
|
|
<el-button size="mini"
|
|
|
type="danger"
|
|
type="danger"
|
|
|
title="删除"
|
|
title="删除"
|
|
@@ -75,29 +56,6 @@
|
|
|
style="margin-left:5px;"
|
|
style="margin-left:5px;"
|
|
|
icon="el-icon-delete"
|
|
icon="el-icon-delete"
|
|
|
circle></el-button>
|
|
circle></el-button>
|
|
|
- <!-- <router-link :to="'/personnel/maintainlog?id='+scope.row.Id +''">
|
|
|
|
|
- <el-button size="mini" title="质量管理" type="warning" style="margin-left:5px;" icon="fa fa-flask" circle>
|
|
|
|
|
- </el-button>
|
|
|
|
|
- </router-link>
|
|
|
|
|
- <router-link :to="'/personnel/instrumenrunrecord?id='+scope.row.Id +''">
|
|
|
|
|
- <el-button size="mini" title="运行记录" type="warning" style="margin-left:5px;" icon="fa fa-tachometer" circle>
|
|
|
|
|
- </el-button>
|
|
|
|
|
- </router-link> -->
|
|
|
|
|
- <!-- <el-dropdown>
|
|
|
|
|
- <el-button size="mini" type="success" >
|
|
|
|
|
- 更多
|
|
|
|
|
- <i class="el-icon-arrow-down el-icon--right"></i>
|
|
|
|
|
- </el-button>
|
|
|
|
|
- <el-dropdown-menu slot="dropdown">
|
|
|
|
|
-
|
|
|
|
|
- <el-dropdown-item>
|
|
|
|
|
-
|
|
|
|
|
- </el-dropdown-item>
|
|
|
|
|
- <el-dropdown-item>
|
|
|
|
|
-
|
|
|
|
|
- </el-dropdown-item>
|
|
|
|
|
- </el-dropdown-menu>
|
|
|
|
|
- </el-dropdown> -->
|
|
|
|
|
</template>
|
|
</template>
|
|
|
</el-table-column>
|
|
</el-table-column>
|
|
|
<el-table-column prop="PersonnelName"
|
|
<el-table-column prop="PersonnelName"
|
|
@@ -127,31 +85,11 @@
|
|
|
align="center"
|
|
align="center"
|
|
|
min-width="120px"
|
|
min-width="120px"
|
|
|
show-overflow-tooltip></el-table-column>
|
|
show-overflow-tooltip></el-table-column>
|
|
|
-
|
|
|
|
|
- <!-- <el-table-column prop="CalibrationTime"
|
|
|
|
|
- sortable
|
|
|
|
|
- label="校准时间"
|
|
|
|
|
- align="center"
|
|
|
|
|
- width="140px"
|
|
|
|
|
- show-overflow-tooltip>
|
|
|
|
|
- <template slot-scope="scope">{{ jstimehandle(scope.row.CalibrationTime +'') }}</template>
|
|
|
|
|
- </el-table-column> -->
|
|
|
|
|
-
|
|
|
|
|
- <!-- <el-table-column prop="CalibrationDeadline"
|
|
|
|
|
- sortable
|
|
|
|
|
- align="center"
|
|
|
|
|
- width="100px"
|
|
|
|
|
- label="校准期限"></el-table-column> -->
|
|
|
|
|
<el-table-column prop="Address"
|
|
<el-table-column prop="Address"
|
|
|
align="center"
|
|
align="center"
|
|
|
min-width="100px"
|
|
min-width="100px"
|
|
|
label="地址"></el-table-column>
|
|
label="地址"></el-table-column>
|
|
|
|
|
|
|
|
- <!-- <el-table-column prop="Type"
|
|
|
|
|
- min-width="160px"
|
|
|
|
|
- label="类型"
|
|
|
|
|
- align="center"
|
|
|
|
|
- show-overflow-tooltip></el-table-column> -->
|
|
|
|
|
</el-table>
|
|
</el-table>
|
|
|
<!-- </el-card> -->
|
|
<!-- </el-card> -->
|
|
|
<addpersonnellog ref="addpersonnel"
|
|
<addpersonnellog ref="addpersonnel"
|
|
@@ -179,15 +117,7 @@
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
<script>
|
|
|
-// import {
|
|
|
|
|
-// classificationlist,
|
|
|
|
|
-// searchdata,
|
|
|
|
|
-// deletepersonnel
|
|
|
|
|
-// } from '@/api/personnel'
|
|
|
|
|
import PersonnelApi from '@/api/personnel'
|
|
import PersonnelApi from '@/api/personnel'
|
|
|
-// import {
|
|
|
|
|
-// deletetriggerlistfordid
|
|
|
|
|
-// } from '@/api/trigger'
|
|
|
|
|
import addpersonnellog from './components/personneladd'
|
|
import addpersonnellog from './components/personneladd'
|
|
|
import addpersonneleditlog from './components/personneledit'
|
|
import addpersonneleditlog from './components/personneledit'
|
|
|
export default {
|
|
export default {
|
|
@@ -219,20 +149,6 @@ export default {
|
|
|
Code: '',
|
|
Code: '',
|
|
|
classification: ''
|
|
classification: ''
|
|
|
},
|
|
},
|
|
|
- statelist: [
|
|
|
|
|
- {
|
|
|
|
|
- stateName: '正常',
|
|
|
|
|
- Id: 1
|
|
|
|
|
- },
|
|
|
|
|
- {
|
|
|
|
|
- stateName: '维修',
|
|
|
|
|
- Id: 2
|
|
|
|
|
- },
|
|
|
|
|
- {
|
|
|
|
|
- stateName: '闲置',
|
|
|
|
|
- Id: 3
|
|
|
|
|
- }
|
|
|
|
|
- ],
|
|
|
|
|
// 列表排序
|
|
// 列表排序
|
|
|
Column: {
|
|
Column: {
|
|
|
Order: '',
|
|
Order: '',
|
|
@@ -262,32 +178,21 @@ export default {
|
|
|
this.$refs.addpersonnel.dialogvisible = false
|
|
this.$refs.addpersonnel.dialogvisible = false
|
|
|
this.currpage = 1
|
|
this.currpage = 1
|
|
|
this.initDatas()
|
|
this.initDatas()
|
|
|
- // this.getclassificationlist()
|
|
|
|
|
},
|
|
},
|
|
|
// 编辑 返回页面
|
|
// 编辑 返回页面
|
|
|
handleCloseEdit () {
|
|
handleCloseEdit () {
|
|
|
this.$refs.personneledit.dialogvisible = false
|
|
this.$refs.personneledit.dialogvisible = false
|
|
|
- // this.getclassificationlist()
|
|
|
|
|
this.initDatas()
|
|
this.initDatas()
|
|
|
},
|
|
},
|
|
|
// 初始化列表数据
|
|
// 初始化列表数据
|
|
|
initDatas () {
|
|
initDatas () {
|
|
|
let _this = this
|
|
let _this = this
|
|
|
- let CalibrationTime = []
|
|
|
|
|
if (!_this.CalibrationTime) {
|
|
if (!_this.CalibrationTime) {
|
|
|
_this.CalibrationTime = []
|
|
_this.CalibrationTime = []
|
|
|
}
|
|
}
|
|
|
- // 解析时间
|
|
|
|
|
- // if (_this.CalibrationTime.length === 2) {
|
|
|
|
|
- // _this.CalibrationTime[1].setHours(23)
|
|
|
|
|
- // _this.CalibrationTime[1].setMinutes(59)
|
|
|
|
|
- // _this.CalibrationTime[1].setSeconds(59)
|
|
|
|
|
- // CalibrationTime.push(_this.formatDateTime(_this.CalibrationTime[0]))
|
|
|
|
|
- // CalibrationTime.push(_this.formatDateTime(_this.CalibrationTime[1]))
|
|
|
|
|
- // }
|
|
|
|
|
let params = {
|
|
let params = {
|
|
|
- _currentPage: this.currpage,
|
|
|
|
|
- _size: this.size,
|
|
|
|
|
|
|
+ current: this.currpage,
|
|
|
|
|
+ size: this.size,
|
|
|
Code: this.search.Code,
|
|
Code: this.search.Code,
|
|
|
Classification: this.search.classification,
|
|
Classification: this.search.classification,
|
|
|
Name: this.search.Name,
|
|
Name: this.search.Name,
|
|
@@ -297,44 +202,7 @@ export default {
|
|
|
PersonnelApi.getAllPersonnel(params)
|
|
PersonnelApi.getAllPersonnel(params)
|
|
|
.then(res => {
|
|
.then(res => {
|
|
|
_this.activities = res.records
|
|
_this.activities = res.records
|
|
|
- // for (let i = 0; i < _this.activities.length; i++) {
|
|
|
|
|
- // var addTime = _this.addDate(_this.activities[i].CalibrationTime, 2)
|
|
|
|
|
- // var tdate = 0
|
|
|
|
|
- // if (_this.activities[i].CalibrationDeadlineType === 1) {
|
|
|
|
|
- // addTime = _this.addDate(_this.activities[i].CalibrationTime, _this.activities[i].CalibrationDeadline)
|
|
|
|
|
- // tdate = _this.count(new Date(addTime))
|
|
|
|
|
- // _this.activities[i].CalibrationDeadlineType = '天'
|
|
|
|
|
- // } else if (_this.activities[i].CalibrationDeadlineType === 2) {
|
|
|
|
|
- // addTime = _this.addDate(_this.activities[i].CalibrationTime, (_this.activities[i].CalibrationDeadline) * 7)
|
|
|
|
|
- // tdate = _this.count(new Date(addTime))
|
|
|
|
|
- // _this.activities[i].CalibrationDeadlineType = '周'
|
|
|
|
|
- // } else if (_this.activities[i].CalibrationDeadlineType === 3) {
|
|
|
|
|
- // addTime = _this.addDate(_this.activities[i].CalibrationTime, (_this.activities[i].CalibrationDeadline) * 30)
|
|
|
|
|
- // tdate = _this.count(new Date(addTime))
|
|
|
|
|
- // _this.activities[i].CalibrationDeadlineType = '月'
|
|
|
|
|
- // } else if (_this.activities[i].CalibrationDeadlineType === 4) {
|
|
|
|
|
- // addTime = _this.addDate(_this.activities[i].CalibrationTime, (_this.activities[i].CalibrationDeadline) * 365)
|
|
|
|
|
- // tdate = _this.count(new Date(addTime))
|
|
|
|
|
- // _this.activities[i].CalibrationDeadlineType = '年'
|
|
|
|
|
- // }
|
|
|
|
|
- // if (tdate >= 30) {
|
|
|
|
|
- // _this.activities[i].tYPE = 1
|
|
|
|
|
- // } else if (tdate < 30 && tdate >= 0) {
|
|
|
|
|
- // _this.activities[i].tYPE = 2
|
|
|
|
|
- // } else if (tdate < 0) {
|
|
|
|
|
- // _this.activities[i].tYPE = 3
|
|
|
|
|
- // }
|
|
|
|
|
- // }
|
|
|
|
|
-
|
|
|
|
|
- // for (let i = 0; i < _this.activities.length; i++) {
|
|
|
|
|
- // // _this.activities[i].CalibrationDeadline = _this.activities[i].CalibrationDeadline + ''
|
|
|
|
|
- // _this.activities[i].CalibrationDeadline = _this.activities[i].CalibrationDeadline + '' + _this.activities[i].CalibrationDeadlineType
|
|
|
|
|
- // }
|
|
|
|
|
-
|
|
|
|
|
- // _this.totalsize = response.info.currentItemCount
|
|
|
|
|
- // })
|
|
|
|
|
- // .catch(function (error) {
|
|
|
|
|
- // console.log(error)
|
|
|
|
|
|
|
+ _this.totalsize = res.total
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|
|
|
handleSizeChange (val) {
|
|
handleSizeChange (val) {
|