Esempio n. 1
0
        private void addlink()
        {
            string id = Request.QueryString["id"].ToString();

            FactLinkmanManager.deleteFactLinkmanByfactId(Convert.ToInt32(id));

            string strList = this.hidlink.Value;

            if (strList != "")
            {
                string[] row  = null;
                string[] cell = null;
                EtNet_Models.FactLinkman cusLink = null;
                if (strList.IndexOf(',') >= 0)
                {
                    row = strList.Split(',');
                }
                else
                {
                    row = new string[1] {
                        strList
                    };
                }
                for (int i = 0; i < row.Length; i++)
                {
                    cusLink           = new EtNet_Models.FactLinkman();
                    cell              = row[i].Split('|');
                    cusLink.LinkName  = cell[0];
                    cusLink.Duty      = cell[1];
                    cusLink.Telephone = cell[2];
                    cusLink.Fax       = cell[3];
                    cusLink.Mobile    = cell[4];
                    cusLink.Email     = cell[5];
                    cusLink.QQ        = cell[6];
                    cusLink.Skype     = cell[7];
                    cusLink.FactId    = Convert.ToInt32(id);
                    FactLinkmanManager.addFactLinkman(cusLink);
                }
            }
        }
Esempio n. 2
0
        //次要联系人
        private void addlink()
        {
            string strList = this.hidlink.Value;

            if (strList != "")
            {
                string[] row  = null;
                string[] cell = null;
                EtNet_Models.FactLinkman factLink = null;
                if (strList.IndexOf(',') >= 0)
                {
                    row = strList.Split(',');
                }
                else
                {
                    row = new string[1] {
                        strList
                    };
                }
                for (int i = 0; i < row.Length; i++)
                {
                    factLink           = new EtNet_Models.FactLinkman();
                    cell               = row[i].Split('|');
                    factLink.LinkName  = cell[0];
                    factLink.Duty      = cell[1];
                    factLink.Telephone = cell[2];
                    factLink.Fax       = cell[3];
                    factLink.Mobile    = cell[4];
                    factLink.Email     = cell[5];
                    factLink.QQ        = cell[6];
                    factLink.Skype     = cell[7];
                    factLink.FactId    = FactoryManager.getLastOneID().Id;
                    FactLinkmanManager.addFactLinkman(factLink);
                }
            }
        }