Selaa lähdekoodia

版本號 : 2021042101

更新內容
1、修正不含管銷計算沒計算的bug
B70340 4 vuotta sitten
vanhempi
commit
0b8ad6a52b

BIN
.vs/YD-ERP-SYS/v16/.suo Näytä tiedosto


+ 1
- 1
YD-ERP-SYS/Module/全域變數.vb Näytä tiedosto

@@ -4,7 +4,7 @@
4 4
     Public 版本號 As String : Public Target As String : Public Target1 As String : Public Target2 As String : Public FTP帳號 As String : Public FTP密碼 As String : Public FTP物理位置 As String
5 5
     Public AA(99) As String : Public BB(99) As Boolean : Public CC(99) As Boolean : Public 登入判斷 As Boolean : Public 業務號碼 As String
6 6
     '----系統版本-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
7
-    Public 版本 As String = "2021042001"
7
+    Public 版本 As String = "2021042101"
8 8
     '----系統用全域變數-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
9 9
     Public 列印用SQL As String = "" : Public 列印用SQL2 As String : Public 公司編號 As String : Public 公司電話 As String : Public 公司統編 As String : Public 公司地址 As String
10 10
     Public 關鍵字編號 As String

BIN
YD-ERP-SYS/bin/Debug/YD-ERP-SYS.exe Näytä tiedosto


BIN
YD-ERP-SYS/bin/Debug/YD-ERP-SYS.pdb Näytä tiedosto


BIN
YD-ERP-SYS/obj/Debug/YD-ERP-SYS.exe Näytä tiedosto


BIN
YD-ERP-SYS/obj/Debug/YD-ERP-SYS.pdb Näytä tiedosto


BIN
YD-ERP-SYS/obj/Debug/YD-ERP-SYS.vbproj.GenerateResource.cache Näytä tiedosto


BIN
YD-ERP-SYS/obj/Debug/YD-ERP-SYS.vbprojAssemblyReference.cache Näytä tiedosto


+ 14
- 1
YD-ERP-SYS/業務系統管理/訂單控制表.Designer.vb Näytä tiedosto

@@ -140,6 +140,7 @@ Partial Class 訂單控制表
140 140
         Me.Panel3 = New System.Windows.Forms.Panel()
141 141
         Me.顯示_bt = New System.Windows.Forms.Button()
142 142
         Me.隱藏_bt = New System.Windows.Forms.Button()
143
+        Me.物料成本無管銷_tb = New System.Windows.Forms.TextBox()
143 144
         CType(Me.銷售單據_dgv, System.ComponentModel.ISupportInitialize).BeginInit()
144 145
         Me.Panel1.SuspendLayout()
145 146
         CType(Me.銷售衍生運費_dgv, System.ComponentModel.ISupportInitialize).BeginInit()
@@ -905,7 +906,7 @@ Partial Class 訂單控制表
905 906
         Me.客戶資料_dgv.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
906 907
         Me.客戶資料_dgv.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill
907 908
         Me.客戶資料_dgv.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize
908
-        Me.客戶資料_dgv.Location = New System.Drawing.Point(17, 8832)
909
+        Me.客戶資料_dgv.Location = New System.Drawing.Point(17, 9111)
909 910
         Me.客戶資料_dgv.Name = "客戶資料_dgv"
910 911
         Me.客戶資料_dgv.RowHeadersWidth = 5
911 912
         DataGridViewCellStyle6.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
@@ -1275,6 +1276,7 @@ Partial Class 訂單控制表
1275 1276
         Me.Panel2.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
1276 1277
             Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
1277 1278
         Me.Panel2.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D
1279
+        Me.Panel2.Controls.Add(Me.物料成本無管銷_tb)
1278 1280
         Me.Panel2.Controls.Add(Me.未審核_lb)
1279 1281
         Me.Panel2.Controls.Add(Me.Label27)
1280 1282
         Me.Panel2.Controls.Add(Me.Label23)
@@ -1355,6 +1357,16 @@ Partial Class 訂單控制表
1355 1357
         Me.隱藏_bt.Text = "隱藏" & Global.Microsoft.VisualBasic.ChrW(13) & Global.Microsoft.VisualBasic.ChrW(10) & "控件"
1356 1358
         Me.隱藏_bt.UseVisualStyleBackColor = True
1357 1359
         '
1360
+        '物料成本無管銷_tb
1361
+        '
1362
+        Me.物料成本無管銷_tb.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
1363
+        Me.物料成本無管銷_tb.Enabled = False
1364
+        Me.物料成本無管銷_tb.Location = New System.Drawing.Point(229, 204)
1365
+        Me.物料成本無管銷_tb.Name = "物料成本無管銷_tb"
1366
+        Me.物料成本無管銷_tb.Size = New System.Drawing.Size(165, 23)
1367
+        Me.物料成本無管銷_tb.TabIndex = 1340
1368
+        Me.物料成本無管銷_tb.Visible = False
1369
+        '
1358 1370
         '訂單控制表
1359 1371
         '
1360 1372
         Me.AutoScaleDimensions = New System.Drawing.SizeF(7.0!, 16.0!)
@@ -1489,4 +1501,5 @@ Partial Class 訂單控制表
1489 1501
     Friend WithEvents 項次4_tb As TextBox
1490 1502
     Friend WithEvents Label49 As Label
1491 1503
     Friend WithEvents 銷售衍生運費_dgv As DataGridView
1504
+    Friend WithEvents 物料成本無管銷_tb As TextBox
1492 1505
 End Class

+ 5
- 2
YD-ERP-SYS/業務系統管理/訂單控制表.vb Näytä tiedosto

@@ -181,7 +181,7 @@ Public Class 訂單控制表
181 181
     Private Sub Set_合記計算()
182 182
         Dim 不含1類銷售小記 As Integer : Dim 金額1 As Integer = 0
