Commit aaaac4f0 authored by lujunye's avatar lujunye

修复显示bug

parent e6eefa72
......@@ -436,6 +436,7 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
let UserToken = UserDefaults.standard.value(forKey: "user_token")
goodsDetail(["user_token":UserToken,"goods_id":goods_id], success: { (data) in
//MARK: - 获取详情
self.listTbv.isHidden = false
let model = data as! GoodsDetailModel
self.goodsDetailModel = model
//商品名
......@@ -671,7 +672,7 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
navbar.title = "商品详情"
self.view.addSubview(navbar)
SetTopFrameView(view: listTbv, btmView: btmBtnBGView)
listTbv.isHidden = true
loadData()
self.listTbv.separatorStyle = .none
......@@ -689,11 +690,15 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
}
func getResponseArr(str:String)->Array<String>{
let a = str.replacingOccurrences(of: "{", with: "")
let b = a.replacingOccurrences(of: "}", with: "")
let c = b.replacingOccurrences(of: ":", with: "_")
let d = c.replacingOccurrences(of: "\"", with: "")
return d.components(separatedBy: ",")
let dict = getDictionaryFromJSONString(jsonString: str)
var arr:Array<String> = []
for key in dict.allKeys{
let k = key as! String
let str = k + "_" + (dict[k] as! String)
arr.append(str)
}
return arr
}
//MARK: - cell delegate
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
......
......@@ -414,6 +414,7 @@ class CreatNewSpecsViewController: BaseViewController,UITableViewDelegate,UITabl
}
if item != "" {
//MARK:--阶梯价格切割
// print("sjklasd",item)
let arr = item.components(separatedBy: "_")
cell.priceTF.text = arr[0]
cell.countTF.text = arr[1]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment