|  | @@ -45,6 +45,7 @@
 | 
	
		
			
				|  |  |              <el-button v-if="isBasicAdd" class="filter-item" type="primary" icon="el-icon-edit" @click="form_add">新增</el-button>
 | 
	
		
			
				|  |  |              <el-button v-if="isBasicTemplate" v-waves class="filter-item" type="info" icon="el-icon-tickets" @click="handleDownloadTemp">模板</el-button>
 | 
	
		
			
				|  |  |              <el-button v-if="isDisable" v-waves class="filter-item" type="danger" icon="el-icon-remove-outline"  @click="handleBatchDisable">批量禁用</el-button>
 | 
	
		
			
				|  |  | +            <el-button v-if="isEnable" v-waves class="filter-item" type="danger" icon="el-icon-success"  @click="handleBatchEnable">批量启用</el-button>
 | 
	
		
			
				|  |  |              <el-upload style="display: inline-block;" :headers="headers" :data="uploadData" :action="uploadExcelUrl" :show-file-list="false" :before-upload="beforeImportExcel" :on-success="handleImportExcelSuccess">
 | 
	
		
			
				|  |  |                <el-button v-if="isBasicImport" v-waves class="filter-item" type="warning" icon="el-icon-download" @click="form_search">导入</el-button>
 | 
	
		
			
				|  |  |              </el-upload>
 | 
	
	
		
			
				|  | @@ -1014,7 +1015,7 @@ export default {
 | 
	
		
			
				|  |  |      handleBatchDisable(){
 | 
	
		
			
				|  |  |        if(this.multipleSelection.length > 0){
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | -    
 | 
	
		
			
				|  |  | +
 | 
	
		
			
				|  |  |        this.$confirm('是否确定批量禁用?', '提示', {
 | 
	
		
			
				|  |  |            confirmButtonText: '确定',
 | 
	
		
			
				|  |  |            cancelButtonText: '取消',
 | 
	
	
		
			
				|  | @@ -1022,6 +1023,7 @@ export default {
 | 
	
		
			
				|  |  |          }).then(() => {
 | 
	
		
			
				|  |  |            this.multipleSelection.forEach(row => {
 | 
	
		
			
				|  |  |              console.log("批量禁用",row)
 | 
	
		
			
				|  |  | +            this.requestParam = {}
 | 
	
		
			
				|  |  |              this.requestParam.name = 'updatepartsEnable'
 | 
	
		
			
				|  |  |              this.requestParam.parammaps = {}
 | 
	
		
			
				|  |  |              this.requestParam.parammaps.id = row.id
 | 
	
	
		
			
				|  | @@ -1042,6 +1044,36 @@ export default {
 | 
	
		
			
				|  |  |          this.$notify({ title: '提示', message: '请勾选禁用备件', type: 'error', duration: 2000 })
 | 
	
		
			
				|  |  |        }
 | 
	
		
			
				|  |  |      },
 | 
	
		
			
				|  |  | +    handleBatchEnable(){
 | 
	
		
			
				|  |  | +      if(this.multipleSelection.length > 0){
 | 
	
		
			
				|  |  | +      this.$confirm('是否确定批量启用?', '提示', {
 | 
	
		
			
				|  |  | +          confirmButtonText: '确定',
 | 
	
		
			
				|  |  | +          cancelButtonText: '取消',
 | 
	
		
			
				|  |  | +          type: 'warning'
 | 
	
		
			
				|  |  | +        }).then(() => {
 | 
	
		
			
				|  |  | +          this.multipleSelection.forEach(row => {
 | 
	
		
			
				|  |  | +            console.log("批量启用",row)
 | 
	
		
			
				|  |  | +            this.requestParam = {}
 | 
	
		
			
				|  |  | +            this.requestParam.name = 'updatepartsEnable'
 | 
	
		
			
				|  |  | +            this.requestParam.parammaps = {}
 | 
	
		
			
				|  |  | +            this.requestParam.parammaps.id = row.id
 | 
	
		
			
				|  |  | +            this.requestParam.parammaps.enable = 1
 | 
	
		
			
				|  |  | +            PostDataByName(this.requestParam).then(() => {
 | 
	
		
			
				|  |  | +              this.$notify({ title: '成功', message: '启用成功', type: 'success', duration: 2000 })
 | 
	
		
			
				|  |  | +            })
 | 
	
		
			
				|  |  | +          });
 | 
	
		
			
				|  |  | +          this.getList()
 | 
	
		
			
				|  |  | +          this.getListSH()
 | 
	
		
			
				|  |  | +        }).catch(() => {
 | 
	
		
			
				|  |  | +          this.$message({
 | 
	
		
			
				|  |  | +            type: 'info',
 | 
	
		
			
				|  |  | +            message: '已取消批量启用'
 | 
	
		
			
				|  |  | +          });          
 | 
	
		
			
				|  |  | +        });
 | 
	
		
			
				|  |  | +      }else{
 | 
	
		
			
				|  |  | +        this.$notify({ title: '提示', message: '请勾选启用备件', type: 'error', duration: 2000 })
 | 
	
		
			
				|  |  | +      }
 | 
	
		
			
				|  |  | +    },
 | 
	
		
			
				|  |  |      getDownList() {
 | 
	
		
			
				|  |  |        GetDataByNames(this.requestParams).then(response => {
 | 
	
		
			
				|  |  |          this.units = response.data.getDictByName.list
 |