|
@ -79,13 +79,19 @@ if(isset($_GET['id']) && $_GET['id']!=""){ |
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
print_r($buyArr); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
$sql_str = "SELECT file_name FROM contract_apply_files WHERE contract_id = :contract_id AND deleted_at IS NULL"; |
|
|
|
|
|
$stmt = $conn->prepare($sql_str); |
|
|
|
|
|
$stmt->bindParam(':contract_id', $id); |
|
|
|
|
|
$stmt->execute(); |
|
|
|
|
|
$files = $stmt->fetchAll(PDO::FETCH_ASSOC); |
|
|
|
|
|
print_r($files); |
|
|
|
|
|
echo "count=>" . count($files); |
|
|
|
|
|
$files_count = count($files); |
|
|
} |
|
|
} |
|
|
catch (PDOException $e ){ |
|
|
catch (PDOException $e ){ |
|
|
die("ERROR!!!: ". $e->getMessage()); |
|
|
die("ERROR!!!: ". $e->getMessage()); |
|
|
} |
|
|
} |
|
|
echo $buy_total_price; |
|
|
|
|
|
} |
|
|
} |
|
|
?> |
|
|
?> |
|
|
<link rel="stylesheet" href="./styles/style.css"> |
|
|
<link rel="stylesheet" href="./styles/style.css"> |
|
@ -113,7 +119,7 @@ if(isset($_GET['id']) && $_GET['id']!=""){ |
|
|
<input type="number" x-model="buyfill2"> |
|
|
<input type="number" x-model="buyfill2"> |
|
|
</label> --> |
|
|
</label> --> |
|
|
<?php } ?> |
|
|
<?php } ?> |
|
|
<label for=""> |
|
|
<!-- <label for=""> |
|
|
<p>附件數</p> |
|
|
<p>附件數</p> |
|
|
<select x-model="buyAffix"> |
|
|
<select x-model="buyAffix"> |
|
|
<option value="1">1</option> |
|
|
<option value="1">1</option> |
|
@ -122,9 +128,9 @@ if(isset($_GET['id']) && $_GET['id']!=""){ |
|
|
<option value="4">4</option> |
|
|
<option value="4">4</option> |
|
|
<option value="5">5</option> |
|
|
<option value="5">5</option> |
|
|
</select> |
|
|
</select> |
|
|
</label> |
|
|
</label> --> |
|
|
<label for=""> |
|
|
<label for=""> |
|
|
<button @click="sendBuyInputFn()">確認</button> |
|
|
<button @click="sendBuyInputFn()">生成買賣合約書</button> |
|
|
</label> |
|
|
</label> |
|
|
</div> |
|
|
</div> |
|
|
<div class="contract-material-component" x-show="isbuyShow && !isBuyInputIng"> |
|
|
<div class="contract-material-component" x-show="isbuyShow && !isBuyInputIng"> |
|
@ -238,7 +244,7 @@ if(isset($_GET['id']) && $_GET['id']!=""){ |
|
|
<p>免費保養月數(月)</p> |
|
|
<p>免費保養月數(月)</p> |
|
|
<input type="number" x-model="installfill2" @keyup="sendInstallInputKeyupFn($event)" /> |
|
|
<input type="number" x-model="installfill2" @keyup="sendInstallInputKeyupFn($event)" /> |
|
|
</label> --> |
|
|
</label> --> |
|
|
<label for=""> |
|
|
<!-- <label for=""> |
|
|
<p>附件數</p> |
|
|
<p>附件數</p> |
|
|
<select x-model="installAffix" @keyup="sendInstallInputKeyupFn($event)"> |
|
|
<select x-model="installAffix" @keyup="sendInstallInputKeyupFn($event)"> |
|
|
<option value="1">1</option> |
|
|
<option value="1">1</option> |
|
@ -247,9 +253,9 @@ if(isset($_GET['id']) && $_GET['id']!=""){ |
|
|
<option value="4">4</option> |
|
|
<option value="4">4</option> |
|
|
<option value="5">5</option> |
|
|
<option value="5">5</option> |
|
|
</select> |
|
|
</select> |
|
|
</label> |
|
|
</label> --> |
|
|
<label for=""> |
|
|
<label for=""> |
|
|
<button @click="sendInstallInputFn()">確認</button> |
|
|
<button @click="sendInstallInputFn()">生成安裝合約書</button> |
|
|
</label> |
|
|
</label> |
|
|
</div> |
|
|
</div> |
|
|
<div class="contract-install-component" x-show="!isbuyShow && !isInstallInputIng" x-cloak > |
|
|
<div class="contract-install-component" x-show="!isbuyShow && !isInstallInputIng" x-cloak > |
|
@ -348,7 +354,7 @@ if(isset($_GET['id']) && $_GET['id']!=""){ |
|
|
</table> |
|
|
</table> |
|
|
</div> |
|
|
</div> |
|
|
|
|
|
|
|
|
<form action="prviewPdf.php?&<?php echo $token_link; ?>" id="form" method="post" x-ref="form" style="display:none"> |
|
|
<form action="prviewPdf.php?id=<?php echo $id; ?>&<?php echo $token_link; ?>" id="form" method="post" x-ref="form" style="display:none"> |
|
|
<input type="hidden" name="list" id="prview-list" /> |
|
|
<input type="hidden" name="list" id="prview-list" /> |
|
|
<input type="hidden" name="prviewType" id="prview-type" /> |
|
|
<input type="hidden" name="prviewType" id="prview-type" /> |
|
|
<input type="hidden" name="standardList" id="standard-prview-list" /> |
|
|
<input type="hidden" name="standardList" id="standard-prview-list" /> |
|
@ -390,7 +396,8 @@ if(isset($_GET['id']) && $_GET['id']!=""){ |
|
|
const people = <?php echo $noteArr[1]; ?>; |
|
|
const people = <?php echo $noteArr[1]; ?>; |
|
|
const floor = <?php echo $noteArr[2]; ?>; |
|
|
const floor = <?php echo $noteArr[2]; ?>; |
|
|
const speed = <?php echo $noteArr[3]; ?>; |
|
|
const speed = <?php echo $noteArr[3]; ?>; |
|
|
console.log(buyArr); |
|
|
const buyAffix =' <?php echo $files_count; ?>'; |
|
|
|
|
|
console.log(buyAffix); |
|
|
console.log(installArr); |
|
|
console.log(installArr); |
|
|
buyArr.forEach((item, idx) => { |
|
|
buyArr.forEach((item, idx) => { |
|
|
if(item.scale > 0){ |
|
|
if(item.scale > 0){ |
|
|