Commit ba3c054f authored by xinyuandu's avatar xinyuandu

商铺图库

parent b59ab82c
......@@ -129,7 +129,9 @@ define (['doT', 'text!temp/picture_add_template_tpl.html', 'css!style/home.css',
//获取列表
getList: function (pageNo) {
picture.pageNo = pageNo;
var params = {};
var params = {
"AuthToken" : JSON.parse(decodeURIComponent(localStorage.getItem('pcUserInfo'))).AuthToken,
};
params.pageNo = picture.pageNo;
params.pageSize = picture.pageSize;
params.img_type = $('#p_type option:selected').val() == -1 ? '' : $('#p_type option:selected').val();
......@@ -139,7 +141,7 @@ define (['doT', 'text!temp/picture_add_template_tpl.html', 'css!style/home.css',
params.label = $('#yetai_type option:selected').val() ==-1 ? '' : $('#yetai_type option:selected').html();
}
$.ajax ({
url: '/api/getImageDepotList',//获取列表
url: '/index/getImageDepotList',//获取列表
type: 'GET',
async: true,
data: params,
......@@ -158,7 +160,7 @@ define (['doT', 'text!temp/picture_add_template_tpl.html', 'css!style/home.css',
//查看功能获取数据
getDataByParams : function(id){
$.ajax ({
url: '/api/getImageDepotById',//获取列表
url: '/index/getImageDepotById',//获取列表
type: 'GET',
async: true,
data: {'id' : id },
......@@ -191,11 +193,12 @@ define (['doT', 'text!temp/picture_add_template_tpl.html', 'css!style/home.css',
//获取业态
getYetai: function($yetai,$pt,isModal) {
$.ajax({
url: '/api/getImageTypeLabel',
url: '/index/getImageTypeLabel',
type: 'GET',
async: true,
data: {
"pageSize": 1000
"AuthToken" : JSON.parse(decodeURIComponent(localStorage.getItem('pcUserInfo'))).AuthToken,
"pageSize": 10
},
dataType: 'json',
success: function(data) {
......@@ -252,7 +255,7 @@ define (['doT', 'text!temp/picture_add_template_tpl.html', 'css!style/home.css',
};
$.ajax({
url: '/api/addImageDepot',
url: '/index/addImageDepot',
type: 'GET',
async: true,
data: params,
......@@ -274,7 +277,7 @@ define (['doT', 'text!temp/picture_add_template_tpl.html', 'css!style/home.css',
//删除表格的行(单行删除)
deletePictureById: function(id) {
$.ajax({
url: '/api/delImageDepot',
url: '/index/delImageDepot',
type: 'POST',
async: true,
data: { "id": id},
......
......@@ -8,8 +8,19 @@
<img src='[%= it[item]['img_file_path'] %]' >
</td>
<td>[%= it[item]['img_type'] %]</td>
[% if ( it[item]['img_type'] == 2 ){ %]
<td>人群图</td>
<td>-</td>
[% } else if ( it[item]['img_type'] == 1 ) { %]
<td>室内图</td>
<td>[%= it[item]['label'] %] </td>
[% } else if ( it[item]['img_type'] == 0) { %]
<td>室外图</td>
<td>[%= it[item]['label'] %] </td>
[% }else { %]
<td>-</td>
<td>-</td>
[% } %]
<td>
<a class="btn1 btn-success is_show" data-toggle="modal" data-id='[%= it[item]["id"] %]' data-target="#modal-show">查看</a>
<a class="btn1 btn-danger announcement-del" href="#modal-delete" data-toggle="modal" data-id='[%= it[item]["id"] %]'>删除</a>
......
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