123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384 |
- <template name="freight">
- <view class="freight-template">
- <!-- 运费信息 -->
- <view class="invoice-freight">
- <view class="freight-left">
- 运费<text class="iconfont icon-yunfeishuoming" @click="showTip"></text>
- </view>
- <view class="freight-right">
- <text>{{freightText}}</text>
- </view>
- </view>
- </view>
- </template>
- <script>
- export default{
- name:"freight",
- props:{
- freightData:{
- type:Object
- }
- },
- data() {
- return{
- freightText:'',
- }
- },
- created(){
- this.initData(this.freightData)
- },
- computed: {
- },
- methods:{
- initData(res) {
- switch(res.freePostFlag){
- case '0':
- this.freightText = '包邮';break
- case '1':
- this.freightText = res.freePostFlag;break
- case '-1':
- this.freightText = '到付';break
- }
- },
- showTip(){
- this.$emit('showFreightAlert');
- },
- }
- }
- </script>
- <style lang="scss">
- .freight-template{
- width: 100%;
- height: auto;
- background: #FFFFFF;
- float: left;
- margin-top: 24rpx;
- .invoice-freight{
- width: 702rpx;
- padding: 0 24rpx;
- height: 86rpx;
- line-height: 86rpx;
- font-size: $font-size-28;
- color: $text-color;
- background: #FFFFFF;
- float: left;
- font-weight: bold;
- .freight-left{
- float: left;
- .icon-yunfeishuoming{
- height: 100%;
- padding:15rpx;
- color: $color-system;
- font-weight: normal;
- }
- }
- .freight-right{
- float: right;
- color: #2A81FF;
- }
- }
- }
- </style>
|