Click here to Skip to main content
15,889,096 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
Question[Message Deleted] Pin
C.P.Rajesh18-Apr-08 0:05
C.P.Rajesh18-Apr-08 0:05 
GeneralRe: operator overloading Pin
CPallini18-Apr-08 0:21
mveCPallini18-Apr-08 0:21 
GeneralRe: operator overloading Pin
ThatsAlok18-Apr-08 3:21
ThatsAlok18-Apr-08 3:21 
GeneralRe: operator overloading Pin
CPallini18-Apr-08 4:15
mveCPallini18-Apr-08 4:15 
GeneralRe: [Message Deleted] Pin
Hamid_RT18-Apr-08 5:34
Hamid_RT18-Apr-08 5:34 
GeneralRe: [Message Deleted] Pin
Moak18-Apr-08 10:46
Moak18-Apr-08 10:46 
GeneralRe: [Message Deleted] Pin
Hamid_RT18-Apr-08 17:10
Hamid_RT18-Apr-08 17:10 
Generalany smarter ways to design this tree structure Pin
George_George17-Apr-08 23:58
George_George17-Apr-08 23:58 
Hello everyone,


I am designing a small budget assignment/checking application for a hierarchy organization structure. The purpose is to check and assign the budget for each employee not exceeds the total budget of a department.

The most difficult part is, a sub-department's total budget is not always lower than the upper level department's budget (i.e. the organization tree does not 100% reflects the relationship that father department node's budget is always more than that of child department node).

So, I put many exception rules to check in such situation. I am wondering whether there is any smarter ways to implement and represent the budget assignment and check model?

(I can re-write anything in this application, including data structure and algorithm, if the budget assignment and checking function is met.)

An example,

department goo under larger department foo, is represented as, /foo/goo, and /foo/zoo's budget is lower than /foo (this is a normal senses), but /foo/goo's budget is larger than /foo(this is a special rule, in the business model, even if goo under management of foo, its budget is not controlled by foo, so larger), and I maintain the remaining budget for each department,

for employee, /foo/emp1 and /foo/zoo/emp2, I can check from father node to child node for making all child nodes' budget not exceed father node, but for /foo/goo/emp3, I have to check specially. This is my headache.

If there are any smarter ways to represent the data structure and budget check, I would appreciated. Smile | :)


thanks in advance,
George
GeneralOT Pin
CPallini18-Apr-08 0:30
mveCPallini18-Apr-08 0:30 
GeneralRe: OT Pin
George_George18-Apr-08 0:34
George_George18-Apr-08 0:34 
GeneralRe: OT Pin
CPallini18-Apr-08 0:53
mveCPallini18-Apr-08 0:53 
GeneralRe: OT Pin
George_George18-Apr-08 0:59
George_George18-Apr-08 0:59 
GeneralRe: any smarter ways to design this tree structure Pin
Matthew Faithfull18-Apr-08 0:58
Matthew Faithfull18-Apr-08 0:58 
GeneralRe: any smarter ways to design this tree structure Pin
George_George18-Apr-08 1:17
George_George18-Apr-08 1:17 
GeneralRe: any smarter ways to design this tree structure Pin
Matthew Faithfull18-Apr-08 6:42
Matthew Faithfull18-Apr-08 6:42 
GeneralRe: any smarter ways to design this tree structure Pin
George_George18-Apr-08 22:44
George_George18-Apr-08 22:44 
GeneralRe: any smarter ways to design this tree structure Pin
Matthew Faithfull19-Apr-08 11:41
Matthew Faithfull19-Apr-08 11:41 
GeneralRe: any smarter ways to design this tree structure Pin
George_George19-Apr-08 21:25
George_George19-Apr-08 21:25 
GeneralRe: any smarter ways to design this tree structure Pin
Matthew Faithfull20-Apr-08 5:31
Matthew Faithfull20-Apr-08 5:31 
GeneralRe: any smarter ways to design this tree structure Pin
George_George20-Apr-08 17:34
George_George20-Apr-08 17:34 
GeneralRe: any smarter ways to design this tree structure Pin
Matthew Faithfull21-Apr-08 9:54
Matthew Faithfull21-Apr-08 9:54 
GeneralRe: any smarter ways to design this tree structure Pin
George_George21-Apr-08 22:02
George_George21-Apr-08 22:02 
GeneralRe: any smarter ways to design this tree structure Pin
Maximilien18-Apr-08 1:04
Maximilien18-Apr-08 1:04 
GeneralRe: any smarter ways to design this tree structure Pin
George_George18-Apr-08 1:20
George_George18-Apr-08 1:20 
GeneralRe: any smarter ways to design this tree structure Pin
jhwurmbach18-Apr-08 2:11
jhwurmbach18-Apr-08 2:11 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.