更新
This commit is contained in:
parent
2021b8b076
commit
e2c12e3fd8
@ -2,7 +2,7 @@
|
||||
* @Author: zwq
|
||||
* @Date: 2021-11-15 08:20:28
|
||||
* @LastEditors: zwq
|
||||
* @LastEditTime: 2022-07-07 09:48:49
|
||||
* @LastEditTime: 2022-08-11 16:22:10
|
||||
* @Description:
|
||||
*/
|
||||
/**
|
||||
@ -40,7 +40,8 @@ const mainRoutes = {
|
||||
// 2. iframeUrl: 是否通过iframe嵌套展示内容, '以http[s]://开头': 是, '': 否
|
||||
// 提示: 如需要通过iframe嵌套展示内容, 但不通过tab打开, 请自行创建组件使用iframe处理!
|
||||
{ path: '/home', component: _import('common/home'), name: 'home', meta: { title: '首页', isTab: true } },
|
||||
{ path: '/orderProcess', component: _import('common/order-process'), name: 'orderProcess', meta: { title: '订单加工', isTab: true } },
|
||||
{ path: '/Problem', component: _import('common/Problem'), name: 'Problem', meta: { title: '常见问题汇总', isTab: true } },
|
||||
{ path: '/orderProcess', component: _import('common/order-process'), name: 'orderProcess', meta: { title: '单步骤任务', isTab: true } },
|
||||
{ path: '/orderAuto', component: _import('common/order-auto'), name: 'orderAuto', meta: { title: '自动任务', isTab: true } },
|
||||
{ path: '/exWarehouse', component: _import('common/ex-warehouse'), name: 'exWarehouse', meta: { title: '货物出库', isTab: true } },
|
||||
{ path: '/addProcess', component: _import('common/add-process'), name: 'addProcess', meta: { title: '追加加工', isTab: true } },
|
||||
@ -60,6 +61,7 @@ const mainRoutes = {
|
||||
{ path: '/report-kiln-alarm', component: _import('report/kiln-alarm'), name: 'report-kiln-alarm', meta: { title: '工业炉报警', isTab: true } },
|
||||
{ path: '/report-car-alarm', component: _import('report/car-alarm'), name: 'report-car-alarm', meta: { title: '车辆运行报警', isTab: true } },
|
||||
{ path: '/report-order-history', component: _import('report/order-history'), name: 'report-order-history', meta: { title: '订单历史列表', isTab: true } },
|
||||
{ path: '/report-APMS-work', component: _import('report/APMS-work'), name: 'report-APMS-work', meta: { title: 'APMS报工', isTab: true } },
|
||||
{ path: '/report-order-history-task', component: _import('report/components/order-history-task'), name: 'report-order-history-task', meta: { title: '订单历史任务详情', isTab: true } },
|
||||
{ path: '/report-task-history', component: _import('report/task-history'), name: 'report-task-history', meta: { title: '执行任务历史列表', isTab: true } },
|
||||
{ path: '/report-task-history-detail', component: _import('report/components/task-history-detail'), name: 'report-task-history-detail', meta: { title: '执行任务历史详情', isTab: true } },
|
||||
|
96
src/views/common/Problem-add.vue
Normal file
96
src/views/common/Problem-add.vue
Normal file
@ -0,0 +1,96 @@
|
||||
<!--
|
||||
* @Author: zwq
|
||||
* @Date: 2021-11-18 14:16:25
|
||||
* @LastEditors: zwq
|
||||
* @LastEditTime: 2022-08-11 16:51:45
|
||||
* @Description:
|
||||
-->
|
||||
<template>
|
||||
<el-dialog title="新增" :visible.sync="visible">
|
||||
<el-form
|
||||
:model="dataForm"
|
||||
:rules="dataRule"
|
||||
ref="dataForm"
|
||||
@keyup.enter.native="dataFormSubmit()"
|
||||
label-width="80px"
|
||||
>
|
||||
<el-form-item label="问题" prop="question">
|
||||
<el-input
|
||||
type="textarea"
|
||||
:rows="3"
|
||||
v-model="dataForm.question"
|
||||
placeholder="问题"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="解答" prop="answer">
|
||||
<el-input
|
||||
type="textarea"
|
||||
:rows="5"
|
||||
v-model="dataForm.answer"
|
||||
placeholder="解答"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button @click="visible = false">取消</el-button>
|
||||
<el-button type="primary" @click="dataFormSubmit()">确定</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
data () {
|
||||
return {
|
||||
visible: false,
|
||||
dataForm: {
|
||||
question: '',
|
||||
answer: ''
|
||||
},
|
||||
dataRule: {
|
||||
question: [
|
||||
{ required: true, message: '问题不能为空', trigger: 'blur' }
|
||||
],
|
||||
answer: [{ required: true, message: '解答不能为空', trigger: 'blur' }]
|
||||
}
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
init () {
|
||||
this.visible = true
|
||||
this.$nextTick(() => {
|
||||
this.$refs['dataForm'].resetFields()
|
||||
})
|
||||
},
|
||||
// 表单提交
|
||||
dataFormSubmit () {
|
||||
this.$refs['dataForm'].validate(valid => {
|
||||
if (valid) {
|
||||
this.$http({
|
||||
url: this.$http.adornUrl('/questionAnswer/add'),
|
||||
method: 'post',
|
||||
data: this.$http.adornData({
|
||||
question: this.dataForm.question,
|
||||
answer: this.dataForm.answer
|
||||
})
|
||||
}).then(({ data }) => {
|
||||
if (data && data.code === 0) {
|
||||
this.$message({
|
||||
message: '操作成功',
|
||||
type: 'success',
|
||||
duration: 1500,
|
||||
onClose: () => {
|
||||
this.visible = false
|
||||
this.$emit('refreshDataList')
|
||||
}
|
||||
})
|
||||
} else {
|
||||
this.$message.error(data.msg)
|
||||
}
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
106
src/views/common/Problem.vue
Normal file
106
src/views/common/Problem.vue
Normal file
@ -0,0 +1,106 @@
|
||||
<!--
|
||||
* @Author: zwq
|
||||
* @Date: 2022-08-11 16:22:07
|
||||
* @LastEditors: zwq
|
||||
* @LastEditTime: 2022-08-11 16:48:39
|
||||
* @Description:
|
||||
-->
|
||||
<template>
|
||||
<div class="mod-config">
|
||||
<el-form
|
||||
:inline="true"
|
||||
style="display: flex; align-items: center; justify-content: right;"
|
||||
@keyup.enter.native="getDataList()"
|
||||
>
|
||||
<el-form-item>
|
||||
<el-input
|
||||
size="small"
|
||||
v-model="key"
|
||||
placeholder="搜索问题"
|
||||
clearable
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button size="small" @click="getDataList()">
|
||||
<icon-svg class="iconClass" name="sousuo"></icon-svg>
|
||||
查询
|
||||
</el-button>
|
||||
<el-button size="small" type="primary" @click="addOrUpdateHandle()">
|
||||
<icon-svg class="iconClass" name="新建"></icon-svg>
|
||||
新增
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<el-collapse v-model="activeNames">
|
||||
<el-collapse-item
|
||||
v-for="(item, index) in problemArr"
|
||||
:key="index"
|
||||
:name="index"
|
||||
>
|
||||
<template slot="title">
|
||||
<span style="color:#409EFF">
|
||||
{{ item.question }}<i class="el-icon-question"></i>
|
||||
</span>
|
||||
</template>
|
||||
<div>
|
||||
{{ item.answer }}
|
||||
</div>
|
||||
</el-collapse-item>
|
||||
</el-collapse>
|
||||
<!-- 弹窗, 新增 / 修改 -->
|
||||
<problem-add
|
||||
v-if="addOrUpdateVisible"
|
||||
ref="addOrUpdate"
|
||||
@refreshDataList="getDataList"
|
||||
></problem-add>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import ProblemAdd from './Problem-add'
|
||||
export default {
|
||||
data () {
|
||||
return {
|
||||
key: '',
|
||||
addOrUpdateVisible: false,
|
||||
activeNames: [],
|
||||
problemArr: []
|
||||
}
|
||||
},
|
||||
components: {
|
||||
ProblemAdd
|
||||
},
|
||||
created () {
|
||||
this.getDataList()
|
||||
},
|
||||
methods: {
|
||||
getDataList () {
|
||||
this.$http({
|
||||
url: this.$http.adornUrl('/questionAnswer/page'),
|
||||
method: 'post',
|
||||
data: this.$http.adornData({
|
||||
current: 1,
|
||||
size: 200,
|
||||
key: this.key
|
||||
// paramKey: this.dataForm.paramKey
|
||||
})
|
||||
}).then(({ data }) => {
|
||||
if (data && data.code === 0) {
|
||||
this.problemArr = data.data.records
|
||||
} else {
|
||||
this.problemArr = []
|
||||
}
|
||||
})
|
||||
},
|
||||
// 新增
|
||||
addOrUpdateHandle () {
|
||||
this.addOrUpdateVisible = true
|
||||
this.$nextTick(() => {
|
||||
this.$refs.addOrUpdate.init()
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style></style>
|
@ -2,14 +2,14 @@
|
||||
* @Author: gtz
|
||||
* @Date: 2022-03-04 10:22:13
|
||||
* @LastEditors: zwq
|
||||
* @LastEditTime: 2022-07-13 10:11:05
|
||||
* @LastEditTime: 2022-08-05 09:05:08
|
||||
* @Description: file content
|
||||
* @FilePath: \mt-qj-wms-ui\src\views\common\order-auto-submit.vue
|
||||
-->
|
||||
|
||||
<template>
|
||||
<el-dialog
|
||||
:title="!row ? '新增' : '修改'"
|
||||
title="提交任务"
|
||||
:close-on-click-modal="false"
|
||||
:visible.sync="visible">
|
||||
<el-form :model="dataForm" v-loading="formLoading" :rules="dataRule" ref="dataForm" label-width="120px">
|
||||
@ -140,7 +140,6 @@
|
||||
},
|
||||
dataList: [],
|
||||
formLoading: false,
|
||||
row: null,
|
||||
editIndex: null,
|
||||
processDis: {
|
||||
secProcess: false,
|
||||
|
144
src/views/common/order-process-submit.vue
Normal file
144
src/views/common/order-process-submit.vue
Normal file
@ -0,0 +1,144 @@
|
||||
<!--
|
||||
* @Author: gtz
|
||||
* @Date: 2022-03-04 10:22:13
|
||||
* @LastEditors: zwq
|
||||
* @LastEditTime: 2022-08-05 09:29:56
|
||||
* @Description: file content
|
||||
* @FilePath: \mt-qj-wms-ui\src\views\common\order-auto-submit.vue
|
||||
-->
|
||||
|
||||
<template>
|
||||
<el-dialog
|
||||
title="提交任务"
|
||||
:visible.sync="visible">
|
||||
<el-form :model="dataForm" v-loading="formLoading" :rules="dataRule" ref="dataForm" label-width="120px">
|
||||
<el-form-item label="加工类型" prop="processType">
|
||||
<el-select v-model="dataForm.processType" size="small" placeholder="加工类型" clearable>
|
||||
<el-option :value="0" label="初始加工" />
|
||||
<el-option :value="1" label="复加工" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="加工起点" prop="startPosition" style="margin-bottom: 24px">
|
||||
<el-select v-model="dataForm.startPosition" size="small" placeholder="任务起点位置" clearable>
|
||||
<el-option value="YYT001" label="液压台1" />
|
||||
<el-option value="YYT002" label="液压台2" />
|
||||
<el-option value="YYT003" label="液压台3" />
|
||||
<el-option value="YYT004" label="液压台4" />
|
||||
</el-select>
|
||||
<!-- <el-button style="margin-left:10px" type="primary" @click="getPoint(0)">{{startPosition}}</el-button> -->
|
||||
</el-form-item>
|
||||
<el-form-item label="加工炉" prop="kilnId" style="margin-bottom: 24px">
|
||||
<el-select v-model="dataForm.kilnId" size="small" @change="handleChange($event)" placeholder="加工炉" clearable>
|
||||
<el-option v-for="item in kilnList" :key="item.id" :value="item.id" :label="item.kilnName" />
|
||||
</el-select>
|
||||
<!-- <el-button style="margin-left:10px" type="primary" @click="getPoint(1)">{{kilnId}}</el-button> -->
|
||||
</el-form-item>
|
||||
<el-form-item label="工艺" prop="craftCode" style="margin-bottom: 24px">
|
||||
<el-select v-model="dataForm.craftCode" placeholder="工艺">
|
||||
<el-option v-for="item in processList" :key="item.id" :value="item.code" :label="item.craftCode" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button @click="visible = false">取消</el-button>
|
||||
<el-button type="primary" :loading="btnLoad" @click="dataFormSubmit()">确定</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
props: {
|
||||
kilnList: {
|
||||
type: Array,
|
||||
default: () => []
|
||||
},
|
||||
processList: {
|
||||
type: Array,
|
||||
default: () => []
|
||||
}
|
||||
},
|
||||
data () {
|
||||
return {
|
||||
visible: false,
|
||||
btnLoad: false,
|
||||
dataForm: {
|
||||
craftCode: null,
|
||||
processType: null,
|
||||
startPosition: null,
|
||||
kilnId: null
|
||||
},
|
||||
dataRule: {
|
||||
craftCode: [
|
||||
{ required: true, message: '工艺不能为空', trigger: 'blur' }
|
||||
],
|
||||
processType: [
|
||||
{ required: true, message: '加工类型不能为空', trigger: 'blur' }
|
||||
],
|
||||
startPosition: [
|
||||
{ required: true, message: '加工起点不能为空', trigger: 'blur' }
|
||||
],
|
||||
kilnId: [
|
||||
{ required: true, message: '工业炉不能为空', trigger: 'blur' }
|
||||
]
|
||||
},
|
||||
dataList: [],
|
||||
formLoading: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
handleChange (e) {
|
||||
this.dataForm.craftCode = null
|
||||
this.kilnList.find(item => {
|
||||
if (item.id === e) {
|
||||
if (item.type === 4) {
|
||||
this.dataForm.craftCode = 1
|
||||
}
|
||||
}
|
||||
}
|
||||
)
|
||||
},
|
||||
init (list) {
|
||||
this.dataList.splice(0, this.dataList.length)
|
||||
this.dataList = list
|
||||
this.btnLoad = false
|
||||
this.visible = true
|
||||
this.$nextTick(() => {
|
||||
this.$refs['dataForm'].resetFields()
|
||||
})
|
||||
},
|
||||
// 表单提交
|
||||
dataFormSubmit () {
|
||||
this.$refs['dataForm'].validate((valid) => {
|
||||
if (valid) {
|
||||
this.btnLoad = true
|
||||
this.$http({
|
||||
url: this.$http.adornUrl(`/currTask/createProcessTask`),
|
||||
method: 'post',
|
||||
data: this.$http.adornData({
|
||||
craftCode: this.dataForm.craftCode,
|
||||
detParams: this.dataList,
|
||||
kilnId: this.dataForm.kilnId,
|
||||
processType: this.dataForm.processType,
|
||||
startPosition: this.dataForm.startPosition,
|
||||
targetPosition: this.dataForm.kilnId
|
||||
// this.targetPosition
|
||||
})
|
||||
}).then(({data}) => {
|
||||
if (data && data.code === 0) {
|
||||
this.$message.success('任务提交成功')
|
||||
this.btnLoad = false
|
||||
this.visible = false
|
||||
sessionStorage.setItem('taskList', '')
|
||||
this.$emit('refreshDataList')
|
||||
} else {
|
||||
this.btnLoad = false
|
||||
this.$message.warning(data.msg)
|
||||
}
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
@ -7,34 +7,8 @@
|
||||
新增
|
||||
</el-button>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-select v-model="processType" size="small" placeholder="加工类型" clearable>
|
||||
<el-option :value="0" label="初始加工" />
|
||||
<el-option :value="1" label="复加工" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item style="margin-left:1%">
|
||||
<el-select v-model="startPosition" size="small" placeholder="任务起点位置" clearable>
|
||||
<el-option value="YYT001" label="液压台1" />
|
||||
<el-option value="YYT002" label="液压台2" />
|
||||
<el-option value="YYT003" label="液压台3" />
|
||||
<el-option value="YYT004" label="液压台4" />
|
||||
</el-select>
|
||||
<!-- <el-button style="margin-left:10px" type="primary" @click="getPoint(0)">{{startPosition}}</el-button> -->
|
||||
</el-form-item>
|
||||
<el-form-item style="margin-left:1%">
|
||||
<el-select v-model="kilnId" size="small" placeholder="工业炉" clearable>
|
||||
<el-option v-for="item in eqList" :key="item.id" :value="item.id" :label="item.kilnName" />
|
||||
</el-select>
|
||||
<!-- <el-button style="margin-left:10px" type="primary" @click="getPoint(1)">{{kilnId}}</el-button> -->
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-select v-model="craftCode" placeholder="工艺">
|
||||
<el-option v-for="item in processList" :key="item.id" :value="item.code" :label="item.craftCode" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item style="margin-left:1%">
|
||||
<el-button type="primary" size="small" :loading="btnLoad" @click="submitTask()">提交任务</el-button>
|
||||
<el-button type="primary" size="small" @click="submitTask()">提交任务</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<el-table
|
||||
@ -110,22 +84,24 @@
|
||||
</el-table>
|
||||
<!-- 弹窗, 新增 / 修改 -->
|
||||
<add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="getDataList"></add-or-update>
|
||||
<submit-form v-if="submitFormVisible" ref="submitForm" :kilnList="eqList" :processList="processList" @refreshDataList="getDataList" />
|
||||
<process-point v-if="processPointVisible" ref="processPoint" @refreshPoint="setPoint"></process-point>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import AddOrUpdate from './order-process-add'
|
||||
import SubmitForm from './order-process-submit'
|
||||
import ProcessPoint from './order-process-point'
|
||||
export default {
|
||||
data () {
|
||||
return {
|
||||
btnLoad: false,
|
||||
startPosition: '',
|
||||
kilnId: '',
|
||||
craftCode: '',
|
||||
targetPosition: '',
|
||||
dataList: [],
|
||||
submitFormVisible: false,
|
||||
processType: null,
|
||||
dataListLoading: false,
|
||||
addOrUpdateVisible: false,
|
||||
@ -136,7 +112,8 @@
|
||||
},
|
||||
components: {
|
||||
AddOrUpdate,
|
||||
ProcessPoint
|
||||
ProcessPoint,
|
||||
SubmitForm
|
||||
},
|
||||
activated () {
|
||||
this.getEqList()
|
||||
@ -207,62 +184,13 @@
|
||||
}
|
||||
},
|
||||
submitTask () {
|
||||
if (this.dataList.length === 0) {
|
||||
this.$message({
|
||||
message: '任务为空,请新增一条托盘信息',
|
||||
type: 'warning'
|
||||
if (this.dataList.length) {
|
||||
this.submitFormVisible = true
|
||||
this.$nextTick(() => {
|
||||
this.$refs.submitForm.init(this.dataList)
|
||||
})
|
||||
} else if (!this.startPosition) {
|
||||
this.$message({
|
||||
message: '请选择任务起点',
|
||||
type: 'warning'
|
||||
})
|
||||
} else if (!this.kilnId) {
|
||||
this.$message({
|
||||
message: '请选择工业炉',
|
||||
type: 'warning'
|
||||
})
|
||||
} else if (!this.craftCode) {
|
||||
this.$message({
|
||||
message: '请选择工艺',
|
||||
type: 'warning'
|
||||
})
|
||||
} else if (this.processType !== 0 && this.processType !== 1) {
|
||||
this.$message.warning('请选择加工类型')
|
||||
} else {
|
||||
this.btnLoad = true
|
||||
this.$confirm(`确定提交任务?`, '提示', {
|
||||
confirmButtonText: '确定',
|
||||
cancelButtonText: '取消',
|
||||
type: 'warning'
|
||||
}).then(() => {
|
||||
this.$http({
|
||||
url: this.$http.adornUrl(`/currTask/createProcessTask`),
|
||||
method: 'post',
|
||||
data: this.$http.adornData({
|
||||
craftCode: this.craftCode,
|
||||
detParams: this.dataList,
|
||||
kilnId: this.kilnId,
|
||||
processType: this.processType,
|
||||
startPosition: this.startPosition,
|
||||
targetPosition: this.kilnId
|
||||
// this.targetPosition
|
||||
})
|
||||
}).then(({data}) => {
|
||||
if (data && data.code === 0) {
|
||||
this.$message.success('任务提交成功')
|
||||
this.btnLoad = false
|
||||
this.dataList = []
|
||||
sessionStorage.setItem('taskList', '')
|
||||
this.startPosition = '选择起点'
|
||||
this.kilnId = '选择工业炉'
|
||||
this.targetPosition = null
|
||||
} else {
|
||||
this.btnLoad = false
|
||||
this.$message.warning(data.msg)
|
||||
}
|
||||
})
|
||||
}).catch(() => {})
|
||||
this.$message.warning('请至少添加一条任务!')
|
||||
}
|
||||
},
|
||||
// 删除
|
||||
|
@ -34,7 +34,7 @@
|
||||
@click="$router.push({ name: 'orderProcess' })"
|
||||
>
|
||||
<icon-svg name="tubiao" class="site-sidebar__menu-icon"></icon-svg>
|
||||
<span slot="title">订单加工</span>
|
||||
<span slot="title">单步骤任务</span>
|
||||
</el-menu-item>
|
||||
<el-menu-item
|
||||
index="exWarehouse"
|
||||
@ -332,7 +332,18 @@
|
||||
<icon-svg name="job" class="site-sidebar__menu-icon"></icon-svg>
|
||||
<span slot="title">执行任务历史列表</span>
|
||||
</el-menu-item>
|
||||
<el-menu-item
|
||||
index="report-APMS-work"
|
||||
@click="$router.push({ name: 'report-APMS-work' })"
|
||||
>
|
||||
<icon-svg name="job" class="site-sidebar__menu-icon"></icon-svg>
|
||||
<span slot="title">APMS报工</span>
|
||||
</el-menu-item>
|
||||
</el-submenu>
|
||||
<el-menu-item index="Problem" @click="$router.push({ name: 'Problem' })">
|
||||
<icon-svg name="log" class="site-sidebar__menu-icon"></icon-svg>
|
||||
<span slot="title">常见问题汇总</span>
|
||||
</el-menu-item>
|
||||
<!-- <sub-menu
|
||||
v-for="menu in menuList"
|
||||
:key="menu.menuId"
|
||||
|
@ -1,5 +1,9 @@
|
||||
<template>
|
||||
<div class="mod-config">
|
||||
<div style="margin-bottom:10px;float:right">
|
||||
<el-tag type="success">加工中</el-tag>
|
||||
<el-tag type="warning">缓存中</el-tag>
|
||||
</div>
|
||||
<!-- <el-form style="display: flex; align-items: center; justify-content: right;" :inline="true" :model="dataForm" @keyup.enter.native="getDataList()">
|
||||
<el-form-item>
|
||||
<el-select size="small" v-model="dataForm.vehicleId" filterable placeholder="车辆名称">
|
||||
@ -19,12 +23,12 @@
|
||||
</el-form> -->
|
||||
<el-table
|
||||
:data="dataList"
|
||||
:stripe="true"
|
||||
:header-cell-style="{
|
||||
background: '#eef1f6',
|
||||
color: '#606266',
|
||||
height: '56px'
|
||||
}"
|
||||
:row-class-name="tableRowClassName"
|
||||
v-loading="dataListLoading"
|
||||
style="width: 100%;"
|
||||
>
|
||||
@ -64,11 +68,7 @@
|
||||
</el-table-column>
|
||||
<el-table-column prop="isAuto" label="多步骤">
|
||||
<template slot-scope="scope">
|
||||
<span>{{
|
||||
scope.row.isAuto === 1
|
||||
? "是"
|
||||
: "否"
|
||||
}}</span>
|
||||
<span>{{ scope.row.isAuto === 1 ? "是" : "否" }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="craftCodeId" label="工艺"> </el-table-column>
|
||||
@ -121,7 +121,7 @@
|
||||
content="执行"
|
||||
placement="top"
|
||||
>
|
||||
<icon-svg class="iconClass" name="维护开始"></icon-svg>
|
||||
<icon-svg class="iconClass" name="维护开始"></icon-svg>
|
||||
</el-tooltip>
|
||||
</el-button>
|
||||
<el-button
|
||||
@ -147,7 +147,7 @@
|
||||
@size-change="sizeChangeHandle"
|
||||
@current-change="currentChangeHandle"
|
||||
:current-page="pageIndex"
|
||||
:page-sizes="[10, 20, 50, 100]"
|
||||
:page-sizes="[10, 20, 30, 50, 100]"
|
||||
:page-size="pageSize"
|
||||
:total="totalPage"
|
||||
layout="total, sizes, prev, pager, next, jumper"
|
||||
@ -174,7 +174,7 @@ export default {
|
||||
dataList: [],
|
||||
options: [],
|
||||
pageIndex: 1,
|
||||
pageSize: 10,
|
||||
pageSize: 30,
|
||||
totalPage: 0,
|
||||
dataListLoading: false,
|
||||
statusList,
|
||||
@ -317,6 +317,14 @@ export default {
|
||||
})
|
||||
})
|
||||
.catch(() => {})
|
||||
},
|
||||
tableRowClassName ({ row, rowIndex }) {
|
||||
if (row.status === 1) {
|
||||
return 'success-row'
|
||||
} else if (row.isCache === 1) {
|
||||
return 'warning-row'
|
||||
}
|
||||
return ''
|
||||
}
|
||||
},
|
||||
beforeDestroy () {
|
||||
@ -324,3 +332,13 @@ export default {
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
.el-table .warning-row {
|
||||
background-color: oldlace;
|
||||
}
|
||||
|
||||
.el-table .success-row {
|
||||
background-color: #f0f9eb;
|
||||
}
|
||||
</style>
|
||||
|
310
src/views/report/APMS-work.vue
Normal file
310
src/views/report/APMS-work.vue
Normal file
@ -0,0 +1,310 @@
|
||||
<template>
|
||||
<div class="mod-config">
|
||||
<el-button type="primary" @click="submit()" size="small">提交</el-button>
|
||||
<el-form
|
||||
ref="dataForm"
|
||||
:model="dataForm"
|
||||
:rules="rules"
|
||||
size="medium"
|
||||
label-width="110px"
|
||||
>
|
||||
<div>
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="8">
|
||||
<el-form-item label="开始加工时间" prop="startTime">
|
||||
<el-date-picker
|
||||
v-model="dataForm.startTime"
|
||||
value-format="yyyy-MM-dd HH:mm:ss"
|
||||
:style="{ width: '100%' }"
|
||||
type="datetime"
|
||||
placeholder="请选择开始加工时间"
|
||||
clearable
|
||||
></el-date-picker>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="账号" prop="startUser">
|
||||
<el-input
|
||||
v-model="dataForm.startUser"
|
||||
placeholder="请输入账号"
|
||||
readonly
|
||||
prefix-icon="el-icon-user-solid"
|
||||
:style="{ width: '100%' }"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="配炉号" prop="stoveCode">
|
||||
<el-select
|
||||
v-model="dataForm.stoveCode"
|
||||
:style="{ width: '100%' }"
|
||||
filterable
|
||||
placeholder="请选择配炉号"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in stoveCodeArr"
|
||||
:key="item.id"
|
||||
:label="item.code"
|
||||
:value="item.code"
|
||||
>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="车间编码" prop="workShopCode">
|
||||
<el-input
|
||||
v-model="dataForm.workShopCode"
|
||||
placeholder="请输入车间编码"
|
||||
readonly
|
||||
:style="{ width: '100%' }"
|
||||
>
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="工艺号" prop="techCode">
|
||||
<el-select
|
||||
v-model="dataForm.techCode"
|
||||
:style="{ width: '100%' }"
|
||||
filterable
|
||||
placeholder="请选择工艺号"
|
||||
>
|
||||
<el-option
|
||||
v-for="item in techCodeArr"
|
||||
:key="item.id"
|
||||
:label="item.craftCode"
|
||||
:value="item.craftCode"
|
||||
>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="炉号备注" prop="stoveRemark">
|
||||
<el-input
|
||||
v-model="dataForm.stoveRemark"
|
||||
placeholder="请输入炉号备注"
|
||||
clearable
|
||||
:style="{ width: '100%' }"
|
||||
>
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="备注" prop="remark">
|
||||
<el-input
|
||||
v-model="dataForm.remark"
|
||||
placeholder="请输入备注"
|
||||
clearable
|
||||
:style="{ width: '100%' }"
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
<el-card class="box-card">
|
||||
<div slot="header" class="clearfix">
|
||||
<span>生产单</span>
|
||||
<el-tooltip effect="dark" content="新增" placement="top">
|
||||
<el-button
|
||||
style="float: right; padding: 0px;color:#409EFF;font-size:20px;border:none"
|
||||
icon="el-icon-circle-plus"
|
||||
@click="itemsPlus()"
|
||||
></el-button>
|
||||
</el-tooltip>
|
||||
</div>
|
||||
<div v-for="(item, index) in dataForm.items" :key="index">
|
||||
<el-row :gutter="20">
|
||||
<el-col :span="1">
|
||||
<el-tooltip effect="dark" content="删除" placement="top">
|
||||
<el-button
|
||||
style="color:red"
|
||||
icon="el-icon-delete"
|
||||
@click="itemsDelete(index)"
|
||||
></el-button>
|
||||
</el-tooltip>
|
||||
</el-col>
|
||||
<el-col :span="7">
|
||||
<el-form-item label="标识卡号" prop="itemCode">
|
||||
<el-input
|
||||
v-model="item.itemCode"
|
||||
placeholder="请输入标识卡号"
|
||||
clearable
|
||||
:style="{ width: '100%' }"
|
||||
>
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="加工数量" prop="quantity">
|
||||
<el-input-number
|
||||
v-model="item.quantity"
|
||||
placeholder="加工数量"
|
||||
:step="1"
|
||||
></el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="加工重量" prop="weight">
|
||||
<el-input-number
|
||||
v-model="item.weight"
|
||||
placeholder="加工重量"
|
||||
:step="1"
|
||||
></el-input-number>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
</div>
|
||||
</el-card>
|
||||
</el-form>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
components: {},
|
||||
props: [],
|
||||
data () {
|
||||
return {
|
||||
stoveCodeArr: [],
|
||||
techCodeArr: [],
|
||||
dataForm: {
|
||||
startTime: null,
|
||||
startUser: 'QJJP03',
|
||||
stoveCode: undefined,
|
||||
workShopCode: 'BM',
|
||||
techCode: undefined,
|
||||
stoveRemark: undefined,
|
||||
remark: undefined,
|
||||
items: [
|
||||
{
|
||||
itemCode: undefined,
|
||||
quantity: 0,
|
||||
weight: 0
|
||||
}
|
||||
]
|
||||
},
|
||||
rules: {
|
||||
startTime: [
|
||||
{
|
||||
required: true,
|
||||
message: '请选择开始加工时间',
|
||||
trigger: 'change'
|
||||
}
|
||||
],
|
||||
startUser: [
|
||||
{
|
||||
required: true,
|
||||
message: '请输入账号',
|
||||
trigger: 'blur'
|
||||
}
|
||||
],
|
||||
stoveCode: [
|
||||
{
|
||||
required: true,
|
||||
message: '请输入配炉号',
|
||||
trigger: 'blur'
|
||||
}
|
||||
],
|
||||
workShopCode: [
|
||||
{
|
||||
required: true,
|
||||
message: '请输入车间编码',
|
||||
trigger: 'blur'
|
||||
}
|
||||
],
|
||||
techCode: [],
|
||||
stoveRemark: [],
|
||||
remark: [],
|
||||
itemCode: []
|
||||
}
|
||||
}
|
||||
},
|
||||
created () {
|
||||
this.init()
|
||||
},
|
||||
methods: {
|
||||
init () {
|
||||
this.$http({
|
||||
url: this.$http.adornUrl('/kilnInfo/page'),
|
||||
method: 'post',
|
||||
data: this.$http.adornData({
|
||||
current: 1,
|
||||
size: 200
|
||||
// paramKey: this.dataForm.paramKey
|
||||
})
|
||||
}).then(({ data }) => {
|
||||
if (data && data.code === 0) {
|
||||
this.stoveCodeArr = data.data.records
|
||||
} else {
|
||||
this.stoveCodeArr = []
|
||||
}
|
||||
})
|
||||
this.$http({
|
||||
url: this.$http.adornUrl('/craftInfo/page'),
|
||||
method: 'post',
|
||||
data: this.$http.adornData({
|
||||
current: 1,
|
||||
size: 200
|
||||
// paramKey: this.dataForm.paramKey
|
||||
})
|
||||
}).then(({ data }) => {
|
||||
if (data && data.code === 0) {
|
||||
this.techCodeArr = data.data.records
|
||||
} else {
|
||||
this.techCodeArr = []
|
||||
}
|
||||
})
|
||||
},
|
||||
itemsPlus () {
|
||||
const obj = {
|
||||
itemCode: undefined,
|
||||
quantity: 0,
|
||||
weight: 0
|
||||
}
|
||||
this.dataForm.items.push(obj)
|
||||
},
|
||||
itemsDelete (index) {
|
||||
this.dataForm.items.splice(index, 1)
|
||||
},
|
||||
submit () {
|
||||
this.$refs['dataForm'].validate(valid => {
|
||||
if (valid) {
|
||||
let scheck = true
|
||||
this.dataForm.items.find(item => {
|
||||
if (!item.itemCode) {
|
||||
scheck = false
|
||||
}
|
||||
})
|
||||
if (scheck) {
|
||||
this.$http({
|
||||
url: this.$http.adornUrl('/apms/createProcessSheet'),
|
||||
method: 'post',
|
||||
data: this.$http.adornData(this.dataForm)
|
||||
}).then(({ data }) => {
|
||||
if (data && data.code === 0) {
|
||||
this.$message({
|
||||
message: '操作成功',
|
||||
type: 'success',
|
||||
duration: 3000,
|
||||
onClose: () => {
|
||||
this.$refs['dataForm'].resetFields()
|
||||
this.dataForm.items.splice(0, this.dataForm.items.length)
|
||||
this.itemsPlus()
|
||||
}
|
||||
})
|
||||
} else {
|
||||
this.$message.error(data.msg)
|
||||
}
|
||||
})
|
||||
} else {
|
||||
this.$message.info('请填写完整生产单')
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
<style scoped></style>
|
256
src/views/report/components/task-history-result.vue
Normal file
256
src/views/report/components/task-history-result.vue
Normal file
@ -0,0 +1,256 @@
|
||||
<!--
|
||||
* @Author: zwq
|
||||
* @Date: 2022-07-29 09:56:45
|
||||
* @LastEditors: zwq
|
||||
* @LastEditTime: 2022-07-29 11:23:47
|
||||
* @Description:
|
||||
-->
|
||||
<template>
|
||||
<el-dialog
|
||||
title="检验结果"
|
||||
:visible.sync="visible"
|
||||
width="85%"
|
||||
>
|
||||
<el-table
|
||||
:data="dataList"
|
||||
border
|
||||
v-loading="dataListLoading"
|
||||
style="width: 100%;"
|
||||
>
|
||||
<el-table-column
|
||||
prop="createTime"
|
||||
header-align="center"
|
||||
align="center"
|
||||
width="95"
|
||||
label="添加时间"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.createTime ? scope.row.createTime.replace('T', ' ') : '' }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="sheetNo"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="生产单号"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="idenCardNum"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="标识卡号"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="hardness"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="硬度检验"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="metallography"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="金相检验"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="heartHardness"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="心部硬度"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="remake"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="备注"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
header-align="center"
|
||||
label="硬度检验">
|
||||
<el-table-column
|
||||
prop="hardnessValueOne"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="结果1"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="hardnessValueTwo"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="结果2"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="hardnessValueThree"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="结果3"
|
||||
>
|
||||
</el-table-column>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
header-align="center"
|
||||
label="金相检验渗碳淬火">
|
||||
<el-table-column
|
||||
prop="metallographyStchStccsd"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="渗碳层深度"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="metallographyStchMstost"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="表面为马氏体、残余奥氏体(级)"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="metallographyStchXxklzthw"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="细小颗粒状碳化物"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="metallographyStchDtmstyltst"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="心部为低碳马氏体加游离铁素体(级)"
|
||||
>
|
||||
</el-table-column>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
header-align="center"
|
||||
label="金相检验整体淬火">
|
||||
<el-table-column
|
||||
prop="metallographyZtchHhmst"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="基体为回火马氏体(级)"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="metallographyZtchHhtst"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="基体为回火托式体(级)"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="metallographyXchHhsst"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="基体为回火素式体(级)"
|
||||
>
|
||||
</el-table-column>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
header-align="center"
|
||||
label="金相检验氮化">
|
||||
<el-table-column
|
||||
prop="metallographyDhDhhwcs"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="表面亮白色的为氮化合物层深"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="metallographyDhKscs"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="向内为扩散层深"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="metallographyDhXb"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="心部"
|
||||
>
|
||||
</el-table-column>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
header-align="center"
|
||||
label="金相检验表面淬火">
|
||||
<el-table-column
|
||||
prop="metallographyBmchBtmst"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="表面为板条马氏体(级)"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="metallographyBmchXb"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="心部"
|
||||
>
|
||||
</el-table-column>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
header-align="center"
|
||||
label="金相检验">
|
||||
<el-table-column
|
||||
prop="metallographyBz"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="备注"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="metallographyXbydXbydjyjg"
|
||||
header-align="center"
|
||||
align="center"
|
||||
label="心部硬度"
|
||||
>
|
||||
</el-table-column>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-dialog>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
data () {
|
||||
return {
|
||||
visible: false,
|
||||
sheetNo: '',
|
||||
dataList: [],
|
||||
dataListLoading: false
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
init (sheetNo) {
|
||||
this.sheetNo = sheetNo || ''
|
||||
this.visible = true
|
||||
this.getDataList()
|
||||
},
|
||||
// 获取数据列表
|
||||
getDataList () {
|
||||
this.dataListLoading = true
|
||||
this.$http({
|
||||
url: this.$http.adornUrl('/electric/checkResultList'),
|
||||
method: 'post',
|
||||
data: this.$http.adornData(
|
||||
{sheetNo: this.sheetNo}
|
||||
)
|
||||
}).then(({ data }) => {
|
||||
if (data) {
|
||||
this.dataList = data
|
||||
} else {
|
||||
this.dataList = []
|
||||
}
|
||||
this.dataListLoading = false
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
@ -108,7 +108,17 @@
|
||||
<!-- <el-table-column
|
||||
prop="vehicleName"
|
||||
label="车辆名称"
|
||||
> -->
|
||||
>
|
||||
</el-table-column> -->
|
||||
<el-table-column
|
||||
fixed="right"
|
||||
header-align="center"
|
||||
align="center"
|
||||
width="80"
|
||||
label="检验">
|
||||
<template slot-scope="scope">
|
||||
<el-button type="text" size="small" @click="checkResult(scope.row.sheetNo)">检验结果</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
fixed="right"
|
||||
@ -117,7 +127,7 @@
|
||||
width="80"
|
||||
label="能耗情况">
|
||||
<template slot-scope="scope">
|
||||
<el-button type="text" size="small" @click="eleHandle(scope.row.id)">详情</el-button>
|
||||
<el-button type="text" size="small" @click="eleHandle(scope.row.taskId)">详情</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
@ -128,7 +138,7 @@
|
||||
label="订单详情"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
<el-button type="text" size="small" @click="LocationBtn(scope.row.id)"
|
||||
<el-button type="text" size="small" @click="LocationBtn(scope.row.taskId)"
|
||||
>订单详情</el-button
|
||||
>
|
||||
</template>
|
||||
@ -144,10 +154,12 @@
|
||||
layout="total, sizes, prev, pager, next, jumper"
|
||||
>
|
||||
</el-pagination>
|
||||
<task-history-result v-if="taskHistoryResultVisible" ref="addOrUpdate" @refreshDataList="getDataList"></task-history-result>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import taskHistoryResult from './components/task-history-result'
|
||||
// 任务状态列表
|
||||
const statusList = {
|
||||
0: '等待执行',
|
||||
@ -163,6 +175,7 @@ export default {
|
||||
vehicleId: '',
|
||||
time: []
|
||||
},
|
||||
taskHistoryResultVisible: false,
|
||||
dataList: [],
|
||||
options2: [],
|
||||
pageIndex: 1,
|
||||
@ -173,6 +186,9 @@ export default {
|
||||
statusList
|
||||
}
|
||||
},
|
||||
components: {
|
||||
taskHistoryResult
|
||||
},
|
||||
activated () {
|
||||
this.getDataList()
|
||||
},
|
||||
@ -227,6 +243,12 @@ export default {
|
||||
name: 'report-task-ele',
|
||||
query: { taskId }
|
||||
})
|
||||
},
|
||||
checkResult (sheetNo) {
|
||||
this.taskHistoryResultVisible = true
|
||||
this.$nextTick(() => {
|
||||
this.$refs.addOrUpdate.init(sheetNo)
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user