记得上下班打卡 | git大法好,push需谨慎

Commit d7561000 authored by dongchun's avatar dongchun

修改首页页面布局排版

parent ed11a382
...@@ -179,6 +179,15 @@ ...@@ -179,6 +179,15 @@
} else { } else {
} }
promiseMethods('/front-index/list','post').then(res=>{
console.log(res, 'resp')
let { data } = res;
data.forEach(item => {
if (item.moudleName == "moFang") {
$("#sorting").val(item.indexs)
}
})
})
promiseMethods('/goblin-front-cube/list', 'post').then(res => { promiseMethods('/goblin-front-cube/list', 'post').then(res => {
let { data } = res; let { data } = res;
if (data && data.length > 0) { if (data && data.length > 0) {
...@@ -411,10 +420,9 @@ ...@@ -411,10 +420,9 @@
"status": 0 "status": 0
}; };
return promiseMethods('/front-index/update', 'post', JSON.stringify(data), 'application/json') return promiseMethods('/front-index/update', 'post', JSON.stringify(data), 'application/json')
}).then(() => { }).then((res) => {
layer.msg("保存成功!") layer.msg("保存成功!")
$.modal.close(); $.operate.successCallback(res);
refreshItem()
}) })
} }
......
...@@ -328,8 +328,7 @@ ...@@ -328,8 +328,7 @@
console.log(res, 'res') console.log(res, 'res')
if (res.code == 0) { if (res.code == 0) {
layer.msg('保存成功!') layer.msg('保存成功!')
$.modal.close(); $.operate.successCallback(res);
refreshItem()
} }
}) })
} }
......
...@@ -14,7 +14,13 @@ ...@@ -14,7 +14,13 @@
flex: 1; flex: 1;
display: flex; display: flex;
flex-direction: column; flex-direction: column;
align-items: center; align-items: flex-start;
height: 100vh;
position: relative;
}
.gitHot {
position: absolute;
bottom: 40px;
} }
.left_title, .right_title { .left_title, .right_title {
margin-bottom: 12px; margin-bottom: 12px;
...@@ -147,11 +153,11 @@ ...@@ -147,11 +153,11 @@
<div class="function_btn"> <div class="function_btn">
<button type="button" class="btn btn-primary" onclick="goArea(1)">金刚位</button> <button type="button" class="btn btn-primary" onclick="goArea(1)">金刚位</button>
<button type="button" class="btn btn-warning" onclick="goArea(2)">活动banner</button> <button type="button" class="btn btn-warning" onclick="goArea(2)">活动banner</button>
<button type="button" class="btn btn-info" onclick="goArea(3)">限时秒杀</button>
<button type="button" class="btn btn-success" onclick="goArea(4)">魔方</button> <button type="button" class="btn btn-success" onclick="goArea(4)">魔方</button>
<button type="button" class="btn" onclick="goArea(7)">精选商品</button> <button type="button" class="btn btn-info" onclick="goArea(7)">精选商品</button>
<!-- <button type="button" class="btn" disabled onclick="goArea(3)">限时秒杀</button> -->
</div> </div>
<button type="button" class="btn" onclick="git()">上线</button> <button type="button" class="btn btn-danger gitHot" onclick="git()">上线</button>
</div> </div>
<div class="right_content"> <div class="right_content">
<div class="right_title"> <div class="right_title">
...@@ -209,26 +215,26 @@ ...@@ -209,26 +215,26 @@
switch(num) { switch(num) {
case 1: case 1:
// $.modal.open('添加用户', prefix2 + "/form", '900', '320', callback); // $.modal.open('添加用户', prefix2 + "/form", '900', '320', callback);
$.modal.open('金刚位', prefix2 + "/kingArea?id=" + 1212) $.modal.open('金刚位', prefix2 + "/kingArea?id=" + 1212,900,800, cancel)
break; break;
case 5: case 5:
$.modal.open('商品搜索', prefix2 + "/searchStore?id=" + 1212) $.modal.open('商品搜索', prefix2 + "/searchStore?id=" + 1212,900,800, cancel)
// $.modal.openTab('商品搜索', prefix2 + "/searchStore?id=" + 1212) // $.modal.openTab('商品搜索', prefix2 + "/searchStore?id=" + 1212)
break; break;
case 6: case 6:
$.modal.open('顶部banner', prefix2 + "/topBanner?id=" + num) $.modal.open('顶部banner', prefix2 + "/topBanner?id=" + num,900,800, cancel)
// $.modal.openTab('顶部banner', prefix2 + "/topBanner?id=" + num) // $.modal.openTab('顶部banner', prefix2 + "/topBanner?id=" + num)
break; break;
case 2: case 2:
$.modal.open('活动banner', prefix2 + "/topBanner?id=" + num) $.modal.open('活动banner', prefix2 + "/topBanner?id=" + num,900,800, cancel)
// $.modal.openTab('活动banner', prefix2 + "/topBanner?id=" + num) // $.modal.openTab('活动banner', prefix2 + "/topBanner?id=" + num)
break; break;
case 4: case 4:
$.modal.open('魔方位', prefix2 + "/RubikArea?id=" + num) $.modal.open('魔方位', prefix2 + "/RubikArea?id=" + num,900,800, cancel)
// $.modal.openTab('魔方位', prefix2 + "/RubikArea?id=" + num) // $.modal.openTab('魔方位', prefix2 + "/RubikArea?id=" + num)
break; break;
case 7: case 7:
$.modal.open('精选商品', prefix2 + "/carefullyGoods?id=" + num) $.modal.open('精选商品', prefix2 + "/carefullyGoods?id=" + num,900,800, cancel)
// $.modal.openTab('精选商品', prefix2 + "/carefullyGoods?id=" + num) // $.modal.openTab('精选商品', prefix2 + "/carefullyGoods?id=" + num)
break; break;
} }
...@@ -251,6 +257,9 @@ ...@@ -251,6 +257,9 @@
} }
}) })
} }
function cancel () {
modalPx()
}
function git () { function git () {
$.ajax({ $.ajax({
type: 'post', type: 'post',
......
...@@ -168,6 +168,15 @@ ...@@ -168,6 +168,15 @@
} else { } else {
} }
promiseMethods('/front-index/list','post').then(res=>{
console.log(res, 'resp')
let { data } = res;
data.forEach(item => {
if (item.moudleName == "jinGangWei") {
$("#sorting").val(item.indexs)
}
})
})
showDetail (1) showDetail (1)
}) })
function showDetail (numType) { function showDetail (numType) {
...@@ -429,8 +438,7 @@ ...@@ -429,8 +438,7 @@
}).then((res)=> { }).then((res)=> {
layer.msg('保存成功!') layer.msg('保存成功!')
// $.modal.closeTab(); // $.modal.closeTab();
$.modal.close(); $.operate.successCallback(res);
refreshItem()
}) })
} }
function common (num) { function common (num) {
......
...@@ -184,7 +184,7 @@ ...@@ -184,7 +184,7 @@
console.log(data, 'data222') console.log(data, 'data222')
promiseMethods('/hotWord/updateOrCreate', 'post', JSON.stringify(data), 'application/json').then(res => { promiseMethods('/hotWord/updateOrCreate', 'post', JSON.stringify(data), 'application/json').then(res => {
layer.msg('创建成功!') layer.msg('创建成功!')
$.modal.close(); // $.modal.close();
$.operate.successCallback(res); $.operate.successCallback(res);
}) })
// refreshItem() // refreshItem()
......
...@@ -171,6 +171,15 @@ ...@@ -171,6 +171,15 @@
} else { } else {
} }
promiseMethods('/front-index/list','post').then(res=>{
console.log(res, 'resp')
let { data } = res;
data.forEach(item => {
if (item.moudleName == "huDongBanner") {
$("#sorting").val(item.indexs)
}
})
})
let name = 'id'; let name = 'id';
var reg = new RegExp("(^|&)"+ name +"=([^&]*)(&|$)"); var reg = new RegExp("(^|&)"+ name +"=([^&]*)(&|$)");
var r = window.location.search.substr(1).match(reg); var r = window.location.search.substr(1).match(reg);
...@@ -387,8 +396,7 @@ ...@@ -387,8 +396,7 @@
} }
}).then(res => { }).then(res => {
layer.msg("保存成功!") layer.msg("保存成功!")
$.modal.close(); $.operate.successCallback(res);
refreshItem()
}) })
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment