apps/com.actionsoft.apps.coe.pal/method/data.form/diagram.schema.tpl

69 lines
2.7 KiB
Smarty

/**
* Data shapes
*/
Schema.addCategory({
name: "data_form",
text: "表单图",
dataAttributes: []
});
/* Form*/
Schema.addShape({name:"form", title:"表单",text:"表单", category:"data_form", props:{w:100, h:70},
anchors:[
{x:"w*0.5", y:"0"},
{x:"w", y:"h*0.5"},
{x:"w*0.5", y:"h-Math.min(Math.min(w,h)/8,w/12)"},
{x:"0", y:"h*0.5"}
], textBlock:{x:"0", y:"0", w:"w", h:"h*0.9"},textBlockFinal:{x:"w/2-60", y:"h", w:"120", h:"30"}, path:[
{actions:[
{action:"move", x:"0", y:"h-Math.min(Math.min(w,h)/8,w/12)"},
{action:"line", x:"0", y:"0"},
{action:"line", x:"w", y:"0"},
{action:"line", x:"w", y:"h-Math.min(Math.min(w,h)/8,w/12)"},
{action:"quadraticCurve", x1:"w*0.75", y1:"h-3*Math.min(Math.min(w,h)/8,w/12)", x:"w*0.5", y:"h-Math.min(Math.min(w,h)/8,w/12)"},
{action:"quadraticCurve", x1:"w*0.25", y1:"h+Math.min(Math.min(w,h)/8,w/12)", x:"0", y:"h-Math.min(Math.min(w,h)/8,w/12)"},
{action:"close"}
]}
]});
/*Forms*/
/*Schema.addShape({name:"forms", title:"多个表单", text:"多个表单", category:"data_form", props:{w:100, h:70}, textBlock:{x:"0", y:"h*0.2", w:"w*0.8", h:"h*0.8"},textBlockFinal:{x:"w/2-60", y:"h", w:"120", h:"30"},
anchors:[
{x:"w*0.5", y:"h-h/8"},
{x:"0", y:"h*0.5"},
{x:"w*0.5", y:"0"},
{x:"w", y:"h*0.5"}
], path:[{actions:[
{action:"move", x:"0", y:"h*0.2"},
{action:"line", x:"w*0.1", y:"h*0.2"},
{action:"line", x:"w*0.1", y:"h*0.1"},
{action:"line", x:"w*0.2", y:"h*0.1"},
{action:"line", x:"w*0.2", y:"0"},
{action:"line", x:"w", y:"0"},
{action:"line", x:"w", y:"h*0.7"},
{action:"line", x:"w*0.9", y:"h*0.7"},
{action:"line", x:"w*0.9", y:"h*0.8"},
{action:"line", x:"w*0.8", y:"h*0.8"},
{action:"line", x:"w*0.8", y:"h*0.9"},
{action:"quadraticCurve", x1:"w*0.75*0.8", y1:"h*0.8", x:"w*0.8*0.5", y:"h*0.9"},
{action:"quadraticCurve", x1:"w*0.25*0.8", y1:"h", x:"0", y:"h*0.9"},
{action:"line", x:"0", y:"h*0.2"},
{action:"move", x:"0", y:"h*0.2"},
{action:"line", x:"w*0.8", y:"h*0.2"},
{action:"line", x:"w*0.8", y:"h*0.9"},
{action:"quadraticCurve", x1:"w*0.75*0.8", y1:"h*0.8", x:"w*0.8*0.5", y:"h*0.9"},
{action:"quadraticCurve", x1:"w*0.25*0.8", y1:"h", x:"0", y:"h*0.9"},
{action:"line", x:"0", y:"h*0.2"},
{action:"move", x:"w*0.1", y:"h*0.2"},
{action:"line", x:"w*0.1", y:"h*0.1"},
{action:"line", x:"w*0.9", y:"h*0.1"},
{action:"line", x:"w*0.9", y:"h*0.8"},
{action:"line", x:"w*0.8", y:"h*0.8"},
{action:"line", x:"w*0.8", y:"h*0.2"}
]}
]});*/