|
@ -11,8 +11,8 @@ |
|
|
</div> |
|
|
</div> |
|
|
<div class="ele-item"> |
|
|
<div class="ele-item"> |
|
|
<label for="">下拉框:</label> |
|
|
<label for="">下拉框:</label> |
|
|
<GuipSelect width="600px" v-model="form.card" clearable label="卡片" :default-value="form.card" prop="card" |
|
|
<GuipSelect width="600px" v-model="form.card" clearable label="卡片" :default-value="form.card" |
|
|
:options="options" valueKey="id1" labelKey="id2" /> |
|
|
prop="card" :options="options" valueKey="id1" labelKey="id2" /> |
|
|
</div> |
|
|
</div> |
|
|
<div> |
|
|
<div> |
|
|
<h3 for="">表格:(表头自定义、自定义渲染、固定列)</h3> |
|
|
<h3 for="">表格:(表头自定义、自定义渲染、固定列)</h3> |
|
@ -120,7 +120,7 @@ |
|
|
|
|
|
|
|
|
<div class="ele-item"> |
|
|
<div class="ele-item"> |
|
|
<label for="">文本域:固定行数</label> |
|
|
<label for="">文本域:固定行数</label> |
|
|
<GuipTextarea :styleObject="{ width: '450px' }" placeholder="固定行数" :rows="4" /> |
|
|
<GuipTextarea :styleObject="{ width: '450px' }" placeholder="固定行数" :rows="2" /> |
|
|
</div> |
|
|
</div> |
|
|
<div class="ele-item"> |
|
|
<div class="ele-item"> |
|
|
<label for="">文本域:自适应高度</label> |
|
|
<label for="">文本域:自适应高度</label> |
|
@ -128,9 +128,8 @@ |
|
|
</div> |
|
|
</div> |
|
|
<div class="ele-item"> |
|
|
<div class="ele-item"> |
|
|
<label for="">文本域:自定义label、描述</label> |
|
|
<label for="">文本域:自定义label、描述</label> |
|
|
<GuipTextarea label="详细介绍" column="column" prop="doctor_detail" |
|
|
<GuipTextarea label="详细介绍" column="column" prop="doctor_detail" width="400px" height="90px" |
|
|
width="400px" height="90px" placeholder="请输入描述内容" desc="啊哈哈哈哈哈哈哈哈" |
|
|
placeholder="请输入描述内容" desc="啊哈哈哈哈哈哈哈哈" show-word-limit /> |
|
|
show-word-limit /> |
|
|
|
|
|
</div> |
|
|
</div> |
|
|
|
|
|
|
|
|
<div class="ele-item"> |
|
|
<div class="ele-item"> |
|
@ -283,8 +282,8 @@ |
|
|
<!-- <b slot="formLeft">自定义左侧</b> --> |
|
|
<!-- <b slot="formLeft">自定义左侧</b> --> |
|
|
<span class="desc" slot="formRight"><a href="https://www.baidu.com/">跳转一下</a> 自定义右侧</span> |
|
|
<span class="desc" slot="formRight"><a href="https://www.baidu.com/">跳转一下</a> 自定义右侧</span> |
|
|
<!-- 自定义下方内容 --> |
|
|
<!-- 自定义下方内容 --> |
|
|
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="form.age" |
|
|
<GuipInput slot="formDom" ref="GuipInput" column="column" v-model="form.age" prop="age" |
|
|
prop="age" placeholder="请输入" /> |
|
|
placeholder="请输入" /> |
|
|
</GuipFormItem> |
|
|
</GuipFormItem> |
|
|
</div> |
|
|
</div> |
|
|
|
|
|
|
|
@ -293,6 +292,105 @@ |
|
|
<GuipSwitch :modelValue="switchValue" activeText="开启" inactiveText="关闭" @change="onSwitchChange"> |
|
|
<GuipSwitch :modelValue="switchValue" activeText="开启" inactiveText="关闭" @change="onSwitchChange"> |
|
|
</GuipSwitch> |
|
|
</GuipSwitch> |
|
|
</div> |
|
|
</div> |
|
|
|
|
|
<div class="flex ele-item"> |
|
|
|
|
|
<label for="">input、drop组合使用(默认使用)</label> |
|
|
|
|
|
<GuipFormItem column="column" class="combo-formItem w510" label="域名设置" required="true"> |
|
|
|
|
|
<div slot="formDom" class="self-drop-wrap flex"> |
|
|
|
|
|
<GuipInput style="width: 60%;" v-model="form.domain_set" placeholder="仅支持数字、字母"> |
|
|
|
|
|
</GuipInput> |
|
|
|
|
|
<!-- 只用作选中内容展示 --> |
|
|
|
|
|
<div @click="toggleDrop" class="point flex appendDrop" style="width: 40%;"> |
|
|
|
|
|
{{ currentDomainItem.name }}</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
<!--触发 真实下拉操作 --> |
|
|
|
|
|
<!-- valueKey="id" displayKey="name" 不添加时,默认取值 value、label--> |
|
|
|
|
|
<CustomDropdown slot="formDom" ref="dropDomain" width="100%" v-model="form.domainSuffix1" |
|
|
|
|
|
:options="domainOptions" @change="changeSelectIp" |
|
|
|
|
|
placeholder="请选择"> |
|
|
|
|
|
<template #normal> |
|
|
|
|
|
<div class="flex flex-between noraml-jump"> |
|
|
|
|
|
<div class="left"> |
|
|
|
|
|
<b>添加新域名</b> |
|
|
|
|
|
<p class="one ft12">域名需要在阿里云完成ICP备案并解析到平台服务器</p> |
|
|
|
|
|
<p class="ft12">如果暂时未准备好,可先选用平台免费域名,随时支持域名修改。 </p> |
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="right"> |
|
|
|
|
|
<GuipButton size="form">前往绑定</GuipButton> |
|
|
|
|
|
</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
</template> |
|
|
|
|
|
</CustomDropdown> |
|
|
|
|
|
</GuipFormItem> |
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="flex ele-item"> |
|
|
|
|
|
<label for="">input、drop组合使用(自定义下拉选择项)</label> |
|
|
|
|
|
<GuipFormItem column="column" class="combo-formItem w510" label="域名设置" required="true"> |
|
|
|
|
|
<div slot="formDom" class="self-drop-wrap flex"> |
|
|
|
|
|
<GuipInput style="width: 60%;" v-model="form.domain_set" placeholder="仅支持数字、字母"> |
|
|
|
|
|
</GuipInput> |
|
|
|
|
|
<!-- 只用作选中内容展示 --> |
|
|
|
|
|
<div @click="toggleDrop1" class="point flex appendDrop" style="width: 40%;"> |
|
|
|
|
|
{{ currentDomainItem.name }} |
|
|
|
|
|
</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
<!--触发 真实下拉操作 --> |
|
|
|
|
|
<!-- valueKey="id" displayKey="name" 不添加时,默认取值 value、label--> |
|
|
|
|
|
<CustomDropdown slot="formDom" ref="dropDomain1" width="100%" v-model="form.domainSuffix" |
|
|
|
|
|
:options="domainOptions" @change="changeSelectIp" valueKey="id" placeholder="请选择"> |
|
|
|
|
|
<template #normal> |
|
|
|
|
|
<div class="flex flex-between noraml-jump"> |
|
|
|
|
|
<div class="left"> |
|
|
|
|
|
<b>添加新域名</b> |
|
|
|
|
|
<p class="one ft12">域名需要在阿里云完成ICP备案并解析到平台服务器</p> |
|
|
|
|
|
<p class="ft12">如果暂时未准备好,可先选用平台免费域名,随时支持域名修改。 </p> |
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="right"> |
|
|
|
|
|
<GuipButton size="form">前往绑定</GuipButton> |
|
|
|
|
|
</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
</template> |
|
|
|
|
|
<!-- 自定义下拉选项 选中条件--> |
|
|
|
|
|
<!-- 不添加这个 默认普通选中格式 单独取值 display-key |
|
|
|
|
|
自定义渲染项 渲染的内容自定义 ,display-key 属性不再生效--> |
|
|
|
|
|
<template #item="{ item }"> |
|
|
|
|
|
<div class="flex-between"> |
|
|
|
|
|
<div class="left"> |
|
|
|
|
|
<p class="one">{{ item.label }}</p> |
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="right"> |
|
|
|
|
|
<img v-if="form.domainSuffix == item.id" |
|
|
|
|
|
src="@/assets/register/drop-selected.svg" alt=""> |
|
|
|
|
|
</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
</template> |
|
|
|
|
|
</CustomDropdown> |
|
|
|
|
|
</GuipFormItem> |
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="flex ele-item"> |
|
|
|
|
|
<label for="">单独实现自定义内容下拉选择</label> |
|
|
|
|
|
<CustomDropdown width="500px" v-model="form.domainSuffix" :options="domainOptions" |
|
|
|
|
|
@change="changeSelectIp" valueKey="id" placeholder="请选择"> |
|
|
|
|
|
<template #normal> |
|
|
|
|
|
<div class="flex flex-between noraml-jump"> |
|
|
|
|
|
<div class="left"> |
|
|
|
|
|
<b>添加新域名</b> |
|
|
|
|
|
<p class="one ft12">域名需要在阿里云完成ICP备案并解析到平台服务器</p> |
|
|
|
|
|
<p class="ft12">如果暂时未准备好,可先选用平台免费域名,随时支持域名修改。 </p> |
|
|
|
|
|
</div> |
|
|
|
|
|
<div class="right"> |
|
|
|
|
|
<GuipButton size="form">前往绑定</GuipButton> |
|
|
|
|
|
</div> |
|
|
|
|
|
</div> |
|
|
|
|
|
</template> |
|
|
|
|
|
<template #item="{ item }"> |
|
|
|
|
|
<div class="flex-between"> |
|
|
|
|
|
<p>测试一下自定义内容{{ item. id}} + {{ item.label }}</p> |
|
|
|
|
|
<p>易烊千玺/田栩宁</p> |
|
|
|
|
|
</div> |
|
|
|
|
|
</template> |
|
|
|
|
|
</CustomDropdown> |
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
<el-button type="primary" @click="submitForm">Submit</el-button> |
|
|
<el-button type="primary" @click="submitForm">Submit</el-button> |
|
|
|
|
|
|
|
|
</el-form> |
|
|
</el-form> |
|
@ -327,6 +425,7 @@ |
|
|
<GuipButton type="primary" @click="openDialog">打开弹框</GuipButton> |
|
|
<GuipButton type="primary" @click="openDialog">打开弹框</GuipButton> |
|
|
<GuipButton type="primary" @click="openLoading" size="page">展示加载动画 2s</GuipButton> |
|
|
<GuipButton type="primary" @click="openLoading" size="page">展示加载动画 2s</GuipButton> |
|
|
</div> |
|
|
</div> |
|
|
|
|
|
|
|
|
<div class="flex ele-item"> |
|
|
<div class="flex ele-item"> |
|
|
<label for="">提示信息</label> |
|
|
<label for="">提示信息</label> |
|
|
<GuipToolTip content="这是一个提示"> |
|
|
<GuipToolTip content="这是一个提示"> |
|
@ -364,7 +463,7 @@ |
|
|
<script> |
|
|
<script> |
|
|
|
|
|
|
|
|
import { rules } from "../assets/vabForm"; |
|
|
import { rules } from "../assets/vabForm"; |
|
|
// @ is an alias to /src |
|
|
import CustomDropdown from '@/components/CustomDropdown.vue'; |
|
|
import GuipSwitch from '@/components/GuipSwitch.vue'; |
|
|
import GuipSwitch from '@/components/GuipSwitch.vue'; |
|
|
import GuipDialog from '@/components/GuipDialog.vue'; |
|
|
import GuipDialog from '@/components/GuipDialog.vue'; |
|
|
import GuipRadio from '@/components/GuipRadio.vue'; |
|
|
import GuipRadio from '@/components/GuipRadio.vue'; |
|
@ -394,10 +493,31 @@ export default { |
|
|
GuipToolTip, |
|
|
GuipToolTip, |
|
|
HoverButton, |
|
|
HoverButton, |
|
|
SvgIcon, |
|
|
SvgIcon, |
|
|
GuipFormItem |
|
|
GuipFormItem, |
|
|
|
|
|
CustomDropdown |
|
|
}, |
|
|
}, |
|
|
data() { |
|
|
data() { |
|
|
return { |
|
|
return { |
|
|
|
|
|
domainOptions: [ |
|
|
|
|
|
{ |
|
|
|
|
|
value: '.chachongz.com', |
|
|
|
|
|
label: '111.chachongz.com', |
|
|
|
|
|
id: '11', |
|
|
|
|
|
name: '测试一下自定义名称111' |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
value: '.turnitin.org.cn', |
|
|
|
|
|
label: '222.turnitin.org.cn', |
|
|
|
|
|
id: '22', |
|
|
|
|
|
name: '测试一下自定义名称222' |
|
|
|
|
|
}, |
|
|
|
|
|
{ |
|
|
|
|
|
value: '.jishu.chachongz.com', |
|
|
|
|
|
label: '333.jishu.chachongz.com', |
|
|
|
|
|
id: '33', |
|
|
|
|
|
name: '测试一下自定义名称333' |
|
|
|
|
|
}, |
|
|
|
|
|
], |
|
|
tableData3: [{ |
|
|
tableData3: [{ |
|
|
id: '12987122', |
|
|
id: '12987122', |
|
|
name: '王小虎', |
|
|
name: '王小虎', |
|
@ -443,7 +563,10 @@ export default { |
|
|
form: { |
|
|
form: { |
|
|
username: '', |
|
|
username: '', |
|
|
language: '', |
|
|
language: '', |
|
|
card:'1', |
|
|
domain_set: '', |
|
|
|
|
|
domainSuffix: '11', |
|
|
|
|
|
domainSuffix1: '.chachongz.com', |
|
|
|
|
|
card: '1', |
|
|
input1: '', |
|
|
input1: '', |
|
|
input2: '', |
|
|
input2: '', |
|
|
input3: '', |
|
|
input3: '', |
|
@ -706,10 +829,30 @@ export default { |
|
|
// this.timer = null; |
|
|
// this.timer = null; |
|
|
|
|
|
|
|
|
}, |
|
|
}, |
|
|
|
|
|
computed: { |
|
|
|
|
|
currentDomainItem() { |
|
|
|
|
|
return this.findItemById('id', 'domainSuffix'); |
|
|
|
|
|
} |
|
|
|
|
|
}, |
|
|
methods: { |
|
|
methods: { |
|
|
|
|
|
findItemById(valueKey, key) { |
|
|
|
|
|
// 自动查找选中项 |
|
|
|
|
|
return this.domainOptions.find(item => item[valueKey] === this.form[key]); |
|
|
|
|
|
}, |
|
|
|
|
|
toggleDrop1(e) { |
|
|
|
|
|
this.$refs.dropDomain1.toggleDropdown(e) |
|
|
|
|
|
}, |
|
|
|
|
|
toggleDrop(e) { |
|
|
|
|
|
this.$refs.dropDomain.toggleDropdown(e) |
|
|
|
|
|
}, |
|
|
changeInputtest(e) { |
|
|
changeInputtest(e) { |
|
|
console.log(e, '---000changeInputtest'); |
|
|
console.log(e, '---000changeInputtest'); |
|
|
}, |
|
|
}, |
|
|
|
|
|
changeSelectIp(item) { |
|
|
|
|
|
// 选中项 |
|
|
|
|
|
// this.selectedItem1 = { ...item }; |
|
|
|
|
|
console.log(item, this.form.domainSuffix,this.form.domainSuffix1, '选中的项-值-'); |
|
|
|
|
|
}, |
|
|
arraySpanMethod({ row, column, rowIndex, columnIndex }) { |
|
|
arraySpanMethod({ row, column, rowIndex, columnIndex }) { |
|
|
console.log(row, column); |
|
|
console.log(row, column); |
|
|
if (rowIndex % 2 === 0) { |
|
|
if (rowIndex % 2 === 0) { |
|
@ -974,7 +1117,51 @@ export default { |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
// 组合框样式 start |
|
|
|
|
|
// input drop组合使用 |
|
|
|
|
|
.combo-formItem { |
|
|
|
|
|
::v-deep { |
|
|
|
|
|
.form-item-bottom { |
|
|
|
|
|
position: relative; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.select-trigger { |
|
|
|
|
|
background: #F6F7FA; |
|
|
|
|
|
border-color: transparent; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.is-open .select-trigger { |
|
|
|
|
|
border-color: #006AFF; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.el-input__inner { |
|
|
|
|
|
border-radius: 2px 0 0 2px; |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
.self-drop-wrap { |
|
|
|
|
|
position: absolute; |
|
|
|
|
|
z-index: 1; |
|
|
|
|
|
width: 100%; |
|
|
|
|
|
} |
|
|
|
|
|
.appendDrop { |
|
|
|
|
|
height: 38px; |
|
|
|
|
|
align-items: center; |
|
|
|
|
|
border-radius: 0 2px 2px 0; |
|
|
|
|
|
border: 1px solid #DFE2E6; |
|
|
|
|
|
border-left-color: transparent; |
|
|
|
|
|
justify-content: center; |
|
|
|
|
|
box-sizing: border-box; |
|
|
|
|
|
padding: 0 30px 0 12px; |
|
|
|
|
|
text-overflow: ellipsis; |
|
|
|
|
|
white-space: nowrap; |
|
|
|
|
|
overflow: hidden; |
|
|
|
|
|
&:hover { |
|
|
|
|
|
border: 1px solid #006AFF; |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// 组合框样式 end |
|
|
|
|
|
|
|
|
.ScaleBox { |
|
|
.ScaleBox { |
|
|
width: 1000px; |
|
|
width: 1000px; |
|
|