123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124 |
- // 机构通知消息
- const noticeMixins = {
- data() {
- },
- filters: {
- noticeUsersFilters(value) { // 账户通知状态
- const map = {
- 1: '账号审核通知',
- 2: '成为公司运营人员通知',
- 3: '商品上架审核通知',
- 4: '新品展示审核通知',
- 5: '商品资质到期通知'
- }
- return map[value]
- },
- noticeServeFilters(value) { // 账户通知状态
- const map = {
- 1: '上架费到期通知'
- }
- return map[value]
- }
- },
- methods: {
- getUserAuthShopMessageList() {
- this.ShopService.getUserAuthShopMessageList(this.listQuery)
- .then(response => {
- let data = response.data
- this.hasNextPage = response.data.hasNextPage
- if (data.list && data.list.length > 0) {
- this.isEmpty = false
- this.list = [...data.list]
- this.pullFlag = false
- setTimeout(() => {
- this.pullFlag = true
- }, 500)
- if (this.hasNextPage) {
- this.pullUpOn = false
- this.nomoreText = '上拉显示更多'
- } else {
- if (this.list.length < 3) {
- this.pullUpOn = true
- this.loadding = false
- } else {
- this.pullUpOn = false
- this.loadding = false
- this.nomoreText = '到底了'
- }
- }
- } else {
- this.isEmpty = true
- }
- this.skeletonShow = false
- })
- .catch(error => {
- this.$util.msg(error.msg, 2000)
- })
- },
- getReachBottomData(index) {
- //上拉加载
- this.listQuery.pageNum += 1
- this.ShopService.getUserAuthShopMessageList(this.listQuery)
- .then(response => {
- let data = response.data
- if (data.list && data.list.length > 0) {
- this.hasNextPage = data.hasNextPage
- this.list = this.list.concat(data.list)
- this.pullFlag = false // 防上拉暴滑
- setTimeout(() => {
- this.pullFlag = true
- }, 500)
- if (this.hasNextPage) {
- this.pullUpOn = false
- this.nomoreText = '上拉显示更多'
- } else {
- this.pullUpOn = false
- this.loadding = false
- this.nomoreText = '已至底部'
- }
- }
- })
- .catch(error => {
- this.$util.msg(error.msg, 2000)
- })
- },
- deleteBtn(id, index) {
- // 删除通知消息
- this.UserService.authDeleteMessage({ id: id })
- .then(response => {
- let _this = this
- uni.vibrateShort({
- success: function() {
- _this.list.splice(index, 1)
- }
- })
- })
- .catch(error => {
- console.log('error=>', error.msg)
- })
- },
- noticeUsersText(cell) { // 账户通知文案
- const map = {
- 1: '您的注册信息已审核通过,恭喜您成为采美平台供应商用户。您可以上架商品到采美商城进行出售了',
- 2: `恭喜您(微信昵称:${cell.content})成功成为【${cell.shopName}】的运营人员。`,
- 3: '该商品上架审核未通过,暂时不能上架采美商城。请登录采美网站修改商品资料重新提交。',
- 4: '该商品新品展示审核未通过,未能展示在采美商城新品橱窗。',
- 5: `该商品的资质证书将于${cell.content}后失效,请及时登录采美网站上传新证书。` ,
- 6: `恭喜您发布的采美百科词条“${cell.content}”审核已通过。`,
- 7: `很遗憾!您发布的采美百科词条“${cell.content}”审核未通过,原因是“${cell.reasonContent}”,可前往电脑端“我的词条”进行修改后,重新提交审核。`,
- 8: `恭喜您发布的采美文章“${cell.content}”审核已通过。`,
- 9: `很遗憾!您发布的采美文章“${cell.content}”审核未通过,原因是“${cell.reasonContent}”,可前往电脑端“文章管理”进行修改后,重新提交审核。`
- }
- return map[cell.shopMessType]
- },
- noticeServeText(cell) { // 服务通知文案
- const map = {
- 1: `您的供应商账号上架费将于${cell.content},到期后将无法发布和编辑商品,同时也会影响到其他采美提供的支持服务。请联系采美工作人员进行续费,联系电话0755-22907771 或15338851365`
- }
- return map[cell.shopTieredType]
- }
- }
- }
- export default noticeMixins
|