import Magix from 'magix' import * as View from '../../../view' Magix.applyStyle('@./create-types.less') export default View.extend({ tmpl: '@create-types.html', init (options) { this.options = options }, render () { const { user } = this.updater.get() const createTypes = [] const { permissions } = user if (permissions.includes('DMP_MENU_CROWD_INSIGHT_ANALYSIS')) { createTypes.push({ index: 1, title: '人群画像分析', img: 'https://img.alicdn.com/tfs/TB18wTgm639YK4jSZPcXXXrUFXa-380-380.png', desc: '基于受众、品类、渠道、私域特征自定义人群画像洞察,实现消费者立体刻画。', path: '#!/insight-new/perspective' }) } if (permissions.includes('DMP_FUNCTION_SCENARIO_CLUSTER')) { createTypes.push({ index: 2, title: '单品洞察圈人', img: 'https://img.alicdn.com/tfs/TB1phAlhSslXu8jSZFuXXXg7FXa-380-380.png', desc: '针对单品历史人群智能洞察聚类,挖掘显著特征,支持多维度扩展拉新人群!', path: '#!/crowds-new/scenes/overview', mark: 'NEW' }) } if (permissions.includes('DMP_FUNCTION_LIVE')) { createTypes.push({ index: 4, title: '直播洞察圈人', img: 'https://img.alicdn.com/tfs/TB1AqCTVvb2gK0jSZK9XXaEgFXa-380-380.png', desc: '洞察公私域直播人群显著特征,沉淀直播行为人群,支持多维度扩展拉新,挖掘直播拉新人群。', path: '#!/crowds-new/scenes/zhibo/shop-analyse?isAutoJump=1' // mark: 'NEW' }) } // if (permissions.includes('DMP_MENU_CROWD_VALUE_ANALYSIS')) { // createTypes.push({ // title: '人群价值分析', // img: 'https://img.alicdn.com/tfs/TB15KCHHbj1gK0jSZFuXXcrHpXa-220-180.png', // desc: '对人群的粉丝/超级用户/潜客老客层级进行分析,评估店铺经营和内容互动价值。', // path: '#!/insight-new/crowd-value' // }) // } // if (permissions.includes('DMP_MENU_MARKET_CHANCE_YUNTU')) { // createTypes.push({ // title: '市场机会云图', // img: 'https://img.alicdn.com/tfs/TB1.u1DHkY2gK0jSZFgXXc5OFXa-220-180.png', // desc: '基于营销场景/商品属性/风格偏好/触点偏好提供市场趋势分析,助力营销决策。', // path: '#!/insight-new/marketing' // }) // } if (permissions.includes('DMP_FUNCTION_SHOP_SCENARIO')) { createTypes.push({ index: 3, title: '超级用户洞察圈人', img: 'https://img.alicdn.com/tfs/TB1sMC0VAL0gK0jSZFAXXcA9pXa-380-380.png', desc: '基于店铺老客挖掘高活跃/高价值/高传播力的超级用户,支持多维度拓展超级新用户!', path: '#!/crowds-new/super-new/old-customer-analysis' }) } if (permissions.includes('DMP_FUNCTION_CHANNEL_STRATEGY_ANALYSIS')) { createTypes.push({ index: 5, title: '营销渠道策略洞察', img: 'https://img.alicdn.com/imgextra/i4/O1CN01zYC49728SuGwdJ72d_!!6000000007932-2-tps-380-380.png', desc: '全面沉淀阿里妈妈各广告营销渠道人群资产和流转漏斗,支持洞察分析、再营销投放。', path: '#!/insight-new/channel-strategy/index', mark: 'NEW' }) } this.updater.digest({ createTypes }) }, 'sceneCrowd' (e) { const viewPath = '@./scenes/scene-crowd-types' const viewOptions = {} const dialogOptions = { width: 740, header: { title: '选择营销场景' }, footer: { enter: false, cancel: false } } this.mxModal(viewPath, viewOptions, dialogOptions) }, 'customCrowd' (e) { Magix.Router.to('/crowds-new/create') } })