禁用
This commit is contained in:
@@ -7,19 +7,8 @@
|
||||
<div style="margin-left: 43%;margin-top: 20px;font-weight: bold;font-size: 24px">不合格原因</div>
|
||||
</el-row>
|
||||
<el-button size="small" type="warning" icon="el-icon-circle-plus-outline" plain style="margin-left: 80%;margin-top: 15px" @click="handleAdd1()">新增</el-button>
|
||||
<el-table
|
||||
:data="tableData"
|
||||
border
|
||||
style="width: 100%;max-height: 450px;margin-top: 10px"
|
||||
height="350px"
|
||||
size="mini"
|
||||
stripe
|
||||
highlight-current-row>
|
||||
<el-table-column
|
||||
type="index"
|
||||
label="序号"
|
||||
align="center"
|
||||
width="50"/>
|
||||
<el-table :data="tableData" border style="width: 100%;max-height: 450px;margin-top: 10px" height="350px" size="mini" stripe highlight-current-row>
|
||||
<el-table-column type="index" label="序号" align="center" width="50"/>
|
||||
<el-table-column label="不合格原因" align="center">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.不合格原因文本 }}
|
||||
@@ -27,11 +16,7 @@
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" align="center" fixed="right" width="70px">
|
||||
<template slot-scope="scope">
|
||||
<el-button
|
||||
size="mini"
|
||||
type="text"
|
||||
icon="el-icon-delete"
|
||||
@click="handleDelete(scope.row)"/>
|
||||
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"/>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
@@ -247,17 +232,20 @@
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button @click="dialogFormVisible=false">取消</el-button>
|
||||
<el-button type="primary" @click="submitAdd()">确定</el-button>
|
||||
<el-button :disabled="disable" type="primary" @click="submitAdd()">确定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>import { initReasons, initHandle, initSize, initAppearance, initPosition, initTest, initTesting, addReasons, addHandle, addSize, addAppearance, addPosition,
|
||||
<script>
|
||||
import { initReasons, initHandle, initSize, initAppearance, initPosition, initTest, initTesting, addReasons, addHandle, addSize, addAppearance, addPosition,
|
||||
addTest, addTesting, deleteReasons, deleteHandle, deleteSize, deleteAppearance, deletePosition, deleteTest, deleteTesting } from '@/api/Assembly/QualityBasicData'
|
||||
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
disable: false,
|
||||
tableData: [],
|
||||
tableData1: [],
|
||||
tableData2: [],
|
||||
@@ -329,33 +317,41 @@ export default {
|
||||
},
|
||||
handleAdd1() {
|
||||
this.title = '增加不合格原因'
|
||||
this.disable = false
|
||||
this.dialogFormVisible = true
|
||||
},
|
||||
handleAdd2() {
|
||||
this.title = '增加不合格处理'
|
||||
this.disable = false
|
||||
this.dialogFormVisible = true
|
||||
},
|
||||
handleAdd3() {
|
||||
this.title = '增加质检尺寸'
|
||||
this.disable = false
|
||||
this.dialogFormVisible = true
|
||||
},
|
||||
handleAdd4() {
|
||||
this.title = '增加质检外观'
|
||||
this.disable = false
|
||||
this.dialogFormVisible = true
|
||||
},
|
||||
handleAdd5() {
|
||||
this.title = '增加质检形位'
|
||||
this.disable = false
|
||||
this.dialogFormVisible = true
|
||||
},
|
||||
handleAdd6() {
|
||||
this.title = '增加检测项'
|
||||
this.disable = false
|
||||
this.dialogFormVisible = true
|
||||
},
|
||||
handleAdd7() {
|
||||
this.title = '增加检测项明细'
|
||||
this.disable = false
|
||||
this.dialogFormVisible = true
|
||||
},
|
||||
submitAdd() {
|
||||
this.disable = true
|
||||
if (this.title === '增加不合格原因') {
|
||||
addReasons(this.Reasons).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
|
||||
@@ -589,11 +589,7 @@
|
||||
</el-row>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button
|
||||
type="primary"
|
||||
size="small"
|
||||
icon="el-icon-check"
|
||||
@click="submitTable">确定</el-button>
|
||||
<el-button :disabled="AddTableData_disable" type="primary" size="small" icon="el-icon-check" @click="submitTable">确定</el-button>
|
||||
</div>
|
||||
</el-dialog>
|
||||
</div>
|
||||
@@ -770,6 +766,7 @@ export default {
|
||||
this.groupNumber = []
|
||||
this.procedureNum = []
|
||||
this.operators = []
|
||||
this.AddTableData_disable = false
|
||||
this.dialogFormVisible10 = true
|
||||
},
|
||||
formatJson(filterVal, jsonData) {
|
||||
@@ -876,6 +873,7 @@ export default {
|
||||
submitTable() {
|
||||
this.$refs['form2'].validate((valid) => {
|
||||
if (valid) {
|
||||
this.AddTableData_disable = true
|
||||
submitTable(this.form2.工序, this.form2.质检类型, this.form2.检测数, this.form2.质检情况, this.id, this.form2.不合格数量, this.form2.不合格原因, this.form2.不合格处理, this.form2.备注, this.form2.操作工).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.dialogFormVisible10 = false
|
||||
|
||||
Reference in New Issue
Block a user