|
@@ -7,7 +7,7 @@ import icon_person from './images/icon_person.png';
|
|
import icon_submit from './images/icon_submit.png';
|
|
import icon_submit from './images/icon_submit.png';
|
|
import icon_logo from './images/logo.png';
|
|
import icon_logo from './images/logo.png';
|
|
import icon_p1 from './images/icon_p1.png';
|
|
import icon_p1 from './images/icon_p1.png';
|
|
-import icon_p2 from './images/icon_p2.png';
|
|
|
|
|
|
+import icons from './images/icons.json';
|
|
import {
|
|
import {
|
|
api_openSendSms,
|
|
api_openSendSms,
|
|
api_schoolAdd,
|
|
api_schoolAdd,
|
|
@@ -16,11 +16,13 @@ import {
|
|
} from './api';
|
|
} from './api';
|
|
import { useRoute } from 'vue-router';
|
|
import { useRoute } from 'vue-router';
|
|
import MImgCode from '@/components/m-img-code';
|
|
import MImgCode from '@/components/m-img-code';
|
|
|
|
+import { browser } from '@/helpers/utils';
|
|
|
|
|
|
export default defineComponent({
|
|
export default defineComponent({
|
|
name: 'SchoolRegister',
|
|
name: 'SchoolRegister',
|
|
setup() {
|
|
setup() {
|
|
const route = useRoute();
|
|
const route = useRoute();
|
|
|
|
+ const browserInfo = browser();
|
|
const formOptions = {
|
|
const formOptions = {
|
|
/** 性质 */
|
|
/** 性质 */
|
|
nature: [
|
|
nature: [
|
|
@@ -73,7 +75,9 @@ export default defineComponent({
|
|
success: false,
|
|
success: false,
|
|
areaList: {} as any,
|
|
areaList: {} as any,
|
|
sendMsg: '发送验证码',
|
|
sendMsg: '发送验证码',
|
|
- imgCodeStatus: false
|
|
|
|
|
|
+ imgCodeStatus: false,
|
|
|
|
+
|
|
|
|
+ inputFouce: 0
|
|
});
|
|
});
|
|
const formateArea = (area: any[]) => {
|
|
const formateArea = (area: any[]) => {
|
|
const province_list: { [_: string]: string } = {};
|
|
const province_list: { [_: string]: string } = {};
|
|
@@ -133,7 +137,7 @@ export default defineComponent({
|
|
forms.name = forms.name.trim();
|
|
forms.name = forms.name.trim();
|
|
if (!forms.code) {
|
|
if (!forms.code) {
|
|
showToast('请输入验证码');
|
|
showToast('请输入验证码');
|
|
- return
|
|
|
|
|
|
+ return;
|
|
}
|
|
}
|
|
const res = await api_schoolSave({ ...forms });
|
|
const res = await api_schoolSave({ ...forms });
|
|
if (res?.code === 200) {
|
|
if (res?.code === 200) {
|
|
@@ -181,6 +185,9 @@ export default defineComponent({
|
|
trigger: 'onBlur'
|
|
trigger: 'onBlur'
|
|
}
|
|
}
|
|
]}
|
|
]}
|
|
|
|
+ onFocus={() => {
|
|
|
|
+ data.inputFouce++;
|
|
|
|
+ }}
|
|
/>
|
|
/>
|
|
<Field
|
|
<Field
|
|
isLink
|
|
isLink
|
|
@@ -190,7 +197,16 @@ export default defineComponent({
|
|
readonly
|
|
readonly
|
|
inputAlign="right"
|
|
inputAlign="right"
|
|
v-model={data.cityName}
|
|
v-model={data.cityName}
|
|
- onClick={() => (data.showArea = true)}
|
|
|
|
|
|
+ onClick={() => {
|
|
|
|
+ if (browserInfo.ios && data.inputFouce < 2) {
|
|
|
|
+ data.inputFouce++
|
|
|
|
+ setTimeout(() => {
|
|
|
|
+ data.showArea = true;
|
|
|
|
+ }, 700);
|
|
|
|
+ } else {
|
|
|
|
+ data.showArea = true;
|
|
|
|
+ }
|
|
|
|
+ }}
|
|
rules={[{ required: true, message: '请选择' }]}></Field>
|
|
rules={[{ required: true, message: '请选择' }]}></Field>
|
|
<Field center border name="schoolNature" label="办学性质">
|
|
<Field center border name="schoolNature" label="办学性质">
|
|
{{
|
|
{{
|
|
@@ -348,7 +364,13 @@ export default defineComponent({
|
|
onUpdate:modelValue={(val: string) => {
|
|
onUpdate:modelValue={(val: string) => {
|
|
forms.educationalAdministrationUsername = val.trim();
|
|
forms.educationalAdministrationUsername = val.trim();
|
|
}}
|
|
}}
|
|
- rules={[{ required: true, message: '请输入负责人姓名', trigger: 'onBlur' }]}
|
|
|
|
|
|
+ rules={[
|
|
|
|
+ {
|
|
|
|
+ required: true,
|
|
|
|
+ message: '请输入负责人姓名',
|
|
|
|
+ trigger: 'onBlur'
|
|
|
|
+ }
|
|
|
|
+ ]}
|
|
/>
|
|
/>
|
|
<Field
|
|
<Field
|
|
border
|
|
border
|
|
@@ -463,7 +485,7 @@ export default defineComponent({
|
|
v-model:show={data.success}>
|
|
v-model:show={data.success}>
|
|
<div class={styles.successWrap}>
|
|
<div class={styles.successWrap}>
|
|
<img class={styles.p1} src={icon_p1} />
|
|
<img class={styles.p1} src={icon_p1} />
|
|
- <img class={styles.p2} src={icon_p2} />
|
|
|
|
|
|
+ <img class={styles.p2} src={icons.icon_p2} />
|
|
<div class={styles.btnWrap}>
|
|
<div class={styles.btnWrap}>
|
|
<div class={styles.btnTitle}>您已成功登记</div>
|
|
<div class={styles.btnTitle}>您已成功登记</div>
|
|
<div class={styles.btnDes}>欢迎您使用音乐数字课堂~</div>
|
|
<div class={styles.btnDes}>欢迎您使用音乐数字课堂~</div>
|
|
@@ -481,7 +503,7 @@ export default defineComponent({
|
|
{data.imgCodeStatus ? (
|
|
{data.imgCodeStatus ? (
|
|
<MImgCode
|
|
<MImgCode
|
|
v-model:value={data.imgCodeStatus}
|
|
v-model:value={data.imgCodeStatus}
|
|
- clientId='cooleshow-teacher'
|
|
|
|
|
|
+ clientId="cooleshow-teacher"
|
|
phone={forms.educationalAdministrationPhone}
|
|
phone={forms.educationalAdministrationPhone}
|
|
onClose={() => {
|
|
onClose={() => {
|
|
data.imgCodeStatus = false;
|
|
data.imgCodeStatus = false;
|