Commit 84c36db8 authored by lujunye's avatar lujunye

修复点击修改数量bug

parent a65824ce
...@@ -222,7 +222,6 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab ...@@ -222,7 +222,6 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab
cell.iconImg.sd_setImage(with: URL(string: SERVERCE_ImageHost + model.goods_img!)) cell.iconImg.sd_setImage(with: URL(string: SERVERCE_ImageHost + model.goods_img!))
cell.imgUrlPath = SERVERCE_ImageHost + model.goods_img! cell.imgUrlPath = SERVERCE_ImageHost + model.goods_img!
cell.sku_id = model.sku_id cell.sku_id = model.sku_id
cell.countTF.text = StringByInt(number: model.origin_number!) cell.countTF.text = StringByInt(number: model.origin_number!)
cell.priceTF.text = model.price! cell.priceTF.text = model.price!
model.target_Count = model.origin_number! model.target_Count = model.origin_number!
...@@ -269,13 +268,13 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab ...@@ -269,13 +268,13 @@ class XuanZeShangPinViewController: BaseViewController,UITableViewDelegate,UITab
func XuanZeShangPinCellTextChange(index: IndexPath,sender:XuanZeShangPinCell,senderTF:UITextField) { func XuanZeShangPinCellTextChange(index: IndexPath,sender:XuanZeShangPinCell,senderTF:UITextField) {
print("count === ",selectArr.count)
let model = selectArr[index.row] let model = sender.cellModel
let valueStr = senderTF.text as! NSString let valueStr = senderTF.text as! NSString
if senderTF == sender.priceTF { if senderTF == sender.priceTF {
model.target_Price = formatShowNumber(value: senderTF.text!) model!.target_Price = formatShowNumber(value: senderTF.text!)
}else{ }else{
model.target_Count = valueStr.integerValue model!.target_Count = valueStr.integerValue
} }
} }
......
...@@ -776,6 +776,7 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo ...@@ -776,6 +776,7 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
cell.textTF.delegate = self cell.textTF.delegate = self
cell.textTF.isUserInteractionEnabled = isAllEditing cell.textTF.isUserInteractionEnabled = isAllEditing
cell.textTF.returnKeyType = .done cell.textTF.returnKeyType = .done
switch cell.nameLbl.text { switch cell.nameLbl.text {
case "关键字": case "关键字":
cell.textTF.text = keyWord cell.textTF.text = keyWord
...@@ -788,6 +789,7 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo ...@@ -788,6 +789,7 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
break break
} }
cell.textTF.placeholder = tishixxArr1[indexPath.row] as! String cell.textTF.placeholder = tishixxArr1[indexPath.row] as! String
cell.tag = indexPath.row cell.tag = indexPath.row
cell.delegate = self cell.delegate = self
return cell return cell
...@@ -1480,8 +1482,11 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo ...@@ -1480,8 +1482,11 @@ class EPViewController: BaseViewController,UITableViewDelegate,UITableViewDataSo
} }
} }
func YuShouWeiKuanFaHuoCellString(str: String) { func YuShouWeiKuanFaHuoCellString(str: String) {
faHuoTime = str if isPurnInt(string: str) {
print(faHuoTime) faHuoTime = formatShowNumber(value: str)
}else{
HUD.flash(.label("请输入正确的数据"), delay: 1.2)
}
} }
override func backAction() { override func backAction() {
self.navigationController?.popViewController(animated: true) self.navigationController?.popViewController(animated: true)
......
...@@ -654,7 +654,7 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl ...@@ -654,7 +654,7 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
for asset in assets { for asset in assets {
PHImageManager.default().requestImage(for: asset, targetSize: PHImageManagerMaximumSize , contentMode: .default , options: option, resultHandler: { (image, _: [AnyHashable : Any]?) in PHImageManager.default().requestImage(for: asset, targetSize: PHImageManagerMaximumSize , contentMode: .default , options: option, resultHandler: { (image, _: [AnyHashable : Any]?) in
// print("上传图片==\(image)") // print("上传图片==\(image)")
self.uploadImg(imge: image!, isOriginal: true, tag: 0) self.uploadImg(imge: image!, isOriginal: true, tag: 0)
}) })
...@@ -1096,8 +1096,11 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl ...@@ -1096,8 +1096,11 @@ class ProductDetailViewController: BaseViewController,UITableViewDelegate,UITabl
} }
} }
func YuShouWeiKuanFaHuoCellString(str: String) { func YuShouWeiKuanFaHuoCellString(str: String) {
faHuoTime = str if isPurnInt(string: str) {
print(faHuoTime) faHuoTime = formatShowNumber(value: str)
}else{
HUD.flash(.label("请输入正确的数据"), delay: 1.2)
}
} }
override func backAction() { override func backAction() {
self.navigationController?.popViewController(animated: true) self.navigationController?.popViewController(animated: true)
......
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