[10719] | 1 | |
---|
| 2 | .. |n0| replace:: n\ :sub:`0` |
---|
| 3 | .. |m0| replace:: m\ :sub:`0` |
---|
| 4 | |
---|
[10699] | 5 | .. _label-data-entities: |
---|
| 6 | |
---|
[10696] | 7 | Data Entities |
---|
| 8 | ============= |
---|
| 9 | |
---|
[10699] | 10 | These are the data entities the new system is supposed to model. Each |
---|
| 11 | of these entities should be addable, editable, and removable as |
---|
| 12 | covered in more detail in :ref:`label-use-cases`. |
---|
[10696] | 13 | |
---|
[10699] | 14 | For each entity we give a short description to tell what it means, |
---|
| 15 | what its purpose is and in what regards (and how) it should be handled |
---|
| 16 | by the system. Again the more detailed actions on these entities |
---|
| 17 | provided by the system are described in the :ref:`label-use-cases` |
---|
| 18 | section. |
---|
| 19 | |
---|
| 20 | The data entities are sorted alphabetically, not by importance or |
---|
| 21 | similar. Used description terms should link to other respective |
---|
| 22 | entities/terms where possible. |
---|
| 23 | |
---|
[10701] | 24 | Each data entitiy description provides a list of use cases and other |
---|
| 25 | data entities connected. Connections to other data entities contain a |
---|
| 26 | relationship telling how many instances of the described entity are |
---|
[10743] | 27 | connected to how many instances of the related entity. |
---|
[10701] | 28 | |
---|
[10743] | 29 | The following relation types may occur (in both directions): |
---|
[10699] | 30 | |
---|
[10743] | 31 | - 1:1 (one on one) |
---|
| 32 | - n:1 (many on one) |
---|
| 33 | - n:m (many on many) |
---|
| 34 | - p:1 (many or none on one) |
---|
| 35 | - p:q (many or none on many or none) |
---|
| 36 | - p:n (many or none on many) |
---|
| 37 | - b:1 (one or none on one) |
---|
| 38 | |
---|
| 39 | with |
---|
| 40 | |
---|
| 41 | - n, m element of {1, 2, ...}, |
---|
| 42 | - p, q element of {0, 1, 2, ...} |
---|
| 43 | - b element of {0, 1} |
---|
| 44 | |
---|
| 45 | Examples: |
---|
| 46 | |
---|
| 47 | 1:p service-contract relation means that each service |
---|
| 48 | offered can result in various contracts, but each contract is |
---|
[10745] | 49 | only based on one service. |
---|
[10743] | 50 | |
---|
[10776] | 51 | p:q useraccount-userrole relation means that each user account can have no role |
---|
| 52 | or several roles and each role can be assigned to no user account |
---|
| 53 | or several user accounts. |
---|
[10743] | 54 | |
---|
| 55 | Relations can always be read in two directions. |
---|
| 56 | |
---|
[10717] | 57 | .. _label-contact-address: |
---|
| 58 | |
---|
| 59 | Contact Address |
---|
| 60 | --------------- |
---|
| 61 | |
---|
| 62 | A postal address. |
---|
| 63 | |
---|
[10745] | 64 | Connected to: :ref:`label-contact-data` (p:1) |
---|
[10717] | 65 | |
---|
[10701] | 66 | |
---|
[10699] | 67 | .. _label-contact-data: |
---|
| 68 | |
---|
[10701] | 69 | Contact Data |
---|
| 70 | ------------ |
---|
[10699] | 71 | |
---|
[10752] | 72 | The data neccessary to contact some :ref:`label-customer`, |
---|
| 73 | :ref:`label-officer` or similar entity. Contact data might contain several |
---|
[10732] | 74 | addresses, phone numbers, emails, etc. |
---|
[10699] | 75 | |
---|
[10717] | 76 | Connected to: :ref:`label-customer` (1:1), |
---|
[10742] | 77 | :ref:`label-contact-address` (1:p), :ref:`label-contact-email` |
---|
| 78 | (1:n), :ref:`label-contact-phone` (1:p) |
---|
[10716] | 79 | |
---|
| 80 | |
---|
| 81 | |
---|
[10719] | 82 | .. _label-contact-email: |
---|
| 83 | |
---|
| 84 | Contact Email |
---|
| 85 | ------------- |
---|
| 86 | |
---|
| 87 | An email address with optional additional clear name. For email |
---|
| 88 | addresses we store some timestamp that indicates when the respective |
---|
| 89 | email address was last checked successfully (thus marking it a 'valid' |
---|
[10742] | 90 | one). No timestamp means, the email address has never been checked. |
---|
[10719] | 91 | |
---|
[10742] | 92 | Connected to: :ref:`label-contact-data` (n:1), |
---|
[10776] | 93 | :ref:`label-timestamp` (1:q), |
---|
| 94 | :ref:`label-user-account` (1:b) |
---|
[10719] | 95 | |
---|
[10781] | 96 | Used in the following use cases: :ref:`label-uc-user-add`, |
---|
| 97 | :ref:`label-uc-user-manage`, :ref:`label-uc-service-manage` |
---|
[10719] | 98 | |
---|
| 99 | |
---|
| 100 | .. _label-contact-phone: |
---|
| 101 | |
---|
| 102 | Contact Phone |
---|
| 103 | ------------- |
---|
| 104 | |
---|
[10737] | 105 | Mobile phone number which is capable of receiving sms text messages. |
---|
[10719] | 106 | |
---|
[10745] | 107 | Connected to: :ref:`label-contact-data` (p:1) |
---|
[10719] | 108 | |
---|
[10781] | 109 | Used in the following use cases: :ref:`label-uc-user-add`, |
---|
| 110 | :ref:`label-uc-user-manage` , :ref:`label-uc-service-manage` |
---|
[10719] | 111 | |
---|
| 112 | |
---|
[10699] | 113 | .. _label-contract: |
---|
| 114 | |
---|
[10701] | 115 | Contract |
---|
| 116 | -------- |
---|
[10699] | 117 | |
---|
[10730] | 118 | A contract is created whenever a :ref:`label-customer` orders some |
---|
| 119 | :ref:`label-service` from the system. It is always connected to a |
---|
| 120 | :ref:`label-customer` and a :ref:`label-service` . |
---|
[10729] | 121 | |
---|
| 122 | A contract is not necessarily written on paper and signed by |
---|
| 123 | people. Instead it is an abstraction used inside the system. |
---|
| 124 | |
---|
[10743] | 125 | It is always created from a :ref:`label-service`, which tells about |
---|
[10730] | 126 | the basic data, with additional parameters set that depend on the type |
---|
| 127 | of :ref:`label-service` ordered. |
---|
[10729] | 128 | |
---|
[10732] | 129 | Contracts can trigger :ref:`label-transaction`\ s. For instance if some |
---|
| 130 | :ref:`label-customer` orders a service. When the service charges |
---|
| 131 | become due, a respective :ref:`label-transaction` is triggered. |
---|
| 132 | |
---|
[10776] | 133 | Contracts can have multiple :ref:`label-supp-contract`\ s. |
---|
[10729] | 134 | |
---|
[10742] | 135 | Connected to: :ref:`label-service` (p:1), :ref:`label-customer` (p:1), |
---|
[10776] | 136 | :ref:`label-supp-contract` (1:p), :ref:`label-transaction` (1:p), |
---|
[10745] | 137 | :ref:`label-meter` (1:b) |
---|
[10729] | 138 | |
---|
| 139 | |
---|
[10699] | 140 | .. _label-customer: |
---|
| 141 | |
---|
[10701] | 142 | Customer |
---|
| 143 | -------- |
---|
[10696] | 144 | |
---|
[10776] | 145 | A user data entity and beneficiary of :ref:`label-contract`\ s. |
---|
[10701] | 146 | |
---|
[10738] | 147 | Customers are added to the system by initial import (migration phase), |
---|
[10776] | 148 | being created by staff or can register themselves (self-registration) |
---|
| 149 | to the system. |
---|
[10733] | 150 | |
---|
[10776] | 151 | Each customer has a :ref:`label-user-account`. |
---|
| 152 | |
---|
[10738] | 153 | Customers have to provide :ref:`label-contact-data` and get |
---|
| 154 | :ref:`label-login-credentials` to login to the system. |
---|
| 155 | |
---|
| 156 | Once logged in, customers get a 'My Eko-Disco' page where they can |
---|
| 157 | |
---|
| 158 | - see their current orders |
---|
| 159 | |
---|
| 160 | - watch their consumption |
---|
| 161 | |
---|
| 162 | - order more services |
---|
| 163 | |
---|
| 164 | - handle contractual problems |
---|
| 165 | |
---|
| 166 | - get help if problems arise |
---|
| 167 | |
---|
[10742] | 168 | - retrieve bills |
---|
[10738] | 169 | |
---|
[10742] | 170 | - change their passwords |
---|
[10738] | 171 | |
---|
| 172 | Customers can order :ref:`label-service`\ s and pay these (kinds of |
---|
| 173 | payment depend on the type of service/good ordered and the available |
---|
| 174 | payment methods). |
---|
| 175 | |
---|
| 176 | Customers and their data can be managed by customers themselves (for |
---|
[10752] | 177 | instance when postal addresses change), and by officers. |
---|
[10738] | 178 | |
---|
[10742] | 179 | Connected to: :ref:`label-contract` (1:p), |
---|
[10746] | 180 | :ref:`label-contact-data` (1:1), :ref:`label-login-credentials` (1:1), |
---|
[10776] | 181 | :ref:`label-user-account` (b:1) |
---|
[10738] | 182 | |
---|
| 183 | |
---|
| 184 | .. _label-location: |
---|
| 185 | |
---|
| 186 | Location |
---|
| 187 | -------- |
---|
| 188 | |
---|
| 189 | A real-world location. Used for instance for meters to store |
---|
[10744] | 190 | information about their place. The location of a meter does not necessarily |
---|
| 191 | correspond with one of the :ref:`label-contact-address`\ es. |
---|
| 192 | Locations can either be less formal, for instance describing a location |
---|
| 193 | in words, or very precise by using GPS data. |
---|
[10738] | 194 | |
---|
[10742] | 195 | Connected to: :ref:`label-meter` (1:p) |
---|
[10738] | 196 | |
---|
| 197 | |
---|
[10699] | 198 | .. _label-login-credentials: |
---|
| 199 | |
---|
[10701] | 200 | Login Credentials |
---|
| 201 | ----------------- |
---|
[10699] | 202 | |
---|
[10776] | 203 | A set of username and password assigned to user accounts. Passwords are |
---|
[10738] | 204 | stored inside the system using strong cryptographic hash functions. |
---|
[10733] | 205 | |
---|
[10738] | 206 | Passwords can be reset on request. |
---|
| 207 | |
---|
[10776] | 208 | Connected to: :ref:`label-customer` (1:1), :ref:`label-user-account` (1:1) |
---|
[10738] | 209 | |
---|
| 210 | |
---|
[10699] | 211 | .. _label-meter: |
---|
| 212 | |
---|
[10701] | 213 | Meter |
---|
| 214 | ----- |
---|
[10696] | 215 | |
---|
[10738] | 216 | A meter measures power consumption. It has a place where it is |
---|
| 217 | installed and might be connected to one or several contracts. For a |
---|
| 218 | given time a meter can be connected to one or zero contracts. |
---|
[10733] | 219 | |
---|
[10738] | 220 | Each meter has to provide a :ref:`label-location` that tells, where it |
---|
| 221 | is installed. |
---|
[10699] | 222 | |
---|
[10738] | 223 | Meters also contain a history of meter values |
---|
| 224 | (:ref:`label-meter-value`), which is basically a list of meter values |
---|
| 225 | at a given time. |
---|
[10696] | 226 | |
---|
[10742] | 227 | Connected to: :ref:`label-contract` (b:1), |
---|
| 228 | :ref:`label-meter-value` (1:n), :ref:`label-location` (p:1) |
---|
[10733] | 229 | |
---|
[10738] | 230 | |
---|
[10699] | 231 | .. _label-meter-value: |
---|
[10696] | 232 | |
---|
[10701] | 233 | Meter Value |
---|
| 234 | ----------- |
---|
[10696] | 235 | |
---|
[10738] | 236 | The value of a :ref:`label-meter` at a certain point in time |
---|
[10776] | 237 | (providing a :ref:`label-timestamp`) authorized by some user or device. |
---|
[10733] | 238 | |
---|
[10738] | 239 | It serves mainly for computing power consumption of |
---|
| 240 | :ref:`label-customer`\ s. |
---|
[10696] | 241 | |
---|
[10738] | 242 | When a new meter value is added to the system (the respective |
---|
| 243 | :ref:`label-meter` is 'updated'), the system also registers how the |
---|
| 244 | the new value was entered, i.e. by whom and when. |
---|
[10696] | 245 | |
---|
[10738] | 246 | The system will be prepared to collect meter values in two ways: |
---|
[10696] | 247 | |
---|
[10738] | 248 | a) (push-method): by being fed with respective data by authorized |
---|
[10752] | 249 | users (officers) |
---|
[10701] | 250 | |
---|
[10738] | 251 | b) (pull-method): by polling dedicated hardware that provides the |
---|
| 252 | neccessary interface (automatic remote-reading). |
---|
[10701] | 253 | |
---|
[10738] | 254 | The second choice requires appropriate hardware to be in place, which |
---|
| 255 | in detail is not part of this specs. The system will, however, be |
---|
| 256 | prepared to collect meter data from external devices. |
---|
[10733] | 257 | |
---|
[10745] | 258 | Connected to: :ref:`label-meter` (n:1), :ref:`label-timestamp` (1:1), |
---|
[10776] | 259 | :ref:`label-user-account` (p:1) |
---|
[10738] | 260 | |
---|
| 261 | |
---|
[10746] | 262 | .. _label-officer: |
---|
| 263 | |
---|
| 264 | Officer |
---|
| 265 | ------- |
---|
| 266 | |
---|
[10776] | 267 | A user data entity of a staff member with certain permissions to manage |
---|
| 268 | portal data. |
---|
[10746] | 269 | |
---|
[10776] | 270 | Each officer has a :ref:`label-user-account`. |
---|
[10746] | 271 | |
---|
[10776] | 272 | Actors are called :ref:`Manager <label-actors>`\ s if they are officers with |
---|
| 273 | local managing permission. |
---|
| 274 | |
---|
[10746] | 275 | Connected to: :ref:`label-login-credentials` (1:1), |
---|
[10776] | 276 | :ref:`label-user-account` (b:1), |
---|
[10746] | 277 | :ref:`label-user-role` (1:p) |
---|
| 278 | |
---|
| 279 | |
---|
[10699] | 280 | .. _label-report: |
---|
[10696] | 281 | |
---|
[10701] | 282 | Report |
---|
| 283 | ------ |
---|
[10699] | 284 | |
---|
[10738] | 285 | Administrative report or list to give overviews over current state of |
---|
| 286 | business. Includes lists of customers sorted by various categories |
---|
| 287 | (type of contract, amount of fees paid, etc.), lists of services |
---|
| 288 | sorted by various categories, etc. |
---|
[10720] | 289 | |
---|
[10738] | 290 | Reports are generated as PDF documents and are available for download |
---|
[10776] | 291 | by authorized users. |
---|
[10738] | 292 | |
---|
| 293 | Connected to: (almost everything else) |
---|
| 294 | |
---|
| 295 | |
---|
[10720] | 296 | .. _label-service: |
---|
| 297 | |
---|
| 298 | Service |
---|
| 299 | ------- |
---|
| 300 | |
---|
[10732] | 301 | The system will provide different services to |
---|
| 302 | :ref:`label-customer`\ s. These can have arbitrary forms, including |
---|
| 303 | one-time services (like installation of meters) and open-ended |
---|
| 304 | long-time services (like delivering power based on contract). Services |
---|
| 305 | are managable by staff like goods offered in a shop. |
---|
[10720] | 306 | |
---|
[10729] | 307 | Services define the conditions under which they can be ordered by |
---|
[10732] | 308 | :ref:`label-customer`\ s, including prices, runtimes, etc. |
---|
[10729] | 309 | |
---|
[10732] | 310 | Services also serve as factories for :ref:`label-contract`\ s. |
---|
[10729] | 311 | |
---|
[10742] | 312 | Connected to: :ref:`label-contract` (1:p) |
---|
[10730] | 313 | |
---|
[10729] | 314 | |
---|
[10776] | 315 | .. _label-supp-contract: |
---|
| 316 | |
---|
| 317 | Supplementary Contract |
---|
| 318 | ---------------------- |
---|
| 319 | |
---|
| 320 | A supplementary contract always belongs to some already existing |
---|
| 321 | :ref:`label-contract` but comes with an own set of |
---|
| 322 | parameters. A typical supplementary contract materialises if a customer |
---|
| 323 | orders an amount of electrical energy on the bases of a 'main' contract |
---|
| 324 | achieved between the customer and the distribution company. |
---|
| 325 | The parent contract for instance may guarantee a special price |
---|
| 326 | per kilowatt hour of electrical energy. |
---|
| 327 | |
---|
| 328 | Supplementary contracts are created by :ref:`label-contract`\ s. |
---|
| 329 | |
---|
| 330 | Connected to: :ref:`label-contract` (p:1), |
---|
| 331 | :ref:`label-service` (p:1), :ref:`label-customer` (p:1), |
---|
| 332 | :ref:`label-transaction` (1:p) |
---|
| 333 | |
---|
| 334 | |
---|
[10699] | 335 | .. _label-timestamp: |
---|
| 336 | |
---|
[10701] | 337 | Timestamp |
---|
| 338 | --------- |
---|
| 339 | |
---|
[10738] | 340 | A timestamp can be a calendar date or a calendar date plus some day |
---|
| 341 | time. |
---|
[10720] | 342 | |
---|
[10738] | 343 | The system will internally use UTC-based timestamps only to minimize |
---|
| 344 | ambiguities. In menus, frontends, etc. timestamps are displayed in |
---|
| 345 | local Lagos time. |
---|
| 346 | |
---|
| 347 | Connected to: :ref:`label-meter-value` (1:1), |
---|
[10742] | 348 | :ref:`label-contact-email` (p:1) |
---|
[10738] | 349 | |
---|
| 350 | |
---|
[10720] | 351 | .. _label-transaction: |
---|
| 352 | |
---|
| 353 | Transaction |
---|
| 354 | ----------- |
---|
| 355 | |
---|
| 356 | A transaction is some business-relevant action taken. A transaction |
---|
| 357 | means basically, that something happened, that leads to increased or |
---|
| 358 | decreased customer accounts. Normally this is something like a |
---|
| 359 | payment, some service order or similar. |
---|
| 360 | |
---|
| 361 | Transactions do always belong to one certain customer account. They |
---|
| 362 | also contain some amount of money which is thereby transfered to or |
---|
| 363 | from a customer's account. They also always reference a service which |
---|
[10730] | 364 | is consumed, purchased, or (pre-)paid by the respective customer. |
---|
[10720] | 365 | |
---|
[10742] | 366 | Connected to: :ref:`label-customer` (p:1), :ref:`label-service` |
---|
[10743] | 367 | (p:1), :ref:`label-contract` (p:1) |
---|
[10720] | 368 | |
---|
| 369 | |
---|
[10776] | 370 | .. _label-user-account: |
---|
[10738] | 371 | |
---|
[10776] | 372 | User Account |
---|
| 373 | ------------ |
---|
[10738] | 374 | |
---|
[10776] | 375 | A user account is a set of user data and :ref:`label-login-credentials` |
---|
[10777] | 376 | which allows a user (agent) to authenticate against the system and |
---|
[10776] | 377 | let the system store some information required for user handling, |
---|
[10777] | 378 | such as real name, email address and/or mobile phone number. An email |
---|
| 379 | address and/or phone number ensures that the user can be contacted |
---|
| 380 | electronically by the system. |
---|
| 381 | |
---|
[10776] | 382 | :ref:`label-user-role`\s are assigned to user accounts and managed by the |
---|
| 383 | system to grant authorization for the various views of the portal. |
---|
| 384 | Real-world officers (staff members) and customers are different to the |
---|
[10777] | 385 | system as they will get different roles. Also anonymous users |
---|
| 386 | (users without user account) are accepted by the system to provide |
---|
| 387 | marketing pages, service offers, etc. |
---|
[10738] | 388 | |
---|
| 389 | Users can be blocked or removed from the system. |
---|
| 390 | |
---|
[10745] | 391 | Connected to: :ref:`label-login-credentials` (1:1), |
---|
[10746] | 392 | :ref:`label-customer` (1:b), |
---|
[10776] | 393 | :ref:`label-user-role` (p:q), |
---|
| 394 | :ref:`label-contact-email` (b:1) |
---|
[10738] | 395 | |
---|
| 396 | |
---|
| 397 | .. _label-user-role: |
---|
| 398 | |
---|
| 399 | User Role |
---|
| 400 | --------- |
---|
| 401 | |
---|
[10776] | 402 | A set of permissions assigned to a group of :ref:`label-user-account`\ s. |
---|
[10738] | 403 | |
---|
[10776] | 404 | Connected to: :ref:`label-user-account` (p:q) |
---|
[10738] | 405 | |
---|