Browse Source

发布者

master
maochaoying 2 years ago
parent
commit
1dbc9dc946
  1. 20
      .env
  2. 6
      src/api/task.js
  3. 14
      src/components/Nuclear.vue
  4. 6
      src/components/Publish.vue
  5. 9
      src/components/Task.vue
  6. 16
      src/pages/index.vue

20
.env

@ -5,14 +5,14 @@
# VITE_HOST_URL=http://192.168.1.194:8081/
# VITE_BASE_URL=http://127.0.0.1:8899
# VITE_WEBSOCKET_JAVA_URL=ws://127.0.0.1:8899/websocket/nuclear
# # VITE_WEBSOCKET_CAMERA_URL=ws://127.0.0.1:8899/websocket/nuclear
# VITE_WEBSOCKET_CAMERA_URL=ws://127.0.0.1:8081/ws/cmd
# VITE_HOST_URL=http://127.0.0.1:8081/
VITE_BASE_URL=http://192.168.1.111:8899
VITE_WEBSOCKET_JAVA_URL=ws://192.168.1.111:8899/websocket/nuclear
VITE_BASE_URL=http://127.0.0.1:8899
VITE_WEBSOCKET_JAVA_URL=ws://127.0.0.1:8899/websocket/nuclear
# VITE_WEBSOCKET_CAMERA_URL=ws://127.0.0.1:8899/websocket/nuclear
VITE_WEBSOCKET_CAMERA_URL=ws://192.168.1.111:8081/ws/cmd
VITE_HOST_URL=http://192.168.1.111:8081/
VITE_WEBSOCKET_CAMERA_URL=ws://127.0.0.1:8081/ws/cmd
VITE_HOST_URL=http://127.0.0.1:8081/
# VITE_BASE_URL=http://192.168.1.111:8899
# VITE_WEBSOCKET_JAVA_URL=ws://192.168.1.111:8899/websocket/nuclear
# # VITE_WEBSOCKET_CAMERA_URL=ws://127.0.0.1:8899/websocket/nuclear
# VITE_WEBSOCKET_CAMERA_URL=ws://192.168.1.111:8081/ws/cmd
# VITE_HOST_URL=http://192.168.1.111:8081/

6
src/api/task.js

@ -1,10 +1,14 @@
import request from '@/service'
import Cookie from '@/utils/cookie'
export const createTaskApi = data => {
return request({
url: '/task/create',
method: 'POST',
data,
data: {
...data,
publishedId: Cookie.getCookie('u'),
},
})
}

14
src/components/Nuclear.vue

@ -58,16 +58,16 @@
/>
</div>
</t-tab-panel>
<t-tab-panel value="second" label="核芯堆信息管理">
<t-tab-panel value="second" label="堆芯信息管理">
<div style="padding: 25px">
<t-button
theme="primary"
style="margin-bottom: 25px"
@click="coreVisible = true"
>新增核芯堆</t-button
>新增堆芯</t-button
>
<t-dialog
header="新增核芯堆"
header="新增堆芯"
:visible="coreVisible"
:footer="false"
:onClose="coreClose"
@ -184,6 +184,14 @@ export default {
trigger: 'blur',
},
],
stationId: [
{
required: true,
message: '所属核电站不能为空',
type: 'error',
trigger: 'blur',
},
],
},
tabValue: 'first',
stationVisible: false,

6
src/components/Publish.vue

@ -41,13 +41,13 @@
</t-option>
</t-select>
</t-form-item>
<t-form-item label="核芯堆" name="nuclearCoreId">
<t-form-item label="堆芯" name="nuclearCoreId">
<t-select
v-model="formData.nuclearCoreId"
class="demo-select-base"
clearable
filterable
placeholder="请选择所在核芯堆"
placeholder="请选择所在堆芯"
>
<t-option
v-for="item in coreList"
@ -108,7 +108,7 @@ export default {
pubRules: {
taskName: [{ required: true, message: '请填写任务名称' }],
operatorId: [{ required: true, message: '请选择要分配的操作员' }],
nuclearCoreId: [{ required: true, message: '请选择核芯堆' }],
nuclearCoreId: [{ required: true, message: '请选择堆芯' }],
nuclearStationId: [{ required: true, message: '请选择核电站' }],
checkOrder: [{ required: true, message: '核查路径顺序必填' }],
},

9
src/components/Task.vue

@ -160,6 +160,11 @@ export default {
width: 130,
},
{
colKey: 'publishedId',
title: '发布者',
width: 130,
},
{
colKey: 'publishTime',
title: '发布时间',
width: 190,
@ -441,6 +446,8 @@ export default {
if (res?.code == 200) {
this.pathVisible = false
this.$message.success('设置成功')
// list
this.getTaskList()
}
},
showPathDialog(taskId) {
@ -622,7 +629,7 @@ export default {
<style lang="scss">
.task_component {
height: 100vh;
height: 90vh;
overflow: scroll;
}
.process_table_btn {

16
src/pages/index.vue

@ -444,13 +444,13 @@ const nickname = computed(() => {
})
const clickLogo = () => {
//
imageStore.reset()
taskStore.updateCurrentDetailTaskId(null)
accountStore.changePage(0)
//
taskStore.updateType(0)
getInitData()
// //
// imageStore.reset()
// taskStore.updateCurrentDetailTaskId(null)
// accountStore.changePage(0)
// //
// taskStore.updateType(0)
// getInitData()
}
const getInitData = async () => {
@ -490,7 +490,7 @@ const clickTaskTab = () => {
const logout = () => {
accountStore.clearLoginInfo()
Cookie.clearAllCookie()
window.location.href = '/login'
window.location.href = '/#/login'
}
const getSocketdata = res => {

Loading…
Cancel
Save