Commit fd72f558 by 李长胜

修改样式

1 parent 32f649df
...@@ -29,6 +29,10 @@ main::-webkit-scrollbar { ...@@ -29,6 +29,10 @@ main::-webkit-scrollbar {
justify-content: space-between; justify-content: space-between;
padding: 0 20px; padding: 0 20px;
} }
.upload-img-box{
margin-right: 10px;
background-color: #f7f7f7;
}
.header-nav { .header-nav {
display: flex; display: flex;
......
...@@ -70,7 +70,9 @@ ...@@ -70,7 +70,9 @@
background-color: #ffffff; background-color: #ffffff;
margin: 15px auto; margin: 15px auto;
position: relative; position: relative;
height: 100%; /* min-height: calc(100vh-182px); */
/* height: 100%; */
padding-bottom: 30px;
} }
.edit-box .grayLine { .edit-box .grayLine {
position: absolute; position: absolute;
...@@ -107,7 +109,7 @@ ...@@ -107,7 +109,7 @@
} }
.Wrap { .Wrap {
margin: 8px 20px 0; margin: 8px 20px 0;
height: 100%; /* height: 100%; */
} }
</style> </style>
</head> </head>
...@@ -156,7 +158,7 @@ ...@@ -156,7 +158,7 @@
<label class="layui-form-label required">可见商户:</label> <label class="layui-form-label required">可见商户:</label>
<div class="layui-input-block"> <div class="layui-input-block">
<input class="layui-input" placeholder="可见商户" id="searchMerchant" /> <input class="layui-input" placeholder="可见商户" id="searchMerchant" />
<ul id="visibleInferiorMerTree" style="height: 200px; overflow-y: auto;" class="ztree wrapper-tree"></ul> <ul id="visibleInferiorMerTree" style="height: 200px; overflow-y: auto" class="ztree wrapper-tree"></ul>
</div> </div>
</div> </div>
<div class="layui-form-item"> <div class="layui-form-item">
...@@ -328,7 +330,7 @@ ...@@ -328,7 +330,7 @@
// 创建角色 // 创建角色
$('#addRole').on('click', function () { $('#addRole').on('click', function () {
// go('role', 'add', null, true) // go('role', 'add', null, true)
$messenger.emit('route-to', { path: '/settings/role/add'}) $messenger.emit('route-to', { path: '/settings/role/add' })
}) })
// 提交表单 // 提交表单
...@@ -396,7 +398,7 @@ ...@@ -396,7 +398,7 @@
request(visibleMerchantParams, function (res) { request(visibleMerchantParams, function (res) {
if (res.code == '0') { if (res.code == '0') {
if (id) { if (id) {
findAllMerchant(function(result) { findAllMerchant(function (result) {
if (result) { if (result) {
getById(function (checkedList) { getById(function (checkedList) {
createMerchant(checkedList, res.data) createMerchant(checkedList, res.data)
......
...@@ -9,7 +9,6 @@ ...@@ -9,7 +9,6 @@
<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>
.edit-box { .edit-box {
/* width: 1046px; */ /* width: 1046px; */
padding: 20px 20px; padding: 20px 20px;
...@@ -83,6 +82,8 @@ ...@@ -83,6 +82,8 @@
.edit-box .upload-img-wh { .edit-box .upload-img-wh {
width: 120px !important; width: 120px !important;
height: 80px; height: 80px;
margin-right: 10px;
margin-bottom: 10px;
} }
.show { .show {
...@@ -125,15 +126,17 @@ ...@@ -125,15 +126,17 @@
.edit-box #accountTypeEl .layui-form-checked span, .edit-box #accountTypeEl .layui-form-checked span,
#accountTypeEl .layui-form-checked:hover span { #accountTypeEl .layui-form-checked:hover span {
background-color: #5850FF !important; background-color: #5850ff !important;
} }
.edit-box #accountTypeEl .layui-form-checked i, .edit-box #accountTypeEl .layui-form-checked i,
#accountTypeEl .layui-form-checked:hover i { #accountTypeEl .layui-form-checked:hover i {
color: #5850FF !important; color: #5850ff !important;
} }
.layui-form-radio:hover *, .layui-form-radioed, .layui-form-radioed>i { .layui-form-radio:hover *,
color: #5850FF !important; .layui-form-radioed,
.layui-form-radioed > i {
color: #5850ff !important;
} }
.pageTitle { .pageTitle {
background-color: #fff; background-color: #fff;
...@@ -254,8 +257,7 @@ ...@@ -254,8 +257,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>
...@@ -280,7 +282,7 @@ ...@@ -280,7 +282,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" maxlength="15" name="merchantLegalPerson" placeholder="请输入联系人姓名" /> <input class="layui-input" maxlength="15" name="merchantLegalPerson" placeholder="请输入联系人姓名" />
<div style="width: 100%; height: 28px;"></div> <div style="width: 100%; height: 28px"></div>
</div> </div>
</div> </div>
</div> </div>
...@@ -667,21 +669,26 @@ ...@@ -667,21 +669,26 @@
return '请填入正确的驻店电话' return '请填入正确的驻店电话'
} }
}, },
otherReq: function(value,item){ otherReq: function (value, item) {
var verifyName=$(item).attr('name') var verifyName = $(item).attr('name'),
, verifyType=$(item).attr('type') verifyType = $(item).attr('type'),
,formElem=$(item).parents('.layui-form')//获取当前所在的form元素,如果存在的话 formElem = $(item).parents('.layui-form'), //获取当前所在的form元素,如果存在的话
,verifyElem=formElem.find('input[name='+verifyName+']')//获取需要校验的元素 verifyElem = formElem.find('input[name=' + verifyName + ']'), //获取需要校验的元素
,isTrue= verifyElem.is(':checked')//是否命中校验 isTrue = verifyElem.is(':checked'), //是否命中校验
,focusElem = verifyElem.next().find('i.layui-icon');//焦点元素 focusElem = verifyElem.next().find('i.layui-icon') //焦点元素
if(!isTrue || !value){ if (!isTrue || !value) {
//定位焦点 //定位焦点
focusElem.css(verifyType=='radio'?{"color":"#FF5722"}:{"border-color":"#FF5722"}); focusElem.css(verifyType == 'radio' ? { color: '#FF5722' } : { 'border-color': '#FF5722' })
//对非输入框设置焦点 //对非输入框设置焦点
focusElem.first().attr("tabIndex","1").css("outline","0").blur(function() { focusElem
focusElem.css(verifyType=='radio'?{"color":""}:{"border-color":""}); .first()
}).focus(); .attr('tabIndex', '1')
return '必填项不能为空'; .css('outline', '0')
.blur(function () {
focusElem.css(verifyType == 'radio' ? { color: '' } : { 'border-color': '' })
})
.focus()
return '必填项不能为空'
} }
} }
}) })
...@@ -966,27 +973,27 @@ ...@@ -966,27 +973,27 @@
reader.onload() reader.onload()
}) })
$('#sevenday').on('click', function() { $('#sevenday').on('click', function () {
var startTime = new Date(new Date().setHours(0,0,0,0)) var startTime = new Date(new Date().setHours(0, 0, 0, 0))
var endTime = startTime * 1 + 86400 * 7 * 1000 var endTime = startTime * 1 + 86400 * 7 * 1000
console.log(helper.dateFormat(startTime), endTime) console.log(helper.dateFormat(startTime), endTime)
$('#effectiveStarttime').val(helper.dateFormat(startTime)) $('#effectiveStarttime').val(helper.dateFormat(startTime))
$('#expireDate').val(helper.dateFormat(endTime)) $('#expireDate').val(helper.dateFormat(endTime))
}) })
$('#oneyear').on('click', function() { $('#oneyear').on('click', function () {
var startTime = new Date(new Date().setHours(0,0,0,0)) var startTime = new Date(new Date().setHours(0, 0, 0, 0))
var endTime = startTime.setFullYear(startTime.getFullYear() + 1) var endTime = startTime.setFullYear(startTime.getFullYear() + 1)
console.log(helper.dateFormat(endTime)) console.log(helper.dateFormat(endTime))
$('#effectiveStarttime').val(helper.dateFormat(new Date(new Date().setHours(0,0,0,0)))) $('#effectiveStarttime').val(helper.dateFormat(new Date(new Date().setHours(0, 0, 0, 0))))
$('#expireDate').val(helper.dateFormat(endTime)) $('#expireDate').val(helper.dateFormat(endTime))
}) })
$('#twoyears').on('click', function() { $('#twoyears').on('click', function () {
var startTime = new Date(new Date().setHours(0,0,0,0)) var startTime = new Date(new Date().setHours(0, 0, 0, 0))
var endTime = startTime.setFullYear(startTime.getFullYear() + 2) var endTime = startTime.setFullYear(startTime.getFullYear() + 2)
console.log(helper.dateFormat(endTime)) console.log(helper.dateFormat(endTime))
$('#effectiveStarttime').val(helper.dateFormat(new Date(new Date().setHours(0,0,0,0)))) $('#effectiveStarttime').val(helper.dateFormat(new Date(new Date().setHours(0, 0, 0, 0))))
$('#expireDate').val(helper.dateFormat(endTime)) $('#expireDate').val(helper.dateFormat(endTime))
}) })
...@@ -1437,8 +1444,7 @@ ...@@ -1437,8 +1444,7 @@
// 选项卡标题的lay-id属性值 // 选项卡标题的lay-id属性值
id: id id: id
}) })
var getTpl = var getTpl = `<form class="layui-form layui-form-pane layui-tab-form" action="">
`<form class="layui-form layui-form-pane layui-tab-form" 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}">
...@@ -1521,12 +1527,11 @@ ...@@ -1521,12 +1527,11 @@
$(`#nodata${id}`).removeClass('hide') $(`#nodata${id}`).removeClass('hide')
$(`#nodata${id}`).addClass('show') $(`#nodata${id}`).addClass('show')
} }
} }
} }
// 产品复选框change事件 // 产品复选框change事件
form.on('checkbox(filter)', function(data) { form.on('checkbox(filter)', function (data) {
console.log(data, '33333333333') console.log(data, '33333333333')
var roleId = +data.elem.dataset.id var roleId = +data.elem.dataset.id
var projectId = data.value var projectId = data.value
......
...@@ -49,6 +49,7 @@ ...@@ -49,6 +49,7 @@
} }
.wrapper-merchant { .wrapper-merchant {
background-color: #f4f5fa; background-color: #f4f5fa;
display: flex;
} }
.merchant-left { .merchant-left {
padding-top: 15px; padding-top: 15px;
...@@ -63,10 +64,12 @@ ...@@ -63,10 +64,12 @@
} }
.merchant-right { .merchant-right {
padding-top: 15px; padding-top: 15px;
overflow-x: auto; overflow-x: auto;
width: calc(100vw - 340px - 20px); /* max-width: calc(100vw - 340px - 20px); */
background-color: #fff; background-color: #fff;
padding-left: 20px; padding-left: 20px;
padding-right: 20px;
box-sizing: border-box; box-sizing: border-box;
} }
...@@ -95,18 +98,19 @@ ...@@ -95,18 +98,19 @@
.merchant-right .layui-btn { .merchant-right .layui-btn {
position: absolute; position: absolute;
right: 20px; right: 0px;
} }
.merchant-right .layui-input-inline { .merchant-right .layui-input-inline {
position: absolute; position: absolute;
right: 90px; right: 70px;
} }
.updateRecord { .updateRecord {
text-align: center; text-align: center;
color: #999; color: #999;
background-color: #fff; background-color: #fff;
padding: 0 10px;
} }
.mb21 { .mb21 {
...@@ -181,9 +185,9 @@ ...@@ -181,9 +185,9 @@
<main class="bg-white wrapper detail"> <main class="bg-white wrapper detail">
<div class="layui-tab layui-top-tab layui-tab-brief bg-detail"> <div class="layui-tab layui-top-tab layui-tab-brief bg-detail">
<ul class="layui-tab-title"> <ul class="layui-tab-title">
<li class="layui-this" style="padding: 0;width: 90px;margin-right: 20px;">商户信息</li> <li class="layui-this" style="padding: 0; width: 90px; margin-right: 20px">商户信息</li>
<li style="padding: 0;width: 90px;margin-right: 20px;">上级/下级商户</li> <li style="padding: 0; width: 90px; margin-right: 20px">上级/下级商户</li>
<li style="padding: 0;width: 90px;">修改记录</li> <li style="padding: 0; width: 90px">修改记录</li>
</ul> </ul>
<div class="layui-tab-content clearfix m-t-md"> <div class="layui-tab-content clearfix m-t-md">
<div class="layui-tab-item layui-show"> <div class="layui-tab-item layui-show">
...@@ -267,7 +271,7 @@ ...@@ -267,7 +271,7 @@
</div> </div>
</div> </div>
</div> </div>
<div class="MsgWrap clearfix" style="margin-bottom: 100px;"> <div class="MsgWrap clearfix" style="margin-bottom: 100px">
<div class="grayLine"></div> <div class="grayLine"></div>
<h3 class="content-title">企业信息</h3> <h3 class="content-title">企业信息</h3>
<div class="detail-content clearfix"> <div class="detail-content clearfix">
...@@ -410,7 +414,7 @@ ...@@ -410,7 +414,7 @@
<script src="https://www.layuicdn.com/layui/layui.js"></script> <script src="https://www.layuicdn.com/layui/layui.js"></script>
<script src="/js/load.js"></script> <script src="/js/load.js"></script>
<script> <script>
layui.use(['request', 'gtree', 'helper', 'table', 'form', 'treeTab', 'laypage'], function() { layui.use(['request', 'gtree', 'helper', 'table', 'form', 'treeTab', 'laypage'], function () {
var $ = layui.$ var $ = layui.$
var request = layui.request var request = layui.request
var tree = layui.gtree var tree = layui.gtree
...@@ -453,7 +457,7 @@ ...@@ -453,7 +457,7 @@
elem: 'recordPage', elem: 'recordPage',
groups: 5, groups: 5,
layout: ['count', 'page', 'skip'], layout: ['count', 'page', 'skip'],
jump: function(obj, first) { jump: function (obj, first) {
recordPage.pageNum = obj.curr recordPage.pageNum = obj.curr
recordPage.pageSize = obj.limit recordPage.pageSize = obj.limit
//首次不执行 //首次不执行
...@@ -532,7 +536,7 @@ ...@@ -532,7 +536,7 @@
id: merchantId, id: merchantId,
method: 'cn.com.glsx.merchants.merchant.findMerchantDetail' method: 'cn.com.glsx.merchants.merchant.findMerchantDetail'
} }
request(params, function(res) { request(params, function (res) {
// businessScopeCustomize // businessScopeCustomize
if (res.code == '0') { if (res.code == '0') {
roleData = helper.clone(true, res.data) roleData = helper.clone(true, res.data)
...@@ -557,11 +561,11 @@ ...@@ -557,11 +561,11 @@
method: 'cn.com.glsx.merchants.merchant.findMenuFunTreeByMerId', method: 'cn.com.glsx.merchants.merchant.findMenuFunTreeByMerId',
id: merchantId id: merchantId
} }
request(params, function(res) { request(params, function (res) {
if (res.code == '0' && res.data && res.data.length != 0) { if (res.code == '0' && res.data && res.data.length != 0) {
var authList = res.data var authList = res.data
console.log(authList) console.log(authList)
$.each(authList, function(index, item) { $.each(authList, function (index, item) {
treeTab.tabAdd( treeTab.tabAdd(
{ {
title: item.accounttypeName, title: item.accounttypeName,
...@@ -573,7 +577,7 @@ ...@@ -573,7 +577,7 @@
$('#accountAuth').append('<span class="account-type-span">' + item.accounttypeName + '</span>') $('#accountAuth').append('<span class="account-type-span">' + item.accounttypeName + '</span>')
var menuData = [] var menuData = []
if (item.products && item.products.length != 0) { if (item.products && item.products.length != 0) {
$.each(item.products, function(idx, m) { $.each(item.products, function (idx, m) {
treeTab.treeTabDetail( treeTab.treeTabDetail(
{ {
name: m.productName, name: m.productName,
...@@ -601,7 +605,7 @@ ...@@ -601,7 +605,7 @@
method: 'cn.com.glsx.merchants.menu.findSubordinateRelationship', method: 'cn.com.glsx.merchants.menu.findSubordinateRelationship',
id: merchantId id: merchantId
}, },
function(res) { function (res) {
console.log(res.data) console.log(res.data)
var data = res.data var data = res.data
$('#secondmerchantName').text(data.merchantName) $('#secondmerchantName').text(data.merchantName)
...@@ -621,7 +625,7 @@ ...@@ -621,7 +625,7 @@
id: merchantId, id: merchantId,
method: 'cn.com.glsx.merchants.merchant.findMerchantTree' method: 'cn.com.glsx.merchants.merchant.findMerchantTree'
} }
request(treeParams, function(res) { request(treeParams, function (res) {
console.log(res) console.log(res)
if (res.code == '0') { if (res.code == '0') {
treeObj = tree.create('merchantTree', res.data, null, { treeObj = tree.create('merchantTree', res.data, null, {
...@@ -639,7 +643,7 @@ ...@@ -639,7 +643,7 @@
} }
function bindEvent() { function bindEvent() {
$('#merchantBtn').on('click', function() { $('#merchantBtn').on('click', function () {
var txt = $('#treeInput').val() var txt = $('#treeInput').val()
if (!txt) { if (!txt) {
treeObj.showNodes(all_nodes) treeObj.showNodes(all_nodes)
...@@ -704,7 +708,7 @@ ...@@ -704,7 +708,7 @@
}) })
// table搜索 // table搜索
$('#tableSearch').on('click', function() { $('#tableSearch').on('click', function () {
var search = $('#tableSearchForm').val() var search = $('#tableSearchForm').val()
console.log(search) console.log(search)
getSecondTable({ getSecondTable({
...@@ -713,7 +717,7 @@ ...@@ -713,7 +717,7 @@
return false return false
}) })
$('#closeEl').on('click', function() { $('#closeEl').on('click', function () {
go('merchant', 'index') go('merchant', 'index')
}) })
...@@ -728,7 +732,7 @@ ...@@ -728,7 +732,7 @@
}, },
search search
) )
request(params, function(res) { request(params, function (res) {
// console.log(res) // console.log(res)
var data = res.data var data = res.data
var options = { var options = {
...@@ -748,9 +752,9 @@ ...@@ -748,9 +752,9 @@
pageSize: recordPage.pageSize, pageSize: recordPage.pageSize,
method: 'cn.com.glsx.merchants.menu.findLog' method: 'cn.com.glsx.merchants.menu.findLog'
} }
request(params, function(res) { request(params, function (res) {
var data = res.data var data = res.data
$.each(data.data, function(index, item) { $.each(data.data, function (index, item) {
item.index = index + 1 + recordPage.pageSize * (recordPage.pageNum - 1) item.index = index + 1 + recordPage.pageSize * (recordPage.pageNum - 1)
data.data[index].modifyContent = item.module + '-' + item.action data.data[index].modifyContent = item.module + '-' + item.action
}) })
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!