我试图在页面加载时在 UI 上加载初始参数虚拟数据,以便我可以使用真实数据进行自定义,因此在下面的代码中,当我在 UI 上更改并发送请求时,它总是采用最初加载到页面的 memberid,任何想法代码有什么问题吗?
主要.html
<script>
var initialParams = [{
"memberid": "etyhdjhsYYhajdsjdsQ==",
"prescriptionInfo": [{
"dispensingStoreDetails": {
"dispensingStoreNumber": "2921",
"dispensingStoreNPINumber": "1043382302",
"dispensingStorePharmacyName": "PROCARE PHARMACY DIRECT, L.L.C.",
"dispensingStoreType": "SPECIALTY_PHARMACY",
"dispensingStoreCity": "MONROEVILLE"
}
}]
}]
$('#spltyRxDetails').val(JSON.stringify(initialParams, undefined, 4));
var specialtyRequest = {
"lineOfBusiness": "SPECIALTY",
"rxOrder": {
"prescriptionDetails": []
}
}
var requestParam = {orders: []};
specialtyRequest.rxOrder.prescriptionDetails = initialParams;
requestParam.orders = specialtyRequest;
</script>
<form>
<div class="form-group memberInfo">
<label for="client_id">Client Id</label>
<input type="text" class="form-control" id="client_id" placeholder="Enter a Client Id">
</div>
<div class="form-group">
<div class="spltyParams" style="border:1px solid rgb(242, 255, 0)">
<label for="spltyRxDetails">validate Order - Request Parameters</label>
<!--<div class="col-lg-12">-->
<!--<label for="spltymemberidEnc">Specialty member idEnc (Encrypted Specialty ID)</label>-->
<!--<input type="text" name="spltymemberidEnc" id="spltymemberidEnc"/>-->
<!--</div>-->
<textarea type="text" class="form-control text-area-request" id="spltyRxDetails" placeholder="Enter Validate Order - Request Parameters in JSON"></textarea>
</div>
<button type="button" class="btn btn-primary" onclick="execWrapperApi()">Submit</button>
<label id="status"></label>
</div>
</form>
None
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)