Authored by ZhongW

视频管理

... ... @@ -13,8 +13,8 @@ module.exports = function (app) {
}
});
//产品图片数据列表
//app.post("/shotManage/proPhoto/index2", "shootMeter_queryProductPhotoList");
//视频列表
app.post("/video/queryVideosList", "video_queryVideosList");
//添加产品图片
//app.post("/shotManage/proPhoto/add", "shootMeter_addProductBatchPhoto");
... ...
... ... @@ -8,18 +8,14 @@ module.exports = {
apis: {
/************************************产品视频管理*************************************/
queryProductPhotoList: {
title: "产品图片数据列表",
url: "/productPhoto/queryProductPhotoList",
queryVideosList: {
title: "视频列表",
url: "/videos/queryVideosList",
params: {
page: {type: Number},
size: {type: Number},
productSkn: {type: Number},
productSku: {type: Number},
productSkc: {type: Number},
startTime: {type: Number},
shopId: {type: Number},
endTime: {type: Number}
skn:{type: String},
videoName: {type: String}
}
}
}
... ...
... ... @@ -21,7 +21,7 @@
<div class="panel-col2">
<a id="filter-btn" href="javascript:;" class="btn btn-info">查询</a>
<a id="filter-all" href="/shotManage/proPhoto/index" class="btn btn-info">全部</a>
<a id="filter-all" href="/video/index" class="btn btn-info">全部</a>
</div>
</div>
</div>
... ... @@ -29,6 +29,123 @@
<div id="content-list"></div>
</div>
<script type="text/template" id="template">
<div class="rows" id="baseform">
<div class="form-group">
<label class="col-sm-2 control-label" for="avatar">头像<span class="red">*</span></label>
[[if avatar]]
<div class="col-sm-6">
<div class="goods-img">
<a class="fileinput-button-icon" href="javascript:void(0);">
<img id="avatarpic" src="[[avatar]]?imageView/2/w/100/h/100">
</a>
<i class="remove-item-btn remove1 glyphicon glyphicon-remove-circle" data-link="avatar"></i>
</div>
</div>
[[else]]
<div class="col-sm-6">
<input type="file" bucket="modelCard" class="form-control avatar" id="avatar" name="avatar"
placeholder="头像" data-field="avatar"/>
</div>
[[/if]]
</div>
<div class="form-group">
<label class="col-sm-2 control-label" for="modelName">姓名<span class="red">*</span></label>
<div class="col-sm-3">
<input type="text" value="[[modelName]]" class="form-control observe" id="modelName"
placeholder="姓名" data-field="modelName"/>
</div>
<label class="col-sm-2 control-label" for="englishName">艺名<span class="red">*</span></label>
<div class="col-sm-3">
<input type="text" value="[[englishName]]" class="form-control observe" id="englishName"
placeholder="艺名" data-field="englishName"/>
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label" for="nationality">国籍</label>
<div class="col-sm-3">
<input type="text" value="[[nationality]]" class="form-control observe" id="nationality"
placeholder="国籍" data-field="nationality"/>
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label" for="height">身高<span class="red">*</span></label>
<div class="col-sm-3">
<input type="number" value="[[height]]" class="form-control observe" id="height"
match="numbers" placeholder="身高(cm)" data-field="height"/>
</div>
<label class="col-sm-2 control-label" for="weight">体重<span class="red">*</span></label>
<div class="col-sm-3">
<input type="number" value="[[weight]]" class="form-control observe" id="weight"
match="numbers" placeholder="体重(kg)" data-field="weight"/>
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label" for="dressSize">穿衣尺码</label>
<div class="col-sm-3">
<input type="text" value="[[dressSize]]" class="form-control observe" id="dressSize"
placeholder="穿衣尺码" data-field="dressSize"/>
</div>
<label class="col-sm-2 control-label" for="shoeSize">鞋码</label>
<div class="col-sm-3">
<input type="text" value="[[shoeSize]]" class="form-control observe" id="shoeSize"
placeholder="鞋码" data-field="shoeSize"/>
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label">三围<span class="red">*</span></label>
<div class="col-sm-3">
<input type="number" value="[[Bust]]" class="form-control observe" id="Bust"
match="numbers" placeholder="胸围(cm)" data-field="Bust"/>
</div>
<div class="col-sm-3">
<input type="number" value="[[waist]]" class="form-control observe" id="waist"
match="numbers" placeholder="腰围(cm)" data-field="waist"/>
</div>
<div class="col-sm-3">
<input type="number" value="[[hips]]" class="form-control observe" id="hips"
match="numbers" placeholder="臀围(cm)" data-field="hips"/>
</div>
</div>
<div class="form-group">
<label class="col-sm-2 control-label" for="avatar">模特卡</label>
[[if modelCard]]
<div class="col-sm-6">
<div class="goods-img">
<a class="fileinput-button-icon" href="javascript:void(0);">
<img src="[[modelCard]]?imageView/2/w/100/h/100">
</a>
<i class="remove-item-btn remove1 glyphicon glyphicon-remove-circle" data-link="modelCard"></i>
</div>
</div>
[[else]]
<div class="col-sm-6">
<input type="file" bucket="modelCard" class="form-control modelCard" id="modelCard" name="modelCard"
placeholder="模特卡" data-field="modelCard"/>
</div>
[[/if]]
</div>
<div class="form-group">
<label class="col-sm-2 control-label">状态</label>
<div class="col-sm-8">
<label style="cursor: pointer;"><input type="radio" name="status" class="observe" data-field="status"
checked value="1">启用</label>
<label style="cursor: pointer;"><input type="radio" name="status" class="observe" data-field="status"
value="0">禁用</label>
</div>
<input type="hidden" id="status" class="observe" value="[[status]]" for="radio" class="observe"
data-field="status">
</div>
</div>
</script>
<!--上传图片-->
<script type="text/template" id="template1">
<div class="rows">
... ...
... ... @@ -44,8 +44,8 @@ var apiCofig = {
//root:__dirname,
EnvConst:{
// domain:"http://192.168.102.48:8088/platform",
//domain:"http://127.0.0.1:8080/platform",
domain:"http://172.16.6.200:8088/platform",
domain:"http://127.0.0.1:8080/platform",
// domain:"http://172.16.6.200:8088/platform",
yohoSearch: 'http://192.168.102.216:8080/yohosearch',
system:Iaccount
},
... ...
/**
* Created by zw on 2016/11/3.
* 产品图片管理
* 视频管理
*/
var $ = require('jquery');
var common = require('../../common/common');
... ... @@ -20,36 +20,39 @@ var g = new common.grid({
},
parms: function () {
return {
//查询参数
productSkn: common.util.__input('content-filter1'),
productSkc: common.util.__input('content-filter2'),
productSku: common.util.__input('content-filter3'),
startTime: ((new Date($('#starttime').val())).getTime()) / 1000,
endTime: ((new Date($('#endtime').val())).getTime()) / 1000,
shopId: common.util.__input("shopId")
skn: common.util.__input('content-filter1'),
videoName: common.util.__input('content-filter2')
};
},
//列表显示
columns: [
{display: "SKN", name: "productSkn"},
{display: "视频名称", name: "videoName"},
{display: "关联SKN", name: "skn"},
{
display: "最后上传时间", name: "lastAddTime",
render: function (item) {
var t = new Date(item.lastAddTime * 1000);
var formatted = common.util.__dateFormat(t, "yyyy-MM-dd hh:mm:ss");
return "<p>" + formatted + "</p>";
display: '视频',
name: 'url',
render: function (item) {
if (item.url) {
return '<img height="140" width="80" src="' + item.url +'?vframe/jpg/offset/0'+ '">';
} else {
return '';
}
}
},
},
{display: "视频大小", name: "videoSize",render:function(item) { return item.videoSize+"M"}},
{display: "备注", name: "note"},
{
display: "操作", name: "", render: function (item) {
var arr = [];
arr.push('<a class="btn btn-xs btn-info update" data-index="' + item.__index + '">编辑</a>');
return arr.join('');
}
var arr = [];
arr.push('<a class="btn btn-xs btn-info update" data-index="' + item.__index + '">编辑</a>');
arr.push('<a class="btn btn-xs btn-danger delete" data-index="' + item.__index + '">删除</a>');
return arr.join('');
}
}
]
});
// g.init("/shotManage/proPhoto/index2");
g.init("/video/queryVideosList");
var Bll = {
... ...