Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
h5
/
account
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 85aaf25b
authored
Oct 12, 2021
by
胡悦
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
提交
1 parent
930ed66a
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
87 additions
and
54 deletions
html/employee/add.html
html/merchant/add.html
html/merchant/detail.html
html/merchant/edit.html
html/merchant/index.html
html/merchant/validPeriodForm.html
html/role/add.html
js/load.js
js/request.js
html/employee/add.html
View file @
85aaf25
...
...
@@ -232,9 +232,8 @@
var
merchantId
=
''
var
visibleMerchant
=
{}
pwd
.
attr
(
'readonly'
,
false
)
var
user
=
helper
.
store
.
get
(
'user'
)
console
.
log
(
user
)
if
(
user
.
accountLevel
==
4
)
{
var
accountInfo
=
helper
.
store
.
get
(
'accountInfo'
)
if
(
accountInfo
)
{
$
(
'#btnGroup'
).
addClass
(
'show'
)
}
// 判断是从商户过来还是员工
...
...
html/merchant/add.html
View file @
85aaf25
...
...
@@ -111,7 +111,7 @@
background-color
:
#1989fa
;
color
:
#fff
;
height
:
16px
;
line-height
:
16px
line-height
:
16px
;
text-align
:
center
;
width
:
16px
;
border-radius
:
50%
;
...
...
@@ -216,7 +216,6 @@
<div
id=
"merchantModel"
class=
"hide layui-col-md9"
>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label required"
>
选择开通模式:
</label>
<!-- <div class="layui-input-inline"> -->
<div
class=
"layuui-radio"
>
<input
type=
"radio"
name=
"merchantModel"
required
lay-verify=
"otherReq"
value=
"男"
title=
"单店企微版"
/>
<span>
(一个门店一个企微账户授权)
</span>
...
...
@@ -225,8 +224,6 @@
<input
type=
"radio"
name=
"merchantModel"
required
lay-verify=
"otherReq"
value=
"女"
title=
"集团企微版"
/>
<span>
(集团多个企微共用一个企微账户授权)
</span>
</div>
<!-- </div> -->
</div>
</div>
<div
class=
"layui-col-md6"
>
...
...
@@ -548,10 +545,10 @@
var
accountTypeVisible
=
false
// 是否工厂
var
isFactory
=
true
var
merchantAccountLevel
=
qs
(
'merchantAccountLevel'
)
var
parentInfo
=
{}
var
isFreshSecond
=
true
var
scopeNum
=
1
var
merchantForm
=
{
channelId
:
''
,
merchantName
:
''
,
...
...
@@ -1088,8 +1085,10 @@
parentMerchantId
=
qs
(
'parentId'
)
}
$
(
'#validPeriodEl'
).
attr
(
'disabled'
,
true
)
$
(
'#effectiveShowEl'
).
removeClass
(
'hide'
)
$
(
'#effectiveShowEl'
).
addClass
(
'show'
)
if
(
merchantAccountLevel
==
4
)
{
$
(
'#effectiveShowEl'
).
removeClass
(
'hide'
)
$
(
'#effectiveShowEl'
).
addClass
(
'show'
)
}
// $('#channelEl').attr('disabled', true)
if
(
editLevel
==
3
||
(
editLevel
==
2
&&
!
merchantId
))
{
getParentInfo
()
...
...
html/merchant/detail.html
View file @
85aaf25
...
...
@@ -75,7 +75,9 @@
height
:
40px
;
line-height
:
40px
;
}
.layui-form-label
{
width
:
130px
!important
;
}
.merchant-right
.companyName
{
display
:
inline-block
;
width
:
300px
;
...
...
@@ -93,7 +95,6 @@
.merchant-right
.layui-btn
{
position
:
absolute
;
right
:
20px
;
}
...
...
@@ -173,18 +174,36 @@
<div
class=
"layui-form-mid layui-word-aux"
id=
"merchantLoginAccount"
></div>
</div>
</div>
<div
class=
"layui-form-item"
>
<
!-- <
div class="layui-form-item">
<label class="layui-form-label">账户类型:</label>
<div class="layui-input-block">
<div class="layui-form-mid layui-word-aux" id="accountTypeNames"></div>
</div>
</div>
</div>
-->
<div
class=
"layui-form-item mb21"
>
<label
class=
"layui-form-label"
>
账户等级:
</label>
<div
class=
"layui-input-block"
>
<div
class=
"layui-form-mid layui-word-aux"
id=
"accountLevelName"
></div>
</div>
</div>
<div
class=
"layui-form-item mb21"
>
<label
class=
"layui-form-label"
>
开通模式:
</label>
<div
class=
"layui-input-block"
>
<div
class=
"layui-form-mid layui-word-aux"
id=
"merchantModelName"
></div>
</div>
</div>
<div
class=
"layui-form-item mb21"
>
<label
class=
"layui-form-label"
>
账户状态:
</label>
<div
class=
"layui-input-block"
>
<div
class=
"layui-form-mid layui-word-aux"
id=
"statusName"
></div>
</div>
</div>
<div
class=
"layui-form-item mb21"
>
<label
class=
"layui-form-label"
>
关联企业微信名:
</label>
<div
class=
"layui-input-block"
>
<div
class=
"layui-form-mid layui-word-aux"
id=
"entmicroName"
></div>
</div>
</div>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label"
>
账户有效期:
</label>
<div
class=
"layui-input-block"
>
...
...
@@ -344,7 +363,10 @@
'merchantLegalPerson'
,
'merchantLegalPersonPhone'
,
'businessScopName'
,
'merchantBrandName'
'merchantBrandName'
,
'merchantModelName'
,
'statusName'
,
'entmicroName'
]
var
roleData
=
{}
...
...
html/merchant/edit.html
View file @
85aaf25
This diff is collapsed.
Click to expand it.
html/merchant/index.html
View file @
85aaf25
...
...
@@ -71,27 +71,27 @@
创建商户
</button>
</div>
<div
id=
"relevancyEl"
class=
"hide"
>
<div
class=
"layui-inline"
>
<!-- <div class="hide"> -->
<div
id=
"relevancyEl"
class=
"layui-inline hide"
>
<button
class=
"layui-btn mb5"
id=
"relevancyBtn"
>
<img
class=
"relevancyImg"
src=
"../../css/img/relevancy.png"
alt=
""
/>
<!-- <i class="layui-icon layui-icon-addition"></i> -->
门店账户关联企微
</button>
</div>
<div
id=
"relevancySearch"
class=
"layui-inline"
>
<div
class=
"layui-inline channel"
>
<label
class=
"layui-form-label"
>
是否已关联企微:
</label>
<div
class=
"layui-input-inline"
>
<select
name=
"
channelId
"
>
<option
value=
""
>
全部
</option>
<select
name=
"
isRelevance
"
>
<option
value=
"
0
"
>
全部
</option>
<option
value=
"1"
>
已关联
</option>
<option
value=
"2"
>
未关联
</option>
</select>
</div>
</div>
</div>
<div
class=
"layui-inline"
>
<button
class=
"layui-btn mb5"
id=
"relevancyBtn"
>
<img
class=
"relevancyImg"
src=
"../../css/img/relevancy.png"
alt=
""
/>
<!-- <i class="layui-icon layui-icon-addition"></i> -->
门店账户关联企微
</button>
</div>
</div>
<!-- </div> -->
<div
id=
"channelBox"
class=
"hide"
style=
"display: inline-block;"
>
<div
class=
"layui-inline channel"
>
<label
class=
"layui-form-label"
>
渠道:
</label>
...
...
@@ -206,13 +206,9 @@
var
form
=
layui
.
form
var
$
=
layui
.
$
var
helper
=
layui
.
helper
// var user = helper.store.get('user')
var
user
=
{
merchantId
:
81
}
// var isDxternal = isAppend()
window
.
isDxternal
=
1
// 1 SCRM, default 运营平台
var
accountInfo
=
helper
.
store
.
get
(
'accountInfo'
)
console
.
log
(
'accountInfo'
,
accountInfo
)
window
.
isDxternal
=
accountInfo
?
1
:
2
// 1 SCRM, default 运营平台
var
baseData
=
{
statusList
:
[],
channelList
:
[],
...
...
@@ -260,7 +256,7 @@
align
:
'center'
},
{
field
:
'merchantModel'
,
field
:
'merchantModel
Name
'
,
title
:
'模式'
,
align
:
'center'
},
...
...
@@ -304,7 +300,7 @@
width
:
120
},
{
field
:
'
merchantLegalPersonPhon
e'
,
field
:
'
entmicroNam
e'
,
title
:
'关联的企业微信'
,
align
:
'center'
,
width
:
120
...
...
@@ -348,7 +344,7 @@
align
:
'center'
},
{
field
:
'
entmicroNam
e'
,
field
:
'
isRelevanc
e'
,
title
:
'关联的企业微信'
,
align
:
'center'
},
...
...
@@ -441,9 +437,9 @@
})
table
.
on
(
'tool(merchant-table-filter)'
,
function
(
obj
)
{
// console.log(obj)
var
eventName
=
obj
.
event
var
row
=
obj
.
data
console
.
log
(
row
.
merchantAccountLevel
)
switch
(
eventName
)
{
// 查看
case
'handleDetail'
:
...
...
@@ -461,7 +457,8 @@
id
:
row
.
id
,
parentId
:
row
.
parentId
,
isFactory
:
row
.
merchantAccountLevel
==
1
,
step
:
1
step
:
1
,
status
:
row
.
status
})
break
case
'handleAuthority'
:
...
...
@@ -484,7 +481,8 @@
editLevel
:
2
,
parentId
:
row
.
id
,
isFactory
:
'false'
,
step
:
1
step
:
1
,
merchantAccountLevel
:
row
.
merchantAccountLevel
})
break
// 创建员工
...
...
@@ -544,7 +542,7 @@
})
$
(
'#relevancyBtn'
).
on
(
'click'
,
function
()
{
$messenger
.
emit
(
'route-to'
,
{
path
:
'
/baseInfo
'
,
params
:
{
a
:
111
}
})
$messenger
.
emit
(
'route-to'
,
{
path
:
'
settings/baseInfo/relevance
'
,
params
:
{
a
:
111
}
})
})
// 搜索绑定事件
form
.
on
(
'submit(searchSubmit)'
,
function
()
{
...
...
@@ -599,7 +597,7 @@
case
1
:
if
(
item
.
status
==
2
)
{
// 本身
if
(
item
.
id
==
user
.
merchantId
)
{
if
(
item
.
id
==
accountInfo
.
merchantId
)
{
item
.
btn
.
createStaff
=
true
if
(
item
.
merchantAccountLevel
!=
4
)
{
item
.
btn
.
createSubMerchant
=
true
...
...
@@ -611,7 +609,7 @@
item
.
btn
.
editPeriod
=
true
// 直属门店
if
(
item
.
merchantAccountLevel
==
4
)
{
if
(
item
.
parentId
==
user
.
merchantId
)
{
if
(
item
.
parentId
==
accountInfo
.
merchantId
)
{
item
.
btn
.
createStaff
=
true
}
}
else
{
...
...
@@ -762,7 +760,10 @@
function
elRemove
()
{
$
(
'#operateEl'
).
remove
()
$
(
'#channelBox'
).
remove
()
$
(
'#relevancyEl'
).
addClass
(
'show'
)
if
(
accountInfo
.
model
==
2
&&
accountInfo
.
merchantAccountLevel
==
1
)
{
$
(
'#relevancyEl'
).
addClass
(
'show'
)
}
$
(
'#relevancySearch'
).
addClass
(
'show'
)
$
(
'#model'
).
remove
()
}
...
...
html/merchant/validPeriodForm.html
View file @
85aaf25
...
...
@@ -82,12 +82,12 @@
$
(
'#merchantEl'
).
show
()
$
(
'#storeEl'
).
hide
()
setText
(
2
)
console
.
log
(
getQueryString
(
'effectiveTime'
))
vaildData
.
effectiveTime
=
getQueryString
(
'effectiveTime'
)
form
.
val
(
'periodFilter'
,
{
effectiveTime
:
'2'
})
}
form
.
val
(
'periodFilter'
,
{
effectiveTime
:
vaildData
.
effectiveTime
})
var
effectiveStarttime
=
laydate
.
render
({
elem
:
'#effectiveStarttime'
,
...
...
@@ -148,7 +148,7 @@
}
})
}
else
{
layer
.
msg
(
'请选择账户有效期
2
'
,
{
layer
.
msg
(
'请选择账户有效期'
,
{
icon
:
5
,
anim
:
6
})
...
...
@@ -168,7 +168,7 @@
}
})
}
else
{
layer
.
msg
(
'请选择账户有效期
1
'
,
{
layer
.
msg
(
'请选择账户有效期'
,
{
icon
:
5
,
anim
:
6
})
...
...
html/role/add.html
View file @
85aaf25
...
...
@@ -26,6 +26,7 @@
background-color
:
#ffffff
;
margin
:
15px
auto
;
position
:
relative
;
height
:
100%
;
}
.edit-box
.grayLine
{
position
:
absolute
;
...
...
@@ -54,6 +55,7 @@
}
.Wrap
{
margin
:
8px
20px
0
;
height
:
100%
;
}
#roleTitle
{
font-size
:
20px
;
...
...
js/load.js
View file @
85aaf25
...
...
@@ -38,6 +38,16 @@ function loadHeaderFooter() {
layui
.
use
([
'store'
],
function
()
{
var
isExternal
=
isAppend
()
var
store
=
layui
.
store
console
.
log
(
qs
(
'merchantId'
),
qs
(
'merchantAccountLevel'
))
if
(
qs
(
'merchantAccountLevel'
))
{
store
.
set
(
'accountInfo'
,
{
merchantAccountLevel
:
qs
(
'merchantAccountLevel'
),
merchantId
:
qs
(
'merchantId'
),
model
:
qs
(
'model'
)
})
// } else {
// store.set('accountInfo', null)
}
if
(
isExternal
){
//运营平台外部系统
append
()
}
else
{
//嵌入运营平台 或者是登录页面
...
...
js/request.js
View file @
85aaf25
...
...
@@ -30,14 +30,14 @@ layui.define(['sha1', 'md5', 'helper'], function (exports) {
async
:
true
,
//false同步方式,true为异步方式
dataType
:
'json'
,
beforeSend
:
function
(
request
)
{
loading
=
layer
.
load
(
0
,
{
shade
:
false
})
//0代表加载的风格,支持0-2
//
loading = layer.load(0, {
//
shade: false
//
}) //0代表加载的风格,支持0-2
var
token
=
store
.
get
(
'token'
)
request
.
setRequestHeader
(
'TGT'
,
token
)
},
complete
:
function
()
{
layer
.
close
(
loading
)
//
layer.close(loading)
},
error
:
function
(
xhr
)
{
if
(
xhr
.
status
==
401
)
{
...
...
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