示例#1
0
        public async Task AddNewComplaint(ComplaintRaised newcompaint)
        {
            // first push to api to get a new complaint id
            int complaintid = UtilHelper.getRandomIdInt();

            // now add new complaint id to current complaint and insert into db.
            newcompaint.ComplaintId = complaintid;
            DbAccessor db = new DbAccessor();

            db.InsertRecord <ComplaintRaised>(newcompaint);
        }
示例#2
0
        public AddNewComplaintPageViewModel(INavigationService navigationService, IPageDialogService dialog) : base(navigationService, dialog)
        {
            SaveComplaintCommand = new DelegateCommand(ProcessSaveComplaintCommand);
            CurrentComplaint     = new ComplaintRaised();
            GetDropdownValues();

            DataColumn  = 2;
            LabelColumn = 1;
            // set up base positions
            if (CultureCode == "ar")
            {
                DataColumn  = 1;
                LabelColumn = 2;
            }
        }