mirror of
				https://gitee.com/hhyykk/ipms-sjy.git
				synced 2025-10-30 09:48:43 +08:00 
			
		
		
		
	替换var 为const/let
删除未使用import 替换 == 为 ===
This commit is contained in:
		| @@ -12,8 +12,8 @@ if (process.env.npm_config_preview || rawArgv.includes('--preview')) { | |||||||
|   const port = 9526 |   const port = 9526 | ||||||
|   const publicPath = config.publicPath |   const publicPath = config.publicPath | ||||||
|  |  | ||||||
|   var connect = require('connect') |   const connect = require('connect') | ||||||
|   var serveStatic = require('serve-static') |   const serveStatic = require('serve-static') | ||||||
|   const app = connect() |   const app = connect() | ||||||
|  |  | ||||||
|   app.use( |   app.use( | ||||||
|   | |||||||
| @@ -89,8 +89,8 @@ | |||||||
|     "fs-extra": "^8.1.0", |     "fs-extra": "^8.1.0", | ||||||
|     "lint-staged": "10.5.3", |     "lint-staged": "10.5.3", | ||||||
|     "runjs": "4.4.2", |     "runjs": "4.4.2", | ||||||
|     "sass": "1.32.13", |     "sass": "1.56.0", | ||||||
|     "sass-loader": "10.1.1", |     "sass-loader": "13.1.0", | ||||||
|     "script-ext-html-webpack-plugin": "2.1.5", |     "script-ext-html-webpack-plugin": "2.1.5", | ||||||
|     "svg-sprite-loader": "5.1.1", |     "svg-sprite-loader": "5.1.1", | ||||||
|     "terser-webpack-plugin": "^4.2.3", |     "terser-webpack-plugin": "^4.2.3", | ||||||
|   | |||||||
| @@ -2,7 +2,7 @@ | |||||||
|   <el-breadcrumb class="app-breadcrumb" separator="/"> |   <el-breadcrumb class="app-breadcrumb" separator="/"> | ||||||
|     <transition-group name="breadcrumb"> |     <transition-group name="breadcrumb"> | ||||||
|       <el-breadcrumb-item v-for="(item,index) in levelList" :key="item.path"> |       <el-breadcrumb-item v-for="(item,index) in levelList" :key="item.path"> | ||||||
|         <span v-if="item.redirect==='noRedirect'||index==levelList.length-1" class="no-redirect">{{ item.meta.title }}</span> |         <span v-if="item.redirect==='noRedirect'||index===levelList.length-1" class="no-redirect">{{ item.meta.title }}</span> | ||||||
|         <a v-else @click.prevent="handleLink(item)">{{ item.meta.title }}</a> |         <a v-else @click.prevent="handleLink(item)">{{ item.meta.title }}</a> | ||||||
|       </el-breadcrumb-item> |       </el-breadcrumb-item> | ||||||
|     </transition-group> |     </transition-group> | ||||||
|   | |||||||
| @@ -103,25 +103,25 @@ export default { | |||||||
| 		}, | 		}, | ||||||
| 		// 周期两个值变化时 | 		// 周期两个值变化时 | ||||||
| 		cycleChange() { | 		cycleChange() { | ||||||
| 			if (this.radioValue == '3') { | 			if (this.radioValue === '3') { | ||||||
| 				this.$emit('update', 'day', this.cycleTotal); | 				this.$emit('update', 'day', this.cycleTotal); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| 		// 平均两个值变化时 | 		// 平均两个值变化时 | ||||||
| 		averageChange() { | 		averageChange() { | ||||||
| 			if (this.radioValue == '4') { | 			if (this.radioValue === '4') { | ||||||
| 				this.$emit('update', 'day', this.averageTotal); | 				this.$emit('update', 'day', this.averageTotal); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| 		// 最近工作日值变化时 | 		// 最近工作日值变化时 | ||||||
| 		workdayChange() { | 		workdayChange() { | ||||||
| 			if (this.radioValue == '5') { | 			if (this.radioValue === '5') { | ||||||
| 				this.$emit('update', 'day', this.workdayCheck + 'W'); | 				this.$emit('update', 'day', this.workdayCheck + 'W'); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| 		// checkbox值变化时 | 		// checkbox值变化时 | ||||||
| 		checkboxChange() { | 		checkboxChange() { | ||||||
| 			if (this.radioValue == '7') { | 			if (this.radioValue === '7') { | ||||||
| 				this.$emit('update', 'day', this.checkboxString); | 				this.$emit('update', 'day', this.checkboxString); | ||||||
| 			} | 			} | ||||||
| 		} | 		} | ||||||
| @@ -148,13 +148,12 @@ export default { | |||||||
| 		}, | 		}, | ||||||
| 		// 计算工作日格式 | 		// 计算工作日格式 | ||||||
| 		workdayCheck: function () { | 		workdayCheck: function () { | ||||||
| 			const workday = this.checkNum(this.workday, 1, 31) | 			return this.checkNum(this.workday, 1, 31); | ||||||
| 			return workday; |  | ||||||
| 		}, | 		}, | ||||||
| 		// 计算勾选的checkbox值合集 | 		// 计算勾选的checkbox值合集 | ||||||
| 		checkboxString: function () { | 		checkboxString: function () { | ||||||
| 			let str = this.checkboxList.join(); | 			let str = this.checkboxList.join(); | ||||||
| 			return str == '' ? '*' : str; | 			return str === '' ? '*' : str; | ||||||
| 		} | 		} | ||||||
| 	} | 	} | ||||||
| } | } | ||||||
|   | |||||||
| @@ -68,19 +68,19 @@ export default { | |||||||
| 		}, | 		}, | ||||||
| 		// 周期两个值变化时 | 		// 周期两个值变化时 | ||||||
| 		cycleChange() { | 		cycleChange() { | ||||||
| 			if (this.radioValue == '2') { | 			if (this.radioValue === '2') { | ||||||
| 				this.$emit('update', 'hour', this.cycleTotal); | 				this.$emit('update', 'hour', this.cycleTotal); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| 		// 平均两个值变化时 | 		// 平均两个值变化时 | ||||||
| 		averageChange() { | 		averageChange() { | ||||||
| 			if (this.radioValue == '3') { | 			if (this.radioValue === '3') { | ||||||
| 				this.$emit('update', 'hour', this.averageTotal); | 				this.$emit('update', 'hour', this.averageTotal); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| 		// checkbox值变化时 | 		// checkbox值变化时 | ||||||
| 		checkboxChange() { | 		checkboxChange() { | ||||||
| 			if (this.radioValue == '4') { | 			if (this.radioValue === '4') { | ||||||
| 				this.$emit('update', 'hour', this.checkboxString); | 				this.$emit('update', 'hour', this.checkboxString); | ||||||
| 			} | 			} | ||||||
| 		} | 		} | ||||||
| @@ -107,7 +107,7 @@ export default { | |||||||
| 		// 计算勾选的checkbox值合集 | 		// 计算勾选的checkbox值合集 | ||||||
| 		checkboxString: function () { | 		checkboxString: function () { | ||||||
| 			let str = this.checkboxList.join(); | 			let str = this.checkboxList.join(); | ||||||
| 			return str == '' ? '*' : str; | 			return str === '' ? '*' : str; | ||||||
| 		} | 		} | ||||||
| 	} | 	} | ||||||
| } | } | ||||||
|   | |||||||
| @@ -143,8 +143,8 @@ export default { | |||||||
|   props: ["expression", "hideComponent"], |   props: ["expression", "hideComponent"], | ||||||
|   methods: { |   methods: { | ||||||
|     shouldHide(key) { |     shouldHide(key) { | ||||||
|       if (this.hideComponent && this.hideComponent.includes(key)) return false; |       return !(this.hideComponent && this.hideComponent.includes(key)); | ||||||
|       return true; |  | ||||||
|     }, |     }, | ||||||
|     resolveExp() { |     resolveExp() { | ||||||
|       // 反解析 表达式 |       // 反解析 表达式 | ||||||
| @@ -215,10 +215,10 @@ export default { | |||||||
|           insValue = 4; |           insValue = 4; | ||||||
|           this.$refs[refName].checkboxList = value.split(","); |           this.$refs[refName].checkboxList = value.split(","); | ||||||
|         } |         } | ||||||
|       } else if (name == "day") { |       } else if (name === "day") { | ||||||
|         if (value === "*") { |         if (value === "*") { | ||||||
|           insValue = 1; |           insValue = 1; | ||||||
|         } else if (value == "?") { |         } else if (value === "?") { | ||||||
|           insValue = 2; |           insValue = 2; | ||||||
|         } else if (value.indexOf("-") > -1) { |         } else if (value.indexOf("-") > -1) { | ||||||
|           let indexArr = value.split("-"); |           let indexArr = value.split("-"); | ||||||
| @@ -246,10 +246,10 @@ export default { | |||||||
|           this.$refs[refName].checkboxList = value.split(","); |           this.$refs[refName].checkboxList = value.split(","); | ||||||
|           insValue = 7; |           insValue = 7; | ||||||
|         } |         } | ||||||
|       } else if (name == "week") { |       } else if (name === "week") { | ||||||
|         if (value === "*") { |         if (value === "*") { | ||||||
|           insValue = 1; |           insValue = 1; | ||||||
|         } else if (value == "?") { |         } else if (value === "?") { | ||||||
|           insValue = 2; |           insValue = 2; | ||||||
|         } else if (value.indexOf("-") > -1) { |         } else if (value.indexOf("-") > -1) { | ||||||
|           let indexArr = value.split("-"); |           let indexArr = value.split("-"); | ||||||
| @@ -275,10 +275,10 @@ export default { | |||||||
|           this.$refs[refName].checkboxList = value.split(","); |           this.$refs[refName].checkboxList = value.split(","); | ||||||
|           insValue = 6; |           insValue = 6; | ||||||
|         } |         } | ||||||
|       } else if (name == "year") { |       } else if (name === "year") { | ||||||
|         if (value == "") { |         if (value === "") { | ||||||
|           insValue = 1; |           insValue = 1; | ||||||
|         } else if (value == "*") { |         } else if (value === "*") { | ||||||
|           insValue = 2; |           insValue = 2; | ||||||
|         } else if (value.indexOf("-") > -1) { |         } else if (value.indexOf("-") > -1) { | ||||||
|           insValue = 3; |           insValue = 3; | ||||||
| @@ -343,7 +343,7 @@ export default { | |||||||
|         obj.month + |         obj.month + | ||||||
|         " " + |         " " + | ||||||
|         obj.week + |         obj.week + | ||||||
|         (obj.year == "" ? "" : " " + obj.year); |         (obj.year === "" ? "" : " " + obj.year); | ||||||
|       return str; |       return str; | ||||||
|     }, |     }, | ||||||
|   }, |   }, | ||||||
|   | |||||||
| @@ -69,19 +69,19 @@ export default { | |||||||
| 		}, | 		}, | ||||||
| 		// 周期两个值变化时 | 		// 周期两个值变化时 | ||||||
| 		cycleChange() { | 		cycleChange() { | ||||||
| 			if (this.radioValue == '2') { | 			if (this.radioValue === '2') { | ||||||
| 				this.$emit('update', 'min', this.cycleTotal, 'min'); | 				this.$emit('update', 'min', this.cycleTotal, 'min'); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| 		// 平均两个值变化时 | 		// 平均两个值变化时 | ||||||
| 		averageChange() { | 		averageChange() { | ||||||
| 			if (this.radioValue == '3') { | 			if (this.radioValue === '3') { | ||||||
| 				this.$emit('update', 'min', this.averageTotal, 'min'); | 				this.$emit('update', 'min', this.averageTotal, 'min'); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| 		// checkbox值变化时 | 		// checkbox值变化时 | ||||||
| 		checkboxChange() { | 		checkboxChange() { | ||||||
| 			if (this.radioValue == '4') { | 			if (this.radioValue === '4') { | ||||||
| 				this.$emit('update', 'min', this.checkboxString, 'min'); | 				this.$emit('update', 'min', this.checkboxString, 'min'); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| @@ -109,7 +109,7 @@ export default { | |||||||
| 		// 计算勾选的checkbox值合集 | 		// 计算勾选的checkbox值合集 | ||||||
| 		checkboxString: function () { | 		checkboxString: function () { | ||||||
| 			let str = this.checkboxList.join(); | 			let str = this.checkboxList.join(); | ||||||
| 			return str == '' ? '*' : str; | 			return str === '' ? '*' : str; | ||||||
| 		} | 		} | ||||||
| 	} | 	} | ||||||
| } | } | ||||||
|   | |||||||
| @@ -68,19 +68,19 @@ export default { | |||||||
| 		}, | 		}, | ||||||
| 		// 周期两个值变化时 | 		// 周期两个值变化时 | ||||||
| 		cycleChange() { | 		cycleChange() { | ||||||
| 			if (this.radioValue == '2') { | 			if (this.radioValue === '2') { | ||||||
| 				this.$emit('update', 'month', this.cycleTotal); | 				this.$emit('update', 'month', this.cycleTotal); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| 		// 平均两个值变化时 | 		// 平均两个值变化时 | ||||||
| 		averageChange() { | 		averageChange() { | ||||||
| 			if (this.radioValue == '3') { | 			if (this.radioValue === '3') { | ||||||
| 				this.$emit('update', 'month', this.averageTotal); | 				this.$emit('update', 'month', this.averageTotal); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| 		// checkbox值变化时 | 		// checkbox值变化时 | ||||||
| 		checkboxChange() { | 		checkboxChange() { | ||||||
| 			if (this.radioValue == '4') { | 			if (this.radioValue === '4') { | ||||||
| 				this.$emit('update', 'month', this.checkboxString); | 				this.$emit('update', 'month', this.checkboxString); | ||||||
| 			} | 			} | ||||||
| 		} | 		} | ||||||
| @@ -107,7 +107,7 @@ export default { | |||||||
| 		// 计算勾选的checkbox值合集 | 		// 计算勾选的checkbox值合集 | ||||||
| 		checkboxString: function () { | 		checkboxString: function () { | ||||||
| 			let str = this.checkboxList.join(); | 			let str = this.checkboxList.join(); | ||||||
| 			return str == '' ? '*' : str; | 			return str === '' ? '*' : str; | ||||||
| 		} | 		} | ||||||
| 	} | 	} | ||||||
| } | } | ||||||
|   | |||||||
| @@ -126,7 +126,7 @@ export default { | |||||||
| 					// 如果到达最大值时 | 					// 如果到达最大值时 | ||||||
| 					if (nDay > DDate[DDate.length - 1]) { | 					if (nDay > DDate[DDate.length - 1]) { | ||||||
| 						resetDay(); | 						resetDay(); | ||||||
| 						if (Mi == MDate.length - 1) { | 						if (Mi === MDate.length - 1) { | ||||||
| 							resetMonth(); | 							resetMonth(); | ||||||
| 							continue goYear; | 							continue goYear; | ||||||
| 						} | 						} | ||||||
| @@ -141,9 +141,9 @@ export default { | |||||||
| 						// 如果到达最大值时 | 						// 如果到达最大值时 | ||||||
| 						if (nHour > hDate[hDate.length - 1]) { | 						if (nHour > hDate[hDate.length - 1]) { | ||||||
| 							resetHour(); | 							resetHour(); | ||||||
| 							if (Di == DDate.length - 1) { | 							if (Di === DDate.length - 1) { | ||||||
| 								resetDay(); | 								resetDay(); | ||||||
| 								if (Mi == MDate.length - 1) { | 								if (Mi === MDate.length - 1) { | ||||||
| 									resetMonth(); | 									resetMonth(); | ||||||
| 									continue goYear; | 									continue goYear; | ||||||
| 								} | 								} | ||||||
| @@ -158,7 +158,7 @@ export default { | |||||||
| 							continue goMonth; | 							continue goMonth; | ||||||
| 						} | 						} | ||||||
| 						// 如果日期规则中有值时 | 						// 如果日期规则中有值时 | ||||||
| 						if (this.dayRule == 'lastDay') { | 						if (this.dayRule === 'lastDay') { | ||||||
| 							// 如果不是合法日期则需要将前将日期调到合法日期即月末最后一天 | 							// 如果不是合法日期则需要将前将日期调到合法日期即月末最后一天 | ||||||
|  |  | ||||||
| 							if (this.checkDate(YY + '-' + MM + '-' + thisDD + ' 00:00:00') !== true) { | 							if (this.checkDate(YY + '-' + MM + '-' + thisDD + ' 00:00:00') !== true) { | ||||||
| @@ -168,7 +168,7 @@ export default { | |||||||
| 									thisDD = DD < 10 ? '0' + DD : DD; | 									thisDD = DD < 10 ? '0' + DD : DD; | ||||||
| 								} | 								} | ||||||
| 							} | 							} | ||||||
| 						} else if (this.dayRule == 'workDay') { | 						} else if (this.dayRule === 'workDay') { | ||||||
| 							// 校验并调整如果是2月30号这种日期传进来时需调整至正常月底 | 							// 校验并调整如果是2月30号这种日期传进来时需调整至正常月底 | ||||||
| 							if (this.checkDate(YY + '-' + MM + '-' + thisDD + ' 00:00:00') !== true) { | 							if (this.checkDate(YY + '-' + MM + '-' + thisDD + ' 00:00:00') !== true) { | ||||||
| 								while (DD > 0 && this.checkDate(YY + '-' + MM + '-' + thisDD + ' 00:00:00') !== true) { | 								while (DD > 0 && this.checkDate(YY + '-' + MM + '-' + thisDD + ' 00:00:00') !== true) { | ||||||
| @@ -179,7 +179,7 @@ export default { | |||||||
| 							// 获取达到条件的日期是星期X | 							// 获取达到条件的日期是星期X | ||||||
| 							let thisWeek = this.formatDate(new Date(YY + '-' + MM + '-' + thisDD + ' 00:00:00'), 'week'); | 							let thisWeek = this.formatDate(new Date(YY + '-' + MM + '-' + thisDD + ' 00:00:00'), 'week'); | ||||||
| 							// 当星期日时 | 							// 当星期日时 | ||||||
| 							if (thisWeek == 1) { | 							if (thisWeek === 1) { | ||||||
| 								// 先找下一个日,并判断是否为月底 | 								// 先找下一个日,并判断是否为月底 | ||||||
| 								DD++; | 								DD++; | ||||||
| 								thisDD = DD < 10 ? '0' + DD : DD; | 								thisDD = DD < 10 ? '0' + DD : DD; | ||||||
| @@ -187,7 +187,7 @@ export default { | |||||||
| 								if (this.checkDate(YY + '-' + MM + '-' + thisDD + ' 00:00:00') !== true) { | 								if (this.checkDate(YY + '-' + MM + '-' + thisDD + ' 00:00:00') !== true) { | ||||||
| 									DD -= 3; | 									DD -= 3; | ||||||
| 								} | 								} | ||||||
| 							} else if (thisWeek == 7) { | 							} else if (thisWeek === 7) { | ||||||
| 								// 当星期6时只需判断不是1号就可进行操作 | 								// 当星期6时只需判断不是1号就可进行操作 | ||||||
| 								if (this.dayRuleSup !== 1) { | 								if (this.dayRuleSup !== 1) { | ||||||
| 									DD--; | 									DD--; | ||||||
| @@ -195,16 +195,16 @@ export default { | |||||||
| 									DD += 2; | 									DD += 2; | ||||||
| 								} | 								} | ||||||
| 							} | 							} | ||||||
| 						} else if (this.dayRule == 'weekDay') { | 						} else if (this.dayRule === 'weekDay') { | ||||||
| 							// 如果指定了是星期几 | 							// 如果指定了是星期几 | ||||||
| 							// 获取当前日期是属于星期几 | 							// 获取当前日期是属于星期几 | ||||||
| 							let thisWeek = this.formatDate(new Date(YY + '-' + MM + '-' + DD + ' 00:00:00'), 'week'); | 							let thisWeek = this.formatDate(new Date(YY + '-' + MM + '-' + DD + ' 00:00:00'), 'week'); | ||||||
| 							// 校验当前星期是否在星期池(dayRuleSup)中 | 							// 校验当前星期是否在星期池(dayRuleSup)中 | ||||||
| 							if (this.dayRuleSup.indexOf(thisWeek) < 0) { | 							if (this.dayRuleSup.indexOf(thisWeek) < 0) { | ||||||
| 								// 如果到达最大值时 | 								// 如果到达最大值时 | ||||||
| 								if (Di == DDate.length - 1) { | 								if (Di === DDate.length - 1) { | ||||||
| 									resetDay(); | 									resetDay(); | ||||||
| 									if (Mi == MDate.length - 1) { | 									if (Mi === MDate.length - 1) { | ||||||
| 										resetMonth(); | 										resetMonth(); | ||||||
| 										continue goYear; | 										continue goYear; | ||||||
| 									} | 									} | ||||||
| @@ -212,7 +212,7 @@ export default { | |||||||
| 								} | 								} | ||||||
| 								continue; | 								continue; | ||||||
| 							} | 							} | ||||||
| 						} else if (this.dayRule == 'assWeek') { | 						} else if (this.dayRule === 'assWeek') { | ||||||
| 							// 如果指定了是第几周的星期几 | 							// 如果指定了是第几周的星期几 | ||||||
| 							// 获取每月1号是属于星期几 | 							// 获取每月1号是属于星期几 | ||||||
| 							let thisWeek = this.formatDate(new Date(YY + '-' + MM + '-' + DD + ' 00:00:00'), 'week'); | 							let thisWeek = this.formatDate(new Date(YY + '-' + MM + '-' + DD + ' 00:00:00'), 'week'); | ||||||
| @@ -221,7 +221,7 @@ export default { | |||||||
| 							} else { | 							} else { | ||||||
| 								DD = this.dayRuleSup[0] * 7 + this.dayRuleSup[1] - thisWeek + 1; | 								DD = this.dayRuleSup[0] * 7 + this.dayRuleSup[1] - thisWeek + 1; | ||||||
| 							} | 							} | ||||||
| 						} else if (this.dayRule == 'lastWeek') { | 						} else if (this.dayRule === 'lastWeek') { | ||||||
| 							// 如果指定了每月最后一个星期几 | 							// 如果指定了每月最后一个星期几 | ||||||
| 							// 校验并调整如果是2月30号这种日期传进来时需调整至正常月底 | 							// 校验并调整如果是2月30号这种日期传进来时需调整至正常月底 | ||||||
| 							if (this.checkDate(YY + '-' + MM + '-' + thisDD + ' 00:00:00') !== true) { | 							if (this.checkDate(YY + '-' + MM + '-' + thisDD + ' 00:00:00') !== true) { | ||||||
| @@ -249,11 +249,11 @@ export default { | |||||||
| 							// 如果到达最大值时 | 							// 如果到达最大值时 | ||||||
| 							if (nMin > mDate[mDate.length - 1]) { | 							if (nMin > mDate[mDate.length - 1]) { | ||||||
| 								resetMin(); | 								resetMin(); | ||||||
| 								if (hi == hDate.length - 1) { | 								if (hi === hDate.length - 1) { | ||||||
| 									resetHour(); | 									resetHour(); | ||||||
| 									if (Di == DDate.length - 1) { | 									if (Di === DDate.length - 1) { | ||||||
| 										resetDay(); | 										resetDay(); | ||||||
| 										if (Mi == MDate.length - 1) { | 										if (Mi === MDate.length - 1) { | ||||||
| 											resetMonth(); | 											resetMonth(); | ||||||
| 											continue goYear; | 											continue goYear; | ||||||
| 										} | 										} | ||||||
| @@ -270,13 +270,13 @@ export default { | |||||||
| 								// 如果到达最大值时 | 								// 如果到达最大值时 | ||||||
| 								if (nSecond > sDate[sDate.length - 1]) { | 								if (nSecond > sDate[sDate.length - 1]) { | ||||||
| 									resetSecond(); | 									resetSecond(); | ||||||
| 									if (mi == mDate.length - 1) { | 									if (mi === mDate.length - 1) { | ||||||
| 										resetMin(); | 										resetMin(); | ||||||
| 										if (hi == hDate.length - 1) { | 										if (hi === hDate.length - 1) { | ||||||
| 											resetHour(); | 											resetHour(); | ||||||
| 											if (Di == DDate.length - 1) { | 											if (Di === DDate.length - 1) { | ||||||
| 												resetDay(); | 												resetDay(); | ||||||
| 												if (Mi == MDate.length - 1) { | 												if (Mi === MDate.length - 1) { | ||||||
| 													resetMonth(); | 													resetMonth(); | ||||||
| 													continue goYear; | 													continue goYear; | ||||||
| 												} | 												} | ||||||
| @@ -297,17 +297,17 @@ export default { | |||||||
| 										nums++; | 										nums++; | ||||||
| 									} | 									} | ||||||
| 									// 如果条数满了就退出循环 | 									// 如果条数满了就退出循环 | ||||||
| 									if (nums == 5) break goYear; | 									if (nums === 5) break goYear; | ||||||
| 									// 如果到达最大值时 | 									// 如果到达最大值时 | ||||||
| 									if (si == sDate.length - 1) { | 									if (si === sDate.length - 1) { | ||||||
| 										resetSecond(); | 										resetSecond(); | ||||||
| 										if (mi == mDate.length - 1) { | 										if (mi === mDate.length - 1) { | ||||||
| 											resetMin(); | 											resetMin(); | ||||||
| 											if (hi == hDate.length - 1) { | 											if (hi === hDate.length - 1) { | ||||||
| 												resetHour(); | 												resetHour(); | ||||||
| 												if (Di == DDate.length - 1) { | 												if (Di === DDate.length - 1) { | ||||||
| 													resetDay(); | 													resetDay(); | ||||||
| 													if (Mi == MDate.length - 1) { | 													if (Mi === MDate.length - 1) { | ||||||
| 														resetMonth(); | 														resetMonth(); | ||||||
| 														continue goYear; | 														continue goYear; | ||||||
| 													} | 													} | ||||||
| @@ -326,7 +326,7 @@ export default { | |||||||
| 				}//goMonth | 				}//goMonth | ||||||
| 			} | 			} | ||||||
| 			// 判断100年内的结果条数 | 			// 判断100年内的结果条数 | ||||||
| 			if (resultArr.length == 0) { | 			if (resultArr.length === 0) { | ||||||
| 				this.resultList = ['没有达到条件的结果!']; | 				this.resultList = ['没有达到条件的结果!']; | ||||||
| 			} else { | 			} else { | ||||||
| 				this.resultList = resultArr; | 				this.resultList = resultArr; | ||||||
| @@ -378,23 +378,23 @@ export default { | |||||||
| 		// 获取"日"数组-主要为日期规则 | 		// 获取"日"数组-主要为日期规则 | ||||||
| 		getWeekArr(rule) { | 		getWeekArr(rule) { | ||||||
| 			// 只有当日期规则的两个值均为“”时则表达日期是有选项的 | 			// 只有当日期规则的两个值均为“”时则表达日期是有选项的 | ||||||
| 			if (this.dayRule == '' && this.dayRuleSup == '') { | 			if (this.dayRule === '' && this.dayRuleSup === '') { | ||||||
| 				if (rule.indexOf('-') >= 0) { | 				if (rule.indexOf('-') >= 0) { | ||||||
| 					this.dayRule = 'weekDay'; | 					this.dayRule = 'weekDay'; | ||||||
| 					this.dayRuleSup = this.getCycleArr(rule, 7, false) | 					this.dayRuleSup = this.getCycleArr(rule, 7, false) | ||||||
| 				} else if (rule.indexOf('#') >= 0) { | 				} else if (rule.indexOf('#') >= 0) { | ||||||
| 					this.dayRule = 'assWeek'; | 					this.dayRule = 'assWeek'; | ||||||
| 					let matchRule = rule.match(/[0-9]{1}/g); | 					let matchRule = rule.match(/[0-9]/g); | ||||||
| 					this.dayRuleSup = [Number(matchRule[1]), Number(matchRule[0])]; | 					this.dayRuleSup = [Number(matchRule[1]), Number(matchRule[0])]; | ||||||
| 					this.dateArr[3] = [1]; | 					this.dateArr[3] = [1]; | ||||||
| 					if (this.dayRuleSup[1] == 7) { | 					if (this.dayRuleSup[1] === 7) { | ||||||
| 						this.dayRuleSup[1] = 0; | 						this.dayRuleSup[1] = 0; | ||||||
| 					} | 					} | ||||||
| 				} else if (rule.indexOf('L') >= 0) { | 				} else if (rule.indexOf('L') >= 0) { | ||||||
| 					this.dayRule = 'lastWeek'; | 					this.dayRule = 'lastWeek'; | ||||||
| 					this.dayRuleSup = Number(rule.match(/[0-9]{1,2}/g)[0]); | 					this.dayRuleSup = Number(rule.match(/[0-9]{1,2}/g)[0]); | ||||||
| 					this.dateArr[3] = [31]; | 					this.dateArr[3] = [31]; | ||||||
| 					if (this.dayRuleSup == 7) { | 					if (this.dayRuleSup === 7) { | ||||||
| 						this.dayRuleSup = 0; | 						this.dayRuleSup = 0; | ||||||
| 					} | 					} | ||||||
| 				} else if (rule !== '*' && rule !== '?') { | 				} else if (rule !== '*' && rule !== '?') { | ||||||
| @@ -425,7 +425,7 @@ export default { | |||||||
| 			} else if (rule !== '*' && rule !== '?') { | 			} else if (rule !== '*' && rule !== '?') { | ||||||
| 				this.dateArr[3] = this.getAssignArr(rule) | 				this.dateArr[3] = this.getAssignArr(rule) | ||||||
| 				this.dayRuleSup = 'null'; | 				this.dayRuleSup = 'null'; | ||||||
| 			} else if (rule == '*') { | 			} else if (rule === '*') { | ||||||
| 				this.dayRuleSup = 'null'; | 				this.dayRuleSup = 'null'; | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| @@ -504,7 +504,7 @@ export default { | |||||||
| 			} | 			} | ||||||
| 			for (let i = min; i <= max; i++) { | 			for (let i = min; i <= max; i++) { | ||||||
| 				let add = 0; | 				let add = 0; | ||||||
| 				if (status == false && i % limit == 0) { | 				if (status === false && i % limit === 0) { | ||||||
| 					add = limit; | 					add = limit; | ||||||
| 				} | 				} | ||||||
| 				arr.push(Math.round(i % limit + add)) | 				arr.push(Math.round(i % limit + add)) | ||||||
| @@ -532,9 +532,9 @@ export default { | |||||||
| 			let s = time.getSeconds(); | 			let s = time.getSeconds(); | ||||||
| 			let week = time.getDay(); | 			let week = time.getDay(); | ||||||
| 			// 如果传递了type的话 | 			// 如果传递了type的话 | ||||||
| 			if (type == undefined) { | 			if (type === undefined) { | ||||||
| 				return Y + '-' + (M < 10 ? '0' + M : M) + '-' + (D < 10 ? '0' + D : D) + ' ' + (h < 10 ? '0' + h : h) + ':' + (m < 10 ? '0' + m : m) + ':' + (s < 10 ? '0' + s : s); | 				return Y + '-' + (M < 10 ? '0' + M : M) + '-' + (D < 10 ? '0' + D : D) + ' ' + (h < 10 ? '0' + h : h) + ':' + (m < 10 ? '0' + m : m) + ':' + (s < 10 ? '0' + s : s); | ||||||
| 			} else if (type == 'week') { | 			} else if (type === 'week') { | ||||||
| 				// 在quartz中 1为星期日 | 				// 在quartz中 1为星期日 | ||||||
| 				return week + 1; | 				return week + 1; | ||||||
| 			} | 			} | ||||||
|   | |||||||
| @@ -68,19 +68,19 @@ export default { | |||||||
| 		}, | 		}, | ||||||
| 		// 周期两个值变化时 | 		// 周期两个值变化时 | ||||||
| 		cycleChange() { | 		cycleChange() { | ||||||
| 			if (this.radioValue == '2') { | 			if (this.radioValue === '2') { | ||||||
| 				this.$emit('update', 'second', this.cycleTotal); | 				this.$emit('update', 'second', this.cycleTotal); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| 		// 平均两个值变化时 | 		// 平均两个值变化时 | ||||||
| 		averageChange() { | 		averageChange() { | ||||||
| 			if (this.radioValue == '3') { | 			if (this.radioValue === '3') { | ||||||
| 				this.$emit('update', 'second', this.averageTotal); | 				this.$emit('update', 'second', this.averageTotal); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| 		// checkbox值变化时 | 		// checkbox值变化时 | ||||||
| 		checkboxChange() { | 		checkboxChange() { | ||||||
| 			if (this.radioValue == '4') { | 			if (this.radioValue === '4') { | ||||||
| 				this.$emit('update', 'second', this.checkboxString); | 				this.$emit('update', 'second', this.checkboxString); | ||||||
| 			} | 			} | ||||||
| 		} | 		} | ||||||
| @@ -110,7 +110,7 @@ export default { | |||||||
| 		// 计算勾选的checkbox值合集 | 		// 计算勾选的checkbox值合集 | ||||||
| 		checkboxString: function () { | 		checkboxString: function () { | ||||||
| 			let str = this.checkboxList.join(); | 			let str = this.checkboxList.join(); | ||||||
| 			return str == '' ? '*' : str; | 			return str === '' ? '*' : str; | ||||||
| 		} | 		} | ||||||
| 	} | 	} | ||||||
| } | } | ||||||
|   | |||||||
| @@ -144,25 +144,25 @@ export default { | |||||||
|  |  | ||||||
| 		// 周期两个值变化时 | 		// 周期两个值变化时 | ||||||
| 		cycleChange() { | 		cycleChange() { | ||||||
| 			if (this.radioValue == '3') { | 			if (this.radioValue === '3') { | ||||||
| 				this.$emit('update', 'week', this.cycleTotal); | 				this.$emit('update', 'week', this.cycleTotal); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| 		// 平均两个值变化时 | 		// 平均两个值变化时 | ||||||
| 		averageChange() { | 		averageChange() { | ||||||
| 			if (this.radioValue == '4') { | 			if (this.radioValue === '4') { | ||||||
| 				this.$emit('update', 'week', this.averageTotal); | 				this.$emit('update', 'week', this.averageTotal); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| 		// 最近工作日值变化时 | 		// 最近工作日值变化时 | ||||||
| 		weekdayChange() { | 		weekdayChange() { | ||||||
| 			if (this.radioValue == '5') { | 			if (this.radioValue === '5') { | ||||||
| 				this.$emit('update', 'week', this.weekday + 'L'); | 				this.$emit('update', 'week', this.weekday + 'L'); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| 		// checkbox值变化时 | 		// checkbox值变化时 | ||||||
| 		checkboxChange() { | 		checkboxChange() { | ||||||
| 			if (this.radioValue == '6') { | 			if (this.radioValue === '6') { | ||||||
| 				this.$emit('update', 'week', this.checkboxString); | 				this.$emit('update', 'week', this.checkboxString); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| @@ -195,7 +195,7 @@ export default { | |||||||
| 		// 计算勾选的checkbox值合集 | 		// 计算勾选的checkbox值合集 | ||||||
| 		checkboxString: function () { | 		checkboxString: function () { | ||||||
| 			let str = this.checkboxList.join(); | 			let str = this.checkboxList.join(); | ||||||
| 			return str == '' ? '*' : str; | 			return str === '' ? '*' : str; | ||||||
| 		} | 		} | ||||||
| 	} | 	} | ||||||
| } | } | ||||||
|   | |||||||
| @@ -79,19 +79,19 @@ export default { | |||||||
| 		}, | 		}, | ||||||
| 		// 周期两个值变化时 | 		// 周期两个值变化时 | ||||||
| 		cycleChange() { | 		cycleChange() { | ||||||
| 			if (this.radioValue == '3') { | 			if (this.radioValue === '3') { | ||||||
| 				this.$emit('update', 'year', this.cycleTotal); | 				this.$emit('update', 'year', this.cycleTotal); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| 		// 平均两个值变化时 | 		// 平均两个值变化时 | ||||||
| 		averageChange() { | 		averageChange() { | ||||||
| 			if (this.radioValue == '4') { | 			if (this.radioValue === '4') { | ||||||
| 				this.$emit('update', 'year', this.averageTotal); | 				this.$emit('update', 'year', this.averageTotal); | ||||||
| 			} | 			} | ||||||
| 		}, | 		}, | ||||||
| 		// checkbox值变化时 | 		// checkbox值变化时 | ||||||
| 		checkboxChange() { | 		checkboxChange() { | ||||||
| 			if (this.radioValue == '5') { | 			if (this.radioValue === '5') { | ||||||
| 				this.$emit('update', 'year', this.checkboxString); | 				this.$emit('update', 'year', this.checkboxString); | ||||||
| 			} | 			} | ||||||
| 		} | 		} | ||||||
|   | |||||||
| @@ -108,7 +108,6 @@ export default { | |||||||
|  |  | ||||||
| .pan-info p a { | .pan-info p a { | ||||||
|   display: block; |   display: block; | ||||||
|   color: #333; |  | ||||||
|   width: 80px; |   width: 80px; | ||||||
|   height: 80px; |   height: 80px; | ||||||
|   background: rgba(255, 255, 255, 0.3); |   background: rgba(255, 255, 255, 0.3); | ||||||
|   | |||||||
| @@ -62,7 +62,7 @@ export default { | |||||||
|     }, |     }, | ||||||
|     // 右侧列表元素变化 |     // 右侧列表元素变化 | ||||||
|     dataChange(data) { |     dataChange(data) { | ||||||
|       for (var item in this.columns) { |       for (let item in this.columns) { | ||||||
|         const key = this.columns[item].key; |         const key = this.columns[item].key; | ||||||
|         this.columns[item].visible = !data.includes(key); |         this.columns[item].visible = !data.includes(key); | ||||||
|       } |       } | ||||||
|   | |||||||
| @@ -69,7 +69,7 @@ export default { | |||||||
|     childrenMenus() { |     childrenMenus() { | ||||||
|       const childrenMenus = []; |       const childrenMenus = []; | ||||||
|       this.routers.map((router) => { |       this.routers.map((router) => { | ||||||
|         for (var item in router.children) { |         for (let item in router.children) { | ||||||
|           if (router.children[item].parentPath === undefined) { |           if (router.children[item].parentPath === undefined) { | ||||||
|             if(router.path === "/") { |             if(router.path === "/") { | ||||||
|               router.children[item].path = "/" + router.children[item].path; |               router.children[item].path = "/" + router.children[item].path; | ||||||
| @@ -135,10 +135,10 @@ export default { | |||||||
|     }, |     }, | ||||||
|     // 当前激活的路由 |     // 当前激活的路由 | ||||||
|     activeRoutes(key) { |     activeRoutes(key) { | ||||||
|       var routes = []; |       const routes = [] | ||||||
|       if (this.childrenMenus && this.childrenMenus.length > 0) { |       if (this.childrenMenus && this.childrenMenus.length > 0) { | ||||||
|         this.childrenMenus.map((item) => { |         this.childrenMenus.map((item) => { | ||||||
|           if (key == item.parentPath || (key == "index" && "" == item.path)) { |           if (key === item.parentPath || (key === "index" && "" === item.path)) { | ||||||
|             routes.push(item); |             routes.push(item); | ||||||
|           } |           } | ||||||
|         }); |         }); | ||||||
|   | |||||||
										
											
												File diff suppressed because one or more lines are too long
											
										
									
								
							| @@ -58,7 +58,7 @@ | |||||||
|  * VerifyPoints |  * VerifyPoints | ||||||
|  * @description 点选 |  * @description 点选 | ||||||
|  * */ |  * */ | ||||||
| import { resetSize, _code_chars, _code_color1, _code_color2 } from './../utils/util' | import { resetSize } from './../utils/util' | ||||||
| import { aesEncrypt } from '@/utils/ase' | import { aesEncrypt } from '@/utils/ase' | ||||||
| import { reqGet, reqCheck } from './../api/index' | import { reqGet, reqCheck } from './../api/index' | ||||||
|  |  | ||||||
| @@ -167,7 +167,7 @@ export default { | |||||||
|         setTimeout(() => { |         setTimeout(() => { | ||||||
|           // var flag = this.comparePos(this.fontPos, this.checkPosArr); |           // var flag = this.comparePos(this.fontPos, this.checkPosArr); | ||||||
|           // 发送后端请求 |           // 发送后端请求 | ||||||
|           var captchaVerification = this.secretKey ? aesEncrypt(this.backToken + '---' + JSON.stringify(this.checkPosArr), this.secretKey) : this.backToken + '---' + JSON.stringify(this.checkPosArr) |           const captchaVerification = this.secretKey ? aesEncrypt(this.backToken + '---' + JSON.stringify(this.checkPosArr), this.secretKey) : this.backToken + '---' + JSON.stringify(this.checkPosArr) | ||||||
|           const data = { |           const data = { | ||||||
|             captchaType: this.captchaType, |             captchaType: this.captchaType, | ||||||
|             'pointJson': this.secretKey ? aesEncrypt(JSON.stringify(this.checkPosArr), this.secretKey) : JSON.stringify(this.checkPosArr), |             'pointJson': this.secretKey ? aesEncrypt(JSON.stringify(this.checkPosArr), this.secretKey) : JSON.stringify(this.checkPosArr), | ||||||
| @@ -205,8 +205,8 @@ export default { | |||||||
|  |  | ||||||
|     // 获取坐标 |     // 获取坐标 | ||||||
|     getMousePos: function(obj, e) { |     getMousePos: function(obj, e) { | ||||||
|       var x = e.offsetX |       const x = e.offsetX | ||||||
|       var y = e.offsetY |       const y = e.offsetY | ||||||
|       return { x, y } |       return { x, y } | ||||||
|     }, |     }, | ||||||
|     // 创建坐标点 |     // 创建坐标点 | ||||||
| @@ -253,7 +253,7 @@ export default { | |||||||
|     }, |     }, | ||||||
|     // 坐标转换函数 |     // 坐标转换函数 | ||||||
|     pointTransfrom(pointArr, imgSize) { |     pointTransfrom(pointArr, imgSize) { | ||||||
|       var newPointArr = pointArr.map(p => { |       const newPointArr = pointArr.map(p => { | ||||||
|         const x = Math.round(310 * p.x / parseInt(imgSize.imgWidth)) |         const x = Math.round(310 * p.x / parseInt(imgSize.imgWidth)) | ||||||
|         const y = Math.round(155 * p.y / parseInt(imgSize.imgHeight)) |         const y = Math.round(155 * p.y / parseInt(imgSize.imgHeight)) | ||||||
|         return { x, y } |         return { x, y } | ||||||
|   | |||||||
| @@ -193,7 +193,7 @@ export default { | |||||||
|         this.$parent.$emit('ready', this) |         this.$parent.$emit('ready', this) | ||||||
|       }) |       }) | ||||||
|  |  | ||||||
|       var _this = this |       const _this = this | ||||||
|  |  | ||||||
|       window.removeEventListener('touchmove', function(e) { |       window.removeEventListener('touchmove', function(e) { | ||||||
|         _this.move(e) |         _this.move(e) | ||||||
| @@ -228,11 +228,12 @@ export default { | |||||||
|  |  | ||||||
|     // 鼠标按下 |     // 鼠标按下 | ||||||
|     start: function(e) { |     start: function(e) { | ||||||
|  |       let x | ||||||
|       e = e || window.event |       e = e || window.event | ||||||
|       if (!e.touches) { // 兼容PC端 |       if (!e.touches) { // 兼容PC端 | ||||||
|         var x = e.clientX |         x = e.clientX | ||||||
|       } else { // 兼容移动端 |       } else { // 兼容移动端 | ||||||
|         var x = e.touches[0].pageX |         x = e.touches[0].pageX | ||||||
|       } |       } | ||||||
|       this.startLeft = Math.floor(x - this.barArea.getBoundingClientRect().left) |       this.startLeft = Math.floor(x - this.barArea.getBoundingClientRect().left) | ||||||
|       this.startMoveTime = +new Date() // 开始滑动的时间 |       this.startMoveTime = +new Date() // 开始滑动的时间 | ||||||
| @@ -247,15 +248,16 @@ export default { | |||||||
|     }, |     }, | ||||||
|     // 鼠标移动 |     // 鼠标移动 | ||||||
|     move: function(e) { |     move: function(e) { | ||||||
|  |       let x | ||||||
|       e = e || window.event |       e = e || window.event | ||||||
|       if (this.status && this.isEnd === false) { |       if (this.status && this.isEnd === false) { | ||||||
|         if (!e.touches) { // 兼容PC端 |         if (!e.touches) { // 兼容PC端 | ||||||
|           var x = e.clientX |           x = e.clientX | ||||||
|         } else { // 兼容移动端 |         } else { // 兼容移动端 | ||||||
|           var x = e.touches[0].pageX |           x = e.touches[0].pageX | ||||||
|         } |         } | ||||||
|         var bar_area_left = this.barArea.getBoundingClientRect().left |         const bar_area_left = this.barArea.getBoundingClientRect().left | ||||||
|         var move_block_left = x - bar_area_left // 小方块相对于父元素的left值 |         let move_block_left = x - bar_area_left  // 小方块相对于父元素的left值 | ||||||
|         if (move_block_left >= this.barArea.offsetWidth - parseInt(parseInt(this.blockSize.width) / 2) - 2) { |         if (move_block_left >= this.barArea.offsetWidth - parseInt(parseInt(this.blockSize.width) / 2) - 2) { | ||||||
|           move_block_left = this.barArea.offsetWidth - parseInt(parseInt(this.blockSize.width) / 2) - 2 |           move_block_left = this.barArea.offsetWidth - parseInt(parseInt(this.blockSize.width) / 2) - 2 | ||||||
|         } |         } | ||||||
| @@ -271,10 +273,10 @@ export default { | |||||||
|     // 鼠标松开 |     // 鼠标松开 | ||||||
|     end: function() { |     end: function() { | ||||||
|       this.endMovetime = +new Date() |       this.endMovetime = +new Date() | ||||||
|       var _this = this |       const _this = this | ||||||
|       // 判断是否重合 |       // 判断是否重合 | ||||||
|       if (this.status && this.isEnd === false) { |       if (this.status && this.isEnd === false) { | ||||||
|         var moveLeftDistance = parseInt((this.moveBlockLeft || '').replace('px', '')) |         const moveLeftDistance = parseInt((this.moveBlockLeft || '').replace('px', '')) | ||||||
|         moveLeftDistance = moveLeftDistance * 310 / parseInt(this.setSize.imgWidth) |         moveLeftDistance = moveLeftDistance * 310 / parseInt(this.setSize.imgWidth) | ||||||
|         const data = { |         const data = { | ||||||
|           captchaType: this.captchaType, |           captchaType: this.captchaType, | ||||||
| @@ -297,7 +299,10 @@ export default { | |||||||
|             } |             } | ||||||
|             this.passFlag = true |             this.passFlag = true | ||||||
|             this.tipWords = `${((this.endMovetime - this.startMoveTime) / 1000).toFixed(2)}s验证成功` |             this.tipWords = `${((this.endMovetime - this.startMoveTime) / 1000).toFixed(2)}s验证成功` | ||||||
|             var captchaVerification = this.secretKey ? aesEncrypt(this.backToken + '---' + JSON.stringify({ x: moveLeftDistance, y: 5.0 }), this.secretKey) : this.backToken + '---' + JSON.stringify({ x: moveLeftDistance, y: 5.0 }) |             const captchaVerification = this.secretKey ? aesEncrypt(this.backToken + '---' + JSON.stringify({ | ||||||
|  |               x: moveLeftDistance, | ||||||
|  |               y: 5.0 | ||||||
|  |             }), this.secretKey) : this.backToken + '---' + JSON.stringify({ x: moveLeftDistance, y: 5.0 }) | ||||||
|             setTimeout(() => { |             setTimeout(() => { | ||||||
|               this.tipWords = '' |               this.tipWords = '' | ||||||
|               this.$parent.closeBox() |               this.$parent.closeBox() | ||||||
|   | |||||||
| @@ -21,8 +21,7 @@ service.interceptors.request.use( | |||||||
| // response interceptor | // response interceptor | ||||||
| service.interceptors.response.use( | service.interceptors.response.use( | ||||||
|   response => { |   response => { | ||||||
|     const res = response.data |     return response.data | ||||||
|     return res |  | ||||||
|   }, |   }, | ||||||
|   error => { |   error => { | ||||||
|   } |   } | ||||||
|   | |||||||
| @@ -49,14 +49,14 @@ export default function ContextPadProvider( | |||||||
|   } |   } | ||||||
|  |  | ||||||
|   eventBus.on("create.end", 250, function(event) { |   eventBus.on("create.end", 250, function(event) { | ||||||
|     var context = event.context, |     const context = event.context, | ||||||
|       shape = context.shape; |       shape = context.shape | ||||||
|  |  | ||||||
|     if (!hasPrimaryModifier(event) || !contextPad.isOpen(shape)) { |     if (!hasPrimaryModifier(event) || !contextPad.isOpen(shape)) { | ||||||
|       return; |       return; | ||||||
|     } |     } | ||||||
|  |  | ||||||
|     var entries = contextPad.getEntries(shape); |     const entries = contextPad.getEntries(shape) | ||||||
|  |  | ||||||
|     if (entries.replace) { |     if (entries.replace) { | ||||||
|       entries.replace.action.click(event, shape); |       entries.replace.action.click(event, shape); | ||||||
| @@ -81,7 +81,7 @@ ContextPadProvider.$inject = [ | |||||||
| ]; | ]; | ||||||
|  |  | ||||||
| ContextPadProvider.prototype.getContextPadEntries = function(element) { | ContextPadProvider.prototype.getContextPadEntries = function(element) { | ||||||
|   var contextPad = this._contextPad, |   const contextPad = this._contextPad, | ||||||
|     modeling = this._modeling, |     modeling = this._modeling, | ||||||
|     elementFactory = this._elementFactory, |     elementFactory = this._elementFactory, | ||||||
|     connect = this._connect, |     connect = this._connect, | ||||||
| @@ -90,15 +90,15 @@ ContextPadProvider.prototype.getContextPadEntries = function(element) { | |||||||
|     canvas = this._canvas, |     canvas = this._canvas, | ||||||
|     rules = this._rules, |     rules = this._rules, | ||||||
|     autoPlace = this._autoPlace, |     autoPlace = this._autoPlace, | ||||||
|     translate = this._translate; |     translate = this._translate | ||||||
|  |  | ||||||
|   var actions = {}; |   const actions = {} | ||||||
|  |  | ||||||
|   if (element.type === "label") { |   if (element.type === "label") { | ||||||
|     return actions; |     return actions; | ||||||
|   } |   } | ||||||
|  |  | ||||||
|   var businessObject = element.businessObject; |   const businessObject = element.businessObject | ||||||
|  |  | ||||||
|   function startConnect(event, element) { |   function startConnect(event, element) { | ||||||
|     connect.start(event, element); |     connect.start(event, element); | ||||||
| @@ -109,21 +109,21 @@ ContextPadProvider.prototype.getContextPadEntries = function(element) { | |||||||
|   } |   } | ||||||
|  |  | ||||||
|   function getReplaceMenuPosition(element) { |   function getReplaceMenuPosition(element) { | ||||||
|     var Y_OFFSET = 5; |     const Y_OFFSET = 5 | ||||||
|  |  | ||||||
|     var diagramContainer = canvas.getContainer(), |     const diagramContainer = canvas.getContainer(), | ||||||
|       pad = contextPad.getPad(element).html; |       pad = contextPad.getPad(element).html | ||||||
|  |  | ||||||
|     var diagramRect = diagramContainer.getBoundingClientRect(), |     const diagramRect = diagramContainer.getBoundingClientRect(), | ||||||
|       padRect = pad.getBoundingClientRect(); |       padRect = pad.getBoundingClientRect() | ||||||
|  |  | ||||||
|     var top = padRect.top - diagramRect.top; |     const top = padRect.top - diagramRect.top | ||||||
|     var left = padRect.left - diagramRect.left; |     const left = padRect.left - diagramRect.left | ||||||
|  |  | ||||||
|     var pos = { |     const pos = { | ||||||
|       x: left, |       x: left, | ||||||
|       y: top + padRect.height + Y_OFFSET |       y: top + padRect.height + Y_OFFSET | ||||||
|     }; |     } | ||||||
|  |  | ||||||
|     return pos; |     return pos; | ||||||
|   } |   } | ||||||
| @@ -145,19 +145,19 @@ ContextPadProvider.prototype.getContextPadEntries = function(element) { | |||||||
|     } |     } | ||||||
|  |  | ||||||
|     function appendStart(event, element) { |     function appendStart(event, element) { | ||||||
|       var shape = elementFactory.createShape(assign({ type: type }, options)); |       const shape = elementFactory.createShape(assign({ type: type }, options)) | ||||||
|       create.start(event, shape, { |       create.start(event, shape, { | ||||||
|         source: element |         source: element | ||||||
|       }); |       }); | ||||||
|     } |     } | ||||||
|  |  | ||||||
|     var append = autoPlace |     const append = autoPlace | ||||||
|       ? function(event, element) { |       ? function(event, element) { | ||||||
|           var shape = elementFactory.createShape(assign({ type: type }, options)); |         const shape = elementFactory.createShape(assign({ type: type }, options)) | ||||||
|  |  | ||||||
|           autoPlace.append(element, shape); |         autoPlace.append(element, shape) | ||||||
|       } |       } | ||||||
|       : appendStart; |       : appendStart | ||||||
|  |  | ||||||
|     return { |     return { | ||||||
|       group: "model", |       group: "model", | ||||||
| @@ -182,7 +182,7 @@ ContextPadProvider.prototype.getContextPadEntries = function(element) { | |||||||
|   } |   } | ||||||
|  |  | ||||||
|   if (isAny(businessObject, ["bpmn:Lane", "bpmn:Participant"]) && isExpanded(businessObject)) { |   if (isAny(businessObject, ["bpmn:Lane", "bpmn:Participant"]) && isExpanded(businessObject)) { | ||||||
|     var childLanes = getChildLanes(element); |     const childLanes = getChildLanes(element) | ||||||
|  |  | ||||||
|     assign(actions, { |     assign(actions, { | ||||||
|       "lane-insert-above": { |       "lane-insert-above": { | ||||||
| @@ -302,9 +302,9 @@ ContextPadProvider.prototype.getContextPadEntries = function(element) { | |||||||
|         title: translate("Change type"), |         title: translate("Change type"), | ||||||
|         action: { |         action: { | ||||||
|           click: function(event, element) { |           click: function(event, element) { | ||||||
|             var position = assign(getReplaceMenuPosition(element), { |             const position = assign(getReplaceMenuPosition(element), { | ||||||
|               cursor: { x: event.x, y: event.y } |               cursor: { x: event.x, y: event.y } | ||||||
|             }); |             }) | ||||||
|  |  | ||||||
|             popupMenu.open(element, "bpmn-replace", position); |             popupMenu.open(element, "bpmn-replace", position); | ||||||
|           } |           } | ||||||
| @@ -350,7 +350,7 @@ ContextPadProvider.prototype.getContextPadEntries = function(element) { | |||||||
|   } |   } | ||||||
|  |  | ||||||
|   // delete element entry, only show if allowed by rules |   // delete element entry, only show if allowed by rules | ||||||
|   var deleteAllowed = rules.allowed("elements.delete", { elements: [element] }); |   let deleteAllowed = rules.allowed('elements.delete', { elements: [element] }) | ||||||
|  |  | ||||||
|   if (isArray(deleteAllowed)) { |   if (isArray(deleteAllowed)) { | ||||||
|     // was the element returned as a deletion candidate? |     // was the element returned as a deletion candidate? | ||||||
| @@ -376,10 +376,10 @@ ContextPadProvider.prototype.getContextPadEntries = function(element) { | |||||||
| // helpers ///////// | // helpers ///////// | ||||||
|  |  | ||||||
| function isEventType(eventBo, type, definition) { | function isEventType(eventBo, type, definition) { | ||||||
|   var isType = eventBo.$instanceOf(type); |   const isType = eventBo.$instanceOf(type) | ||||||
|   var isDefinition = false; |   let isDefinition = false | ||||||
|  |  | ||||||
|   var definitions = eventBo.eventDefinitions || []; |   const definitions = eventBo.eventDefinitions || [] | ||||||
|   forEach(definitions, function(def) { |   forEach(definitions, function(def) { | ||||||
|     if (def.$type === definition) { |     if (def.$type === definition) { | ||||||
|       isDefinition = true; |       isDefinition = true; | ||||||
|   | |||||||
| @@ -1,12 +1,12 @@ | |||||||
| "use strict"; | "use strict"; | ||||||
|  |  | ||||||
| var some = require("min-dash").some; | const some = require('min-dash').some | ||||||
|  |  | ||||||
| var ALLOWED_TYPES = { | const ALLOWED_TYPES = { | ||||||
|   FailedJobRetryTimeCycle: ["bpmn:StartEvent", "bpmn:BoundaryEvent", "bpmn:IntermediateCatchEvent", "bpmn:Activity"], |   FailedJobRetryTimeCycle: ['bpmn:StartEvent', 'bpmn:BoundaryEvent', 'bpmn:IntermediateCatchEvent', 'bpmn:Activity'], | ||||||
|   Connector: ["bpmn:EndEvent", "bpmn:IntermediateThrowEvent"], |   Connector: ['bpmn:EndEvent', 'bpmn:IntermediateThrowEvent'], | ||||||
|   Field: ["bpmn:EndEvent", "bpmn:IntermediateThrowEvent"] |   Field: ['bpmn:EndEvent', 'bpmn:IntermediateThrowEvent'] | ||||||
| }; | } | ||||||
|  |  | ||||||
| function is(element, type) { | function is(element, type) { | ||||||
|   return element && typeof element.$instanceOf === "function" && element.$instanceOf(type); |   return element && typeof element.$instanceOf === "function" && element.$instanceOf(type); | ||||||
| @@ -32,8 +32,8 @@ function anyType(element, types) { | |||||||
| } | } | ||||||
|  |  | ||||||
| function isAllowed(propName, propDescriptor, newElement) { | function isAllowed(propName, propDescriptor, newElement) { | ||||||
|   var name = propDescriptor.name, |   const name = propDescriptor.name, | ||||||
|     types = ALLOWED_TYPES[name.replace(/activiti:/, "")]; |     types = ALLOWED_TYPES[name.replace(/activiti:/, '')] | ||||||
|  |  | ||||||
|   return name === propName && anyType(newElement, types); |   return name === propName && anyType(newElement, types); | ||||||
| } | } | ||||||
| @@ -42,8 +42,8 @@ function ActivitiModdleExtension(eventBus) { | |||||||
|   eventBus.on( |   eventBus.on( | ||||||
|     "property.clone", |     "property.clone", | ||||||
|     function(context) { |     function(context) { | ||||||
|       var newElement = context.newElement, |       const newElement = context.newElement, | ||||||
|         propDescriptor = context.propertyDescriptor; |         propDescriptor = context.propertyDescriptor | ||||||
|  |  | ||||||
|       this.canCloneProperty(newElement, propDescriptor); |       this.canCloneProperty(newElement, propDescriptor); | ||||||
|     }, |     }, | ||||||
|   | |||||||
| @@ -1,17 +1,17 @@ | |||||||
| "use strict"; | "use strict"; | ||||||
|  |  | ||||||
| var isFunction = require("min-dash").isFunction, | const isFunction = require('min-dash').isFunction, | ||||||
|   isObject = require("min-dash").isObject, |   isObject = require('min-dash').isObject, | ||||||
|   some = require("min-dash").some; |   some = require('min-dash').some | ||||||
|  |  | ||||||
| var WILDCARD = "*"; | const WILDCARD = '*' | ||||||
|  |  | ||||||
| function CamundaModdleExtension(eventBus) { | function CamundaModdleExtension(eventBus) { | ||||||
|   var self = this; |   const self = this | ||||||
|  |  | ||||||
|   eventBus.on("moddleCopy.canCopyProperty", function(context) { |   eventBus.on("moddleCopy.canCopyProperty", function(context) { | ||||||
|     var property = context.property, |     const property = context.property, | ||||||
|       parent = context.parent; |       parent = context.parent | ||||||
|  |  | ||||||
|     return self.canCopyProperty(property, parent); |     return self.canCopyProperty(property, parent); | ||||||
|   }); |   }); | ||||||
| @@ -45,14 +45,14 @@ CamundaModdleExtension.prototype.canCopyProperty = function(property, parent) { | |||||||
|  |  | ||||||
| CamundaModdleExtension.prototype.canHostInputOutput = function(parent) { | CamundaModdleExtension.prototype.canHostInputOutput = function(parent) { | ||||||
|   // allowed in camunda:Connector |   // allowed in camunda:Connector | ||||||
|   var connector = getParent(parent, "camunda:Connector"); |   const connector = getParent(parent, 'camunda:Connector') | ||||||
|  |  | ||||||
|   if (connector) { |   if (connector) { | ||||||
|     return true; |     return true; | ||||||
|   } |   } | ||||||
|  |  | ||||||
|   // special rules inside bpmn:FlowNode |   // special rules inside bpmn:FlowNode | ||||||
|   var flowNode = getParent(parent, "bpmn:FlowNode"); |   const flowNode = getParent(parent, 'bpmn:FlowNode') | ||||||
|  |  | ||||||
|   if (!flowNode) { |   if (!flowNode) { | ||||||
|     return false; |     return false; | ||||||
| @@ -62,15 +62,13 @@ CamundaModdleExtension.prototype.canHostInputOutput = function(parent) { | |||||||
|     return false; |     return false; | ||||||
|   } |   } | ||||||
|  |  | ||||||
|   if (is(flowNode, "bpmn:SubProcess") && flowNode.get("triggeredByEvent")) { |   return !(is(flowNode, "bpmn:SubProcess") && flowNode.get("triggeredByEvent")); | ||||||
|     return false; |  | ||||||
|   } |  | ||||||
|  |  | ||||||
|   return true; |  | ||||||
| }; | }; | ||||||
|  |  | ||||||
| CamundaModdleExtension.prototype.canHostConnector = function(parent) { | CamundaModdleExtension.prototype.canHostConnector = function(parent) { | ||||||
|   var serviceTaskLike = getParent(parent, "camunda:ServiceTaskLike"); |   const serviceTaskLike = getParent(parent, 'camunda:ServiceTaskLike') | ||||||
|  |  | ||||||
|   if (is(serviceTaskLike, "bpmn:MessageEventDefinition")) { |   if (is(serviceTaskLike, "bpmn:MessageEventDefinition")) { | ||||||
|     // only allow on throw and end events |     // only allow on throw and end events | ||||||
| @@ -81,13 +79,13 @@ CamundaModdleExtension.prototype.canHostConnector = function(parent) { | |||||||
| }; | }; | ||||||
|  |  | ||||||
| CamundaModdleExtension.prototype.canHostIn = function(parent) { | CamundaModdleExtension.prototype.canHostIn = function(parent) { | ||||||
|   var callActivity = getParent(parent, "bpmn:CallActivity"); |   const callActivity = getParent(parent, 'bpmn:CallActivity') | ||||||
|  |  | ||||||
|   if (callActivity) { |   if (callActivity) { | ||||||
|     return true; |     return true; | ||||||
|   } |   } | ||||||
|  |  | ||||||
|   var signalEventDefinition = getParent(parent, "bpmn:SignalEventDefinition"); |   const signalEventDefinition = getParent(parent, 'bpmn:SignalEventDefinition') | ||||||
|  |  | ||||||
|   if (signalEventDefinition) { |   if (signalEventDefinition) { | ||||||
|     // only allow on throw and end events |     // only allow on throw and end events | ||||||
| @@ -129,9 +127,9 @@ function getParent(element, type) { | |||||||
|  |  | ||||||
| function isAllowedInParent(property, parent) { | function isAllowedInParent(property, parent) { | ||||||
|   // (1) find property descriptor |   // (1) find property descriptor | ||||||
|   var descriptor = property.$type && property.$model.getTypeDescriptor(property.$type); |   const descriptor = property.$type && property.$model.getTypeDescriptor(property.$type) | ||||||
|  |  | ||||||
|   var allowedIn = descriptor && descriptor.meta && descriptor.meta.allowedIn; |   const allowedIn = descriptor && descriptor.meta && descriptor.meta.allowedIn | ||||||
|  |  | ||||||
|   if (!allowedIn || isWildcard(allowedIn)) { |   if (!allowedIn || isWildcard(allowedIn)) { | ||||||
|     return true; |     return true; | ||||||
|   | |||||||
| @@ -1,12 +1,12 @@ | |||||||
| "use strict"; | "use strict"; | ||||||
|  |  | ||||||
| var some = require("min-dash").some; | const some = require('min-dash').some | ||||||
|  |  | ||||||
| var ALLOWED_TYPES = { | const ALLOWED_TYPES = { | ||||||
|   FailedJobRetryTimeCycle: ["bpmn:StartEvent", "bpmn:BoundaryEvent", "bpmn:IntermediateCatchEvent", "bpmn:Activity"], |   FailedJobRetryTimeCycle: ['bpmn:StartEvent', 'bpmn:BoundaryEvent', 'bpmn:IntermediateCatchEvent', 'bpmn:Activity'], | ||||||
|   Connector: ["bpmn:EndEvent", "bpmn:IntermediateThrowEvent"], |   Connector: ['bpmn:EndEvent', 'bpmn:IntermediateThrowEvent'], | ||||||
|   Field: ["bpmn:EndEvent", "bpmn:IntermediateThrowEvent"] |   Field: ['bpmn:EndEvent', 'bpmn:IntermediateThrowEvent'] | ||||||
| }; | } | ||||||
|  |  | ||||||
| function is(element, type) { | function is(element, type) { | ||||||
|   return element && typeof element.$instanceOf === "function" && element.$instanceOf(type); |   return element && typeof element.$instanceOf === "function" && element.$instanceOf(type); | ||||||
| @@ -32,8 +32,8 @@ function anyType(element, types) { | |||||||
| } | } | ||||||
|  |  | ||||||
| function isAllowed(propName, propDescriptor, newElement) { | function isAllowed(propName, propDescriptor, newElement) { | ||||||
|   var name = propDescriptor.name, |   const name = propDescriptor.name, | ||||||
|     types = ALLOWED_TYPES[name.replace(/flowable:/, "")]; |     types = ALLOWED_TYPES[name.replace(/flowable:/, '')] | ||||||
|  |  | ||||||
|   return name === propName && anyType(newElement, types); |   return name === propName && anyType(newElement, types); | ||||||
| } | } | ||||||
| @@ -42,8 +42,8 @@ function FlowableModdleExtension(eventBus) { | |||||||
|   eventBus.on( |   eventBus.on( | ||||||
|     "property.clone", |     "property.clone", | ||||||
|     function(context) { |     function(context) { | ||||||
|       var newElement = context.newElement, |       const newElement = context.newElement, | ||||||
|         propDescriptor = context.propertyDescriptor; |         propDescriptor = context.propertyDescriptor | ||||||
|  |  | ||||||
|       this.canCloneProperty(newElement, propDescriptor); |       this.canCloneProperty(newElement, propDescriptor); | ||||||
|     }, |     }, | ||||||
|   | |||||||
| @@ -10,18 +10,18 @@ F.prototype = PaletteProvider.prototype; // 核心,将父类的原型赋值给 | |||||||
|  |  | ||||||
| // 利用中介函数重写原型链方法 | // 利用中介函数重写原型链方法 | ||||||
| F.prototype.getPaletteEntries = function() { | F.prototype.getPaletteEntries = function() { | ||||||
|   var actions = {}, |   const actions = {}, | ||||||
|     create = this._create, |     create = this._create, | ||||||
|     elementFactory = this._elementFactory, |     elementFactory = this._elementFactory, | ||||||
|     spaceTool = this._spaceTool, |     spaceTool = this._spaceTool, | ||||||
|     lassoTool = this._lassoTool, |     lassoTool = this._lassoTool, | ||||||
|     handTool = this._handTool, |     handTool = this._handTool, | ||||||
|     globalConnect = this._globalConnect, |     globalConnect = this._globalConnect, | ||||||
|     translate = this._translate; |     translate = this._translate | ||||||
|  |  | ||||||
|   function createAction(type, group, className, title, options) { |   function createAction(type, group, className, title, options) { | ||||||
|     function createListener(event) { |     function createListener(event) { | ||||||
|       var shape = elementFactory.createShape(assign({ type: type }, options)); |       const shape = elementFactory.createShape(assign({ type: type }, options)) | ||||||
|  |  | ||||||
|       if (options) { |       if (options) { | ||||||
|         shape.businessObject.di.isExpanded = options.isExpanded; |         shape.businessObject.di.isExpanded = options.isExpanded; | ||||||
| @@ -30,7 +30,7 @@ F.prototype.getPaletteEntries = function() { | |||||||
|       create.start(event, shape); |       create.start(event, shape); | ||||||
|     } |     } | ||||||
|  |  | ||||||
|     var shortType = type.replace(/^bpmn:/, ""); |     const shortType = type.replace(/^bpmn:/, '') | ||||||
|  |  | ||||||
|     return { |     return { | ||||||
|       group: group, |       group: group, | ||||||
| @@ -44,19 +44,19 @@ F.prototype.getPaletteEntries = function() { | |||||||
|   } |   } | ||||||
|  |  | ||||||
|   function createSubprocess(event) { |   function createSubprocess(event) { | ||||||
|     var subProcess = elementFactory.createShape({ |     const subProcess = elementFactory.createShape({ | ||||||
|       type: "bpmn:SubProcess", |       type: 'bpmn:SubProcess', | ||||||
|       x: 0, |       x: 0, | ||||||
|       y: 0, |       y: 0, | ||||||
|       isExpanded: true |       isExpanded: true | ||||||
|     }); |     }) | ||||||
|  |  | ||||||
|     var startEvent = elementFactory.createShape({ |     const startEvent = elementFactory.createShape({ | ||||||
|       type: "bpmn:StartEvent", |       type: 'bpmn:StartEvent', | ||||||
|       x: 40, |       x: 40, | ||||||
|       y: 82, |       y: 82, | ||||||
|       parent: subProcess |       parent: subProcess | ||||||
|     }); |     }) | ||||||
|  |  | ||||||
|     create.start(event, [subProcess, startEvent], { |     create.start(event, [subProcess, startEvent], { | ||||||
|       hints: { |       hints: { | ||||||
|   | |||||||
| @@ -19,18 +19,18 @@ export default function PaletteProvider(palette, create, elementFactory, spaceTo | |||||||
| PaletteProvider.$inject = ["palette", "create", "elementFactory", "spaceTool", "lassoTool", "handTool", "globalConnect", "translate"]; | PaletteProvider.$inject = ["palette", "create", "elementFactory", "spaceTool", "lassoTool", "handTool", "globalConnect", "translate"]; | ||||||
|  |  | ||||||
| PaletteProvider.prototype.getPaletteEntries = function() { | PaletteProvider.prototype.getPaletteEntries = function() { | ||||||
|   var actions = {}, |   const actions = {}, | ||||||
|     create = this._create, |     create = this._create, | ||||||
|     elementFactory = this._elementFactory, |     elementFactory = this._elementFactory, | ||||||
|     spaceTool = this._spaceTool, |     spaceTool = this._spaceTool, | ||||||
|     lassoTool = this._lassoTool, |     lassoTool = this._lassoTool, | ||||||
|     handTool = this._handTool, |     handTool = this._handTool, | ||||||
|     globalConnect = this._globalConnect, |     globalConnect = this._globalConnect, | ||||||
|     translate = this._translate; |     translate = this._translate | ||||||
|  |  | ||||||
|   function createAction(type, group, className, title, options) { |   function createAction(type, group, className, title, options) { | ||||||
|     function createListener(event) { |     function createListener(event) { | ||||||
|       var shape = elementFactory.createShape(assign({ type: type }, options)); |       const shape = elementFactory.createShape(assign({ type: type }, options)) | ||||||
|  |  | ||||||
|       if (options) { |       if (options) { | ||||||
|         shape.businessObject.di.isExpanded = options.isExpanded; |         shape.businessObject.di.isExpanded = options.isExpanded; | ||||||
| @@ -39,7 +39,7 @@ PaletteProvider.prototype.getPaletteEntries = function() { | |||||||
|       create.start(event, shape); |       create.start(event, shape); | ||||||
|     } |     } | ||||||
|  |  | ||||||
|     var shortType = type.replace(/^bpmn:/, ""); |     const shortType = type.replace(/^bpmn:/, '') | ||||||
|  |  | ||||||
|     return { |     return { | ||||||
|       group: group, |       group: group, | ||||||
| @@ -53,19 +53,19 @@ PaletteProvider.prototype.getPaletteEntries = function() { | |||||||
|   } |   } | ||||||
|  |  | ||||||
|   function createSubprocess(event) { |   function createSubprocess(event) { | ||||||
|     var subProcess = elementFactory.createShape({ |     const subProcess = elementFactory.createShape({ | ||||||
|       type: "bpmn:SubProcess", |       type: 'bpmn:SubProcess', | ||||||
|       x: 0, |       x: 0, | ||||||
|       y: 0, |       y: 0, | ||||||
|       isExpanded: true |       isExpanded: true | ||||||
|     }); |     }) | ||||||
|  |  | ||||||
|     var startEvent = elementFactory.createShape({ |     const startEvent = elementFactory.createShape({ | ||||||
|       type: "bpmn:StartEvent", |       type: 'bpmn:StartEvent', | ||||||
|       x: 40, |       x: 40, | ||||||
|       y: 82, |       y: 82, | ||||||
|       parent: subProcess |       parent: subProcess | ||||||
|     }); |     }) | ||||||
|  |  | ||||||
|     create.start(event, [subProcess, startEvent], { |     create.start(event, [subProcess, startEvent], { | ||||||
|       hints: { |       hints: { | ||||||
|   | |||||||
| @@ -76,7 +76,7 @@ export default { | |||||||
|       if (!value) { |       if (!value) { | ||||||
|         return; |         return; | ||||||
|       } |       } | ||||||
|       if (!value.match(/[a-zA-Z_][\-_.0-9_a-zA-Z$]*/)) { |       if (!value.match(/[a-zA-Z_][\-_.0-9a-zA-Z$]*/)) { | ||||||
|         console.log('key 不满足 XML NCName 规则,所以不进行赋值'); |         console.log('key 不满足 XML NCName 规则,所以不进行赋值'); | ||||||
|         return; |         return; | ||||||
|       } |       } | ||||||
|   | |||||||
| @@ -1,5 +1,5 @@ | |||||||
| import { isArray } from 'util' | import { isArray } from 'util' | ||||||
| import { exportDefault, titleCase, deepClone } from '@/utils/index' | import { exportDefault, titleCase, deepClone } from '@/utils' | ||||||
| import ruleTrigger from './ruleTrigger' | import ruleTrigger from './ruleTrigger' | ||||||
|  |  | ||||||
| const units = { | const units = { | ||||||
|   | |||||||
| @@ -5,7 +5,7 @@ | |||||||
| export default { | export default { | ||||||
|   bind(el, binding, vnode, oldVnode) { |   bind(el, binding, vnode, oldVnode) { | ||||||
|     const value = binding.value |     const value = binding.value | ||||||
|     if (value == false) return |     if (value === false) return | ||||||
|     // 获取拖拽内容头部 |     // 获取拖拽内容头部 | ||||||
|     const dialogHeaderEl = el.querySelector('.el-dialog__header'); |     const dialogHeaderEl = el.querySelector('.el-dialog__header'); | ||||||
|     const dragDom = el.querySelector('.el-dialog'); |     const dragDom = el.querySelector('.el-dialog'); | ||||||
| @@ -16,7 +16,7 @@ export default { | |||||||
|     dragDom.style.marginTop = 0; |     dragDom.style.marginTop = 0; | ||||||
|     let width = dragDom.style.width; |     let width = dragDom.style.width; | ||||||
|     if (width.includes('%')) { |     if (width.includes('%')) { | ||||||
|       width = +document.body.clientWidth * (+width.replace(/\%/g, '') / 100); |       width = +document.body.clientWidth * (+width.replace(/%/g, '') / 100); | ||||||
|     } else { |     } else { | ||||||
|       width = +width.replace(/\px/g, ''); |       width = +width.replace(/\px/g, ''); | ||||||
|     } |     } | ||||||
| @@ -32,12 +32,12 @@ export default { | |||||||
|  |  | ||||||
|       // 注意在ie中 第一次获取到的值为组件自带50% 移动之后赋值为px |       // 注意在ie中 第一次获取到的值为组件自带50% 移动之后赋值为px | ||||||
|       if (sty.left.includes('%')) { |       if (sty.left.includes('%')) { | ||||||
|         styL = +document.body.clientWidth * (+sty.left.replace(/\%/g, '') / 100); |         styL = +document.body.clientWidth * (+sty.left.replace(/%/g, '') / 100); | ||||||
|         styT = +document.body.clientHeight * (+sty.top.replace(/\%/g, '') / 100); |         styT = +document.body.clientHeight * (+sty.top.replace(/%/g, '') / 100); | ||||||
|       } else { |       } else { | ||||||
|         styL = +sty.left.replace(/\px/g, ''); |         styL = +sty.left.replace(/\px/g, ''); | ||||||
|         styT = +sty.top.replace(/\px/g, ''); |         styT = +sty.top.replace(/\px/g, ''); | ||||||
|       }; |       } | ||||||
|  |  | ||||||
|       // 鼠标拖拽事件 |       // 鼠标拖拽事件 | ||||||
|       document.onmousemove = function (e) { |       document.onmousemove = function (e) { | ||||||
|   | |||||||
| @@ -56,7 +56,7 @@ export default { | |||||||
|   }, |   }, | ||||||
|   // 添加tab页签 |   // 添加tab页签 | ||||||
|   openPage(title, url, params) { |   openPage(title, url, params) { | ||||||
|     var obj = { path: url, meta: { title: title } } |     const obj = { path: url, meta: { title: title } } | ||||||
|     store.dispatch('tagsView/addView', obj); |     store.dispatch('tagsView/addView', obj); | ||||||
|     return router.push({ path: url, query: params }); |     return router.push({ path: url, query: params }); | ||||||
|   }, |   }, | ||||||
|   | |||||||
| @@ -86,7 +86,7 @@ function filterAsyncRouter(asyncRouterMap, lastRouter = false, type = false) { | |||||||
| } | } | ||||||
|  |  | ||||||
| function filterChildren(childrenMap, lastRouter = false) { | function filterChildren(childrenMap, lastRouter = false) { | ||||||
|   var children = [] |   let children = [] | ||||||
|   childrenMap.forEach((el, index) => { |   childrenMap.forEach((el, index) => { | ||||||
|     if (el.children && el.children.length) { |     if (el.children && el.children.length) { | ||||||
|       if (el.component === 'ParentView' && !lastRouter) { |       if (el.component === 'ParentView' && !lastRouter) { | ||||||
|   | |||||||
| @@ -1,4 +1,4 @@ | |||||||
| import {login, logout, getInfo, socialLogin, socialBindLogin, smsLogin} from '@/api/login' | import {login, logout, getInfo, socialLogin, smsLogin} from '@/api/login' | ||||||
| import {setToken, removeToken} from '@/utils/auth' | import {setToken, removeToken} from '@/utils/auth' | ||||||
|  |  | ||||||
| const user = { | const user = { | ||||||
|   | |||||||
| @@ -4,14 +4,14 @@ import { parseTime } from './ruoyi' | |||||||
|  * 表格时间格式化 |  * 表格时间格式化 | ||||||
|  */ |  */ | ||||||
| export function formatDate(cellValue) { | export function formatDate(cellValue) { | ||||||
|   if (cellValue == null || cellValue == "") return ""; |   if (cellValue == null || cellValue === "") return ""; | ||||||
|   var date = new Date(cellValue) |   const date = new Date(cellValue) | ||||||
|   var year = date.getFullYear() |   const year = date.getFullYear() | ||||||
|   var month = date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1 |   const month = date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1 | ||||||
|   var day = date.getDate() < 10 ? '0' + date.getDate() : date.getDate() |   const day = date.getDate() < 10 ? '0' + date.getDate() : date.getDate() | ||||||
|   var hours = date.getHours() < 10 ? '0' + date.getHours() : date.getHours() |   const hours = date.getHours() < 10 ? '0' + date.getHours() : date.getHours() | ||||||
|   var minutes = date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes() |   const minutes = date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes() | ||||||
|   var seconds = date.getSeconds() < 10 ? '0' + date.getSeconds() : date.getSeconds() |   const seconds = date.getSeconds() < 10 ? '0' + date.getSeconds() : date.getSeconds() | ||||||
|   return year + '-' + month + '-' + day + ' ' + hours + ':' + minutes + ':' + seconds |   return year + '-' + month + '-' + day + ' ' + hours + ':' + minutes + ':' + seconds | ||||||
| } | } | ||||||
|  |  | ||||||
| @@ -78,13 +78,13 @@ export function getQueryObject(url) { | |||||||
| } | } | ||||||
|  |  | ||||||
| /** | /** | ||||||
|  * @param {string} input value |  * @param str | ||||||
|  * @returns {number} output value |  * @param str | ||||||
|  */ |  */ | ||||||
| export function byteLength(str) { | export function byteLength(str) { | ||||||
|   // returns the byte length of an utf8 string |   // returns the byte length of an utf8 string | ||||||
|   let s = str.length |   let s = str.length | ||||||
|   for (var i = str.length - 1; i >= 0; i--) { |   for (let i = str.length - 1; i >= 0; i--) { | ||||||
|     const code = str.charCodeAt(i) |     const code = str.charCodeAt(i) | ||||||
|     if (code > 0x7f && code <= 0x7ff) s++ |     if (code > 0x7f && code <= 0x7ff) s++ | ||||||
|     else if (code > 0x7ff && code <= 0xffff) s += 2 |     else if (code > 0x7ff && code <= 0xffff) s += 2 | ||||||
| @@ -136,8 +136,7 @@ export function param2Obj(url) { | |||||||
|     const index = v.indexOf('=') |     const index = v.indexOf('=') | ||||||
|     if (index !== -1) { |     if (index !== -1) { | ||||||
|       const name = v.substring(0, index) |       const name = v.substring(0, index) | ||||||
|       const val = v.substring(index + 1, v.length) |       obj[name] = v.substring(index + 1, v.length) | ||||||
|       obj[name] = val |  | ||||||
|     } |     } | ||||||
|   }) |   }) | ||||||
|   return obj |   return obj | ||||||
| @@ -330,7 +329,7 @@ export function createUniqueString() { | |||||||
|  |  | ||||||
| /** | /** | ||||||
|  * Check if an element has a class |  * Check if an element has a class | ||||||
|  * @param {HTMLElement} elm |  * @param ele | ||||||
|  * @param {string} cls |  * @param {string} cls | ||||||
|  * @returns {boolean} |  * @returns {boolean} | ||||||
|  */ |  */ | ||||||
| @@ -340,7 +339,7 @@ export function hasClass(ele, cls) { | |||||||
|  |  | ||||||
| /** | /** | ||||||
|  * Add class to element |  * Add class to element | ||||||
|  * @param {HTMLElement} elm |  * @param ele | ||||||
|  * @param {string} cls |  * @param {string} cls | ||||||
|  */ |  */ | ||||||
| export function addClass(ele, cls) { | export function addClass(ele, cls) { | ||||||
| @@ -349,7 +348,7 @@ export function addClass(ele, cls) { | |||||||
|  |  | ||||||
| /** | /** | ||||||
|  * Remove class from element |  * Remove class from element | ||||||
|  * @param {HTMLElement} elm |  * @param ele | ||||||
|  * @param {string} cls |  * @param {string} cls | ||||||
|  */ |  */ | ||||||
| export function removeClass(ele, cls) { | export function removeClass(ele, cls) { | ||||||
|   | |||||||
| @@ -15,10 +15,8 @@ export function checkPermi(value) { | |||||||
|       return all_permission === permission || permissionDatas.includes(permission) |       return all_permission === permission || permissionDatas.includes(permission) | ||||||
|     }) |     }) | ||||||
|  |  | ||||||
|     if (!hasPermission) { |     return hasPermission; | ||||||
|       return false |  | ||||||
|     } |  | ||||||
|     return true |  | ||||||
|   } else { |   } else { | ||||||
|     console.error(`need roles! Like checkPermi="['system:user:add','system:user:edit']"`) |     console.error(`need roles! Like checkPermi="['system:user:add','system:user:edit']"`) | ||||||
|     return false |     return false | ||||||
| @@ -40,10 +38,8 @@ export function checkRole(value) { | |||||||
|       return super_admin === role || permissionRoles.includes(role) |       return super_admin === role || permissionRoles.includes(role) | ||||||
|     }) |     }) | ||||||
|  |  | ||||||
|     if (!hasRole) { |     return hasRole; | ||||||
|       return false |  | ||||||
|     } |  | ||||||
|     return true |  | ||||||
|   } else { |   } else { | ||||||
|     console.error(`need roles! Like checkRole="['admin','editor']"`) |     console.error(`need roles! Like checkRole="['admin','editor']"`) | ||||||
|     return false |     return false | ||||||
|   | |||||||
| @@ -49,12 +49,12 @@ service.interceptors.request.use(config => { | |||||||
|     let url = config.url + '?'; |     let url = config.url + '?'; | ||||||
|     for (const propName of Object.keys(config.params)) { |     for (const propName of Object.keys(config.params)) { | ||||||
|       const value = config.params[propName]; |       const value = config.params[propName]; | ||||||
|       var part = encodeURIComponent(propName) + "="; |       const part = encodeURIComponent(propName) + '=' | ||||||
|       if (value !== null && typeof(value) !== "undefined") { |       if (value !== null && typeof(value) !== "undefined") { | ||||||
|         if (typeof value === 'object') { |         if (typeof value === 'object') { | ||||||
|           for (const key of Object.keys(value)) { |           for (const key of Object.keys(value)) { | ||||||
|             let params = propName + '[' + key + ']'; |             let params = propName + '[' + key + ']'; | ||||||
|             var subPart = encodeURIComponent(params) + "="; |             const subPart = encodeURIComponent(params) + '=' | ||||||
|             url += subPart + encodeURIComponent(value[key]) + "&"; |             url += subPart + encodeURIComponent(value[key]) + "&"; | ||||||
|           } |           } | ||||||
|         } else { |         } else { | ||||||
|   | |||||||
| @@ -18,7 +18,7 @@ export function parseTime(time, pattern) { | |||||||
|     if ((typeof time === 'string') && (/^[0-9]+$/.test(time))) { |     if ((typeof time === 'string') && (/^[0-9]+$/.test(time))) { | ||||||
|       time = parseInt(time) |       time = parseInt(time) | ||||||
|     } else if (typeof time === 'string') { |     } else if (typeof time === 'string') { | ||||||
|       time = time.replace(new RegExp(/-/gm), '/').replace('T', ' ').replace(new RegExp(/\.[\d]{3}/gm),''); |       time = time.replace(new RegExp(/-/gm), '/').replace('T', ' ').replace(new RegExp(/\.\d{3}/gm),''); | ||||||
|     } |     } | ||||||
|     if ((typeof time === 'number') && (time.toString().length === 10)) { |     if ((typeof time === 'number') && (time.toString().length === 10)) { | ||||||
|       time = time * 1000 |       time = time * 1000 | ||||||
| @@ -34,7 +34,7 @@ export function parseTime(time, pattern) { | |||||||
|     s: date.getSeconds(), |     s: date.getSeconds(), | ||||||
|     a: date.getDay() |     a: date.getDay() | ||||||
|   } |   } | ||||||
|   const time_str = format.replace(/{(y|m|d|h|i|s|a)+}/g, (result, key) => { |   const time_str = format.replace(/{([ymdhisa])+}/g, (result, key) => { | ||||||
|     let value = formatObj[key] |     let value = formatObj[key] | ||||||
|     // Note: getDay() returns 0 on Sunday |     // Note: getDay() returns 0 on Sunday | ||||||
|     if (key === 'a') { |     if (key === 'a') { | ||||||
| @@ -102,9 +102,11 @@ export function addBeginAndEndTime(params, dateRange, propName) { | |||||||
|  |  | ||||||
| // 字符串格式化(%s ) | // 字符串格式化(%s ) | ||||||
| export function sprintf(str) { | export function sprintf(str) { | ||||||
|   var args = arguments, flag = true, i = 1; |   const args = arguments | ||||||
|  |   let flag = true | ||||||
|  |   const i = 1 | ||||||
|   str = str.replace(/%s/g, function () { |   str = str.replace(/%s/g, function () { | ||||||
|     var arg = args[i++]; |     const arg = args[i++] | ||||||
|     if (typeof arg === 'undefined') { |     if (typeof arg === 'undefined') { | ||||||
|       flag = false; |       flag = false; | ||||||
|       return ''; |       return ''; | ||||||
| @@ -116,7 +118,7 @@ export function sprintf(str) { | |||||||
|  |  | ||||||
| // 转换字符串,undefined,null等转化为"" | // 转换字符串,undefined,null等转化为"" | ||||||
| export function praseStrEmpty(str) { | export function praseStrEmpty(str) { | ||||||
|   if (!str || str == "undefined" || str == "null") { |   if (!str || str === "undefined" || str === "null") { | ||||||
|     return ""; |     return ""; | ||||||
|   } |   } | ||||||
|   return str; |   return str; | ||||||
| @@ -244,7 +246,7 @@ export function getPath(path) { | |||||||
|  * @returns |  * @returns | ||||||
|  */ |  */ | ||||||
|  export function divide(divisor, dividend) { |  export function divide(divisor, dividend) { | ||||||
|   if(divisor == null || dividend == null || dividend == 0){ |   if(divisor == null || dividend == null || dividend === 0){ | ||||||
|     return null; |     return null; | ||||||
|   } |   } | ||||||
|   return Math.floor(divisor/dividend*100)/100; |   return Math.floor(divisor/dividend*100)/100; | ||||||
|   | |||||||
| @@ -8,8 +8,10 @@ Math.easeInOutQuad = function(t, b, c, d) { | |||||||
| } | } | ||||||
|  |  | ||||||
| // requestAnimationFrame for Smart Animating http://goo.gl/sx5sts | // requestAnimationFrame for Smart Animating http://goo.gl/sx5sts | ||||||
| var requestAnimFrame = (function() { | const requestAnimFrame = (function() { | ||||||
|   return window.requestAnimationFrame || window.webkitRequestAnimationFrame || window.mozRequestAnimationFrame || function(callback) { window.setTimeout(callback, 1000 / 60) } |   return window.requestAnimationFrame || window.webkitRequestAnimationFrame || window.mozRequestAnimationFrame || function(callback) { | ||||||
|  |     window.setTimeout(callback, 1000 / 60) | ||||||
|  |   } | ||||||
| })() | })() | ||||||
|  |  | ||||||
| /** | /** | ||||||
| @@ -37,11 +39,11 @@ export function scrollTo(to, duration, callback) { | |||||||
|   const increment = 20 |   const increment = 20 | ||||||
|   let currentTime = 0 |   let currentTime = 0 | ||||||
|   duration = (typeof (duration) === 'undefined') ? 500 : duration |   duration = (typeof (duration) === 'undefined') ? 500 : duration | ||||||
|   var animateScroll = function() { |   const animateScroll = function() { | ||||||
|     // increment the time |     // increment the time | ||||||
|     currentTime += increment |     currentTime += increment | ||||||
|     // find the value with the quadratic in-out easing function |     // find the value with the quadratic in-out easing function | ||||||
|     var val = Math.easeInOutQuad(currentTime, start, change, duration) |     const val = Math.easeInOutQuad(currentTime, start, change, duration) | ||||||
|     // move the document.body |     // move the document.body | ||||||
|     move(val) |     move(val) | ||||||
|     // do the animation unless its over |     // do the animation unless its over | ||||||
|   | |||||||
| @@ -56,7 +56,7 @@ export function validAlphabets(str) { | |||||||
|  * @returns {Boolean} |  * @returns {Boolean} | ||||||
|  */ |  */ | ||||||
| export function validEmail(email) { | export function validEmail(email) { | ||||||
|   const reg = /^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/ |   const reg = /^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/ | ||||||
|   return reg.test(email) |   return reg.test(email) | ||||||
| } | } | ||||||
|  |  | ||||||
| @@ -65,10 +65,8 @@ export function validEmail(email) { | |||||||
|  * @returns {Boolean} |  * @returns {Boolean} | ||||||
|  */ |  */ | ||||||
| export function isString(str) { | export function isString(str) { | ||||||
|   if (typeof str === 'string' || str instanceof String) { |   return typeof str === 'string' || str instanceof String; | ||||||
|     return true |  | ||||||
|   } |  | ||||||
|   return false |  | ||||||
| } | } | ||||||
|  |  | ||||||
| /** | /** | ||||||
|   | |||||||
| @@ -76,7 +76,6 @@ | |||||||
| <script> | <script> | ||||||
| import {getProcessDefinitionBpmnXML, getProcessDefinitionPage} from "@/api/bpm/definition"; | import {getProcessDefinitionBpmnXML, getProcessDefinitionPage} from "@/api/bpm/definition"; | ||||||
| import {DICT_TYPE, getDictDatas} from "@/utils/dict"; | import {DICT_TYPE, getDictDatas} from "@/utils/dict"; | ||||||
| import {getForm} from "@/api/bpm/form"; |  | ||||||
| import {decodeFields} from "@/utils/formGenerator"; | import {decodeFields} from "@/utils/formGenerator"; | ||||||
| import Parser from '@/components/parser/Parser' | import Parser from '@/components/parser/Parser' | ||||||
| import taskAssignRuleDialog from "../taskAssignRule/taskAssignRuleDialog"; | import taskAssignRuleDialog from "../taskAssignRule/taskAssignRuleDialog"; | ||||||
|   | |||||||
| @@ -151,9 +151,7 @@ import RightPanel from '@/views/infra/build/RightPanel' | |||||||
| import { | import { | ||||||
|   inputComponents, selectComponents, layoutComponents, formConf |   inputComponents, selectComponents, layoutComponents, formConf | ||||||
| } from '@/components/generator/config' | } from '@/components/generator/config' | ||||||
| import { | import {beautifierConf, titleCase, deepClone, isObjectObject} from '@/utils' | ||||||
|   exportDefault, beautifierConf, isNumberStr, titleCase, deepClone, isObjectObject |  | ||||||
| } from '@/utils/index' |  | ||||||
| import { | import { | ||||||
|   makeUpHtml, vueTemplate, vueScript, cssStyle |   makeUpHtml, vueTemplate, vueScript, cssStyle | ||||||
| } from '@/components/generator/html' | } from '@/components/generator/html' | ||||||
|   | |||||||
| @@ -159,7 +159,7 @@ export default { | |||||||
|         type: 'warning', |         type: 'warning', | ||||||
|         confirmButtonText: "确定", |         confirmButtonText: "确定", | ||||||
|         cancelButtonText: "取消", |         cancelButtonText: "取消", | ||||||
|         inputPattern: /^[\s\S]*.*[^\s][\s\S]*$/, // 判断非空,且非空格 |         inputPattern: /^[\s\S]*.*\S[\s\S]*$/, // 判断非空,且非空格 | ||||||
|         inputErrorMessage: "取消原因不能为空", |         inputErrorMessage: "取消原因不能为空", | ||||||
|       }).then(({ value }) => { |       }).then(({ value }) => { | ||||||
|         return cancelProcessInstance(id, value); |         return cancelProcessInstance(id, value); | ||||||
|   | |||||||
| @@ -110,8 +110,8 @@ import {DICT_TYPE, getDictDatas} from "@/utils/dict"; | |||||||
| import store from "@/store"; | import store from "@/store"; | ||||||
| import {decodeFields} from "@/utils/formGenerator"; | import {decodeFields} from "@/utils/formGenerator"; | ||||||
| import Parser from '@/components/parser/Parser' | import Parser from '@/components/parser/Parser' | ||||||
| import {createProcessInstance, getProcessInstance} from "@/api/bpm/processInstance"; | import {getProcessInstance} from "@/api/bpm/processInstance"; | ||||||
| import {approveTask, getTaskListByProcessInstanceId, rejectTask, updateTaskAssignee,backTask} from "@/api/bpm/task"; | import {approveTask, getTaskListByProcessInstanceId, rejectTask, updateTaskAssignee} from "@/api/bpm/task"; | ||||||
| import {getDate} from "@/utils/dateUtils"; | import {getDate} from "@/utils/dateUtils"; | ||||||
| import {listSimpleUsers} from "@/api/system/user"; | import {listSimpleUsers} from "@/api/system/user"; | ||||||
| import {getActivityList} from "@/api/bpm/activity"; | import {getActivityList} from "@/api/bpm/activity"; | ||||||
|   | |||||||
| @@ -164,7 +164,7 @@ export default { | |||||||
|         type: 'warning', |         type: 'warning', | ||||||
|         confirmButtonText: "确定", |         confirmButtonText: "确定", | ||||||
|         cancelButtonText: "取消", |         cancelButtonText: "取消", | ||||||
|         inputPattern: /^[\s\S]*.*[^\s][\s\S]*$/, // 判断非空,且非空格 |         inputPattern: /^[\s\S]*.*\S[\s\S]*$/, // 判断非空,且非空格 | ||||||
|         inputErrorMessage: "取消原因不能为空", |         inputErrorMessage: "取消原因不能为空", | ||||||
|       }).then(({ value }) => { |       }).then(({ value }) => { | ||||||
|         return cancelProcessInstance(id, value); |         return cancelProcessInstance(id, value); | ||||||
|   | |||||||
| @@ -50,7 +50,6 @@ | |||||||
|  |  | ||||||
| <script> | <script> | ||||||
| import {getTodoTaskPage} from '@/api/bpm/task' | import {getTodoTaskPage} from '@/api/bpm/task' | ||||||
| import {listSimpleUsers} from "@/api/system/user"; |  | ||||||
|  |  | ||||||
| export default { | export default { | ||||||
|   name: "Todo", |   name: "Todo", | ||||||
|   | |||||||
| @@ -143,8 +143,7 @@ export default { | |||||||
|     .card-panel-description { |     .card-panel-description { | ||||||
|       float: right; |       float: right; | ||||||
|       font-weight: bold; |       font-weight: bold; | ||||||
|       margin: 26px; |       margin: 26px 26px 26px 0; | ||||||
|       margin-left: 0px; |  | ||||||
|  |  | ||||||
|       .card-panel-text { |       .card-panel-text { | ||||||
|         line-height: 18px; |         line-height: 18px; | ||||||
|   | |||||||
| @@ -60,7 +60,7 @@ | |||||||
|   </div> |   </div> | ||||||
| </template> | </template> | ||||||
| <script> | <script> | ||||||
| import { deepClone } from '@/utils/index' | import { deepClone } from '@/utils' | ||||||
|  |  | ||||||
| export default { | export default { | ||||||
|   components: {}, |   components: {}, | ||||||
|   | |||||||
| @@ -651,10 +651,10 @@ | |||||||
| <script> | <script> | ||||||
| import { isArray } from 'util' | import { isArray } from 'util' | ||||||
| import TreeNodeDialog from './TreeNodeDialog' | import TreeNodeDialog from './TreeNodeDialog' | ||||||
| import { isNumberStr } from '@/utils/index' | import { isNumberStr } from '@/utils' | ||||||
| import IconsDialog from './IconsDialog' | import IconsDialog from './IconsDialog' | ||||||
| import { | import { | ||||||
|   inputComponents, selectComponents, layoutComponents |   inputComponents, selectComponents | ||||||
| } from '@/components/generator/config' | } from '@/components/generator/config' | ||||||
| import { saveFormConf } from '@/utils/db' | import { saveFormConf } from '@/utils/db' | ||||||
|  |  | ||||||
|   | |||||||
| @@ -71,7 +71,7 @@ | |||||||
|   </div> |   </div> | ||||||
| </template> | </template> | ||||||
| <script> | <script> | ||||||
| import { isNumberStr } from '@/utils/index' | import { isNumberStr } from '@/utils' | ||||||
| import { getTreeNodeId, saveTreeNodeId } from '@/utils/db' | import { getTreeNodeId, saveTreeNodeId } from '@/utils/db' | ||||||
|  |  | ||||||
| const id = getTreeNodeId() | const id = getTreeNodeId() | ||||||
|   | |||||||
| @@ -133,8 +133,8 @@ import { | |||||||
|   inputComponents, selectComponents, layoutComponents, formConf |   inputComponents, selectComponents, layoutComponents, formConf | ||||||
| } from '@/components/generator/config' | } from '@/components/generator/config' | ||||||
| import { | import { | ||||||
|   exportDefault, beautifierConf, isNumberStr, titleCase, deepClone |   beautifierConf, titleCase, deepClone | ||||||
| } from '@/utils/index' | } from '@/utils' | ||||||
| import { | import { | ||||||
|   makeUpHtml, vueTemplate, vueScript, cssStyle |   makeUpHtml, vueTemplate, vueScript, cssStyle | ||||||
| } from '@/components/generator/html' | } from '@/components/generator/html' | ||||||
|   | |||||||
| @@ -105,7 +105,7 @@ | |||||||
|         </el-form-item> |         </el-form-item> | ||||||
|       </el-col> |       </el-col> | ||||||
|  |  | ||||||
|       <el-col :span="24" v-if="info.genType == '1'"> |       <el-col :span="24" v-if="info.genType === '1'"> | ||||||
|         <el-form-item prop="genPath"> |         <el-form-item prop="genPath"> | ||||||
|           <span slot="label"> |           <span slot="label"> | ||||||
|             自定义路径 |             自定义路径 | ||||||
| @@ -128,7 +128,7 @@ | |||||||
|       </el-col> |       </el-col> | ||||||
|     </el-row> |     </el-row> | ||||||
|  |  | ||||||
|     <el-row v-show="info.tplCategory == 'tree'"> |     <el-row v-show="info.tplCategory === 'tree'"> | ||||||
|       <h4 class="form-header">其他信息</h4> |       <h4 class="form-header">其他信息</h4> | ||||||
|       <el-col :span="12"> |       <el-col :span="12"> | ||||||
|         <el-form-item> |         <el-form-item> | ||||||
| @@ -185,7 +185,7 @@ | |||||||
|         </el-form-item> |         </el-form-item> | ||||||
|       </el-col> |       </el-col> | ||||||
|     </el-row> |     </el-row> | ||||||
|     <el-row v-show="info.tplCategory == 'sub'"> |     <el-row v-show="info.tplCategory === 'sub'"> | ||||||
|       <h4 class="form-header">关联信息</h4> |       <h4 class="form-header">关联信息</h4> | ||||||
|       <el-col :span="12"> |       <el-col :span="12"> | ||||||
|         <el-form-item> |         <el-form-item> | ||||||
| @@ -314,7 +314,7 @@ export default { | |||||||
|     }, |     }, | ||||||
|     /** 设置关联外键 */ |     /** 设置关联外键 */ | ||||||
|     setSubTableColumns(value) { |     setSubTableColumns(value) { | ||||||
|       for (var item in this.tables) { |       for (let item in this.tables) { | ||||||
|         const name = this.tables[item].tableName; |         const name = this.tables[item].tableName; | ||||||
|         if (value === name) { |         if (value === name) { | ||||||
|           this.subColumns = this.tables[item].columns; |           this.subColumns = this.tables[item].columns; | ||||||
|   | |||||||
| @@ -209,7 +209,7 @@ export default { | |||||||
|     highlightedCode(item) { |     highlightedCode(item) { | ||||||
|       // const vmName = key.substring(key.lastIndexOf("/") + 1, key.indexOf(".vm")); |       // const vmName = key.substring(key.lastIndexOf("/") + 1, key.indexOf(".vm")); | ||||||
|       // var language = vmName.substring(vmName.indexOf(".") + 1, vmName.length); |       // var language = vmName.substring(vmName.indexOf(".") + 1, vmName.length); | ||||||
|       var language = item.filePath.substring(item.filePath.lastIndexOf(".") + 1); |       const language = item.filePath.substring(item.filePath.lastIndexOf('.') + 1) | ||||||
|       const result = hljs.highlight(language, item.code || "", true); |       const result = hljs.highlight(language, item.code || "", true); | ||||||
|       return result.value || ' '; |       return result.value || ' '; | ||||||
|     }, |     }, | ||||||
|   | |||||||
| @@ -13,7 +13,7 @@ | |||||||
|                   <td><div class="cell">Redis版本</div></td> |                   <td><div class="cell">Redis版本</div></td> | ||||||
|                   <td><div class="cell" v-if="cache.info">{{ cache.info.redis_version }}</div></td> |                   <td><div class="cell" v-if="cache.info">{{ cache.info.redis_version }}</div></td> | ||||||
|                   <td><div class="cell">运行模式</div></td> |                   <td><div class="cell">运行模式</div></td> | ||||||
|                   <td><div class="cell" v-if="cache.info">{{ cache.info.redis_mode == "standalone" ? "单机" : "集群" }}</div></td> |                   <td><div class="cell" v-if="cache.info">{{ cache.info.redis_mode === "standalone" ? "单机" : "集群" }}</div></td> | ||||||
|                   <td><div class="cell">端口</div></td> |                   <td><div class="cell">端口</div></td> | ||||||
|                   <td><div class="cell" v-if="cache.info">{{ cache.info.tcp_port }}</div></td> |                   <td><div class="cell" v-if="cache.info">{{ cache.info.tcp_port }}</div></td> | ||||||
|                   <td><div class="cell">客户端数</div></td> |                   <td><div class="cell">客户端数</div></td> | ||||||
|   | |||||||
| @@ -1,4 +1,4 @@ | |||||||
| <template> | <template xmlns=""> | ||||||
|   <div class="container"> |   <div class="container"> | ||||||
|     <div class="logo"></div> |     <div class="logo"></div> | ||||||
|     <!-- 登录区域 --> |     <!-- 登录区域 --> | ||||||
| @@ -150,7 +150,7 @@ export default { | |||||||
|           {required: true, trigger: "blur", message: "手机号不能为空"}, |           {required: true, trigger: "blur", message: "手机号不能为空"}, | ||||||
|           { |           { | ||||||
|             validator: function (rule, value, callback) { |             validator: function (rule, value, callback) { | ||||||
|               if (/^(?:(?:\+|00)86)?1(?:(?:3[\d])|(?:4[5-79])|(?:5[0-35-9])|(?:6[5-7])|(?:7[0-8])|(?:8[\d])|(?:9[189]))\d{8}$/.test(value) === false) { |               if (/^(?:(?:\+|00)86)?1(?:3[\d]|4[5-79]|5[0-35-9]|6[5-7]|7[0-8]|8[\d]|9[189])\d{8}$/.test(value) === false) { | ||||||
|                 callback(new Error("手机号格式错误")); |                 callback(new Error("手机号格式错误")); | ||||||
|               } else { |               } else { | ||||||
|                 callback(); |                 callback(); | ||||||
| @@ -285,7 +285,7 @@ export default { | |||||||
|  |  | ||||||
| .oauth-login { | .oauth-login { | ||||||
|   display: flex; |   display: flex; | ||||||
|   align-items: cen; |   align-items: center; | ||||||
|   cursor:pointer; |   cursor:pointer; | ||||||
| } | } | ||||||
| .oauth-login-item { | .oauth-login-item { | ||||||
|   | |||||||
| @@ -107,7 +107,6 @@ | |||||||
| import { | import { | ||||||
|   createBanner, |   createBanner, | ||||||
|   deleteBanner, |   deleteBanner, | ||||||
|   exportBannerExcel, |  | ||||||
|   getBanner, |   getBanner, | ||||||
|   getBannerPage, |   getBannerPage, | ||||||
|   updateBanner |   updateBanner | ||||||
|   | |||||||
| @@ -98,7 +98,6 @@ | |||||||
| import { | import { | ||||||
|   createProductCategory, |   createProductCategory, | ||||||
|   deleteProductCategory, |   deleteProductCategory, | ||||||
|   exportCategoryExcel, |  | ||||||
|   getProductCategory, |   getProductCategory, | ||||||
|   getProductCategoryList, |   getProductCategoryList, | ||||||
|   updateProductCategory |   updateProductCategory | ||||||
| @@ -106,7 +105,6 @@ import { | |||||||
| import Editor from '@/components/Editor'; | import Editor from '@/components/Editor'; | ||||||
| import Treeselect from "@riophae/vue-treeselect"; | import Treeselect from "@riophae/vue-treeselect"; | ||||||
| import "@riophae/vue-treeselect/dist/vue-treeselect.css"; | import "@riophae/vue-treeselect/dist/vue-treeselect.css"; | ||||||
| import IconSelect from "@/components/IconSelect"; |  | ||||||
| import ImageUpload from '@/components/ImageUpload'; | import ImageUpload from '@/components/ImageUpload'; | ||||||
| import {CommonStatusEnum} from "@/utils/constants"; | import {CommonStatusEnum} from "@/utils/constants"; | ||||||
|  |  | ||||||
|   | |||||||
| @@ -254,7 +254,7 @@ export default { | |||||||
|         }).catch(() => {}); |         }).catch(() => {}); | ||||||
|     }, |     }, | ||||||
|     removePropertyValue(item) { |     removePropertyValue(item) { | ||||||
|       var index = this.form.propertyValueList.indexOf(item) |       const index = this.form.propertyValueList.indexOf(item) | ||||||
|       if (index !== -1) { |       if (index !== -1) { | ||||||
|         this.form.propertyValueList.splice(index, 1) |         this.form.propertyValueList.splice(index, 1) | ||||||
|       } |       } | ||||||
| @@ -266,9 +266,9 @@ export default { | |||||||
|     }, |     }, | ||||||
|     formatList(list) { |     formatList(list) { | ||||||
|       let str = '' |       let str = '' | ||||||
|       for (var i = 0; i < list.length; i++) { |       for (let i = 0; i < list.length; i++) { | ||||||
|         str += list[i].name; |         str += list[i].name; | ||||||
|         if(i != list.length-1){ |         if(i !== list.length-1){ | ||||||
|           str+="/"; |           str+="/"; | ||||||
|         } |         } | ||||||
|       } |       } | ||||||
|   | |||||||
| @@ -67,7 +67,7 @@ | |||||||
|           <!-- 规格明细 --> |           <!-- 规格明细 --> | ||||||
|           <el-form-item label="规格明细"> |           <el-form-item label="规格明细"> | ||||||
|             <el-table :data="ratesForm.rates" border style="width: 100%" ref="ratesTable"> |             <el-table :data="ratesForm.rates" border style="width: 100%" ref="ratesTable"> | ||||||
|               <template v-if="ratesForm.spec == 2"> |               <template v-if="ratesForm.spec === 2"> | ||||||
|                 <el-table-column :key="index" v-for="(item, index) in dynamicSpec.filter(v => v.specName !== undefined)" |                 <el-table-column :key="index" v-for="(item, index) in dynamicSpec.filter(v => v.specName !== undefined)" | ||||||
|                                  :label="item.specName"> |                                  :label="item.specName"> | ||||||
|                   <template v-slot="scope"> |                   <template v-slot="scope"> | ||||||
| @@ -118,13 +118,13 @@ | |||||||
|               <el-table-column label="库存" :render-header="addRedStar" key="95"> |               <el-table-column label="库存" :render-header="addRedStar" key="95"> | ||||||
|                 <template v-slot="scope"> |                 <template v-slot="scope"> | ||||||
|                   <el-form-item :prop="'rates.'+ scope.$index + '.stock'" :rules="[{required: true, trigger: 'change'}]"> |                   <el-form-item :prop="'rates.'+ scope.$index + '.stock'" :rules="[{required: true, trigger: 'change'}]"> | ||||||
|                     <el-input v-model="scope.row.stock" oninput="value=value.replace(/^(0+)|[^\d]+/g,'')"></el-input> |                     <el-input v-model="scope.row.stock" oninput="value=value.replace(/^(0+)|\D+/g,'')"></el-input> | ||||||
|                   </el-form-item> |                   </el-form-item> | ||||||
|                 </template> |                 </template> | ||||||
|               </el-table-column> |               </el-table-column> | ||||||
|               <el-table-column label="预警库存" key="96"> |               <el-table-column label="预警库存" key="96"> | ||||||
|                 <template v-slot="scope"> |                 <template v-slot="scope"> | ||||||
|                   <el-input v-model="scope.row.warnStock" oninput="value=value.replace(/^(0+)|[^\d]+/g,'')"></el-input> |                   <el-input v-model="scope.row.warnStock" oninput="value=value.replace(/^(0+)|\D+/g,'')"></el-input> | ||||||
|                 </template> |                 </template> | ||||||
|               </el-table-column> |               </el-table-column> | ||||||
|               <el-table-column label="体积" key="97"> |               <el-table-column label="体积" key="97"> | ||||||
| @@ -145,8 +145,8 @@ | |||||||
|                <template v-if="ratesForm.spec === 2"> |                <template v-if="ratesForm.spec === 2"> | ||||||
|                 <el-table-column fixed="right" label="操作" width="50" key="100"> |                 <el-table-column fixed="right" label="操作" width="50" key="100"> | ||||||
|                   <template v-slot="scope"> |                   <template v-slot="scope"> | ||||||
|                     <el-button @click="scope.row.status = 1" type="text" size="small" v-show="scope.row.status == undefined || scope.row.status == 0 ">禁用</el-button> |                     <el-button @click="scope.row.status = 1" type="text" size="small" v-show="scope.row.status == 0 ">禁用</el-button> | ||||||
|                     <el-button @click="scope.row.status = 0" type="text" size="small" v-show="scope.row.status == 1">启用</el-button> |                     <el-button @click="scope.row.status = 0" type="text" size="small" v-show="scope.row.status === 1">启用</el-button> | ||||||
|                   </template> |                   </template> | ||||||
|                 </el-table-column> |                 </el-table-column> | ||||||
|               </template> |               </template> | ||||||
| @@ -154,7 +154,7 @@ | |||||||
|           </el-form-item> |           </el-form-item> | ||||||
|           <el-form-item label="虚拟销量" prop="virtualSalesCount"> |           <el-form-item label="虚拟销量" prop="virtualSalesCount"> | ||||||
|             <!-- TODO @Luowenfeng:使用 input 类型即可 --> |             <!-- TODO @Luowenfeng:使用 input 类型即可 --> | ||||||
|             <el-input v-model="baseForm.virtualSalesCount" placeholder="请输入虚拟销量" oninput="value=value.replace(/^(0+)|[^\d]+/g,'')"/> |             <el-input v-model="baseForm.virtualSalesCount" placeholder="请输入虚拟销量" oninput="value=value.replace(/^(0+)|\D+/g,'')"/> | ||||||
|           </el-form-item> |           </el-form-item> | ||||||
|         </el-form> |         </el-form> | ||||||
|       </el-tab-pane> |       </el-tab-pane> | ||||||
| @@ -172,7 +172,7 @@ | |||||||
|       <el-tab-pane label="高级设置" name="fourth"> |       <el-tab-pane label="高级设置" name="fourth"> | ||||||
|         <el-form ref="fourth" :model="baseForm" :rules="rules" label-width="100px" style="width: 95%"> |         <el-form ref="fourth" :model="baseForm" :rules="rules" label-width="100px" style="width: 95%"> | ||||||
|           <el-form-item label="排序字段"> |           <el-form-item label="排序字段"> | ||||||
|             <el-input v-model="baseForm.sort" placeholder="请输入排序字段" oninput="value=value.replace(/^(0+)|[^\d]+/g,'')"/> |             <el-input v-model="baseForm.sort" placeholder="请输入排序字段" oninput="value=value.replace(/^(0+)|\D+/g,'')"/> | ||||||
|           </el-form-item> |           </el-form-item> | ||||||
|            <el-form-item label="是否展示库存" prop="showStock"> |            <el-form-item label="是否展示库存" prop="showStock"> | ||||||
|              <el-radio-group v-model="baseForm.showStock"> |              <el-radio-group v-model="baseForm.showStock"> | ||||||
| @@ -271,7 +271,7 @@ export default { | |||||||
|     this.getListBrand(); |     this.getListBrand(); | ||||||
|     this.getListCategory(); |     this.getListCategory(); | ||||||
|     this.getPropertyPageList(); |     this.getPropertyPageList(); | ||||||
|     if(this.type == 'upd'){ |     if(this.type === 'upd'){ | ||||||
|       this.updateType(this.obj.id) |       this.updateType(this.obj.id) | ||||||
|     } |     } | ||||||
|   }, |   }, | ||||||
| @@ -297,7 +297,7 @@ export default { | |||||||
|     }, |     }, | ||||||
|     changeRadio() { |     changeRadio() { | ||||||
|       this.$refs.ratesTable.doLayout(); |       this.$refs.ratesTable.doLayout(); | ||||||
|       if (this.ratesForm.spec == 1) { |       if (this.ratesForm.spec === 1) { | ||||||
|         this.ratesForm.rates = [{}] |         this.ratesForm.rates = [{}] | ||||||
|       } else { |       } else { | ||||||
|         this.ratesForm.rates = [] |         this.ratesForm.rates = [] | ||||||
| @@ -363,7 +363,7 @@ export default { | |||||||
|       }) |       }) | ||||||
|  |  | ||||||
|       // 动态规格调整字段 |       // 动态规格调整字段 | ||||||
|       if (this.ratesForm.spec == 2) { |       if (this.ratesForm.spec === 2) { | ||||||
|         rates.forEach(r => { |         rates.forEach(r => { | ||||||
|           let properties = [] |           let properties = [] | ||||||
|             Array.of(r.spec).forEach(s => { |             Array.of(r.spec).forEach(s => { | ||||||
| @@ -374,7 +374,7 @@ export default { | |||||||
|                   obj = Array.of(s); |                   obj = Array.of(s); | ||||||
|                } |                } | ||||||
|               obj.forEach((v, i) => { |               obj.forEach((v, i) => { | ||||||
|                 let specValue = this.dynamicSpec[i].specValue.find(o => o.name == v); |                 let specValue = this.dynamicSpec[i].specValue.find(o => o.name === v); | ||||||
|                 let propertie = {}; |                 let propertie = {}; | ||||||
|                 propertie.propertyId = this.dynamicSpec[i].specId; |                 propertie.propertyId = this.dynamicSpec[i].specId; | ||||||
|                 propertie.valueId = specValue.id; |                 propertie.valueId = specValue.id; | ||||||
| @@ -422,9 +422,9 @@ export default { | |||||||
|       }); |       }); | ||||||
|     }, |     }, | ||||||
|     changeSpec(val) { |     changeSpec(val) { | ||||||
|       let obj = this.propertyPageList.find(o => o.id == val); |       let obj = this.propertyPageList.find(o => o.id === val); | ||||||
|       let dynamicSpec = this.dynamicSpec; |       let dynamicSpec = this.dynamicSpec; | ||||||
|       let spec = dynamicSpec.find(o => o.specId == val) |       let spec = dynamicSpec.find(o => o.specId === val) | ||||||
|       spec.specId = obj.id; |       spec.specId = obj.id; | ||||||
|       spec.specName = obj.name; |       spec.specName = obj.name; | ||||||
|       spec.specValue = obj.propertyValueList; |       spec.specValue = obj.propertyValueList; | ||||||
| @@ -451,7 +451,7 @@ export default { | |||||||
|               r.price = this.divide(r.price, 100) |               r.price = this.divide(r.price, 100) | ||||||
|               r.costPrice = this.divide(r.costPrice, 100) |               r.costPrice = this.divide(r.costPrice, 100) | ||||||
|             }) |             }) | ||||||
|             if(this.ratesForm.spec == 2){ |             if(this.ratesForm.spec === 2){ | ||||||
|               data.productPropertyViews.forEach(p=>{ |               data.productPropertyViews.forEach(p=>{ | ||||||
|                 let obj = {}; |                 let obj = {}; | ||||||
|                 obj.specId = p.propertyId; |                 obj.specId = p.propertyId; | ||||||
| @@ -462,7 +462,7 @@ export default { | |||||||
|               data.skus.forEach(s=>{ |               data.skus.forEach(s=>{ | ||||||
|                 s.spec = []; |                 s.spec = []; | ||||||
|                 s.properties.forEach(sp=>{ |                 s.properties.forEach(sp=>{ | ||||||
|                   let spec = data.productPropertyViews.find(o=>o.propertyId == sp.propertyId).propertyValues.find(v=>v.id == sp.valueId).name; |                   let spec = data.productPropertyViews.find(o=>o.propertyId === sp.propertyId).propertyValues.find(v=>v.id === sp.valueId).name; | ||||||
|                    s.spec.push(spec) |                    s.spec.push(spec) | ||||||
|                 }) |                 }) | ||||||
|               }) |               }) | ||||||
| @@ -483,12 +483,10 @@ export default { | |||||||
| .dynamic-spec { | .dynamic-spec { | ||||||
|   background-color: #f2f2f2; |   background-color: #f2f2f2; | ||||||
|   width: 85%; |   width: 85%; | ||||||
|   margin: auto; |   margin: auto auto 10px; | ||||||
|   margin-bottom: 10px; |  | ||||||
|  |  | ||||||
|   .spec-header { |   .spec-header { | ||||||
|     padding: 30px; |     padding: 30px 30px 20px; | ||||||
|     padding-bottom: 20px; |  | ||||||
|  |  | ||||||
|     .spec-name { |     .spec-name { | ||||||
|       display: inline; |       display: inline; | ||||||
| @@ -501,9 +499,8 @@ export default { | |||||||
|  |  | ||||||
|   .spec-values { |   .spec-values { | ||||||
|     width: 84%; |     width: 84%; | ||||||
|     padding: 25px; |  | ||||||
|     margin: auto; |     margin: auto; | ||||||
|     padding-top: 5px; |     padding: 5px 25px 25px; | ||||||
|  |  | ||||||
|     .spec-value { |     .spec-value { | ||||||
|       display: inline-block; |       display: inline-block; | ||||||
|   | |||||||
| @@ -219,7 +219,6 @@ import {getOrder, getOrderPage, exportOrderExcel} from "@/api/pay/order"; | |||||||
| import {getMerchantListByName} from "@/api/pay/merchant"; | import {getMerchantListByName} from "@/api/pay/merchant"; | ||||||
| import {getAppListByMerchantId} from "@/api/pay/app"; | import {getAppListByMerchantId} from "@/api/pay/app"; | ||||||
| import {DICT_TYPE, getDictDatas} from "@/utils/dict"; | import {DICT_TYPE, getDictDatas} from "@/utils/dict"; | ||||||
| import {PayOrderNotifyStatusEnum, PayOrderRefundStatusEnum, PayOrderStatusEnum} from "@/utils/constants"; |  | ||||||
| import { getNowDateTime} from "@/utils/ruoyi"; | import { getNowDateTime} from "@/utils/ruoyi"; | ||||||
|  |  | ||||||
| const defaultOrderDetail = { | const defaultOrderDetail = { | ||||||
|   | |||||||
| @@ -175,7 +175,7 @@ export default { | |||||||
| @import "~@/assets/styles/login.scss"; | @import "~@/assets/styles/login.scss"; | ||||||
| .oauth-login { | .oauth-login { | ||||||
|   display: flex; |   display: flex; | ||||||
|   align-items: cen; |   align-items: center; | ||||||
|   cursor:pointer; |   cursor:pointer; | ||||||
| } | } | ||||||
| .oauth-login-item { | .oauth-login-item { | ||||||
|   | |||||||
| @@ -167,7 +167,7 @@ export default { | |||||||
|         ], |         ], | ||||||
|         phone: [ |         phone: [ | ||||||
|           { |           { | ||||||
|             pattern: /^(?:(?:\+|00)86)?1(?:(?:3[\d])|(?:4[5-79])|(?:5[0-35-9])|(?:6[5-7])|(?:7[0-8])|(?:8[\d])|(?:9[189]))\d{8}$/, |             pattern: /^(?:(?:\+|00)86)?1(?:3[\d]|4[5-79]|5[0-35-9]|6[5-7]|7[0-8]|8[\d]|9[189])\d{8}$/, | ||||||
|             message: "请输入正确的手机号码", |             message: "请输入正确的手机号码", | ||||||
|             trigger: "blur" |             trigger: "blur" | ||||||
|           } |           } | ||||||
|   | |||||||
| @@ -167,7 +167,6 @@ | |||||||
| import { | import { | ||||||
|   addRole, |   addRole, | ||||||
|   changeRoleStatus, |   changeRoleStatus, | ||||||
|   dataScope, |  | ||||||
|   delRole, |   delRole, | ||||||
|   exportRole, |   exportRole, | ||||||
|   getRole, |   getRole, | ||||||
|   | |||||||
| @@ -107,8 +107,7 @@ | |||||||
| </template> | </template> | ||||||
|  |  | ||||||
| <script> | <script> | ||||||
| import { createSmsChannel, updateSmsChannel, deleteSmsChannel, getSmsChannel, getSmsChannelPage, | import { createSmsChannel, updateSmsChannel, deleteSmsChannel, getSmsChannel, getSmsChannelPage } from "@/api/system/sms/smsChannel"; | ||||||
|   getSimpleSmsChannels } from "@/api/system/sms/smsChannel"; |  | ||||||
|  |  | ||||||
| export default { | export default { | ||||||
|   name: "SmsChannel", |   name: "SmsChannel", | ||||||
|   | |||||||
| @@ -91,7 +91,7 @@ | |||||||
|  |  | ||||||
| <script> | <script> | ||||||
| import { createTenantPackage, updateTenantPackage, deleteTenantPackage, getTenantPackage, getTenantPackagePage} from "@/api/system/tenantPackage"; | import { createTenantPackage, updateTenantPackage, deleteTenantPackage, getTenantPackage, getTenantPackagePage} from "@/api/system/tenantPackage"; | ||||||
| import {CommonStatusEnum, SystemMenuTypeEnum} from "@/utils/constants"; | import {CommonStatusEnum} from "@/utils/constants"; | ||||||
| import {listSimpleMenus} from "@/api/system/menu"; | import {listSimpleMenus} from "@/api/system/menu"; | ||||||
|  |  | ||||||
| export default { | export default { | ||||||
|   | |||||||
| @@ -343,7 +343,7 @@ export default { | |||||||
|         ], |         ], | ||||||
|         mobile: [ |         mobile: [ | ||||||
|           { |           { | ||||||
|             pattern: /^(?:(?:\+|00)86)?1(?:(?:3[\d])|(?:4[5-79])|(?:5[0-35-9])|(?:6[5-7])|(?:7[0-8])|(?:8[\d])|(?:9[189]))\d{8}$/, |             pattern: /^(?:(?:\+|00)86)?1(?:3[\d]|4[5-79]|5[0-35-9]|6[5-7]|7[0-8]|8[\d]|9[189])\d{8}$/, | ||||||
|             message: "请输入正确的手机号码", |             message: "请输入正确的手机号码", | ||||||
|             trigger: "blur" |             trigger: "blur" | ||||||
|           } |           } | ||||||
|   | |||||||
| @@ -109,7 +109,7 @@ export default { | |||||||
|     }, |     }, | ||||||
|     // 上传预处理 |     // 上传预处理 | ||||||
|     beforeUpload(file) { |     beforeUpload(file) { | ||||||
|       if (file.type.indexOf("image/") == -1) { |       if (file.type.indexOf("image/") === -1) { | ||||||
|         this.$modal.msgError("文件格式错误,请上传图片类型,如:JPG,PNG后缀的文件。"); |         this.$modal.msgError("文件格式错误,请上传图片类型,如:JPG,PNG后缀的文件。"); | ||||||
|       } else { |       } else { | ||||||
|         const reader = new FileReader(); |         const reader = new FileReader(); | ||||||
|   | |||||||
| @@ -49,7 +49,7 @@ export default { | |||||||
|         mobile: [ |         mobile: [ | ||||||
|           { required: true, message: "手机号码不能为空", trigger: "blur" }, |           { required: true, message: "手机号码不能为空", trigger: "blur" }, | ||||||
|           { |           { | ||||||
|             pattern: /^1[3|4|5|6|7|8|9][0-9]\d{8}$/, |             pattern: /^1[3|456789][0-9]\d{8}$/, | ||||||
|             message: "请输入正确的手机号码", |             message: "请输入正确的手机号码", | ||||||
|             trigger: "blur" |             trigger: "blur" | ||||||
|           } |           } | ||||||
|   | |||||||
| @@ -5504,6 +5504,11 @@ image-size@^0.5.1: | |||||||
|   resolved "https://registry.npmmirror.com/image-size/-/image-size-0.5.5.tgz#09dfd4ab9d20e29eb1c3e80b8990378df9e3cb9c" |   resolved "https://registry.npmmirror.com/image-size/-/image-size-0.5.5.tgz#09dfd4ab9d20e29eb1c3e80b8990378df9e3cb9c" | ||||||
|   integrity sha512-6TDAlDPZxUFCv+fuOkIoXT/V/f3Qbq8e37p+YOiYrUv3v9cc3/6x78VdfPgFVaB9dZYeLUfKgHRebpkm/oP2VQ== |   integrity sha512-6TDAlDPZxUFCv+fuOkIoXT/V/f3Qbq8e37p+YOiYrUv3v9cc3/6x78VdfPgFVaB9dZYeLUfKgHRebpkm/oP2VQ== | ||||||
|  |  | ||||||
|  | immutable@^4.0.0: | ||||||
|  |   version "4.1.0" | ||||||
|  |   resolved "https://registry.npmmirror.com/immutable/-/immutable-4.1.0.tgz#f795787f0db780183307b9eb2091fcac1f6fafef" | ||||||
|  |   integrity sha512-oNkuqVTA8jqG1Q6c+UglTOD1xhC1BtjKI7XkCXRkZHrN5m18/XsnUp8Q89GkQO/z+0WjonSvl0FLhDYftp46nQ== | ||||||
|  |  | ||||||
| import-cwd@^2.0.0: | import-cwd@^2.0.0: | ||||||
|   version "2.1.0" |   version "2.1.0" | ||||||
|   resolved "https://registry.npmmirror.com/import-cwd/-/import-cwd-2.1.0.tgz#aa6cf36e722761285cb371ec6519f53e2435b0a9" |   resolved "https://registry.npmmirror.com/import-cwd/-/import-cwd-2.1.0.tgz#aa6cf36e722761285cb371ec6519f53e2435b0a9" | ||||||
| @@ -8560,23 +8565,22 @@ safe-regex@^1.1.0: | |||||||
|   resolved "https://registry.npmmirror.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" |   resolved "https://registry.npmmirror.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" | ||||||
|   integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== |   integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== | ||||||
|  |  | ||||||
| sass-loader@10.1.1: | sass-loader@13.1.0: | ||||||
|   version "10.1.1" |   version "13.1.0" | ||||||
|   resolved "https://registry.npmmirror.com/sass-loader/-/sass-loader-10.1.1.tgz#4ddd5a3d7638e7949065dd6e9c7c04037f7e663d" |   resolved "https://registry.npmmirror.com/sass-loader/-/sass-loader-13.1.0.tgz#e5b9acf14199a9bc6eaed7a0b8b23951c2cebf6f" | ||||||
|   integrity sha512-W6gVDXAd5hR/WHsPicvZdjAWHBcEJ44UahgxcIE196fW2ong0ZHMPO1kZuI5q0VlvMQZh32gpv69PLWQm70qrw== |   integrity sha512-tZS1RJQ2n2+QNyf3CCAo1H562WjL/5AM6Gi8YcPVVoNxQX8d19mx8E+8fRrMWsyc93ZL6Q8vZDSM0FHVTJaVnQ== | ||||||
|   dependencies: |   dependencies: | ||||||
|     klona "^2.0.4" |     klona "^2.0.4" | ||||||
|     loader-utils "^2.0.0" |  | ||||||
|     neo-async "^2.6.2" |     neo-async "^2.6.2" | ||||||
|     schema-utils "^3.0.0" |  | ||||||
|     semver "^7.3.2" |  | ||||||
|  |  | ||||||
| sass@1.32.13: | sass@1.56.0: | ||||||
|   version "1.32.13" |   version "1.56.0" | ||||||
|   resolved "https://registry.npmmirror.com/sass/-/sass-1.32.13.tgz#8d29c849e625a415bce71609c7cf95e15f74ed00" |   resolved "https://registry.npmmirror.com/sass/-/sass-1.56.0.tgz#134032075a3223c8d49cb5c35e091e5ba1de8e0a" | ||||||
|   integrity sha512-dEgI9nShraqP7cXQH+lEXVf73WOPCse0QlFzSD8k+1TcOxCMwVXfQlr0jtoluZysQOyJGnfr21dLvYKDJq8HkA== |   integrity sha512-WFJ9XrpkcnqZcYuLRJh5qiV6ibQOR4AezleeEjTjMsCocYW59dEG19U3fwTTXxzi2Ed3yjPBp727hbbj53pHFw== | ||||||
|   dependencies: |   dependencies: | ||||||
|     chokidar ">=3.0.0 <4.0.0" |     chokidar ">=3.0.0 <4.0.0" | ||||||
|  |     immutable "^4.0.0" | ||||||
|  |     source-map-js ">=0.6.2 <2.0.0" | ||||||
|  |  | ||||||
| sax@^1.2.4, sax@~1.2.4: | sax@^1.2.4, sax@~1.2.4: | ||||||
|   version "1.2.4" |   version "1.2.4" | ||||||
| @@ -8673,7 +8677,7 @@ semver@^6.0.0, semver@^6.1.0, semver@^6.1.1, semver@^6.1.2, semver@^6.3.0: | |||||||
|   resolved "https://registry.npmmirror.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" |   resolved "https://registry.npmmirror.com/semver/-/semver-6.3.0.tgz#ee0a64c8af5e8ceea67687b133761e1becbd1d3d" | ||||||
|   integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== |   integrity sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw== | ||||||
|  |  | ||||||
| semver@^7.2.1, semver@^7.3.2, semver@^7.3.5, semver@^7.3.6: | semver@^7.2.1, semver@^7.3.5, semver@^7.3.6: | ||||||
|   version "7.3.8" |   version "7.3.8" | ||||||
|   resolved "https://registry.npmmirror.com/semver/-/semver-7.3.8.tgz#07a78feafb3f7b32347d725e33de7e2a2df67798" |   resolved "https://registry.npmmirror.com/semver/-/semver-7.3.8.tgz#07a78feafb3f7b32347d725e33de7e2a2df67798" | ||||||
|   integrity sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A== |   integrity sha512-NB1ctGL5rlHrPJtFDVIVzTyQylMLu9N9VICA6HSFJo8MCGVTMW6gfpicwKmmK/dAjTOrqu5l63JJOpDSrAis3A== | ||||||
| @@ -8933,7 +8937,7 @@ source-list-map@^2.0.0: | |||||||
|   resolved "https://registry.npmmirror.com/source-list-map/-/source-list-map-2.0.1.tgz#3993bd873bfc48479cca9ea3a547835c7c154b34" |   resolved "https://registry.npmmirror.com/source-list-map/-/source-list-map-2.0.1.tgz#3993bd873bfc48479cca9ea3a547835c7c154b34" | ||||||
|   integrity sha512-qnQ7gVMxGNxsiL4lEuJwe/To8UnK7fAnmbGEEH8RpLouuKbeEm0lhbQVFIrNSuB+G7tVrAlVsZgETT5nljf+Iw== |   integrity sha512-qnQ7gVMxGNxsiL4lEuJwe/To8UnK7fAnmbGEEH8RpLouuKbeEm0lhbQVFIrNSuB+G7tVrAlVsZgETT5nljf+Iw== | ||||||
|  |  | ||||||
| source-map-js@^1.0.2: | "source-map-js@>=0.6.2 <2.0.0", source-map-js@^1.0.2: | ||||||
|   version "1.0.2" |   version "1.0.2" | ||||||
|   resolved "https://registry.npmmirror.com/source-map-js/-/source-map-js-1.0.2.tgz#adbc361d9c62df380125e7f161f71c826f1e490c" |   resolved "https://registry.npmmirror.com/source-map-js/-/source-map-js-1.0.2.tgz#adbc361d9c62df380125e7f161f71c826f1e490c" | ||||||
|   integrity sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw== |   integrity sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw== | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 xingyu4j
					xingyu4j