张延森 3 лет назад
Родитель
Сommit
0b026a132e
3 измененных файлов: 7 добавлений и 72 удалений
  1. 2
    2
      config/dev.js
  2. 1
    1
      config/prod.js
  3. 4
    69
      src/pages/index/encyclopediasOfBuyHouse/index.jsx

+ 2
- 2
config/dev.js Просмотреть файл

@@ -3,8 +3,8 @@ module.exports = {
3 3
     NODE_ENV: '"development"'
4 4
   },
5 5
   defineConstants: {
6
-    HOST: '"https://xlj.newlandsh.com"',
7
-    // HOST: '"http://127.0.0.1:8081"',
6
+    // HOST: '"https://xlj.newlandsh.com"',
7
+    HOST: '"http://127.0.0.1:8081"',
8 8
     WSS_HOST: '"wss://xlk.njyz.tech"',
9 9
     OSS_PATH: '"https://xlk-assets.oss-accelerate.aliyuncs.com/"',
10 10
     OSS_FAST_PATH: '"https://xlk-assets.oss-accelerate.aliyuncs.com/"',

+ 1
- 1
config/prod.js Просмотреть файл

@@ -10,7 +10,7 @@ module.exports = {
10 10
     OSS_PATH: '"https://xlk-assets.oss-accelerate.aliyuncs.com/"',
11 11
     OSS_FAST_PATH: '"https://xlk-assets.oss-accelerate.aliyuncs.com/"',
12 12
     ICON_FONT: '"https://yz-websit.oss-cn-hangzhou.aliyuncs.com/xlk/css/iconfont.ttf"',
13
-    Version: '"V0.0.32-20210809"'
13
+    Version: '"V0.0.33-20210809"'
14 14
   },
15 15
   mini: {},
16 16
   h5: {

+ 4
- 69
src/pages/index/encyclopediasOfBuyHouse/index.jsx Просмотреть файл

@@ -61,80 +61,15 @@ const EncyItem = (props) => {
61 61
 };
62 62
 
63 63
 export default withLayout((props) => {
64
-  // const [PageProps] = useState(props)
64
+  const { city } = props;
65 65
 
66
-  const [PageList, setPageList] = useState([
67
-    {
68
-      name: "准备买房",
69
-      icon: require("@/assets/ency-icon3.png"),
70
-      list: [
71
-        {
72
-          name: "买房资质查询",
73
-          id: 1,
74
-          tips: "HOT",
75
-          tipsColor: "#FF0000",
76
-          icon: "",
77
-        },
78
-        {
79
-          name: "22个房产名词",
80
-          id: 2,
81
-          tips: "NEW",
82
-          tipsColor: "#30CFCF",
83
-          icon: "",
84
-        },
85
-      ],
86
-    },
87
-    {
88
-      name: "看房选房",
89
-      icon: require("@/assets/ency-icon4.png"),
90
-      list: [
91
-        { name: "热门楼盘地图", id: 3, tips: "", icon: "" },
92
-        {
93
-          name: "选户型攻略",
94
-          id: 4,
95
-          tips: "实用",
96
-          tipsColor: "#62D547",
97
-          icon: "",
98
-        },
99
-        { name: "期房新房怎么选", id: 5, tips: "", icon: "" },
100
-      ],
101
-    },
102
-    {
103
-      name: "认筹签约",
104
-      icon: require("@/assets/ency-icon5.png"),
105
-      list: [
106
-        {
107
-          name: "买房签约流程",
108
-          id: 6,
109
-          tips: "哇!",
110
-          tipsColor: "#FF396C",
111
-          icon: require("@/assets/ency-icon2.png"),
112
-        },
113
-        { name: "契税征收标准", id: 7, tips: "", icon: "" },
114
-        { name: "公司名义买房", id: 8, tips: "", icon: "" },
115
-      ],
116
-    },
117
-    {
118
-      name: "贷款买房",
119
-      icon: require("@/assets/ency-icon6.png"),
120
-      list: [
121
-        { name: "新房贷政策", id: 9, tips: "", icon: "" },
122
-        {
123
-          name: "贷款查征信",
124
-          id: 10,
125
-          tips: "",
126
-          icon: require("@/assets/ency-icon1.png"),
127
-        },
128
-      ],
129
-    },
130
-  ]);
66
+  const [PageList, setPageList] = useState([]);
131 67
 
132 68
   const getPageList = () => {
133 69
     queryPolicyTypeList({ pageSize: 100 }).then((res) => {
134
-      setPageList(res.records);
70
+      setPageList(res.records||[]);
135 71
     });
136 72
   };
137
-  // GET /api/{plat}/taPolicyType
138 73
 
139 74
   useEffect(() => {
140 75
     getPageList();
@@ -148,7 +83,7 @@ export default withLayout((props) => {
148 83
       >
149 84
         <view className="PageContent">
150 85
           {PageList.map((item, index) => (
151
-            <EncyItem item={item} key={index} index={index}></EncyItem>
86
+            <EncyItem city={city} item={item} key={index} index={index}></EncyItem>
152 87
           ))}
153 88
         </view>
154 89
       </ScrollView>