@opendesign-plus-test/components 0.0.1-rc.34 → 0.0.1-rc.35
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/dist/chunk-OElCookieNotice.cjs.js +1 -1
- package/dist/chunk-OElCookieNotice.es.js +68 -62
- package/dist/components/activity/composables/useActivityConfig.d.ts +17 -0
- package/dist/components/activity/config.d.ts +0 -14
- package/dist/components/meeting/composables/useMeetingConfig.d.ts +14 -0
- package/dist/components/meeting/config.d.ts +1 -16
- package/dist/components/meeting/types.d.ts +1 -0
- package/dist/components/meeting/utils.d.ts +1 -15
- package/dist/components.cjs.js +39 -39
- package/dist/components.css +1 -1
- package/dist/components.es.js +10456 -10473
- package/package.json +1 -1
- package/src/components/activity/OActivityApproval.vue +3 -4
- package/src/components/activity/OActivityForm.vue +5 -4
- package/src/components/activity/OMyActivityCalendar.vue +3 -4
- package/src/components/activity/composables/useActivityConfig.ts +141 -0
- package/src/components/activity/config.ts +1 -141
- package/src/components/meeting/OMeetingCalendar.vue +7 -9
- package/src/components/meeting/OMeetingForm.vue +11 -18
- package/src/components/meeting/OMyMeetingCalendar.vue +4 -8
- package/src/components/meeting/OSigMeetingCalendar.vue +3 -5
- package/src/components/meeting/components/OMeetingCalendarList.vue +7 -8
- package/src/components/meeting/components/OMeetingDetail.vue +9 -8
- package/src/components/meeting/components/OSigMeetingAside.vue +3 -1
- package/src/components/meeting/composables/useMeetingConfig.ts +111 -0
- package/src/components/meeting/config.ts +58 -120
- package/src/components/meeting/types.ts +1 -0
- package/src/components/meeting/utils.ts +69 -122
- package/src/i18n/en.ts +17 -14
- package/src/i18n/zh.ts +3 -0
package/package.json
CHANGED
|
@@ -15,15 +15,14 @@ import {
|
|
|
15
15
|
import { useScreen } from '@opendesign-plus/composables';
|
|
16
16
|
import { onMounted, watch, ref, reactive, computed } from 'vue';
|
|
17
17
|
import { ActivityItemT, ActivityTablePropsT, ReviewParamsT, TypeOptionT } from './types';
|
|
18
|
-
import {
|
|
18
|
+
import { useActivityConfig } from './composables/useActivityConfig';
|
|
19
19
|
import ThFilter from '../common/ThFilter.vue';
|
|
20
20
|
import OMeetingDetail from '@/components/meeting/components/OMeetingDetail.vue';
|
|
21
21
|
import { useI18n } from '@/i18n';
|
|
22
22
|
|
|
23
23
|
const { t, locale } = useI18n();
|
|
24
24
|
const isZh = computed(() => locale.value === 'zh');
|
|
25
|
-
const approvalStatusMap =
|
|
26
|
-
const statusMap = getStatusMap();
|
|
25
|
+
const { approvalStatusMap, statusMap } = useActivityConfig();
|
|
27
26
|
|
|
28
27
|
|
|
29
28
|
const message = useMessage(null);
|
|
@@ -58,7 +57,7 @@ const sortTime = () => {
|
|
|
58
57
|
const statusValue = ref();
|
|
59
58
|
const statusOptions = computed<TypeOptionT[]>(() => {
|
|
60
59
|
let list: TypeOptionT[] | { label: string; value: string; }[] = [];
|
|
61
|
-
approvalStatusMap.forEach((item) => {
|
|
60
|
+
approvalStatusMap.value.forEach((item) => {
|
|
62
61
|
list.push(item);
|
|
63
62
|
});
|
|
64
63
|
return list.slice(1);
|
|
@@ -15,9 +15,10 @@ import { computed, ref, watch } from 'vue';
|
|
|
15
15
|
import { ActivityFormPropsT, ParamsItemT } from './types';
|
|
16
16
|
import { useScreen } from '@opendesign-plus/composables';
|
|
17
17
|
import { dayjs, ElDatePicker } from 'element-plus';
|
|
18
|
-
import {
|
|
18
|
+
import { WEBSITE_REGEXP } from './config';
|
|
19
19
|
import { EMAIL_REGEX } from '@/components/meeting/config.ts';
|
|
20
20
|
import { useI18n } from '@/i18n';
|
|
21
|
+
import { useActivityConfig } from './composables/useActivityConfig';
|
|
21
22
|
|
|
22
23
|
const emits = defineEmits(['confirm', 'close']);
|
|
23
24
|
|
|
@@ -25,7 +26,7 @@ const message = useMessage(null);
|
|
|
25
26
|
const { lePadV } = useScreen();
|
|
26
27
|
const { t } = useI18n();
|
|
27
28
|
const $t = t;
|
|
28
|
-
const
|
|
29
|
+
const { activityTypeMap } = useActivityConfig();
|
|
29
30
|
|
|
30
31
|
interface TypeOptionT {
|
|
31
32
|
label: string;
|
|
@@ -226,7 +227,7 @@ const approverList = computed(() => {
|
|
|
226
227
|
|
|
227
228
|
const typeValue = ref<string>('');
|
|
228
229
|
const typeOptions = ref<TypeOptionT[]>([]); // 活动类型
|
|
229
|
-
|
|
230
|
+
activityTypeMap.value.forEach((item) => {
|
|
230
231
|
typeOptions.value.push(item);
|
|
231
232
|
});
|
|
232
233
|
const changeType = (val: SelectValueT) => {
|
|
@@ -279,7 +280,7 @@ watch(
|
|
|
279
280
|
organizer,
|
|
280
281
|
} as ParamsItemT;
|
|
281
282
|
form.value = { ...params };
|
|
282
|
-
typeValue.value =
|
|
283
|
+
typeValue.value = activityTypeMap.value.get(val.activity_type)?.label;
|
|
283
284
|
form.value.start_date = `${ form.value.start_date } ${ form.value.start }`;
|
|
284
285
|
form.value.end_date = `${ form.value.end_date } ${ form.value.end }`;
|
|
285
286
|
}
|
|
@@ -26,15 +26,14 @@ import IconEvent from '~icons/meeting/icon-event.svg';
|
|
|
26
26
|
import type { ActivityItemT, MyActivityCalendarPropsT, ParamsItemT } from './types';
|
|
27
27
|
import { useScreen } from '@opendesign-plus/composables';
|
|
28
28
|
import { formatDate, getDateNumber } from '../meeting/utils';
|
|
29
|
-
import {
|
|
29
|
+
import { useActivityConfig } from './composables/useActivityConfig';
|
|
30
30
|
import { PageParamsT } from '../meeting/types';
|
|
31
31
|
import OMeetingDetail from '@/components/meeting/components/OMeetingDetail.vue';
|
|
32
32
|
import { useI18n, Locales } from '@/i18n';
|
|
33
33
|
|
|
34
34
|
const { t, locale } = useI18n();
|
|
35
35
|
const isZh = computed(() => locale.value === Locales.ZH);
|
|
36
|
-
const statusMap =
|
|
37
|
-
const acticityTypeMap = getActicityTypeMap();
|
|
36
|
+
const { statusMap, activityTypeMap } = useActivityConfig();
|
|
38
37
|
|
|
39
38
|
const formatMonthYear = (date: string | Date) => {
|
|
40
39
|
const d = dayjs(date || new Date());
|
|
@@ -628,7 +627,7 @@ const deleteActions = computed<DialogActionT[]>(() => {
|
|
|
628
627
|
<div class="act-info">
|
|
629
628
|
<span class="date-range">{{ row.dateRange }}</span>
|
|
630
629
|
<ODivider direction="v"></ODivider>
|
|
631
|
-
<span>{{
|
|
630
|
+
<span>{{ activityTypeMap.get(row.activity_type)?.label }}</span>
|
|
632
631
|
</div>
|
|
633
632
|
</div>
|
|
634
633
|
</div>
|
|
@@ -0,0 +1,141 @@
|
|
|
1
|
+
import { computed } from 'vue';
|
|
2
|
+
import { useI18n } from '@/i18n';
|
|
3
|
+
|
|
4
|
+
export const useActivityConfig = () => {
|
|
5
|
+
const { t } = useI18n();
|
|
6
|
+
|
|
7
|
+
const activityTypeMap = computed(() => new Map([
|
|
8
|
+
[
|
|
9
|
+
1,
|
|
10
|
+
{
|
|
11
|
+
label: t('meeting.offline'),
|
|
12
|
+
value: 1,
|
|
13
|
+
},
|
|
14
|
+
],
|
|
15
|
+
[
|
|
16
|
+
2,
|
|
17
|
+
{
|
|
18
|
+
label: t('meeting.online'),
|
|
19
|
+
value: 2,
|
|
20
|
+
},
|
|
21
|
+
],
|
|
22
|
+
[
|
|
23
|
+
3,
|
|
24
|
+
{
|
|
25
|
+
label: t('meeting.onlineOffline'),
|
|
26
|
+
value: 3,
|
|
27
|
+
},
|
|
28
|
+
],
|
|
29
|
+
]));
|
|
30
|
+
|
|
31
|
+
const statusMap = computed(() => new Map([
|
|
32
|
+
[
|
|
33
|
+
1,
|
|
34
|
+
{
|
|
35
|
+
id: 'draft',
|
|
36
|
+
label: t('meeting.statusDraft'),
|
|
37
|
+
text: t('meeting.statusDraft'),
|
|
38
|
+
value: 1,
|
|
39
|
+
},
|
|
40
|
+
],
|
|
41
|
+
[
|
|
42
|
+
2,
|
|
43
|
+
{
|
|
44
|
+
id: 'under-review',
|
|
45
|
+
label: t('meeting.statusUnderReview'),
|
|
46
|
+
text: t('meeting.statusPending'),
|
|
47
|
+
value: 2,
|
|
48
|
+
},
|
|
49
|
+
],
|
|
50
|
+
[
|
|
51
|
+
3,
|
|
52
|
+
{
|
|
53
|
+
id: 'registration',
|
|
54
|
+
label: t('meeting.statusRegistering'),
|
|
55
|
+
text: t('meeting.statusApproved'),
|
|
56
|
+
value: 3,
|
|
57
|
+
},
|
|
58
|
+
],
|
|
59
|
+
[
|
|
60
|
+
4,
|
|
61
|
+
{
|
|
62
|
+
id: 'in-progress',
|
|
63
|
+
label: t('meeting.statusInProgress'),
|
|
64
|
+
text: t('meeting.statusApproved'),
|
|
65
|
+
value: 4,
|
|
66
|
+
},
|
|
67
|
+
],
|
|
68
|
+
[
|
|
69
|
+
5,
|
|
70
|
+
{
|
|
71
|
+
id: 'ended',
|
|
72
|
+
label: t('meeting.statusEnded'),
|
|
73
|
+
text: t('meeting.statusEnded'),
|
|
74
|
+
value: 5,
|
|
75
|
+
},
|
|
76
|
+
],
|
|
77
|
+
[
|
|
78
|
+
6,
|
|
79
|
+
{
|
|
80
|
+
id: 'modified',
|
|
81
|
+
label: t('meeting.statusModified'),
|
|
82
|
+
text: t('meeting.statusModified'),
|
|
83
|
+
value: 6,
|
|
84
|
+
},
|
|
85
|
+
],
|
|
86
|
+
[
|
|
87
|
+
7,
|
|
88
|
+
{
|
|
89
|
+
id: 'reject',
|
|
90
|
+
label: t('meeting.statusRejected'),
|
|
91
|
+
text: t('meeting.statusRejected'),
|
|
92
|
+
value: 7,
|
|
93
|
+
},
|
|
94
|
+
],
|
|
95
|
+
]));
|
|
96
|
+
|
|
97
|
+
const approvalStatusMap = computed(() => new Map([
|
|
98
|
+
[
|
|
99
|
+
'all',
|
|
100
|
+
{
|
|
101
|
+
label: t('common.all'),
|
|
102
|
+
value: 'all',
|
|
103
|
+
},
|
|
104
|
+
],
|
|
105
|
+
[
|
|
106
|
+
'rejected',
|
|
107
|
+
{
|
|
108
|
+
label: t('meeting.statusRejected'),
|
|
109
|
+
value: 'rejected',
|
|
110
|
+
},
|
|
111
|
+
],
|
|
112
|
+
[
|
|
113
|
+
'approved',
|
|
114
|
+
{
|
|
115
|
+
label: t('meeting.statusApproved'),
|
|
116
|
+
value: 'approved',
|
|
117
|
+
},
|
|
118
|
+
],
|
|
119
|
+
[
|
|
120
|
+
'publish',
|
|
121
|
+
{
|
|
122
|
+
label: t('meeting.statusPending'),
|
|
123
|
+
value: 'publish',
|
|
124
|
+
},
|
|
125
|
+
],
|
|
126
|
+
[
|
|
127
|
+
'cancel',
|
|
128
|
+
{
|
|
129
|
+
label: t('meeting.statusCanceled'),
|
|
130
|
+
value: 'cancel',
|
|
131
|
+
},
|
|
132
|
+
],
|
|
133
|
+
]));
|
|
134
|
+
|
|
135
|
+
return {
|
|
136
|
+
t,
|
|
137
|
+
activityTypeMap,
|
|
138
|
+
statusMap,
|
|
139
|
+
approvalStatusMap,
|
|
140
|
+
};
|
|
141
|
+
};
|
|
@@ -1,141 +1 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
export const getActicityTypeMap = () => {
|
|
4
|
-
const { t } = useI18n();
|
|
5
|
-
return new Map([
|
|
6
|
-
[
|
|
7
|
-
1,
|
|
8
|
-
{
|
|
9
|
-
label: t('meeting.offline'),
|
|
10
|
-
value: 1,
|
|
11
|
-
},
|
|
12
|
-
],
|
|
13
|
-
[
|
|
14
|
-
2,
|
|
15
|
-
{
|
|
16
|
-
label: t('meeting.online'),
|
|
17
|
-
value: 2,
|
|
18
|
-
},
|
|
19
|
-
],
|
|
20
|
-
[
|
|
21
|
-
3,
|
|
22
|
-
{
|
|
23
|
-
label: t('meeting.onlineOffline'),
|
|
24
|
-
value: 3,
|
|
25
|
-
},
|
|
26
|
-
],
|
|
27
|
-
]);
|
|
28
|
-
};
|
|
29
|
-
|
|
30
|
-
export const WEBSITE_REGEXP = /^http(s)?:\/\/([\w-]+\.)+[\w-]+(\/[\w ./?%&=-]*)?$/;
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
export const getStatusMap = () => {
|
|
34
|
-
const { t } = useI18n();
|
|
35
|
-
return new Map([
|
|
36
|
-
[
|
|
37
|
-
1,
|
|
38
|
-
{
|
|
39
|
-
id: 'draft',
|
|
40
|
-
label: t('meeting.statusDraft'),
|
|
41
|
-
text: t('meeting.statusDraft'),
|
|
42
|
-
value: 1,
|
|
43
|
-
},
|
|
44
|
-
],
|
|
45
|
-
[
|
|
46
|
-
2,
|
|
47
|
-
{
|
|
48
|
-
id: 'under-review',
|
|
49
|
-
label: t('meeting.statusUnderReview'),
|
|
50
|
-
text: t('meeting.statusPending'),
|
|
51
|
-
value: 2,
|
|
52
|
-
},
|
|
53
|
-
],
|
|
54
|
-
[
|
|
55
|
-
3,
|
|
56
|
-
{
|
|
57
|
-
id: 'registration',
|
|
58
|
-
label: t('meeting.statusRegistering'),
|
|
59
|
-
text: t('meeting.statusApproved'),
|
|
60
|
-
value: 3,
|
|
61
|
-
},
|
|
62
|
-
],
|
|
63
|
-
[
|
|
64
|
-
4,
|
|
65
|
-
{
|
|
66
|
-
id: 'in-progress',
|
|
67
|
-
label: t('meeting.statusInProgress'),
|
|
68
|
-
text: t('meeting.statusApproved'),
|
|
69
|
-
value: 4,
|
|
70
|
-
},
|
|
71
|
-
],
|
|
72
|
-
[
|
|
73
|
-
5,
|
|
74
|
-
{
|
|
75
|
-
id: 'ended',
|
|
76
|
-
label: t('meeting.statusEnded'),
|
|
77
|
-
text: t('meeting.statusEnded'),
|
|
78
|
-
value: 5,
|
|
79
|
-
},
|
|
80
|
-
],
|
|
81
|
-
[
|
|
82
|
-
6,
|
|
83
|
-
{
|
|
84
|
-
id: 'modified',
|
|
85
|
-
label: t('meeting.statusModified'),
|
|
86
|
-
text: t('meeting.statusModified'),
|
|
87
|
-
value: 6,
|
|
88
|
-
},
|
|
89
|
-
],
|
|
90
|
-
[
|
|
91
|
-
7,
|
|
92
|
-
{
|
|
93
|
-
id: 'reject',
|
|
94
|
-
label: t('meeting.statusRejected'),
|
|
95
|
-
text: t('meeting.statusRejected'),
|
|
96
|
-
value: 7,
|
|
97
|
-
},
|
|
98
|
-
],
|
|
99
|
-
]);
|
|
100
|
-
};
|
|
101
|
-
|
|
102
|
-
export const getApprovalStatusMap = () => {
|
|
103
|
-
const { t } = useI18n();
|
|
104
|
-
return new Map([
|
|
105
|
-
[
|
|
106
|
-
'all',
|
|
107
|
-
{
|
|
108
|
-
label: t('common.all'),
|
|
109
|
-
value: 'all',
|
|
110
|
-
},
|
|
111
|
-
],
|
|
112
|
-
[
|
|
113
|
-
'rejected',
|
|
114
|
-
{
|
|
115
|
-
label: t('meeting.statusRejected'),
|
|
116
|
-
value: 'rejected',
|
|
117
|
-
},
|
|
118
|
-
],
|
|
119
|
-
[
|
|
120
|
-
'approved',
|
|
121
|
-
{
|
|
122
|
-
label: t('meeting.statusApproved'),
|
|
123
|
-
value: 'approved',
|
|
124
|
-
},
|
|
125
|
-
],
|
|
126
|
-
[
|
|
127
|
-
'publish',
|
|
128
|
-
{
|
|
129
|
-
label: t('meeting.statusPending'),
|
|
130
|
-
value: 'publish',
|
|
131
|
-
},
|
|
132
|
-
],
|
|
133
|
-
[
|
|
134
|
-
'cancel',
|
|
135
|
-
{
|
|
136
|
-
label: t('meeting.statusCanceled'),
|
|
137
|
-
value: 'cancel',
|
|
138
|
-
},
|
|
139
|
-
],
|
|
140
|
-
]);
|
|
141
|
-
};
|
|
1
|
+
export const WEBSITE_REGEXP = /^http(s)?:\/\/([\w-]+\.)+[\w-]+(\/[\w ./?%&=-]*)?$/;
|
|
@@ -17,10 +17,10 @@ import OMeetingCalendarList from './components/OMeetingCalendarList.vue';
|
|
|
17
17
|
import IconEvent from '~icons/meeting/icon-event.svg';
|
|
18
18
|
import IconSummit from '~icons/meeting/icon-summit.svg';
|
|
19
19
|
import IconMeeting from '~icons/meeting/icon-meet.svg';
|
|
20
|
-
import { Locales
|
|
21
|
-
import {
|
|
20
|
+
import { Locales } from '@/i18n';
|
|
21
|
+
import { useMeetingConfig } from './composables/useMeetingConfig';
|
|
22
22
|
import { CalendarDataType, GroupItemT, MeetingCalendarPropsT, MeetingGroupType } from './types.ts';
|
|
23
|
-
import { formatDate
|
|
23
|
+
import { formatDate } from './utils.ts';
|
|
24
24
|
import { useDebounceFn } from '@vueuse/core';
|
|
25
25
|
|
|
26
26
|
const props = withDefaults(defineProps<MeetingCalendarPropsT>(), {
|
|
@@ -31,11 +31,10 @@ const props = withDefaults(defineProps<MeetingCalendarPropsT>(), {
|
|
|
31
31
|
groupType: MeetingGroupType.SIG,
|
|
32
32
|
});
|
|
33
33
|
|
|
34
|
-
const { t, locale } =
|
|
34
|
+
const { t, locale, meetingTabs, getConfig } = useMeetingConfig();
|
|
35
35
|
const isEn = computed(() => locale.value === Locales.EN);
|
|
36
36
|
|
|
37
|
-
|
|
38
|
-
const latestDay = ref<string>(''); // 截止当天最新的活动日期
|
|
37
|
+
const latestDay = ref<string>('');
|
|
39
38
|
const dateList = ref([]);
|
|
40
39
|
const summitData = ref([]);
|
|
41
40
|
const summitDates = ref([]);
|
|
@@ -43,11 +42,10 @@ const eventsData = ref([]);
|
|
|
43
42
|
const eventsDates = ref([]);
|
|
44
43
|
const allDates = ref<string[]>([]);
|
|
45
44
|
const meetingData = ref([]);
|
|
46
|
-
// 日历展示时间限制
|
|
47
45
|
const limitTime = '2021-01-01';
|
|
48
|
-
const tabType = ref(
|
|
46
|
+
const tabType = ref(CalendarDataType.ALL);
|
|
49
47
|
const tabs = computed(() => {
|
|
50
|
-
let list =
|
|
48
|
+
let list = meetingTabs.value;
|
|
51
49
|
if (props.hiddenEvents) {
|
|
52
50
|
list = list.filter((item) => item.value !== CalendarDataType.EVENTS);
|
|
53
51
|
}
|
|
@@ -21,20 +21,13 @@ import IconHelp from '~icons/meeting/icon-help.svg';
|
|
|
21
21
|
import IconTip from '~icons/meeting/icon-tip.svg';
|
|
22
22
|
import { MeetingFormPropsT, MeetingGroupType, MeetingPostT, OptionItemT } from './types';
|
|
23
23
|
import dayjs from 'dayjs';
|
|
24
|
-
import { findLabelFromOptions, formatDateNumber, getDateNumber
|
|
25
|
-
import {
|
|
26
|
-
CYCLE_TYPE_OPTIONS0,
|
|
27
|
-
EMAIL_REGEX,
|
|
28
|
-
INTERVAL_DAY,
|
|
29
|
-
INTERVAL_MONTH,
|
|
30
|
-
INTERVAL_WEEK,
|
|
31
|
-
INTERVAL_WEEK_OPTIONS,
|
|
32
|
-
} from './config';
|
|
24
|
+
import { findLabelFromOptions, formatDateNumber, getDateNumber } from './utils';
|
|
25
|
+
import { EMAIL_REGEX, INTERVAL_DAY, INTERVAL_MONTH, INTERVAL_WEEK } from './config';
|
|
33
26
|
import OMeetingCalendarSelector from './components/OMeetingCalendarSelector.vue';
|
|
34
27
|
import { useScreen } from '@opendesign-plus/composables';
|
|
35
|
-
import {
|
|
28
|
+
import { useMeetingConfig } from './composables/useMeetingConfig';
|
|
36
29
|
|
|
37
|
-
const { t, locale } =
|
|
30
|
+
const { t, locale, cycleTypeOptions0, intervalWeekOptions, getPlatformLabel } = useMeetingConfig();
|
|
38
31
|
|
|
39
32
|
const props = withDefaults(defineProps<MeetingFormPropsT>(), {
|
|
40
33
|
isSub: false,
|
|
@@ -44,9 +37,8 @@ const props = withDefaults(defineProps<MeetingFormPropsT>(), {
|
|
|
44
37
|
});
|
|
45
38
|
const message = useMessage(null);
|
|
46
39
|
|
|
47
|
-
const cycleTypeOptions =
|
|
48
|
-
|
|
49
|
-
const weekOptions = ref(INTERVAL_WEEK_OPTIONS);
|
|
40
|
+
const cycleTypeOptions = cycleTypeOptions0;
|
|
41
|
+
const weekOptions = intervalWeekOptions;
|
|
50
42
|
|
|
51
43
|
const intervalTypeMax = computed(() => {
|
|
52
44
|
return findLabelFromOptions(form.value.cycle_type, cycleTypeOptions.value, 'max');
|
|
@@ -616,9 +608,10 @@ defineExpose({
|
|
|
616
608
|
</OFormItem>
|
|
617
609
|
<OFormItem :label="t('meeting.meetingPlatform')" field="platform" :rules="rules.platform">
|
|
618
610
|
<ORadioGroup v-model="form.platform" v-if="!data" :disabled="form.is_cycle">
|
|
619
|
-
<ORadio v-for="item in typeOptions" :key="item.value" :value="item.value">{{ item.label }}
|
|
611
|
+
<ORadio v-for="item in typeOptions" :key="item.value" :value="item.value">{{ getPlatformLabel(item.label) }}
|
|
612
|
+
</ORadio>
|
|
620
613
|
</ORadioGroup>
|
|
621
|
-
<span v-else>{{ form.platform }}</span>
|
|
614
|
+
<span v-else>{{ getPlatformLabel(form.platform) }}</span>
|
|
622
615
|
</OFormItem>
|
|
623
616
|
<OFormItem field="agenda" :label="t('meeting.meetingAgenda')" :rules="rules.genda">
|
|
624
617
|
<OTextarea
|
|
@@ -639,7 +632,7 @@ defineExpose({
|
|
|
639
632
|
<OIcon>
|
|
640
633
|
<IconTip />
|
|
641
634
|
</OIcon>
|
|
642
|
-
<span>{{ t('meeting.meetingRecordDesc', [form.platform]) }}</span>
|
|
635
|
+
<span>{{ t('meeting.meetingRecordDesc', [getPlatformLabel(form.platform)]) }}</span>
|
|
643
636
|
</div>
|
|
644
637
|
</div>
|
|
645
638
|
</template>
|
|
@@ -651,7 +644,7 @@ defineExpose({
|
|
|
651
644
|
<OIcon>
|
|
652
645
|
<IconTip />
|
|
653
646
|
</OIcon>
|
|
654
|
-
<span>{{ t('meeting.meetingRecordDesc', [form.platform]) }}</span>
|
|
647
|
+
<span>{{ t('meeting.meetingRecordDesc', [getPlatformLabel(form.platform)]) }}</span>
|
|
655
648
|
</div>
|
|
656
649
|
</div>
|
|
657
650
|
</template>
|
|
@@ -23,12 +23,12 @@ import OMeetingDetail from './components/OMeetingDetail.vue';
|
|
|
23
23
|
import { MeetingGroupType, MeetingItemT, PageParamsT } from './types.ts';
|
|
24
24
|
import dayjs from 'dayjs';
|
|
25
25
|
import IconMeeting from '~icons/meeting/icon-meet.svg';
|
|
26
|
-
import { INTERVAL_DAY, INTERVAL_MONTH, INTERVAL_WEEK
|
|
26
|
+
import { INTERVAL_DAY, INTERVAL_MONTH, INTERVAL_WEEK } from './config.ts';
|
|
27
27
|
import { formatDate, getDateNumber } from './utils.ts';
|
|
28
|
-
import {
|
|
28
|
+
import { useMeetingConfig } from './composables/useMeetingConfig';
|
|
29
29
|
import { useDebounceFn } from '@vueuse/core';
|
|
30
30
|
import { useScreen } from '@opendesign-plus/composables';
|
|
31
|
-
import { Locales
|
|
31
|
+
import { Locales } from '@/i18n';
|
|
32
32
|
import IconCopy from '~icons/meeting/icon-copy.svg';
|
|
33
33
|
|
|
34
34
|
const message = useMessage(null);
|
|
@@ -40,7 +40,7 @@ const list = ref<MeetingItemT[]>([]); // 列表数据
|
|
|
40
40
|
const originList = ref([]); // 原始数据
|
|
41
41
|
const canLoadMore = computed(() => total.value === null || originList.value.length < total.value);
|
|
42
42
|
const reloadAll = ref(false); // 是否需要清空数据
|
|
43
|
-
const { t, locale } =
|
|
43
|
+
const { t, locale, weekDay, getPointStr, getWeekFromDate } = useMeetingConfig();
|
|
44
44
|
const isEn = computed(() => locale.value === Locales.EN);
|
|
45
45
|
|
|
46
46
|
const props = withDefaults(defineProps<{
|
|
@@ -426,10 +426,6 @@ const groupList = computed(() => {
|
|
|
426
426
|
}, []);
|
|
427
427
|
});
|
|
428
428
|
|
|
429
|
-
const getWeekFromDate = (date) => {
|
|
430
|
-
return WEEKDAY[dayjs(date).day()];
|
|
431
|
-
};
|
|
432
|
-
|
|
433
429
|
// -------------------- 处理滚动事件 --------------------
|
|
434
430
|
const scrollerRef = ref();
|
|
435
431
|
watch(
|
|
@@ -6,19 +6,17 @@ import IconTips from '~icons/components/icon-tips.svg';
|
|
|
6
6
|
import OSigMeetingAside from './components/OSigMeetingAside.vue';
|
|
7
7
|
import { CalendarDataType, MeetingItemT } from './types.ts';
|
|
8
8
|
import { useScreen } from '@opendesign-plus/composables';
|
|
9
|
-
import {
|
|
9
|
+
import { useMeetingConfig } from './composables/useMeetingConfig';
|
|
10
10
|
import OMeetingCalendarList from '@/components/meeting/components/OMeetingCalendarList.vue';
|
|
11
|
-
import { useI18n } from '@/i18n';
|
|
12
11
|
|
|
13
12
|
const props = defineProps<{
|
|
14
|
-
//sig name
|
|
15
13
|
sigName: String;
|
|
16
14
|
getMeetingListRequest: any;
|
|
17
15
|
getDateListRequest: any;
|
|
18
16
|
getEventsListRequest: any;
|
|
19
17
|
dates: String[];
|
|
20
18
|
}>();
|
|
21
|
-
const { t } =
|
|
19
|
+
const { t, meetingTabs } = useMeetingConfig();
|
|
22
20
|
const { lePadV } = useScreen();
|
|
23
21
|
const selectDate = ref<string>('');
|
|
24
22
|
|
|
@@ -257,7 +255,7 @@ onMounted(() => {
|
|
|
257
255
|
</OPopover>
|
|
258
256
|
</div>
|
|
259
257
|
<OTab v-model="tabType" @change="selectTab" :line="false">
|
|
260
|
-
<OTabPane v-for="item in
|
|
258
|
+
<OTabPane v-for="item in meetingTabs.slice(0, -1)" :key="item.value" :value="item.value">
|
|
261
259
|
<template #nav>
|
|
262
260
|
<OIcon>
|
|
263
261
|
<component :is="item.icon" />
|
|
@@ -11,13 +11,12 @@ import IconEvent from '~icons/meeting/icon-event.svg';
|
|
|
11
11
|
import IconSummit from '~icons/meeting/icon-summit.svg';
|
|
12
12
|
import IconMeeting from '~icons/meeting/icon-meet.svg';
|
|
13
13
|
import IconChevronRight from '~icons/components/icon-chevron-right.svg';
|
|
14
|
-
import {
|
|
14
|
+
import { INTERVAL_DAY, INTERVAL_MONTH, INTERVAL_WEEK } from '../config.ts';
|
|
15
|
+
import { formatDate } from '../utils.ts';
|
|
16
|
+
import { useMeetingConfig } from '../composables/useMeetingConfig';
|
|
17
|
+
import { useActivityConfig } from '@/components/activity/composables/useActivityConfig';
|
|
15
18
|
|
|
16
|
-
|
|
17
|
-
import { useI18n } from '@/i18n';
|
|
18
|
-
import { getActicityTypeMap } from '@/components/activity/config.ts';
|
|
19
|
-
|
|
20
|
-
const acticityTypeMap = getActicityTypeMap();
|
|
19
|
+
const { activityTypeMap } = useActivityConfig();
|
|
21
20
|
|
|
22
21
|
const props = withDefaults(defineProps<{
|
|
23
22
|
list: MeetingItemT[];
|
|
@@ -25,7 +24,7 @@ const props = withDefaults(defineProps<{
|
|
|
25
24
|
}>(), {
|
|
26
25
|
list: () => [],
|
|
27
26
|
});
|
|
28
|
-
const { t, locale } =
|
|
27
|
+
const { t, locale, getConfig, getPointStr } = useMeetingConfig();
|
|
29
28
|
const detailRefs = ref([]);
|
|
30
29
|
const message = useMessage();
|
|
31
30
|
const copyInfo = async (idx) => {
|
|
@@ -88,7 +87,7 @@ const computedList = computed(() => {
|
|
|
88
87
|
const type = v.type;
|
|
89
88
|
let dateRange = '';
|
|
90
89
|
if (['activity'].includes(type)) {
|
|
91
|
-
let activity_type =
|
|
90
|
+
let activity_type = activityTypeMap.value.get(v.activity_type)?.label;
|
|
92
91
|
if (v.end_date === v.start_date) {
|
|
93
92
|
return {
|
|
94
93
|
...v,
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
2
|
import { OLink } from '@opensig/opendesign';
|
|
3
3
|
import { computed, ref } from 'vue';
|
|
4
|
-
import { CalendarDataType, MeetingItemT } from '
|
|
4
|
+
import { CalendarDataType, MeetingItemT } from '../types.ts';
|
|
5
5
|
import MoreText from '@/components/common/MoreText.vue';
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
6
|
+
import { formatDate } from '@/components/meeting/utils.ts';
|
|
7
|
+
import { useMeetingConfig } from '../composables/useMeetingConfig';
|
|
8
8
|
|
|
9
9
|
const props = defineProps<{
|
|
10
10
|
data: MeetingItemT;
|
|
11
11
|
from?: string;
|
|
12
12
|
show: boolean;
|
|
13
13
|
}>();
|
|
14
|
-
const { t,
|
|
15
|
-
|
|
14
|
+
const { t, getPlatformLabel } = useMeetingConfig();
|
|
15
|
+
|
|
16
16
|
// 会议详情配置
|
|
17
17
|
const infoList = computed(() =>
|
|
18
18
|
[
|
|
@@ -29,8 +29,9 @@ const infoList = computed(() =>
|
|
|
29
29
|
|
|
30
30
|
|
|
31
31
|
const activityInfoList = computed(() => {
|
|
32
|
-
const isLive = props.data.
|
|
32
|
+
const isLive = props.data.live_url?.length > 0;
|
|
33
33
|
return [
|
|
34
|
+
{ label: t('meeting.activityDetail2'), key: 'agenda', ellipsis: true },
|
|
34
35
|
{ label: t('meeting.startDate'), key: 'start_date_time' },
|
|
35
36
|
{ label: t('meeting.endDate'), key: 'end_date_time' },
|
|
36
37
|
{ label: t('meeting.registrationDeadline'), key: 'register_end_date' },
|
|
@@ -38,10 +39,10 @@ const activityInfoList = computed(() => {
|
|
|
38
39
|
{ label: t('meeting.activityDetailUrl'), key: 'content_url', isLink: true },
|
|
39
40
|
{ label: t('meeting.activityApprover'), key: 'approver' },
|
|
40
41
|
{ label: t('meeting.reviewNotesLabel'), key: 'approve_record', isRecord: true },
|
|
41
|
-
].slice(0, props.from === 'home' ?
|
|
42
|
+
].slice(0, props.from === 'home' ? 5 : 8);
|
|
42
43
|
});
|
|
43
44
|
const activityInfoApprovalList = computed(() => {
|
|
44
|
-
const isLive = props.data.
|
|
45
|
+
const isLive = props.data.live_url?.length > 0;
|
|
45
46
|
return [
|
|
46
47
|
{ label: t('meeting.activityType'), key: 'activity_type', isType: true },
|
|
47
48
|
{ label: isLive ? t('meeting.livePlatform') : t('meeting.activityAddress'), key: 'address' },
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
2
|
import { OIcon, OIconArrowLeft, OIconArrowRight } from '@opensig/opendesign';
|
|
3
3
|
import IconMeetinging from '~icons/meeting/icon-meet.svg';
|
|
4
|
-
import {
|
|
4
|
+
import { useMeetingConfig } from '@/components/meeting/composables/useMeetingConfig';
|
|
5
5
|
import { CalendarDataType } from '@/components/meeting';
|
|
6
6
|
|
|
7
|
+
const { getConfig } = useMeetingConfig();
|
|
8
|
+
|
|
7
9
|
const props = defineProps<{
|
|
8
10
|
data: any[];
|
|
9
11
|
current: number;
|