html代碼:{{ it.priceType == 5 ? "元" : (it.priceType | priceText) }}下面是過濾器:Vue.filter('priceText', function(l){ l = parseFloat(l) || 0; var o = ["錢", "元", "小", "中", "大", "元"]; return o[l];});使用這個(gè)就返回空了是不是我寫的方式有問題呢?
vue 不能使用復(fù)雜的三元表達(dá)式嗎?
不負(fù)相思意
2018-12-27 14:15:00