Browse Source

fix: 解决allowEdit为false时允许上传图片的问题

master
菜猫子neko 4 years ago
parent
commit
76194a38c0
  1. 7
      src/controllers/handler.js

7
src/controllers/handler.js

@ -45,7 +45,7 @@ import {
mouseposition mouseposition
} from '../global/location'; } from '../global/location';
import { rowlenByRange } from '../global/getRowlen'; import { rowlenByRange } from '../global/getRowlen';
import { isRealNull, hasPartMC, isEditMode } from '../global/validate'; import { isRealNull, hasPartMC, isEditMode, checkIsAllowEdit } from '../global/validate';
import { countfunc } from '../global/count'; import { countfunc } from '../global/count';
import browser from '../global/browser'; import browser from '../global/browser';
import formula from '../global/formula'; import formula from '../global/formula';
@ -4863,6 +4863,11 @@ export default function luckysheetHandler() {
//菜单栏 插入图片按钮 //菜单栏 插入图片按钮
$("#luckysheet-insertImg-btn-title").click(function () { $("#luckysheet-insertImg-btn-title").click(function () {
// *如果禁止前台编辑,则中止下一步操作
if (!checkIsAllowEdit()) {
tooltip.info("", locale().pivotTable.errorNotAllowEdit);
return
}
if(!checkProtectionAuthorityNormal(Store.currentSheetIndex, "editObjects")){ if(!checkProtectionAuthorityNormal(Store.currentSheetIndex, "editObjects")){
return; return;
} }

Loading…
Cancel
Save