183 183
         售價小計_tb.Text = "0" : 稅金_tb.Text = "0" : 銷售合計_tb.Text = "0" : 收入小計_tb.Text = "0" : 支出小計_tb.Text = "0" : 額外收支_tb.Text = "0" : 物料成本_tb.Text = "0"
184
-        司機運費_tb.Text = "0" : 管銷費用_tb.Text = "0" : 其他成本_tb.Text = "0" : 刷卡總和_tb.Text = "0" : 刷卡稅金_tb.Text = "0" : 刷卡傭金_tb.Text = "0"
184
+        司機運費_tb.Text = "0" : 管銷費用_tb.Text = "0" : 其他成本_tb.Text = "0" : 刷卡總和_tb.Text = "0" : 刷卡稅金_tb.Text = "0" : 刷卡傭金_tb.Text = "0" : 物料成本無管銷_tb.Text = "0"
185 185
         '-------001-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
186 186
         For i As Integer = 0 To 收款事項_dgv.Rows.Count - 1
187 187
             If 收款事項_dgv("真項次", i).Value.ToString = "0" And 收款事項_dgv("內容", i).Value.ToString <> "未收餘額" Then
@@ -195,6 +195,9 @@ Public Class 訂單控制表
195 195
 
196 196
             If Strings.Left(銷售明細_dgv("料號", i).Value.ToString, 1) <> "1" Then
197 197
                 物料成本_tb.Text = Val(物料成本_tb.Text) + (銷售明細_dgv("數量", i).Value * 銷售明細_dgv("成本", i).Value)
198
+                If 銷售明細_dgv("無管銷", i).Value = False Then
199
+                    物料成本無管銷_tb.Text = Val(物料成本無管銷_tb.Text) + (銷售明細_dgv("數量", i).Value * 銷售明細_dgv("成本", i).Value)
200
+                End If
198 201
                 不含1類銷售小記 = 不含1類銷售小記 + 銷售明細_dgv("售價", i).Value
199 202
             End If
200 203
             If Strings.Left(銷售明細_dgv("料號", i).Value.ToString, 1) = "1" Then
@@ -205,7 +208,7 @@ Public Class 訂單控制表
205 208
                 稅金_tb.Text = Val(稅金_tb.Text) + ((銷售明細_dgv("數量", i).Value * 銷售明細_dgv("單價", i).Value * 1.05) - (銷售明細_dgv("數量", i).Value * 銷售明細_dgv("單價", i).Value))
206 209
             End If
207 210
         Next
208
-        管銷費用_tb.Text = Val(物料成本_tb.Text) * 1.06 - Val(物料成本_tb.Text)
211
+        管銷費用_tb.Text = Val(物料成本無管銷_tb.Text) * 1.06 - Val(物料成本無管銷_tb.Text)
209 212
         銷售合計_tb.Text = Val(售價小計_tb.Text) + Val(稅金_tb.Text)
210 213
 
211 214
         If Val(稅金_tb.Text) = 0 And Val(刷卡稅金_tb.Text) = 0 Then

+ 70
- 57
YD-ERP-SYS/業務系統管理/銷售單審核.Designer.vb Näytä tiedosto

@@ -22,22 +22,22 @@ Partial Class 銷售單審核
22 22
     '請勿使用程式碼編輯器進行修改。
23 23
     <System.Diagnostics.DebuggerStepThrough()>
24 24
     Private Sub InitializeComponent()
25
-        Dim DataGridViewCellStyle1 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
26
-        Dim DataGridViewCellStyle2 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
27
-        Dim DataGridViewCellStyle3 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
28
-        Dim DataGridViewCellStyle4 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
29
-        Dim DataGridViewCellStyle5 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
30
-        Dim DataGridViewCellStyle6 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
31
-        Dim DataGridViewCellStyle7 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
32
-        Dim DataGridViewCellStyle8 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
33
-        Dim DataGridViewCellStyle9 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
34
-        Dim DataGridViewCellStyle10 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
35
-        Dim DataGridViewCellStyle11 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
36
-        Dim DataGridViewCellStyle12 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
37
-        Dim DataGridViewCellStyle13 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
38
-        Dim DataGridViewCellStyle14 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
39
-        Dim DataGridViewCellStyle15 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
40
-        Dim DataGridViewCellStyle16 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
25
+        Dim DataGridViewCellStyle33 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
26
+        Dim DataGridViewCellStyle34 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
27
+        Dim DataGridViewCellStyle35 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
28
+        Dim DataGridViewCellStyle36 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
29
+        Dim DataGridViewCellStyle37 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
30
+        Dim DataGridViewCellStyle38 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
31
+        Dim DataGridViewCellStyle39 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
32
+        Dim DataGridViewCellStyle40 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
33
+        Dim DataGridViewCellStyle41 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
34
+        Dim DataGridViewCellStyle42 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
35
+        Dim DataGridViewCellStyle43 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
36
+        Dim DataGridViewCellStyle44 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
37
+        Dim DataGridViewCellStyle45 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
38
+        Dim DataGridViewCellStyle46 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
39
+        Dim DataGridViewCellStyle47 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
40
+        Dim DataGridViewCellStyle48 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle()
41 41
         Me.業務_cb = New System.Windows.Forms.ComboBox()
42 42
         Me.客戶資料驗證_bt = New System.Windows.Forms.Button()
43 43
         Me.售價_nud = New System.Windows.Forms.NumericUpDown()
@@ -197,6 +197,7 @@ Partial Class 銷售單審核
197 197
         Me.運費資料流水號_tb = New System.Windows.Forms.TextBox()
198 198
         Me.Panel3 = New System.Windows.Forms.Panel()
199 199
         Me.顯示_bt = New System.Windows.Forms.Button()
