flat: 合并, 报错修复

This commit is contained in:
Apcallover
2024-04-21 16:38:25 +08:00
parent 1d0ef39fff
commit 3cb42d7be1
4 changed files with 219 additions and 238 deletions

View File

@@ -372,7 +372,7 @@ const addressColumn = [
}, },
{ {
value: '185', value: '185',
label: "绵竹市" label: "广汉市"
}, },
{ {
value: '143', value: '143',

View File

@@ -414,8 +414,7 @@
} }
}, },
cityNamed() { cityNamed() {
console.log('val', this.info, this.area.dic) if (this.info && typeof this.info.cityId !== 'undefined' && this.info.cityId !== -1 && this.area.dic) {
if (this.info && this.info.cityId !== -1 && this.area.dic) {
return this.area.dic[this.info.cityId].label return this.area.dic[this.info.cityId].label
} else { } else {
return '无' return '无'

View File

@@ -1,36 +1,18 @@
<template> <template>
<view <view class="u-icon" @tap="clickHandler" :class="['u-icon--' + labelPos]">
class="u-icon" <image class="u-icon__img" v-if="isImg" :src="name" :mode="imgMode"
@tap="clickHandler" :style="[imgStyle, $u.addStyle(customStyle)]"></image>
:class="['u-icon--' + labelPos]" <text v-else class="u-icon__icon" :class="uClasses" :style="[iconStyle, $u.addStyle(customStyle)]"
> :hover-class="hoverClass">{{icon}}</text>
<image
class="u-icon__img"
v-if="isImg"
:src="name"
:mode="imgMode"
:style="[imgStyle, $u.addStyle(customStyle)]"
></image>
<text
v-else
class="u-icon__icon"
:class="uClasses"
:style="[iconStyle, $u.addStyle(customStyle)]"
:hover-class="hoverClass"
>{{icon}}</text>
<!-- 这里进行空字符串判断如果仅仅是v-if="label"可能会出现传递0的时候结果也无法显示 --> <!-- 这里进行空字符串判断如果仅仅是v-if="label"可能会出现传递0的时候结果也无法显示 -->
<text <text v-if="label !== ''" class="u-icon__label" :style="{
v-if="label !== ''"
class="u-icon__label"
:style="{
color: labelColor, color: labelColor,
fontSize: $u.addUnit(labelSize), fontSize: $u.addUnit(labelSize),
marginLeft: labelPos == 'right' ? $u.addUnit(space) : 0, marginLeft: labelPos == 'right' ? $u.addUnit(space) : 0,
marginTop: labelPos == 'bottom' ? $u.addUnit(space) : 0, marginTop: labelPos == 'bottom' ? $u.addUnit(space) : 0,
marginRight: labelPos == 'left' ? $u.addUnit(space) : 0, marginRight: labelPos == 'left' ? $u.addUnit(space) : 0,
marginBottom: labelPos == 'top' ? $u.addUnit(space) : 0, marginBottom: labelPos == 'top' ? $u.addUnit(space) : 0,
}" }">{{ label }}</text>
>{{ label }}</text>
</view> </view>
</template> </template>
@@ -160,7 +142,7 @@
// 非nvue下加载字体 // 非nvue下加载字体
@font-face { @font-face {
font-family: 'uicon-iconfont'; font-family: 'uicon-iconfont';
src: url('https://at.alicdn.com/t/font_2225171_8kdcwk4po24.ttf') format('truetype'); src: url('/static/font/font_2225171_8kdcwk4po24.ttf') format('truetype');
} }
/* #endif */ /* #endif */

View File

@@ -3,7 +3,7 @@ module.exports = {
port: 1887, port: 1887,
proxy: { proxy: {
'/api': { '/api': {
target: 'http://192.168.1.106:8000', target: 'http://10.165.0.173:8000',
ws: true, ws: true,
pathRewrite: { pathRewrite: {
'^/api': '/' '^/api': '/'