warning if product/service code import wasn't run, RT#77163, RT#75262
authorIvan Kohler <ivan@freeside.biz>
Wed, 6 Sep 2017 18:20:50 +0000 (11:20 -0700)
committerIvan Kohler <ivan@freeside.biz>
Wed, 6 Sep 2017 18:20:50 +0000 (11:20 -0700)
httemplate/browse/part_pkg_taxproduct/compliance_solutions.html

index bbcb687..b5936da 100644 (file)
@@ -53,6 +53,9 @@ function category_changed(what) {
       jopt( $('#product_code'), '', 'Select product code' );
 
       var part_pkg_taxproduct = reply.part_pkg_taxproduct;
+      if ( part_pkg_taxproduct.length == 0 ) {
+        alert('No compliance solutions product codes found; did you run freeside-compliance_solutions-import?');
+      }
       for ( var s = 0; s < part_pkg_taxproduct.length; s=s+2 ) {
         var product_code = part_pkg_taxproduct[s];
         var description = part_pkg_taxproduct[s+1];