|
@@ -39,6 +39,7 @@
|
|
@click.native="handleEditClick(scope.row, scope.$index)"
|
|
@click.native="handleEditClick(scope.row, scope.$index)"
|
|
/>
|
|
/>
|
|
</div>
|
|
</div>
|
|
|
|
+
|
|
<el-input
|
|
<el-input
|
|
v-else
|
|
v-else
|
|
v-model="scope.row.indexNum"
|
|
v-model="scope.row.indexNum"
|
|
@@ -46,7 +47,7 @@
|
|
style="width: 60px"
|
|
style="width: 60px"
|
|
type="number"
|
|
type="number"
|
|
@blur="onNumberBlur(scope.row, scope.$index)"
|
|
@blur="onNumberBlur(scope.row, scope.$index)"
|
|
- @keyup.enter.native="onNumberBlur(scope.row, scope.$index)"
|
|
|
|
|
|
+ @keyup.enter.native="onNumberBlurEnter(scope.row, scope.$index)"
|
|
placeholder="序号"
|
|
placeholder="序号"
|
|
ref="numberInput"
|
|
ref="numberInput"
|
|
/>
|
|
/>
|
|
@@ -312,6 +313,7 @@
|
|
<script>
|
|
<script>
|
|
import {
|
|
import {
|
|
change,
|
|
change,
|
|
|
|
+ channeledit,
|
|
channels,
|
|
channels,
|
|
classEdit,
|
|
classEdit,
|
|
classRemove,
|
|
classRemove,
|
|
@@ -436,6 +438,10 @@ export default {
|
|
});
|
|
});
|
|
},
|
|
},
|
|
|
|
|
|
|
|
+ onNumberBlurEnter(row, index) {
|
|
|
|
+ this.editData.currentEditIndex = -1;
|
|
|
|
+ },
|
|
|
|
+
|
|
// 输入框失去焦点时隐藏
|
|
// 输入框失去焦点时隐藏
|
|
onNumberBlur(row, index) {
|
|
onNumberBlur(row, index) {
|
|
var newSort = row.indexNum;
|
|
var newSort = row.indexNum;
|
|
@@ -467,7 +473,8 @@ export default {
|
|
}
|
|
}
|
|
this.editData.currentEditIndex = -1;
|
|
this.editData.currentEditIndex = -1;
|
|
|
|
|
|
- // channeledit(this.dialogForm).then((res) => {
|
|
|
|
|
|
+ // channeledit(this.tableData).then((res) => {
|
|
|
|
+ // console.log("编辑成功:", JSON.stringify(res));
|
|
// if (res.code === 0) {
|
|
// if (res.code === 0) {
|
|
// this.$message.success("编辑成功!");
|
|
// this.$message.success("编辑成功!");
|
|
// this.getList();
|
|
// this.getList();
|