|
@@ -1307,16 +1307,17 @@ class Sale extends Base
|
|
|
|
|
|
} else {
|
|
|
//项目类竞价单
|
|
|
- if ($key == 0) Db::name('standing_book')->where('projectNo', $plan['projectNo'])->where('infoNo', $standing_book_data['infoNo'])->update($standing_book_data);
|
|
|
- else {
|
|
|
- $temp = Db::name('standing_book')->where('projectNo', $plan['projectNo'])->where('infoNo', $standing_book_data['infoNo'])->find();
|
|
|
- if (!empty($temp)) {
|
|
|
- unset($temp['id']);
|
|
|
- $temp = array_merge($temp, $standing_book_data);
|
|
|
- $temp['standBookNo'] = makeNo('IO');
|
|
|
- Db::name('standing_book')->insert($temp);
|
|
|
- }
|
|
|
- }
|
|
|
+ Db::name('standing_book')->where(['projectNo' => $plan['projectNo'], 'infoNo' => $standing_book_data['infoNo']])->update($standing_book_data);
|
|
|
+// if ($key == 0) Db::name('standing_book')->where('projectNo', $plan['projectNo'])->where('infoNo', $standing_book_data['infoNo'])->update($standing_book_data);
|
|
|
+// else {
|
|
|
+// $temp = Db::name('standing_book')->where('projectNo', $plan['projectNo'])->where('infoNo', $standing_book_data['infoNo'])->find();
|
|
|
+// if (!empty($temp)) {
|
|
|
+// unset($temp['id']);
|
|
|
+// $temp = array_merge($temp, $standing_book_data);
|
|
|
+// $temp['standBookNo'] = makeNo('IO');
|
|
|
+// Db::name('standing_book')->insert($temp);
|
|
|
+// }
|
|
|
+// }
|
|
|
}
|
|
|
|
|
|
}
|