django-bom 1.262__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of django-bom might be problematic. Click here for more details.

Files changed (191) hide show
  1. bom/__init__.py +1 -0
  2. bom/admin.py +207 -0
  3. bom/apps.py +8 -0
  4. bom/auth_backends.py +47 -0
  5. bom/base_classes.py +31 -0
  6. bom/constants.py +217 -0
  7. bom/context_processors.py +9 -0
  8. bom/csv_headers.py +252 -0
  9. bom/decorators.py +32 -0
  10. bom/form_fields.py +59 -0
  11. bom/forms.py +1328 -0
  12. bom/helpers.py +367 -0
  13. bom/local_settings.py +35 -0
  14. bom/migrations/0001_initial.py +135 -0
  15. bom/migrations/0002_auto_20180908_2151.py +24 -0
  16. bom/migrations/0003_sellerpart_data_source.py +18 -0
  17. bom/migrations/0004_auto_20180911_0011.py +18 -0
  18. bom/migrations/0005_auto_20181007_1934.py +56 -0
  19. bom/migrations/0006_auto_20181007_1949.py +41 -0
  20. bom/migrations/0007_auto_20181009_0256.py +19 -0
  21. bom/migrations/0008_auto_20181030_0427.py +19 -0
  22. bom/migrations/0009_subpart_reference.py +18 -0
  23. bom/migrations/0010_auto_20181202_0733.py +23 -0
  24. bom/migrations/0011_auto_20181202_2113.py +22 -0
  25. bom/migrations/0012_partchangehistory.py +30 -0
  26. bom/migrations/0013_auto_20190222_1631.py +19 -0
  27. bom/migrations/0014_auto_20190223_2353.py +18 -0
  28. bom/migrations/0015_auto_20190303_1915.py +136 -0
  29. bom/migrations/0016_auto_20190405_2308.py +58 -0
  30. bom/migrations/0017_auto_20190616_1912.py +19 -0
  31. bom/migrations/0018_auto_20190616_2143.py +24 -0
  32. bom/migrations/0019_auto_20190624_1246.py +45 -0
  33. bom/migrations/0020_auto_20190627_0207.py +38 -0
  34. bom/migrations/0021_auto_20190627_0428.py +23 -0
  35. bom/migrations/0022_auto_20190811_2140.py +35 -0
  36. bom/migrations/0023_auto_20191205_2351.py +255 -0
  37. bom/migrations/0024_auto_20191214_1342.py +89 -0
  38. bom/migrations/0025_auto_20191221_1907.py +38 -0
  39. bom/migrations/0026_auto_20191222_2258.py +22 -0
  40. bom/migrations/0027_auto_20191222_2347.py +17 -0
  41. bom/migrations/0028_partrevision_displayable_synopsis.py +74 -0
  42. bom/migrations/0029_auto_20191231_1630.py +23 -0
  43. bom/migrations/0030_auto_20200101_2253.py +22 -0
  44. bom/migrations/0031_auto_20200104_1352.py +38 -0
  45. bom/migrations/0032_auto_20200126_1806.py +27 -0
  46. bom/migrations/0033_auto_20200203_0618.py +29 -0
  47. bom/migrations/0034_auto_20200222_0359.py +30 -0
  48. bom/migrations/0035_auto_20200303_0111.py +34 -0
  49. bom/migrations/0036_auto_20200303_0538.py +17 -0
  50. bom/migrations/0037_auto_20200405_1642.py +44 -0
  51. bom/migrations/0038_auto_20200422_0504.py +19 -0
  52. bom/migrations/0039_auto_20200929_2315.py +41 -0
  53. bom/migrations/0040_alter_organization_currency.py +19 -0
  54. bom/migrations/0041_organization_subscription_quantity.py +18 -0
  55. bom/migrations/0042_auto_20210720_2137.py +23 -0
  56. bom/migrations/0043_auto_20211123_0157.py +24 -0
  57. bom/migrations/0044_auto_20220831_1241.py +23 -0
  58. bom/migrations/0045_sellerpart_link.py +18 -0
  59. bom/migrations/0046_alter_sellerpart_unique_together.py +17 -0
  60. bom/migrations/0047_sellerpart_seller_part_number.py +18 -0
  61. bom/migrations/0048_rename_part_organization_number_class_bom_part_organiz_b333d6_idx_and_more.py +1017 -0
  62. bom/migrations/0049_alter_assembly_id_alter_assemblysubparts_id_and_more.py +99 -0
  63. bom/migrations/0050_alter_organization_options.py +17 -0
  64. bom/migrations/0051_alter_manufacturer_organization_and_more.py +41 -0
  65. bom/migrations/0052_remove_partrevision_attribute_and_more.py +584 -0
  66. bom/migrations/__init__.py +0 -0
  67. bom/models.py +886 -0
  68. bom/part_bom.py +192 -0
  69. bom/settings.py +262 -0
  70. bom/static/bom/css/dashboard.css +17 -0
  71. bom/static/bom/css/jquery.treetable.css +28 -0
  72. bom/static/bom/css/materialize.min.css +13 -0
  73. bom/static/bom/css/part-info.css +15 -0
  74. bom/static/bom/css/style.css +482 -0
  75. bom/static/bom/css/tablesorter-theme.materialize.css +176 -0
  76. bom/static/bom/css/treetable-theme.css +42 -0
  77. bom/static/bom/doc/sample_part_classes.csv +38 -0
  78. bom/static/bom/doc/test_bom.csv +6 -0
  79. bom/static/bom/doc/test_bom_5_intelligent.csv +4 -0
  80. bom/static/bom/doc/test_full_bom.csv +37 -0
  81. bom/static/bom/doc/test_new_parts.csv +5 -0
  82. bom/static/bom/doc/test_new_parts_5_intelligent.csv +5 -0
  83. bom/static/bom/img/_ionicons_svg_md-arrow-dropdown.svg +1 -0
  84. bom/static/bom/img/_ionicons_svg_md-arrow-dropright.svg +1 -0
  85. bom/static/bom/img/favicon.ico +0 -0
  86. bom/static/bom/img/google/web/1x/btn_google_signin_dark_disabled_web.png +0 -0
  87. bom/static/bom/img/google/web/1x/btn_google_signin_dark_focus_web.png +0 -0
  88. bom/static/bom/img/google/web/1x/btn_google_signin_dark_normal_web.png +0 -0
  89. bom/static/bom/img/google/web/1x/btn_google_signin_dark_pressed_web.png +0 -0
  90. bom/static/bom/img/google/web/1x/btn_google_signin_light_disabled_web.png +0 -0
  91. bom/static/bom/img/google/web/1x/btn_google_signin_light_focus_web.png +0 -0
  92. bom/static/bom/img/google/web/1x/btn_google_signin_light_normal_web.png +0 -0
  93. bom/static/bom/img/google/web/1x/btn_google_signin_light_pressed_web.png +0 -0
  94. bom/static/bom/img/google/web/2x/btn_google_signin_dark_disabled_web@2x.png +0 -0
  95. bom/static/bom/img/google/web/2x/btn_google_signin_dark_focus_web@2x.png +0 -0
  96. bom/static/bom/img/google/web/2x/btn_google_signin_dark_normal_web@2x.png +0 -0
  97. bom/static/bom/img/google/web/2x/btn_google_signin_dark_pressed_web@2x.png +0 -0
  98. bom/static/bom/img/google/web/2x/btn_google_signin_light_disabled_web@2x.png +0 -0
  99. bom/static/bom/img/google/web/2x/btn_google_signin_light_focus_web@2x.png +0 -0
  100. bom/static/bom/img/google/web/2x/btn_google_signin_light_normal_web@2x.png +0 -0
  101. bom/static/bom/img/google/web/2x/btn_google_signin_light_pressed_web@2x.png +0 -0
  102. bom/static/bom/img/google/web/vector/btn_google_dark_disabled_ios.eps +814 -0
  103. bom/static/bom/img/google/web/vector/btn_google_dark_disabled_ios.svg +24 -0
  104. bom/static/bom/img/google/web/vector/btn_google_dark_focus_ios.eps +1866 -0
  105. bom/static/bom/img/google/web/vector/btn_google_dark_focus_ios.svg +51 -0
  106. bom/static/bom/img/google/web/vector/btn_google_dark_normal_ios.eps +1031 -0
  107. bom/static/bom/img/google/web/vector/btn_google_dark_normal_ios.svg +50 -0
  108. bom/static/bom/img/google/web/vector/btn_google_dark_pressed_ios.eps +1031 -0
  109. bom/static/bom/img/google/web/vector/btn_google_dark_pressed_ios.svg +50 -0
  110. bom/static/bom/img/google/web/vector/btn_google_light_disabled_ios.eps +814 -0
  111. bom/static/bom/img/google/web/vector/btn_google_light_disabled_ios.svg +24 -0
  112. bom/static/bom/img/google/web/vector/btn_google_light_focus_ios.eps +1837 -0
  113. bom/static/bom/img/google/web/vector/btn_google_light_focus_ios.svg +44 -0
  114. bom/static/bom/img/google/web/vector/btn_google_light_normal_ios.eps +1002 -0
  115. bom/static/bom/img/google/web/vector/btn_google_light_normal_ios.svg +43 -0
  116. bom/static/bom/img/google/web/vector/btn_google_light_pressed_ios.eps +1002 -0
  117. bom/static/bom/img/google/web/vector/btn_google_light_pressed_ios.svg +43 -0
  118. bom/static/bom/img/google_drive_logo.svg +1 -0
  119. bom/static/bom/img/indabom.png +0 -0
  120. bom/static/bom/img/mouser.png +0 -0
  121. bom/static/bom/img/octopart_blue.svg +19 -0
  122. bom/static/bom/js/formset-handler.js +65 -0
  123. bom/static/bom/js/jquery-3.4.1.min.js +2 -0
  124. bom/static/bom/js/jquery.ba-floatingscrollbar.min.js +10 -0
  125. bom/static/bom/js/jquery.treetable.js +629 -0
  126. bom/static/bom/js/materialize.min.js +6 -0
  127. bom/templates/bom/account-delete.html +23 -0
  128. bom/templates/bom/add-manufacturer-part.html +66 -0
  129. bom/templates/bom/add-sellerpart.html +93 -0
  130. bom/templates/bom/base-menu.html +16 -0
  131. bom/templates/bom/base.html +129 -0
  132. bom/templates/bom/bom-action-btn.html +23 -0
  133. bom/templates/bom/bom-action-table.html +57 -0
  134. bom/templates/bom/bom-base-menu.html +6 -0
  135. bom/templates/bom/bom-base.html +24 -0
  136. bom/templates/bom/bom-form-modal.html +36 -0
  137. bom/templates/bom/bom-form.html +30 -0
  138. bom/templates/bom/bom-modal-add-users.html +49 -0
  139. bom/templates/bom/bom-signup.html +12 -0
  140. bom/templates/bom/components/bom-flat.html +131 -0
  141. bom/templates/bom/components/bom-indented.html +237 -0
  142. bom/templates/bom/components/manufacturer-part-list.html +270 -0
  143. bom/templates/bom/components/seller-part-list.html +62 -0
  144. bom/templates/bom/create-part.html +65 -0
  145. bom/templates/bom/dashboard-menu.html +15 -0
  146. bom/templates/bom/dashboard.html +303 -0
  147. bom/templates/bom/edit-manufacturer-part.html +72 -0
  148. bom/templates/bom/edit-part-class.html +120 -0
  149. bom/templates/bom/edit-part.html +67 -0
  150. bom/templates/bom/edit-quantity-of-measure.html +119 -0
  151. bom/templates/bom/edit-user-meta.html +70 -0
  152. bom/templates/bom/help.html +1356 -0
  153. bom/templates/bom/manufacturer-info.html +82 -0
  154. bom/templates/bom/manufacturers.html +97 -0
  155. bom/templates/bom/nothing-to-see.html +15 -0
  156. bom/templates/bom/organization-create.html +135 -0
  157. bom/templates/bom/part-info.html +448 -0
  158. bom/templates/bom/part-revision-display.html +50 -0
  159. bom/templates/bom/part-revision-edit.html +39 -0
  160. bom/templates/bom/part-revision-manage-bom.html +115 -0
  161. bom/templates/bom/part-revision-new.html +57 -0
  162. bom/templates/bom/part-revision-release.html +41 -0
  163. bom/templates/bom/search-help.html +101 -0
  164. bom/templates/bom/seller-info.html +82 -0
  165. bom/templates/bom/sellers.html +97 -0
  166. bom/templates/bom/settings.html +734 -0
  167. bom/templates/bom/signup.html +28 -0
  168. bom/templates/bom/subscription_panel.html +16 -0
  169. bom/templates/bom/table_of_contents.html +47 -0
  170. bom/templates/bom/upload-bom.html +111 -0
  171. bom/templates/bom/upload-parts-help.html +103 -0
  172. bom/templates/bom/upload-parts.html +50 -0
  173. bom/templates/registration/login.html +39 -0
  174. bom/tests.py +1592 -0
  175. bom/third_party_apis/__init__.py +0 -0
  176. bom/third_party_apis/base_api.py +51 -0
  177. bom/third_party_apis/google_drive.py +166 -0
  178. bom/third_party_apis/mouser.py +132 -0
  179. bom/third_party_apis/test_apis.py +24 -0
  180. bom/urls.py +100 -0
  181. bom/utils.py +228 -0
  182. bom/validators.py +23 -0
  183. bom/views/__init__.py +0 -0
  184. bom/views/json_views.py +55 -0
  185. bom/views/views.py +1773 -0
  186. bom/wsgi.py +16 -0
  187. django_bom-1.262.dist-info/METADATA +206 -0
  188. django_bom-1.262.dist-info/RECORD +191 -0
  189. django_bom-1.262.dist-info/WHEEL +5 -0
  190. django_bom-1.262.dist-info/licenses/LICENSE +674 -0
  191. django_bom-1.262.dist-info/top_level.txt +1 -0
