|
|
@@ -0,0 +1,555 @@
|
|
|
+<template>
|
|
|
+ <div v-loading="downloading" element-loading-text="数据拼命准备中,请稍候。。。">
|
|
|
+ <el-breadcrumb class="heading">
|
|
|
+ <el-breadcrumb-item :to="{ path: '/' }">平台首页</el-breadcrumb-item>
|
|
|
+ <el-breadcrumb-item>样品类型</el-breadcrumb-item>
|
|
|
+ </el-breadcrumb>
|
|
|
+ <el-card class="box-card" style="height: calc(100vh - 115px);">
|
|
|
+ <div slot="header">
|
|
|
+ <span>
|
|
|
+ <i class="icon icon-table2">样品类型</i>
|
|
|
+ </span>
|
|
|
+ <span style="float: right;">
|
|
|
+ <el-button type="primary" size="mini" style="margin-left:10px; margin-top: -4px;" @click="opendatadialog(1,null,-1)">新增样品类型</el-button>
|
|
|
+ </span>
|
|
|
+ <el-form ref="form" :inline="true" style="float: right; margin-top: -10px;">
|
|
|
+ <el-form-item label="样品名称">
|
|
|
+ <el-input size="mini" style="width: 165px;" v-model="keyword" placeholder="请输入样品名称" clearable></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item>
|
|
|
+ <el-button type="primary" size="mini" style="margin-left:10px; margin-top: -4px;" @click="seachdata">查询</el-button>
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+ </div>
|
|
|
+ <el-row :gutter="20">
|
|
|
+ <el-col :span="6">
|
|
|
+ <el-tabs tab-position="left" style="height: calc(100vh - 245px); margin-top: 5px; overflow: auto;">
|
|
|
+ <el-tab-pane label="样品类型">
|
|
|
+ <el-tree highlight-current :expand-on-click-node="true" node-key="id" :data="typeTreeList" :props="orgtreeprops"
|
|
|
+ :default-expanded-keys="userdepartment" @node-click="orgtreeNodeClick" ref="orgmanagetree">
|
|
|
+ </el-tree>
|
|
|
+ </el-tab-pane>
|
|
|
+ </el-tabs>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="18">
|
|
|
+ <el-table :data="tableList" border height="calc(100vh - 243px)">
|
|
|
+ <el-table-column label="操作" width="70" align="center" fixed>
|
|
|
+ <template slot-scope="scope">
|
|
|
+ <template v-if="scope.row.Parentid !== 0">
|
|
|
+ <el-button size="small" type="text" @click="opendatadialog(2,scope.row,scope.$index)" icon="el-icon-edit"
|
|
|
+ title="编辑"></el-button>
|
|
|
+ <el-button size="small" type="text" @click="delSampleType(scope.row)" icon="el-icon-delete" title="删除"
|
|
|
+ style="margin-left: 3px"></el-button>
|
|
|
+ </template>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
+ <el-table-column prop="FullName" sortable min-width="100" label="样品名称" align="center" show-overflow-tooltip></el-table-column>
|
|
|
+ <el-table-column prop="Parentname" sortable min-width="100" label="样品类型" align="center"
|
|
|
+ show-overflow-tooltip></el-table-column>
|
|
|
+ <el-table-column prop="Description" sortable min-width="100" label="备注" align="center"
|
|
|
+ show-overflow-tooltip></el-table-column>
|
|
|
+ </el-table>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+ <!--分页-->
|
|
|
+ <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="sampleTitle" :visible.sync="sampleTypeShow" size="small">
|
|
|
+ <el-form :model="sampleForm" :rules="rulesorganize" ref="sampleForm" label-width="120px">
|
|
|
+ <el-row>
|
|
|
+ <el-col :span="11">
|
|
|
+ <el-form-item label="检测报告">
|
|
|
+ <el-select ref="refProjectTypeId" v-model="sampleForm.ProjectTypeId" @change="chooseSampleType" clearable
|
|
|
+ filterable placeholder="请选择">
|
|
|
+ <el-option v-for="item in projectTypeList" :key="item.value" :label="item.FullName" :value="item.Id"></el-option>
|
|
|
+ </el-select>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="11" v-if="parent_flag == 1">
|
|
|
+ <el-form-item label="样品类型">
|
|
|
+ <el-cascader :options="typeTreeList" :props="orgtreeprops" v-model="selectedorg" @change="getProject"
|
|
|
+ change-on-select :show-all-levels="false" placeholder="请选择组织" clearable filterable></el-cascader>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="22">
|
|
|
+ <el-form-item :label="(parent_flag =='1')?'样品名称':'样品类型'" prop="FullName">
|
|
|
+ <el-input v-model="sampleForm.FullName"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="5">
|
|
|
+ <el-form-item label="是否交接">
|
|
|
+ <el-checkbox v-model="sampleForm.ISdeliver" style="margin-left:20px"></el-checkbox>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="6">
|
|
|
+ <el-form-item label="是否制备">
|
|
|
+ <el-checkbox v-model="sampleForm.ISprepare" style="margin-left:20px"></el-checkbox>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="11" v-if="sampleForm.ISprepare">
|
|
|
+ <el-form-item label="制备份数">
|
|
|
+ <el-input v-model="sampleForm.PrepareNum"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="11">
|
|
|
+ <el-form-item label="是否留样">
|
|
|
+ <el-checkbox v-model="sampleForm.ISreveive" style="margin-left:20px"></el-checkbox>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="11" v-if="sampleForm.ISreveive">
|
|
|
+ <el-form-item label="留样数量">
|
|
|
+ <el-input v-model="sampleForm.ReveiveNum"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="22">
|
|
|
+ <el-form-item label="检测项目">
|
|
|
+ <div style="border: 1px solid rgb(204, 204, 204); overflow: auto; height: 120px;" label-width="130px">
|
|
|
+ <el-checkbox-group v-model="selectTestDetail">
|
|
|
+ <el-checkbox v-for="v in sampleTypeList" @change="CheckTestDetail" :label="v.Id+','+v.FullName" style="margin-left:8px;margin-top:5px" :key="v">{{v.FullName}}</el-checkbox>
|
|
|
+ </el-checkbox-group>
|
|
|
+ </div>
|
|
|
+ <el-checkbox v-model="checkAll" :indeterminate="isIndeterminate" @change="CheckTestDetailAll">全选</el-checkbox>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="22">
|
|
|
+ <el-form-item label="描述" prop="Sender">
|
|
|
+ <el-input type="textarea" v-model="sampleForm.description"></el-input>
|
|
|
+ </el-form-item>
|
|
|
+ </el-col>
|
|
|
+ </el-row>
|
|
|
+ </el-form>
|
|
|
+ <div slot="footer" class="dialog-footer">
|
|
|
+ <el-button @click="sampleTypeShow = false">取 消</el-button>
|
|
|
+ <el-button type="primary" @click="addSampleType('sampleForm')">确 定</el-button>
|
|
|
+ </div>
|
|
|
+ </el-dialog>
|
|
|
+
|
|
|
+ </div>
|
|
|
+</template>
|
|
|
+
|
|
|
+<script>
|
|
|
+ import {
|
|
|
+ mapGetters
|
|
|
+ } from 'vuex'
|
|
|
+ export default {
|
|
|
+ name: 'organize',
|
|
|
+
|
|
|
+ data() {
|
|
|
+ return {
|
|
|
+ downloading: true,
|
|
|
+ currentItemCount: 0,
|
|
|
+ currentPage: 1,
|
|
|
+ size: 10,
|
|
|
+ tableList: [], // 处理分页用
|
|
|
+ keyword: '',
|
|
|
+ sampleTypeShow: false,
|
|
|
+ sampleTitle: '',
|
|
|
+ testTypeList: [],
|
|
|
+ projectTypeList: [], //检验项目大项
|
|
|
+ sampleTypeList: [], //检测项目 小项
|
|
|
+ selectTestDetail: [],
|
|
|
+ sampleForm: {
|
|
|
+ IsInnerOrganize: 1,
|
|
|
+ ProjectTypeId: '',
|
|
|
+ ProjectType: '',
|
|
|
+ TestDetailId: '',
|
|
|
+ ParentId: 0,
|
|
|
+ FullName: '',
|
|
|
+ FullNameOzId: '',
|
|
|
+ description: '',
|
|
|
+ id: 0,
|
|
|
+ ISdeliver: false,
|
|
|
+ ISprepare: false,
|
|
|
+ PrepareNum: 0,
|
|
|
+ ISreveive: false,
|
|
|
+ ReveiveNum: 0.0
|
|
|
+ },
|
|
|
+ rulesorganize: {
|
|
|
+ FullName: [{
|
|
|
+ required: true,
|
|
|
+ message: '请输入样品类型',
|
|
|
+ trigger: 'blur'
|
|
|
+ }]
|
|
|
+ },
|
|
|
+ operatingitem: 0,
|
|
|
+ permissiondialogtitle: '',
|
|
|
+ permissiondatadialogVisible: false,
|
|
|
+ binddevices: [],
|
|
|
+ devices: [],
|
|
|
+ devicesallid: [],
|
|
|
+ isIndeterminate: true,
|
|
|
+ checkAll: false,
|
|
|
+ update: true,
|
|
|
+ childArr: [],
|
|
|
+ parentArr: [],
|
|
|
+ // 级联选项
|
|
|
+ options: [],
|
|
|
+ currentOrgan: '请选择套餐名称',
|
|
|
+ havechild: false,
|
|
|
+ // 数据传输
|
|
|
+ currId: 0,
|
|
|
+ currOrganName: '',
|
|
|
+ typeTreeList: [],
|
|
|
+ orgtreeprops: {
|
|
|
+ value: 'id',
|
|
|
+ label: 'FullName',
|
|
|
+ children: 'children'
|
|
|
+ },
|
|
|
+ selectedorg: [],
|
|
|
+ userdepartment: [],
|
|
|
+ parent_flag: 1
|
|
|
+ }
|
|
|
+ },
|
|
|
+
|
|
|
+ created() {
|
|
|
+ this.initData()
|
|
|
+ this.getProjectType()
|
|
|
+ this.gettreelist()
|
|
|
+ },
|
|
|
+ updated() {},
|
|
|
+ watch: {},
|
|
|
+ computed: mapGetters({
|
|
|
+ authUser: 'authUser'
|
|
|
+ }),
|
|
|
+ methods: {
|
|
|
+ initData() {
|
|
|
+ let _this = this
|
|
|
+ // paginate
|
|
|
+ let params = {
|
|
|
+ _currentPage: this.currentPage,
|
|
|
+ _size: this.size,
|
|
|
+ keyword: this.keyword,
|
|
|
+ parentId: this.parentId
|
|
|
+ }
|
|
|
+ // request
|
|
|
+ this.$axios.get('/limsampletype/smpletypelistbyorg', {
|
|
|
+ params
|
|
|
+ })
|
|
|
+ .then(res => {
|
|
|
+ // response
|
|
|
+ _this.tableList = res.data.items
|
|
|
+ _this.currentItemCount = res.data.currentItemCount
|
|
|
+ _this.downloading = false
|
|
|
+ })
|
|
|
+ .catch(err => {
|
|
|
+ // handle error
|
|
|
+ console.error(err)
|
|
|
+ })
|
|
|
+ },
|
|
|
+
|
|
|
+ gettreelist() {
|
|
|
+ let _this = this
|
|
|
+ _this.$axios.get('/limsampletype/sampletypetreebyorg', {})
|
|
|
+ .then(res => {
|
|
|
+ _this.typeTreeList = window.toolfun_gettreejson(res.data.items, 'Id', 'ParentId',
|
|
|
+ 'Id,FullName,ProjectType,ProjectTypeId')
|
|
|
+ })
|
|
|
+ .catch(err => {
|
|
|
+ // handle error
|
|
|
+ console.error(err)
|
|
|
+ })
|
|
|
+ },
|
|
|
+
|
|
|
+ getProject() {
|
|
|
+ let _this = this
|
|
|
+ for (var i = 0; i < _this.typeTreeList.length; i++) {
|
|
|
+ if (_this.selectedorg == _this.typeTreeList[i].id) {
|
|
|
+ _this.sampleForm.ProjectTypeId = _this.typeTreeList[i].ProjectTypeId
|
|
|
+ _this.sampleForm.ProjectType = _this.typeTreeList[i].ProjectType
|
|
|
+ _this.chooseSampleType()
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+
|
|
|
+ addSampleType(formName) {
|
|
|
+ let _this = this
|
|
|
+ this.$refs[formName].validate((valid) => {
|
|
|
+ if (valid) {
|
|
|
+ _this.sampleForm.ProjectTypeId = parseInt(_this.sampleForm.ProjectTypeId)
|
|
|
+ _this.sampleForm.ProjectType = _this.$refs.refProjectTypeId.selectedLabel + ''
|
|
|
+ _this.sampleForm.ParentId = parseInt(_this.selectedorg[_this.selectedorg.length - 1])
|
|
|
+ if (_this.sampleForm.ISdeliver) {
|
|
|
+ _this.sampleForm.ISdeliver = 1
|
|
|
+ } else if (!_this.sampleForm.ISdeliver) {
|
|
|
+ _this.sampleForm.ISdeliver = 2
|
|
|
+ }
|
|
|
+ if (_this.sampleForm.ISprepare) {
|
|
|
+ _this.sampleForm.ISprepare = 1
|
|
|
+ _this.sampleForm.PrepareNum = parseInt(_this.sampleForm.PrepareNum)
|
|
|
+ } else if (!_this.sampleForm.ISprepare) {
|
|
|
+ _this.sampleForm.ISprepare = 2
|
|
|
+ }
|
|
|
+ if (_this.sampleForm.ISreveive) {
|
|
|
+ _this.sampleForm.ISreveive = 1
|
|
|
+ _this.sampleForm.ReveiveNum = parseFloat(_this.sampleForm.ReveiveNum)
|
|
|
+ } else if (!_this.sampleForm.ISreveive) {
|
|
|
+ _this.sampleForm.ISreveive = 2
|
|
|
+ }
|
|
|
+ if (_this.sampleForm.ParentId === _this.sampleForm.id) {
|
|
|
+ _this.$message({
|
|
|
+ type: 'warning',
|
|
|
+ message: '上一级组织不能为自身数据!'
|
|
|
+ })
|
|
|
+ return
|
|
|
+ }
|
|
|
+ if (_this.operatingitem === 1) {
|
|
|
+ _this.sampleForm.IsInnerOrganize = 1
|
|
|
+ _this.$axios.post('limsampletype/sampletypeadd/', _this.sampleForm)
|
|
|
+ .then(res => {
|
|
|
+ // response
|
|
|
+ if (res.data.code === 0) {
|
|
|
+ _this.$message({
|
|
|
+ type: 'success',
|
|
|
+ message: res.data.message
|
|
|
+ })
|
|
|
+ _this.sampleTypeShow = false
|
|
|
+ // 重新加载tree数据
|
|
|
+ _this.initData()
|
|
|
+ _this.gettreelist()
|
|
|
+ } else {
|
|
|
+ _this.$message({
|
|
|
+ type: 'warning',
|
|
|
+ message: res.data.message
|
|
|
+ })
|
|
|
+ }
|
|
|
+ })
|
|
|
+ .catch(err => {
|
|
|
+ // handle error
|
|
|
+ console.error(err)
|
|
|
+ })
|
|
|
+ } else if (_this.operatingitem === 2) {
|
|
|
+ _this.$axios.put('limsampletype/sampletypedit/' + _this.sampleForm.id, _this.sampleForm)
|
|
|
+ .then(res => {
|
|
|
+ // response
|
|
|
+ if (res.data.code === 0) {
|
|
|
+ _this.$message({
|
|
|
+ type: 'success',
|
|
|
+ message: res.data.message
|
|
|
+ })
|
|
|
+ _this.sampleTypeShow = false
|
|
|
+ // 更新界面
|
|
|
+ _this.initData()
|
|
|
+ _this.gettreelist()
|
|
|
+ } else {
|
|
|
+ _this.$message({
|
|
|
+ type: 'warning',
|
|
|
+ message: res.data.message
|
|
|
+ })
|
|
|
+ }
|
|
|
+ })
|
|
|
+ .catch(() => {})
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ return false
|
|
|
+ }
|
|
|
+ })
|
|
|
+ },
|
|
|
+
|
|
|
+ opendatadialog(item, v, index) {
|
|
|
+ this.operatingitem = item
|
|
|
+ this.parent_flag = 1
|
|
|
+ this.clearsampleForm()
|
|
|
+ this.sampleTypeShow = true
|
|
|
+ let _this = this
|
|
|
+ if (item === 1) {
|
|
|
+ _this.sampleTitle = `新增样品类型`
|
|
|
+ // 选中状态
|
|
|
+ _this.selectedorg = []
|
|
|
+ } else if (item === 2) {
|
|
|
+ _this.sampleTitle = `编辑样品类型(${v.FullName})`
|
|
|
+ _this.sampleForm.id = v.Id
|
|
|
+ _this.sampleForm.ProjectTypeId = v.ProjectTypeId
|
|
|
+ _this.sampleForm.ProjectType = v.ProjectType
|
|
|
+ //_this.sampleForm.ParentId = v.ParentId
|
|
|
+ if (v.ParentId && v.ParentId > 0) {
|
|
|
+ _this.sampleForm.ParentId = v.ParentId
|
|
|
+ _this.sampleForm.ParentName = v.Parentname
|
|
|
+ } else {
|
|
|
+ _this.parent_flag = 2
|
|
|
+ }
|
|
|
+ _this.sampleForm.FullName = v.FullName
|
|
|
+ _this.sampleForm.description = v.Description
|
|
|
+ //处理checkbox
|
|
|
+ if (v.ISdeliver == 1) {
|
|
|
+ _this.sampleForm.ISdeliver = true
|
|
|
+ } else if (v.ISdeliver == 2) {
|
|
|
+ _this.sampleForm.ISdeliver = false
|
|
|
+ }
|
|
|
+ if (v.ISprepare == 1) {
|
|
|
+ _this.sampleForm.ISprepare = true
|
|
|
+ } else if (v.ISprepare == 2) {
|
|
|
+ _this.sampleForm.ISprepare = false
|
|
|
+ }
|
|
|
+ if (v.ISreveive == 1) {
|
|
|
+ _this.sampleForm.ISreveive = true
|
|
|
+ } else if (v.ISreveive == 2) {
|
|
|
+ _this.sampleForm.ISreveive = false
|
|
|
+ }
|
|
|
+ _this.sampleForm.ReveiveNum = v.ReveiveNum
|
|
|
+ _this.sampleForm.PrepareNum = v.PrepareNum
|
|
|
+ //处理样品类型
|
|
|
+ _this.selectedorg = []
|
|
|
+ _this.selectedorg.push(v.ParentId)
|
|
|
+ //处理检测项目
|
|
|
+ _this.sampleForm.TestDetailId = v.TestDetailId
|
|
|
+ _this.selectTestDetail = _this.sampleForm.TestDetailId.split('/')
|
|
|
+ _this.chooseSampleType()
|
|
|
+ }
|
|
|
+ },
|
|
|
+
|
|
|
+ delSampleType(val) {
|
|
|
+ let _this = this
|
|
|
+ _this.$confirm("此操作将永久删除该数据, 是否继续?", "提示", {
|
|
|
+ confirmButtonText: "确定",
|
|
|
+ cancelButtonText: "取消",
|
|
|
+ type: "warning"
|
|
|
+ })
|
|
|
+ .then(() => {
|
|
|
+ _this.$axios
|
|
|
+ .delete("limsampletype/deletesampletype/" + val.Id, {})
|
|
|
+ .then(function (response) {
|
|
|
+ // response
|
|
|
+ if (response.data.code === 0) {
|
|
|
+ _this.$message({
|
|
|
+ type: "success",
|
|
|
+ message: response.data.message
|
|
|
+ });
|
|
|
+ // 更新界面
|
|
|
+ _this.initData()
|
|
|
+ } else {
|
|
|
+ _this.$message({
|
|
|
+ type: "warning",
|
|
|
+ message: response.data.message
|
|
|
+ });
|
|
|
+ }
|
|
|
+ })
|
|
|
+ .catch(function (error) {
|
|
|
+ console.log(error)
|
|
|
+ });
|
|
|
+ })
|
|
|
+ .catch(() => {});
|
|
|
+ },
|
|
|
+
|
|
|
+ chooseSampleType() {
|
|
|
+ this.sampleTypeList = []
|
|
|
+ this.getSampleType()
|
|
|
+ },
|
|
|
+
|
|
|
+ //检验报告
|
|
|
+ getProjectType() {
|
|
|
+ let _this = this
|
|
|
+ _this.$axios.get('/testtype/testypetreebyorg', {})
|
|
|
+ .then(res => {
|
|
|
+ _this.testTypeList = res.data.items
|
|
|
+ for (var i = 0; i < _this.testTypeList.length; i++) {
|
|
|
+ if (_this.testTypeList[i].ParentId == 0) {
|
|
|
+ _this.projectTypeList.push(_this.testTypeList[i])
|
|
|
+ }
|
|
|
+ }
|
|
|
+ })
|
|
|
+ .catch(err => {
|
|
|
+ // handle error
|
|
|
+ console.error(err)
|
|
|
+ })
|
|
|
+ },
|
|
|
+
|
|
|
+ //检测小项目
|
|
|
+ getSampleType() {
|
|
|
+ let _this = this
|
|
|
+ _this.sampleTypeList = []
|
|
|
+ for (var i = 0; i < _this.testTypeList.length; i++) {
|
|
|
+ if (_this.testTypeList[i].ParentId == _this.sampleForm.ProjectTypeId) {
|
|
|
+ _this.sampleTypeList.push(_this.testTypeList[i])
|
|
|
+ }
|
|
|
+ }
|
|
|
+ this.isIndeterminate = true
|
|
|
+ },
|
|
|
+
|
|
|
+ CheckTestDetail() {
|
|
|
+ let checkedCount = this.selectTestDetail.length
|
|
|
+ this.checkAll = checkedCount === this.sampleTypeList.length
|
|
|
+ this.isIndeterminate = checkedCount > 0 && checkedCount < this.sampleTypeList.length
|
|
|
+ this.chooseTestDetail()
|
|
|
+ },
|
|
|
+ CheckTestDetailAll(val) {
|
|
|
+ let _this = this
|
|
|
+ _this.selectTestDetail = []
|
|
|
+ if (val) {
|
|
|
+ _this.sampleTypeList.forEach((item, k) => {
|
|
|
+ _this.selectTestDetail.push(item.Id + ',' + item.FullName)
|
|
|
+ })
|
|
|
+ _this.sampleForm.TestDetailId = _this.selectTestDetail.join('/')
|
|
|
+ _this.isIndeterminate = false
|
|
|
+ }
|
|
|
+ },
|
|
|
+
|
|
|
+ chooseTestDetail() {
|
|
|
+ let _this = this
|
|
|
+ _this.sampleForm.TestDetailId = _this.selectTestDetail.join('/')
|
|
|
+ },
|
|
|
+
|
|
|
+ orgtreeNodeClick(data) {
|
|
|
+ this.parentId = data.id + ''
|
|
|
+ this.initData()
|
|
|
+ this.currentPage = 1
|
|
|
+ },
|
|
|
+ seachdata() {
|
|
|
+ this.currentPage = 1
|
|
|
+ this.initData()
|
|
|
+ },
|
|
|
+
|
|
|
+ clearsampleForm() {
|
|
|
+ this.sampleForm = {
|
|
|
+ id: 0,
|
|
|
+ FullName: '',
|
|
|
+ ParentId: 0,
|
|
|
+ ProjectType: '',
|
|
|
+ ProjectTypeId: '',
|
|
|
+ TestDetailId: '',
|
|
|
+ description: '',
|
|
|
+ ISdeliver: false,
|
|
|
+ ISprepare: false,
|
|
|
+ PrepareNum: '',
|
|
|
+ ISreveive: false,
|
|
|
+ ReveiveNum: 0.0,
|
|
|
+ }
|
|
|
+ },
|
|
|
+
|
|
|
+ handleSizeChange(value) {
|
|
|
+ this.size = value
|
|
|
+ this.currentPage = 1
|
|
|
+ this.initData()
|
|
|
+ },
|
|
|
+ handleCurrentChange(value) {
|
|
|
+ this.currentPage = value
|
|
|
+ this.initData()
|
|
|
+ },
|
|
|
+ jstimehandle(val) {
|
|
|
+ val = val.replace('T', ' ')
|
|
|
+ return val.substring(0, 19)
|
|
|
+ },
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+</script>
|
|
|
+
|
|
|
+<style lang="scss">
|
|
|
+ .el-pagination {
|
|
|
+ margin: 1rem 0 2rem;
|
|
|
+ text-align: right;
|
|
|
+ }
|
|
|
+
|
|
|
+ .triggerone {
|
|
|
+ font-size: 13px;
|
|
|
+ margin-left: 80px;
|
|
|
+ }
|
|
|
+
|
|
|
+ .plab {
|
|
|
+ font-size: 13px;
|
|
|
+ color: #999;
|
|
|
+ }
|
|
|
+
|
|
|
+</style>
|