流程发布适应高宽
This commit is contained in:
parent
dbe84f0e9b
commit
bf7e1bb236
@ -641,27 +641,28 @@
|
|||||||
$('#content_zoom').append(Math.round(Designer.config.scale * 100) + "%")
|
$('#content_zoom').append(Math.round(Designer.config.scale * 100) + "%")
|
||||||
var winSize = {
|
var winSize = {
|
||||||
w: $(window).width() - 332,
|
w: $(window).width() - 332,
|
||||||
h: $(window).height() - $('#toolbarName').height() - $('#tools').height() - 41 - 40 - 70 // 41为文件名行高 40为文件属性行高 70为下方评论行高
|
h: $(window).height() - $('#tools').height() - 41 - 40 - 70 // 41为文件名行高 40为最下方功能区域 70为下方评论行高
|
||||||
}
|
}
|
||||||
var designerSize = {
|
var designerSize = {
|
||||||
w: $("#canvas_container").width(),
|
w: $("#canvas_container").width(),
|
||||||
h: $("#canvas_container").height()
|
h: $("#canvas_container").height()
|
||||||
}
|
}
|
||||||
if (designerSize.w <= designerSize.h && designerSize.h > winSize.h) {
|
if (designerSize.w <= designerSize.h && designerSize.h > winSize.h) {
|
||||||
resizeCanvas('height')
|
|
||||||
} else if(designerSize.w > designerSize.h && designerSize.w > winSize.w) {
|
|
||||||
resizeCanvas('width')
|
resizeCanvas('width')
|
||||||
|
} else if(designerSize.w > designerSize.h && designerSize.w > winSize.w) {
|
||||||
|
resizeCanvas('height')
|
||||||
}
|
}
|
||||||
function resizeCanvas(type) {
|
function resizeCanvas(type) {
|
||||||
if (type == 'height') {
|
if (type == 'height') {
|
||||||
if($("#canvas_container").height() <= winSize.h) {
|
console.log(Designer.config.scale)
|
||||||
|
if($("#canvas_container").height() <= winSize.h || Designer.config.scale <= 0.25) {
|
||||||
return
|
return
|
||||||
} else {
|
} else {
|
||||||
canvasresizeMin()
|
canvasresizeMin()
|
||||||
resizeCanvas('height')
|
resizeCanvas('height')
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if($("#canvas_container").width() <= winSize.w) {
|
if($("#canvas_container").width() <= winSize.w || Designer.config.scale <= 0.25) {
|
||||||
return
|
return
|
||||||
} else {
|
} else {
|
||||||
canvasresizeMin()
|
canvasresizeMin()
|
||||||
|
|||||||
@ -1445,6 +1445,7 @@ function isObjectRelationshipModel(linker, isAlert) {
|
|||||||
|
|
||||||
// 文件属性的处理
|
// 文件属性的处理
|
||||||
function initProcessDesc() {
|
function initProcessDesc() {
|
||||||
|
console.log(processDesc)
|
||||||
var length = Object.keys(processDesc).length;
|
var length = Object.keys(processDesc).length;
|
||||||
var t = '';
|
var t = '';
|
||||||
for(var i = 1; i <= length; i++) {
|
for(var i = 1; i <= length; i++) {
|
||||||
@ -1457,13 +1458,18 @@ function initProcessDesc() {
|
|||||||
t += '<td colspan="2" class="tableContent">' + value + '</td>';
|
t += '<td colspan="2" class="tableContent">' + value + '</td>';
|
||||||
t += '</tr>';
|
t += '</tr>';
|
||||||
} else if(obj.type == 'table') {
|
} else if(obj.type == 'table') {
|
||||||
let tableValue = JSON.parse(value.replace(/"/g,'\"'))
|
if(value == '') {
|
||||||
let tableFlag = '请输入'
|
t += '<td colspan="2" class="tableContent">' + value + '</td>';
|
||||||
if (tableValue.table.length > 1) {
|
t += '</tr>';
|
||||||
tableFlag = '请查看'
|
} else {
|
||||||
|
let tableValue = JSON.parse(value.replace(/"/g,'\"'))
|
||||||
|
let tableFlag = '请输入'
|
||||||
|
if (tableValue.table.length > 1) {
|
||||||
|
tableFlag = '请查看'
|
||||||
|
}
|
||||||
|
t += '<td colspan="2" class="tableContent" onclick="openDialog(' + JSON.stringify(tableValue).replace(/\"/g,"'") +')">' + tableFlag + '</td>';
|
||||||
|
t += '</tr>';
|
||||||
}
|
}
|
||||||
t += '<td colspan="2" class="tableContent" onclick="openDialog(' + JSON.stringify(tableValue).replace(/\"/g,"'") +')">' + tableFlag + '</td>';
|
|
||||||
t += '</tr>';
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
value = value.replace(/\n/g,'<br>')
|
value = value.replace(/\n/g,'<br>')
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user