xowiki::jqueryui_touchpunch::resource_info (private)

 xowiki::jqueryui_touchpunch::resource_info [ -version version ]

Defined in packages/xowiki/tcl/resource-info-procs.tcl

Get information about available version(s) of jqueryui-touch-punch either from the local filesystem, or from CDN.

Switches:
-version (optional)

Partial Call Graph (max 5 caller/called nodes):
%3 packages/xowiki/www/sitewide-admin/index.tcl packages/xowiki/ www/sitewide-admin/index.tcl xowiki::jqueryui_touchpunch::resource_info xowiki::jqueryui_touchpunch::resource_info packages/xowiki/www/sitewide-admin/index.tcl->xowiki::jqueryui_touchpunch::resource_info acs_package_root_dir acs_package_root_dir (public) xowiki::jqueryui_touchpunch::resource_info->acs_package_root_dir parameter::get_global_value parameter::get_global_value (public) xowiki::jqueryui_touchpunch::resource_info->parameter::get_global_value

Testcases:
No testcase defined.
Source code:
    set parameter_info {
        package_key xowiki
        parameter_name JqueryuiTouchPunchVersion
        default_value 0.2.3
    }

    if {$version eq ""} {
      dict with parameter_info {
        set version [::parameter::get_global_value  -package_key $package_key  -parameter $parameter_name  -default $default_value]
      }
    }
    #
    # Setup variables for access via CDN vs. local resources.
    #
    set resourceDir [acs_package_root_dir xowiki/www/resources/jqueryui-touch-punch]
    set cdn         //cdnjs.cloudflare.com/ajax/libs/jqueryui-touch-punch

    set path $resourceDir/$version/jqueryui-touch-punch.min.js
    ns_log notice "jqueryui-touch-punch: check $path ->" [file exists $path]

    if {[file exists $path]} {
      set prefix  /resources/xowiki/jqueryui-touch-punch/$version
      set cdnHost ""
      set cspMap ""
    } else {
      set prefix $cdn/$version
      set cdnHost cdnjs.cloudflare.com
      dict set cspMap urn:ad:js:jqueryui-touch-punch script-src $cdnHost
    }

    #
    # Return the dict with at least the required fields
    #
    lappend result  resourceName "jqueryui-touch-punch"  resourceDir $resourceDir  cdn $cdn  cdnHost $cdnHost  prefix $prefix  cssFiles {}  jsFiles  {jqueryui-touch-punch.min.js}  extraFiles {}  cspMap $cspMap  urnMap {
          urn:ad:js:jquery-ui-touch-punch jqueryui-touch-punch.min.js
        }  versionCheckAPI {cdn cdnjs library jqueryui-touch-punch count 1}  vulnerabilityCheck {service snyk library jquery-ui-touch-punch}  parameterInfo $parameter_info  configuredVersion $version

    return $result
XQL Not present:
Generic, PostgreSQL, Oracle
[ hide source ] | [ make this the default ]
Show another procedure: