Commit a36d6b3b authored by 华国豪's avatar 华国豪 🙄
parents 41eeece2 956abc70
......@@ -3,10 +3,77 @@
height: auto
}
.Rotationchart .TFimgList:hover .TFIMGzhe {
display: block;
}
.AdManageList .TFimgList {
float: left;
width: 220px;
height: 120px;
border-radius: 4px;
position: relative;
margin: 0 10px 10px 0;
overflow: hidden;
}
.AdManageList .TFIMGzhe {
width: 100%;
height: 100%;
background: rgba(0, 0, 0, 0.4);
position: absolute;
top: 0;
text-align: center;
line-height: 115px;
border-radius: 4px;
display: none;
}
.AdManageList .TFreupload {
width: 32px;
height: 32px;
border-radius: 50%;
line-height: 32px;
top: 50px;
left: 53px;
display: inline-block;
text-align: center;
background-color: gray;
color: #fff;
}
.AdManageList .TFimgList:hover .TFIMGzhe {
display: block;
}
.AdManageList .TFimgList img {
width: 100%;
height: 100%;
}
.AdManageList ._tit {
padding-left: 10px;
border-left: 3px solid #e95252;
font-size: 16px;
color: #000000;
}
.AdManageList .changeMsg li {
float: left;
margin-right: 30px;
color: #666666;
}
</style>
<template>
<div class="flexOne">
<div class="clearfix"></div>
<div class="flexOne AdManageList">
<div class="query-box">
<ul>
<li>
<input type="button" class="normalBtn" value="新增" @click="IsShowBtm=true" />
</li>
</ul>
</div>
<table class="singeRowTable" border="0" cellspacing="0" cellpadding="0" v-loading="loading">
<tr>
<th>编号</th>
......@@ -17,9 +84,12 @@
</tr>
<tr v-for="item in dataList">
<td>{{item.Id}}</td>
<td>{{item.AdImage}}</td>
<td>
<img v-if="!item.ShowImage" src="../../assets/img/bg_c3@3x.png" />
<img v-else :src='item.ShowImage' style="width:100px;height:40px;" />
</td>
<td>{{item.AdLink}}</td>
<td>{{item.Status}}</td>
<td>{{item.StatusStr}}</td>
<td>
<el-button-group>
<el-tooltip class="item" effect="dark" :content="$t('active.ld_editInfo')" placement="top">
......@@ -38,6 +108,43 @@
<i class="iconfont icon-kong"></i>
<p>{{$t("active.ld_noData")}}</p>
</div>
<div class="combottomDiv" v-if="IsShowBtm" style="left:0;">
<el-row>
<el-col :span="20">
<p class="combottomTitle">广告图</p>
</el-col>
<el-col :span="4">
<input type="button" class="normalBtn" @click="SetAdmanage()" value="保存" />
<input type="button" class="hollowFixedBtn" @click="clearAdManage(),IsShowBtm=false" value="取消" />
</el-col>
</el-row>
<el-form label-width="80px">
<ul class="changeMsg">
<li>
<el-form-item label="图片">
<div class="TFimgList">
<img v-if="!ShowImgUrl" src="../../assets/img/bg_c3@3x.png">
<img v-else :src='ShowImgUrl'>
<div class="TFIMGzhe">
<div class="TFreupload">
<el-upload :file-list="fileList" :http-request="UploadImage" :multiple="false" :limit="1"
accept="image/jpeg, image/gif, image/png, image/bmp" :show-file-list="false" action>
<i class="iconfont icon-Edit"></i>
</el-upload>
</div>
</div>
</div>
</el-form-item>
</li>
<li>
<el-form-item label="广告链接">
<el-input v-model="addMsg.AdLink" class="w210"></el-input>
</el-form-item>
</li>
</ul>
</el-form>
</div>
</div>
</template>
<script>
......@@ -53,9 +160,13 @@
},
loading: false,
dataList: [],
//显示底部
IsShowBtm: false,
fileList: [],
//图片全路劲
ShowImgUrl: "",
};
},
mounted() {
this.getList();
},
......@@ -77,20 +188,32 @@
SetAdmanage() {
this.apipost("ShopAd_post_SetAdManageService", this.addMsg, res => {
if (res.data.resultCode === 1) {
this.IsShowBtm = false;
this.clearAdManage();
this.getList();
} else {
this.Error(res.data.message)
}
}, null);
},
//情况默认值
clearAdManage() {
this.addMsg.Id = 0;
this.addMsg.AdImage = "";
this.addMsg.AdLink = "";
this.ShowImgUrl = "";
},
//根据编号获取广告详情
getAdManage(Id) {
this.IsShowBtm = true;
this.apipost("ShopAd_get_GetAdManageService", {
Id: Id
}, res => {
if (res.data.resultCode === 1) {
this.addMsg = res.data.data;
if (this.addMsg.AdImage) {
this.ShowImgUrl = this.domainManager().ViittoFileUrl + this.addMsg.AdImage;
}
} else {
this.Error(res.data.message)
}
......@@ -98,34 +221,31 @@
},
//根据编号删除广告详情
removeAdManage(Id) {
this.apipost("ShopAd_post_RemoveAdManageService", {
Id: Id
}, res => {
if (res.data.resultCode === 1) {
this.getList();
} else {
this.Error(res.data.message)
}
}, null);
var that = this;
this.Confirm("是否删除此广告?", function () {
that.apipost("ShopAd_post_RemoveAdManageService", {
Id: Id
}, res => {
if (res.data.resultCode === 1) {
that.getList();
} else {
that.Error(res.data.message)
}
}, null);
});
},
},
//上传图片
UploadImage(file) {
let newArr = [];
newArr.push(file.file);
let fileName = file.file.name;
var path = "/Upload/Temporary/";
this.UploadSelfFileT(path, newArr, x => {
//统一图片处理
if (this.DiningImageArray.length === 5) {
return this.$message.error('最多上传5张图片')
}
var obj = {}
var str = x.data.FilePath;
var imgUrl = this.domainManager().ViittoFileUrl + x.data.FilePath;
this.DiningImageArray.push(imgUrl);
});
},
//上传图片
UploadImage(file) {
let newArr = [];
newArr.push(file.file);
let fileName = file.file.name;
var path = "/Upload/Temporary/";
this.UploadSelfFileT(path, newArr, x => {
this.addMsg.AdImage = x.data.FilePath;
this.ShowImgUrl = this.domainManager().ViittoFileUrl + x.data.FilePath;
});
},
}
};
</script>
<style>
.GuestAccountList .el-button-group .el-button{
padding:5px;
}
</style>
<template>
<div class="flexOne">
<div class="flexOne GuestAccountList">
<div class="query-box">
<ul class="user_time_picker">
<li>
<span>
<em>姓名</em>
<el-input v-model="msg.AccountName" @keyup.enter.native="getList"></el-input>
</span>
</li>
<li>
<span>
<em>护照号</em>
<el-input v-model="msg.PassportNo" @keyup.enter.native="getList"></el-input>
</span>
</li>
<li>
<span>
<em>账户</em>
<el-input v-model="msg.LoginAccount" @keyup.enter.native="getList"></el-input>
</span>
</li>
<li>
<span>
<em>手机号码</em>
<el-input v-model="msg.MobilePhone" @keyup.enter.native="getList"></el-input>
</span>
</li>
<li>
<span>
<em>{{$t('admin.admin_status')}}</em>
<el-select filterable v-model="msg.AccountStatus">
<el-option :label="$t('pub.unlimitedSel')" :value="-1"></el-option>
<el-option label="正常" :value="0"></el-option>
<el-option label="禁用" :value="1"></el-option>
<el-option label="删除" :value="2"></el-option>
</el-select>
</span>
</li>
<li>
<input type="button" @click="getList()" class="hollowFixedBtn" :value="$t('pub.searchBtn')">
</li>
</ul>
</div>
<div class="clearfix"></div>
<table class="singeRowTable" border="0" cellspacing="0" cellpadding="0" v-loading="loading">
<tr>
......@@ -24,17 +72,17 @@
<el-button-group>
<template v-if="item.AccountStatus==0">
<el-tooltip class="item" effect="dark" content="禁用" placement="top">
<el-button type="primary" size="mini" icon="el-icon-edit" @click="SetAccountStatus(item.Id,1)">
<el-button type="primary" size="mini" icon="iconfont icon-jinyong" @click="SetAccountStatus(item.Id,1)">
</el-button>
</el-tooltip>
<el-tooltip class="item" effect="dark" content="删除" placement="top">
<el-button type="danger" size="mini" class="iconfont icon-quxiao1" @click="SetAccountStatus(item.Id,2)">
<el-button type="danger" size="mini" icon="iconfont icon-img_delete_small" @click="SetAccountStatus(item.Id,2)">
</el-button>
</el-tooltip>
</template>
<template v-else>
<el-tooltip class="item" effect="dark" content="启用" placement="top">
<el-button type="primary" size="mini" icon="el-icon-edit" @click="SetAccountStatus(item.Id,0)">
<el-button type="primary" size="mini" icon="iconfont icon-qidong" @click="SetAccountStatus(item.Id,0)">
</el-button>
</el-tooltip>
</template>
......@@ -59,6 +107,11 @@
return {
//查询参数
msg: {
AccountName: "", //姓名
PassportNo: "", //护照
MobilePhone: "", //手机号码
AccountStatus: -1, //状态,
LoginAccount: "", //登录账户
pageIndex: 1,
pageSize: 10,
total: 0,
......
......@@ -275,8 +275,9 @@
<span>{{$t('Operation.Op_TransportState')}}</span>
<span>
<el-select class="w180 multiple_input" v-model="queryMsg.IsShowUnion">
<el-option :key="1" :label="$t('system.table_isShows')" :value="1"></el-option>
<el-option :key="0" :label="$t('Operation.Op_hide')" :value="0"></el-option>
<el-option :key="-1" label="全部" :value="-1"></el-option>
<el-option :key="0" label="主团" :value="0"></el-option>
<el-option :key="1" label="分销团" :value="1"></el-option>
</el-select>
</span>
</div>
......@@ -732,7 +733,7 @@
RateOnDay: '-1',
RateOn: '-1',
TeamType: 2, //一日游的团
IsShowUnion: 1,
IsShowUnion: -1,
TCID: '',
},
remarkMsg: {
......@@ -1484,7 +1485,7 @@
created () {
this.checkAllTeam();
//默认显示联运
this.queryMsg.IsShowUnion = 1
this.queryMsg.IsShowUnion = -1;
let userInfo = this.getLocalStorage()
this.CurrentUserInfo = userInfo
......
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