1: //using EntityFramework.Triggers;
2: using System;
3: using System.Collections.Generic;
4: using System.ComponentModel.DataAnnotations;
5: using System.ComponentModel.DataAnnotations.Schema;
6:
7: namespace Ia.Ngn.Cl.Model
8: {
9: ////////////////////////////////////////////////////////////////////////////
10:
11: /// <summary publish="true">
12: /// Service Request Service Entity Framework class for Next Generation Network (NGN) entity model.
13: /// </summary>
14: ///
15: /// <remarks>
16: /// Copyright © 2006-2019 Jasem Y. Al-Shamlan (info@ia.com.kw), Integrated Applications - Kuwait. All Rights Reserved.
17: ///
18: /// This library is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by
19: /// the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
20: ///
21: /// This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of
22: /// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
23: ///
24: /// You should have received a copy of the GNU General Public License along with this library. If not, see http://www.gnu.org/licenses.
25: ///
26: /// Copyright notice: This notice may not be removed or altered from any source distribution.
27: /// </remarks>
28: public partial class ServiceRequestService //: ITriggerable
29: {
30: /// <summary/>
31: public ServiceRequestService()
32: {
33: //this.Triggers().Inserting += entry => { TriggeredInstanceQueue.Enqueue(entry.Entity); };
34: //this.Triggers().Updating += entry => { TriggeredInstanceQueue.Enqueue(entry.Entity); };
35: //this.Triggers().Deleting += entry => { TriggeredInstanceQueue.Enqueue(entry.Entity); };
36: }
37:
38: /// <summary/>
39: [Key, DatabaseGenerated(DatabaseGeneratedOption.None)]
40: public string Id { get; set; }
41: /// <summary/>
42: public string Service { get; set; }
43: /// <summary/>
44: public int Serial { get; set; }
45: /// <summary/>
46: public int ServiceType { get; set; }
47: /// <summary/>
48: public int Type { get; set; }
49: /// <summary/>
50: public bool Provisioned { get; set; }
51: /// <summary/>
52: public int AreaCode { get; set; }
53: /// <summary/>
54: public bool CallWaiting { get; set; }
55: /// <summary/>
56: public bool CallForwarding { get; set; }
57: /// <summary/>
58: public bool AlarmCall { get; set; }
59: /// <summary/>
60: public bool InternationalCallingUserControlled { get; set; }
61: /// <summary/>
62: public bool InternationalCalling { get; set; }
63: /// <summary/>
64: public bool CallerId { get; set; }
65: /// <summary/>
66: public bool WakeupCall { get; set; }
67: /// <summary/>
68: public bool ConferenceCall { get; set; }
69: /// <summary/>
70: public bool CallBarring { get; set; }
71: /// <summary/>
72: public bool ServiceSuspension { get; set; }
73: /// <summary/>
74: public int ServiceSuspensionTypeId { get; set; }
75: /// <summary/>
76: public bool AbbriviatedCalling { get; set; }
77: /// <summary/>
78: public bool CallForwardingUnconditional { get; set; }
79: /// <summary/>
80: public bool CallingLineIdentificationRestriction { get; set; }
81: /// <summary/>
82: public bool ConnectedLineIdentificationRestriction { get; set; }
83: /// <summary/>
84: public bool WakeUp { get; set; }
85: /// <summary/>
86: public bool CallForwardingByTime { get; set; }
87: /// <summary/>
88: public bool MutlimediaInformationPresentation { get; set; }
89: /// <summary/>
90: public bool SelectiveOutgoingCallBarring { get; set; }
91: /// <summary/>
92: public bool DialNumberCallOutAllow { get; set; }
93: /// <summary/>
94: public bool DoNotDisturb { get; set; }
95: /// <summary/>
96: public bool OutgoingCallBarring { get; set; }
97: /// <summary/>
98: public bool TemporaryLine { get; set; }
99: /// <summary/>
100: public bool CodecControl { get; set; }
101: /// <summary/>
102: public bool SelectiveIncomingCallBarring { get; set; }
103: /// <summary/>
104: public bool SelectiveCallForwarding { get; set; }
105: /// <summary/>
106: public bool DialNumberCallOutBarring { get; set; }
107: /// <summary/>
108: public bool CallForwardingBasedonBlackList { get; set; }
109: /// <summary/>
110: public bool CallForwardingBusy { get; set; }
111: /// <summary/>
112: public bool CallForwardingNoReply { get; set; }
113: /// <summary/>
114: public bool CallForwardingOffline { get; set; }
115: /// <summary/>
116: public bool CallForwardingOnUserNotReachable { get; set; }
117: /// <summary/>
118: public bool CallForwardingNoReplyinCallWaiting { get; set; }
119: /// <summary/>
120: public bool MultiRinging { get; set; }
121: /// <summary/>
122: public bool ConvergentInterPersonalService { get; set; }
123: /// <summary/>
124: public bool CallForwardingBySequence { get; set; }
125: /// <summary/>
126: public bool UserNumberChange { get; set; }
127: /// <summary/>
128: public bool BlackNumberData { get; set; }
129: /// <summary/>
130: public bool WhiteNumberData { get; set; }
131: /// <summary/>
132: public bool OwedRestriction { get; set; }
133: /// <summary/>
134: public bool Strategy { get; set; }
135: /// <summary/>
136: public bool GreenNumberData { get; set; }
137: /// <summary/>
138: public bool RedNumberData { get; set; }
139: /// <summary/>
140: public bool BarringOfAllOutgoingCalls { get; set; }
141: /// <summary/>
142: public bool BarringOfAllOutgoingInternationalCalls { get; set; }
143: /// <summary/>
144: public bool BarringOfOutgoingInternationalCallsExceptThoseDirectedToTheHomePlmnCountry { get; set; }
145: /// <summary/>
146: public bool BarringOfAllIncomingCalls { get; set; }
147: /// <summary/>
148: public bool BarringOfIncomingCallsWhenRoamingOutsideTheHomePlmnCountry { get; set; }
149: /// <summary/>
150: public bool SpeedDial { get; set; }
151: /// <summary/>
152: public bool GreenCall { get; set; }
153: /// <summary/>
154: public bool SetDataUpgrade { get; set; }
155: /// <summary/>
156: public bool AutoConsole { get; set; }
157: /// <summary/>
158: public bool NightService { get; set; }
159: /// <summary/>
160: public bool BackupNumber { get; set; }
161: /// <summary/>
162: public bool Absence { get; set; }
163: /// <summary/>
164: public bool AuthorizedCodeForStdIdd { get; set; }
165: /// <summary/>
166: public bool Hotline { get; set; }
167: /// <summary/>
168: public bool CetMaliciousCommunicationIdentification { get; set; }
169: /// <summary/>
170: public bool MissCallNotify { get; set; }
171: /// <summary/>
172: public bool SubscriptionStatus { get; set; }
173: /// <summary/>
174: public bool UsbDongleOneKeyService { get; set; }
175: /// <summary/>
176: public bool IRoamingInboundSingleImsiMultiMsisdn { get; set; }
177: /// <summary/>
178: public bool IRoamingOutboundSingleImsiMultiMsisdn { get; set; }
179: /// <summary/>
180: public bool NpaSplit { get; set; }
181: /// <summary/>
182: public bool AllCallForwardingGroup { get; set; }
183: /// <summary/>
184: public bool ConditionalCallForwardingGroup { get; set; }
185: /// <summary/>
186: public bool GeneralOrigIdentificationRestriction { get; set; }
187: /// <summary/>
188: public bool MultimediaOfOrigIdRestriction { get; set; }
189: /// <summary/>
190: public bool TerminatingIdentityRestriction { get; set; }
191: /// <summary/>
192: public bool DistinctiveRing { get; set; }
193: /// <summary/>
194: public bool VisitedNetworkImpu { get; set; }
195: /// <summary/>
196: public bool SeasonalSuspend { get; set; }
197: /// <summary/>
198: public bool NumberInvalidation { get; set; }
199: /// <summary/>
200: public bool IroamingServiceProvision { get; set; }
201: /// <summary/>
202: public bool IptvCallerId { get; set; }
203: /// <summary/>
204: public bool IptvVideoCall { get; set; }
205: /// <summary/>
206: public bool NumberPortability { get; set; }
207: /// <summary/>
208: public bool SecretaryService { get; set; }
209: /// <summary/>
210: public bool SalesBlock { get; set; }
211: /// <summary/>
212: public bool FilterCriteria { get; set; }
213: /// <summary/>
214: public bool CallerInformation { get; set; }
215: /// <summary/>
216: public bool PresenceStatus { get; set; }
217: /// <summary/>
218: public bool OneNumberService { get; set; }
219: /// <summary/>
220: public bool AssociationList { get; set; }
221: /// <summary/>
222: public int Pin { get; set; }
223: /// <summary/>
224: public virtual Access Access { get; set; }
225: /// <summary/>
226: public virtual ICollection<ServiceRequest> ServiceRequests { get; set; }
227: /// <summary/>
228: public DateTime LastRequestDateTime { get; set; }
229: /// <summary/>
230: public DateTime Created { get; set; }
231: /// <summary/>
232: public DateTime Updated { get; set; }
233: /// <summary/>
234: public System.Guid UserId { get; set; }
235:
236: /// <summary/>
237: [NotMapped]
238: public static Queue<ServiceRequestService> TriggeredInstanceQueue = new Queue<ServiceRequestService>();
239:
240: ////////////////////////////////////////////////////////////////////////////
241:
242: /// <summary>
243: ///
244: /// </summary>
245: public static bool operator ==(ServiceRequestService obj1, ServiceRequestService obj2)
246: {
247: if (ReferenceEquals(obj1, obj2))
248: {
249: return true;
250: }
251:
252: if (ReferenceEquals(obj1, null))
253: {
254: return false;
255: }
256: if (ReferenceEquals(obj2, null))
257: {
258: return false;
259: }
260:
261: return (obj1.Id == obj2.Id &&
262: obj1.Service == obj2.Service &&
263: obj1.Serial == obj2.Serial &&
264: obj1.Provisioned == obj2.Provisioned &&
265: obj1.CallWaiting == obj2.CallWaiting &&
266: obj1.InternationalCallingUserControlled == obj2.InternationalCallingUserControlled &&
267: obj1.CallerId == obj2.CallerId &&
268: obj1.CallForwarding == obj2.CallForwarding &&
269: obj1.CallBarring == obj2.CallBarring &&
270: obj1.ConferenceCall == obj2.ConferenceCall &&
271: obj1.AbbriviatedCalling == obj2.AbbriviatedCalling &&
272: obj1.InternationalCalling == obj2.InternationalCalling &&
273: obj1.AlarmCall == obj2.AlarmCall &&
274: obj1.WakeupCall == obj2.WakeupCall &&
275: obj1.BarringOfAllOutgoingCalls == obj2.BarringOfAllOutgoingCalls &&
276: obj1.BarringOfAllIncomingCalls == obj2.BarringOfAllIncomingCalls);
277: }
278:
279: ////////////////////////////////////////////////////////////////////////////
280:
281: /// <summary>
282: ///
283: /// </summary>
284: public static bool operator !=(ServiceRequestService obj1, ServiceRequestService obj2)
285: {
286: return !(obj1 == obj2);
287: }
288:
289: ////////////////////////////////////////////////////////////////////////////
290:
291: /// <summary>
292: ///
293: /// </summary>
294: public bool Equals(ServiceRequestService obj1)
295: {
296: if (ReferenceEquals(null, obj1))
297: {
298: return false;
299: }
300: if (ReferenceEquals(this, obj1))
301: {
302: return true;
303: }
304:
305: return (obj1.Id == Id &&
306: obj1.Service == Service &&
307: obj1.Serial == Serial &&
308: obj1.Provisioned == Provisioned &&
309: obj1.CallWaiting == CallWaiting &&
310: obj1.InternationalCallingUserControlled == InternationalCallingUserControlled &&
311: obj1.CallerId == CallerId &&
312: obj1.CallForwarding == CallForwarding &&
313: obj1.CallBarring == CallBarring &&
314: obj1.ConferenceCall == ConferenceCall &&
315: obj1.AbbriviatedCalling == AbbriviatedCalling &&
316: obj1.InternationalCalling == InternationalCalling &&
317: obj1.AlarmCall == AlarmCall &&
318: obj1.WakeupCall == WakeupCall &&
319: obj1.BarringOfAllOutgoingCalls == BarringOfAllOutgoingCalls &&
320: obj1.BarringOfAllIncomingCalls == BarringOfAllIncomingCalls);
321: }
322:
323: ////////////////////////////////////////////////////////////////////////////
324:
325: /// <summary>
326: ///
327: /// </summary>
328: public override bool Equals(object obj)
329: {
330: if (ReferenceEquals(null, obj))
331: {
332: return false;
333: }
334: if (ReferenceEquals(this, obj))
335: {
336: return true;
337: }
338:
339: return obj.GetType() == GetType() && Equals((ServiceRequestService)obj);
340: }
341:
342: ////////////////////////////////////////////////////////////////////////////
343:
344: /// <summary>
345: ///
346: /// </summary>
347: public override int GetHashCode()
348: {
349: unchecked
350: {
351: int hashCode = Id.GetHashCode();
352: hashCode = (hashCode * 397) ^ Service.GetHashCode();
353: hashCode = (hashCode * 397) ^ Serial.GetHashCode();
354: hashCode = (hashCode * 397) ^ Provisioned.GetHashCode();
355: hashCode = (hashCode * 397) ^ CallWaiting.GetHashCode();
356: hashCode = (hashCode * 397) ^ InternationalCallingUserControlled.GetHashCode();
357: hashCode = (hashCode * 397) ^ CallerId.GetHashCode();
358: hashCode = (hashCode * 397) ^ CallForwarding.GetHashCode();
359: hashCode = (hashCode * 397) ^ CallBarring.GetHashCode();
360: hashCode = (hashCode * 397) ^ ConferenceCall.GetHashCode();
361: hashCode = (hashCode * 397) ^ AbbriviatedCalling.GetHashCode();
362: hashCode = (hashCode * 397) ^ InternationalCalling.GetHashCode();
363: hashCode = (hashCode * 397) ^ AlarmCall.GetHashCode();
364: hashCode = (hashCode * 397) ^ WakeupCall.GetHashCode();
365: hashCode = (hashCode * 397) ^ BarringOfAllOutgoingCalls.GetHashCode();
366: hashCode = (hashCode * 397) ^ BarringOfAllIncomingCalls.GetHashCode();
367: return hashCode;
368: }
369: }
370:
371: ////////////////////////////////////////////////////////////////////////////
372:
373: /// <summary>
374: ///
375: /// </summary>
376: public bool Update(ServiceRequestService updatedServiceRequestService)
377: {
378: // below: this will not update Id, Created
379: bool updated;
380:
381: updated = false;
382:
383: if (this.Service != updatedServiceRequestService.Service) { this.Service = updatedServiceRequestService.Service; updated = true; }
384: if (this.Serial != updatedServiceRequestService.Serial) { this.Serial = updatedServiceRequestService.Serial; updated = true; }
385: if (this.ServiceType != updatedServiceRequestService.ServiceType) { this.ServiceType = updatedServiceRequestService.ServiceType; updated = true; }
386: if (this.Type != updatedServiceRequestService.Type) { this.Type = updatedServiceRequestService.Type; updated = true; }
387: if (this.Provisioned != updatedServiceRequestService.Provisioned) { this.Provisioned = updatedServiceRequestService.Provisioned; updated = true; }
388: if (this.AreaCode != updatedServiceRequestService.AreaCode) { this.AreaCode = updatedServiceRequestService.AreaCode; updated = true; }
389: if (this.CallWaiting != updatedServiceRequestService.CallWaiting) { this.CallWaiting = updatedServiceRequestService.CallWaiting; updated = true; }
390: if (this.CallForwarding != updatedServiceRequestService.CallForwarding) { this.CallForwarding = updatedServiceRequestService.CallForwarding; updated = true; }
391:
392: if (this.AlarmCall != updatedServiceRequestService.AlarmCall) { this.AlarmCall = updatedServiceRequestService.AlarmCall; updated = true; }
393: if (this.WakeupCall != updatedServiceRequestService.WakeupCall) { this.WakeupCall = updatedServiceRequestService.WakeupCall; updated = true; }
394:
395: if (this.CallBarring != updatedServiceRequestService.CallBarring) { this.CallBarring = updatedServiceRequestService.CallBarring; updated = true; }
396: if (this.InternationalCallingUserControlled != updatedServiceRequestService.InternationalCallingUserControlled) { this.InternationalCallingUserControlled = updatedServiceRequestService.InternationalCallingUserControlled; updated = true; }
397: if (this.InternationalCalling != updatedServiceRequestService.InternationalCalling) { this.InternationalCalling = updatedServiceRequestService.InternationalCalling; updated = true; }
398: if (this.CallerId != updatedServiceRequestService.CallerId) { this.CallerId = updatedServiceRequestService.CallerId; updated = true; }
399: if (this.ConferenceCall != updatedServiceRequestService.ConferenceCall) { this.ConferenceCall = updatedServiceRequestService.ConferenceCall; updated = true; }
400: if (this.ServiceSuspensionTypeId != updatedServiceRequestService.ServiceSuspensionTypeId) { this.ServiceSuspensionTypeId = updatedServiceRequestService.ServiceSuspensionTypeId; updated = true; }
401: if (this.AbbriviatedCalling != updatedServiceRequestService.AbbriviatedCalling) { this.AbbriviatedCalling = updatedServiceRequestService.AbbriviatedCalling; updated = true; }
402: if (this.CallForwardingUnconditional != updatedServiceRequestService.CallForwardingUnconditional) { this.CallForwardingUnconditional = updatedServiceRequestService.CallForwardingUnconditional; updated = true; }
403: if (this.CallingLineIdentificationRestriction != updatedServiceRequestService.CallingLineIdentificationRestriction) { this.CallingLineIdentificationRestriction = updatedServiceRequestService.CallingLineIdentificationRestriction; updated = true; }
404: if (this.ConnectedLineIdentificationRestriction != updatedServiceRequestService.ConnectedLineIdentificationRestriction) { this.ConnectedLineIdentificationRestriction = updatedServiceRequestService.ConnectedLineIdentificationRestriction; updated = true; }
405: if (this.WakeUp != updatedServiceRequestService.WakeUp) { this.WakeUp = updatedServiceRequestService.WakeUp; updated = true; }
406: if (this.CallForwardingByTime != updatedServiceRequestService.CallForwardingByTime) { this.CallForwardingByTime = updatedServiceRequestService.CallForwardingByTime; updated = true; }
407: if (this.MutlimediaInformationPresentation != updatedServiceRequestService.MutlimediaInformationPresentation) { this.MutlimediaInformationPresentation = updatedServiceRequestService.MutlimediaInformationPresentation; updated = true; }
408: if (this.SelectiveOutgoingCallBarring != updatedServiceRequestService.SelectiveOutgoingCallBarring) { this.SelectiveOutgoingCallBarring = updatedServiceRequestService.SelectiveOutgoingCallBarring; updated = true; }
409: if (this.DialNumberCallOutAllow != updatedServiceRequestService.DialNumberCallOutAllow) { this.DialNumberCallOutAllow = updatedServiceRequestService.DialNumberCallOutAllow; updated = true; }
410: if (this.DoNotDisturb != updatedServiceRequestService.DoNotDisturb) { this.DoNotDisturb = updatedServiceRequestService.DoNotDisturb; updated = true; }
411: if (this.OutgoingCallBarring != updatedServiceRequestService.OutgoingCallBarring) { this.OutgoingCallBarring = updatedServiceRequestService.OutgoingCallBarring; updated = true; }
412: if (this.TemporaryLine != updatedServiceRequestService.TemporaryLine) { this.TemporaryLine = updatedServiceRequestService.TemporaryLine; updated = true; }
413: if (this.CodecControl != updatedServiceRequestService.CodecControl) { this.CodecControl = updatedServiceRequestService.CodecControl; updated = true; }
414: if (this.SelectiveIncomingCallBarring != updatedServiceRequestService.SelectiveIncomingCallBarring) { this.SelectiveIncomingCallBarring = updatedServiceRequestService.SelectiveIncomingCallBarring; updated = true; }
415: if (this.SelectiveCallForwarding != updatedServiceRequestService.SelectiveCallForwarding) { this.SelectiveCallForwarding = updatedServiceRequestService.SelectiveCallForwarding; updated = true; }
416: if (this.DialNumberCallOutBarring != updatedServiceRequestService.DialNumberCallOutBarring) { this.DialNumberCallOutBarring = updatedServiceRequestService.DialNumberCallOutBarring; updated = true; }
417: if (this.CallForwardingBasedonBlackList != updatedServiceRequestService.CallForwardingBasedonBlackList) { this.CallForwardingBasedonBlackList = updatedServiceRequestService.CallForwardingBasedonBlackList; updated = true; }
418: if (this.CallForwardingBusy != updatedServiceRequestService.CallForwardingBusy) { this.CallForwardingBusy = updatedServiceRequestService.CallForwardingBusy; updated = true; }
419: if (this.CallForwardingNoReply != updatedServiceRequestService.CallForwardingNoReply) { this.CallForwardingNoReply = updatedServiceRequestService.CallForwardingNoReply; updated = true; }
420: if (this.CallForwardingOffline != updatedServiceRequestService.CallForwardingOffline) { this.CallForwardingOffline = updatedServiceRequestService.CallForwardingOffline; updated = true; }
421: if (this.CallForwardingOnUserNotReachable != updatedServiceRequestService.CallForwardingOnUserNotReachable) { this.CallForwardingOnUserNotReachable = updatedServiceRequestService.CallForwardingOnUserNotReachable; updated = true; }
422: if (this.CallForwardingNoReplyinCallWaiting != updatedServiceRequestService.CallForwardingNoReplyinCallWaiting) { this.CallForwardingNoReplyinCallWaiting = updatedServiceRequestService.CallForwardingNoReplyinCallWaiting; updated = true; }
423: if (this.MultiRinging != updatedServiceRequestService.MultiRinging) { this.MultiRinging = updatedServiceRequestService.MultiRinging; updated = true; }
424: if (this.ConvergentInterPersonalService != updatedServiceRequestService.ConvergentInterPersonalService) { this.ConvergentInterPersonalService = updatedServiceRequestService.ConvergentInterPersonalService; updated = true; }
425: if (this.CallForwardingBySequence != updatedServiceRequestService.CallForwardingBySequence) { this.CallForwardingBySequence = updatedServiceRequestService.CallForwardingBySequence; updated = true; }
426: if (this.UserNumberChange != updatedServiceRequestService.UserNumberChange) { this.UserNumberChange = updatedServiceRequestService.UserNumberChange; updated = true; }
427: if (this.BlackNumberData != updatedServiceRequestService.BlackNumberData) { this.BlackNumberData = updatedServiceRequestService.BlackNumberData; updated = true; }
428: if (this.WhiteNumberData != updatedServiceRequestService.WhiteNumberData) { this.WhiteNumberData = updatedServiceRequestService.WhiteNumberData; updated = true; }
429: if (this.OwedRestriction != updatedServiceRequestService.OwedRestriction) { this.OwedRestriction = updatedServiceRequestService.OwedRestriction; updated = true; }
430: if (this.Strategy != updatedServiceRequestService.Strategy) { this.Strategy = updatedServiceRequestService.Strategy; updated = true; }
431: if (this.GreenNumberData != updatedServiceRequestService.GreenNumberData) { this.GreenNumberData = updatedServiceRequestService.GreenNumberData; updated = true; }
432: if (this.RedNumberData != updatedServiceRequestService.RedNumberData) { this.RedNumberData = updatedServiceRequestService.RedNumberData; updated = true; }
433: if (this.BarringOfAllOutgoingCalls != updatedServiceRequestService.BarringOfAllOutgoingCalls) { this.BarringOfAllOutgoingCalls = updatedServiceRequestService.BarringOfAllOutgoingCalls; updated = true; }
434: if (this.BarringOfAllOutgoingInternationalCalls != updatedServiceRequestService.BarringOfAllOutgoingInternationalCalls) { this.BarringOfAllOutgoingInternationalCalls = updatedServiceRequestService.BarringOfAllOutgoingInternationalCalls; updated = true; }
435: if (this.BarringOfOutgoingInternationalCallsExceptThoseDirectedToTheHomePlmnCountry != updatedServiceRequestService.BarringOfOutgoingInternationalCallsExceptThoseDirectedToTheHomePlmnCountry) { this.BarringOfOutgoingInternationalCallsExceptThoseDirectedToTheHomePlmnCountry = updatedServiceRequestService.BarringOfOutgoingInternationalCallsExceptThoseDirectedToTheHomePlmnCountry; updated = true; }
436: if (this.BarringOfAllIncomingCalls != updatedServiceRequestService.BarringOfAllIncomingCalls) { this.BarringOfAllIncomingCalls = updatedServiceRequestService.BarringOfAllIncomingCalls; updated = true; }
437: if (this.BarringOfIncomingCallsWhenRoamingOutsideTheHomePlmnCountry != updatedServiceRequestService.BarringOfIncomingCallsWhenRoamingOutsideTheHomePlmnCountry) { this.BarringOfIncomingCallsWhenRoamingOutsideTheHomePlmnCountry = updatedServiceRequestService.BarringOfIncomingCallsWhenRoamingOutsideTheHomePlmnCountry; updated = true; }
438: if (this.SpeedDial != updatedServiceRequestService.SpeedDial) { this.SpeedDial = updatedServiceRequestService.SpeedDial; updated = true; }
439: if (this.GreenCall != updatedServiceRequestService.GreenCall) { this.GreenCall = updatedServiceRequestService.GreenCall; updated = true; }
440: if (this.SetDataUpgrade != updatedServiceRequestService.SetDataUpgrade) { this.SetDataUpgrade = updatedServiceRequestService.SetDataUpgrade; updated = true; }
441: if (this.AutoConsole != updatedServiceRequestService.AutoConsole) { this.AutoConsole = updatedServiceRequestService.AutoConsole; updated = true; }
442: if (this.NightService != updatedServiceRequestService.NightService) { this.NightService = updatedServiceRequestService.NightService; updated = true; }
443: if (this.BackupNumber != updatedServiceRequestService.BackupNumber) { this.BackupNumber = updatedServiceRequestService.BackupNumber; updated = true; }
444: if (this.Absence != updatedServiceRequestService.Absence) { this.Absence = updatedServiceRequestService.Absence; updated = true; }
445: if (this.AuthorizedCodeForStdIdd != updatedServiceRequestService.AuthorizedCodeForStdIdd) { this.AuthorizedCodeForStdIdd = updatedServiceRequestService.AuthorizedCodeForStdIdd; updated = true; }
446: if (this.Hotline != updatedServiceRequestService.Hotline) { this.Hotline = updatedServiceRequestService.Hotline; updated = true; }
447: if (this.CetMaliciousCommunicationIdentification != updatedServiceRequestService.CetMaliciousCommunicationIdentification) { this.CetMaliciousCommunicationIdentification = updatedServiceRequestService.CetMaliciousCommunicationIdentification; updated = true; }
448: if (this.MissCallNotify != updatedServiceRequestService.MissCallNotify) { this.MissCallNotify = updatedServiceRequestService.MissCallNotify; updated = true; }
449: if (this.SubscriptionStatus != updatedServiceRequestService.SubscriptionStatus) { this.SubscriptionStatus = updatedServiceRequestService.SubscriptionStatus; updated = true; }
450: if (this.UsbDongleOneKeyService != updatedServiceRequestService.UsbDongleOneKeyService) { this.UsbDongleOneKeyService = updatedServiceRequestService.UsbDongleOneKeyService; updated = true; }
451: if (this.IRoamingInboundSingleImsiMultiMsisdn != updatedServiceRequestService.IRoamingInboundSingleImsiMultiMsisdn) { this.IRoamingInboundSingleImsiMultiMsisdn = updatedServiceRequestService.IRoamingInboundSingleImsiMultiMsisdn; updated = true; }
452: if (this.IRoamingOutboundSingleImsiMultiMsisdn != updatedServiceRequestService.IRoamingOutboundSingleImsiMultiMsisdn) { this.IRoamingOutboundSingleImsiMultiMsisdn = updatedServiceRequestService.IRoamingOutboundSingleImsiMultiMsisdn; updated = true; }
453: if (this.NpaSplit != updatedServiceRequestService.NpaSplit) { this.NpaSplit = updatedServiceRequestService.NpaSplit; updated = true; }
454: if (this.AllCallForwardingGroup != updatedServiceRequestService.AllCallForwardingGroup) { this.AllCallForwardingGroup = updatedServiceRequestService.AllCallForwardingGroup; updated = true; }
455: if (this.ConditionalCallForwardingGroup != updatedServiceRequestService.ConditionalCallForwardingGroup) { this.ConditionalCallForwardingGroup = updatedServiceRequestService.ConditionalCallForwardingGroup; updated = true; }
456: if (this.GeneralOrigIdentificationRestriction != updatedServiceRequestService.GeneralOrigIdentificationRestriction) { this.GeneralOrigIdentificationRestriction = updatedServiceRequestService.GeneralOrigIdentificationRestriction; updated = true; }
457: if (this.MultimediaOfOrigIdRestriction != updatedServiceRequestService.MultimediaOfOrigIdRestriction) { this.MultimediaOfOrigIdRestriction = updatedServiceRequestService.MultimediaOfOrigIdRestriction; updated = true; }
458: if (this.TerminatingIdentityRestriction != updatedServiceRequestService.TerminatingIdentityRestriction) { this.TerminatingIdentityRestriction = updatedServiceRequestService.TerminatingIdentityRestriction; updated = true; }
459: if (this.DistinctiveRing != updatedServiceRequestService.DistinctiveRing) { this.DistinctiveRing = updatedServiceRequestService.DistinctiveRing; updated = true; }
460: if (this.VisitedNetworkImpu != updatedServiceRequestService.VisitedNetworkImpu) { this.VisitedNetworkImpu = updatedServiceRequestService.VisitedNetworkImpu; updated = true; }
461: if (this.SeasonalSuspend != updatedServiceRequestService.SeasonalSuspend) { this.SeasonalSuspend = updatedServiceRequestService.SeasonalSuspend; updated = true; }
462: if (this.NumberInvalidation != updatedServiceRequestService.NumberInvalidation) { this.NumberInvalidation = updatedServiceRequestService.NumberInvalidation; updated = true; }
463: if (this.IroamingServiceProvision != updatedServiceRequestService.IroamingServiceProvision) { this.IroamingServiceProvision = updatedServiceRequestService.IroamingServiceProvision; updated = true; }
464: if (this.IptvCallerId != updatedServiceRequestService.IptvCallerId) { this.IptvCallerId = updatedServiceRequestService.IptvCallerId; updated = true; }
465: if (this.IptvVideoCall != updatedServiceRequestService.IptvVideoCall) { this.IptvVideoCall = updatedServiceRequestService.IptvVideoCall; updated = true; }
466: if (this.NumberPortability != updatedServiceRequestService.NumberPortability) { this.NumberPortability = updatedServiceRequestService.NumberPortability; updated = true; }
467: if (this.SecretaryService != updatedServiceRequestService.SecretaryService) { this.SecretaryService = updatedServiceRequestService.SecretaryService; updated = true; }
468: if (this.SalesBlock != updatedServiceRequestService.SalesBlock) { this.SalesBlock = updatedServiceRequestService.SalesBlock; updated = true; }
469: if (this.FilterCriteria != updatedServiceRequestService.FilterCriteria) { this.FilterCriteria = updatedServiceRequestService.FilterCriteria; updated = true; }
470: if (this.CallerInformation != updatedServiceRequestService.CallerInformation) { this.CallerInformation = updatedServiceRequestService.CallerInformation; updated = true; }
471: if (this.PresenceStatus != updatedServiceRequestService.PresenceStatus) { this.PresenceStatus = updatedServiceRequestService.PresenceStatus; updated = true; }
472: if (this.OneNumberService != updatedServiceRequestService.OneNumberService) { this.OneNumberService = updatedServiceRequestService.OneNumberService; updated = true; }
473: if (this.AssociationList != updatedServiceRequestService.AssociationList) { this.AssociationList = updatedServiceRequestService.AssociationList; updated = true; }
474: if (this.Pin != updatedServiceRequestService.Pin) { this.Pin = updatedServiceRequestService.Pin; updated = true; }
475:
476: // below: ServiceSuspension is updated individually
477: // if (this.ServiceSuspension != updatedServiceRequestService.ServiceSuspension) { this.ServiceSuspension = updatedServiceRequestService.ServiceSuspension; updated = true; }
478:
479: // important: ServiceRequestService.Update() will only update stored.Access if it is null, or (stored.userId == Guid.Empty && update.Id > stored.Id)
480: // this is important to enable manual staff update.
481: if (this.Access == null && updatedServiceRequestService.Access != null) { this.Access = updatedServiceRequestService.Access; updated = true; }
482: else if (this.Access != null && updatedServiceRequestService.Access != null && this.Access.Id != updatedServiceRequestService.Access.Id && this.UserId == Guid.Empty /*&& long.Parse(updatedServiceRequestService.Id) > long.Parse(this.Id)*/) { this.Access = updatedServiceRequestService.Access; updated = true; }
483:
484: // important: I will not update this.UserId if update.UserId is Guid.Empty so that I don't override staff this.UserId. I need this to be valid for this.Access test above
485: if (this.UserId != updatedServiceRequestService.UserId && updatedServiceRequestService.UserId != Guid.Empty) { this.UserId = updatedServiceRequestService.UserId; updated = true; }
486:
487: //if (this.ServiceRequests != updatedServiceRequestService.ServiceRequests) { this.ServiceRequests = updatedServiceRequestService.ServiceRequests; updated = true; }
488:
489: if (this.LastRequestDateTime != updatedServiceRequestService.LastRequestDateTime) { this.LastRequestDateTime = updatedServiceRequestService.LastRequestDateTime; updated = true; }
490:
491: if (updated) this.Updated = DateTime.UtcNow.AddHours(3);
492:
493: return updated;
494: }
495:
496: ////////////////////////////////////////////////////////////////////////////
497:
498: /// <summary>
499: /// Copy value from another ServiceRequestService
500: /// </summary>
501: public void Copy(ServiceRequestService sourceServiceRequestService)
502: {
503: // below: this will not ...
504:
505: this.Id = sourceServiceRequestService.Id;
506: this.Service = sourceServiceRequestService.Service;
507: this.Serial = sourceServiceRequestService.Serial;
508: this.ServiceType = sourceServiceRequestService.ServiceType;
509: this.Type = sourceServiceRequestService.Type;
510: this.Provisioned = sourceServiceRequestService.Provisioned;
511: this.AreaCode = sourceServiceRequestService.AreaCode;
512:
513: this.CallWaiting = sourceServiceRequestService.CallWaiting;
514: this.CallForwarding = sourceServiceRequestService.CallForwarding;
515:
516: this.AlarmCall = sourceServiceRequestService.AlarmCall;
517: this.WakeupCall = sourceServiceRequestService.WakeupCall;
518:
519: this.CallBarring = sourceServiceRequestService.CallBarring;
520: this.InternationalCallingUserControlled = sourceServiceRequestService.InternationalCallingUserControlled;
521: this.InternationalCalling = sourceServiceRequestService.InternationalCalling;
522: this.CallerId = sourceServiceRequestService.CallerId;
523: this.ConferenceCall = sourceServiceRequestService.ConferenceCall;
524: this.ServiceSuspensionTypeId = sourceServiceRequestService.ServiceSuspensionTypeId;
525: this.AbbriviatedCalling = sourceServiceRequestService.AbbriviatedCalling;
526: this.CallForwardingUnconditional = sourceServiceRequestService.CallForwardingUnconditional;
527: this.CallingLineIdentificationRestriction = sourceServiceRequestService.CallingLineIdentificationRestriction;
528: this.ConnectedLineIdentificationRestriction = sourceServiceRequestService.ConnectedLineIdentificationRestriction;
529: this.WakeUp = sourceServiceRequestService.WakeUp;
530: this.CallForwardingByTime = sourceServiceRequestService.CallForwardingByTime;
531: this.MutlimediaInformationPresentation = sourceServiceRequestService.MutlimediaInformationPresentation;
532: this.SelectiveOutgoingCallBarring = sourceServiceRequestService.SelectiveOutgoingCallBarring;
533: this.DialNumberCallOutAllow = sourceServiceRequestService.DialNumberCallOutAllow;
534: this.DoNotDisturb = sourceServiceRequestService.DoNotDisturb;
535: this.OutgoingCallBarring = sourceServiceRequestService.OutgoingCallBarring;
536: this.TemporaryLine = sourceServiceRequestService.TemporaryLine;
537: this.CodecControl = sourceServiceRequestService.CodecControl;
538: this.SelectiveIncomingCallBarring = sourceServiceRequestService.SelectiveIncomingCallBarring;
539: this.SelectiveCallForwarding = sourceServiceRequestService.SelectiveCallForwarding;
540: this.DialNumberCallOutBarring = sourceServiceRequestService.DialNumberCallOutBarring;
541: this.CallForwardingBasedonBlackList = sourceServiceRequestService.CallForwardingBasedonBlackList;
542: this.CallForwardingBusy = sourceServiceRequestService.CallForwardingBusy;
543: this.CallForwardingNoReply = sourceServiceRequestService.CallForwardingNoReply;
544: this.CallForwardingOffline = sourceServiceRequestService.CallForwardingOffline;
545: this.CallForwardingOnUserNotReachable = sourceServiceRequestService.CallForwardingOnUserNotReachable;
546: this.CallForwardingNoReplyinCallWaiting = sourceServiceRequestService.CallForwardingNoReplyinCallWaiting;
547: this.MultiRinging = sourceServiceRequestService.MultiRinging;
548: this.ConvergentInterPersonalService = sourceServiceRequestService.ConvergentInterPersonalService;
549: this.CallForwardingBySequence = sourceServiceRequestService.CallForwardingBySequence;
550: this.UserNumberChange = sourceServiceRequestService.UserNumberChange;
551: this.BlackNumberData = sourceServiceRequestService.BlackNumberData;
552: this.WhiteNumberData = sourceServiceRequestService.WhiteNumberData;
553: this.OwedRestriction = sourceServiceRequestService.OwedRestriction;
554: this.Strategy = sourceServiceRequestService.Strategy;
555: this.GreenNumberData = sourceServiceRequestService.GreenNumberData;
556: this.RedNumberData = sourceServiceRequestService.RedNumberData;
557: this.BarringOfAllOutgoingCalls = sourceServiceRequestService.BarringOfAllOutgoingCalls;
558: this.BarringOfAllOutgoingInternationalCalls = sourceServiceRequestService.BarringOfAllOutgoingInternationalCalls;
559: this.BarringOfOutgoingInternationalCallsExceptThoseDirectedToTheHomePlmnCountry = sourceServiceRequestService.BarringOfOutgoingInternationalCallsExceptThoseDirectedToTheHomePlmnCountry;
560: this.BarringOfAllIncomingCalls = sourceServiceRequestService.BarringOfAllIncomingCalls;
561: this.BarringOfIncomingCallsWhenRoamingOutsideTheHomePlmnCountry = sourceServiceRequestService.BarringOfIncomingCallsWhenRoamingOutsideTheHomePlmnCountry;
562: this.SpeedDial = sourceServiceRequestService.SpeedDial;
563: this.GreenCall = sourceServiceRequestService.GreenCall;
564: this.SetDataUpgrade = sourceServiceRequestService.SetDataUpgrade;
565: this.AutoConsole = sourceServiceRequestService.AutoConsole;
566: this.NightService = sourceServiceRequestService.NightService;
567: this.BackupNumber = sourceServiceRequestService.BackupNumber;
568: this.Absence = sourceServiceRequestService.Absence;
569: this.AuthorizedCodeForStdIdd = sourceServiceRequestService.AuthorizedCodeForStdIdd;
570: this.Hotline = sourceServiceRequestService.Hotline;
571: this.CetMaliciousCommunicationIdentification = sourceServiceRequestService.CetMaliciousCommunicationIdentification;
572: this.MissCallNotify = sourceServiceRequestService.MissCallNotify;
573: this.SubscriptionStatus = sourceServiceRequestService.SubscriptionStatus;
574: this.UsbDongleOneKeyService = sourceServiceRequestService.UsbDongleOneKeyService;
575: this.IRoamingInboundSingleImsiMultiMsisdn = sourceServiceRequestService.IRoamingInboundSingleImsiMultiMsisdn;
576: this.IRoamingOutboundSingleImsiMultiMsisdn = sourceServiceRequestService.IRoamingOutboundSingleImsiMultiMsisdn;
577: this.NpaSplit = sourceServiceRequestService.NpaSplit;
578: this.AllCallForwardingGroup = sourceServiceRequestService.AllCallForwardingGroup;
579: this.ConditionalCallForwardingGroup = sourceServiceRequestService.ConditionalCallForwardingGroup;
580: this.GeneralOrigIdentificationRestriction = sourceServiceRequestService.GeneralOrigIdentificationRestriction;
581: this.MultimediaOfOrigIdRestriction = sourceServiceRequestService.MultimediaOfOrigIdRestriction;
582: this.TerminatingIdentityRestriction = sourceServiceRequestService.TerminatingIdentityRestriction;
583: this.DistinctiveRing = sourceServiceRequestService.DistinctiveRing;
584: this.VisitedNetworkImpu = sourceServiceRequestService.VisitedNetworkImpu;
585: this.SeasonalSuspend = sourceServiceRequestService.SeasonalSuspend;
586: this.NumberInvalidation = sourceServiceRequestService.NumberInvalidation;
587: this.IroamingServiceProvision = sourceServiceRequestService.IroamingServiceProvision;
588: this.IptvCallerId = sourceServiceRequestService.IptvCallerId;
589: this.IptvVideoCall = sourceServiceRequestService.IptvVideoCall;
590: this.NumberPortability = sourceServiceRequestService.NumberPortability;
591: this.SecretaryService = sourceServiceRequestService.SecretaryService;
592: this.SalesBlock = sourceServiceRequestService.SalesBlock;
593: this.FilterCriteria = sourceServiceRequestService.FilterCriteria;
594: this.CallerInformation = sourceServiceRequestService.CallerInformation;
595: this.PresenceStatus = sourceServiceRequestService.PresenceStatus;
596: this.OneNumberService = sourceServiceRequestService.OneNumberService;
597: this.AssociationList = sourceServiceRequestService.AssociationList;
598: this.Pin = sourceServiceRequestService.Pin;
599:
600: this.LastRequestDateTime = sourceServiceRequestService.LastRequestDateTime;
601:
602: // ServiceSuspection is updated individually using a seperate function
603: // this.ServiceSuspension = srs.ServiceSuspension;
604:
605: this.UserId = sourceServiceRequestService.UserId;
606: }
607:
608: ////////////////////////////////////////////////////////////////////////////
609: ////////////////////////////////////////////////////////////////////////////
610: }
611:
612: ////////////////////////////////////////////////////////////////////////////
613: ////////////////////////////////////////////////////////////////////////////
614: }