347617796@qq.com vor 4 Jahren
Ursprung
Commit
194815cae1

+ 15 - 12
src/api/axios.js

@@ -16,22 +16,18 @@ const service = axios.create({
 		return qs.stringify(data)
 	}]
 })
-
 service.interceptors.request.use(
 	config => {
 		if (getToken()) {
-			// config.headers['A-Token'] = getToken()
-			config.headers['A-Token'] = ' eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwczpcL1wvdGVzdC1kaW5nLmcxMDcuY29tXC9hcGlcL2RpbmdcL2xvZ2luIiwiaWF0IjoxNjA1MjQ4MzM1LCJleHAiOjE2MDU4NDgzMzUsIm5iZiI6MTYwNTI0ODMzNSwianRpIjoiU29DNXFjZTY2aDhkbWdtaSIsInN1YiI6MTU5LCJwcnYiOiJjYTY0ODlkNTBmMjQwN2E2NzgzMGU4MDkwZDAxNDg4MzU2ODU5NjJiIiwicm9sZSI6ImVtcGxveWVlIn0.2Ayf0qYdg7cfpFSYGMFDxxE5ypkc5HwbM_QADleNik8'
-		}
-		if (config.url == '/api/integral/statistics/ranking' || config.url == '/api/integral/review/apply'|| config.url == '/api/rule/import') {
-		  config.headers['Accept'] = 'application/vnd.test.v2+json'
-		}
-		if (config.url == '/api/integral/statistics/prize/list'  || config.url =='/api/integral/performance/employee') {
-		  config.headers['Accept'] = 'application/vnd.test.v3+json'
-		}
-		if (config.url == '/api/integral/statistics/integral') {
-		  config.headers['Accept'] = 'application/json, text/plain, */*';
+			config.headers['A-Token'] = getToken()
+			// config.headers['A-Token'] = ' eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwczpcL1wvdGVzdC1kaW5nLmcxMDcuY29tXC9hcGlcL2RpbmdcL2xvZ2luIiwiaWF0IjoxNjA3NDA4OTYyLCJleHAiOjE2MDgwMDg5NjIsIm5iZiI6MTYwNzQwODk2MiwianRpIjoiS2pMd2hSSExtMTY0OTBpdiIsInN1YiI6MTU5LCJwcnYiOiJjYTY0ODlkNTBmMjQwN2E2NzgzMGU4MDkwZDAxNDg4MzU2ODU5NjJiIiwicm9sZSI6ImVtcGxveWVlIn0.NeaMkTIvr-EV9pQcXg3J_Q5kWl0wSJatwJVi_gkoXeo'
 		}
+		// if (config.url == '/api/integral/statistics/ranking' || config.url == '/api/integral/review/apply'|| config.url == '/api/rule/import') {
+		//   config.headers['Accept'] = 'application/vnd.test.v2+json'
+		// }
+		// if (config.url == '/api/integral/statistics/integral') {
+		//   config.headers['Accept'] = 'application/json, text/plain, */*';
+		// }
 		return config
 	},
 	error => {
@@ -66,6 +62,7 @@ service.interceptors.response.use(
 		}
 	},
 	error => {
+		// console.log(error)
 		if(error.message=='interrupt'){
 			// Message({
 			// 	message: '请勿频繁切换页面',
@@ -78,6 +75,12 @@ service.interceptors.response.use(
 				type: 'error',
 			})
 			return Promise.reject(error.message)
+		}else if(error.message=='timeout of 5000ms exceeded'){
+			Message({
+				message: '请求超时,请稍后再试',
+				type: 'error',
+			})
+			return Promise.reject(error.message)
 		}else{
 			Message({
 				message: error.message,

+ 7 - 0
src/assets/css/reset.css

@@ -245,3 +245,10 @@ table { border-collapse:collapse; border-spacing:0; }
 	text-align: center;
 }
 
+
+/* EL UI 重置 */
+
+.notifyBox{
+	width: auto !important;
+}
+

+ 1 - 0
src/index.vue

@@ -269,6 +269,7 @@ export default {
 }
 .upgrade {
 	margin-left: 10px;
+	margin-right: 10px;
 }
 ::v-deep .el-menu-item{
 	padding-right: 10px !important;

+ 16 - 3
src/main.js

@@ -34,14 +34,28 @@ Vue.prototype.$http= service;
 var CancelToken = axios.CancelToken;
 Vue.$httpRequestList=[];
 
-Vue.prototype.$axios = (type, url, data) => {
-	// console.log(url)
+Vue.prototype.$axios = (type, url, data,heaStr) => {
 	if(url!='/api/ding/login'&& url!='/api/integral/types'){
+	    var Accept='';
+		switch(heaStr){
+		   case 'v2':
+		     Accept='application/vnd.test.v2+json'
+		     break;
+		   case 'v3':
+		     Accept='application/vnd.test.v3+json'
+		     break;
+		   case 'v4':
+		     Accept='application/vnd.test.v4+json'
+		     break;
+		}
 		if(getToken()){
 			return new Promise((resolve, reject) => {   //封装ajax
 			    var aa = {
 			        method: type,
 			        url: url,
+					headers:{
+					  'Accept':Accept
+					},
 			        cancelToken: new CancelToken(c => {  //强行中断请求要用到的
 			            Vue.$httpRequestList.push(c);
 			        })
@@ -94,7 +108,6 @@ router.beforeEach((to, from, next) => {   //路由切换检测是否强行中断
     next();    
 });
 
-
 Vue.config.productionTip = false
 new Vue({
   router,

+ 1 - 1
src/views/ranking/custom_rank.vue

@@ -360,7 +360,7 @@ export default {
 					pt_id: 3,
 				}
 			}
-			this.$axios('get','/api/integral/statistics/ranking',data).then((res) => {
+			this.$axios('get','/api/integral/statistics/ranking',data,'v2').then((res) => {
 				if (res.data.code == 1) {
 						this.table_list = res.data.data.list
 						this.total = res.data.data.total

+ 2 - 1
src/views/ranking/deptRankSwiper.vue

@@ -64,7 +64,8 @@
         let data = this.formData
         delete data.type
 		var url=self.type == 1? '/api/integral/statistics/integral' : '/api/integral/statistics/ranking';
-        self.$axios('get',url,data).then((res) => {
+        var str=self.type == 1? 'plain':'v2'
+		self.$axios('get',url,data,str).then((res) => {
           if (res.data.code == 1) {
             self.lastTime = this.$moment().format('YYYY-MM-DD HH:mm:ss')
             self.list = res.data.data.list

+ 3 - 3
src/views/ranking/dept_rank.vue

@@ -132,7 +132,7 @@
 			</center>
 		</div>
 		<!-- 导出弹窗 -->
-		<el-dialog title="导出排名" :visible.sync="dialogVisible" width="730px" top="5%">
+		<el-dialog title="导出排名" :visible.sync="dialogVisible" width="730px" top="10%">
 			<span style="font-size:15px">系统将按以下已选条件导出对应的排名报表</span>
 			<el-form :inline="true">
 				<div class="picker_er">
@@ -189,7 +189,7 @@
 		</el-dialog>
 
 		<!-- 轮播弹窗 -->
-		<el-dialog title="轮播排名" :visible.sync="byRankingShow" width="500px" top="5%">
+		<el-dialog title="轮播排名" :visible.sync="byRankingShow" width="500px" top="10%">
 			<div>
 				<el-form :inline="true" ref="byRankingData" :model="byRankingData" :rules="byRankingDataRules" label-width="90px">
 					<el-form-item label="月份" prop="month">
@@ -431,7 +431,7 @@ export default {
 			data ? '' : (data = this.formData);
 			
 			data.position = data.position == 'manager' ? 'manager' : data.position == 'employee' ? 'employee' : 'all';
-			self.$axios('get','/api/integral/statistics/ranking',data).then(res => {
+			self.$axios('get','/api/integral/statistics/ranking',data,'v2').then(res => {
 				this.labelName=this.formData.pt_id==2? 'A分':'B分';
 				if (res.data.code == 1) {
 					self.list = res.data.data.list;

+ 57 - 23
src/views/ranking/integral_event.vue

@@ -50,8 +50,8 @@
 				  </el-input>
 			  </el-form-item>
 			  <el-form-item>
-				  <!-- <el-button type="primary" size="medium" @click="excelImportShow = true">导入数据</el-button> -->
-				  <el-button type="primary" size="medium" @click="exportExcel">导出当前数据</el-button>
+				  <el-button type="success" size="medium" @click="excelImportShow = true" plain>导入数据</el-button>
+				  <el-button type="primary" size="medium" @click="exportExcel" plain>导出当前数据</el-button>
 				  <!-- <el-button type="primary" size="medium" plain @click="swiperShow = true">轮播事件</el-button> -->
 			  </el-form-item>
 			</el-form> 
@@ -211,15 +211,23 @@
 					<el-button size="medium" type="primary" @click="downloadTemplate"  plain>下载模板</el-button>
 				</div>
 				<div class="margin-bottom">
-					<el-upload  :limit="1" :headers="ATOKEN" ref="upload1" :action="action" :data="{ type: 'integral' }" :on-success="handlePictureCardPreview" :before-upload="beforeFilesUpload">
+					<el-upload  
+					:limit="1" 
+					:headers="ATOKEN" 
+					ref="upload" 
+					:action="action" 
+					:on-remove="handleRemove"
+					:on-success="handlePictureCardPreview" 
+					:file-list="fileList"
+					:before-upload="beforeFilesUpload">
 						<p>2、上传积分事件数据Excel表<el-button  style="margin-left: 10px;" size="medium" type="primary" plain>选择文件</el-button></p>
 					</el-upload>
 				</div>
-				<div>3、选择文件后点击下方【上传】按钮</div>
+				<!-- <div>3、选择文件后点击下方【上传】按钮</div> -->
 			</div>
 			<div slot="footer" class="dialog-footer">
 				<el-button @click="close_import"  size="medium">取 消</el-button>
-				<el-button type="primary" @click="uploadFile(1)"  size="medium" :loading="update_btn">上传</el-button>
+				<!-- <el-button type="primary" @click="uploadFile()"  size="medium" :loading="update_btn">上传</el-button> -->
 			</div>
 		</el-dialog>
 
@@ -262,8 +270,9 @@ import noData from '@/components/noData';
 export default {
 	data() {
 		return {
-			action:process.env.VUE_APP_BASE_API+'/api/upload/excel',
-			ATOKEN: { 'A-TOKEN':this.$getToken()},
+			action:process.env.VUE_APP_BASE_API+'api/integral/import',
+			ATOKEN: { 'A-TOKEN': this.$getToken(),'Accept':'application/vnd.test.v2+json' },
+			
 			loading: false,
 			swiperShow: false,
 			swiperPageList: [{ value: '10' }, { value: '30' }, { value: '50' }],
@@ -288,7 +297,8 @@ export default {
 			excelImportShow: false,
 			update_btn: false,
 			error_list: [],
-			importErrorInfoShow: false
+			importErrorInfoShow: false,
+			fileList: [],
 		};
 	},
 	components: { noData },
@@ -321,9 +331,9 @@ export default {
 		dept_name(val, old_val) {
 			this.formData.page = 1;
 			if (val.length !== 0) {
-				this.formData.dept_id = val[val.length - 1];
+				this.formData.dept_ids = val[val.length - 1];
 			} else {
-				this.formData.dept_id == 0;
+				this.formData.dept_ids == 0;
 			}
 			this.$nextTick(() => {
 				this.$refs.dept.dropDownVisible = false;
@@ -332,23 +342,31 @@ export default {
 		}
 	},
 	methods: {
+		handleRemove(file, fileList) {
+			// if (fileList !== null && fileList.length != 0) {
+			// 	this.import_btn_show = true;
+			// } else {
+			// 	this.import_btn_show = false;
+			// }
+		},
+		// 导入相关
+		close_import() {
+			this.excelImportShow = false;
+			this.$refs.upload.clearFiles();
+		},
 		// keyword
 		keyWordSelect() {
 			this.formData.page = 1;
 			this.get_integral_list(this.formData);
 		},
 		downloadTemplate() {
-			window.open(process.env.VUE_APP_BASE_API + 'api/download/integral/template');
-		},
-		// 文件上传
-		close_import() {
-			this.excelImportShow = false;
+			window.open('https://ding.insys.g107.com/file/integral.xlsx');
 		},
 		uploadFile() {
 			let params = {};
 			params.file = this.file;
 			this.update_btn = true;
-			this.$axios("post",'/api/integral/import', params).then(res => {
+			this.$axios("post",'/api/integral/import', params,'v2').then(res => {
 					if (res.data.code == 1) {
 						if (res.data.data.error.length == 0) {
 							this.$message({ type: 'success', message: '导入成功' });
@@ -361,17 +379,35 @@ export default {
 					} else {
 						this.$message({ type: 'error', message: res.data.msg });
 					}
-				})
-				.finally(() => {
+				}).finally(() => {
 					setTimeout(() => {
 						this.update_btn = false;
 					}, 3000);
 				});
 		},
 		handlePictureCardPreview(response) {
-			console.log(response);
 			if (response.code == 1) {
-				this.file = response.data;
+				if(response.data.error.length>0){
+					var htmls=response.data.error;
+					var str="<div class='red'></div>";
+					htmls.forEach(item=>{
+						str+=`<div>${item}</div>`;
+					})
+					this.close_import();
+					this.$notify.error({
+					          title: '导入错误',
+					          dangerouslyUseHTMLString: true,
+					          message: str,
+							  duration:0,
+							  offset:50,
+							  customClass:'notifyBox',
+					});
+				}else{
+					this.file = response.data;
+					this.$message.success({ message: response.msg });
+					this.keyWordSelect();
+					this.close_import();
+				}
 			}
 		},
 		beforeFilesUpload(file) {
@@ -391,7 +427,7 @@ export default {
 					this.formData.page_size +
 					(this.formData.rule_id ? '&rule_id=' + this.formData.rule_id : '') +
 					(this.formData.pt_id ? '&pt_id=' + this.formData.pt_id : '') +
-					(this.formData.dept_id ? '&dept_ids=' + this.formData.dept_id : '') +
+					(this.formData.dept_ids ? '&dept_ids=' + this.formData.dept_ids : '') +
 					(this.formData.start_day ? '&start_day=' + this.formData.start_day : '') +
 					(this.formData.end_day ? '&end_day=' + this.formData.end_day : '') +
 					(this.formData.keyword ? '&keyword=' + this.formData.keyword : ''),
@@ -437,8 +473,6 @@ export default {
 			});
 		},
 		get_integral_list(data) {
-			data.dept_ids = data.dept_id;
-			delete data.dept_id;
 			this.loading = true;
 			this.$axios('get','/api/integral/statistics/integral',data).then(res => {
 					if (res.data.code == 1) {

+ 93 - 3
src/views/ranking/total_rank.vue

@@ -19,7 +19,10 @@
 						placeholder="全公司"
 					></el-cascader>
 				</el-form-item>
-				<el-form-item><el-checkbox v-model="sort" size="medium" label="排名由低到高" border></el-checkbox></el-form-item>
+				<el-form-item>
+					<el-checkbox v-model="sort" size="medium" label="排名由低到高" border></el-checkbox>
+					<el-button type="primary" size="medium" @click="dialogVisible = true" style="margin-left: 10px;" plain>导出排名</el-button>
+				</el-form-item>
 			</el-form>
 
 			<el-table :data="list" style="width: 100%" v-loading="loading">
@@ -61,6 +64,50 @@
 				></el-pagination>
 			</center>
 		</div>
+		
+		<!-- 导出弹窗 -->
+		<el-dialog title="导出排名" :visible.sync="dialogVisible" width="730px" top="10%">
+			<span style="font-size:15px">系统将按以下已选条件导出对应的排名报表</span>
+			<el-form :inline="true">
+				<div class="picker_er">
+					<el-form-item label="时间">
+						<el-date-picker
+							v-model="Dc_Data.value1"
+							type="daterange"
+							 size="medium"
+							value-format="yyyy-MM-dd"
+							format="yyyy-MM-dd"
+							range-separator="至"
+							start-placeholder="开始日期"
+							end-placeholder="结束日期"
+						></el-date-picker>
+					</el-form-item>
+		
+					<el-form-item label="人员" style="margin-left:30px">
+						<el-select  size="medium" v-model="Dc_Data.DC_position" style="width:150px" placeholder="请选择">
+							<el-option v-for="item in positions" :key="item.id" :label="item.name" :value="item.age"></el-option>
+						</el-select>
+					</el-form-item>
+				</div>
+				<el-form-item label="部门">
+					<el-cascader
+						class="date-picker-width cascader_bm"
+						v-model="Dc_Data.dept_name"
+						:options="dept_tree"
+						:props="{ checkStrictly: true,value:'id',label:'name',children:'_child'}"
+						ref="dept2"
+						size="medium"
+						clearable
+						filterable
+						placeholder="全公司"
+					></el-cascader>
+				</el-form-item>
+			</el-form>
+			<span slot="footer" class="dialog-footer">
+				<el-button @click="dialogVisible = false"  size="medium">取 消</el-button>
+				<el-button type="primary" @click="exportExcel"  size="medium">导 出</el-button>
+			</span>
+		</el-dialog>
 	</div>
 </template>
 <script>
@@ -82,7 +129,15 @@ export default {
 			list: null,
 			pageLimit: 10,
 			total: null,
-			tips_show: false
+			tips_show: false,
+			dialogVisible:false,
+			positions: [{ id: 0, age: 'all', name: '全部' }, { id: 1, age: 'manager', name: '管理者' }, { id: 2, age: 'employee', name: '员工' }],
+			Dc_Data: {
+				//导出数据
+				value1: '', //时间
+				DC_position: '全部', //人员
+				dept_name: [], //部门
+			},
 		};
 	},
 	watch: {
@@ -109,6 +164,41 @@ export default {
 		}
 	},
 	methods: {
+		exportExcel() {
+			//人员
+			this.Dc_Data.DC_position =this.Dc_Data.DC_position == 'manager' ? 'manager' : this.Dc_Data.DC_position == 'employee' ? 'employee' : this.Dc_Data.DC_position == '全部' ? 'all' : 'all';
+			//部门
+			let dept_name;
+			for (let i in this.Dc_Data.dept_name) {
+				dept_name = this.Dc_Data.dept_name[i];
+			}
+			this.Dc_Data.dept_name = dept_name;
+			//规则
+			let rule_id = [];
+			for (let i in this.Dc_Data.rule_id) {
+				for (let a in this.Dc_Data.rule_id[i]) {
+					rule_id.push(this.Dc_Data.rule_id[i][a]);
+				}
+			}
+			this.Dc_Data.rule_id = rule_id;
+			let data = '';
+			if (this.Dc_Data.value1) {
+				data += '&start_date=' + this.Dc_Data.value1[0];
+				data += '&end_date=' + this.Dc_Data.value1[1];
+			}
+			data += '&position=' + this.Dc_Data.DC_position;
+			this.Dc_Data.dept_name > 0 ? (data += '&dept_id=' + this.Dc_Data.dept_name) : (data += '&dept_id=0');
+			if (this.Dc_Data.rule_id.length > 0) {
+				data += '&rule_id=' + this.Dc_Data.rule_id;
+			}
+			var tempwindow = window.open('_blank'); // 先打开页面
+			tempwindow.document.write(
+			  "<p style='text-align:center;padding-top:50px;font-size:24px'>数据报表正在生成,生成后将自动下载,请不要关闭此标签页<br/><span style='font-size:17px'>(如网络错误请刷新后重试)<span/></p>"
+			);
+			tempwindow.document.title = '导出';
+			tempwindow.location = process.env.VUE_APP_BASE_API + '/api/download/ranking/v2?pt_id=3&type=all&employee_id='+this.$getUserData().id+ data; // 后更改页面地址
+			this.dialogVisible = false;
+		},
 		// 提示信息
 		tips_close() {
 			localStorage.setItem('total_rank_tips', 'true');
@@ -132,7 +222,7 @@ export default {
 		},
 		get_list() {
 			this.loading = true;
-			this.$axios('get','/api/integral/statistics/ranking', this.formData).then(res => {
+			this.$axios('get','/api/integral/statistics/ranking', this.formData,'v2').then(res => {
 					if (res.data.code == 1) {
 						this.list = res.data.data.list;
 						this.total = res.data.data.total;

+ 42 - 1
src/views/set/framework.vue

@@ -71,6 +71,25 @@
 						</el-table-column>
 						<el-table-column prop="accedence_time" label="入职时间"></el-table-column>
 						<el-table-column label="启用积分管理">
+							<template slot="header" slot-scope="scope">
+								  <el-popover
+									placement="top-start"
+									width="300"
+									trigger="manual"
+									v-model="visible">
+									<div class="el-popover2">
+										<div class="title">提示 <i class="el-icon-info" style="margin-left: 5px;"></i></div>
+										<div>员工在此启用积分管理后才能正常,管理员默认开启</div>
+										
+										<div class="flex-box">
+											<div class="flex-1"></div>
+											<el-button size="small" @click="visible=!visible">我知道了</el-button>
+										</div>
+										
+									</div>
+									<div slot="reference" class="popover" @click="visible=!visible">启用积分管理</div>
+								  </el-popover>
+							</template>
 							<template slot-scope="scope">
 								<div :class="[scope.row.is_official==1? 'switch-box':'']" @click="changeIs(scope.row.is_official, scope.row.id)">
 									<div class="switch"></div>
@@ -122,7 +141,8 @@ export default {
 			tableToading: false,
 			tbLoading: false,
 			selectIds: [],
-			enable_loading:false
+			enable_loading:false,
+			visible:false
 			
 		};
 	},
@@ -231,6 +251,7 @@ export default {
 			this.$axios('get','/api/employee/index', {dept_id: this.dept_id, keywords: this.keywords, page: this.page, page_size: this.perPage }).then(res => {
 				this.total = res.data.data.pageInfo.count;
 				this.userList = res.data.data.list;
+				this.visible=true;
 			}).finally(err=>{
 				this.tableToading=false;
 			});
@@ -255,6 +276,22 @@ export default {
 </script>
 
 <style lang="scss" scoped="scoped">
+ .title{
+	 font-size: 16px;
+	 color: #909399;
+	 margin-bottom: 10px;
+ }	
+.popover{
+	border: none;
+	// color: #909399;
+	font-weight: 600;
+	cursor: pointer;
+}
+.popover:hover{
+	background-color: #fff;
+	border-color: #fff;
+}
+
 .switch{
     margin: 0;
     display: inline-block;
@@ -336,6 +373,10 @@ export default {
 	}
 }
 
+ .el-popover2{
+		 // background-color: #409eff !important;
+		 color: #409eff;
+	}
 .rule_class_box {
 	::v-deep .el-tree-node {
 		border-bottom: 1px #f8f8f8 solid;

+ 23 - 12
src/views/set/rule.vue

@@ -27,7 +27,7 @@
 					<div class="flex-box btns flex-v-ce">
 						<el-button size="small" @click="del_item" type="danger" plain>批量删除</el-button>
 						<el-button size="small" @click="add_rule" type="primary">添加规则</el-button>
-						<el-button size="small" @click="import_rules_show = true" plain>导入规则</el-button>
+						<el-button size="small" type="success" @click="import_rules_show = true" plain>导入规则</el-button>
 					</div>
 					<el-table stripe ref="multipleTable" :data="item_list" tooltip-effect="dark" @selection-change="handleSelectionChange" @row-click="editDetails" align="center">
 						<el-table-column type="selection" width="55"></el-table-column>
@@ -212,7 +212,7 @@ export default {
 	data() {
 		return {
 			action:process.env.VUE_APP_BASE_API+'/api/rule/import',
-			downloadUrl:process.env.VUE_APP_BASE_API+'/api/download/rule_item',
+			downloadUrl:'https://ding.insys.g107.com/file/template.xlsx',
 			ATOKEN: { 'A-TOKEN': this.$getToken(),'Accept':'application/vnd.test.v2+json' },
 			tips_show: true,
 			rule_loading: false,
@@ -362,10 +362,27 @@ export default {
 		},
 		handleSuccess(response) {
 			if (response.code == 1) {
-				this.file = response.data;
-				this.$message.success({ message: response.msg });
-				this.getData();
-				this.close_import();
+				if(response.data.length>0){
+					var htmls=response.data;
+					var str="<div class='red'></div>";
+					htmls.forEach(item=>{
+						str+=`<div>${item.errors}</div>`;
+					})
+					this.close_import();
+					this.$notify.error({
+					          title: '导入错误',
+					          dangerouslyUseHTMLString: true,
+					          message: str,
+							  duration:0,
+							  offset:50,
+							  customClass:'notifyBox',
+					});
+				}else{
+						this.file = response.data;
+						this.$message.success({ message: response.msg });
+						this.getData();
+						this.close_import();
+				}
 			}
 		},
 		handleRemove(file, fileList) {
@@ -642,7 +659,6 @@ export default {
 
 		editDetails(val) {
 			this.rules_detail_form = JSON.parse(JSON.stringify(val));
-			console.log(val);
 			if (this.rules_detail_form.min_point == this.rules_detail_form.max_point) {
 				this.rules_detail_form.range_type = '1';
 			} else {
@@ -652,13 +668,10 @@ export default {
 			if (this.rules_detail_form.min_point < 0) {
 				this.integral_select_name1 = '2';
 				let str=this.rules_detail_form.min_point;
-				console.log(str);
 				this.rules_detail_form.min_point=str.toString().substring(1);
 			} else {
 				this.integral_select_name1 = '1';
 			}
-			
-			
 			if (this.rules_detail_form.max_point < 0) {
 				this.integral_select_name2 = '2';
 				let str=this.rules_detail_form.max_point;
@@ -666,8 +679,6 @@ export default {
 			} else {
 				this.integral_select_name2 = '1';
 			}
-			
-			
 			this.rule_show = true;
 			this.rule_type = 'edit';
 		},