Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/javascript/398.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript 计算列上的CAMLQuery返回十进制而不是百分比。如何更改为百分比?_Javascript_Jquery_Sharepoint 2013_Spservices - Fatal编程技术网

Javascript 计算列上的CAMLQuery返回十进制而不是百分比。如何更改为百分比?

Javascript 计算列上的CAMLQuery返回十进制而不是百分比。如何更改为百分比?,javascript,jquery,sharepoint-2013,spservices,Javascript,Jquery,Sharepoint 2013,Spservices,我使用SPServices查询SharePoint 2013列表,并跨5列返回值。其中一列设置为以百分比显示,但返回值时,它是十进制格式。我如何将其改为百分比 以下是显示返回值的代码段: var PercentComplete = $(this).attr("ows_Overall_QA_Percent_Complete").substring(7); 由于以下是您的全部想法,我将将其作为答案发布,以便您可以接受/关闭此问题: var PercentComplete=parseFloat($(

我使用SPServices查询SharePoint 2013列表,并跨5列返回值。其中一列设置为以百分比显示,但返回值时,它是十进制格式。我如何将其改为百分比

以下是显示返回值的代码段:

var PercentComplete = $(this).attr("ows_Overall_QA_Percent_Complete").substring(7);

由于以下是您的全部想法,我将将其作为答案发布,以便您可以接受/关闭此问题:


var PercentComplete=parseFloat($(this).attr(“ows_-totall_-QA_-Percent_-Complete”).substring(7,10)*100
var PercentComplete=parseFloat($(this).attr(“ows_-totall_-QA_-Percent_-Complete”).substring(7,10)*100
!谢谢