Advertisement
Guest User

Untitled

a guest
Jul 24th, 2019
112
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.14 KB | None | 0 0
  1. function storePolicy(
  2. string memory _PolicyID,
  3. string memory _InsuredFullName ,
  4. string memory _PolicyType ,
  5. string memory _InsuredPremium ,
  6. string memory _InsuredVehicleNo ,
  7. string memory _PolicyStartDate ,
  8. string memory _PolicyEndDate
  9. )
  10. public
  11. {
  12. policy[_PolicyID].PolicyID =_PolicyID;
  13. policy[_PolicyID].InsuredFullName = _InsuredFullName;
  14. policy[_PolicyID].PolicyType = _PolicyType;
  15. policy[_PolicyID].InsuredPremium = _InsuredPremium;
  16. policy[_PolicyID].InsuredVehicleNo = _InsuredVehicleNo;
  17. policy[_PolicyID].PolicyStartDate = _PolicyStartDate;
  18. policy[_PolicyID].PolicyEndDate = _PolicyEndDate;
  19. policy[_PolicyID].policyCount = policyIndex.push(_PolicyID)-1;
  20. }
  21.  
  22. app.post('/storePolicy', (req, res) => {
  23. let PolicyID = req.query.PolicyID;
  24. let InsuredFullName = req.query.InsuredFullName;
  25. let PolicyType = req.query.PolicyType;
  26. let InsuredPremium = req.query.InsuredPremium;
  27. let InsuredVehicleNo = req.query.InsuredVehicleNo;
  28. let PolicyStartDate = req.query.PolicyStartDate;
  29. let PolicyEndDate = req.query.PolicyEndDate;
  30. let defaultAaccount = '0x7cC6C0f909824842C8faBDAB63C27d34c1747Bc7';
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement