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
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
152 additions
and
72 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 @@
...
@@ -232,9 +232,8 @@
var
merchantId
=
''
var
merchantId
=
''
var
visibleMerchant
=
{}
var
visibleMerchant
=
{}
pwd
.
attr
(
'readonly'
,
false
)
pwd
.
attr
(
'readonly'
,
false
)
var
user
=
helper
.
store
.
get
(
'user'
)
var
accountInfo
=
helper
.
store
.
get
(
'accountInfo'
)
console
.
log
(
user
)
if
(
accountInfo
)
{
if
(
user
.
accountLevel
==
4
)
{
$
(
'#btnGroup'
).
addClass
(
'show'
)
$
(
'#btnGroup'
).
addClass
(
'show'
)
}
}
// 判断是从商户过来还是员工
// 判断是从商户过来还是员工
...
...
html/merchant/add.html
View file @
85aaf25
...
@@ -111,7 +111,7 @@
...
@@ -111,7 +111,7 @@
background-color
:
#1989fa
;
background-color
:
#1989fa
;
color
:
#fff
;
color
:
#fff
;
height
:
16px
;
height
:
16px
;
line-height
:
16px
line-height
:
16px
;
text-align
:
center
;
text-align
:
center
;
width
:
16px
;
width
:
16px
;
border-radius
:
50%
;
border-radius
:
50%
;
...
@@ -216,7 +216,6 @@
...
@@ -216,7 +216,6 @@
<div
id=
"merchantModel"
class=
"hide layui-col-md9"
>
<div
id=
"merchantModel"
class=
"hide layui-col-md9"
>
<div
class=
"layui-form-item"
>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label required"
>
选择开通模式:
</label>
<label
class=
"layui-form-label required"
>
选择开通模式:
</label>
<!-- <div class="layui-input-inline"> -->
<div
class=
"layuui-radio"
>
<div
class=
"layuui-radio"
>
<input
type=
"radio"
name=
"merchantModel"
required
lay-verify=
"otherReq"
value=
"男"
title=
"单店企微版"
/>
<input
type=
"radio"
name=
"merchantModel"
required
lay-verify=
"otherReq"
value=
"男"
title=
"单店企微版"
/>
<span>
(一个门店一个企微账户授权)
</span>
<span>
(一个门店一个企微账户授权)
</span>
...
@@ -225,8 +224,6 @@
...
@@ -225,8 +224,6 @@
<input
type=
"radio"
name=
"merchantModel"
required
lay-verify=
"otherReq"
value=
"女"
title=
"集团企微版"
/>
<input
type=
"radio"
name=
"merchantModel"
required
lay-verify=
"otherReq"
value=
"女"
title=
"集团企微版"
/>
<span>
(集团多个企微共用一个企微账户授权)
</span>
<span>
(集团多个企微共用一个企微账户授权)
</span>
</div>
</div>
<!-- </div> -->
</div>
</div>
</div>
</div>
<div
class=
"layui-col-md6"
>
<div
class=
"layui-col-md6"
>
...
@@ -548,10 +545,10 @@
...
@@ -548,10 +545,10 @@
var
accountTypeVisible
=
false
var
accountTypeVisible
=
false
// 是否工厂
// 是否工厂
var
isFactory
=
true
var
isFactory
=
true
var
merchantAccountLevel
=
qs
(
'merchantAccountLevel'
)
var
parentInfo
=
{}
var
parentInfo
=
{}
var
isFreshSecond
=
true
var
isFreshSecond
=
true
var
scopeNum
=
1
var
scopeNum
=
1
var
merchantForm
=
{
var
merchantForm
=
{
channelId
:
''
,
channelId
:
''
,
merchantName
:
''
,
merchantName
:
''
,
...
@@ -1088,8 +1085,10 @@
...
@@ -1088,8 +1085,10 @@
parentMerchantId
=
qs
(
'parentId'
)
parentMerchantId
=
qs
(
'parentId'
)
}
}
$
(
'#validPeriodEl'
).
attr
(
'disabled'
,
true
)
$
(
'#validPeriodEl'
).
attr
(
'disabled'
,
true
)
if
(
merchantAccountLevel
==
4
)
{
$
(
'#effectiveShowEl'
).
removeClass
(
'hide'
)
$
(
'#effectiveShowEl'
).
removeClass
(
'hide'
)
$
(
'#effectiveShowEl'
).
addClass
(
'show'
)
$
(
'#effectiveShowEl'
).
addClass
(
'show'
)
}
// $('#channelEl').attr('disabled', true)
// $('#channelEl').attr('disabled', true)
if
(
editLevel
==
3
||
(
editLevel
==
2
&&
!
merchantId
))
{
if
(
editLevel
==
3
||
(
editLevel
==
2
&&
!
merchantId
))
{
getParentInfo
()
getParentInfo
()
...
...
html/merchant/detail.html
View file @
85aaf25
...
@@ -75,7 +75,9 @@
...
@@ -75,7 +75,9 @@
height
:
40px
;
height
:
40px
;
line-height
:
40px
;
line-height
:
40px
;
}
}
.layui-form-label
{
width
:
130px
!important
;
}
.merchant-right
.companyName
{
.merchant-right
.companyName
{
display
:
inline-block
;
display
:
inline-block
;
width
:
300px
;
width
:
300px
;
...
@@ -93,7 +95,6 @@
...
@@ -93,7 +95,6 @@
.merchant-right
.layui-btn
{
.merchant-right
.layui-btn
{
position
:
absolute
;
position
:
absolute
;
right
:
20px
;
right
:
20px
;
}
}
...
@@ -173,18 +174,36 @@
...
@@ -173,18 +174,36 @@
<div
class=
"layui-form-mid layui-word-aux"
id=
"merchantLoginAccount"
></div>
<div
class=
"layui-form-mid layui-word-aux"
id=
"merchantLoginAccount"
></div>
</div>
</div>
</div>
</div>
<div
class=
"layui-form-item"
>
<
!-- <
div class="layui-form-item">
<label class="layui-form-label">账户类型:</label>
<label class="layui-form-label">账户类型:</label>
<div class="layui-input-block">
<div class="layui-input-block">
<div class="layui-form-mid layui-word-aux" id="accountTypeNames"></div>
<div class="layui-form-mid layui-word-aux" id="accountTypeNames"></div>
</div>
</div>
</div>
</div>
-->
<div
class=
"layui-form-item mb21"
>
<div
class=
"layui-form-item mb21"
>
<label
class=
"layui-form-label"
>
账户等级:
</label>
<label
class=
"layui-form-label"
>
账户等级:
</label>
<div
class=
"layui-input-block"
>
<div
class=
"layui-input-block"
>
<div
class=
"layui-form-mid layui-word-aux"
id=
"accountLevelName"
></div>
<div
class=
"layui-form-mid layui-word-aux"
id=
"accountLevelName"
></div>
</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=
"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"
>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label"
>
账户有效期:
</label>
<label
class=
"layui-form-label"
>
账户有效期:
</label>
<div
class=
"layui-input-block"
>
<div
class=
"layui-input-block"
>
...
@@ -344,7 +363,10 @@
...
@@ -344,7 +363,10 @@
'merchantLegalPerson'
,
'merchantLegalPerson'
,
'merchantLegalPersonPhone'
,
'merchantLegalPersonPhone'
,
'businessScopName'
,
'businessScopName'
,
'merchantBrandName'
'merchantBrandName'
,
'merchantModelName'
,
'statusName'
,
'entmicroName'
]
]
var
roleData
=
{}
var
roleData
=
{}
...
...
html/merchant/edit.html
View file @
85aaf25
...
@@ -9,6 +9,16 @@
...
@@ -9,6 +9,16 @@
<meta
name=
"keywords"
itemprop=
"keywords"
content=
"广联,帐户管理,员工管理"
/>
<meta
name=
"keywords"
itemprop=
"keywords"
content=
"广联,帐户管理,员工管理"
/>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"/css/main.css"
/>
<link
rel=
"stylesheet"
type=
"text/css"
href=
"/css/main.css"
/>
<style>
<style>
.clearfix
{
zoom
:
1
;
}
.clearfix
::after
{
content
:
''
;
display
:
block
;
height
:
0
;
clear
:
both
;
visibility
:
hidden
;
}
.edit-box
{
.edit-box
{
/* width: 1046px; */
/* width: 1046px; */
padding
:
20px
20px
;
padding
:
20px
20px
;
...
@@ -143,6 +153,17 @@
...
@@ -143,6 +153,17 @@
.layui-no-data
.no-data
div
{
.layui-no-data
.no-data
div
{
margin-top
:
12px
;
margin-top
:
12px
;
}
}
.layuui-radio
{
display
:
inline-flex
;
align-items
:
center
;
margin-right
:
20px
;
}
.layuui-radio
.layui-form-radio
{
margin
:
0
;
}
.layuui-radio
span
{
line-height
:
28px
;
}
</style>
</style>
<title>
商户编辑
</title>
<title>
商户编辑
</title>
</head>
</head>
...
@@ -171,12 +192,14 @@
...
@@ -171,12 +192,14 @@
<ul
class=
"layui-tab-title"
></ul>
<ul
class=
"layui-tab-title"
></ul>
<div
class=
"layui-tab-content"
></div>
<div
class=
"layui-tab-content"
></div>
</div>
</div>
<div
class=
"footer-close"
>
<!-- <button id="draft" class="layui-btn">存草稿</button> -->
<!-- <button id="draft" class="layui-btn">存草稿</button> -->
<!-- <button id="preStep" class="layui-btn">上一步</button> -->
<!-- <button id="preStep" class="layui-btn">上一步</button> -->
<button
id=
"confirm"
class=
"layui-btn"
>
确定
</button>
<button
id=
"confirm"
class=
"layui-btn"
>
确定
</button>
<button
class=
"layui-btn"
data-type=
"handleCancel"
>
取消
</button>
<button
class=
"layui-btn"
data-type=
"handleCancel"
>
取消
</button>
</div>
</div>
</div>
</div>
</div>
<div
class=
"layui-tab-item layui-show"
>
<div
class=
"layui-tab-item layui-show"
>
<!-- 基本信息 -->
<!-- 基本信息 -->
<div
id=
"basicForm"
>
<div
id=
"basicForm"
>
...
@@ -238,8 +261,21 @@
...
@@ -238,8 +261,21 @@
<div
class=
"layui-input-inline w-70"
id=
"accountTypeEl"
></div>
<div
class=
"layui-input-inline w-70"
id=
"accountTypeEl"
></div>
</div>
</div>
</div>
</div>
<div
class=
"edit-bo
x"
>
<div
class=
"edit-box clearfi
x"
>
<p
class=
"edit-title"
>
修改企业基本信息
</p>
<p
class=
"edit-title"
>
修改企业基本信息
</p>
<div
id=
"merchantModel"
class=
"hide layui-col-md12"
>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label required"
>
选择开通模式:
</label>
<div
class=
"layuui-radio"
>
<input
type=
"radio"
name=
"merchantModel"
required
lay-verify=
"otherReq"
value=
"男"
title=
"单店企微版"
/>
<span>
(一个门店一个企微账户授权)
</span>
</div>
<div
class=
"layuui-radio"
>
<input
type=
"radio"
name=
"merchantModel"
required
lay-verify=
"otherReq"
value=
"女"
title=
"集团企微版"
/>
<span>
(集团多个企微共用一个企微账户授权)
</span>
</div>
</div>
</div>
<div
class=
"layui-col-md6"
>
<div
class=
"layui-col-md6"
>
<div
class=
"layui-form-item"
>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label required"
>
商户名称:
</label>
<label
class=
"layui-form-label required"
>
商户名称:
</label>
...
@@ -271,8 +307,7 @@
...
@@ -271,8 +307,7 @@
<div
class=
"layui-form-item"
>
<div
class=
"layui-form-item"
>
<label
class=
"layui-form-label"
>
商户地址:
</label>
<label
class=
"layui-form-label"
>
商户地址:
</label>
<div
class=
"layui-input-inline w-70"
>
<div
class=
"layui-input-inline w-70"
>
<input
style=
"color: #333333 !important;"
name=
"merchantAddress"
disabled
<input
style=
"color: #333333 !important;"
name=
"merchantAddress"
disabled
class=
"layui-input layui-btn-disabled"
id=
"addrEl"
placeholder=
"请选择商户地址"
/>
class=
"layui-input layui-btn-disabled"
id=
"addrEl"
placeholder=
"请选择商户地址"
>
<!-- <div class="m-t-10" id="addrEl">请选择商户地址</div> -->
<!-- <div class="m-t-10" id="addrEl">请选择商户地址</div> -->
<button
type=
"button"
class=
"layui-btn"
data-type=
"handleSelectAddr"
>
选择地址
</button>
<button
type=
"button"
class=
"layui-btn"
data-type=
"handleSelectAddr"
>
选择地址
</button>
</div>
</div>
...
@@ -350,7 +385,7 @@
...
@@ -350,7 +385,7 @@
<label
class=
"layui-form-label"
>
主营品牌:
</label>
<label
class=
"layui-form-label"
>
主营品牌:
</label>
<div
class=
"layui-input-inline"
>
<div
class=
"layui-input-inline"
>
<input
class=
"layui-input"
placeholder=
"车型品牌"
id=
"brand"
/>
<input
class=
"layui-input"
placeholder=
"车型品牌"
id=
"brand"
/>
<div
id=
"carBrandTree"
style=
"width: 30
0px; height: 200px; overflow-y: scroll;"
></div>
<div
id=
"carBrandTree"
style=
"width: 31
0px; height: 200px; overflow-y: scroll;"
></div>
</div>
</div>
</div>
</div>
</div>
</div>
...
@@ -408,7 +443,7 @@
...
@@ -408,7 +443,7 @@
<span
class=
"tips"
>
图片格式仅支持JPG,PNG格式,大小1M以内
</span>
<span
class=
"tips"
>
图片格式仅支持JPG,PNG格式,大小1M以内
</span>
</div>
</div>
</div>
</div>
<div
class=
"layui-form-item"
style=
"text-align: center;
"
>
<div
class=
"footer-close
"
>
<button
id=
"basicSumit"
class=
"layui-btn"
lay-submit
lay-filter=
"handleFirstSubmit"
>
确定
</button>
<button
id=
"basicSumit"
class=
"layui-btn"
lay-submit
lay-filter=
"handleFirstSubmit"
>
确定
</button>
<button
type=
"reset"
class=
"layui-btn"
data-type=
"handleCancel"
>
取消
</button>
<button
type=
"reset"
class=
"layui-btn"
data-type=
"handleCancel"
>
取消
</button>
</div>
</div>
...
@@ -571,7 +606,7 @@
...
@@ -571,7 +606,7 @@
return
'请填入正确的驻店电话'
return
'请填入正确的驻店电话'
}
}
},
},
hasModify
:
function
(
value
)
{
hasModify
:
function
(
value
)
{
console
.
log
(
value
,
'=================----------==========='
)
console
.
log
(
value
,
'=================----------==========='
)
}
}
})
})
...
@@ -601,7 +636,8 @@
...
@@ -601,7 +636,8 @@
'merchantLoginAccount'
,
'merchantLoginAccount'
,
'merchantLoginPassword'
,
'merchantLoginPassword'
,
'merchantAccountLevel'
,
'merchantAccountLevel'
,
'effectiveTime'
'effectiveTime'
,
'merchantModel'
]
]
if
(
formData
.
isloginName
==
'on'
)
{
if
(
formData
.
isloginName
==
'on'
)
{
params
.
isloginName
=
1
params
.
isloginName
=
1
...
@@ -821,17 +857,21 @@
...
@@ -821,17 +857,21 @@
var
layId
=
this
.
getAttribute
(
'lay-id'
)
var
layId
=
this
.
getAttribute
(
'lay-id'
)
if
(
current
!=
layId
)
{
if
(
current
!=
layId
)
{
if
(
basicFlag
)
{
if
(
basicFlag
)
{
layer
.
confirm
(
'是否保存修改信息?'
,
{
layer
.
confirm
(
btn
:
[
'是'
,
'否'
]
//按钮
'是否保存修改信息?'
,
},
function
(
index
)
{
{
btn
:
[
'是'
,
'否'
]
//按钮
},
function
(
index
)
{
element
.
tabChange
(
'editTab'
,
2
)
element
.
tabChange
(
'editTab'
,
2
)
functionClick
=
true
functionClick
=
true
$
(
'#basicSumit'
).
click
()
$
(
'#basicSumit'
).
click
()
step
=
2
step
=
2
init
()
init
()
layer
.
close
(
index
)
layer
.
close
(
index
)
},
function
(){
},
});
function
()
{}
)
}
else
{
}
else
{
element
.
tabChange
(
'editTab'
,
2
)
element
.
tabChange
(
'editTab'
,
2
)
step
=
2
step
=
2
...
@@ -847,23 +887,26 @@
...
@@ -847,23 +887,26 @@
var
layId
=
this
.
getAttribute
(
'lay-id'
)
var
layId
=
this
.
getAttribute
(
'lay-id'
)
if
(
current
!=
layId
)
{
if
(
current
!=
layId
)
{
if
(
functionFlag
)
{
if
(
functionFlag
)
{
layer
.
confirm
(
'是否保存修改信息?'
,
{
layer
.
confirm
(
btn
:
[
'是'
,
'否'
]
//按钮
'是否保存修改信息?'
,
},
function
(
index
)
{
{
btn
:
[
'是'
,
'否'
]
//按钮
},
function
(
index
)
{
element
.
tabChange
(
'editTab'
,
1
)
element
.
tabChange
(
'editTab'
,
1
)
basicClick
=
true
basicClick
=
true
step
=
1
step
=
1
submitAuth
()
submitAuth
()
location
.
reload
()
location
.
reload
()
layer
.
close
(
index
)
layer
.
close
(
index
)
},
function
(){
},
});
function
()
{}
)
}
else
{
}
else
{
element
.
tabChange
(
'editTab'
,
1
)
element
.
tabChange
(
'editTab'
,
1
)
step
=
1
step
=
1
location
.
reload
()
location
.
reload
()
}
}
}
}
return
false
return
false
})
})
...
@@ -966,6 +1009,11 @@
...
@@ -966,6 +1009,11 @@
// baseIsShow(false)
// baseIsShow(false)
// treeIsShow(true)
// treeIsShow(true)
}
}
console
.
log
(
helper
.
store
.
get
(
'accountInfo'
))
if
(
qs
(
'status'
)
&&
!
helper
.
store
.
get
(
'accountInfo'
))
{
$
(
'#merchantModel'
).
removeClass
(
'hide'
)
$
(
'#merchantModel'
).
addClass
(
'show'
)
}
// 创建商户
// 创建商户
if
(
!
merchantId
)
{
if
(
!
merchantId
)
{
...
@@ -1336,8 +1384,7 @@
...
@@ -1336,8 +1384,7 @@
// 选项卡标题的lay-id属性值
// 选项卡标题的lay-id属性值
id
:
id
id
:
id
})
})
var
getTpl
=
var
getTpl
=
`<form class="layui-form layui-form-pane" action="">
`<form class="layui-form layui-form-pane" action="">
<div class="layui-form-item" pane>
<div class="layui-form-item" pane>
<label class="layui-form-label">选择产品:</label>
<label class="layui-form-label">选择产品:</label>
<div class="layui-input-block" id="project
${
id
}
">
<div class="layui-input-block" id="project
${
id
}
">
...
@@ -1650,7 +1697,7 @@
...
@@ -1650,7 +1697,7 @@
submitAuth
()
submitAuth
()
})
})
function
submitAuth
()
{
function
submitAuth
()
{
getAuthList
()
getAuthList
()
var
params
=
{
var
params
=
{
merchantId
:
merchantId
,
merchantId
:
merchantId
,
...
@@ -1668,7 +1715,7 @@
...
@@ -1668,7 +1715,7 @@
layer
.
msg
(
'操作成功'
,
{
layer
.
msg
(
'操作成功'
,
{
icon
:
1
icon
:
1
})
})
if
(
!
basicClick
)
{
if
(
!
basicClick
)
{
go
(
'merchant'
,
'index'
)
go
(
'merchant'
,
'index'
)
}
}
}
}
...
...
html/merchant/index.html
View file @
85aaf25
...
@@ -71,27 +71,27 @@
...
@@ -71,27 +71,27 @@
创建商户
创建商户
</button>
</button>
</div>
</div>
<div
id=
"relevancyEl"
class=
"hide"
>
<!-- <div class="hide"> -->
<div
class=
"layui-inline"
>
<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"
>
<div
class=
"layui-inline channel"
>
<label
class=
"layui-form-label"
>
是否已关联企微:
</label>
<label
class=
"layui-form-label"
>
是否已关联企微:
</label>
<div
class=
"layui-input-inline"
>
<div
class=
"layui-input-inline"
>
<select
name=
"
channelId
"
>
<select
name=
"
isRelevance
"
>
<option
value=
""
>
全部
</option>
<option
value=
"
0
"
>
全部
</option>
<option
value=
"1"
>
已关联
</option>
<option
value=
"1"
>
已关联
</option>
<option
value=
"2"
>
未关联
</option>
<option
value=
"2"
>
未关联
</option>
</select>
</select>
</div>
</div>
</div>
</div>
</div>
</div>
<div
class=
"layui-inline"
>
<!-- </div> -->
<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
id=
"channelBox"
class=
"hide"
style=
"display: inline-block;"
>
<div
id=
"channelBox"
class=
"hide"
style=
"display: inline-block;"
>
<div
class=
"layui-inline channel"
>
<div
class=
"layui-inline channel"
>
<label
class=
"layui-form-label"
>
渠道:
</label>
<label
class=
"layui-form-label"
>
渠道:
</label>
...
@@ -206,13 +206,9 @@
...
@@ -206,13 +206,9 @@
var
form
=
layui
.
form
var
form
=
layui
.
form
var
$
=
layui
.
$
var
$
=
layui
.
$
var
helper
=
layui
.
helper
var
helper
=
layui
.
helper
// var user = helper.store.get('user')
var
accountInfo
=
helper
.
store
.
get
(
'accountInfo'
)
var
user
=
{
console
.
log
(
'accountInfo'
,
accountInfo
)
merchantId
:
81
window
.
isDxternal
=
accountInfo
?
1
:
2
// 1 SCRM, default 运营平台
}
// var isDxternal = isAppend()
window
.
isDxternal
=
1
// 1 SCRM, default 运营平台
var
baseData
=
{
var
baseData
=
{
statusList
:
[],
statusList
:
[],
channelList
:
[],
channelList
:
[],
...
@@ -260,7 +256,7 @@
...
@@ -260,7 +256,7 @@
align
:
'center'
align
:
'center'
},
},
{
{
field
:
'merchantModel'
,
field
:
'merchantModel
Name
'
,
title
:
'模式'
,
title
:
'模式'
,
align
:
'center'
align
:
'center'
},
},
...
@@ -304,7 +300,7 @@
...
@@ -304,7 +300,7 @@
width
:
120
width
:
120
},
},
{
{
field
:
'
merchantLegalPersonPhon
e'
,
field
:
'
entmicroNam
e'
,
title
:
'关联的企业微信'
,
title
:
'关联的企业微信'
,
align
:
'center'
,
align
:
'center'
,
width
:
120
width
:
120
...
@@ -348,7 +344,7 @@
...
@@ -348,7 +344,7 @@
align
:
'center'
align
:
'center'
},
},
{
{
field
:
'
entmicroNam
e'
,
field
:
'
isRelevanc
e'
,
title
:
'关联的企业微信'
,
title
:
'关联的企业微信'
,
align
:
'center'
align
:
'center'
},
},
...
@@ -441,9 +437,9 @@
...
@@ -441,9 +437,9 @@
})
})
table
.
on
(
'tool(merchant-table-filter)'
,
function
(
obj
)
{
table
.
on
(
'tool(merchant-table-filter)'
,
function
(
obj
)
{
// console.log(obj)
var
eventName
=
obj
.
event
var
eventName
=
obj
.
event
var
row
=
obj
.
data
var
row
=
obj
.
data
console
.
log
(
row
.
merchantAccountLevel
)
switch
(
eventName
)
{
switch
(
eventName
)
{
// 查看
// 查看
case
'handleDetail'
:
case
'handleDetail'
:
...
@@ -461,7 +457,8 @@
...
@@ -461,7 +457,8 @@
id
:
row
.
id
,
id
:
row
.
id
,
parentId
:
row
.
parentId
,
parentId
:
row
.
parentId
,
isFactory
:
row
.
merchantAccountLevel
==
1
,
isFactory
:
row
.
merchantAccountLevel
==
1
,
step
:
1
step
:
1
,
status
:
row
.
status
})
})
break
break
case
'handleAuthority'
:
case
'handleAuthority'
:
...
@@ -484,7 +481,8 @@
...
@@ -484,7 +481,8 @@
editLevel
:
2
,
editLevel
:
2
,
parentId
:
row
.
id
,
parentId
:
row
.
id
,
isFactory
:
'false'
,
isFactory
:
'false'
,
step
:
1
step
:
1
,
merchantAccountLevel
:
row
.
merchantAccountLevel
})
})
break
break
// 创建员工
// 创建员工
...
@@ -544,7 +542,7 @@
...
@@ -544,7 +542,7 @@
})
})
$
(
'#relevancyBtn'
).
on
(
'click'
,
function
()
{
$
(
'#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
()
{
form
.
on
(
'submit(searchSubmit)'
,
function
()
{
...
@@ -599,7 +597,7 @@
...
@@ -599,7 +597,7 @@
case
1
:
case
1
:
if
(
item
.
status
==
2
)
{
if
(
item
.
status
==
2
)
{
// 本身
// 本身
if
(
item
.
id
==
user
.
merchantId
)
{
if
(
item
.
id
==
accountInfo
.
merchantId
)
{
item
.
btn
.
createStaff
=
true
item
.
btn
.
createStaff
=
true
if
(
item
.
merchantAccountLevel
!=
4
)
{
if
(
item
.
merchantAccountLevel
!=
4
)
{
item
.
btn
.
createSubMerchant
=
true
item
.
btn
.
createSubMerchant
=
true
...
@@ -611,7 +609,7 @@
...
@@ -611,7 +609,7 @@
item
.
btn
.
editPeriod
=
true
item
.
btn
.
editPeriod
=
true
// 直属门店
// 直属门店
if
(
item
.
merchantAccountLevel
==
4
)
{
if
(
item
.
merchantAccountLevel
==
4
)
{
if
(
item
.
parentId
==
user
.
merchantId
)
{
if
(
item
.
parentId
==
accountInfo
.
merchantId
)
{
item
.
btn
.
createStaff
=
true
item
.
btn
.
createStaff
=
true
}
}
}
else
{
}
else
{
...
@@ -762,7 +760,10 @@
...
@@ -762,7 +760,10 @@
function
elRemove
()
{
function
elRemove
()
{
$
(
'#operateEl'
).
remove
()
$
(
'#operateEl'
).
remove
()
$
(
'#channelBox'
).
remove
()
$
(
'#channelBox'
).
remove
()
if
(
accountInfo
.
model
==
2
&&
accountInfo
.
merchantAccountLevel
==
1
)
{
$
(
'#relevancyEl'
).
addClass
(
'show'
)
$
(
'#relevancyEl'
).
addClass
(
'show'
)
}
$
(
'#relevancySearch'
).
addClass
(
'show'
)
$
(
'#model'
).
remove
()
$
(
'#model'
).
remove
()
}
}
...
...
html/merchant/validPeriodForm.html
View file @
85aaf25
...
@@ -82,12 +82,12 @@
...
@@ -82,12 +82,12 @@
$
(
'#merchantEl'
).
show
()
$
(
'#merchantEl'
).
show
()
$
(
'#storeEl'
).
hide
()
$
(
'#storeEl'
).
hide
()
setText
(
2
)
setText
(
2
)
console
.
log
(
getQueryString
(
'effectiveTime'
))
vaildData
.
effectiveTime
=
getQueryString
(
'effectiveTime'
)
vaildData
.
effectiveTime
=
getQueryString
(
'effectiveTime'
)
}
form
.
val
(
'periodFilter'
,
{
form
.
val
(
'periodFilter'
,
{
effectiveTime
:
vaildData
.
effectiveTime
effectiveTime
:
'2'
})
})
}
var
effectiveStarttime
=
laydate
.
render
({
var
effectiveStarttime
=
laydate
.
render
({
elem
:
'#effectiveStarttime'
,
elem
:
'#effectiveStarttime'
,
...
@@ -148,7 +148,7 @@
...
@@ -148,7 +148,7 @@
}
}
})
})
}
else
{
}
else
{
layer
.
msg
(
'请选择账户有效期
2
'
,
{
layer
.
msg
(
'请选择账户有效期'
,
{
icon
:
5
,
icon
:
5
,
anim
:
6
anim
:
6
})
})
...
@@ -168,7 +168,7 @@
...
@@ -168,7 +168,7 @@
}
}
})
})
}
else
{
}
else
{
layer
.
msg
(
'请选择账户有效期
1
'
,
{
layer
.
msg
(
'请选择账户有效期'
,
{
icon
:
5
,
icon
:
5
,
anim
:
6
anim
:
6
})
})
...
...
html/role/add.html
View file @
85aaf25
...
@@ -26,6 +26,7 @@
...
@@ -26,6 +26,7 @@
background-color
:
#ffffff
;
background-color
:
#ffffff
;
margin
:
15px
auto
;
margin
:
15px
auto
;
position
:
relative
;
position
:
relative
;
height
:
100%
;
}
}
.edit-box
.grayLine
{
.edit-box
.grayLine
{
position
:
absolute
;
position
:
absolute
;
...
@@ -54,6 +55,7 @@
...
@@ -54,6 +55,7 @@
}
}
.Wrap
{
.Wrap
{
margin
:
8px
20px
0
;
margin
:
8px
20px
0
;
height
:
100%
;
}
}
#roleTitle
{
#roleTitle
{
font-size
:
20px
;
font-size
:
20px
;
...
...
js/load.js
View file @
85aaf25
...
@@ -38,6 +38,16 @@ function loadHeaderFooter() {
...
@@ -38,6 +38,16 @@ function loadHeaderFooter() {
layui
.
use
([
'store'
],
function
()
{
layui
.
use
([
'store'
],
function
()
{
var
isExternal
=
isAppend
()
var
isExternal
=
isAppend
()
var
store
=
layui
.
store
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
){
//运营平台外部系统
if
(
isExternal
){
//运营平台外部系统
append
()
append
()
}
else
{
//嵌入运营平台 或者是登录页面
}
else
{
//嵌入运营平台 或者是登录页面
...
...
js/request.js
View file @
85aaf25
...
@@ -30,14 +30,14 @@ layui.define(['sha1', 'md5', 'helper'], function (exports) {
...
@@ -30,14 +30,14 @@ layui.define(['sha1', 'md5', 'helper'], function (exports) {
async
:
true
,
//false同步方式,true为异步方式
async
:
true
,
//false同步方式,true为异步方式
dataType
:
'json'
,
dataType
:
'json'
,
beforeSend
:
function
(
request
)
{
beforeSend
:
function
(
request
)
{
loading
=
layer
.
load
(
0
,
{
//
loading = layer.load(0, {
shade
:
false
//
shade: false
})
//0代表加载的风格,支持0-2
//
}) //0代表加载的风格,支持0-2
var
token
=
store
.
get
(
'token'
)
var
token
=
store
.
get
(
'token'
)
request
.
setRequestHeader
(
'TGT'
,
token
)
request
.
setRequestHeader
(
'TGT'
,
token
)
},
},
complete
:
function
()
{
complete
:
function
()
{
layer
.
close
(
loading
)
//
layer.close(loading)
},
},
error
:
function
(
xhr
)
{
error
:
function
(
xhr
)
{
if
(
xhr
.
status
==
401
)
{
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