ofbiz-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [ofbiz-framework] verma-pawan commented on a change in pull request #14: Implemented: Added new inventory cycle count feature for warehouse.
Date Fri, 01 May 2020 13:04:07 GMT

verma-pawan commented on a change in pull request #14:
URL: https://github.com/apache/ofbiz-framework/pull/14#discussion_r418531989



##########
File path: applications/product/template/cyclecount/ReviewCountSession.ftl
##########
@@ -0,0 +1,188 @@
+<#--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements.  See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership.  The ASF licenses this file
+to you under the Apache License, Version 2.0 (the
+"License"); you may not use this file except in compliance
+with the License.  You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing,
+software distributed under the License is distributed on an
+"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+KIND, either express or implied.  See the License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<script type="text/javascript">
+    function rejectCountSession(){
+        var checkboxes = document.getElementsByClassName("rowSubmit");
+        var checkCondition = true;
+        for (var i=0; i<checkboxes.length; i++) {
+            if (checkboxes[i].checked) {
+                checkCondition = false;
+            }
+        }
+        if (checkCondition) {
+            alert("Please select row to proceed");
+            return false;
+        }
+        var retVal = confirm('Are you sure want to reject?');
+        if (retVal == null || retVal == "") {
+            return false;
+        } else {
+            document.getElementById("statusId").value = "INV_COUNT_REJECTED";
+            return true;
+        }
+    }
+    function getValue(){
+        var form = document.selectAllForm;
+        var checkboxes = document.getElementsByClassName("rowSubmit");
+        var checkCondition = true;
+        for (var i=0; i<checkboxes.length; i++) {
+            if (checkboxes[i].checked) {
+                checkCondition = false;
+            }
+        }
+        if (checkCondition) {
+            alert("Please select row to proceed");
+            return false;
+        }
+        var retVal = prompt("Schedule Next Cycle Count in (Days)", "60");
+        if (retVal == null || retVal == "") {
+            return false;
+        } else {
+            document.getElementById("nextCountDay").value = retVal;
+            return true;
+        }
+    }
+    function toggleInventoryCountList() {
+        var form = document.selectAllForm;
+        var inventoryCounts = form.elements.length;
+        var isAllSelected = true;
+        for (var i = 0; i < inventoryCounts; i++) {
+            var element = form.elements[i];
+            if ("bulkAction" == element.id && !element.checked)
+                isAllSelected = false;
+        }
+        jQuery('#selectAll').attr("checked", isAllSelected);
+    }
+    function toggleInventoryCount(master) {
+        var form = document.selectAllForm;
+        var inventoryCounts = form.elements.length;
+        for (var i = 0; i < inventoryCounts; i++) {
+            var element = form.elements[i];
+            if ("bulkAction" == element.id) {
+                element.checked = master.checked;
+            }
+        }
+    }
+</script>
+<#if countSessionValue?has_content>

Review comment:
       Needs formatting here also




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



Mime
View raw message