Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
AI100
ai100
提交
d372d726
ai100
项目概览
AI100
/
ai100
通知
7
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
ai100
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
d372d726
编写于
10月 31, 2023
作者:
璃白.
🌻
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
✨
add pwd of message send
上级
a4473eb4
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
97 addition
and
67 deletion
+97
-67
pages/admin/index.vue
pages/admin/index.vue
+25
-16
pages/admin/index/manage/message/index.vue
pages/admin/index/manage/message/index.vue
+66
-45
pages/admin/index/manage/wxmessage/index.vue
pages/admin/index/manage/wxmessage/index.vue
+6
-6
未找到文件。
pages/admin/index.vue
浏览文件 @
d372d726
<
template
>
<div
class=
"fixHeight"
>
<TransitionRoot
as=
"template"
:show=
"sidebarOpen"
>
<Dialog
as=
"div"
class=
"fixed inset-0 z-40 flex md:hidden"
@
close=
"sidebarOpen = false"
>
<Dialog
as=
"div"
class=
"fixed inset-0 z-40 flex md:hidden"
@
close=
"sidebarOpen = false"
>
<TransitionChild
as=
"template"
enter=
"transition-opacity ease-linear duration-300"
...
...
@@ -45,7 +49,11 @@
</TransitionChild>
<div
class=
"flex-1 h-0 pt-5 pb-4 overflow-y-auto"
>
<div
class=
"flex-shrink-0 flex items-center px-4"
>
<img
class=
"h-8 w-auto"
src=
"@/assets/imgs/logo.png"
alt=
"Workflow"
/>
<img
class=
"h-8 w-auto"
src=
"@/assets/imgs/logo.png"
alt=
"Workflow"
/>
</div>
<nav
class=
"mt-10 px-2 space-y-1"
>
<nuxt-link
...
...
@@ -88,7 +96,9 @@
>
<!-- Sidebar component, swap this element with another sidebar if you like -->
<div
class=
"flex-1 flex flex-col min-h-0 bg-white"
>
<div
class=
"flex-1 flex justify-start flex-col pt-5 pb-4 overflow-y-auto"
>
<div
class=
"flex-1 flex justify-start flex-col pt-5 pb-4 overflow-y-auto"
>
<nav
class=
"mt-16 flex-1 px-2"
>
<div
class=
"text-sm text-gray-500 my-4 ml-2"
>
数据报表
</div>
<nuxt-link
...
...
@@ -166,7 +176,8 @@
: 'cursor-pointer text-gray-800',
'group flex items-center px-14 py-2 text-sm font-medium rounded-sm'
]"
>
{{
subItem
.
name
}}
</nuxt-link>
>
{{
subItem
.
name
}}
</nuxt-link
>
</DisclosurePanel>
</Disclosure>
<nuxt-link
...
...
@@ -236,7 +247,11 @@ import {
MenuIcon
,
UsersIcon
,
ChatIcon
,
SpeakerphoneIcon
,
CurrencyYenIcon
,
VideoCameraIcon
,
TicketIcon
,
ChatAltIcon
,
XIcon
}
from
"
@heroicons/vue/outline/index
"
;
import
{
SourceType
}
from
"
~~/types
"
;
...
...
@@ -291,15 +306,15 @@ const adminMenu = computed(() => {
{
name
:
"
公开课管理
"
,
href
:
"
/admin/manage/
"
,
icon
:
Chat
Icon
,
icon
:
VideoCamera
Icon
,
children
:
[
{
name
:
"
视频
公开课
管理
"
,
name
:
"
视频管理
"
,
href
:
"
/admin/manage/course
"
,
current
:
path
.
value
.
includes
(
"
manage/course
"
)
},
{
name
:
"
文档
公开课
管理
"
,
name
:
"
文档管理
"
,
href
:
"
/admin/manage/textcourse
"
,
current
:
path
.
value
.
includes
(
"
manage/textcourse
"
)
},
...
...
@@ -313,7 +328,7 @@ const adminMenu = computed(() => {
{
name
:
"
广告活动管理
"
,
href
:
"
/admin/manage/
"
,
icon
:
Chat
Icon
,
icon
:
Speakerphone
Icon
,
children
:
[
{
name
:
"
蒙版弹框管理
"
,
...
...
@@ -325,7 +340,7 @@ const adminMenu = computed(() => {
{
name
:
"
活动管理
"
,
href
:
"
/admin/manage/activity
"
,
icon
:
Cha
tIcon
,
icon
:
Ticke
tIcon
,
current
:
path
.
value
.
includes
(
"
manage/activity
"
)
},
{
...
...
@@ -337,14 +352,8 @@ const adminMenu = computed(() => {
{
name
:
"
短信群发
"
,
href
:
"
/admin/manage/message
"
,
icon
:
ChatIcon
,
icon
:
Chat
Alt
Icon
,
current
:
path
.
value
.
includes
(
"
manage/message
"
)
},
{
name
:
"
模块测试
"
,
href
:
"
/admin/manage/test
"
,
icon
:
ChatIcon
,
current
:
path
.
value
.
includes
(
"
manage/test
"
)
}
];
});
...
...
pages/admin/index/manage/message/index.vue
浏览文件 @
d372d726
<
template
>
<h3
class=
"text-lg leading-6 font-medium text-gray-900"
>
短信群发服务
</h3>
<div
class=
"mt-8 flex items-start space-x-4"
>
<div
class=
"flex-shrink-0"
>
<img
class=
"inline-block h-10 w-10 rounded-full"
src=
"@/assets/imgs/logo.png"
alt=
""
/>
</div>
<div
class=
"min-w-0 flex-1"
>
<form
class=
"relative"
>
<div
class=
"min-w-0 flex-1 px-12"
>
<form
class=
"relative mt-12 max-w-[800px]"
>
<div
class=
"flex items-center"
>
<span
class=
"w-28"
>
测试手机号:
</span>
<span
class=
"w-28 text-md text-gray-600"
>
发送对象:
</span>
<el-radio-group
@
change=
"changeType"
size=
"large"
v-model=
"type"
>
<el-radio
:label=
"1"
>
指定手机号
</el-radio>
<el-radio
:label=
"0"
>
所有用户
</el-radio>
</el-radio-group>
</div>
<div
v-if=
"type === 1"
class=
"flex mt-4 items-center"
>
<span
class=
"w-28 text-md text-gray-600"
>
手机号:
</span>
<el-input
size=
"large"
maxlength=
"11"
v-model=
"telNumber"
placeholder=
"测试手机号有值时,只对该手机发送短信"
placeholder=
"请输入手机号"
></el-input>
</div>
<div
v-else
class=
"flex mt-4 items-center"
>
<span
class=
"w-28 text-md text-gray-600"
>
群发密码:
</span>
<el-input
size=
"large"
v-model=
"password"
placeholder=
"请输入群发密码"
></el-input>
</div>
<div
class=
"mt-4 border border-gray-300 rounded-lg shadow-sm overflow-hidden focus-within:border-indigo-500 focus-within:ring-1 focus-within:ring-indigo-500"
>
<label
for=
"comment"
class=
"sr-only"
>
Add your comment
</label>
<textarea
<div
class=
"flex mt-6 items-start"
>
<span
class=
"w-28 text-md text-gray-600"
>
短信内容:
</span>
<el-input
type=
"textarea"
rows=
"6"
name=
"comment"
id=
"comment"
size=
"large"
v-model=
"message"
class=
"p-4 block w-full py-3 outline-0 border-none resize-none ring-none sm:text-sm"
placeholder=
"输入短信内容"
/>
<!-- Spacer element to match the height of the toolbar -->
<div
class=
"py-2"
aria-hidden=
"true"
>
<!-- Matches height of button in toolbar (1px border + 36px content height) -->
<div
class=
"py-px"
>
<div
class=
"h-9"
/>
</div>
</div>
placeholder=
"请输入短信内容"
></el-input>
</div>
<div
class=
"absolute bottom-0 inset-x-0 pl-3 pr-2 py-2 flex justify-between"
>
<div
class=
"flex items-center space-x-5"
></div>
<div
class=
"flex-shrink-0"
>
<span
@
click=
"openSend"
class=
"cursor-pointer inline-flex items-center px-4 py-2 border border-transparent text-sm font-medium rounded-md shadow-sm text-white bg-indigo-600 hover:bg-indigo-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"
>
{{
telNumber
?
"
发送测试消息
"
:
"
群 发
"
}}
</span>
</div>
<div
class=
"flex mt-6 items-center"
>
<span
class=
"w-28 text-md text-gray-600"
></span>
<span
@
click=
"openSend"
class=
"cursor-pointer inline-flex items-center px-4 py-2 border border-transparent text-sm font-medium rounded-md shadow-sm text-white bg-indigo-600 hover:bg-indigo-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500"
>
发 送
</span>
</div>
</form>
</div>
</div>
<confirm
tip=
"短信将通知到所有用户,确认发送?
"
:tip=
"`短信将通知到$
{telNumber || '所有用户'},确认发送?`
"
:open="showSend"
@confirm="confirmSend"
@cancel="cancelSend"
...
...
@@ -67,15 +61,42 @@
<
script
lang=
"ts"
setup
>
import
confirm
from
"
~~/components/confirm.vue
"
;
import
api
from
"
@/api
"
;
import
{
ElNotification
,
ElInput
}
from
"
element-plus
"
;
import
{
HelloWorld
}
from
"
./index.cmd.js
"
;
import
{
ElNotification
,
ElInput
,
ElSelect
,
ElRadio
,
ElRadioGroup
,
ElOption
}
from
"
element-plus
"
;
const
type
=
ref
(
1
);
const
telNumber
=
ref
(
""
);
const
password
=
ref
(
""
);
const
message
=
ref
(
""
);
const
showSend
=
ref
(
false
);
const
changeType
=
(
val
:
any
)
=>
{
console
.
log
(
val
);
switch
(
val
)
{
case
0
:
telNumber
.
value
=
""
;
break
;
case
1
:
password
.
value
=
""
;
break
;
default
:
break
;
}
};
const
openSend
=
()
=>
{
if
(
!
message
.
value
.
trim
())
return
;
if
(
!
message
.
value
.
trim
())
return
ElNotification
.
warning
(
"
请输入短信内容
"
);
if
(
type
.
value
===
1
)
{
if
(
!
telNumber
.
value
)
return
ElNotification
.
warning
(
"
请输入手机号
"
);
}
else
{
if
(
!
password
.
value
)
return
ElNotification
.
warning
(
"
请输入群发确认密码
"
);
}
showSend
.
value
=
true
;
};
...
...
pages/admin/index/manage/wxmessage/index.vue
浏览文件 @
d372d726
...
...
@@ -21,18 +21,18 @@
<el-form-item
label=
"查看详情链接"
>
<el-input
v-model=
"form.destUrl"
/>
</el-form-item>
<el-form-item
label=
"发送人数"
>
<el-form-item
v-if=
"!form.openid"
label=
"发送人数"
>
<el-input
v-model=
"form.num"
/>
</el-form-item>
<el-form-item
label=
"测试openid"
>
<el-form-item
v-if=
"!form.openid"
label=
"包含已发送用户"
>
<el-checkbox
v-model=
"form.needRestart"
/>
</el-form-item>
<el-form-item
label=
"指定用户( 选填 )"
>
<el-input
v-model=
"form.openid"
placeholder=
"
openid有值时,只对该用户发送消息
"
placeholder=
"
请输入指定用户的 openid
"
/>
</el-form-item>
<el-form-item
label=
"包含已发送用户"
>
<el-checkbox
v-model=
"form.needRestart"
/>
</el-form-item>
<el-form-item
label=
""
>
<span
@
click=
"openSend"
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录