재고관리 추가 품명에 바코드 추가(김정만)
This commit is contained in:
@@ -3,6 +3,7 @@ using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Data.SqlClient;
|
||||
using System.Windows.Forms;
|
||||
|
||||
namespace FCOMMON
|
||||
{
|
||||
@@ -31,6 +32,35 @@ namespace FCOMMON
|
||||
public int qty;
|
||||
}
|
||||
|
||||
public static List<string> GetItemStorageList()
|
||||
{
|
||||
|
||||
|
||||
var cn = getCn();
|
||||
cn.Open();
|
||||
|
||||
List<string> retval = new List<string>();
|
||||
var sql = "SELECT Storage FROM Items WHERE(gcode = @gcode) AND(ISNULL(disable, 0) = 0) AND(ISNULL(Storage, '') <> '') GROUP BY Storage ORDER BY Storage";
|
||||
var cmd = new SqlCommand(sql, cn);
|
||||
cmd.Parameters.Add("gcode", System.Data.SqlDbType.VarChar).Value = FCOMMON.info.Login.gcode;
|
||||
try
|
||||
{
|
||||
var rdr = cmd.ExecuteReader();
|
||||
while(rdr.Read())
|
||||
{
|
||||
retval.Add(rdr[0].ToString());
|
||||
}
|
||||
}
|
||||
catch
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
cn.Close();
|
||||
cn.Dispose();
|
||||
return retval;
|
||||
}
|
||||
|
||||
public static byte[] getImagByteArray(System.Drawing.Image img)
|
||||
{
|
||||
if (img == null || img.Width < 1 || img.Height < 1) return null;
|
||||
|
||||
Reference in New Issue
Block a user