From ad0a81a53a4d23311659f92e531b52ad358feeec Mon Sep 17 00:00:00 2001 From: Burak Civan Date: Tue, 6 Dec 2022 10:10:22 +0300 Subject: [PATCH 1/4] css compiled --- public/css/app.css | 4 ---- 1 file changed, 4 deletions(-) diff --git a/public/css/app.css b/public/css/app.css index 33820d6f1..8e634b6c0 100644 --- a/public/css/app.css +++ b/public/css/app.css @@ -56327,10 +56327,6 @@ body{ right: -2rem; } -[dir="rtl"] .rtl\:float-left{ - float: left; -} - [dir="rtl"] .rtl\:m-0{ margin: 0px; } From 7e83aefa374c712354e4ed6ee98364e068c5dceb Mon Sep 17 00:00:00 2001 From: Burak Civan Date: Tue, 6 Dec 2022 13:58:50 +0300 Subject: [PATCH 2/4] console error fixed --- resources/assets/js/views/common/documents.js | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/resources/assets/js/views/common/documents.js b/resources/assets/js/views/common/documents.js index f94c05ba1..bf0f3452c 100644 --- a/resources/assets/js/views/common/documents.js +++ b/resources/assets/js/views/common/documents.js @@ -811,15 +811,20 @@ const app = new Vue({ watch: { 'form.discount': function (newVal, oldVal) { - if (newVal != '' && newVal.search('^(?=.*?[0-9])[0-9.,]+$') !== 0) { + if (newVal > 99) { + newVal = oldVal; + return; + } + + if (newVal != '' && newVal.search('^[-+]?([0-9]|[1-9][0-9]|100)*\.?[0-9]+$') !== 0) { this.form.discount = oldVal; - this.form.discount = this.form.discount.replace(',', '.'); + this.form.discount = this.form.discount ? this.form.discount.replace(',', '.') : ''; return; } for (let item of this.regex_condition) { - if (this.form.discount.includes(item)) { + if (this.form.discount && this.form.discount.includes(item)) { const removeLastChar = newVal.length - 1; const inputShown = newVal.slice(0, removeLastChar); @@ -827,7 +832,7 @@ const app = new Vue({ } } - this.form.discount = this.form.discount.replace(',', '.'); + this.form.discount = this.form.discount ? this.form.discount.replace(',', '.') : ''; }, 'form.loading': function (newVal, oldVal) { From 9885709f897246f9b8e5fb48f4576a9adf22006b Mon Sep 17 00:00:00 2001 From: Burak Civan Date: Tue, 6 Dec 2022 15:36:06 +0300 Subject: [PATCH 3/4] console error fixed --- resources/assets/js/views/common/documents.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/resources/assets/js/views/common/documents.js b/resources/assets/js/views/common/documents.js index bf0f3452c..cb77d4739 100644 --- a/resources/assets/js/views/common/documents.js +++ b/resources/assets/js/views/common/documents.js @@ -114,7 +114,10 @@ const app = new Vue({ onRefFocus(ref) { let index = this.form.items.length - 1; - this.$refs['items-' + index + '-' + ref][0].focus(); + if (this.$refs['items-' + index + '-' + ref] != undefined) { + let first_ref = this.$refs['items-' + index + '-' + ref]; + first_ref != undefined ? first_ref[0].focus() : this.$refs[Object.keys(this.$refs)[0]][0].focus(); + } }, onCalculateTotal() { From 9be53b46a22f8354830c977a69037c1b75fa3464 Mon Sep 17 00:00:00 2001 From: Burak Civan Date: Tue, 6 Dec 2022 17:23:19 +0300 Subject: [PATCH 4/4] added class for collapse-sub --- public/css/app.css | 1 + resources/assets/sass/app.css | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/public/css/app.css b/public/css/app.css index 8e634b6c0..0f477b5a2 100644 --- a/public/css/app.css +++ b/public/css/app.css @@ -54051,6 +54051,7 @@ html[dir='rtl'] .el-scrollbar__wrap { } .collapse-sub{ + display: block; height: 0px; overflow: hidden; opacity: 0; diff --git a/resources/assets/sass/app.css b/resources/assets/sass/app.css index ca2906ef9..4a8f6dd02 100644 --- a/resources/assets/sass/app.css +++ b/resources/assets/sass/app.css @@ -561,7 +561,7 @@ html[dir='rtl'] .el-scrollbar__wrap { } .collapse-sub { - @apply opacity-0 h-0 overflow-hidden; + @apply block opacity-0 h-0 overflow-hidden; } .collapse-sub-report.collapse-sub {