Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
江名洋
/
linkwe-scrm
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 8c2c85b9
authored
Feb 06, 2023
by
xinla
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
小程序配置
1 parent
adc5fea5
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
389 additions
and
91 deletions
linkwe-pc/src/views/enterpriseWechat/list.vue
linkwe-pc/src/views/enterpriseWechat/part7.vue
linkwe-uniapp/package-lock.json
linkwe-uniapp/package.json
linkwe-pc/src/views/enterpriseWechat/list.vue
View file @
8c2c85b
...
@@ -16,104 +16,98 @@
...
@@ -16,104 +16,98 @@
<el-tab-pane
label=
"公众号配置"
name=
"5"
>
<el-tab-pane
label=
"公众号配置"
name=
"5"
>
<part5
@
submit=
"savePart1"
:data=
"form"
></part5>
<part5
@
submit=
"savePart1"
:data=
"form"
></part5>
</el-tab-pane>
</el-tab-pane>
<el-tab-pane
label=
"小程序配置g"
name=
"7"
>
<part7
@
submit=
"savePart1"
:data=
"form"
></part7>
</el-tab-pane>
</el-tabs>
</el-tabs>
</div>
</div>
</
template
>
</
template
>
<
script
>
<
script
>
import
Part1
from
'./part1.vue'
import
*
as
api
from
'@/api/enterpriseId'
import
Part2
from
'./part2.vue'
// import clipboard from "clipboard";
import
Part3
from
'./part3.vue'
export
default
{
import
Part4
from
'./part4.vue'
components
:
{
import
Part5
from
'./part5.vue'
part1
:
()
=>
import
(
'./part1.vue'
),
import
*
as
api
from
'@/api/enterpriseId'
part2
:
()
=>
import
(
'./part2.vue'
),
// import clipboard from "clipboard";
part3
:
()
=>
import
(
'./part3.vue'
),
export
default
{
part4
:
()
=>
import
(
'./part4.vue'
),
components
:
{
part5
:
()
=>
import
(
'./part5.vue'
),
Part1
,
part7
:
()
=>
import
(
'./part7.vue'
),
Part2
,
},
Part3
,
props
:
{},
Part4
,
data
()
{
Part5
return
{
},
currentActive
:
'1'
,
props
:
{},
form
:
{},
data
()
{
disabled
:
false
,
return
{
loading
:
false
,
currentActive
:
'1'
,
rules
:
Object
.
freeze
({
form
:
{},
// companyName: [{ required: true, message: '必填项', trigger: 'blur' }],
disabled
:
false
,
corpId
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
loading
:
false
,
corpSecret
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
rules
:
Object
.
freeze
({
agentId
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
// companyName: [{ required: true, message: '必填项', trigger: 'blur' }],
agentSecret
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
corpId
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
contactSecret
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
corpSecret
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
seasRedirectUrl
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
agentId
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
sopTagRedirectUrl
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
agentSecret
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
}),
contactSecret
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
}
seasRedirectUrl
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
},
sopTagRedirectUrl
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}]
watch
:
{},
computed
:
{},
created
()
{
this
.
getDetail
()
},
mounted
()
{},
methods
:
{
savePart1
(
data
)
{
api
.
addOrUpdate
(
data
)
.
then
(()
=>
{
this
.
msgSuccess
(
'操作成功'
)
// this.dialogVisible = false
this
.
getDetail
()
})
.
catch
(()
=>
{
// this.dialogVisible = false
})
})
}
},
watch
:
{},
computed
:
{},
created
()
{
this
.
getDetail
()
},
},
mounted
()
{},
getDetail
()
{
methods
:
{
this
.
loading
=
true
savePart1
(
data
)
{
api
api
.
getDetail
()
.
addOrUpdate
(
data
)
.
then
(({
data
})
=>
{
.
then
(()
=>
{
this
.
form
=
data
this
.
msgSuccess
(
'操作成功'
)
this
.
loading
=
false
// this.dialogVisible = false
this
.
getDetail
()
})
.
catch
(()
=>
{
// this.dialogVisible = false
})
},
getDetail
()
{
this
.
loading
=
true
api
.
getDetail
()
.
then
(({
data
})
=>
{
this
.
form
=
data
this
.
loading
=
false
})
.
catch
(()
=>
{
this
.
loading
=
false
})
},
submit
()
{
this
.
$refs
[
'form'
].
validate
((
valid
)
=>
{
if
(
valid
)
{
api
.
addOrUpdate
(
this
.
form
)
.
then
(()
=>
{
this
.
msgSuccess
(
'操作成功'
)
// this.dialogVisible = false
this
.
getDetail
()
})
.
catch
(()
=>
{
// this.dialogVisible = false
})
}
})
})
},
.
catch
(()
=>
{
start
(
corpId
)
{
this
.
loading
=
false
api
.
start
(
corpId
).
then
(({
rows
,
total
})
=>
{
this
.
msgSuccess
(
'操作成功'
)
this
.
getList
()
})
})
}
},
}
submit
()
{
}
this
.
$refs
[
'form'
].
validate
((
valid
)
=>
{
if
(
valid
)
{
api
.
addOrUpdate
(
this
.
form
)
.
then
(()
=>
{
this
.
msgSuccess
(
'操作成功'
)
// this.dialogVisible = false
this
.
getDetail
()
})
.
catch
(()
=>
{
// this.dialogVisible = false
})
}
})
},
start
(
corpId
)
{
api
.
start
(
corpId
).
then
(({
rows
,
total
})
=>
{
this
.
msgSuccess
(
'操作成功'
)
this
.
getList
()
})
},
},
}
</
script
>
</
script
>
<
style
lang=
"scss"
scoped
>
<
style
lang=
"scss"
scoped
></
style
>
.tips
{
color
:
#aaa
;
font-size
:
12px
;
}
</
style
>
linkwe-pc/src/views/enterpriseWechat/part7.vue
0 → 100644
View file @
8c2c85b
<
template
>
<div>
<el-form
ref=
"form"
label-position=
"right"
:model=
"form"
:rules=
"rules"
size=
"small"
label-width=
"180px"
>
<div
class=
"g-card g-pad20"
>
<div
class=
"my-title"
>
小程序配置
</div>
<div>
<el-form-item
label=
"微信小程序APPID:"
prop=
"miniAppId"
>
<el-input
style=
"width: 40%"
v-model=
"form.miniAppId"
placeholder=
"请输入APPID"
></el-input>
<!--
<div
class=
"tips"
>
在微信公众号后台->开发管理->开发设置中获取
</div>
-->
</el-form-item>
</div>
<div
id=
"step2"
>
<el-form-item
label=
"微信小程序Secret:"
prop=
"miniSecret"
>
<el-input
style=
"width: 40%"
v-model=
"form.miniSecret"
placeholder=
"请输入小程序Secret"
></el-input>
<!--
<div
class=
"tips"
>
在微信公众号后台->开发管理->开发设置->开发者ID中获取
</div>
-->
</el-form-item>
</div>
<el-form-item
label=
"小程序原始ID:"
prop=
"wxAppletOriginalId"
>
<el-input
style=
"width: 40%"
v-model=
"form.wxAppletOriginalId"
placeholder=
"请输入小程序原始ID"
></el-input>
<!--
<div
class=
"tips"
>
在微信公众号后台->开发管理->开发设置中获取
</div>
-->
</el-form-item>
<!--
<el-form-item
label=
"小程序验证token:"
prop=
"miniMaToken"
>
<el-input
style=
"width: 40%"
v-model=
"form.miniMaToken"
placeholder=
"请输入小程序验证token"
></el-input>
<div
class=
"tips"
>
在微信公众号后台->开发管理->开发设置->消息推送中获取
</div>
</el-form-item>
<el-form-item
label=
"小程序EncodingAESKey:"
prop=
"miniMaEncodingaeskey"
>
<el-input
style=
"width: 40%"
v-model=
"form.miniMaEncodingaeskey"
placeholder=
"请输入小程序EncodingAESKey"
></el-input>
<div
class=
"tips"
>
在微信公众号后台->开发管理->开发设置->消息推送中获取
</div>
</el-form-item>
<el-form-item
label=
"URL服务器地址:"
prop=
"miniMaApi"
>
<el-input
style=
"width: 40%"
v-model=
"form.miniMaApi"
disabled
placeholder=
"这是一段固定的服务器地址,不可更改"
></el-input>
<el-button
class=
"copy-btn ml10"
type=
"primary"
:data-clipboard-text=
"form.miniMaApi"
>
复制
</el-button>
<div
class=
"tips"
>
将此段内容复制黏贴至微信公众号后台->开发管理->开发设置->消息推送中的【url服务器地址】处
</div>
</el-form-item>
-->
</div>
<el-form-item
label=
""
class=
"ar"
>
<el-button
type=
"primary"
@
click=
"submit"
id=
"step5"
>
保存配置
</el-button>
</el-form-item>
<a
href=
""
></a>
</el-form>
</div>
</
template
>
<
script
>
export
default
{
data
()
{
return
{
mat
:
[
'p12'
],
merChantSecretCopy
:
''
,
merChantSecretEditState
:
false
,
form
:
{},
// activeNumber: '',
rules
:
{
miniAppId
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
miniSecret
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
wxAppletOriginalId
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
miniMaToken
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
miniMaEncodingaeskey
:
[{
required
:
true
,
message
:
'必填项'
,
trigger
:
'blur'
}],
},
// dataList: [
// {
// element: '#step1',
// popover: {
// title: "<div style='display:none'></div>",
// description:
// '<div>1、请于此处填写商户名称,您可前往<微信支付后台—账号中心—个人信息>中获取查看。 <a style="color:#2c8cf0" href="https://pay.weixin.qq.com/index.php/core/account/info" target="_blank">点击前往 >></a></div>',
// position: 'top-center',
// className: 'step_none',
// },
// onPrevious: () => {
// this.$driver.preventMove()
// },
// },
// {
// element: '#step2',
// popover: {
// title: "<div style='display:none'></div>",
// description:
// '<div>2、请于此处填写商户号,您可前往<微信支付后台—账号中心—个人信息>中获取查看。 <a style="color:#2c8cf0" href="https://pay.weixin.qq.com/index.php/core/account/info" target="_blank">点击前往 >></a></div>',
// position: 'bottom-center',
// },
// },
// {
// element: '#step3',
// popover: {
// title: "<div style='display:none'></div>",
// description:
// '<div>3、请于此处填写商户支付Secret,您可前往<微信支付后台—账号中心—API安全>中获取查看。 <a style="color:#2c8cf0" href="https://pay.weixin.qq.com/index.php/core/cert/api_cert#/" target="_blank">点击前往 >></a></div>',
// position: 'bottom-center',
// },
// },
// {
// element: '#step4',
// popover: {
// title: "<div style='display:none'></div>",
// description:
// '<div>4、请于此处上传API证书文件,您可前往<微信支付后台—账号中心—账户设置—API安全>中获取查看。 <a style="color:#2c8cf0" href="https://pay.weixin.qq.com/index.php/core/cert/api_cert#/" target="_blank">点击前往 >></a></div>',
// position: 'bottom-center',
// },
// },
// {
// element: '#step5',
// doneBtnText: '下一步',
// popover: {
// title: "<div style='display:none'></div>",
// description: '5、填写完成后请于此处点击< 保存配置 >按钮并点击完成按钮。',
// position: 'top-center',
// },
// onNext: (ele) => {
// sessionStorage.setItem('currentActive', '2')
// this.$emit('getActive', '2')
// },
// },
// {
// element: '#item1',
// popover: {
// title: '',
// description:
// '<div>6、请于此处填写公众号ID,您可前往<公众号后台—设置与开发—基本配置>中获取查看。 <a style="color:#2c8cf0" href="https://mp.weixin.qq.com/advanced/advanced?action=dev&t=advanced/dev&token=603419011&lang=zh_CN" target="_blank">点击前往 >></a></div>',
// position: 'bottom-center',
// },
// },
// ],
}
},
watch
:
{
data
:
'setData'
,
// currentActive() {
// if (sessionStorage.getItem('currentActive') && this.currentActive === '4') {
// this.$driver.defineSteps(this.dataList)
// this.$driver.start(4)
// }
// },
// part4Number() {
// this.activeNumber = '2'
// },
},
props
:
{
data
:
{
type
:
Object
,
default
:
{},
},
// currentActive: {
// type: String,
// },
// part4Number: {
// type: String,
// },
},
created
()
{
// this.activeNumber = sessionStorage.getItem('currentActive')
},
mounted
()
{
this
.
clipboard
=
new
this
.
ClipboardJS
(
'.copy-btn'
)
// if (sessionStorage.getItem('currentActive') === '4') {
// this.$driver.defineSteps(this.dataList)
// this.$driver.start()
// }
},
destroyed
()
{
this
.
clipboard
.
destroy
()
},
methods
:
{
// editMerChantSecret() {
// this.merChantSecretEditState = true
// this.merChantSecretCopy = JSON.parse(JSON.stringify(this.form.merChantSecret))
// this.form.merChantSecret = ''
// },
// cancelEditMerChantSecret() {
// this.merChantSecretEditState = false
// this.form.merChantSecret = JSON.parse(JSON.stringify(this.merChantSecretCopy))
// },
// submitEditMerChantSecret() {
// if (this.form.merChantSecret) {
// this.$emit('submit', this.form)
// this.merChantSecretEditState = false
// }
// },
submit
()
{
this
.
$refs
[
'form'
].
validate
((
validate
)
=>
{
if
(
validate
)
{
this
.
$emit
(
'submit'
,
this
.
form
)
}
})
},
setData
()
{
if
(
Object
.
keys
(
this
.
data
).
length
)
{
this
.
form
=
this
.
data
}
},
},
}
</
script
>
<
style
lang=
"scss"
>
div
.step_none
#driver-popover-item
{
div.driver-popover-footer
{
span.driver-navigation-btns
{
button.driver-prev-btn
{
opacity
:
0
;
cursor
:
default
!important
;
display
:
none
;
}
}
}
}
div
#driver-popover-item
{
div.driver-popover-footer
{
button.driver-close-btn
{
display
:
none
;
//隐藏关闭按钮
}
.driver-btn-group
{
button.driver-disabled
{
//
display
:
none
!important
;
color
:
#2d2d2d
;
border
:
1px
solid
#d4d4d4
;
cursor
:
pointer
!important
;
pointer-events
:
auto
!important
;
}
}
}
}
div
#driver-page-overlay
{
opacity
:
1
!important
;
background
:
rgba
(
$
color
:
#000000
,
$
alpha
:
0.65
)
!important
;
}
div
#driver-highlighted-element-stage
{
border-radius
:
8px
!important
;
}
</
style
>
<
style
lang=
"scss"
scoped
>
.my-title
{
}
#step1
{
width
:
100%
;
height
:
120px
;
overflow
:
hidden
;
.el-form-item
{
width
:
80%
;
}
}
//
.driver-highlighted-element
{
//
pointer-events
:
none
;
//
}
//
::v-deep
.scoped-class
.driver-close-btn
{
//
visibility
:
hidden
;
//
}
.tips
{
color
:
#aaa
;
font-size
:
12px
;
}
</
style
>
linkwe-uniapp/package-lock.json
0 → 100644
View file @
8c2c85b
{
"name"
:
"linkwe-uniapp"
,
"lockfileVersion"
:
2
,
"requires"
:
true
,
"packages"
:
{
""
:
{
"dependencies"
:
{
"jsqr"
:
"^1.4.0"
}
},
"node_modules/jsqr"
:
{
"version"
:
"1.4.0"
,
"resolved"
:
"https://registry.npmmirror.com/jsqr/-/jsqr-1.4.0.tgz"
,
"integrity"
:
"sha512-dxLob7q65Xg2DvstYkRpkYtmKm2sPJ9oFhrhmudT1dZvNFFTlroai3AWSpLey/w5vMcLBXRgOJsbXpdN9HzU/A=="
}
},
"dependencies"
:
{
"jsqr"
:
{
"version"
:
"1.4.0"
,
"resolved"
:
"https://registry.npmmirror.com/jsqr/-/jsqr-1.4.0.tgz"
,
"integrity"
:
"sha512-dxLob7q65Xg2DvstYkRpkYtmKm2sPJ9oFhrhmudT1dZvNFFTlroai3AWSpLey/w5vMcLBXRgOJsbXpdN9HzU/A=="
}
}
}
linkwe-uniapp/package.json
0 → 100644
View file @
8c2c85b
{
"name"
:
"linkwe-uniapp"
,
"version"
:
"1.0.0"
,
"description"
:
""
,
"main"
:
"main.js"
,
"dependencies"
:
{
"jsqr"
:
"^1.4.0"
},
"devDependencies"
:
{},
"scripts"
:
{
"test"
:
"echo
\"
Error: no test specified
\"
&& exit 1"
},
"keywords"
:
[],
"author"
:
""
,
"license"
:
"ISC"
}
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment