Commit c1abb457 by 胡悦

Merge branch 'master' of 192.168.3.233:h5/account

2 parents d82fa804 0e2b3e18
......@@ -111,7 +111,10 @@
<script type="text/html" id="merchantBtns">
<a class="layui-btn-xs" lay-event="handleDetail">查看</a>
{{# if((d.btn.edit)){ }}
<a class="layui-btn-xs" lay-event="handleEdit">修改</a>
<a class="layui-btn-xs" lay-event="handleEdit">修改基本信息</a>
{{# } }}
{{# if((d.btn.edit)){ }}
<a class="layui-btn-xs" lay-event="handleAuthority">修改权限</a>
{{# } }}
{{# if((d.btn.createSubMerchant)){ }}
<a class="layui-btn-xs" lay-event="handleAddMerchant">创建子商户/门店</a>
......@@ -219,11 +222,28 @@
break
// 修改
case 'handleEdit':
// 1-创建新商户;2-创建子商户;3-修改
// editLevel - 1-创建新商户;2-创建子商户;3-修改
// step - 1-基本信息;2-权限树
// merchantAccountLevel 账户等级(1-工厂;2-省代;3-市代;4-门店)
go('merchant', 'edit', {
editLevel: 3,
id: row.id,
parentId: row.parentId,
isFactory: (row.merchantAccountLevel == 1),
step: 1
})
break
case 'handleAuthority':
// editLevel - 1-创建新商户;2-创建子商户;3-修改
// step - 1-基本信息;2-权限树
// merchantAccountLevel 账户等级
go('merchant', 'edit', {
editLevel: 3,
id: row.id
// merchantName: row.merchantName
id: row.id,
parentId: row.parentId,
isFactory: (row.merchantAccountLevel == 1),
id: row.id,
step: 2
})
break
// 创建子商户/门店
......@@ -231,12 +251,16 @@
// 1-创建新商户;2-创建子商户;3-修改
go('merchant', 'edit', {
editLevel: 2,
id: row.id
parentId: row.id,
isFactory: 'false',
step: 1
})
break
// 创建员工
case 'handleAddStaff':
go('employee', 'add')
go('employee', 'add', {
merchantId: row.id
})
break
// 修改账户有效期
case 'handleVaildPeriod':
......@@ -278,7 +302,9 @@
$('#addBtn').on('click', function () {
// 1-创建新商户;2-创建子商户;3-修改
go('merchant', 'edit', {
editLevel: 1
editLevel: 1,
step: 1,
isFactory: 'true'
})
return false
})
......@@ -440,7 +466,8 @@
function init() {
// 运营系统
if (!isDxternal) {
// if (!isDxternal) {
if (isDxternal) {
getChannel()
getAccountLevel()
getAccountType()
......
......@@ -116,8 +116,8 @@ layui.define(['sha1', 'md5', 'helper'], function (exports) {
secretArr.push(val + params[val])
}
var str = secretArr.join('')
// console.log(str)
return isMd5 ? md5(secret + str + secret).toUpperCase() : SHA1(secret + str + secret).toUpperCase()
// return SHA1(secret + str + secret).toUpperCase()
}
function msg(msg) {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!