diff --git a/wms/contract-repair/contract-renovate-input.php b/wms/contract-repair/contract-renovate-input.php
new file mode 100644
index 00000000..d688cc8d
--- /dev/null
+++ b/wms/contract-repair/contract-renovate-input.php
@@ -0,0 +1,268 @@
+prepare($sql);
+// $stmt->bindParam(':depart_no', $depart_no);
+$stmt->execute();
+$contractSalesman = $stmt->fetchAll(PDO::FETCH_ASSOC);
+// echo '
';
+// print_r($contractSalesman);
+// echo '
';
+?>
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/wms/contract-repair/js/alpine.js b/wms/contract-repair/js/alpine.js
index 99291141..3bfae87d 100644
--- a/wms/contract-repair/js/alpine.js
+++ b/wms/contract-repair/js/alpine.js
@@ -1000,33 +1000,45 @@ const bonunsIndexTest = () => {
}
}
-{/* = $data['contract_no'] ?> */ }
-// const bonusIndex = () => {
-// return {
-// init() {
-// window.onload = () => {
-// this.isPay();
-// }
-// },
-// initbtn: null,
-// data: {
-// isPay: []
-// },
-// isPays: [],
-// step: 1,
-// async isPay() {
-// // console.log(this.data)
-// for (let i = 0; i < datas.length; i++) {
-// await axios.get('./api/get.php?contract_no=' + datas[i].contract_no).then(res => {
-// let isPay = res.data;
-// this.isPays.push(isPay);
-// }).catch(err => {
-// })
-// }
+const renovateInput = () => {
+ return {
+ data: {
+ contract_no: '',
+ customer: '',
+ salesman: '',
+ address: '',
+ paykind: [],
+ payarr: [1, 2, 6, 12],
+ },
+ step: 1,
+ isLoading: false,
+ nextStepFn() {
+ if (this.step == 1) {
+ if (this.data.contract_no == '') return alert('請輸入合約號');
+ this.isLoading = true;
+ this.getContractData();
+ } else if (this.step == 2) {
+ console.log('1111');
+ }
+ // this.step = 3;
+ },
+ nextStepKeyupFn() {
+
+ },
+ preStepFn() {
+ this.step -= 1;
+ console.log(this.step);
+ },
+ save() {
-// console.log(this.isPays);
+ },
+ getContractData() {
+ this.step = 2;
+ this.isLoading = false;
+ console.log(this.step);
-// }
-// }
-// }
\ No newline at end of file
+ }
+
+ }
+}
\ No newline at end of file
diff --git a/wms/mkt/pricereview_mi-api.php b/wms/mkt/pricereview_mi-api.php
index 495eab2a..183731b7 100644
--- a/wms/mkt/pricereview_mi-api.php
+++ b/wms/mkt/pricereview_mi-api.php
@@ -219,6 +219,7 @@ try {
$floor = $v['floors'];
$speed = $v['speed'];
$min_weight = $v['item_weight'];
+
$sql_str = "SELECT elevator_mi_option.*,elevator_quotation_rule.* FROM elevator_mi_option
JOIN elevator_quotation_rule ON elevator_mi_option.quotation_no = elevator_quotation_rule.quotation_no
WHERE elevator_mi_option.elevator_type = :elevator_type AND
@@ -255,7 +256,9 @@ try {
// 設備
$equipment_ntd = round(($part1 + $profit) * $row_e["equipment"], 0);
// 報關+運輸
- $customs = round($equipment_ntd * $row_e["shipping"], 0) + $row_e["customs_shipping"];
+ // $customs = round($equipment_ntd * $row_e["shipping"], 0) + $row_e["customs_shipping"];
+ $customs = round($equipment_ntd * $row_e["shipping"], 0);
+
// 安裝基價
$install_base = $row_e["install_price"] + $row_e["trial_price"] + $row_e["install_coef"] * $row_e["install_plus"] + $row_e["trial_coef"] * $row_e["trial_plus"];
// 安裝成本
@@ -336,7 +339,7 @@ try {
AND option_mi.open_kind = '" . $v["item_op"] . "'";
$res_om = mysqli_query($link, $sql4);
-
+
if ($row_om = mysqli_fetch_assoc($res_om)) {
$row_om['price'] = (int)ceil($row_om['price']);
$plus = ($v["floors"] > $row_om["base_floor"]) ? ($v["floors"] - $row_om["base_floor"]) * $row_om["base_floor_plus"] : 0;
@@ -488,13 +491,9 @@ try {
}
}
// $rarr["content"][] = $exceptArr;
-<<<<<<< HEAD
+ // print_r($rarr["content"]);
+ // exit;
foreach ($rarr["content"] as $idx => &$item) {
-=======
- print_r($rarr["content"]);
- exit;
- foreach($rarr["content"] as $idx=>&$item){
->>>>>>> ea503fbee65cc2bb5ce9442e618db9c6878a09cb
$newTotal = 0;
$item[16] = [];
$item[14] = [];