{"id":723,"date":"2022-01-15T14:59:44","date_gmt":"2022-01-15T06:59:44","guid":{"rendered":"http:\/\/zhuxinyong.com\/?p=723"},"modified":"2022-01-15T23:43:23","modified_gmt":"2022-01-15T15:43:23","slug":"shan-chu-qian-tao-shu-zu-xia-de-zhi-ding-yuan-su","status":"publish","type":"post","link":"https:\/\/zhuxinyong.com\/?p=723","title":{"rendered":"\u5220\u9664\u5d4c\u5957\u6570\u7ec4\u4e0b\u7684\u6307\u5b9a\u5143\u7d20"},"content":{"rendered":"<p>\u4e1a\u52a1\u573a\u666f\uff1a<\/p>\n<p><img decoding=\"async\" src=\"http:\/\/zhuxinyong.com\/wp-content\/uploads\/2022\/01\/16422379936950.jpg\" alt=\"\" \/><\/p>\n<p>\u9700\u6c42\uff1a<br \/>\n<strong>reasons \u90a3\u5c42\u6570\u636e\u53ef\u4ee5\u5220\u9664\uff0c\u540c\u65f6 measures \u90a3\u5c42\u6570\u636e\u4e5f\u53ef\u662f\u5220\u9664\u3002<\/strong><\/p>\n<p>\u5b9e\u73b0\uff1a<br \/>\nreasons \u90a3\u5c42\u5220\u9664\u5f88\u5bb9\u6613\u60f3\u5230\uff0c\u5c31\u6839\u636e reason \u7684 id \u904d\u5386\u5339\u914d\u3002\u5229\u7528\u6570\u7ec4\u7684 filter \u65b9\u6cd5\uff1a<\/p>\n<pre><code class=\"language-plain_text\">let reasons = [...]\nfunction delReason(targetReason){\n    reasons = reasons.filter((item)=&gt;{\n        \/\/ \u628a\u6ca1\u7528\u5339\u914d\u7684\u8fd4\u56de\uff0c\u7ec4\u88c5\u6210\u65b0\u6570\u7ec4\u3002\n        return item.id != targetReason.id\n    })\n    return reasons\n}\n<\/code><\/pre>\n<p><strong>\u5220\u9664\u67d0\u4e2a reason \u4e0b\u6307\u5b9a\u7684 measure\u3002<\/strong><\/p>\n<pre><code class=\"language-plain_text\">let reasons = [...]\n\nfunction delMeasure(targetMeasure){\n    reasons = reasons.map((item)=&gt;{\n        item.measures = item.measures.filter((measureItem)=&gt; measureItem.id != targetMeasure.id)\n        return item\n    })\n    return reasons\n}\n<\/code><\/pre>\n<p>\u6d4b\u8bd5\u6570\u636e\uff1a<\/p>\n<pre><code class=\"language-plain_text\">    &quot;reasons&quot;: [\n        {\n            &quot;tenantId&quot;: &quot;1268024398774177794&quot;,\n            &quot;createTime&quot;: 1642044516649,\n            &quot;updateTime&quot;: 1642161992240,\n            &quot;updateUser&quot;: &quot;1437627170697543683&quot;,\n            &quot;id&quot;: &quot;1481468194816217090&quot;,\n            &quot;gapId&quot;: &quot;1481468194614890498&quot;,\n            &quot;reasonNo&quot;: &quot;BHDB00007&quot;,\n            &quot;reasonContent&quot;: &quot;\u67d0\u65e5\u67d0\u65f6\uff1f#VCM\u538b\u7f29\u673a\u8ba1\u5212\u68c0\u4fee\uff0c\u5269\u4f596\u53f0\u538b\u7f29\u673a\u6ee1\u8d1f\u8377\u8fd0\u884c\uff0c\u4e59\u7094\u901a\u91cf\u8c03\u6574\u81f319000m3\/h,\u5355\u4f53\u51cf\u4ea710\u5428\u3002&quot;,\n            &quot;rate&quot;: 99,\n            &quot;isDel&quot;: 0,\n            &quot;measures&quot;: [\n                {\n                    &quot;tenantId&quot;: &quot;1268024398774177794&quot;,\n                    &quot;createTime&quot;: 1642161992246,\n                    &quot;updateTime&quot;: 1642161992246,\n                    &quot;updateUser&quot;: &quot;1437627170697543683&quot;,\n                    &quot;id&quot;: &quot;1481960923185614849&quot;,\n                    &quot;gapReasonId&quot;: &quot;1481468194816217090&quot;,\n                    &quot;measureContent&quot;: &quot;\u8ba1\u5212\u68c0\u4fee\uff0c\u8d23\u4efb\u4eba\uff1aXXX\uff1b\u5b8c\u6210\u65f6\u95f4\uff1aX\u6708X\u65e5\u3002&quot;,\n                    &quot;personId&quot;: &quot;1322069368578351150&quot;,\n                    &quot;personName&quot;: &quot;\u8339\u4f1f&quot;,\n                    &quot;joinPerson&quot;: &quot;[{\\&quot;userId\\&quot;:\\&quot;1322069414707306499\\&quot;,\\&quot;username\\&quot;:\\&quot;\u738b\u5728\u6e05(wangzq12)\\&quot;}]&quot;,\n                    &quot;joinPersonName&quot;: &quot;\u738b\u5728\u6e05(wangzq12)&quot;,\n                    &quot;completeDate&quot;: &quot;2022-01-25&quot;,\n                    &quot;isTask&quot;: &quot;0&quot;,\n                    &quot;isDel&quot;: 0\n                },\n                {\n                    &quot;tenantId&quot;: &quot;1268024398774177794&quot;,\n                    &quot;createTime&quot;: 1642044516688,\n                    &quot;updateTime&quot;: 1642157810459,\n                    &quot;updateUser&quot;: &quot;1437627170697543683&quot;,\n                    &quot;id&quot;: &quot;1481468194975600641&quot;,\n                    &quot;gapReasonId&quot;: &quot;1481468194816217090&quot;,\n                    &quot;measureContent&quot;: &quot;\u8c03\u6574\u5404\u53f0\u8f6c\u5316\u5668\u914d\u6bd4\uff0c\u53ca\u65f6\u5c06\u5931\u6548\u89e6\u5a92\u5207\u51fa\u7ffb\u5230\u3002\u8d23\u4efb\u4eba\uff1a\u738b\u78ca\uff1b\u5b8c\u6210\u65f6\u95f4\uff1aX\u6708X\u65e5\u3002&quot;,\n                    &quot;personId&quot;: &quot;1322069368578351150&quot;,\n                    &quot;personName&quot;: &quot;\u8339\u4f1f&quot;,\n                    &quot;joinPerson&quot;: &quot;[{\\&quot;userId\\&quot;:\\&quot;1339563619613458458\\&quot;,\\&quot;username\\&quot;:\\&quot;\u8d3e\u6625\u4f1f(jiacw984)\\&quot;}]&quot;,\n                    &quot;joinPersonName&quot;: &quot;\u8d3e\u6625\u4f1f(jiacw984)&quot;,\n                    &quot;completeDate&quot;: &quot;2022-01-31&quot;,\n                    &quot;isTask&quot;: &quot;0&quot;,\n                    &quot;isDel&quot;: 0\n                }\n            ],\n            &quot;targetCode&quot;: null\n        },\n        {\n            &quot;tenantId&quot;: &quot;1268024398774177794&quot;,\n            &quot;createTime&quot;: 1642150622106,\n            &quot;updateTime&quot;: 1642156984212,\n            &quot;updateUser&quot;: &quot;1437627170697543683&quot;,\n            &quot;id&quot;: &quot;1481913233361936385&quot;,\n            &quot;gapId&quot;: &quot;1481468194614890498&quot;,\n            &quot;reasonNo&quot;: &quot;BHDB00021&quot;,\n            &quot;reasonContent&quot;: &quot;VCM\u9664\u6c5e\u5668\u4e59\u7094\u542b\u91cf\u8d85\u6807\uff08\u5f53\u524d\u503c\uff1f\u6807\u51c6\u503c\uff1c3%),\u5bfc\u81f4\u5355\u4f53\u8017\u7535\u77f3\u8d85\u6807\u3002&quot;,\n            &quot;rate&quot;: 1,\n            &quot;isDel&quot;: 0,\n            &quot;measures&quot;: [],\n            &quot;targetCode&quot;: null\n        }\n    ]\n\n<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>\u4e1a\u52a1\u573a\u666f\uff1a \u9700\u6c42\uff1a reasons \u90a3\u5c42\u6570\u636e\u53ef\u4ee5\u5220\u9664\uff0c\u540c\u65f6 measures \u90a3\u5c42\u6570\u636e\u4e5f\u53ef\u662f\u5220\u9664\u3002 &#46;&#46;&#46;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2,20,3],"tags":[6],"class_list":["post-723","post","type-post","status-publish","format-standard","hentry","category-all","category-frontend","category-tech","tag-javascript"],"_links":{"self":[{"href":"https:\/\/zhuxinyong.com\/index.php?rest_route=\/wp\/v2\/posts\/723","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/zhuxinyong.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/zhuxinyong.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/zhuxinyong.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/zhuxinyong.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=723"}],"version-history":[{"count":3,"href":"https:\/\/zhuxinyong.com\/index.php?rest_route=\/wp\/v2\/posts\/723\/revisions"}],"predecessor-version":[{"id":726,"href":"https:\/\/zhuxinyong.com\/index.php?rest_route=\/wp\/v2\/posts\/723\/revisions\/726"}],"wp:attachment":[{"href":"https:\/\/zhuxinyong.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=723"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/zhuxinyong.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=723"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/zhuxinyong.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=723"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}