123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221 |
- @{
- ViewBag.Title = "Detail";
- Layout = "~/Views/Shared/_Layout.cshtml";
- }
- @using MES.Production.Service;
- @using Central.Control.Domain;
- @using Ant.Service.Common;
- @using Ant.Service.Common.Enums;
- @using MES.Production.Entity;
- @using CommonToolHelper;
- @model EntYW_UserDistributor
- <style>
- body {
- background-color: white;
- }
- .changeicon {
- float: right;
- margin-right: -15px;
- position: absolute;
- right: -7px;
- top: 0px;
- border: none;
- background-color: #18a689;
- color: #FFFFFF;
- line-height: 33px;
- height: 33px;
- }
- </style>
- <link href="~/Content/uploadone/CSS/webuploader.css" rel="stylesheet" />
- <link href="~/Content/uploadone/CSS/bootstrap.min.css" rel="stylesheet" />
- <link href="~/Content/uploadone/CSS/uploadstyle.css" rel="stylesheet" />
- <link href="~/Content/uploadone/CSS/font-awesome.css" rel="stylesheet" />
- <!-- 配置文件 -->
- <!-- 编辑器源码文件 -->
- @using (Ajax.BeginForm("Save", null, new AjaxOptions()
- {
- HttpMethod = "Post",
- OnBegin = "SubAjax.Loading",
- OnComplete = "SubAjax.Complate",
- OnFailure = "SubAjax.Failure",
- OnSuccess = "SubAjax.Success"
- }, new { @class = "form-horizontal dig-from", @role = "form" }))
- {
- @Html.Hidden("productline")
- @Html.Hidden("distributorsid", ViewData["distributorsid"])
- <div class="wrapper-content">
- <div class="panel-body">
- <div class="tab-content">
- <div id="tab-1" class="tab-pane active">
- <div class="form-group">
- <label class="col-lg-3 control-label">产品线负责人员</label>
- <div class="col-lg-8">
- @{
- var fromuser = ViewData["userid"] as string;
- }
- <span id="readuser" class="form-control" style="padding:8px 5px; font-size:14px;overflow:hidden;">
- @if (!string.IsNullOrEmpty(fromuser))
- {
- @Html.Raw(fromuser.Split('|')[1]);
- }
- </span>
- @Html.Hidden("hidsendUserid", (!string.IsNullOrEmpty(fromuser) ? fromuser.Split('|')[0] : ""))
- <button class="changeicon" id="changesendUser" type="button">
- 选择
- </button>
- </div>
- </div>
- <div class="form-group">
- <label class="col-lg-3 control-label">轮拖轮式收条线</label>
- <div class="col-lg-8">
- <label class="radio-inline">
- <input name="ckb_per" type="checkbox" value="601" data-parent="轮拖"> 轮 拖
- </label>
- <label class="radio-inline">
- <input name="ckb_per" type="checkbox" value="615" data-parent="轮式收"> 轮式收
- @*<input type="radio" name="sexcode" value="2" @(Model.SEXCODE != null && Model.SEXCODE == 2 ? "checked" : "")>女*@
- </label>
- </div>
- </div>
- <div class="form-group">
- <label class="col-lg-3 control-label">履带插秧条线</label>
- <div class="col-lg-8">
- <label class="radio-inline">
- <input name="ckb_per" type="checkbox" value="612" data-parent="履带收"> 履带收
- </label>
- <label class="radio-inline">
- <input name="ckb_per" type="checkbox" value="61102" data-parent="插秧机"> 插秧机
- </label>
- </div>
- </div>
- <div class="form-group">
- <label class="col-lg-3 control-label">玉米收花生机线</label>
- <div class="col-lg-8">
- <label class="radio-inline">
- <input name="ckb_per" type="checkbox" value="622" data-parent="玉米收"> 玉米收
- </label>
- <label class="radio-inline">
- <input name="ckb_per" type="checkbox" value="628" data-parent="花生机"> 花生机
- </label>
- </div>
- </div>
- </div>
- </div>
- </div>
- </div>
- <div class="hr-line-dashed">
- <div class="form-group" style="margin-top:10px !important;">
- <div class="col-sm-2 col-sm-offset-2" style="text-align:center">
- <button class="btn btn-primary" id="btn-save" type="submit" onclick="GetParentModuleId()"><i class="fa fa-check"></i> <span>确定保存</span></button>
- <button class="btn btn-warning" id="btn-dig-close1" type="button"><i class="im-undo2"></i> 取消返回</button>
- </div>
- </div>
- </div>
- }
- @section scripts{
- <script type="text/javascript">
- var applicationPath = "http://" + window.location.host;
- $(function () {
- $('.select2').select2();
- //分配部门
- $('#changeDpt').click(function () {
- var vals = $('#hiddpt').val();
- top.dialog({
- url: '/Sys/Department/GetSelectDpt',
- title: '选择景点',
- width: 450,
- height: 500,
- data: vals, // 给 iframe 的数据
- onclose: function () {
- if (this.returnValue != 'no') {
- $('#hiddpt').val(this.returnValue.split('|')[0]);
- $('#dpt').html(this.returnValue.split('|')[1]);
- //清理岗位
- $('#hidpost').val('');
- $('#post').html('');
- }
- },
- oniframeload: function () {
- }
- }).showModal();
- return false;
- });
- $('#changesendUser').click(function () {
- var vals = $('#hidsendUserid').val();
- dig.addModel('选择用户', '/Sys/User/SelectUser?userid=' + vals, 800, 500, function () {
- if (this.returnValue != 'no' && this.returnValue != 'undefined' && this.returnValue != '') {
- var vl = "";
- if ($('#hidsendUserid').val() == "") {
- vl = this.returnValue.split('|')[0]
- }
- else {
- vl = $('#hidsendUserid').val() + "," + this.returnValue.split('|')[0]
- }
- //alert(vl);
- $('#hidsendUserid').val(vl);
- var vals = "";
- if ($('#readuser').html().replace(/^\s\s*/, '').replace(/\s\s*$/, '').length == 0) {
- vals = this.returnValue.split('|')[1];
- }
- else {
- vals = $('#readuser').html().replace(/^\s\s*/, '').replace(/\s\s*$/, '') + "," + this.returnValue.split('|')[1];
- }
- $('#readuser').html(vals);
- }
- });
- });
- //分配岗位
- $('#changePost').click(function () {
- var dptid = $('#DPTID').val() + ',' + $('#hiddpt').val();
- if ($('#DPTID').val() == '' && $('#hiddpt').val() == '') {
- dig.alertError('提示', '请选择部门后再选择岗位');
- return;
- }
- var vals = $('#hidpost').val();
- top.dialog({
- url: '/Sys/Post/PostUser?dptid=' + dptid,
- title: '分配岗位',
- width: 500,
- height: 500,
- data: vals, // 给 iframe 的数据
- onclose: function () {
- if (this.returnValue != 'no') {
- $('#hidpost').val(this.returnValue.split('|')[0]);
- $('#post').html(this.returnValue.split('|')[1]);
- }
- },
- oniframeload: function () {
- }
- }).showModal();
- return false;
- });
- });
- function GetParentModuleId() {
- var perid = '';
- $('input[name="ckb_per"]:checked').each(function () {
- perid += $(this).attr('value') + ',';
- });
- $('#productline').val(perid);
- }
- </script>
- }
|