diff --git a/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue b/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue index ca201efe18..59629c6dff 100644 --- a/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue +++ b/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue @@ -359,6 +359,9 @@ :old-enable-cookie-share="enableCookieShare" :old-on-sample-error="onSampleError" :project-list="projectList" + :new-create-time="newCreateTime" + :old-create-time="oldCreateTime" + :old-user-name="oldUserName" :type="type"/> @@ -556,6 +559,9 @@ export default { }, ], reloadTree: "", + newCreateTime:0, + oldCreateTime:0, + oldUserName:'' } }, created() { @@ -1977,6 +1983,9 @@ export default { compare(row) { this.scenarioRefId = this.currentScenario.refId; this.dffScenarioId = row.id; + this.newCreateTime = row.createTime + this.oldUserName = this.currentScenario.userName + this.oldCreateTime = this.$refs.versionHistory.versionOptions.filter(v => v.id === this.currentScenario.versionId)[0].createTime; this.dialogVisible = true; }, closeDiff() { diff --git a/frontend/src/business/components/api/automation/version/ScenarioChildDiff.vue b/frontend/src/business/components/api/automation/version/ScenarioChildDiff.vue index 51b866cefb..0cb85f0943 100644 --- a/frontend/src/business/components/api/automation/version/ScenarioChildDiff.vue +++ b/frontend/src/business/components/api/automation/version/ScenarioChildDiff.vue @@ -4,6 +4,7 @@ 当前{{ oldData.versionName }} - {{ oldData.userName }}{{ oldData.createTime | timestampFormatDate }} + {{ oldUserName }}{{ oldCreateTime | timestampFormatDate }} {{ newData.versionName }} - {{ newData.userName }}{{ newData.createTime | timestampFormatDate }} + {{ newData.userName }}{{ newCreateTime | timestampFormatDate }}
@@ -150,6 +150,7 @@ v.id === this.basisData.versionId)[0].createTime; this.$get('/api/definition/get/' + row.id+"/"+this.basisData.refId, response => { this.$get('/api/definition/get/' + response.data.id, res => { if (res.data) { this.newData = res.data; + this.newData.createTime = row.createTime; this.dealWithTag(res.data); this.setRequest(res.data) if (!this.setRequest(res.data)) { diff --git a/frontend/src/business/components/api/definition/components/complete/EditCompleteHTTPApi.vue b/frontend/src/business/components/api/definition/components/complete/EditCompleteHTTPApi.vue index 73b200f7b4..87aa6b7ceb 100644 --- a/frontend/src/business/components/api/definition/components/complete/EditCompleteHTTPApi.vue +++ b/frontend/src/business/components/api/definition/components/complete/EditCompleteHTTPApi.vue @@ -569,10 +569,12 @@ export default { }); }, compare(row) { + this.httpForm.createTime = this.$refs.versionHistory.versionOptions.filter(v => v.id === this.httpForm.versionId)[0].createTime; this.$get('/api/definition/get/' + row.id + "/" + this.httpForm.refId, response => { this.$get('/api/definition/get/' + response.data.id, res => { if (res.data) { this.newData = res.data; + this.newData.createTime = row.createTime; this.dealWithTag(res.data); this.setRequest(res.data); if (!this.setRequest(res.data)) { diff --git a/frontend/src/business/components/api/definition/components/complete/EditCompleteSQLApi.vue b/frontend/src/business/components/api/definition/components/complete/EditCompleteSQLApi.vue index a4cd8cf586..746dd041ba 100644 --- a/frontend/src/business/components/api/definition/components/complete/EditCompleteSQLApi.vue +++ b/frontend/src/business/components/api/definition/components/complete/EditCompleteSQLApi.vue @@ -249,10 +249,12 @@ export default { }); }, compare(row) { + this.basisData.createTime = this.$refs.versionHistory.versionOptions.filter(v => v.id === this.basisData.versionId)[0].createTime; this.$get('/api/definition/get/' + row.id+"/"+this.basisData.refId, response => { this.$get('/api/definition/get/' + response.data.id, res => { if (res.data) { this.newData = res.data; + this.newData.createTime = row.createTime; this.dealWithTag(res.data); this.setRequest(res.data) if (!this.setRequest(res.data)) { diff --git a/frontend/src/business/components/api/definition/components/complete/EditCompleteTCPApi.vue b/frontend/src/business/components/api/definition/components/complete/EditCompleteTCPApi.vue index 4d7b1981b8..d69bb75795 100644 --- a/frontend/src/business/components/api/definition/components/complete/EditCompleteTCPApi.vue +++ b/frontend/src/business/components/api/definition/components/complete/EditCompleteTCPApi.vue @@ -370,10 +370,12 @@ export default { }); }, compare(row) { + this.basisData.createTime = this.$refs.versionHistory.versionOptions.filter(v => v.id === this.basisData.versionId)[0].createTime; this.$get('/api/definition/get/' + row.id+"/"+this.basisData.refId, response => { this.$get('/api/definition/get/' + response.data.id, res => { if (res.data) { this.newData = res.data; + this.newData.createTime = row.createTime; if (this.newData.method !== 'TCP' && this.newData.method !== 'ESB') { this.newData.method = this.newData.protocol; } diff --git a/frontend/src/business/components/performance/test/EditPerformanceTest.vue b/frontend/src/business/components/performance/test/EditPerformanceTest.vue index c2ac2220b0..eea502d494 100644 --- a/frontend/src/business/components/performance/test/EditPerformanceTest.vue +++ b/frontend/src/business/components/performance/test/EditPerformanceTest.vue @@ -561,10 +561,12 @@ export default { }, compare(row) { this.oldData = this.test; + this.oldData.createTime = this.$refs.versionHistory.versionOptions.filter(v => v.id === this.test.versionId)[0].createTime; this.$get('/performance/get/' + row.id + "/" + this.test.refId, response => { this.$get('/performance/get/' + response.data.id, res => { if (res.data) { this.newData = res.data; + this.newData.createTime = row.createTime; this.$get('/performance/test/follow/' + response.data.id, resp => { if (resp.data && resp.data.follows) { for (let i = 0; i < resp.data.follows.length; i++) { diff --git a/frontend/src/business/components/track/case/components/TestCaseEdit.vue b/frontend/src/business/components/track/case/components/TestCaseEdit.vue index c30e13b254..7c8140a925 100644 --- a/frontend/src/business/components/track/case/components/TestCaseEdit.vue +++ b/frontend/src/business/components/track/case/components/TestCaseEdit.vue @@ -948,6 +948,8 @@ export default { if (data[0] && data[1]) { that.newData = data[0].data.data; that.oldData = data[1].data.data; + that.newData.createTime = row.createTime; + that.oldData.createTime = this.$refs.versionHistory.versionOptions.filter(v => v.id === that.oldData.versionId)[0].createTime; let testCase = that.versionData.filter(v => v.versionId === this.currentTestCaseInfo.versionId)[0]; that.newData.versionName = that.versionData.filter(v => v.id === that.newData.id)[0].versionName; that.oldData.versionName = that.versionData.filter(v => v.id === that.oldData.id)[0].versionName; diff --git a/frontend/src/business/components/track/case/version/TestCaseVersionDiff.vue b/frontend/src/business/components/track/case/version/TestCaseVersionDiff.vue index 225053e505..e5890d07ed 100644 --- a/frontend/src/business/components/track/case/version/TestCaseVersionDiff.vue +++ b/frontend/src/business/components/track/case/version/TestCaseVersionDiff.vue @@ -331,10 +331,10 @@ export default { let vnode = this.$refs.new let oldColor = ""; let newColor = ""; - if(this.oldData.createTime>this.newData.createTime){ + if(this.oldData.createTime > this.newData.createTime) { oldColor = "rgb(121, 225, 153,0.3)"; newColor = "rgb(241,200,196,0.45)" - }else{ + } else { oldColor = "rgb(241,200,196,0.45)" newColor = "rgb(121, 225, 153,0.3)"; }