200
+        Me.物料成本無管銷_tb = New System.Windows.Forms.TextBox()
200 201
         CType(Me.售價_nud, System.ComponentModel.ISupportInitialize).BeginInit()
201 202
         CType(Me.區域庫存_dgv, System.ComponentModel.ISupportInitialize).BeginInit()
202 203
         CType(Me.成本_nud, System.ComponentModel.ISupportInitialize).BeginInit()
@@ -260,17 +261,17 @@ Partial Class 銷售單審核
260 261
         '
261 262
         '區域庫存_dgv
262 263
         '
263
-        DataGridViewCellStyle1.BackColor = System.Drawing.Color.FromArgb(CType(CType(192, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
264
-        Me.區域庫存_dgv.AlternatingRowsDefaultCellStyle = DataGridViewCellStyle1
264
+        DataGridViewCellStyle33.BackColor = System.Drawing.Color.FromArgb(CType(CType(192, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
265
+        Me.區域庫存_dgv.AlternatingRowsDefaultCellStyle = DataGridViewCellStyle33
265 266
         Me.區域庫存_dgv.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
266 267
         Me.區域庫存_dgv.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill
267 268
         Me.區域庫存_dgv.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize
268 269
         Me.區域庫存_dgv.Location = New System.Drawing.Point(345, 317)
269 270
         Me.區域庫存_dgv.Name = "區域庫存_dgv"
270 271
         Me.區域庫存_dgv.RowHeadersWidth = 5
271
-        DataGridViewCellStyle2.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
272
-        DataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.[True]
273
-        Me.區域庫存_dgv.RowsDefaultCellStyle = DataGridViewCellStyle2
272
+        DataGridViewCellStyle34.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
273
+        DataGridViewCellStyle34.WrapMode = System.Windows.Forms.DataGridViewTriState.[True]
274
+        Me.區域庫存_dgv.RowsDefaultCellStyle = DataGridViewCellStyle34
274 275
         Me.區域庫存_dgv.RowTemplate.Height = 24
275 276
         Me.區域庫存_dgv.Size = New System.Drawing.Size(191, 90)
276 277
         Me.區域庫存_dgv.TabIndex = 1323
@@ -620,8 +621,8 @@ Partial Class 銷售單審核
620 621
         '
621 622
         '物料清單_dgv
622 623
         '
623
-        DataGridViewCellStyle3.BackColor = System.Drawing.Color.FromArgb(CType(CType(192, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer))
624
-        Me.物料清單_dgv.AlternatingRowsDefaultCellStyle = DataGridViewCellStyle3
624
+        DataGridViewCellStyle35.BackColor = System.Drawing.Color.FromArgb(CType(CType(192, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer))
625
+        Me.物料清單_dgv.AlternatingRowsDefaultCellStyle = DataGridViewCellStyle35
625 626
         Me.物料清單_dgv.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
626 627
             Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
627 628
         Me.物料清單_dgv.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill
@@ -629,9 +630,9 @@ Partial Class 銷售單審核
629 630
         Me.物料清單_dgv.Location = New System.Drawing.Point(2, 79)
630 631
         Me.物料清單_dgv.Name = "物料清單_dgv"
631 632
         Me.物料清單_dgv.RowHeadersWidth = 5
632
-        DataGridViewCellStyle4.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
633
-        DataGridViewCellStyle4.WrapMode = System.Windows.Forms.DataGridViewTriState.[True]
634
-        Me.物料清單_dgv.RowsDefaultCellStyle = DataGridViewCellStyle4
633
+        DataGridViewCellStyle36.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
634
+        DataGridViewCellStyle36.WrapMode = System.Windows.Forms.DataGridViewTriState.[True]
635
+        Me.物料清單_dgv.RowsDefaultCellStyle = DataGridViewCellStyle36
635 636
         Me.物料清單_dgv.RowTemplate.Height = 24
636 637
         Me.物料清單_dgv.Size = New System.Drawing.Size(534, 235)
637 638
         Me.物料清單_dgv.TabIndex = 1283
@@ -866,16 +867,16 @@ Partial Class 銷售單審核
866 867
         '
867 868
         '銷售單據_dgv
868 869
         '
869
-        DataGridViewCellStyle5.BackColor = System.Drawing.Color.FromArgb(CType(CType(192, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
870
-        Me.銷售單據_dgv.AlternatingRowsDefaultCellStyle = DataGridViewCellStyle5
870
+        DataGridViewCellStyle37.BackColor = System.Drawing.Color.FromArgb(CType(CType(192, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
871
+        Me.銷售單據_dgv.AlternatingRowsDefaultCellStyle = DataGridViewCellStyle37
871 872
         Me.銷售單據_dgv.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill
872 873
         Me.銷售單據_dgv.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize
873 874
         Me.銷售單據_dgv.Location = New System.Drawing.Point(2, 28)
874 875
         Me.銷售單據_dgv.Name = "銷售單據_dgv"
875 876
         Me.銷售單據_dgv.RowHeadersWidth = 5
876
-        DataGridViewCellStyle6.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
877
-        DataGridViewCellStyle6.WrapMode = System.Windows.Forms.DataGridViewTriState.[True]
878
-        Me.銷售單據_dgv.RowsDefaultCellStyle = DataGridViewCellStyle6
877
+        DataGridViewCellStyle38.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
878
+        DataGridViewCellStyle38.WrapMode = System.Windows.Forms.DataGridViewTriState.[True]
879
+        Me.銷售單據_dgv.RowsDefaultCellStyle = DataGridViewCellStyle38
879 880
         Me.銷售單據_dgv.RowTemplate.Height = 24
880 881
         Me.銷售單據_dgv.Size = New System.Drawing.Size(146, 141)
881 882
         Me.銷售單據_dgv.TabIndex = 1256
@@ -1033,8 +1034,8 @@ Partial Class 銷售單審核
1033 1034
         '
1034 1035
         '銷售衍生運費_dgv
1035 1036
         '
1036
-        DataGridViewCellStyle7.BackColor = System.Drawing.Color.FromArgb(CType(CType(192, Byte), Integer), CType(CType(192, Byte), Integer), CType(CType(255, Byte), Integer))
1037
-        Me.銷售衍生運費_dgv.AlternatingRowsDefaultCellStyle = DataGridViewCellStyle7
1037
+        DataGridViewCellStyle39.BackColor = System.Drawing.Color.FromArgb(CType(CType(192, Byte), Integer), CType(CType(192, Byte), Integer), CType(CType(255, Byte), Integer))
1038
+        Me.銷售衍生運費_dgv.AlternatingRowsDefaultCellStyle = DataGridViewCellStyle39
1038 1039
         Me.銷售衍生運費_dgv.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Left) _
1039 1040
             Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
1040 1041
         Me.銷售衍生運費_dgv.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill
@@ -1042,9 +1043,9 @@ Partial Class 銷售單審核
1042 1043
         Me.銷售衍生運費_dgv.Location = New System.Drawing.Point(610, 465)
1043 1044
         Me.銷售衍生運費_dgv.Name = "銷售衍生運費_dgv"
1044 1045
         Me.銷售衍生運費_dgv.RowHeadersWidth = 5
1045
-        DataGridViewCellStyle8.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
1046
-        DataGridViewCellStyle8.WrapMode = System.Windows.Forms.DataGridViewTriState.[True]
1047
-        Me.銷售衍生運費_dgv.RowsDefaultCellStyle = DataGridViewCellStyle8
1046
+        DataGridViewCellStyle40.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
1047
+        DataGridViewCellStyle40.WrapMode = System.Windows.Forms.DataGridViewTriState.[True]
1048
+        Me.銷售衍生運費_dgv.RowsDefaultCellStyle = DataGridViewCellStyle40
1048 1049
         Me.銷售衍生運費_dgv.RowTemplate.Height = 24
1049 1050
         Me.銷售衍生運費_dgv.Size = New System.Drawing.Size(95, 190)
1050 1051
         Me.銷售衍生運費_dgv.TabIndex = 1344
@@ -1557,17 +1558,17 @@ Partial Class 銷售單審核
1557 1558
         '
1558 1559
         '客戶資料_dgv
1559 1560
         '
1560
-        DataGridViewCellStyle9.BackColor = System.Drawing.Color.FromArgb(CType(CType(192, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
1561
-        Me.客戶資料_dgv.AlternatingRowsDefaultCellStyle = DataGridViewCellStyle9
1561
+        DataGridViewCellStyle41.BackColor = System.Drawing.Color.FromArgb(CType(CType(192, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
1562
+        Me.客戶資料_dgv.AlternatingRowsDefaultCellStyle = DataGridViewCellStyle41
1562 1563
         Me.客戶資料_dgv.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
1563 1564
         Me.客戶資料_dgv.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill
1564 1565
         Me.客戶資料_dgv.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize
1565
-        Me.客戶資料_dgv.Location = New System.Drawing.Point(17, 9405)
1566
+        Me.客戶資料_dgv.Location = New System.Drawing.Point(17, 9689)
1566 1567
         Me.客戶資料_dgv.Name = "客戶資料_dgv"
1567 1568
         Me.客戶資料_dgv.RowHeadersWidth = 5
1568
-        DataGridViewCellStyle10.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
1569
-        DataGridViewCellStyle10.WrapMode = System.Windows.Forms.DataGridViewTriState.[True]
1570
-        Me.客戶資料_dgv.RowsDefaultCellStyle = DataGridViewCellStyle10
1569
+        DataGridViewCellStyle42.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
1570
+        DataGridViewCellStyle42.WrapMode = System.Windows.Forms.DataGridViewTriState.[True]
1571
+        Me.客戶資料_dgv.RowsDefaultCellStyle = DataGridViewCellStyle42
1571 1572
         Me.客戶資料_dgv.RowTemplate.Height = 24
1572 1573
         Me.客戶資料_dgv.Size = New System.Drawing.Size(191, 92)
1573 1574
         Me.客戶資料_dgv.TabIndex = 1254
@@ -1657,8 +1658,8 @@ Partial Class 銷售單審核
1657 1658
         '
1658 1659
         '銷售明細_dgv
1659 1660
         '
1660
-        DataGridViewCellStyle11.BackColor = System.Drawing.Color.White
1661
-        Me.銷售明細_dgv.AlternatingRowsDefaultCellStyle = DataGridViewCellStyle11
1661
+        DataGridViewCellStyle43.BackColor = System.Drawing.Color.White
1662
+        Me.銷售明細_dgv.AlternatingRowsDefaultCellStyle = DataGridViewCellStyle43
1662 1663
         Me.銷售明細_dgv.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Left) _
1663 1664
             Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
1664 1665
         Me.銷售明細_dgv.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill
@@ -1666,33 +1667,33 @@ Partial Class 銷售單審核
1666 1667
         Me.銷售明細_dgv.Location = New System.Drawing.Point(3, 29)
1667 1668
         Me.銷售明細_dgv.Name = "銷售明細_dgv"
1668 1669
         Me.銷售明細_dgv.RowHeadersWidth = 5
1669
-        DataGridViewCellStyle12.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
1670
-        DataGridViewCellStyle12.WrapMode = System.Windows.Forms.DataGridViewTriState.[True]
1671
-        Me.銷售明細_dgv.RowsDefaultCellStyle = DataGridViewCellStyle12
1670
+        DataGridViewCellStyle44.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
1671
+        DataGridViewCellStyle44.WrapMode = System.Windows.Forms.DataGridViewTriState.[True]
1672
+        Me.銷售明細_dgv.RowsDefaultCellStyle = DataGridViewCellStyle44
1672 1673
         Me.銷售明細_dgv.RowTemplate.Height = 24
1673 1674
         Me.銷售明細_dgv.Size = New System.Drawing.Size(892, 409)
1674 1675
         Me.銷售明細_dgv.TabIndex = 1199
1675 1676
         '
1676 1677
         '銷售備註_dgv
1677 1678
         '
1678
-        DataGridViewCellStyle13.BackColor = System.Drawing.Color.FromArgb(CType(CType(192, Byte), Integer), CType(CType(192, Byte), Integer), CType(CType(255, Byte), Integer))
1679
-        Me.銷售備註_dgv.AlternatingRowsDefaultCellStyle = DataGridViewCellStyle13
1679
+        DataGridViewCellStyle45.BackColor = System.Drawing.Color.FromArgb(CType(CType(192, Byte), Integer), CType(CType(192, Byte), Integer), CType(CType(255, Byte), Integer))
1680
+        Me.銷售備註_dgv.AlternatingRowsDefaultCellStyle = DataGridViewCellStyle45
1680 1681
         Me.銷售備註_dgv.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill
1681 1682
         Me.銷售備註_dgv.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize
1682 1683
         Me.銷售備註_dgv.Location = New System.Drawing.Point(3, 465)
1683 1684
         Me.銷售備註_dgv.Name = "銷售備註_dgv"
1684 1685
         Me.銷售備註_dgv.RowHeadersWidth = 5
1685
-        DataGridViewCellStyle14.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
1686
-        DataGridViewCellStyle14.WrapMode = System.Windows.Forms.DataGridViewTriState.[True]
1687
-        Me.銷售備註_dgv.RowsDefaultCellStyle = DataGridViewCellStyle14
1686
+        DataGridViewCellStyle46.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
1687
+        DataGridViewCellStyle46.WrapMode = System.Windows.Forms.DataGridViewTriState.[True]
1688
+        Me.銷售備註_dgv.RowsDefaultCellStyle = DataGridViewCellStyle46
1688 1689
         Me.銷售備註_dgv.RowTemplate.Height = 24
1689 1690
         Me.銷售備註_dgv.Size = New System.Drawing.Size(603, 190)
1690 1691
         Me.銷售備註_dgv.TabIndex = 1250
1691 1692
         '
1692 1693
         '收款事項_dgv
1693 1694
         '
1694
-        DataGridViewCellStyle15.BackColor = System.Drawing.Color.FromArgb(CType(CType(192, Byte), Integer), CType(CType(192, Byte), Integer), CType(CType(255, Byte), Integer))
1695
-        Me.收款事項_dgv.AlternatingRowsDefaultCellStyle = DataGridViewCellStyle15
1695
+        DataGridViewCellStyle47.BackColor = System.Drawing.Color.FromArgb(CType(CType(192, Byte), Integer), CType(CType(192, Byte), Integer), CType(CType(255, Byte), Integer))
1696
+        Me.收款事項_dgv.AlternatingRowsDefaultCellStyle = DataGridViewCellStyle47
1696 1697
         Me.收款事項_dgv.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Left) _
1697 1698
             Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
1698 1699
         Me.收款事項_dgv.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill
@@ -1700,9 +1701,9 @@ Partial Class 銷售單審核
1700 1701
         Me.收款事項_dgv.Location = New System.Drawing.Point(3, 682)
1701 1702
         Me.收款事項_dgv.Name = "收款事項_dgv"
1702 1703
         Me.收款事項_dgv.RowHeadersWidth = 5
1703
-        DataGridViewCellStyle16.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
1704
-        DataGridViewCellStyle16.WrapMode = System.Windows.Forms.DataGridViewTriState.[True]
1705
-        Me.收款事項_dgv.RowsDefaultCellStyle = DataGridViewCellStyle16
1704
+        DataGridViewCellStyle48.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
1705
+        DataGridViewCellStyle48.WrapMode = System.Windows.Forms.DataGridViewTriState.[True]
1706
+        Me.收款事項_dgv.RowsDefaultCellStyle = DataGridViewCellStyle48
1706 1707
         Me.收款事項_dgv.RowTemplate.Height = 24
1707 1708
         Me.收款事項_dgv.Size = New System.Drawing.Size(616, 93)
1708 1709
         Me.收款事項_dgv.TabIndex = 1282
@@ -1923,6 +1924,7 @@ Partial Class 銷售單審核
1923 1924
         Me.Panel2.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
1924 1925
             Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
1925 1926
         Me.Panel2.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D
1927
+        Me.Panel2.Controls.Add(Me.物料成本無管銷_tb)
1926 1928
         Me.Panel2.Controls.Add(Me.Label50)
1927 1929
         Me.Panel2.Controls.Add(Me.運費資料流水號_tb)
1928 1930
         Me.Panel2.Controls.Add(Me.Label21)
@@ -2059,6 +2061,16 @@ Partial Class 銷售單審核
2059 2061
         Me.顯示_bt.Text = "顯示物料控件"
2060 2062
         Me.顯示_bt.UseVisualStyleBackColor = True
2061 2063
         '
2064
+        '物料成本無管銷_tb
2065
+        '
2066
+        Me.物料成本無管銷_tb.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
2067
+        Me.物料成本無管銷_tb.Enabled = False
2068
+        Me.物料成本無管銷_tb.Location = New System.Drawing.Point(214, 355)
2069
+        Me.物料成本無管銷_tb.Name = "物料成本無管銷_tb"
2070
+        Me.物料成本無管銷_tb.Size = New System.Drawing.Size(165, 23)
2071
+        Me.物料成本無管銷_tb.TabIndex = 1339
2072
+        Me.物料成本無管銷_tb.Visible = False
2073
+        '
2062 2074
         '銷售單審核
2063 2075
         '
2064 2076
         Me.AutoScaleDimensions = New System.Drawing.SizeF(7.0!, 16.0!)
@@ -2252,4 +2264,5 @@ Partial Class 銷售單審核
2252 2264
     Friend WithEvents 顯示_bt As Button
2253 2265
     Friend WithEvents Label50 As Label
2254 2266
     Friend WithEvents 運費資料流水號_tb As TextBox
2267
+    Friend WithEvents 物料成本無管銷_tb As TextBox
2255 2268
 End Class

+ 10
- 4
YD-ERP-SYS/業務系統管理/銷售單審核.vb Näytä tiedosto

@@ -301,7 +301,7 @@ Public Class 銷售單審核
301 301
     Private Sub Set_合記計算()
302 302
         Dim 不含1類銷售小記 As Integer : Dim 金額1 As Integer = 0
303 303
         售價小計_tb.Text = "0" : 稅金_tb.Text = "0" : 銷售合計_tb.Text = "0" : 收入小計_tb.Text = "0" : 支出小計_tb.Text = "0" : 額外收支_tb.Text = "0" : 物料成本_tb.Text = "0"
304
-        司機運費_tb.Text = "0" : 管銷費用_tb.Text = "0" : 其他成本_tb.Text = "0" : 刷卡總和_tb.Text = "0" : 刷卡稅金_tb.Text = "0" : 刷卡傭金_tb.Text = "0"
304
+        司機運費_tb.Text = "0" : 管銷費用_tb.Text = "0" : 其他成本_tb.Text = "0" : 刷卡總和_tb.Text = "0" : 刷卡稅金_tb.Text = "0" : 刷卡傭金_tb.Text = "0" : 物料成本無管銷_tb.Text = "0"
305 305
         '-------001-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
306 306
         For i As Integer = 0 To 收款事項_dgv.Rows.Count - 1
307 307
             If 收款事項_dgv("真項次", i).Value.ToString = "0" And 收款事項_dgv("內容", i).Value.ToString <> "未收餘額" Then
@@ -315,6 +315,9 @@ Public Class 銷售單審核
315 315
 
316 316
             If Strings.Left(銷售明細_dgv("料號", i).Value.ToString, 1) <> "1" Then
317 317
                 物料成本_tb.Text = Val(物料成本_tb.Text) + (銷售明細_dgv("數量", i).Value * 銷售明細_dgv("成本", i).Value)
318
+                If 銷售明細_dgv("無管銷", i).Value = False Then
319
+                    物料成本無管銷_tb.Text = Val(物料成本無管銷_tb.Text) + (銷售明細_dgv("數量", i).Value * 銷售明細_dgv("成本", i).Value)
320
+                End If
318 321
                 不含1類銷售小記 = 不含1類銷售小記 + 銷售明細_dgv("售價", i).Value
319 322
             End If
320 323
             If Strings.Left(銷售明細_dgv("料號", i).Value.ToString, 1) = "1" Then
@@ -325,7 +328,7 @@ Public Class 銷售單審核
325 328
                 稅金_tb.Text = Val(稅金_tb.Text) + ((銷售明細_dgv("數量", i).Value * 銷售明細_dgv("單價", i).Value * 1.05) - (銷售明細_dgv("數量", i).Value * 銷售明細_dgv("單價", i).Value))
326 329
             End If
327 330
         Next
328
-        管銷費用_tb.Text = Val(物料成本_tb.Text) * 1.06 - Val(物料成本_tb.Text)
331
+        管銷費用_tb.Text = Val(物料成本無管銷_tb.Text) * 1.06 - Val(物料成本無管銷_tb.Text)
329 332
         銷售合計_tb.Text = Val(售價小計_tb.Text) + Val(稅金_tb.Text)
330 333
 
331 334
         If Val(稅金_tb.Text) = 0 And Val(刷卡稅金_tb.Text) = 0 Then
@@ -1177,7 +1180,7 @@ Public Class 銷售單審核
1177 1180
     Private Sub Reset_bt_Click(sender As Object, e As EventArgs) Handles Reset_bt.Click
1178 1181
         Dim 不含1類銷售小記 As Integer : Dim 金額1 As Integer = 0
1179 1182
         售價小計_tb.Text = "0" : 稅金_tb.Text = "0" : 銷售合計_tb.Text = "0" : 收入小計_tb.Text = "0" : 支出小計_tb.Text = "0" : 額外收支_tb.Text = "0" : 物料成本_tb.Text = "0"
1180
-        司機運費_tb.Text = "0" : 管銷費用_tb.Text = "0" : 其他成本_tb.Text = "0"
1183
+        司機運費_tb.Text = "0" : 管銷費用_tb.Text = "0" : 其他成本_tb.Text = "0" : 物料成本無管銷_tb.Text = "0"
1181 1184
         '-------001-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
1182 1185
         For i As Integer = 0 To 收款事項_dgv.Rows.Count - 1
1183 1186
             If 收款事項_dgv("真項次", i).Value.ToString = "0" And 收款事項_dgv("內容", i).Value.ToString <> "未收餘額" Then
@@ -1191,6 +1194,9 @@ Public Class 銷售單審核
1191 1194
 
1192 1195
             If Strings.Left(銷售明細_dgv("料號", i).Value.ToString, 1) <> 1 Then
1193 1196
                 物料成本_tb.Text = Val(物料成本_tb.Text) + (銷售明細_dgv("數量", i).Value * 銷售明細_dgv("成本", i).Value)
1197
+                If 銷售明細_dgv("無管銷", i).Value = False Then
1198
+                    物料成本無管銷_tb.Text = Val(物料成本無管銷_tb.Text) + (銷售明細_dgv("數量", i).Value * 銷售明細_dgv("成本", i).Value)
1199
+                End If
1194 1200
                 不含1類銷售小記 = 不含1類銷售小記 + 銷售明細_dgv("售價", i).Value
1195 1201
             End If
1196 1202
             If Strings.Left(銷售明細_dgv("料號", i).Value.ToString, 1) = 1 Then
@@ -1201,7 +1207,7 @@ Public Class 銷售單審核
1201 1207
                 稅金_tb.Text = Val(稅金_tb.Text) + ((銷售明細_dgv("數量", i).Value * 銷售明細_dgv("單價", i).Value * 1.05) - (銷售明細_dgv("數量", i).Value * 銷售明細_dgv("單價", i).Value))
1202 1208
             End If
1203 1209
         Next
1204
-        管銷費用_tb.Text = Val(物料成本_tb.Text) * 1.06 - Val(物料成本_tb.Text)
1210
+        管銷費用_tb.Text = Val(物料成本無管銷_tb.Text) * 1.06 - Val(物料成本無管銷_tb.Text)
1205 1211
         銷售合計_tb.Text = Val(售價小計_tb.Text) + Val(稅金_tb.Text)
1206 1212
 
1207 1213
         If Val(稅金_tb.Text) = 0 And Val(刷卡稅金_tb.Text) = 0 Then

+ 14
- 1
YD-ERP-SYS/業務系統管理/銷售單申請.Designer.vb Näytä tiedosto

@@ -198,6 +198,7 @@ Partial Class 銷售單申請
198 198
         Me.隱藏_bt = New System.Windows.Forms.Button()
199 199
         Me.Panel3 = New System.Windows.Forms.Panel()
200 200
         Me.顯示_bt = New System.Windows.Forms.Button()
201
+        Me.物料成本無管銷_tb = New System.Windows.Forms.TextBox()
201 202
         CType(Me.銷售單據_dgv, System.ComponentModel.ISupportInitialize).BeginInit()
202 203
         CType(Me.銷售明細_dgv, System.ComponentModel.ISupportInitialize).BeginInit()
203 204
         CType(Me.區域庫存_dgv, System.ComponentModel.ISupportInitialize).BeginInit()
@@ -1646,7 +1647,7 @@ Partial Class 銷售單申請
1646 1647
         Me.客戶資料_dgv.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
1647 1648
         Me.客戶資料_dgv.AutoSizeColumnsMode = System.Windows.Forms.DataGridViewAutoSizeColumnsMode.Fill
1648 1649
         Me.客戶資料_dgv.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize
1649
-        Me.客戶資料_dgv.Location = New System.Drawing.Point(17, 10480)
1650
+        Me.客戶資料_dgv.Location = New System.Drawing.Point(17, 10755)
1650 1651
         Me.客戶資料_dgv.Name = "客戶資料_dgv"
1651 1652
         Me.客戶資料_dgv.RowHeadersWidth = 5
1652 1653
         DataGridViewCellStyle12.Font = New System.Drawing.Font("微軟正黑體", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(136, Byte))
@@ -1930,6 +1931,7 @@ Partial Class 銷售單申請
1930 1931
         Me.Panel2.Anchor = CType(((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
1931 1932
             Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
1932 1933
         Me.Panel2.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D
1934
+        Me.Panel2.Controls.Add(Me.物料成本無管銷_tb)
1933 1935
         Me.Panel2.Controls.Add(Me.Label50)
1934 1936
         Me.Panel2.Controls.Add(Me.運費資料流水號_tb)
1935 1937
         Me.Panel2.Controls.Add(Me.隱藏_bt)
@@ -2079,6 +2081,16 @@ Partial Class 銷售單申請
2079 2081
         Me.顯示_bt.Text = "顯示物料控件"
2080 2082
         Me.顯示_bt.UseVisualStyleBackColor = True
2081 2083
         '
2084
+        '物料成本無管銷_tb
2085
+        '
2086
+        Me.物料成本無管銷_tb.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
2087
+        Me.物料成本無管銷_tb.Enabled = False
2088
+        Me.物料成本無管銷_tb.Location = New System.Drawing.Point(199, 372)
2089
+        Me.物料成本無管銷_tb.Name = "物料成本無管銷_tb"
2090
+        Me.物料成本無管銷_tb.Size = New System.Drawing.Size(165, 23)
2091
+        Me.物料成本無管銷_tb.TabIndex = 1298
2092
+        Me.物料成本無管銷_tb.Visible = False
2093
+        '
2082 2094
         '銷售單申請
2083 2095
         '
2084 2096
         Me.AutoScaleDimensions = New System.Drawing.SizeF(7.0!, 16.0!)
@@ -2273,4 +2285,5 @@ Partial Class 銷售單申請
2273 2285
     Friend WithEvents 顯示_bt As Button
2274 2286
     Friend WithEvents Label50 As Label
2275 2287
     Friend WithEvents 運費資料流水號_tb As TextBox
2288
+    Friend WithEvents 物料成本無管銷_tb As TextBox
2276 2289
 End Class

+ 10
- 4
YD-ERP-SYS/業務系統管理/銷售單申請.vb Näytä tiedosto

@@ -301,7 +301,7 @@ Public Class 銷售單申請
301 301
     Private Sub Set_合記計算()
302 302
         Dim 不含1類銷售小記 As Integer : Dim 金額1 As Integer = 0
303 303
         售價小計_tb.Text = "0" : 稅金_tb.Text = "0" : 銷售合計_tb.Text = "0" : 收入小計_tb.Text = "0" : 支出小計_tb.Text = "0" : 額外收支_tb.Text = "0" : 物料成本_tb.Text = "0"
304
-        司機運費_tb.Text = "0" : 管銷費用_tb.Text = "0" : 其他成本_tb.Text = "0" : 刷卡總和_tb.Text = "0" : 刷卡稅金_tb.Text = "0" : 刷卡傭金_tb.Text = "0"
304
+        司機運費_tb.Text = "0" : 管銷費用_tb.Text = "0" : 其他成本_tb.Text = "0" : 刷卡總和_tb.Text = "0" : 刷卡稅金_tb.Text = "0" : 刷卡傭金_tb.Text = "0" : 物料成本無管銷_tb.Text = "0"
305 305
         '-------001-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
306 306
         For i As Integer = 0 To 收款事項_dgv.Rows.Count - 1
307 307
             If 收款事項_dgv("真項次", i).Value.ToString = "0" And 收款事項_dgv("內容", i).Value.ToString <> "未收餘額" Then
@@ -315,6 +315,9 @@ Public Class 銷售單申請
315 315
 
316 316
             If Strings.Left(銷售明細_dgv("料號", i).Value.ToString, 1) <> "1" Then
317 317
                 物料成本_tb.Text = Val(物料成本_tb.Text) + (銷售明細_dgv("數量", i).Value * 銷售明細_dgv("成本", i).Value)
318
+                If 銷售明細_dgv("無管銷", i).Value = False Then
319
+                    物料成本無管銷_tb.Text = Val(物料成本無管銷_tb.Text) + (銷售明細_dgv("數量", i).Value * 銷售明細_dgv("成本", i).Value)
320
+                End If
318 321
                 不含1類銷售小記 = 不含1類銷售小記 + 銷售明細_dgv("售價", i).Value
319 322
             End If
320 323
             If Strings.Left(銷售明細_dgv("料號", i).Value.ToString, 1) = "1" Then
@@ -325,7 +328,7 @@ Public Class 銷售單申請
325 328
                 稅金_tb.Text = Val(稅金_tb.Text) + ((銷售明細_dgv("數量", i).Value * 銷售明細_dgv("單價", i).Value * 1.05) - (銷售明細_dgv("數量", i).Value * 銷售明細_dgv("單價", i).Value))
326 329
             End If
327 330
         Next
328
-        管銷費用_tb.Text = Val(物料成本_tb.Text) * 1.06 - Val(物料成本_tb.Text)
331
+        管銷費用_tb.Text = Val(物料成本無管銷_tb.Text) * 1.06 - Val(物料成本無管銷_tb.Text)
329 332
         銷售合計_tb.Text = Val(售價小計_tb.Text) + Val(稅金_tb.Text)
330 333
 
331 334
         If Val(稅金_tb.Text) = 0 And Val(刷卡稅金_tb.Text) = 0 Then
@@ -1263,7 +1266,7 @@ Public Class 銷售單申請
1263 1266
     Private Sub Reset_bt_Click(sender As Object, e As EventArgs) Handles Reset_bt.Click
1264 1267
         Dim 不含1類銷售小記 As Integer : Dim 金額1 As Integer = 0
1265 1268
         售價小計_tb.Text = "0" : 稅金_tb.Text = "0" : 銷售合計_tb.Text = "0" : 收入小計_tb.Text = "0" : 支出小計_tb.Text = "0" : 額外收支_tb.Text = "0" : 物料成本_tb.Text = "0"
1266
-        司機運費_tb.Text = "0" : 管銷費用_tb.Text = "0" : 其他成本_tb.Text = "0" : 刷卡總和_tb.Text = "0" : 刷卡稅金_tb.Text = "0" : 刷卡傭金_tb.Text = "0"
1269
+        司機運費_tb.Text = "0" : 管銷費用_tb.Text = "0" : 其他成本_tb.Text = "0" : 刷卡總和_tb.Text = "0" : 刷卡稅金_tb.Text = "0" : 刷卡傭金_tb.Text = "0" : 物料成本無管銷_tb.Text = "0"
1267 1270
         '-------001-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
1268 1271
         For i As Integer = 0 To 收款事項_dgv.Rows.Count - 1
1269 1272
             If 收款事項_dgv("真項次", i).Value.ToString = "0" And 收款事項_dgv("內容", i).Value.ToString <> "未收餘額" Then
@@ -1277,6 +1280,9 @@ Public Class 銷售單申請
1277 1280
 
1278 1281
             If Strings.Left(銷售明細_dgv("料號", i).Value.ToString, 1) <> 1 Then
1279 1282
                 物料成本_tb.Text = Val(物料成本_tb.Text) + (銷售明細_dgv("數量", i).Value * 銷售明細_dgv("成本", i).Value)
1283
+                If 銷售明細_dgv("無管銷", i).Value = False Then
1284
+                    物料成本無管銷_tb.Text = Val(物料成本無管銷_tb.Text) + (銷售明細_dgv("數量", i).Value * 銷售明細_dgv("成本", i).Value)
1285
+                End If
1280 1286
                 不含1類銷售小記 = 不含1類銷售小記 + 銷售明細_dgv("售價", i).Value
1281 1287
             End If
1282 1288
             If Strings.Left(銷售明細_dgv("料號", i).Value.ToString, 1) = 1 Then
@@ -1287,7 +1293,7 @@ Public Class 銷售單申請
1287 1293
                 稅金_tb.Text = Val(稅金_tb.Text) + ((銷售明細_dgv("數量", i).Value * 銷售明細_dgv("單價", i).Value * 1.05) - (銷售明細_dgv("數量", i).Value * 銷售明細_dgv("單價", i).Value))
1288 1294
             End If
1289 1295
         Next
1290
-        管銷費用_tb.Text = Val(物料成本_tb.Text) * 1.06 - Val(物料成本_tb.Text)
1296
+        管銷費用_tb.Text = Val(物料成本無管銷_tb.Text) * 1.06 - Val(物料成本無管銷_tb.Text)
1291 1297
         銷售合計_tb.Text = Val(售價小計_tb.Text) + Val(稅金_tb.Text)
1292 1298
 
1293 1299
         If Val(稅金_tb.Text) = 0 And Val(刷卡稅金_tb.Text) = 0 Then

Loading…
Peruuta
Tallenna