2424 <TabPane name =" code" :label =" $t('message.linkis.executionCode')" ></TabPane >
2525 <!-- <TabPane name="detail" :label="$t('message.linkis.detail')" disabled></TabPane> -->
2626 <TabPane name =" result" :label =" $t('message.linkis.result')" ></TabPane >
27- <TabPane v-show = " hasEngine" name =" engineLog" :label =" $t('message.linkis.engineLog')" ></TabPane >
28- <TabPane v-show = " hasEngine " name =" udfLog" :label =" $t('message.linkis.udfLog')" ></TabPane >
27+ <TabPane :disabled = " ! hasEngine" name =" engineLog" :label =" $t('message.linkis.engineLog')" ></TabPane >
28+ <TabPane :disabled = " !showUDF " name =" udfLog" :label =" $t('message.linkis.udfLog')" ></TabPane >
2929 <TabPane name =" terminal" :label =" $t('message.linkis.diagnosticLog')" ></TabPane >
3030 </Tabs >
3131 <!-- <Button v-if="tabName === 'log' && yarnAddress" class="jumpButton" type="primary" @click="jump">{{$t('message.linkis.jump')}}</Button> -->
5050 :visualParams =" visualParams"
5151 />
5252 <ViewLog ref =" logPanel" :inHistory =" true" v-show =" tabName === 'engineLog' && hasEngine" @back =" showviewlog = false" />
53- <logWithPage ref =" udfLog" logType =" udfLog" v-show =" tabName === 'udfLog' && hasEngine" />
53+ <logWithPage ref =" udfLog" logType =" udfLog" v-show =" tabName === 'udfLog' && showUDF && hasEngine" />
5454
5555 <term ref =" termRef" v-if =" tabName === 'terminal'" :logs =" termLogs" :script-view-state =" scriptViewState" :loading =" termLogLoading" />
5656 </div >
@@ -124,6 +124,7 @@ export default {
124124 yarnAddress: ' ' ,
125125 logTimer: null ,
126126 preName: ' log' ,
127+ showUDF: false ,
127128 }
128129 },
129130 created () {
@@ -137,6 +138,7 @@ export default {
137138 async mounted () {
138139 let taskID = this .$route .query .taskID
139140 let engineInstance = this .$route .query .engineInstance
141+
140142 const engineLogOnlyAdminEnable = storage .get (' engineLogOnlyAdminEnable' )
141143 // 仅管理员可以查看引擎日志
142144 const isAdminShowEngineLog = ! engineLogOnlyAdminEnable || (engineLogOnlyAdminEnable && (storage .get (' isLogAdmin' ) || storage .get (' isLogHistoryAdmin' ) || storage .get (' isLogDeptAdmin' )))
@@ -153,6 +155,7 @@ export default {
153155 this .hasEngine = !! param;
154156
155157 }
158+ this .showUDF = [' spark' , ' hive' ].includes (this .param .engineType )
156159 await this .initHistory (taskID);
157160 const node = document .getElementsByClassName (' global-history' )[0 ];
158161 this .scriptViewState .bottomContentHeight = node .clientHeight - 85 ;
0 commit comments