@@ -0,0 +1,28 @@
1
+ {% extends 'bom/base.html' %}
2
+
3
+ {% load materializecss %}
4
+
5
+ {% block title %}Sign Up For BOM{% endblock %}
6
+ {% block head-title %}Sign Up{% endblock %}
7
+
8
+ {% block content %}
9
+ {% load static %}
10
+ <div class="container">
11
+ <div class="section center">
12
+ <h5 class="">Sign up for BOM</h5>
13
+ </div>
14
+ <div class="section center">
15
+ <form method="post">
16
+ {% csrf_token %}
17
+ <div class="row">
18
+ <div class="col m6 push-m3 s12">
19
+ {{ form|materializecss }}
20
+ <div class="center">
21
+ <button class="waves-effect waves-light btn btn-primary" style="min-width:150px" type="submit">Sign Up</button>
22
+ </div>
23
+ </div>
24
+ </div>
25
+ </form>
26
+ </div>
27
+ </div>
28
+ {% endblock %}
@@ -0,0 +1,16 @@
1
+ {# Placeholder for subscription/billing UI. Host apps can override this template. Flat layout (no cards). #}
2
+ <div class="section">
3
+ <h4 class="section-title" style="display:flex;align-items:center;gap:8px;margin-top:0;">
4
+ <i class="material-icons teal-text text-darken-1">credit_card</i>
5
+ Subscription & Billing
6
+ </h4>
7
+ <p class="grey-text" style="margin-top:8px;">
8
+ This self-hosted instance of django-bom does not include a billing portal. To change an organization's plan or
9
+ seat count,
10
+ use the Django admin: edit the Organization object and adjust the <b>Subscription</b> related fields.
11
+ </p>
12
+ <div class="right-align" style="margin-top: 8px;">
13
+ <a class="btn waves-effect" href="/admin/">Open Admin</a>
14
+ </div>
15
+ <div class="divider" style="margin-top:16px;"></div>
16
+ </div>
@@ -0,0 +1,47 @@
1
+ {% load static %}
2
+
3
+ {% block script %}
4
+ <script>
5
+ document.addEventListener('DOMContentLoaded', function() {
6
+ htmlTableOfContents();
7
+ } );
8
+
9
+ function htmlTableOfContents(documentRef) {
10
+ var documentRef = documentRef || document;
11
+ var toc = documentRef.getElementById("toc");
12
+ // Use headings inside <article> only:
13
+ // var headings = [].slice.call(documentRef.body.querySelectorAll('article h1, article h2, article h3, article h4, article h5, article h6'));
14
+ {#var headings = [].slice.call(documentRef.body.querySelectorAll('h1, h2, h3, h4, h5, h6'));#}
15
+ var article = document.querySelector("article");
16
+ var headings = article ? [].slice.call(article.querySelectorAll( "h1, h2, h3, h4, h5, h6")) : [];
17
+ headings.forEach(function (heading, index) {
18
+ var ref = "toc" + index;
19
+ var h_parent = heading.parentElement;
20
+ if (h_parent.hasAttribute("id"))
21
+ ref = h_parent.getAttribute( "id" );
22
+ else
23
+ ref = heading.textContent.replace(/\s+/g, '-').toLowerCase();
24
+ h_parent.setAttribute("id", ref);
25
+
26
+ var link = documentRef.createElement("a");
27
+ link.setAttribute("href", "#" + ref);
28
+ link.textContent = heading.textContent;
29
+
30
+ var div = documentRef.createElement("li");
31
+ div.setAttribute("class", `${heading.tagName.toLowerCase()} scrollspy`);
32
+ div.appendChild(link);
33
+ toc.appendChild(div);
34
+ });
35
+ }
36
+
37
+ try {
38
+ module.exports = htmlTableOfContents;
39
+ } catch (e) {
40
+ // module.exports is not defined
41
+ }
42
+
43
+ $(document).ready(function(){
44
+ $('.scrollspy').scrollSpy();
45
+ });
46
+ </script>
47
+ {% endblock %}
@@ -0,0 +1,111 @@
1
+ {% extends 'bom/bom-base.html' %}
2
+
3
+ {% load static %}
4
+ {% load materializecss %}
5
+
6
+ {% block head-title %}{{ title }}{% endblock %}
7
+
8
+ {% block main %}
9
+ {{ add_subpart_form.media }}
10
+ {% endblock %}
11
+
12
+ {% block bom-menu %}
13
+ {% endblock %}
14
+
15
+ {% block content %}
16
+ <div class="container-app">
17
+ {% if profile.role == 'A' %}
18
+ <div class="upload-bom">
19
+ <p>Click here to download <a href="{% static 'bom/doc/test_bom_5_intelligent.csv' %}">a sample CSV file for uploading intelligent
20
+ parts</a> and here is <a href="{% static 'bom/doc/test_bom.csv' %}">a sample CSV file for uploading semi-intelligent parts</a>. Uploading uses
21
+ an append or create strategy, for example, if a part, part revision, or part class already exists, it will be overwritten; and
22
+ if a part, part revision, or part class <b>does not</b> exist, it will be created.</p>
23
+ <p>For details on CSV file requirements, see the help docs <a href="{% url 'bom:help' %}#uploading-parts" target="_blank">here <i class="material-icons" style="font-size: 1em;">open_in_new</i></a>.</p>
24
+
25
+ <form action="{% url 'bom:upload-bom' %}" method="post" enctype="multipart/form-data">
26
+ {% csrf_token %}
27
+ <div class="row">
28
+ <div class="col s9 file-field input-field">
29
+ <div class="green lighten-1 btn">
30
+ <span>File</span>
31
+ {{ bom_csv_form.file }}
32
+ </div>
33
+ <div class="file-path-wrapper">
34
+ <input class="file-path validate" type="text" placeholder="Upload a file.">
35
+ {{ bom_csv_form.file.errors }}
36
+ </div>
37
+ </div>
38
+ <div class="col s1 input-field">
39
+ <input class="green lighten-1 btn" type="submit" value="Upload"/>
40
+ </div>
41
+ </div>
42
+ {# <div class="row">#}
43
+ {# {{ upload_bom_form.create_part_classes|materializecss:'m3 s12' }}#}
44
+ {# <div class="col m6 s12">#}
45
+ {# If a part is uploaded with a part class that doesn't exist, the upload will fail. Check this box to instead, try to create the part class.#}
46
+ {# </div>#}
47
+ {# </div>#}
48
+ <div class="row">
49
+ {{ upload_bom_form.parent_part_number|materializecss:'m3 s12' }}
50
+ <div class="col m6 s12 input-field">
51
+ <b>{{upload_bom_form.parent_part_number.label}}</b> <i>Optional.</i> Upload this BOM to a parent assembly by specifying the parent part number. Level 1 will upload as the first child of this part.
52
+ {% if parent_part %}
53
+ <br><h6><a href="{% url 'bom:part-info' part_id=parent_part.id %}">Go to {{ parent_part_number }}</a></h6>
54
+ {% endif %}
55
+ </div>
56
+ </div>
57
+ </form>
58
+ <div class="row">
59
+ <div class="col s6">
60
+ <a href="{% url 'bom:upload-bom' %}" class="waves-effect waves-light btn-flat grey-text lighten-1" style="margin-left: -16px;">Cancel</a>
61
+ </div>
62
+ </div>
63
+ <br>
64
+ </div>
65
+ {% else %}
66
+ {% include 'bom/nothing-to-see.html' with required_privilege='Admin' %}
67
+ {% endif %}
68
+ </div>
69
+ {% endblock %}
70
+
71
+ {% block bom-script %}
72
+ <!-- Tree Table -->
73
+ <script src="{% static 'bom/js/jquery.treetable.js' %}"></script>
74
+ <script>
75
+ $("#indented-bom").treetable({
76
+ expandable: true,
77
+ indent: 2,
78
+ initialState: 'collapsed',
79
+ onInitialized: function () {
80
+ $("#indented-bom").treetable("reveal", {{ part_revision.id }});
81
+ }
82
+ });
83
+ </script>
84
+
85
+ <!-- Floating Horizontal Scrollbar -->
86
+ <script type="text/javascript" src="{% static 'bom/js/jquery.ba-floatingscrollbar.min.js' %}"></script>
87
+ <script>
88
+ $(function () {
89
+ $('.responsive-table-wrapper').floatingScrollbar();
90
+ });
91
+ </script>
92
+
93
+ <!-- Handle if there's an anchor, select tab -->
94
+ <script type='text/javascript'>
95
+ // For dropdown menu
96
+ $(document).ready(function () {
97
+ $('.dropdown-trigger').dropdown({
98
+ inDuration: 300,
99
+ outDuration: 225,
100
+ constrainWidth: false, // Does not change width of dropdown to that of the activator
101
+ hover: false, // Activate on hover
102
+ gutter: 0, // Spacing from edge
103
+ belowOrigin: false, // Displays dropdown below the button
104
+ alignment: 'left', // Displays dropdown with edge aligned to the left of button
105
+ stopPropagation: false // Stops event propagation
106
+ }
107
+ );
108
+
109
+ });
110
+ </script>
111
+ {% endblock %}
@@ -0,0 +1,103 @@
1
+ {% extends 'bom/bom-base.html' %}
2
+
3
+ {% load static %}
4
+ {% load materializecss %}
5
+
6
+ {% block head-title %}{{ title }}{% endblock %}
7
+
8
+ {% block bom-menu %}
9
+ <li><a href="{% url 'bom:home' %}">Home</a></li>
10
+ {% endblock %}
11
+
12
+ {% block content %}
13
+ <div class="container">
14
+
15
+ <h5>Help For Uploading Parts</h5>
16
+ <p>To batch create parts, upload a csv that contains columns with the headers
17
+ {% if organization.number_scheme == 'S' %}<b>'part_class'</b> or {% endif %}<b>'part_number'</b>, <b>'description'</b> or <b>'value'</b>
18
+ along with <b>'value_units'</b>, and <b>'revision'</b>.{% if organization.number_scheme == 'S' %} If you specify a part number
19
+ then it must be one that is not already being used. If you don't specify a part number
20
+ then IndaBOM will create one for you.{% endif %}</p>
21
+
22
+ <p>If you specify <b>'value_units'</b> then valid choices are:
23
+ Ohms, mOhms, kOhms, F, pF, nF, uF, V, uV, mV, A, uA, mA, C, F, Other
24
+ <p>
25
+ You may optionally specify a manufacturer and manufacturer's part number using
26
+ columns with the headers <b>'manufacturer'</b> and a <b>'manufacturer_part_number'</b>.
27
+ <p>
28
+ If you specify a part number that is already in use then the part will not be uploaded.
29
+ Similarly, other errors may prevent a part from being uploaded{% if organization.number_scheme == 'S' %}, for example, an improperly
30
+ formatted IndaBOM part number or the use of an unknown IndaBOM part class{% endif %}. The
31
+ uploading will continue with the next valid part in the file.
32
+ </p>
33
+ <p>
34
+ Any optional information that you can enter manually about a part via the
35
+ Create Part page may also be submitted via the part list CSV file.
36
+ Below is the complete list of the additional items you can upload for each part in
37
+ the file.
38
+ </p>
39
+
40
+ <h5>Optional Part Properties</h5>
41
+ <p/>
42
+ <p>
43
+ Optional part properties are listed below. Some properties requires that you also
44
+ specify units of measure.
45
+ </p>
46
+ <p>
47
+ Valid choices for part properties and units appear below.
48
+ </p>
49
+ <p><b>'tolerance'</b></p>
50
+ <p><b>'package'</b> (See choices below)</p>
51
+ <p><b>'pin_count'</b></p>
52
+ <p><b>'supply_voltage'</b> and <b>'supply_voltage_units'</b> (See choices below)</p>
53
+ <p><b>'power_rating'</b> and <b>'power_rating_units'</b> (See choices below)</p>
54
+ <p><b>'voltage_rating'</b> and <b>'voltage_rating_units'</b> (See choices below)</p>
55
+ <p><b>'current_rating'</b> and <b>'current_rating_units'</b> (See choices below)</p>
56
+ <p><b>'temperature_rating'</b> and <b>'temperature_rating_units'</b> (See choices below)</p>
57
+ <p><b>'memory'</b> and <b>'memory_units'</b> (See choices below)</p>
58
+ <p><b>'interface'</b> (See choices below)</p>
59
+ <p><b>'frequency'</b> and <b>'frequency_units'</b> (See choices below)</p>
60
+ <p><b>'wavelength'</b> and <b>'wavelength_units'</b> (See choices below)</p>
61
+ <p><b>'color'</b></p>
62
+ <p><b>'material'</b></p>
63
+ <p><b>'finish'</b></p>
64
+ <p><b>'length'</b> and <b>'length_units'</b> (See choices below)</p>
65
+ <p><b>'width'</b> and <b>'width_units'</b> (See choices below)</p>
66
+ <p><b>'height'</b> and <b>'height_units'</b> (See choices below)</p>
67
+ <p><b>'weight'</b> and <b>'weight_units'</b> (See choices below)</p>
68
+ <p><b>'attribute'</b></p>
69
+ <p/>
70
+
71
+ <h5>Valid Choices for Part Properties or Units</h5>
72
+ <p/>
73
+ <p><b>'package'</b> = 0201 smd, 0402 smd, 0603 smd, 0805 smd, 1206 smd, 1210 smd, 1812 smd,
74
+ 2010 smd, 2512 smd, 1/8 radial, 1/4 radial, 1/2 radial, Size A, Size B, Size C, Size D, Size E, SOT-23,
75
+ SOT-223, DIL, SOP, SOIC, QFN, QFP, QFT, PLCCP, VGA, BGA, CSP</p>
76
+ <p><b>'power_rating'</b> = W, uW, mW, kW, MW</p>
77
+ <p><b>'supply_voltage'</b>, <b>'voltage_rating'</b> = V, uV, mV, kV, MV</p>
78
+ <p><b>'current_rating'</b> = A, uA, mA, kA, MA</p>
79
+ <p><b>'temperature_rating'</b> = C, F</p>
80
+ <p><b>'memory'</b> = KB, MB, GB, TB</p>
81
+ <p><b>'interface'</b> = I2C, SPI, CAN, One-Wire, RS485, RS232, WiFi, 4G, BT, Z_Wave, Zigbee, LAN, USB, HDMI, Other</p>
82
+ <p><b>'frequency'</b> = Hz, kHz MHz, GHz</p>
83
+ <p><b>'wavelength'</b> = km, m, cm, um, nm, A (where A means Angstrom)</p>
84
+ <p><b>'length'</b>, <b>'width'</b>, <b>'height'</b> = mil, in, ft, yd, km, m, cm, um, nm</p>
85
+ <p><b>'weight'</b> = mg, g, kb, oz, lb</p>
86
+ </p>
87
+
88
+ <h5>Manufacturers and sellers</h5>
89
+ <p/>
90
+ <p>
91
+ Manufacturers and sellers informations can be directly imported. Sellers data can be imported only when manufacturer data are present. Seller information must contains at least the seller name, unit cost and nre cost.
92
+ </p>
93
+ <p><b>'manufacturer_name'</b> Manufacturer name. Will be created if not exists</p>
94
+ <p><b>'manufacturer_part_number'</b></p>
95
+ <p><b>'seller'</b> Seller name. Will be created if not exists</p>
96
+ <p><b>'seller_part_number'</b> Optional seller part number</p>
97
+ <p><b>'unit_cost'</b></p>
98
+ <p><b>'part_nre_cost'</b></p>
99
+ <p><b>'moq'</b></p>
100
+ <p><b>'mpq</b></p>
101
+ </p>
102
+ </div>
103
+ {% endblock %}
@@ -0,0 +1,50 @@
1
+ {% extends 'bom/bom-base.html' %}
2
+
3
+ {% load static %}
4
+
5
+ {% block head-title %}{{ title }}{% endblock %}
6
+
7
+ {% block bom-menu %}
8
+ <li><a href="{% url 'bom:home' %}">Cancel</a></li>
9
+ {% endblock %}
10
+
11
+
12
+ {% block content %}
13
+ <div class="container-app">
14
+ {% if profile.role == 'A' %}
15
+ <h5>Upload Parts</h5>
16
+ <p>To batch create parts, upload a csv that contains columns with the headers
17
+ {% if organization.number_scheme == 'S' %}<b>'part_class'</b> or {% endif %}<b>'part_number'</b>, <b>'description'</b> or <b>'value'</b>
18
+ along with <b>'value_units'</b>, and <b>'revision'</b>. {% if organization.number_scheme == 'S' %}If you specify a part number
19
+ then it must be one that is not already being used. If you don't specify a part number
20
+ then IndaBOM will create one for you.{% endif %}
21
+ </p>
22
+ </p>
23
+ You may optionally specify a manufacturer and manufacturer's part number using
24
+ columns with the headers <b>'manufacturer'</b> and a <b>'manufacturer_part_number'</b>.
25
+ For the names of other optional columns click <a href="{% url 'bom:upload-parts-help' %}">here</a>.
26
+ </p>
27
+ <form action="{% url 'bom:upload-parts' %}" method="post" enctype="multipart/form-data">
28
+ {% csrf_token %}
29
+ <div class="row">
30
+ <div class="col m10 s12 file-field input-field">
31
+ <div class="green lighten-1 btn">
32
+ <span>File</span>
33
+ {{ form.file }}
34
+ </div>
35
+ <div class="file-path-wrapper">
36
+ <input class="file-path validate" type="text" placeholder="Upload a file.">
37
+ {{ form.file.errors }}
38
+ </div>
39
+ </div>
40
+ <div class="col m2 s12 text-center input-field">
41
+ <input class="green lighten-1 btn" type="submit" value="Upload"/>
42
+ </div>
43
+ </div>
44
+ </form>
45
+ {% else %}
46
+ {% include 'bom/nothing-to-see.html' with required_privilege='Admin' %}
47
+ {% endif %}
48
+ </div>
49
+ {% endblock %}
50
+
@@ -0,0 +1,39 @@
1
+ {% extends BASE_TEMPLATE %}
2
+
3
+ {% load static %}
4
+
5
+ {% block head-title %}Login!{% endblock %}
6
+
7
+ {% block title %}
8
+ <link rel="stylesheet" type="text/css" href="{% static 'bom/style.css' %}" />
9
+
10
+ <div class="text-center">Login...</div>
11
+
12
+ {% endblock %}
13
+
14
+ {% block menu %}
15
+ {% endblock%}
16
+ {% block content %}
17
+ <div class="section center">
18
+ <h5 class="">Login into your BOM account</h5>
19
+ </div>
20
+
21
+ <div class="section center">
22
+ <div class="container ">
23
+ <div class="row" style="display: inline-block; ">
24
+ <form method="post">
25
+ {% csrf_token %}
26
+ <div class="row">
27
+ <div class="col s12">
28
+ {{ form }}
29
+ <div class="center">
30
+ <button class="waves-effect waves-light btn green lighten-1" style="min-width:150px" type="submit">Login</button>
31
+ </div>
32
+ </div>
33
+ </div>
34
+ </form>
35
+ </div>
36
+ </div>
37
+ </div>
38
+ {% endblock %}
39
+