fhrons-mobile-next 2.0.0 → 2.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.env.poc +8 -0
- package/assets/css/colors.js +6 -0
- package/assets/css/customVant.less +60 -0
- package/assets/css/extra.css +32 -0
- package/assets/css/global.css +1 -0
- package/assets/css/global.less +1637 -0
- package/assets/css/index.js +63 -0
- package/assets/css/static.less +607 -0
- package/assets/js/func.js +361 -0
- package/assets/js/globalData.js +18 -0
- package/assets/js/qywxapi.js +484 -0
- package/{packages → assets/js}/storage.js +1 -20
- package/assets/js/upload.js +269 -0
- package/assets/js/validate.js +48 -0
- package/assets/js/vant.js +39 -0
- package/assets/js/wxapi.js +297 -0
- package/assets/vantLang/index.js +172 -0
- package/assets/vantLang/lib/en-US.js +95 -0
- package/assets/vantLang/lib/es-ES.js +95 -0
- package/assets/vantLang/lib/pt-PT.js +96 -0
- package/assets/vantLang/lib/zh-CN.js +96 -0
- package/assets/vantLang/lib/zh-HK.js +96 -0
- package/assets/vantLang/locales/en_US.js +102 -0
- package/assets/vantLang/locales/es_ES.js +102 -0
- package/assets/vantLang/locales/index.js +12 -0
- package/assets/vantLang/locales/pt_PT.js +102 -0
- package/assets/vantLang/locales/zh_CN.js +102 -0
- package/assets/vantLang/locales/zh_T.js +102 -0
- package/babel.config.js +15 -0
- package/index.js +68 -33
- package/inject-env-plugin.js +29 -0
- package/package.json +46 -32
- package/packages/areaMobile/index.js +5 -0
- package/packages/areaMobile/index.vue +260 -0
- package/packages/autoGraph/VueEsign.vue +309 -0
- package/packages/autoGraph/index.js +5 -0
- package/packages/autoGraph/index.vue +472 -0
- package/packages/commonForm/CommonAsyncAreaPicker.vue +223 -0
- package/packages/commonForm/CommonDatePicker.vue +152 -0
- package/packages/commonForm/CommonForm.vue +786 -0
- package/packages/commonForm/CommonFullTimePicker.vue +137 -0
- package/packages/commonForm/CommonSinglePicker.vue +121 -0
- package/packages/commonForm/CommonYearMonthPicker.vue +127 -0
- package/packages/commonForm/index.js +33 -0
- package/packages/dialog/index.js +32 -0
- package/packages/dialog/index.vue +379 -0
- package/packages/index.js +7 -3
- package/packages/introduce/index.js +5 -0
- package/packages/introduce/index.vue +31 -0
- package/packages/loading/Loading.vue +70 -0
- package/packages/loading/index.js +43 -0
- package/packages/mindMap/index.js +5 -0
- package/packages/mindMap/index.vue +437 -0
- package/packages/pdfViewer/index.js +12 -0
- package/packages/pdfViewer/index.vue +131 -0
- package/packages/sharePanel/SheetPanel.vue +316 -0
- package/packages/sharePanel/index.js +5 -0
- package/packages/sharePanel/index.vue +476 -0
- package/packages/sharePanel/props.js +58 -0
- package/packages/sharePanel/utils/QyWxShareMixin.js +93 -0
- package/packages/sharePanel/utils/shareWay.js +81 -0
- package/packages/theme/index copy.js +89 -0
- package/packages/theme/index.js +38 -0
- package/packages/theme/theme.css +910 -0
- package/packages/theme/theme.less +26 -0
- package/packages/uploadFile/VanUploadFile.vue +80 -0
- package/packages/uploadFile/index.js +5 -0
- package/packages/uploadFile/index.vue +725 -0
- package/packages/uploadFile/vanUpload.js +5 -0
- package/packages/verify/Verify/VerifyPoints.vue +247 -0
- package/packages/verify/Verify/VerifySlide.vue +364 -0
- package/packages/verify/index.js +5 -0
- package/packages/verify/index.vue +416 -0
- package/packages/verify/utils/verify.js +53 -0
- package/packages/videoPage/index.js +5 -0
- package/packages/videoPage/index.vue +440 -0
- package/plugins/sensors/fhsensors.js +84 -0
- package/plugins/sensors/sensors.js +175 -0
- package/plugins/sensors/sensorsFun.js +1387 -0
- package/fhrons-mobile-next-2.0.0.tgz +0 -0
- package/packages/fhImage/index.js +0 -5
- package/packages/fhImage/index.vue +0 -57
- package/packages/fhPresetImage/index.js +0 -5
- package/packages/fhPresetImage/index.vue +0 -39
- package/packages/html2canvas/index.js +0 -29
- package/upload copy.js +0 -468
- package/utils/tools.js +0 -22
- /package/{dist → fhcommon/dist}/fhcommon.min.js +0 -0
- /package/{dist → fhcommon/dist}/fhcommon.min.js.LICENSE.txt +0 -0
- /package/{upload.js → fhcommon/upload.js} +0 -0
|
@@ -0,0 +1,152 @@
|
|
|
1
|
+
<!-- 功能:功能描述; 作者:LZJ; 时间:2021年11月10日 11:46:03-->
|
|
2
|
+
<template>
|
|
3
|
+
<div id="CommonDatePicker">
|
|
4
|
+
<van-field v-show="item.show !== false" :ref="item['prop']" v-model="model[item['prop']]" :label-class="item.labelClass" :label-width="item.labelWidth" :class="[item.class, underLine ? 'underLine' : '']" class="field-select" :required="item.required" readonly :type="item.displayType || 'textarea'" :rows="item.displayRows || '1'" :autosize="typeof item.autosize === 'function' ? item.autosize() : true" :right-icon="item.readOnly && item.cientshow ? '' : 'arrow'" :label="item.title" :name="item.prop" :rules="item.rule" :placeholder="item.placeholder || $t('financialinfo.carinfo.42bfwl')" :input-align="item.inputAlign || 'right'" @input="fieldChange($event, item, model)" @click="fieldClick($event, item)">
|
|
5
|
+
<template #label>
|
|
6
|
+
<span v-if="item.rule && item.rule[0].required" class="c-ff5c5c ft14 line-height21">*</span>
|
|
7
|
+
<span class="title">{{ item.title }}</span>
|
|
8
|
+
</template>
|
|
9
|
+
</van-field>
|
|
10
|
+
<van-popup v-model="showPop" round position="bottom" :closeable="true" get-container="#app" class="over-hidden ps-f" :item-height="`${48 / 37.5}rem`" :close-icon="'https://dop-pro-1251973116.file.myqcloud.com/upload/img/funzg/icon_zhankailine.png'" :style="{ height: '40%' }">
|
|
11
|
+
<van-datetime-picker v-model="modelDate" type="date" :confirm-button-text="$t('productcomponents.compareproup.tg417c')" :cancel-button-text="$t('dataenrichcompoentns.basicinfoform.434f5b')" :title="$t('commonform.commondatepicker.3y9tp1')" :min-date="minDate" :max-date="maxDate" :formatter="formatter" @confirm="(value, pIdx) => onConfirm(value, pIdx, index, item, model)" @cancel="showPop = false" />
|
|
12
|
+
</van-popup>
|
|
13
|
+
</div>
|
|
14
|
+
</template>
|
|
15
|
+
|
|
16
|
+
<script>
|
|
17
|
+
import { getTranslateMonth } from "../../assets/vantLang";
|
|
18
|
+
export default {
|
|
19
|
+
// 组件名称
|
|
20
|
+
name: "CommonDatePicker",
|
|
21
|
+
// 局部注册的组件
|
|
22
|
+
components: {},
|
|
23
|
+
// 组件参数 接收来自父组件的数据
|
|
24
|
+
props: {
|
|
25
|
+
item: {
|
|
26
|
+
type: Object,
|
|
27
|
+
default: () => {},
|
|
28
|
+
},
|
|
29
|
+
index: {
|
|
30
|
+
type: Number,
|
|
31
|
+
default: 0,
|
|
32
|
+
},
|
|
33
|
+
model: {
|
|
34
|
+
type: Object,
|
|
35
|
+
default: () => {},
|
|
36
|
+
},
|
|
37
|
+
cellData: {
|
|
38
|
+
type: Array,
|
|
39
|
+
default: () => [],
|
|
40
|
+
},
|
|
41
|
+
underLine: {
|
|
42
|
+
type: Boolean,
|
|
43
|
+
default: () => false,
|
|
44
|
+
},
|
|
45
|
+
},
|
|
46
|
+
// 组件状态值
|
|
47
|
+
data() {
|
|
48
|
+
return {
|
|
49
|
+
modelDate: new Date(),
|
|
50
|
+
showPop: false,
|
|
51
|
+
};
|
|
52
|
+
},
|
|
53
|
+
computed: {
|
|
54
|
+
maxDate() {
|
|
55
|
+
if (!this.item.maxDate || this.item.maxDate === "current") return new Date();
|
|
56
|
+
const a = this.item.maxDate;
|
|
57
|
+
const timeArr = a.split(",");
|
|
58
|
+
if (timeArr[2]) {
|
|
59
|
+
return new Date(+timeArr[0], +timeArr[1], +timeArr[2]);
|
|
60
|
+
}
|
|
61
|
+
return new Date(+timeArr[0], +timeArr[1]);
|
|
62
|
+
},
|
|
63
|
+
minDate() {
|
|
64
|
+
if (!this.item.minDate) return new Date("1949/12/1");
|
|
65
|
+
if (this.item.minDate === "current") return new Date();
|
|
66
|
+
const a = this.item.minDate || "1949,10";
|
|
67
|
+
const timeArr = a.split(",");
|
|
68
|
+
if (timeArr[2]) {
|
|
69
|
+
return new Date(+timeArr[0], +timeArr[1], +timeArr[2]);
|
|
70
|
+
}
|
|
71
|
+
return new Date(+timeArr[0], +timeArr[1]);
|
|
72
|
+
},
|
|
73
|
+
},
|
|
74
|
+
// 侦听器
|
|
75
|
+
watch: {
|
|
76
|
+
model: {
|
|
77
|
+
deep: true,
|
|
78
|
+
immediate: true,
|
|
79
|
+
handler(val) {
|
|
80
|
+
const date = val[this.item["prop"]];
|
|
81
|
+
if (!date) return;
|
|
82
|
+
const year = date.substring(0, 4);
|
|
83
|
+
const month = date.substring(5, 7);
|
|
84
|
+
const day = date.substring(8, 10);
|
|
85
|
+
this.modelDate = (date && new Date(year, month - 1, day)) || new Date(+new Date().getFullYear() - 28, 10, 1);
|
|
86
|
+
},
|
|
87
|
+
},
|
|
88
|
+
item: {
|
|
89
|
+
deep: true,
|
|
90
|
+
immediate: true,
|
|
91
|
+
handler(val) {},
|
|
92
|
+
},
|
|
93
|
+
},
|
|
94
|
+
methods: {
|
|
95
|
+
formatter(type, val) {
|
|
96
|
+
if (type === "year") {
|
|
97
|
+
return `${val}`;
|
|
98
|
+
} else if (type === "month") {
|
|
99
|
+
return getTranslateMonth(val, "simple");
|
|
100
|
+
} else if (type === "day") {
|
|
101
|
+
return `${val}`;
|
|
102
|
+
}
|
|
103
|
+
return val;
|
|
104
|
+
},
|
|
105
|
+
onConfirm(value, pIdx, index, item, model) {
|
|
106
|
+
const obj = {
|
|
107
|
+
value,
|
|
108
|
+
pIdx,
|
|
109
|
+
index,
|
|
110
|
+
item,
|
|
111
|
+
model,
|
|
112
|
+
};
|
|
113
|
+
this.showPop = false;
|
|
114
|
+
this.$emit("onConfirmPicker", obj);
|
|
115
|
+
},
|
|
116
|
+
fieldChange(val, item, model, allDataArr = this.cellData) {
|
|
117
|
+
const obj = {
|
|
118
|
+
val,
|
|
119
|
+
item,
|
|
120
|
+
model,
|
|
121
|
+
allDataArr,
|
|
122
|
+
};
|
|
123
|
+
this.$emit("pickerFieldChange", obj);
|
|
124
|
+
},
|
|
125
|
+
fieldClick(event, item) {
|
|
126
|
+
if (item.readOnly) {
|
|
127
|
+
event.preventDefault();
|
|
128
|
+
event.stopPropagation();
|
|
129
|
+
if (item.message) {
|
|
130
|
+
this.$toast(item.message);
|
|
131
|
+
}
|
|
132
|
+
return;
|
|
133
|
+
}
|
|
134
|
+
if (!item.canClick) {
|
|
135
|
+
this.showPop = true;
|
|
136
|
+
}
|
|
137
|
+
},
|
|
138
|
+
},
|
|
139
|
+
};
|
|
140
|
+
</script>
|
|
141
|
+
|
|
142
|
+
<!--使用了scoped属性之后,父组件的style样式将不会渗透到子组件中,-->
|
|
143
|
+
<style scoped lang="less">
|
|
144
|
+
.colorgray {
|
|
145
|
+
.title {
|
|
146
|
+
color: #c8c9cc !important;
|
|
147
|
+
}
|
|
148
|
+
/deep/ .van-field__control {
|
|
149
|
+
color: #c8c9cc !important;
|
|
150
|
+
}
|
|
151
|
+
}
|
|
152
|
+
</style>
|