| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287 |
- using Castle.ActiveRecord;
- using NHibernate.Criterion;
- using System;
- using System.Text;
- namespace BizCom
- {
- [ActiveRecord("CE_ErpTradeRefund")]
- public class CeErpTradeRefund : ComBase<CeErpTradeRefund>
- {
- /// <summary>
- /// 退款单号
- /// </summary>
- [PrimaryKey(PrimaryKeyType.Assigned)]
- public string refund_id { get; set; }
- private string _oid = "";
- /// <summary>
- ///
- /// </summary>
- [Property]
- public string oid
- {
- get { return _oid; }
- set { _oid = value; }
- }
- private string _tid = "";
- /// <summary>
- ///
- /// </summary>
- [Property]
- public string tid
- {
- get { return _tid; }
- set { _tid = value; }
- }
- private string _total_fee = "";
- /// <summary>
- ///交易金额
- /// </summary>
- [Property]
- public string total_fee
- {
- get { return _total_fee; }
- set { _total_fee = value; }
- }
- private string _buyer_nick = "";
- /// <summary>
- ///
- /// </summary>
- [Property]
- public string buyer_nick
- {
- get { return _buyer_nick; }
- set { _buyer_nick = value; }
- }
- private string _seller_nick = "";
- /// <summary>
- ///
- /// </summary>
- [Property]
- public string seller_nick
- {
- get { return _seller_nick; }
- set { _seller_nick = value; }
- }
- /// <summary>
- ///创建时间
- /// </summary>
- [Property]
- public DateTime? created { get; set; }
- /// <summary>
- ///修改时间
- /// </summary>
- [Property]
- public DateTime? modified { get; set; }
- private string _order_status = "";
- /// <summary>
- ///交易状态
- /// </summary>
- [Property]
- public string order_status
- {
- get { return _order_status; }
- set { _order_status = value; }
- }
- private string _status = "";
- /// <summary>
- ///退款状态
- /// </summary>
- [Property]
- public string status
- {
- get { return _status; }
- set { _status = value; }
- }
- private string _good_status = "";
- /// <summary>
- ///货物状态
- /// </summary>
- [Property]
- public string good_status
- {
- get { return _good_status; }
- set { _good_status = value; }
- }
- private bool _has_good_return = false;
- /// <summary>
- ///买家是否需要退货
- /// </summary>
- [Property]
- public bool has_good_return
- {
- get { return _has_good_return; }
- set { _has_good_return = value; }
- }
- private string _refund_fee = "";
- /// <summary>
- ///退款金额
- /// </summary>
- [Property]
- public string refund_fee
- {
- get { return _refund_fee; }
- set { _refund_fee = value; }
- }
- private string _payment = "";
- /// <summary>
- ///
- /// </summary>
- [Property]
- public string payment
- {
- get { return _payment; }
- set { _payment = value; }
- }
- private string _reason = "";
- /// <summary>
- ///退款原因
- /// </summary>
- [Property]
- public string reason
- {
- get { return _reason; }
- set { _reason = value; }
- }
- private string _describe = "";
- /// <summary>
- ///退款说明
- /// </summary>
- [Property]
- public string describe
- {
- get { return _describe; }
- set { _describe = value; }
- }
- private string _refund_phase = "";
- /// <summary>
- ///
- /// </summary>
- [Property]
- public string refund_phase
- {
- get { return _refund_phase; }
- set { _refund_phase = value; }
- }
- private string _responsibleUserId = "";
- /// <summary>
- ///责任人 123_k,23_s
- /// </summary>
- [Property]
- public string ResponsibleUserId
- {
- get { return _responsibleUserId; }
- set { _responsibleUserId = value; }
- }
- private int _refundState = 0;
- /// <summary>
- ///审核状态 1待审核2待确认
- /// </summary>
- [Property]
- public int RefundState
- {
- get { return _refundState; }
- set { _refundState = value; }
- }
- private string _responsibleUserName = "";
- /// <summary>
- ///责任人名字
- /// </summary>
- [Property]
- public string ResponsibleUserName
- {
- get { return _responsibleUserName; }
- set { _responsibleUserName = value; }
- }
- private string _memo = "";
- /// <summary>
- ///标记的备注
- /// </summary>
- [Property]
- public string Memo
- {
- get { return _memo; }
- set { _memo = value; }
- }
- private int _isPartRefund = 0;
- /// <summary>
- ///是否部分退款
- /// </summary>
- [Property]
- public int IsPartRefund
- {
- get { return _isPartRefund; }
- set { _isPartRefund = value; }
- }
- private string _refundDesc = "";
- /// <summary>
- ///客户额外描述原因
- /// </summary>
- [Property]
- public string refundDesc
- {
- get { return _refundDesc; }
- set { _refundDesc = value; }
- }
- private string _buyer_id = "";
- /// <summary>
- ///客户id
- /// </summary>
- [Property]
- public string buyer_id
- {
- get { return _buyer_id; }
- set { _buyer_id = value; }
- }
- public static void Del(object id)
- {
- StringBuilder sql = new StringBuilder();
- sql.AppendFormat("delete from CE_ErpTradeRefund where tid='" + id + "'");
- ExecuteNonQuery(sql.ToString());
- }
- public static CeErpTradeRefund Get(string rid)
- {
- return FindFirst(Expression.Sql("refund_id='" + rid + "'"));
- }
- public static CeErpTradeRefund GetByTid(string rid)
- {
- return FindFirst(Expression.Sql("tid='" + rid + "'"));
- }
- public static CeErpTradeRefund GetByTidAndReId(string rid, string refundid)
- {
- return FindFirst(Expression.Sql(string.Format("tid='{0}' and refund_id = '{1}'", rid, refundid)));
- }
- public static CeErpTradeRefund GetByOidAndReId(string rid, string refundid)
- {
- return FindFirst(Expression.Sql(string.Format("oid='{0}' and refund_id = '{1}'", rid, refundid)));
- }
- }
- }
|