Authored by xuhongyun

build

... ... @@ -370,7 +370,7 @@ webpackJsonp([31],[
//html.push('<a data-index="'+ item.__index+ '" href="JavaScript:;" class="btn btn-info btn-xs edit-class-btn" id="btn-item-info">查看</a>');
html.push('<a href="/goods/audit/info/' + item.productSkn + '" class="btn btn-info btn-xs info-btn">查看</a>');
html.push('<a target="_black" href="/goods/audit/info/' + item.productSkn + '" class="btn btn-info btn-xs info-btn">查看</a>');
//if (item.status == 3 || item.status == 6) { // 驳回
// html.push('<a data-index="'+ item.__index+ '" href="JavaScript:;" class="btn operation btn-success btn-xs edit-class-btn" id="btn-item-pass">通过</a>');
... ...
... ... @@ -14146,6 +14146,65 @@ webpackJsonp([46],{
});
}
//封面视频调用弹出
var uesVedioDialog = null, uesVedioIndex=0;
$(document).on('click', '.btn-use-vedio', function() {
var productSkc = $(this).attr('data-productSkc'); // 当前点击的图片的skc信息
var skcIndex = $(this).attr('data-skcIndex');
var uesVedioIndex = $(this).data("index"); // 当前点击图片在当前skc中的序号
var selectVedioId = $(this).attr("data-vedioId"); // 当前图片已经选择的视频id 没选择则为null
common.util.__ajax({
url: '/productVideo/queryProductVideoList',
data: {
skn: NETSALEDATA.baseProductInfo.baseProduct.productSkn
}
}, function(res) {
var data = res.data;
var imgHtml = '';
if (res.code == 200 && data instanceof Array && data.length > 0) {
var vedioHtml = "<table><tr>";
$.each(data, function(i, vedioItem) {
var select_img_class = "";
if (selectVedioId && selectVedioId == vedioItem.id) {
select_img_class = " select_img";
}
vedioHtml += '<td><div style="height:123px; width:125px;margin:5px;text-align: center;line-height:20px" ><a style="display:inline-block" class="vedio_a'+ select_img_class + '"><img class="use-vedio"'
+ ' src="http://admin.portal.yohobuy.com/static/assets/images/defaultvideo.png'
+ '" alt="" data-vedioid="' + vedioItem.id + '" data-index="' + i + '" style="cursor:pointer;" /></a><span style="display:inline;height:100%;line-height:0px">' + vedioItem.videoName + "-"
+ vedioItem.id +'</span></div></td>';
})
vedioHtml += "</tr></table></div>";
imgHtml += vedioHtml;
uesVedioDialog = common.dialog.confirm("调用视频", imgHtml, function(){ // 确认事件触发
var newSelectVedioId = $(".vedio_a.select_img").find('img').attr('data-vedioid'); // 重新选择的视频id 如果无值则代表需要清除当前封面的视频
if (newSelectVedioId) {
$('a[data-index='+ uesVedioIndex +'][data-productSkc='+ productSkc +']').attr('data-vedioId', newSelectVedioId).addClass('info');
} else {
$('a[data-index='+ uesVedioIndex +'][data-productSkc='+ productSkc +']').attr('data-vedioId', '').removeClass('info');
}
resetVedioId(skcIndex, uesVedioIndex, newSelectVedioId);
},function(){ // 取消的事件触发
});
} else {
common.util.__tip('没有可调用的视频', 'warning');
}
}, true);
});
$(document).on('click', '.use-vedio', function(event) { //点击调用的视频列表
var index=$(this).data("index");
$(".vedio_a").not($(this).parent("a")).removeClass("select_img");
$(this).parent("a").toggleClass("select_img");
});
function resetVedioId(skcIndex, uesVedioIndex, newSelectVedioId) { //设置视频Id到内存中goodList中
var item = goodsList[skcIndex].goodsImagesList[uesVedioIndex];
item.vedioUrlId = newSelectVedioId;
renderGoodList();
};
/***/ },
... ...
... ... @@ -44,7 +44,7 @@ var Iaccount = {
var apiCofig = {
//root:__dirname,
EnvConst:{
domain:"http://192.168.102.48:8088/platform",
domain:"http://192.168.102.210:8088/platform",
//domain:"http://127.0.0.1:8088/platform",
// domain:"http://172.16.6.200:8088/platform",
//domain:"http://192.168.102.202:8088/platform",
... ...
... ... @@ -46,6 +46,7 @@
<script type="text/template" id="fenmianTemp">
[[each goodsList as item index]]
<div class="form-group">
<div class="cover-color" style="text-align: left; margin-left: 10px">颜色封面:</div>
<div class="fm-side col-sm-2">
<div class="goods-img-left">
<p>SKC: [[item.productSkc]]</p>
... ... @@ -60,9 +61,7 @@
[[if index2%2==1]] </td></tr><tr><td>[[/if]]
[[/each]]</td>
</tr></table>
</div>
<div class="cover-color">颜色封面:</div>
</div>
<ul class="cover-image-list col-sm-10 image_index_class" style="padding: 0;margin: 0;" data-index=[[index]]>
[[each item.goodsImagesList as _item _index]]
... ... @@ -71,7 +70,7 @@
<a class="fileinput-button-icon" href="javascript:void(0);"><img src="[[_item.imageUrl]]"></a>
<i class="remove-item-btn glyphicon glyphicon-remove-circle"></i>
</div>
<div class="cover-color">
<div class="cover-color" style="line-height: 26px; height: 52px;">
[[if _item.isDefault=="Y"]]
<a href="javascript:;" class="btn btn-default btn-metro info" data-i="0">默认</a>
[[else]]
... ... @@ -92,6 +91,11 @@
[[else]]
<a href="javascript:;" class="btn btn-default btn-metro" data-i="2">女封</a>
[[/if]]
[[/if]]
[[if _item.vedioUrlId && _item.vedioUrlId != ""]]
<a href="javascript:;" class="btn-use-vedio btn btn-default info" data-index="[[_index]]" data-skcIndex="[[index]]" data-productSkc="[[item.productSkc]]" data-vedioId="[[_item.vedioUrlId]]">调用视频</a>
[[else]]
<a href="javascript:;" class="btn-use-vedio btn btn-default " data-index="[[_index]]" data-skcIndex="[[index]]" data-productSkc="[[item.productSkc]]">调用视频</a>
[[/if]]
</div>
</li>
... ...
... ... @@ -103,7 +103,8 @@
<option value="yohoCoin">YOHO</option>
<option value="coupon">优惠券</option>
<option value="feedback">意见反馈</option>
<option value="invite">邀请好友</option>
<option value="invite">分享购</option>
<option value="inviteFriend">邀请好友</option>
<option value="online">在线客服</option>
<option value="willDeliver">待发货</option>
<option value="willPay">待付款</option>
... ...