浏览代码

Update bootstrap-table-editable.js

linting issues
Oleksii Kuznietsov 2 年之前
父节点
当前提交
8df0f9c0b4
共有 1 个文件被更改,包括 6 次插入5 次删除
  1. 6 5
      src/extensions/editable/bootstrap-table-editable.js

+ 6 - 5
src/extensions/editable/bootstrap-table-editable.js

@@ -78,14 +78,15 @@ $.BootstrapTable = class extends $.BootstrapTable {
 
         const editableOpts = Utils.calculateObjectValue(column,
           column.editable, [index, row], {})
-        const noEditFormatter = editableOpts.hasOwnProperty("noEditFormatter") &&
-                                editableOpts.noEditFormatter(value, row, index, field);
+        const noEditFormatter = editableOpts.hasOwnProperty('noEditFormatter') &&
+                                editableOpts.noEditFormatter(value, row, index, field)
 
         if (noEditFormatter) {
-            return noEditFormatter
+          return noEditFormatter
         }
 
-        let editableDataMarkup = ""
+        let editableDataMarkup = ''
+
         $.each(editableOptions, (key, value) => {
           editableDataMarkup += ` ${key}="${value}"`
         })
@@ -93,7 +94,7 @@ $.BootstrapTable = class extends $.BootstrapTable {
         return `<a href="javascript:void(0)"
           data-name="${column.field}"
           data-pk="${row[this.options.idField]}"
-          data-value="${value || ""}"
+          data-value="${value || ''}"
           ${editableDataMarkup}>${result}</a>` // expand all data-editable-XXX
       }
     })