Browse Source

单行文本移动端扫描输入配置开关及方式选择

lwx_v17
liwenxuan 10 months ago
parent
commit
1004264ebd
  1. 4
      src/components/DesignForm/assembly/index.ts
  2. 51
      src/components/DesignForm/formControlPropertiNew.vue

4
src/components/DesignForm/assembly/index.ts

@ -217,7 +217,9 @@ export default [
iconFont: 'fa-text-width', iconFont: 'fa-text-width',
control: { control: {
// 组件所有属性 // 组件所有属性
modelValue: '' modelValue: '',
scanInputFlag: false,
scanType:'',
}, },
config: {}, // 其他配置信息 config: {}, // 其他配置信息
styles: { styles: {

51
src/components/DesignForm/formControlPropertiNew.vue

@ -527,6 +527,7 @@ const attrList = computed(() => {
path: "config.append", path: "config.append",
vShow: ["input", "password", "digitpage"], vShow: ["input", "password", "digitpage"],
}, },
// { // {
// label: '', // label: '',
// value: control.activeValue, // value: control.activeValue,
@ -733,6 +734,14 @@ const attrList = computed(() => {
vIf: state.isSearch, vIf: state.isSearch,
vShow: ["associatedForms"], vShow: ["associatedForms"],
}, },
{
label: "移动端扫描输入",
value: config.scanInput,
path: "config.scanInput",
type: "input",
vIf: state.isSearch,
vShow: ["input"],
},
{ {
label: "隐藏条件", label: "隐藏条件",
value: config.associatedForms, value: config.associatedForms,
@ -3351,6 +3360,19 @@ const gainFormGroupList = () => {
} }
}); });
}; };
//liwenxuan 2025 start
const scanTypes = [
{
value: 'QrCode',
label: '二维码',
},
{
value: 'OCR',
label: '光学字符识别',
},
]
//liwenxuan 2025 end
let asfs: any[] = []; let asfs: any[] = [];
let asfsExpectCurrent: any[] = []; let asfsExpectCurrent: any[] = [];
@ -4207,6 +4229,35 @@ const updataBase = (val: any) => {
> >
</el-row> </el-row>
<el-row v-else-if="item.type === 'input'"><!-- 移动端扫描输入 -->
<el-switch v-model="controlData.control.scanInputFlag" />
<div
v-if="controlData.control.scanInputFlag"
style="
display: flex;
width: auto;
margin-top: 33px;
margin-left: -125px;
padding-bottom: 6px;
"
>
<div style="margin-right: 12px;">扫描方式</div>
<el-select
v-model="controlData.control.scanType"
style="width: 150px; height:20px">
<el-option
v-for="scanType in scanTypes"
:key="scanType.value"
:label="scanType.label"
:value="scanType.value"
/>
</el-select>
</div>
</el-row>
<el-row v-else-if="item.type === 'associatedForms_dataRange'"> <el-row v-else-if="item.type === 'associatedForms_dataRange'">
<el-button <el-button
v-if="controlData.control.dataRangeConditionHtml === ''" v-if="controlData.control.dataRangeConditionHtml === ''"

Loading…
Cancel
Save