Commit d6612ef4 authored by 黄奎's avatar 黄奎

页面修改

parent b5e7e1dd
......@@ -74,10 +74,15 @@
pageSize: 10,
},
addMsg: {
Id: 0,
Name: '', //分类名称
Level: 1, //层级
ParentId: 0, //父节点编号
Id: 0, //编号
CateId: 0, //分类编号
GoodsId: 0, //商品编号
CoverImg: "", //封面图
MaterialImg: "", //素材图片
MaterialInfo: "", //素材文案
LinkUrl: "", //链接地址
IsTop: 0, //是否置顶
SortNum: 0, //排序
},
};
},
......@@ -85,7 +90,7 @@
//获取分类列表
getList() {
this.loading = true;
this.apipost("/api/Share/GetShareCategoryList", this.msg,
this.apipost("/api/Share/GetShareFriendPageList", this.msg,
res => {
this.loading = false;
if (res.data.resultCode === 1) {
......@@ -98,7 +103,7 @@
},
//新增修改分类
submitform() {
this.apipost("/api/Share/SetShareCategory", this.addMsg,
this.apipost("/api/Share/SetShareFriend", this.addMsg,
res => {
this.loading = false;
if (res.data.resultCode === 1) {
......@@ -113,9 +118,9 @@
null
);
},
//获取分类
getCategory(Id) {
this.apipost("/api/Share/GetShareCategory", {
//获取实体
getShareFriend(Id) {
this.apipost("/api/Share/GetShareFriend", {
Id: Id
},
res => {
......@@ -123,9 +128,14 @@
var tempObj = res.data.data;
if (tempObj) {
this.addMsg.Id = tempObj.Id;
this.addMsg.Name = tempObj.Name;
this.addMsg.Level = tempObj.Level;
this.addMsg.ParentId = tempObj.ParentId;
this.addMsg.CateId = tempObj.CateId;
this.addMsg.GoodsId = tempObj.GoodsId;
this.addMsg.CoverImg = tempObj.CoverImg;
this.addMsg.MaterialImg = tempObj.MaterialImg;
this.addMsg.MaterialInfo = tempObj.MaterialInfo;
this.addMsg.LinkUrl = tempObj.LinkUrl;
this.addMsg.IsTop = tempObj.IsTop;
this.addMsg.SortNum = tempObj.SortNum;
}
} else {
this.Error(res.data.message);
......@@ -134,11 +144,11 @@
null
);
},
//删除分类
removeCategory(Id) {
//删除素材
removeShareFriend(Id) {
let that = this;
that.Confirm("确定要删除分类吗?", function () {
that.apipost("/api/Share/RemoveShareCategory", {
that.apipost("/api/Share/RemoveShareFriend", {
Id: Id
},
res => {
......@@ -154,9 +164,14 @@
},
clearMsg() {
this.addMsg.Id = 0;
this.addMsg.Name = "";
this.addMsg.Level = 1;
this.addMsg.ParentId = 0;
this.addMsg.CateId = 0;
this.addMsg.GoodsId = 0;
this.addMsg.CoverImg = "";
this.addMsg.MaterialImg = "";
this.addMsg.MaterialInfo = "";
this.addMsg.LinkUrl = "";
this.addMsg.IsTop = 1;
this.addMsg.SortNum = 1;
},
},
mounted() {
......
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