Browse Source

1.修改开关的关联选项设置按钮不显示bug

2.优化关联表单的tinymce编辑器样式和提醒
lwx_v1
liwenxuan 1 year ago
parent
commit
a3551a07ee
  1. 16
      src/components/DesignForm/formControlAttr.vue
  2. 15
      src/components/DesignForm/formControlPropertiNew.vue
  3. 10
      src/widget/associatedforms/associatedFormsTinyace.vue
  4. 6
      src/widget/associatedforms/associatedFormsTinyaceRange.vue

16
src/components/DesignForm/formControlAttr.vue

@ -1883,7 +1883,7 @@ const treeDefaultProps = {
label: 'label',
}
//AssociatedFormsTinyace
let aft = ref();
const aft = ref();
const aftRange = ref();
function getAssociatedFormsCurrentFieldTree() {
@ -3159,7 +3159,7 @@ const disabledIstrue = (val:string) => {
</el-form-item>
</div>
</div>
<div v-if="showHide(['switch'],true)&&controlData.config.optionsType==0">
<div v-if="showHide(['switch'],true)">
<el-button @click="handelGlxxszDialogSwitch">关联选项设置</el-button>
</div>
<div v-if="showHide(['radio','select',],true)&&controlData.config.optionsType==0">
@ -3858,17 +3858,19 @@ const disabledIstrue = (val:string) => {
</el-aside>
<el-main style="border: 1px solid gainsboro; padding: 3px;" class="associatedFormsHideDialogMain">
<div style="border: 1px solid gainsboro; height: 7%; border-bottom: 0px; padding-top: 3px; padding-left: 5px; background-color: #E6F3FE;">当满足以下条件时此控件隐藏</div>
<div id="associatedFormsHideEditArea" style="border: 1px solid gainsboro; height: 63%; border-bottom: 0px;">
<div id="associatedFormsHideEditArea" style="border: 1px solid gainsboro; height: 43%; border-bottom: 0px;">
<AssociatedFormsTinyace ref="aft" :aft-text="controlData.control.hideConditionHtml" :aft-text-copy = "controlData.control.hideConditionHtmlCopy" @text-change = "aftTextChanged" @gongshi-change = "aftGongshiChanged"></AssociatedFormsTinyace>
<!-- <div style="border: 1px solid #4189EF;width:90px;height:26px;border-radius: 3px;padding:2px;text-align: center;cursor:pointer;float: right;margin-top: -32px;margin-right: 5px;z-index:99999999;position: relative;">
<span style="color: #4189EF;font:6px;margin-right: 5px;">fx</span>插入函数
</div> -->
</div>
<div style="border: 1px solid gainsboro; height: 30%; padding-top: 20px;">
<div style="border: 1px solid gainsboro; height: 50%; padding-top: 20px;">
<ul>
<li>请从左侧面板<span style="color: red">右击</span>选择字段或选项</li>
<li>支持<span style="color: red">英文</span>模式下运算符<!-- +-*/><== --></li>
<li>支持<span style="color: red">"包含"</span>关键字,用于组织机构条件</li>
<li>支持<span style="color: red">"当前用户"</span>关键字,用于角色条件</li>
<li>参考场景</li>
<span style="margin-left: 14px;">年龄控件输入的值大于10时需要隐藏当前控件则可将隐藏条件设置为年龄>10</span>
</ul>
@ -3968,17 +3970,19 @@ const disabledIstrue = (val:string) => {
</el-aside>
<el-main style="border: 1px solid gainsboro; padding: 3px;" class="associatedFormsHideDialogMain">
<div style="border: 1px solid gainsboro; height: 7%; border-bottom: 0px; padding-top: 3px; padding-left: 5px; background-color: #E6F3FE;">仅可选择符合以下条件的数据</div>
<div id="associatedFormsHideEditArea" style="border: 1px solid gainsboro; height: 63%; border-bottom: 0px;">
<div id="associatedFormsHideEditArea" style="border: 1px solid gainsboro; height: 43%; border-bottom: 0px;">
<AssociatedFormsTinyaceRange ref="aftRange" :aft-text="controlData.control.dataRangeConditionHtml" :aft-text-copy = "controlData.control.dataRangeConditionHtmlCopy" @text-change = "aftTextChangedRange" @gongshi-change = "aftGongshiChangedRange"></AssociatedFormsTinyaceRange>
<!-- <div style="border: 1px solid #4189EF;width:90px;height:26px;border-radius: 3px;padding:2px;text-align: center;cursor:pointer;float: right;margin-top: -32px;margin-right: 5px;z-index:99999999;position: relative;">
<span style="color: #4189EF;font:6px;margin-right: 5px;">fx</span>插入函数
</div> -->
</div>
<div style="border: 1px solid gainsboro; height: 30%; padding-top: 20px;">
<div style="border: 1px solid gainsboro; height: 50%; padding-top: 20px;">
<ul>
<li>请从左侧面板<span style="color: red">右击</span>选择字段或选项</li>
<li>支持<span style="color: red">英文</span>模式下运算符<!-- +-*/><== --></li>
<li>支持<span style="color: red">"包含"</span>关键字,用于组织机构条件</li>
<li>支持<span style="color: red">"当前用户"</span>关键字,用于角色条件</li>
<li>参考场景</li>
<span style="margin-left: 14px;">仅可选择关联表单中年龄大于10的数据则可将数据范围设置为年龄>10</span>
</ul>

15
src/components/DesignForm/formControlPropertiNew.vue

@ -3211,7 +3211,8 @@ const disabledIstrue = (val:string) => {
</el-form-item>
</div>
</div>
<div v-if="showHide(['switch'],true)&&controlData.config.optionsType==0">
<!-- {{controlData.config.optionsType}} -->
<div v-if="showHide(['switch'],true)">
<el-button @click="handelGlxxszDialogSwitch">关联选项设置</el-button>
</div>
<div v-if="showHide(['radio','select',],true)&&controlData.config.optionsType==0">
@ -3911,17 +3912,19 @@ const disabledIstrue = (val:string) => {
</el-aside>
<el-main style="border: 1px solid gainsboro; padding: 3px;" class="associatedFormsHideDialogMain">
<div style="border: 1px solid gainsboro; height: 7%; border-bottom: 0px; padding-top: 3px; padding-left: 5px; background-color: #E6F3FE;">当满足以下条件时此控件隐藏</div>
<div id="associatedFormsHideEditArea" style="border: 1px solid gainsboro; height: 63%; border-bottom: 0px;">
<div id="associatedFormsHideEditArea" style="border: 1px solid gainsboro; height: 43%; border-bottom: 0px;">
<AssociatedFormsTinyace ref="aft" :aft-text="controlData.control.hideConditionHtml" :aft-text-copy = "controlData.control.hideConditionHtmlCopy" @text-change = "aftTextChanged" @gongshi-change = "aftGongshiChanged"></AssociatedFormsTinyace>
<!-- <div style="border: 1px solid #4189EF;width:90px;height:26px;border-radius: 3px;padding:2px;text-align: center;cursor:pointer;float: right;margin-top: -32px;margin-right: 5px;z-index:99999999;position: relative;">
<span style="color: #4189EF;font:6px;margin-right: 5px;">fx</span>插入函数
</div> -->
</div>
<div style="border: 1px solid gainsboro; height: 30%; padding-top: 20px;">
<div style="border: 1px solid gainsboro; height: 50%; padding-top: 20px;">
<ul>
<li>请从左侧面板<span style="color: red">右击</span>选择字段或选项</li>
<li>支持<span style="color: red">英文</span>模式下运算符<!-- +-*/><== --></li>
<li>支持<span style="color: red">"包含"</span>关键字,用于组织机构条件</li>
<li>支持<span style="color: red">"当前用户"</span>关键字,用于角色条件</li>
<li>参考场景</li>
<span style="margin-left: 14px;">年龄控件输入的值大于10时需要隐藏当前控件则可将隐藏条件设置为年龄>10</span>
</ul>
@ -4021,17 +4024,19 @@ const disabledIstrue = (val:string) => {
</el-aside>
<el-main style="border: 1px solid gainsboro; padding: 3px;" class="associatedFormsHideDialogMain">
<div style="border: 1px solid gainsboro; height: 7%; border-bottom: 0px; padding-top: 3px; padding-left: 5px; background-color: #E6F3FE;">仅可选择符合以下条件的数据</div>
<div id="associatedFormsHideEditArea" style="border: 1px solid gainsboro; height: 63%; border-bottom: 0px;">
<div id="associatedFormsHideEditArea" style="border: 1px solid gainsboro; height: 43%; border-bottom: 0px;">
<AssociatedFormsTinyaceRange ref="aftRange" :aft-text="controlData.control.dataRangeConditionHtml" :aft-text-copy = "controlData.control.dataRangeConditionHtmlCopy" @text-change = "aftTextChangedRange" @gongshi-change = "aftGongshiChangedRange"></AssociatedFormsTinyaceRange>
<!-- <div style="border: 1px solid #4189EF;width:90px;height:26px;border-radius: 3px;padding:2px;text-align: center;cursor:pointer;float: right;margin-top: -32px;margin-right: 5px;z-index:99999999;position: relative;">
<span style="color: #4189EF;font:6px;margin-right: 5px;">fx</span>插入函数
</div> -->
</div>
<div style="border: 1px solid gainsboro; height: 30%; padding-top: 20px;">
<div style="border: 1px solid gainsboro; height: 50%; padding-top: 20px;">
<ul>
<li>请从左侧面板<span style="color: red">右击</span>选择字段或选项</li>
<li>支持<span style="color: red">英文</span>模式下运算符<!-- +-*/><== --></li>
<li>支持<span style="color: red">"包含"</span>关键字,用于组织机构条件</li>
<li>支持<span style="color: red">"当前用户"</span>关键字,用于角色条件</li>
<li>参考场景</li>
<span style="margin-left: 14px;">仅可选择关联表单中年龄大于10的数据则可将数据范围设置为年龄>10</span>
</ul>

10
src/widget/associatedforms/associatedFormsTinyace.vue

@ -18,7 +18,7 @@ const tinymceInit = {
language_url: "/tinymce/langs/zh-Hans.js", // public
language: "zh-Hans", // zh-Hans.js
skin_url: "/tinymce/skins/ui/oxide", //
height: 260, //
height: 174, //
statusbar:false,
toolbar:false,
branding: false, //Powered by TinyMCE
@ -85,9 +85,11 @@ watch(()=>tinymceHtml.value, (val:any) => {
errorCondition("条件不能以蓝色块结尾")
}else if(countSpanTags(gongShi.formulaHtml)>1){
errorCondition("不允许出现多个蓝色块")
}else if(!containsSingleComparator(gongShi.mathsFormula)){
errorCondition("不存在有效符号")
}else if(checkEnding(gongShi.mathsFormula)){
}else if(!containsSingleComparator(gongShi.mathsFormula)&&!gongShi.mathsFormula.includes("包含")){
errorCondition("不存在有效符号")
}else if(checkEnding(gongShi.mathsFormula)){
errorCondition("不能以符号为结尾")
}else{
succCondition()

6
src/widget/associatedforms/associatedFormsTinyaceRange.vue

@ -17,7 +17,7 @@ const tinymceInit = {
language_url: "/tinymce/langs/zh-Hans.js", // public
language: "zh-Hans", // zh-Hans.js
skin_url: "/tinymce/skins/ui/oxide", //
height: 260, //
height: 174, //
statusbar:false,
toolbar:false,
branding: false, //Powered by TinyMCE
@ -84,8 +84,10 @@ watch(()=>tinymceHtml.value, (val:any) => {
errorCondition("条件不能以蓝色块结尾")
}else if(countSpanTags(gongShi.formulaHtml)>1){
errorCondition("不允许出现多个蓝色块")
}else if(!containsSingleComparator(gongShi.mathsFormula)){
}else if(!containsSingleComparator(gongShi.mathsFormula)&&!gongShi.mathsFormula.includes("包含")){
errorCondition("不存在有效符号")
}else if(checkEnding(gongShi.mathsFormula)){
errorCondition("不能以符号为结尾")
}else{

Loading…
Cancel
Save